LLDB mainline
SBProcessInfo.h
Go to the documentation of this file.
1//===-- SBProcessInfo.h -----------------------------------------*- C++ -*-===//
2//
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
6//
7//===----------------------------------------------------------------------===//
8
9#ifndef LLDB_API_SBPROCESSINFO_H
10#define LLDB_API_SBPROCESSINFO_H
11
12#include "lldb/API/SBDefines.h"
13
14namespace lldb {
15
17public:
19 SBProcessInfo(const SBProcessInfo &rhs);
20
22
24
25 explicit operator bool() const;
26
27 bool IsValid() const;
28
29 const char *GetName();
30
32
34
35 uint32_t GetUserID();
36
37 uint32_t GetGroupID();
38
39 bool UserIDIsValid();
40
41 bool GroupIDIsValid();
42
43 uint32_t GetEffectiveUserID();
44
45 uint32_t GetEffectiveGroupID();
46
48
50
52
53 /// Return the target triple (arch-vendor-os) for the described process.
54 const char *GetTriple();
55
56 /// Returns the number of command line arguments for the described process.
57 uint32_t GetNumArguments() const;
58
59 /// Returns the command line argument at the given index, or `nullptr` if
60 /// the index is out of range or if the process info is invalid..
61 const char *GetArgumentAtIndex(uint32_t idx) const;
62
63private:
64 friend class SBProcess;
65 friend class SBProcessInfoList;
66
68
69 void SetProcessInfo(const lldb_private::ProcessInstanceInfo &proc_info_ref);
70
71 std::unique_ptr<lldb_private::ProcessInstanceInfo> m_opaque_up;
72};
73
74} // namespace lldb
75
76#endif // LLDB_API_SBPROCESSINFO_H
#define LLDB_API
Definition SBDefines.h:28
static llvm::StringRef GetName(XcodeSDK::Type type)
Definition XcodeSDK.cpp:21
uint32_t GetNumArguments() const
Returns the number of command line arguments for the described process.
uint32_t GetEffectiveGroupID()
friend class SBProcess
const char * GetArgumentAtIndex(uint32_t idx) const
Returns the command line argument at the given index, or nullptr if the index is out of range or if t...
lldb::pid_t GetParentProcessID()
uint32_t GetEffectiveUserID()
SBProcessInfo & operator=(const SBProcessInfo &rhs)
std::unique_ptr< lldb_private::ProcessInstanceInfo > m_opaque_up
lldb_private::ProcessInstanceInfo & ref()
void SetProcessInfo(const lldb_private::ProcessInstanceInfo &proc_info_ref)
friend class SBProcessInfoList
lldb::pid_t GetProcessID()
const char * GetTriple()
Return the target triple (arch-vendor-os) for the described process.
SBFileSpec GetExecutableFile()
uint64_t pid_t
Definition lldb-types.h:83