Mosa.Compiler.Pdb.PdbReader.PdbReader C# (CSharp) Method

PdbReader() public method

Initializes a new instance of the PdbReader class.
is null. must be readable and seekable.
public PdbReader ( Stream stream ) : System
stream Stream The stream.
return System
        public PdbReader(Stream stream)
        {
            if (stream == null)
                throw new ArgumentNullException(@"stream");
            if (stream.CanRead == false)
                throw new ArgumentException(@"Stream is not readable", @"stream");
            if (stream.CanSeek == false)
                throw new ArgumentException(@"Stream must be seekable.", @"stream");

            this.stream = stream;
            reader = new BinaryReader(stream);

            // Read the file header
            if (PdbFileHeader.Read(reader, out header) == false)
                throw new InvalidDataException(@"Not a Microsoft program database v7.0 file.");

            LoadRootStream();
        }