SheafSystem  0.0.0.0
filtered_depth_first_itr.h
Go to the documentation of this file.
1 
2 //
3 // Copyright (c) 2014 Limit Point Systems, Inc.
4 //
5 // Licensed under the Apache License, Version 2.0 (the "License");
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 // http://www.apache.org/licenses/LICENSE-2.0
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17 
20 
21 #ifndef FILTERED_DEPTH_FIRST_ITR_H
22 #define FILTERED_DEPTH_FIRST_ITR_H
23 
24 #ifndef SHEAF_DLL_SPEC_H
25 #include "SheafSystem/sheaf_dll_spec.h"
26 #endif
27 
28 #ifndef DEPTH_FIRST_ITR_H
29 #include "SheafSystem/depth_first_itr.h"
30 #endif
31 
32 #ifndef POSET_STATE_HANDLE_H
33 #include "SheafSystem/poset_state_handle.h"
34 #endif
35 
36 #ifndef STD_STACK_H
37 #include "SheafSystem/std_stack.h"
38 #endif
39 
40 #ifndef SUBPOSET_H
41 #include "SheafSystem/subposet.h"
42 #endif
43 
44 #ifndef TOTAL_POSET_MEMBER_H
45 #include "SheafSystem/total_poset_member.h"
46 #endif
47 
48 namespace sheaf
49 {
50 
51 class zn_to_bool;
52 
55 
81 
82 template <typename T>
83 class SHEAF_DLL_SPEC filtered_depth_first_itr : public depth_first_itr<T>
84 {
85  // ===========================================================
87  // ===========================================================
89 
90 public:
91 
97 
102 
106  filtered_depth_first_itr& operator=(const filtered_depth_first_itr& xother);
107 
112 
113  // OTHER CONSTRUCTORS
114 
121  bool xdown,
122  bool xstrict,
124 
131  const subposet& xfilter,
132  bool xdown,
133  bool xstrict,
135 
142  pod_index_type xfilter_index,
143  bool xdown,
144  bool xstrict,
146 
153  const scoped_index& xfilter_index,
154  bool xdown,
155  bool xstrict,
157 
164  const std::string& xfilter_name,
165  bool xdown,
166  bool xstrict,
168 
169 protected:
170 
171 private:
172 
174 
175 
176  // ===========================================================
178  // ===========================================================
180 
181 public:
182 
186  virtual void put_anchor(const abstract_poset_member* xanchor);
187 
191  virtual void put_anchor(pod_index_type xanchor_index);
192 
196  void put_anchor(const scoped_index& xanchor_index);
197 
201  void put_descending(bool xdescending);
202 
206  void put_strict(bool xstrict);
207 
211  void put_filter(const subposet& xfilter);
212 
216  void put_filter(const std::string& xfilter_name);
217 
221  void put_filter(pod_index_type xfilter_index);
222 
226  void put_filter(const scoped_index& xfilter_index);
227 
228 protected:
229 
230 private:
231 
233 
234 
235  // ===========================================================
237  // ===========================================================
239 
240 public:
241 
245  virtual bool is_ancestor_of(const any* other) const;
246 
250  virtual filtered_depth_first_itr* clone() const;
251 
255  bool invariant() const;
256 
257 protected:
258 
259 private:
260 
262 };
263 
264 } // namespace sheaf
265 
266 #endif // ifndef FILTERED_DEPTH_FIRST_ITR_H
A client handle for a subposet.
Definition: subposet.h:86
order_type
The types of order in which the iterator will visit the members of the poset. Determines which action...
The general depth-first iterator over the intersection of a subposet filter with a directional (up or...
Abstract base class with useful features for all objects.
Definition: any.h:39
The general depth-first iterator over the intersection of a poset member anchor&#39;s whole with its down...
An index within the external ("client") scope of a given id space.
Definition: scoped_index.h:116
int_type pod_index_type
The plain old data index type.
Definition: pod_types.h:49
Namespace for the sheaves component of the sheaf system.
An abstract client handle for a member of a poset.