LLDB mainline
|
#include <SBPlatform.h>
Public Member Functions | |
SBPlatform () | |
SBPlatform (const char *platform_name) | |
SBPlatform (const SBPlatform &rhs) | |
SBPlatform & | operator= (const SBPlatform &rhs) |
~SBPlatform () | |
operator bool () const | |
bool | IsValid () const |
void | Clear () |
const char * | GetWorkingDirectory () |
bool | SetWorkingDirectory (const char *path) |
const char * | GetName () |
SBError | ConnectRemote (SBPlatformConnectOptions &connect_options) |
void | DisconnectRemote () |
bool | IsConnected () |
const char * | GetTriple () |
const char * | GetHostname () |
const char * | GetOSBuild () |
const char * | GetOSDescription () |
uint32_t | GetOSMajorVersion () |
uint32_t | GetOSMinorVersion () |
uint32_t | GetOSUpdateVersion () |
void | SetSDKRoot (const char *sysroot) |
SBError | Put (SBFileSpec &src, SBFileSpec &dst) |
SBError | Get (SBFileSpec &src, SBFileSpec &dst) |
SBError | Install (SBFileSpec &src, SBFileSpec &dst) |
SBError | Run (SBPlatformShellCommand &shell_command) |
SBError | Launch (SBLaunchInfo &launch_info) |
SBError | Kill (const lldb::pid_t pid) |
SBError | MakeDirectory (const char *path, uint32_t file_permissions=eFilePermissionsDirectoryDefault) |
uint32_t | GetFilePermissions (const char *path) |
SBError | SetFilePermissions (const char *path, uint32_t file_permissions) |
SBUnixSignals | GetUnixSignals () const |
SBEnvironment | GetEnvironment () |
Return the environment variables of the remote platform connection process. | |
Static Public Member Functions | |
static SBPlatform | GetHostPlatform () |
Protected Member Functions | |
lldb::PlatformSP | GetSP () const |
void | SetSP (const lldb::PlatformSP &platform_sp) |
SBError | ExecuteConnected (const std::function< lldb_private::Status(const lldb::PlatformSP &)> &func) |
Protected Attributes | |
lldb::PlatformSP | m_opaque_sp |
Friends | |
class | SBDebugger |
class | SBTarget |
Definition at line 93 of file SBPlatform.h.
SBPlatform::SBPlatform | ( | ) |
Definition at line 290 of file SBPlatform.cpp.
References LLDB_INSTRUMENT_VA.
SBPlatform::SBPlatform | ( | const char * | platform_name | ) |
Definition at line 292 of file SBPlatform.cpp.
References lldb_private::Platform::Create(), LLDB_INSTRUMENT_VA, and m_opaque_sp.
SBPlatform::SBPlatform | ( | const SBPlatform & | rhs | ) |
Definition at line 298 of file SBPlatform.cpp.
References LLDB_INSTRUMENT_VA, and m_opaque_sp.
|
default |
void SBPlatform::Clear | ( | ) |
Definition at line 331 of file SBPlatform.cpp.
References LLDB_INSTRUMENT_VA, and m_opaque_sp.
SBError SBPlatform::ConnectRemote | ( | SBPlatformConnectOptions & | connect_options | ) |
Definition at line 375 of file SBPlatform.cpp.
References lldb_private::Args::AppendArgument(), GetSP(), lldb::SBPlatformConnectOptions::GetURL(), LLDB_INSTRUMENT_VA, lldb::SBError::ref(), and lldb::SBError::SetErrorString().
void SBPlatform::DisconnectRemote | ( | ) |
Definition at line 390 of file SBPlatform.cpp.
References GetSP(), and LLDB_INSTRUMENT_VA.
|
protected |
Definition at line 583 of file SBPlatform.cpp.
References GetSP(), lldb::SBError::ref(), and lldb::SBError::SetErrorString().
Referenced by Install(), Kill(), Launch(), Put(), and Run().
SBError SBPlatform::Get | ( | SBFileSpec & | src, |
SBFileSpec & | dst | ||
) |
Definition at line 494 of file SBPlatform.cpp.
References GetSP(), LLDB_INSTRUMENT_VA, lldb::SBError::ref(), lldb::SBFileSpec::ref(), and lldb::SBError::SetErrorString().
SBEnvironment SBPlatform::GetEnvironment | ( | ) |
Return the environment variables of the remote platform connection process.
Definition at line 648 of file SBPlatform.cpp.
References GetSP(), and LLDB_INSTRUMENT_VA.
uint32_t SBPlatform::GetFilePermissions | ( | const char * | path | ) |
Definition at line 612 of file SBPlatform.cpp.
References GetSP(), and LLDB_INSTRUMENT_VA.
const char * SBPlatform::GetHostname | ( | ) |
Definition at line 452 of file SBPlatform.cpp.
References lldb_private::ConstString::GetCString(), GetSP(), and LLDB_INSTRUMENT_VA.
|
static |
Definition at line 313 of file SBPlatform.cpp.
References lldb_private::Platform::GetHostPlatform(), LLDB_INSTRUMENT, and m_opaque_sp.
const char * SBPlatform::GetName | ( | ) |
Definition at line 337 of file SBPlatform.cpp.
References lldb_private::ConstString::AsCString(), GetSP(), and LLDB_INSTRUMENT_VA.
Referenced by lldb::SBDebugger::GetSelectedPlatform(), and lldb::SBDebugger::SetSelectedPlatform().
const char * SBPlatform::GetOSBuild | ( | ) |
Definition at line 422 of file SBPlatform.cpp.
References lldb_private::ConstString::GetCString(), GetSP(), and LLDB_INSTRUMENT_VA.
const char * SBPlatform::GetOSDescription | ( | ) |
Definition at line 437 of file SBPlatform.cpp.
References lldb_private::ConstString::GetCString(), GetSP(), and LLDB_INSTRUMENT_VA.
uint32_t SBPlatform::GetOSMajorVersion | ( | ) |
Definition at line 461 of file SBPlatform.cpp.
References GetSP(), LLDB_INSTRUMENT_VA, and UINT32_MAX.
uint32_t SBPlatform::GetOSMinorVersion | ( | ) |
Definition at line 470 of file SBPlatform.cpp.
References GetSP(), LLDB_INSTRUMENT_VA, and UINT32_MAX.
uint32_t SBPlatform::GetOSUpdateVersion | ( | ) |
Definition at line 479 of file SBPlatform.cpp.
References GetSP(), LLDB_INSTRUMENT_VA, and UINT32_MAX.
|
protected |
Definition at line 346 of file SBPlatform.cpp.
References m_opaque_sp.
Referenced by ConnectRemote(), DisconnectRemote(), ExecuteConnected(), Get(), GetEnvironment(), GetFilePermissions(), GetHostname(), GetName(), GetOSBuild(), GetOSDescription(), GetOSMajorVersion(), GetOSMinorVersion(), GetOSUpdateVersion(), lldb::SBDebugger::GetSelectedPlatform(), GetTriple(), GetUnixSignals(), GetWorkingDirectory(), IsConnected(), MakeDirectory(), SetFilePermissions(), SetSDKRoot(), lldb::SBDebugger::SetSelectedPlatform(), and SetWorkingDirectory().
const char * SBPlatform::GetTriple | ( | ) |
Definition at line 407 of file SBPlatform.cpp.
References lldb_private::ConstString::GetCString(), GetSP(), lldb_private::ArchSpec::GetTriple(), lldb_private::ArchSpec::IsValid(), and LLDB_INSTRUMENT_VA.
SBUnixSignals SBPlatform::GetUnixSignals | ( | ) | const |
Definition at line 639 of file SBPlatform.cpp.
References GetSP(), and LLDB_INSTRUMENT_VA.
const char * SBPlatform::GetWorkingDirectory | ( | ) |
Definition at line 352 of file SBPlatform.cpp.
References GetSP(), and LLDB_INSTRUMENT_VA.
SBError SBPlatform::Install | ( | SBFileSpec & | src, |
SBFileSpec & | dst | ||
) |
Definition at line 529 of file SBPlatform.cpp.
References error(), ExecuteConnected(), lldb::SBFileSpec::Exists(), lldb_private::FileSpec::GetPath(), LLDB_INSTRUMENT_VA, and lldb::SBFileSpec::ref().
bool SBPlatform::IsConnected | ( | ) |
Definition at line 398 of file SBPlatform.cpp.
References GetSP(), and LLDB_INSTRUMENT_VA.
bool SBPlatform::IsValid | ( | ) | const |
Definition at line 321 of file SBPlatform.cpp.
References LLDB_INSTRUMENT_VA.
SBError SBPlatform::Kill | ( | const lldb::pid_t | pid | ) |
Definition at line 576 of file SBPlatform.cpp.
References ExecuteConnected(), and LLDB_INSTRUMENT_VA.
SBError SBPlatform::Launch | ( | SBLaunchInfo & | launch_info | ) |
Definition at line 566 of file SBPlatform.cpp.
References error(), ExecuteConnected(), LLDB_INSTRUMENT_VA, lldb::SBLaunchInfo::ref(), and lldb::SBLaunchInfo::set_ref().
SBError SBPlatform::MakeDirectory | ( | const char * | path, |
uint32_t | file_permissions = eFilePermissionsDirectoryDefault |
||
) |
Definition at line 598 of file SBPlatform.cpp.
References GetSP(), LLDB_INSTRUMENT_VA, lldb::SBError::ref(), and lldb::SBError::SetErrorString().
|
explicit |
Definition at line 325 of file SBPlatform.cpp.
References LLDB_INSTRUMENT_VA.
SBPlatform & SBPlatform::operator= | ( | const SBPlatform & | rhs | ) |
Definition at line 304 of file SBPlatform.cpp.
References LLDB_INSTRUMENT_VA, and m_opaque_sp.
SBError SBPlatform::Put | ( | SBFileSpec & | src, |
SBFileSpec & | dst | ||
) |
Definition at line 507 of file SBPlatform.cpp.
References error(), ExecuteConnected(), lldb::SBFileSpec::Exists(), lldb_private::FileSpec::GetPath(), LLDB_INSTRUMENT_VA, and lldb::SBFileSpec::ref().
SBError SBPlatform::Run | ( | SBPlatformShellCommand & | shell_command | ) |
Definition at line 542 of file SBPlatform.cpp.
References ExecuteConnected(), lldb::SBPlatformShellCommand::GetCommand(), lldb::SBPlatformShellCommand::GetWorkingDirectory(), LLDB_INSTRUMENT_VA, lldb::SBPlatformShellCommand::m_opaque_ptr, PlatformShellCommand::m_output, PlatformShellCommand::m_shell, PlatformShellCommand::m_signo, PlatformShellCommand::m_status, and PlatformShellCommand::m_timeout.
Definition at line 624 of file SBPlatform.cpp.
References GetSP(), LLDB_INSTRUMENT_VA, lldb::SBError::ref(), and lldb::SBError::SetErrorString().
void SBPlatform::SetSDKRoot | ( | const char * | sysroot | ) |
Definition at line 488 of file SBPlatform.cpp.
References GetSP(), and LLDB_INSTRUMENT_VA.
|
protected |
Definition at line 348 of file SBPlatform.cpp.
References m_opaque_sp.
Referenced by lldb::SBDebugger::GetPlatformAtIndex(), and lldb::SBDebugger::GetSelectedPlatform().
bool SBPlatform::SetWorkingDirectory | ( | const char * | path | ) |
Definition at line 361 of file SBPlatform.cpp.
References GetSP(), and LLDB_INSTRUMENT_VA.
|
friend |
Definition at line 173 of file SBPlatform.h.
|
friend |
Definition at line 174 of file SBPlatform.h.
|
protected |
Definition at line 184 of file SBPlatform.h.
Referenced by Clear(), GetHostPlatform(), lldb::SBTarget::GetPlatform(), GetSP(), operator=(), SBPlatform(), and SetSP().