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/SBAddress.h" 14 #include "lldb/API/SBDefines.h" 15 #include "lldb/API/SBInstructionList.h" 16 17 namespace lldb { 18 19 class LLDB_API SBFunction { 20 public: 21 SBFunction(); 22 23 SBFunction(const lldb::SBFunction &rhs); 24 25 const lldb::SBFunction &operator=(const lldb::SBFunction &rhs); 26 27 ~SBFunction(); 28 29 bool IsValid() const; 30 31 const char *GetName() const; 32 33 const char *GetDisplayName() const; 34 35 const char *GetMangledName() const; 36 37 lldb::SBInstructionList GetInstructions(lldb::SBTarget target); 38 39 lldb::SBInstructionList GetInstructions(lldb::SBTarget target, 40 const char *flavor); 41 42 lldb::SBAddress GetStartAddress(); 43 44 lldb::SBAddress GetEndAddress(); 45 46 const char *GetArgumentName(uint32_t arg_idx); 47 48 uint32_t GetPrologueByteSize(); 49 50 lldb::SBType GetType(); 51 52 lldb::SBBlock GetBlock(); 53 54 lldb::LanguageType GetLanguage(); 55 56 bool GetIsOptimized(); 57 58 bool operator==(const lldb::SBFunction &rhs) const; 59 60 bool operator!=(const lldb::SBFunction &rhs) const; 61 62 bool GetDescription(lldb::SBStream &description); 63 64 protected: 65 lldb_private::Function *get(); 66 67 void reset(lldb_private::Function *lldb_object_ptr); 68 69 private: 70 friend class SBAddress; 71 friend class SBFrame; 72 friend class SBSymbolContext; 73 74 SBFunction(lldb_private::Function *lldb_object_ptr); 75 76 lldb_private::Function *m_opaque_ptr; 77 }; 78 79 } // namespace lldb 80 81 #endif // LLDB_SBFunction_h_ 82