Ejemplo n.º 1
0
        /// <summary>
        /// Parses a sub stream.
        /// </summary>
        /// <returns></returns>
        SType ParseSubStream()
        {
            SType subStream = new SStreamType(StreamType.SubStream);
            var   length    = m_reader.ReadLength();

            if (s_dumpStructure)
            {
                var subReader = new CachedFileReader(m_reader, length);
                var subParser = new CachedFileParser(subReader);
                subParser.Parse();
                subStream.AddMember(subParser.m_stream.Clone());
            }

            if (s_cachedObject)
            {
                return(new SStringType(m_reader.ReadString(length)));
            }

            m_reader.Seek(length);

            return(subStream);
        }