예제 #1
0
        public Stream Read( Stream stream, PbpEntryType entryType )
        {
            if( _entries.ContainsKey( entryType ) == false )
                return null;
            PbpEntry entry = _entries[ entryType ];

            stream.Seek( entry.Offset, SeekOrigin.Begin );
            byte[] buffer = new byte[ entry.Length ];
            stream.Read( buffer, 0, ( int )entry.Length );

            return new MemoryStream( buffer, 0, buffer.Length, false, false );
        }
예제 #2
0
        public Stream Read(Stream stream, PbpEntryType entryType)
        {
            if (_entries.ContainsKey(entryType) == false)
            {
                return(null);
            }
            PbpEntry entry = _entries[entryType];

            stream.Seek(entry.Offset, SeekOrigin.Begin);
            byte[] buffer = new byte[entry.Length];
            stream.Read(buffer, 0, ( int )entry.Length);

            return(new MemoryStream(buffer, 0, buffer.Length, false, false));
        }
예제 #3
0
 public bool ContainsEntry( PbpEntryType entryType )
 {
     return _entries.ContainsKey( entryType );
 }
예제 #4
0
 public bool ContainsEntry(PbpEntryType entryType)
 {
     return(_entries.ContainsKey(entryType));
 }