예제 #1
0
    public virtual async Task ReadCompressedChunk(ByteArrayReader reader) {
      UncompressedOffset = reader.ReadInt32();
      UncompressedSize   = reader.ReadInt32();

      CompressedOffset = reader.ReadInt32();
      CompressedSize   = reader.ReadInt32();

      Header = new DomainCompressedChunkHeader();

      await Header.ReadCompressedChunkHeader(reader.Branch(CompressedOffset), 1, UncompressedSize, CompressedSize);
    }
예제 #2
0
        public virtual async Task ReadCompressedChunk(ByteArrayReader reader)
        {
            UncompressedOffset = reader.ReadInt32();
            UncompressedSize   = reader.ReadInt32();

            CompressedOffset = reader.ReadInt32();
            CompressedSize   = reader.ReadInt32();

            Header = new DomainCompressedChunkHeader();

            await Header.ReadCompressedChunkHeader(reader.Branch(CompressedOffset), 1, UncompressedSize, CompressedSize);
        }
    public override async Task ReadCompressedChunk(ByteArrayReader reader) {
      BulkDataFlags = reader.ReadUInt32();

      UncompressedSize = reader.ReadInt32();

      CompressedSize   = reader.ReadInt32();
      CompressedOffset = reader.ReadInt32();

      if (((BulkDataCompressionTypes)BulkDataFlags & NothingToDo) > 0) return;

      Header = new DomainCompressedChunkHeader();

      await Header.ReadCompressedChunkHeader(reader, BulkDataFlags, UncompressedSize, CompressedSize);
    }
예제 #4
0
        public override async Task ReadCompressedChunk(ByteArrayReader reader)
        {
            BulkDataFlags = reader.ReadUInt32();

            UncompressedSize = reader.ReadInt32();

            CompressedSize   = reader.ReadInt32();
            CompressedOffset = reader.ReadInt32();

            if (((BulkDataCompressionTypes)BulkDataFlags & NothingToDo) > 0)
            {
                return;
            }

            Header = new DomainCompressedChunkHeader();

            await Header.ReadCompressedChunkHeader(reader, BulkDataFlags, UncompressedSize, CompressedSize);
        }
    public async Task<int> BuildCompressedChunk(ByteArrayReader reader, BulkDataCompressionTypes compressionFlags) {
      BulkDataFlags = (uint)compressionFlags;

      int builderSize = sizeof(uint)
                      + sizeof(int) * 3;

      if ((compressionFlags & NothingToDo) > 0) return builderSize;

      reader.Seek(0);

      UncompressedSize = reader.Remaining;

      Header = new DomainCompressedChunkHeader();

      builderSize += await Header.BuildCompressedChunkHeader(reader, BulkDataFlags);

      CompressedSize = builderSize - 16;

      return builderSize;
    }
예제 #6
0
        public async Task <int> BuildCompressedChunk(ByteArrayReader reader, BulkDataCompressionTypes compressionFlags)
        {
            BulkDataFlags = (uint)compressionFlags;

            int builderSize = sizeof(uint)
                              + sizeof(int) * 3;

            if ((compressionFlags & NothingToDo) > 0)
            {
                return(builderSize);
            }

            reader.Seek(0);

            UncompressedSize = reader.Remaining;

            Header = new DomainCompressedChunkHeader();

            builderSize += await Header.BuildCompressedChunkHeader(reader, BulkDataFlags);

            CompressedSize = builderSize - 16;

            return(builderSize);
        }