Struct pdb::PDB
[−]
[src]
pub struct PDB<'s, S> { /* fields omitted */ }
PDB
provides access to the data within a PDB file.
A PDB file is internally a Multi-Stream File (MSF), composed of multiple independent
(and usually discontiguous) data streams on-disk. PDB
provides lazy access to these data
structures, which means the PDB
accessor methods usually cause disk accesses.
Methods
impl<'s, S: Source<'s> + 's> PDB<'s, S>
[src]
fn open(source: S) -> Result<PDB<'s, S>>
Create a new PDB
for a Source
.
open()
accesses enough of the source file to find the MSF stream table. This usually
involves reading the header, a block near the end of the file, and finally the stream table
itself. It does not access or validate any of the contents of the rest of the PDB.
Errors
Error::UnimplementedFeature
if the PDB file predates ~2002Error::UnrecognizedFileFormat
if theSource
does not appear to be a PDB fileError::IoError
if returned by theSource
Error::PageReferenceOutOfRange
,Error::InvalidPageSize
if the PDB file seems corrupt
fn pdb_information(&mut self) -> Result<PDBInformation>
fn type_information(&mut self) -> Result<TypeInformation<'s>>
Retrieve the TypeInformation
for this PDB.
The TypeInformation
object owns a SourceView
for the type information ("TPI") stream.
This is usually the single largest stream of the PDB file.
Errors
Error::StreamNotFound
if the PDB somehow does not contain the type information streamError::IoError
if returned by theSource
Error::PageReferenceOutOfRange
if the PDB file seems corruptError::InvalidTypeInformationHeader
if the type information stream header was not understood
fn debug_information(&mut self) -> Result<DebugInformation<'s>>
Retrieve the DebugInformation
for this PDB.
The DebugInformation
object owns a SourceView
for the debug information ("DBI") stream.
Errors
Error::StreamNotFound
if the PDB somehow does not contain a symbol records streamError::IoError
if returned by theSource
Error::PageReferenceOutOfRange
if the PDB file seems corruptError::UnimplementedFeature
if the debug information header predates ~1995
fn global_symbols(&mut self) -> Result<SymbolTable<'s>>
Retrieve the global symbol table for this PDB.
The SymbolTable
object owns a SourceView
for the symbol records stream. This is usually
the second-largest stream of the PDB file.
The debug information stream indicates which stream is the symbol records stream, so
global_symbols()
accesses the debug information stream to read the header unless
debug_information()
was called first.
Errors
Error::StreamNotFound
if the PDB somehow does not contain a symbol records streamError::IoError
if returned by theSource
Error::PageReferenceOutOfRange
if the PDB file seems corrupt
If debug_information()
was not already called, global_symbols()
will additionally read
the debug information header, in which case it can also return:
Error::StreamNotFound
if the PDB somehow does not contain a debug information streamError::UnimplementedFeature
if the debug information header predates ~1995