ValueObjectList.h revision 870a1cdb923ce708d474af357dd1fea3d063ab97
1//===-- ValueObjectList.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_ValueObjectList_h_
11#define liblldb_ValueObjectList_h_
12
13// C Includes
14// C++ Includes
15#include <vector>
16
17// Other libraries and framework includes
18// Project includes
19#include "lldb/lldb-private.h"
20#include "lldb/Core/ClangForward.h"
21#include "lldb/Core/UserID.h"
22#include "lldb/Target/ExecutionContextScope.h"
23
24namespace lldb_private {
25
26//----------------------------------------------------------------------
27// A collection of ValueObject values that
28//----------------------------------------------------------------------
29class ValueObjectList
30{
31public:
32    //------------------------------------------------------------------
33    // Constructors and Destructors
34    //------------------------------------------------------------------
35    ValueObjectList ();
36
37    ValueObjectList (const ValueObjectList &rhs);
38
39    ~ValueObjectList();
40
41    const ValueObjectList &
42    operator = (const ValueObjectList &rhs);
43
44    void
45    Append (const lldb::ValueObjectSP &val_obj_sp);
46
47    lldb::ValueObjectSP
48    FindValueObjectByPointer (ValueObject *valobj);
49
50    uint32_t
51    GetSize() const;
52
53    lldb::ValueObjectSP
54    GetValueObjectAtIndex (uint32_t);
55
56    lldb::ValueObjectSP
57    FindValueObjectByValueName (const char *name);
58
59    lldb::ValueObjectSP
60    FindValueObjectByUID (lldb::user_id_t uid);
61
62    void
63    Swap (ValueObjectList &value_object_list);
64
65protected:
66    typedef std::vector<lldb::ValueObjectSP> collection;
67    //------------------------------------------------------------------
68    // Classes that inherit from ValueObjectList can see and modify these
69    //------------------------------------------------------------------
70    collection  m_value_objects;
71
72};
73
74
75} // namespace lldb_private
76
77#endif  // liblldb_ValueObjectList_h_
78