Dyninst::SymtabAPI::Module Class Reference

#include <Module.h>

Inheritance diagram for Dyninst::SymtabAPI::Module:
Dyninst::SymtabAPI::LookupInterface Dyninst::Serializable

Public Member Functions

SYMTAB_EXPORT Module ()
SYMTAB_EXPORT Module (supportedLanguages lang, Offset adr, std::string fullNm, Symtab *img)
SYMTAB_EXPORT Module (const Module &mod)
SYMTAB_EXPORT bool operator== (Module &mod)
SYMTAB_EXPORT Serializableserialize_impl (SerializerBase *sb, const char *tag="Module") THROW_SPEC(SerializerError)
SYMTAB_EXPORT const std::string & fileName () const
SYMTAB_EXPORT const std::string & fullName () const
SYMTAB_EXPORT bool setName (std::string newName)
SYMTAB_EXPORT supportedLanguages language () const
SYMTAB_EXPORT void setLanguage (supportedLanguages lang)
SYMTAB_EXPORT Offset addr () const
SYMTAB_EXPORT Symtabexec () const
SYMTAB_EXPORT bool isShared () const
SYMTAB_EXPORT ~Module ()
virtual SYMTAB_EXPORT bool findSymbol (std::vector< Symbol * > &ret, const std::string &name, Symbol::SymbolType sType=Symbol::ST_UNKNOWN, NameType nameType=anyName, bool isRegex=false, bool checkCase=false, bool includeUndefined=false)
virtual SYMTAB_EXPORT bool getAllSymbolsByType (std::vector< Symbol * > &ret, Symbol::SymbolType sType)
virtual SYMTAB_EXPORT bool getAllSymbols (std::vector< Symbol * > &ret)
SYMTAB_EXPORT bool getAllFunctions (std::vector< Function * > &ret)
SYMTAB_EXPORT bool findFunctionByEntryOffset (Function *&ret, const Offset offset)
SYMTAB_EXPORT bool findFunctionsByName (std::vector< Function * > &ret, const std::string &name, NameType nameType=anyName, bool isRegex=false, bool checkCase=true)
SYMTAB_EXPORT bool findVariableByOffset (Variable *&ret, const Offset offset)
SYMTAB_EXPORT bool findVariablesByName (std::vector< Variable * > &ret, const std::string &name, NameType nameType=anyName, bool isRegex=false, bool checkCase=true)
SYMTAB_EXPORT bool getAllVariables (std::vector< Variable * > &ret)
virtual SYMTAB_EXPORT bool findType (Type *&type, std::string name)
virtual SYMTAB_EXPORT bool findVariableType (Type *&type, std::string name)
SYMTAB_EXPORT std::vector
< Type * > * 
getAllTypes ()
SYMTAB_EXPORT std::vector
< std::pair< std::string, Type * > > * 
getAllGlobalVars ()
SYMTAB_EXPORT typeCollectiongetModuleTypes ()
SYMTAB_EXPORT bool findLocalVariable (std::vector< localVar * > &vars, std::string name)
SYMTAB_EXPORT bool getAddressRanges (std::vector< std::pair< Offset, Offset > > &ranges, std::string lineSource, unsigned int LineNo)
SYMTAB_EXPORT bool getSourceLines (std::vector< Statement * > &lines, Offset addressInRange)
SYMTAB_EXPORT bool getSourceLines (std::vector< LineNoTuple > &lines, Offset addressInRange)
SYMTAB_EXPORT bool getStatements (std::vector< Statement * > &statements)
SYMTAB_EXPORT LineInformationgetLineInformation ()
SYMTAB_EXPORT bool hasLineInformation ()
SYMTAB_EXPORT bool setDefaultNamespacePrefix (std::string str)
SYMTAB_EXPORT typeCollectiongetModuleTypesPrivate ()

Private Member Functions

bool setLineInfo (Dyninst::SymtabAPI::LineInformation *lineInfo)

Private Attributes

std::string fileName_
std::string fullName_
supportedLanguages language_
Offset addr_
Symtabexec_

Friends

class Symtab

Detailed Description

Definition at line 105 of file Module.h.


Constructor & Destructor Documentation

Module::Module (  ) 

Definition at line 400 of file Module.C.

Module::Module ( supportedLanguages  lang,
Offset  adr,
std::string  fullNm,
Symtab img 
)

Definition at line 390 of file Module.C.

References extract_pathname_tail(), and fileName_.

Module::Module ( const Module mod  ) 

Definition at line 409 of file Module.C.

Module::~Module (  ) 

Definition at line 422 of file Module.C.

References FILE__, fprintf, ModuleLineInfoAnno, and ModuleTypeInfoAnno.


Member Function Documentation

Offset Module::addr (  )  const

Definition at line 558 of file Module.C.

References addr_.

Referenced by Dyninst::SymtabAPI::Symtab::findModuleByOffset().

Symtab * Module::exec (  )  const
const std::string & Module::fileName (  )  const
SYMTAB_EXPORT bool Dyninst::SymtabAPI::Module::findFunctionByEntryOffset ( Function *&  ret,
const Offset  offset 
)
SYMTAB_EXPORT bool Dyninst::SymtabAPI::Module::findFunctionsByName ( std::vector< Function * > &  ret,
const std::string &  name,
NameType  nameType = anyName,
bool  isRegex = false,
bool  checkCase = true 
)
bool Module::findLocalVariable ( std::vector< localVar * > &  vars,
std::string  name 
)

Definition at line 368 of file Module.C.

References exec_, and Dyninst::SymtabAPI::Symtab::getAllFunctions().

bool Module::findSymbol ( std::vector< Symbol * > &  ret,
const std::string &  name,
Symbol::SymbolType  sType = Symbol::ST_UNKNOWN,
NameType  nameType = anyName,
bool  isRegex = false,
bool  checkCase = false,
bool  includeUndefined = false 
) [virtual]

Implements Dyninst::SymtabAPI::LookupInterface.

Definition at line 53 of file Module.C.

References exec().

bool Module::findType ( Type *&  type,
std::string  name 
) [virtual]
SYMTAB_EXPORT bool Dyninst::SymtabAPI::Module::findVariableByOffset ( Variable *&  ret,
const Offset  offset 
)
bool Module::findVariablesByName ( std::vector< Variable * > &  ret,
const std::string &  name,
NameType  nameType = anyName,
bool  isRegex = false,
bool  checkCase = true 
)

Definition at line 568 of file Module.C.

References exec().

Referenced by Dyninst::SymtabAPI::parseStabString().

bool Module::findVariableType ( Type *&  type,
std::string  name 
) [virtual]
const std::string & Module::fullName (  )  const
SYMTAB_EXPORT bool Dyninst::SymtabAPI::Module::getAddressRanges ( std::vector< std::pair< Offset, Offset > > &  ranges,
std::string  lineSource,
unsigned int  LineNo 
)
bool Module::getAllFunctions ( std::vector< Function * > &  ret  ) 

Definition at line 485 of file Module.C.

References exec(), and Dyninst::SymtabAPI::Symtab::getAllFunctions().

vector< pair< string, Type * > > * Module::getAllGlobalVars (  ) 
bool Module::getAllSymbols ( std::vector< Symbol * > &  ret  )  [virtual]

Definition at line 79 of file Module.C.

References exec().

bool Module::getAllSymbolsByType ( std::vector< Symbol * > &  ret,
Symbol::SymbolType  sType 
) [virtual]

Implements Dyninst::SymtabAPI::LookupInterface.

Definition at line 462 of file Module.C.

References exec(), Dyninst::SymtabAPI::No_Such_Symbol, and serr.

vector< Type * > * Module::getAllTypes (  ) 
SYMTAB_EXPORT bool Dyninst::SymtabAPI::Module::getAllVariables ( std::vector< Variable * > &  ret  ) 
LineInformation * Module::getLineInformation (  ) 
typeCollection * Module::getModuleTypes (  ) 

Definition at line 256 of file Module.C.

References exec_, getModuleTypesPrivate(), and Dyninst::SymtabAPI::Symtab::parseTypesNow().

Referenced by findType(), and findVariableType().

typeCollection * Module::getModuleTypesPrivate (  ) 

Definition at line 262 of file Module.C.

References ModuleTypeInfoAnno.

Referenced by getModuleTypes().

bool Module::getSourceLines ( std::vector< LineNoTuple > &  lines,
Offset  addressInRange 
)
bool Module::getSourceLines ( std::vector< Statement * > &  lines,
Offset  addressInRange 
)
bool Module::getStatements ( std::vector< Statement * > &  statements  ) 
bool Module::hasLineInformation (  ) 
bool Module::isShared (  )  const
supportedLanguages Module::language (  )  const
bool Module::operator== ( Module mod  ) 
Serializable * Module::serialize_impl ( SerializerBase sb,
const char *  tag = "Module" 
)

Definition at line 641 of file Module.C.

SYMTAB_EXPORT bool Dyninst::SymtabAPI::Module::setDefaultNamespacePrefix ( std::string  str  ) 
void Module::setLanguage ( supportedLanguages  lang  ) 

Definition at line 553 of file Module.C.

References language_.

Referenced by Dyninst::SymtabAPI::Symtab::setModuleLanguages().

bool Module::setLineInfo ( Dyninst::SymtabAPI::LineInformation lineInfo  )  [private]

Definition at line 300 of file Module.C.

References FILE__, fprintf, and ModuleLineInfoAnno.

Referenced by Dyninst::SymtabAPI::Symtab::parseLineInformation().

bool Module::setName ( std::string  newName  ) 

Definition at line 546 of file Module.C.

References extract_pathname_tail(), fileName_, and fullName_.


Friends And Related Function Documentation

friend class Symtab [friend]

Definition at line 109 of file Module.h.


Field Documentation

Definition at line 200 of file Module.h.

Referenced by addr(), and operator==().

Definition at line 197 of file Module.h.

Referenced by fileName(), Module(), operator==(), and setName().

Definition at line 198 of file Module.h.

Referenced by fullName(), operator==(), and setName().

Definition at line 199 of file Module.h.

Referenced by language(), operator==(), and setLanguage().


The documentation for this class was generated from the following files:
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 12 Jul 2013 for SymtabAPI by  doxygen 1.6.1