Exemple #1
0
        public static SubRecord Read(Stream stream)
        {
            SubRecord record = SubRecord.ReadBase(stream);

            switch (record.Type)
            {
            case SubRecordType.CommonObjectData:
                return(new CommonObjectData(record));

            case SubRecordType.End:
                return(new End(record));

            case SubRecordType.GroupMarker:
                return(new GroupMarker(record));

            case SubRecordType.ClipboardFormat:
                return(new ClipboardFormat(record));

            case SubRecordType.PictureOption:
                return(new PictureOption(record));

            default:
                return(record);
            }
        }
 public static new SubRecord ReadBase(Stream stream)
 {
     BinaryReader reader = new BinaryReader(stream);
     SubRecord record = new SubRecord();
     record.Type = reader.ReadUInt16();
     record.Size = reader.ReadUInt16();
     record.Data = reader.ReadBytes(record.Size);
     return record;
 }
        public new static SubRecord ReadBase(Stream stream)
        {
            BinaryReader reader = new BinaryReader(stream);
            SubRecord    record = new SubRecord();

            record.Type = reader.ReadUInt16();
            record.Size = reader.ReadUInt16();
            record.Data = reader.ReadBytes(record.Size);
            return(record);
        }
Exemple #4
0
        public override void Decode()
        {
            MemoryStream stream = new MemoryStream(Data);

            SubRecords.Clear();
            while (stream.Position < Size)
            {
                SubRecord subRecord = SubRecord.Read(stream);
                subRecord.Decode();
                SubRecords.Add(subRecord);
            }
        }
 public SubRecord(SubRecord record)
     : base(record)
 {
 }
Exemple #6
0
 public GroupMarker(SubRecord record) : base(record)
 {
 }
 public ClipboardFormat(SubRecord record)
     : base(record)
 {
 }
 public CommonObjectData(SubRecord record) : base(record)
 {
 }
Exemple #9
0
 public End(SubRecord record) : base(record)
 {
 }
 public PictureOption(SubRecord record)
     : base(record)
 {
 }
 public SubRecord(SubRecord record) : base(record)
 {
 }
Exemple #12
0
 public End(SubRecord record)
     : base(record)
 {
 }
 public ClipboardFormat(SubRecord record) : base(record)
 {
 }
Exemple #14
0
 public PictureOption(SubRecord record) : base(record)
 {
 }
 public CommonObjectData(SubRecord record)
     : base(record)
 {
 }
 public GroupMarker(SubRecord record)
     : base(record)
 {
 }