]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - contrib/llvm/tools/lldb/include/lldb/DataFormatters/VectorIterator.h
Bring down 0.4.5 vendor files and other catchups with the distribution tarball.
[FreeBSD/FreeBSD.git] / contrib / llvm / tools / lldb / include / lldb / DataFormatters / VectorIterator.h
1 //===-- VectorIterator.h ----------------------------------------------*- C++ -*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9
10 #ifndef liblldb_VectorIterator_h_
11 #define liblldb_VectorIterator_h_
12
13 #include "lldb/lldb-forward.h"
14
15 #include "lldb/Core/ConstString.h"
16 #include "lldb/Target/ExecutionContext.h"
17
18 namespace lldb_private {
19     namespace formatters
20     {
21         class VectorIteratorSyntheticFrontEnd : public SyntheticChildrenFrontEnd
22         {
23         public:
24             VectorIteratorSyntheticFrontEnd (lldb::ValueObjectSP valobj_sp,
25                                              ConstString item_name);
26             
27             size_t
28             CalculateNumChildren() override;
29             
30             lldb::ValueObjectSP
31             GetChildAtIndex(size_t idx) override;
32             
33             bool
34             Update() override;
35             
36             bool
37             MightHaveChildren() override;
38             
39             size_t
40             GetIndexOfChildWithName(const ConstString &name) override;
41             
42             ~VectorIteratorSyntheticFrontEnd() override;
43             
44         private:
45             ExecutionContextRef m_exe_ctx_ref;
46             ConstString m_item_name;
47             lldb::ValueObjectSP m_item_sp;
48         };
49         
50     } // namespace formatters
51 } // namespace lldb_private
52
53 #endif // liblldb_CF_h_