xref: /freebsd/contrib/llvm-project/lldb/include/lldb/API/SBAddressRangeList.h (revision 0fca6ea1d4eea4c934cfff25ac9ee8ad6fe95583)
1 //===-- SBAddressRangeList.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_SBADDRESSRANGELIST_H
10 #define LLDB_API_SBADDRESSRANGELIST_H
11 
12 #include <memory>
13 
14 #include "lldb/API/SBDefines.h"
15 
16 namespace lldb_private {
17 class AddressRangeListImpl;
18 }
19 
20 namespace lldb {
21 
22 class LLDB_API SBAddressRangeList {
23 public:
24   SBAddressRangeList();
25 
26   SBAddressRangeList(const lldb::SBAddressRangeList &rhs);
27 
28   ~SBAddressRangeList();
29 
30   const lldb::SBAddressRangeList &
31   operator=(const lldb::SBAddressRangeList &rhs);
32 
33   uint32_t GetSize() const;
34 
35   void Clear();
36 
37   SBAddressRange GetAddressRangeAtIndex(uint64_t idx);
38 
39   void Append(const lldb::SBAddressRange &addr_range);
40 
41   void Append(const lldb::SBAddressRangeList &addr_range_list);
42 
43   bool GetDescription(lldb::SBStream &description, const SBTarget &target);
44 
45 private:
46   friend class SBBlock;
47   friend class SBProcess;
48 
49   lldb_private::AddressRangeListImpl &ref() const;
50 
51   std::unique_ptr<lldb_private::AddressRangeListImpl> m_opaque_up;
52 };
53 
54 } // namespace lldb
55 
56 #endif // LLDB_API_SBADDRESSRANGELIST_H
57