SBModule.h revision 4ed315fdc503cfdc18e89b1eb43bf87e07fd1673
1//===-- SBModule.h ----------------------------------------------*- C++ -*-===// 2// 3// The LLVM Compiler Infrastructure 4// 5// This file is distributed under the University of Illinois Open Source 6// License. See LICENSE.TXT for details. 7// 8//===----------------------------------------------------------------------===// 9 10#ifndef LLDB_SBModule_h_ 11#define LLDB_SBModule_h_ 12 13#include "lldb/API/SBDefines.h" 14#include "lldb/API/SBSymbolContext.h" 15 16namespace lldb { 17 18class SBModule 19{ 20public: 21 22 SBModule (); 23 24 SBModule (const SBModule &rhs); 25 26#ifndef SWIG 27 const SBModule & 28 operator = (const SBModule &rhs); 29#endif 30 31 ~SBModule (); 32 33 bool 34 IsValid () const; 35 36 lldb::SBFileSpec 37 GetFileSpec () const; 38 39 lldb::SBFileSpec 40 GetPlatformFileSpec () const; 41 42 bool 43 SetPlatformFileSpec (const lldb::SBFileSpec &platform_file); 44 45 const uint8_t * 46 GetUUIDBytes () const; 47 48 const char * 49 GetUUIDString () const; 50 51#ifndef SWIG 52 bool 53 operator == (const lldb::SBModule &rhs) const; 54 55 bool 56 operator != (const lldb::SBModule &rhs) const; 57 58#endif 59 60 bool 61 ResolveFileAddress (lldb::addr_t vm_addr, 62 lldb::SBAddress& addr); 63 64 lldb::SBSymbolContext 65 ResolveSymbolContextForAddress (const lldb::SBAddress& addr, 66 uint32_t resolve_scope); 67 68 bool 69 GetDescription (lldb::SBStream &description); 70 71 size_t 72 GetNumSymbols (); 73 74 lldb::SBSymbol 75 GetSymbolAtIndex (size_t idx); 76 77 uint32_t 78 FindFunctions (const char *name, 79 uint32_t name_type_mask, // Logical OR one or more FunctionNameType enum bits 80 bool append, 81 lldb::SBSymbolContextList& sc_list); 82 83private: 84 friend class SBAddress; 85 friend class SBFrame; 86 friend class SBSymbolContext; 87 friend class SBTarget; 88 89 explicit SBModule (const lldb::ModuleSP& module_sp); 90 91 void 92 SetModule (const lldb::ModuleSP& module_sp); 93#ifndef SWIG 94 95 lldb::ModuleSP & 96 operator *(); 97 98 99 lldb_private::Module * 100 operator ->(); 101 102 const lldb_private::Module * 103 operator ->() const; 104 105 lldb_private::Module * 106 get(); 107 108 const lldb_private::Module * 109 get() const; 110 111#endif 112 113 lldb::ModuleSP m_opaque_sp; 114}; 115 116 117} // namespace lldb 118 119#endif // LLDB_SBModule_h_ 120