SBFunction.h revision a0d0a7cbd773ded4ced8d5065f993b6e0feb8dfe
1//===-- SBFunction.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_SBFunction_h_ 11#define LLDB_SBFunction_h_ 12 13#include "lldb/API/SBDefines.h" 14#include "lldb/API/SBAddress.h" 15#include "lldb/API/SBInstructionList.h" 16 17namespace lldb { 18 19#ifdef SWIG 20%feature("docstring", 21 "Represents a generic function, which can be inlined or not." 22 ) SBFunction; 23#endif 24class SBFunction 25{ 26#ifdef SWIG 27 %feature("autodoc", "1"); 28#endif 29public: 30 31 SBFunction (); 32 33 SBFunction (const lldb::SBFunction &rhs); 34 35#ifndef SWIG 36 const lldb::SBFunction & 37 operator = (const lldb::SBFunction &rhs); 38#endif 39 40 41 ~SBFunction (); 42 43 bool 44 IsValid () const; 45 46 const char * 47 GetName() const; 48 49 const char * 50 GetMangledName () const; 51 52 lldb::SBInstructionList 53 GetInstructions (lldb::SBTarget target); 54 55 SBAddress 56 GetStartAddress (); 57 58 SBAddress 59 GetEndAddress (); 60 61 uint32_t 62 GetPrologueByteSize (); 63 64#ifndef SWIG 65 bool 66 operator == (const lldb::SBFunction &rhs) const; 67 68 bool 69 operator != (const lldb::SBFunction &rhs) const; 70#endif 71 72 bool 73 GetDescription (lldb::SBStream &description); 74 75protected: 76 77#ifndef SWIG 78 79 lldb_private::Function * 80 get (); 81 82 void 83 reset (lldb_private::Function *lldb_object_ptr); 84 85#endif 86 87private: 88 friend class SBFrame; 89 friend class SBSymbolContext; 90 91 SBFunction (lldb_private::Function *lldb_object_ptr); 92 93 94 lldb_private::Function *m_opaque_ptr; 95}; 96 97 98} // namespace lldb 99 100#endif // LLDB_SBFunction_h_ 101