16498aff2SJonas Devlieghere //===-- SWIG Interface for SBModule -----------------------------*- C++ -*-===// 26498aff2SJonas Devlieghere // 36498aff2SJonas Devlieghere // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 46498aff2SJonas Devlieghere // See https://llvm.org/LICENSE.txt for license information. 56498aff2SJonas Devlieghere // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 66498aff2SJonas Devlieghere // 76498aff2SJonas Devlieghere //===----------------------------------------------------------------------===// 86498aff2SJonas Devlieghere 96498aff2SJonas Devlieghere namespace lldb { 106498aff2SJonas Devlieghere 116498aff2SJonas Devlieghere class SBModuleSpec 126498aff2SJonas Devlieghere { 136498aff2SJonas Devlieghere public: 146498aff2SJonas Devlieghere 156498aff2SJonas Devlieghere SBModuleSpec (); 166498aff2SJonas Devlieghere 176498aff2SJonas Devlieghere SBModuleSpec (const lldb::SBModuleSpec &rhs); 186498aff2SJonas Devlieghere 196498aff2SJonas Devlieghere ~SBModuleSpec (); 206498aff2SJonas Devlieghere 216498aff2SJonas Devlieghere bool 226498aff2SJonas Devlieghere IsValid () const; 236498aff2SJonas Devlieghere 246498aff2SJonas Devlieghere explicit operator bool() const; 256498aff2SJonas Devlieghere 266498aff2SJonas Devlieghere void 276498aff2SJonas Devlieghere Clear(); 286498aff2SJonas Devlieghere 296498aff2SJonas Devlieghere %feature("docstring", " 306498aff2SJonas Devlieghere Get const accessor for the module file. 316498aff2SJonas Devlieghere 326498aff2SJonas Devlieghere This function returns the file for the module on the host system 336498aff2SJonas Devlieghere that is running LLDB. This can differ from the path on the 346498aff2SJonas Devlieghere platform since we might be doing remote debugging. 356498aff2SJonas Devlieghere 366498aff2SJonas Devlieghere @return 376498aff2SJonas Devlieghere A const reference to the file specification object.") GetFileSpec; 386498aff2SJonas Devlieghere lldb::SBFileSpec 396498aff2SJonas Devlieghere GetFileSpec (); 406498aff2SJonas Devlieghere 416498aff2SJonas Devlieghere void 426498aff2SJonas Devlieghere SetFileSpec (const lldb::SBFileSpec &fspec); 436498aff2SJonas Devlieghere 446498aff2SJonas Devlieghere %feature("docstring", " 456498aff2SJonas Devlieghere Get accessor for the module platform file. 466498aff2SJonas Devlieghere 476498aff2SJonas Devlieghere Platform file refers to the path of the module as it is known on 486498aff2SJonas Devlieghere the remote system on which it is being debugged. For local 496498aff2SJonas Devlieghere debugging this is always the same as Module::GetFileSpec(). But 506498aff2SJonas Devlieghere remote debugging might mention a file '/usr/lib/liba.dylib' 516498aff2SJonas Devlieghere which might be locally downloaded and cached. In this case the 526498aff2SJonas Devlieghere platform file could be something like: 536498aff2SJonas Devlieghere '/tmp/lldb/platform-cache/remote.host.computer/usr/lib/liba.dylib' 546498aff2SJonas Devlieghere The file could also be cached in a local developer kit directory. 556498aff2SJonas Devlieghere 566498aff2SJonas Devlieghere @return 576498aff2SJonas Devlieghere A const reference to the file specification object.") GetPlatformFileSpec; 586498aff2SJonas Devlieghere lldb::SBFileSpec 596498aff2SJonas Devlieghere GetPlatformFileSpec (); 606498aff2SJonas Devlieghere 616498aff2SJonas Devlieghere void 626498aff2SJonas Devlieghere SetPlatformFileSpec (const lldb::SBFileSpec &fspec); 636498aff2SJonas Devlieghere 646498aff2SJonas Devlieghere lldb::SBFileSpec 656498aff2SJonas Devlieghere GetSymbolFileSpec (); 666498aff2SJonas Devlieghere 676498aff2SJonas Devlieghere void 686498aff2SJonas Devlieghere SetSymbolFileSpec (const lldb::SBFileSpec &fspec); 696498aff2SJonas Devlieghere 706498aff2SJonas Devlieghere const char * 716498aff2SJonas Devlieghere GetObjectName (); 726498aff2SJonas Devlieghere 736498aff2SJonas Devlieghere void 746498aff2SJonas Devlieghere SetObjectName (const char *name); 756498aff2SJonas Devlieghere 766498aff2SJonas Devlieghere const char * 776498aff2SJonas Devlieghere GetTriple (); 786498aff2SJonas Devlieghere 796498aff2SJonas Devlieghere void 806498aff2SJonas Devlieghere SetTriple (const char *triple); 816498aff2SJonas Devlieghere 826498aff2SJonas Devlieghere const uint8_t * 836498aff2SJonas Devlieghere GetUUIDBytes (); 846498aff2SJonas Devlieghere 856498aff2SJonas Devlieghere size_t 866498aff2SJonas Devlieghere GetUUIDLength (); 876498aff2SJonas Devlieghere 886498aff2SJonas Devlieghere bool 896498aff2SJonas Devlieghere SetUUIDBytes (const uint8_t *uuid, size_t uuid_len); 906498aff2SJonas Devlieghere 916498aff2SJonas Devlieghere bool 926498aff2SJonas Devlieghere GetDescription (lldb::SBStream &description); 936498aff2SJonas Devlieghere 946498aff2SJonas Devlieghere STRING_EXTENSION(SBModuleSpec) 956498aff2SJonas Devlieghere }; 966498aff2SJonas Devlieghere 976498aff2SJonas Devlieghere 98*acdc7456SRaphael Isemann %feature("docstring", 99*acdc7456SRaphael Isemann "Represents a list of :py:class:`SBModuleSpec`." 100*acdc7456SRaphael Isemann ) SBModuleSpecList; 1016498aff2SJonas Devlieghere class SBModuleSpecList 1026498aff2SJonas Devlieghere { 1036498aff2SJonas Devlieghere public: 1046498aff2SJonas Devlieghere SBModuleSpecList(); 1056498aff2SJonas Devlieghere 1066498aff2SJonas Devlieghere SBModuleSpecList (const SBModuleSpecList &rhs); 1076498aff2SJonas Devlieghere 1086498aff2SJonas Devlieghere ~SBModuleSpecList(); 1096498aff2SJonas Devlieghere 1106498aff2SJonas Devlieghere static SBModuleSpecList 1116498aff2SJonas Devlieghere GetModuleSpecifications (const char *path); 1126498aff2SJonas Devlieghere 1136498aff2SJonas Devlieghere void 1146498aff2SJonas Devlieghere Append (const lldb::SBModuleSpec &spec); 1156498aff2SJonas Devlieghere 1166498aff2SJonas Devlieghere void 1176498aff2SJonas Devlieghere Append (const lldb::SBModuleSpecList &spec_list); 1186498aff2SJonas Devlieghere 1196498aff2SJonas Devlieghere lldb::SBModuleSpec 1206498aff2SJonas Devlieghere FindFirstMatchingSpec (const lldb::SBModuleSpec &match_spec); 1216498aff2SJonas Devlieghere 1226498aff2SJonas Devlieghere lldb::SBModuleSpecList 1236498aff2SJonas Devlieghere FindMatchingSpecs (const lldb::SBModuleSpec &match_spec); 1246498aff2SJonas Devlieghere 1256498aff2SJonas Devlieghere size_t 1266498aff2SJonas Devlieghere GetSize(); 1276498aff2SJonas Devlieghere 1286498aff2SJonas Devlieghere lldb::SBModuleSpec 1296498aff2SJonas Devlieghere GetSpecAtIndex (size_t i); 1306498aff2SJonas Devlieghere 1316498aff2SJonas Devlieghere bool 1326498aff2SJonas Devlieghere GetDescription (lldb::SBStream &description); 1336498aff2SJonas Devlieghere 1346498aff2SJonas Devlieghere STRING_EXTENSION(SBModuleSpecList) 1356498aff2SJonas Devlieghere }; 1366498aff2SJonas Devlieghere 1376498aff2SJonas Devlieghere } // namespace lldb 138