BALL 1.5.0
compositeManager.h
Go to the documentation of this file.
1// -*- Mode: C++; tab-width: 2; -*-
2// vi: set ts=2:
3//
4
5#ifndef BALL_VIEW_KERNEL_COMPOSITEMANAGER_H
6#define BALL_VIEW_KERNEL_COMPOSITEMANAGER_H
7
8#ifndef BALL_DATATYPE_HASHSET_H
10#endif
11
12namespace BALL
13{
14 class Composite;
15 class System;
16
17 namespace VIEW
18 {
27 {
28 public:
33 typedef Composite *& reference;
34 typedef Composite** pointer;
35 typedef const Composite*& const_reference;
36 typedef const Composite** const_pointer;
38 typedef Size size_type;
40
43
46
48
51
55
59
63
66 virtual void clear();
67
69
72
76 bool has(const Composite* composite) const;
77
81 bool hasRoot(const Composite* composite) const;
82
84
87
92 bool insert(Composite& composite);
93
97 void remove(Composite& composite, bool to_delete = true);
98
102 { return composite_set_.size();}
103
105
108
111 { return composite_set_.begin();}
112
115 { return composite_set_.end();}
116
119 { return composite_set_.begin();}
120
123 { return composite_set_.end();}
124
127 { return composite_set_;}
128
131 { return composite_set_;}
132
138 virtual void dump(std::ostream& s = std::cout, Size depth = 0) const;
139
141
142 private:
143
144 HashSet<Composite*> composite_set_;
145 HashSet<String> name_set_;
146 };
147
148 } // namespace VIEW
149} // namespace BALL
150
151#endif // BALL_VIEW_KERNEL_COMPOSITEMANAGER_H
Definition: constants.h:13
static ConstForwardIterator begin(const Container &container)
static ConstForwardIterator end(const Container &container)
static ForwardIterator begin(const Container &container)
static ForwardIterator end(const Container &container)
CompositeManager(const CompositeManager &cm)
bool hasRoot(const Composite *composite) const
bool has(const Composite *composite) const
HashSet< Composite * >::Iterator CompositeIterator
CompositeConstIterator begin() const
bool insert(Composite &composite)
HashSet< Composite * >::Iterator iterator
const HashSet< Composite * > & getComposites() const
HashSet< Composite * >::ConstIterator CompositeConstIterator
void remove(Composite &composite, bool to_delete=true)
HashSet< Composite * > & getComposites()
virtual void dump(std::ostream &s=std::cout, Size depth=0) const
const Composite ** const_pointer
const Composite *& const_reference
CompositeConstIterator end() const
#define BALL_VIEW_EXPORT
Definition: COMMON/global.h:52