LLDB mainline
SBStringList.h
Go to the documentation of this file.
1//===-- SBStringList.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_SBSTRINGLIST_H
10#define LLDB_API_SBSTRINGLIST_H
11
12#include "lldb/API/SBDefines.h"
13
14namespace lldb {
15
17public:
19
21
22 const SBStringList &operator=(const SBStringList &rhs);
23
25
26 explicit operator bool() const;
27
28 bool IsValid() const;
29
30 void AppendString(const char *str);
31
32 void AppendList(const char **strv, int strc);
33
34 void AppendList(const lldb::SBStringList &strings);
35
36 uint32_t GetSize() const;
37
38 const char *GetStringAtIndex(size_t idx);
39
40 const char *GetStringAtIndex(size_t idx) const;
41
42 void Clear();
43
44protected:
46 friend class SBDebugger;
47 friend class SBBreakpoint;
49 friend class SBBreakpointName;
50 friend class SBStructuredData;
51
52 SBStringList(const lldb_private::StringList *lldb_strings);
53
54 void AppendList(const lldb_private::StringList &strings);
55
56 lldb_private::StringList *operator->();
57
58 const lldb_private::StringList *operator->() const;
59
60 const lldb_private::StringList &operator*() const;
61
62private:
63 std::unique_ptr<lldb_private::StringList> m_opaque_up;
64};
65
66} // namespace lldb
67
68#endif // LLDB_API_SBSTRINGLIST_H
#define LLDB_API
Definition: SBDefines.h:28
std::unique_ptr< lldb_private::StringList > m_opaque_up
Definition: SBStringList.h:63
Definition: SBAddress.h:15