1 //===-- SWIG Interface for SBPlatform ---------------------------*- C++ -*-===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
12 class SBPlatformConnectOptions
15 SBPlatformConnectOptions (const char *url);
17 SBPlatformConnectOptions (const SBPlatformConnectOptions &rhs);
19 ~SBPlatformConnectOptions ();
25 SetURL(const char *url);
31 EnableRsync (const char *options,
32 const char *remote_path_prefix,
33 bool omit_remote_hostname);
39 GetLocalCacheDirectory();
42 SetLocalCacheDirectory(const char *path);
45 class SBPlatformShellCommand
48 SBPlatformShellCommand (const char *shell_command);
50 SBPlatformShellCommand (const SBPlatformShellCommand &rhs);
52 ~SBPlatformShellCommand();
61 SetCommand(const char *shell_command);
64 GetWorkingDirectory ();
67 SetWorkingDirectory (const char *path);
73 SetTimeoutSeconds (uint32_t sec);
86 "A class that represents a platform that can represent the current host or a remote host debug platform.
88 The SBPlatform class represents the current host, or a remote host.
89 It can be connected to a remote platform in order to provide ways
90 to remotely launch and attach to processes, upload/download files,
91 create directories, run remote shell commands, find locally cached
92 versions of files from the remote system, and much more.
94 SBPlatform objects can be created and then used to connect to a remote
95 platform which allows the SBPlatform to be used to get a list of the
96 current processes on the remote host, attach to one of those processes,
97 install programs on the remote system, attach and launch processes,
100 Every SBTarget has a corresponding SBPlatform. The platform can be
101 specified upon target creation, or the currently selected platform
102 will attempt to be used when creating the target automatically as long
103 as the currently selected platform matches the target architecture
104 and executable type. If the architecture or executable type do not match,
105 a suitable platform will be found automatically."
114 SBPlatform (const char *);
121 explicit operator bool() const;
127 GetWorkingDirectory();
130 SetWorkingDirectory(const char *);
136 ConnectRemote (lldb::SBPlatformConnectOptions &connect_options);
157 GetOSMajorVersion ();
160 GetOSMinorVersion ();
163 GetOSUpdateVersion ();
166 Get (lldb::SBFileSpec &src, lldb::SBFileSpec &dst);
169 Put (lldb::SBFileSpec &src, lldb::SBFileSpec &dst);
172 Install (lldb::SBFileSpec &src, lldb::SBFileSpec &dst);
175 Run (lldb::SBPlatformShellCommand &shell_command);
178 Launch (lldb::SBLaunchInfo &launch_info);
181 Kill (const lldb::pid_t pid);
184 MakeDirectory (const char *path, uint32_t file_permissions = lldb::eFilePermissionsDirectoryDefault);
187 GetFilePermissions (const char *path);
190 SetFilePermissions (const char *path, uint32_t file_permissions);