Package tv.porst.splib.binaryparser

Examples of tv.porst.splib.binaryparser.AsciiString


    final Flag fontFlagsWideCodes = parseFlag(parser, 0x00006, "DefineFont2::FontFlagsWideCodes");
    final Flag fontFlagsItalic = parseFlag(parser, 0x00006, "DefineFont2::FontFlagsItalic");
    final Flag fontFlagsBold = parseFlag(parser, 0x00006, "DefineFont2::FontFlagsBold");
    final UINT8 languageCode = parseUINT8(parser, 0x00006, "Define2::LanguageCode");
    final UINT8 fontNameLen = parseUINT8(parser, 0x00006, "DefineFont2::FontNameLen");
    final AsciiString fontName = parseString(parser, fontNameLen.value(), 0x00006, "DefineFont2::FontName");
    final UINT16 numGlyphs = parseUINT16(parser, 0x00006, "DefineFont2::NumGlyphs");

    final List<IParsedINTElement> offsetTable = new ArrayList<IParsedINTElement>();

    for (int i=0;i<numGlyphs.value();i++) {
View Full Code Here


   *
   * @throws SWFParserException Thrown if parsing the tag failed.
   */
  public static EnableDebuggerTag parse(final RecordHeader header, final SWFBinaryParser parser) throws SWFParserException {

    final AsciiString password = parseString(parser, 0x00006, "EnableDebugger::Password");

    return new EnableDebuggerTag(header, password);
  }
View Full Code Here

   *
   * @throws SWFParserException Thrown if parsing the tag failed.
   */
  public static ImportAssetsTag parse(final RecordHeader header, final SWFBinaryParser parser) throws SWFParserException {

    final AsciiString url = parseString(parser, 0x00006, "ImportAssets::URL");
    final UINT16 count= parseUINT16(parser, 0x00006, "ImportAssets::Count");

    final List<Symbol> symbols = new ArrayList<Symbol>();

    for (int i=0;i<count.value();i++) {
View Full Code Here

   *
   * @throws SWFParserException Thrown if parsing the tag failed.
   */
  public static FrameLabelTag parse(final RecordHeader header, final SWFBinaryParser parser) throws SWFParserException {

    final AsciiString name = parseString(parser, 0x00006, "FrameLabel::Name");
    final UINT8 namedAnchorFlag = parseUINT8If(parser, 0x00006, header.getNormalizedLength() == name.value().length() + 1 + 1, "FrameLabel::NamedAnchorFlag");

    return new FrameLabelTag(header, name, namedAnchorFlag);
  }
View Full Code Here

    final UINT16 depth = parseUINT16(parser, 0x00005, "PlaceObject2::Depth");
    final UINT16 characterId = parseUINT16If(parser, 0x00006, placeFlagHasCharacter, "PlaceObject2::CharacterId");
    final Matrix matrix = MatrixParser.parseIf(parser, placeFlagHasMatrix, "PlaceObject2::Matrix");
    final CxFormWithAlpha colorTransform = CxFormWithAlphaParser.parseIf(parser, placeFlagHasColorTransform, "PlaceObject2::CxFormWithAlpha");
    final UINT16 ratio = parseUINT16If(parser, 0x00006, placeFlagHasRatio, "PlaceObject2::Ratio");
    final AsciiString name = parseStringIf(parser, 0x00006, placeFlagHasName, "PlaceObject2::Name");
    final UINT16 clipDepth = parseUINT16If(parser, 0x00006, placeFlagHasClipDepth, "PlaceObject2::ClipDepth");
    final ClipActions clipActions = parseIf(parser, version, placeFlagHasClipActions, "PlaceObject2::ClipActions");

    return new PlaceObject2Tag(header, placeFlagHasClipActions, placeFlagHasClipDepth, placeFlagHasName,
        placeFlagHasRatio, placeFlagHasColorTransform, placeFlagHasMatrix,
View Full Code Here

   * @throws SWFParserException Thrown if parsing the tag failed.
   */
  public static DoABCTag parse(final RecordHeader header, final SWFBinaryParser parser) throws SWFParserException {

    final UINT32 flags = parseUINT32(parser, 0x00006, "DoABC::Flags");
    final AsciiString name = parseString(parser, 0x00006, "DoABC::Name");

    final AS3Data abcData = AS3DataParser.parse(parser, "DoABC::ABCData");

    return new DoABCTag(header, flags, name, abcData);
  }
View Full Code Here

   */
  public static DefineFontInfoTag parse(final RecordHeader header, final SWFBinaryParser parser) throws SWFParserException {

    final UINT16 fontId = parseUINT16(parser, 0x00006, "DefineFontInfo::FontId");
    final UINT8 fontNameLen = parseUINT8(parser, 0x00006, "DefineFontInfo::FontNameLen");
    final AsciiString fontName = parseString(parser, fontNameLen.value(), 0x00006, "DefineFontInfo::FontName");
    final UBits fontFlagsReserved = parseUBits(parser, 2, 0x00006, "DefineFontInfo::FontFlagsReserved");
    final Flag fontFlagsSmallText = parseFlag(parser, 0x00006, "DefineFontInfo::FontFlagsSmallText");
    final Flag fontFlagsShiftJIS = parseFlag(parser, 0x00006, "DefineFontInfo::FontFlagsShiftJIS");
    final Flag fontFlagsANSI = parseFlag(parser, 0x00006, "DefineFontInfo::FontFlagsANSI");
    final Flag fontFlagsItalic = parseFlag(parser, 0x00006, "DefineFontInfo::FontFlagsItalic");
View Full Code Here

    final UINT16 fontId = parseUINT16(parser, 0x00006, "DefineText2::FontId");
    final UBits fontFlagsReserved = parseUBits(parser, 5, 0x00006, "DefineFont4::FontFlagsReserved");
    final Flag fontFlagsHasFontData = parseFlag(parser, 0x00006, "DefineFont4::FontFlagsHasFontData");
    final Flag fontFlagsItalic = parseFlag(parser, 0x00006, "DefineFont4::FontFlagsItalic");
    final Flag fontFlagsBold = parseFlag(parser, 0x00006, "DefineFont4::FontFlagsBold");
    final AsciiString fontName = parseString(parser, 0x00006, "DefineFont4::FontName");

    final int remainingLength = header.getNormalizedLength() - 1 - 1 - fontName.value().length() - 1;

    final ByteArray fontData = parseByteArrayIf(parser, remainingLength, 0x00006, fontFlagsHasFontData, "DefineFont4::FontData");

    return new DefineFont4Tag(header, fontId, fontFlagsReserved, fontFlagsHasFontData, fontFlagsItalic, fontFlagsBold, fontName, fontData);
  }
View Full Code Here

public class ActionGetURLParser {

  public static ActionGetURL parse(final SWFBinaryParser parser, final UINT8 actionCode, final String fieldName) throws SWFParserException {
    final UINT16 length = parseUINT16(parser, 0x00006, fieldName + "::Length");
    final AsciiString urlString = parseString(parser, 0x00006, "::UrlString");
    final AsciiString targetString = parseString(parser, 0x00006, "::TargetString");

    return new ActionGetURL(actionCode, length, urlString, targetString);
  }
View Full Code Here

   * @throws SWFParserException Thrown if the structure could not be parsed.
   */
  public static SceneName parse(final SWFBinaryParser parser, final String fieldName) throws SWFParserException {

    final EncodedU32 offset = EncodedU32Parser.parse(parser, fieldName + "::Offset");
    final AsciiString name = parseString(parser, 0x00006, fieldName + "::Name");

    return new SceneName(offset, name);
  }
View Full Code Here

TOP

Related Classes of tv.porst.splib.binaryparser.AsciiString

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.