aGrUM  0.16.0
set.cpp
Go to the documentation of this file.
1 
29 #ifndef DOXYGEN_SHOULD_SKIP_THIS
30 
31 # include <agrum/core/set.h>
32 
33 namespace gum {
34 
35  // creates (if needed) and returns the iterator __SetIterEndSafe
36  const SetIteratorSafe< int >* SetIteratorStaticEnd::endSafe4Statics() {
37  static bool first_time = true;
38 
39  if (first_time) {
40  first_time = false;
41  __SetIterEndSafe = new SetIteratorSafe< int >;
42 # ifdef GUM_DEBUG_MODE
43  __debug__::__dec_creation("SetIteratorSafe",
44  "__set_static_end",
45  0,
46  "static variable correction",
47  0);
48  __debug__::__dec_creation("HashTableConstIteratorSafe",
49  "__set_static_end",
50  0,
51  "static variable correction",
52  0);
53 # endif
54  }
55 
56  return __SetIterEndSafe;
57  }
58 
59  // creates (if needed) and returns the iterator __SetIterEndSafe
60  const SetIteratorSafe< int >* SetIteratorStaticEnd::constEndSafe4Statics() {
61  return endSafe4Statics();
62  }
63 
64  // creates (if needed) and returns the iterator __SetIterEnd
65  const SetIterator< int >* SetIteratorStaticEnd::end4Statics() {
66  static bool first_time = true;
67 
68  if (first_time) {
69  first_time = false;
70  __SetIterEnd = new SetIterator< int >;
71 # ifdef GUM_DEBUG_MODE
72  __debug__::__dec_creation(
73  "SetIterator", "__set_static_end", 0, "static variable correction", 0);
74  __debug__::__dec_creation("HashTableConstIterator",
75  "__set_static_end",
76  0,
77  "static variable correction",
78  0);
79 # endif
80  }
81 
82  return __SetIterEnd;
83  }
84 
85  // creates (if needed) and returns the iterator __SetIterEnd
86  const SetIterator< int >* SetIteratorStaticEnd::constEnd4Statics() {
87  return end4Statics();
88  }
89 
90  // create the end iterator for all Sets
91  const SetIteratorSafe< int >* SetIteratorStaticEnd::__SetIterEndSafe =
92  SetIteratorStaticEnd::endSafe4Statics();
93 
94  // create the end iterator for all Sets
95  const SetIterator< int >* SetIteratorStaticEnd::__SetIterEnd =
96  SetIteratorStaticEnd::end4Statics();
97 
98 } /* namespace gum */
99 
100 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
101 
102 
103 #ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
104 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
105 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
106 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
107 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
108 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
109 template class gum::Set< int >;
110 # endif
111 # endif
112 # endif
113 # endif
114 # endif
115 #endif
116 #ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
117 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
118 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
119 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
120 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
121 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
122 template class gum::Set< long >;
123 # endif
124 # endif
125 # endif
126 # endif
127 # endif
128 #endif
129 #ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
130 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
131 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
132 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
133 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
134 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
135 template class gum::Set< unsigned int >;
136 # endif
137 # endif
138 # endif
139 # endif
140 # endif
141 #endif
142 #ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
143 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
144 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
145 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
146 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
147 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
148 template class gum::Set< unsigned long >;
149 # endif
150 # endif
151 # endif
152 # endif
153 # endif
154 #endif
155 
156 #ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
157 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
158 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
159 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
160 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
161 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
162 template class gum::Set< double >;
163 # endif
164 # endif
165 # endif
166 # endif
167 # endif
168 #endif
169 #ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
170 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
171 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
172 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
173 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
174 # ifndef GUM_NO_EXTERN_TEMPLATE_CLASS
175 template class gum::Set< std::string >;
176 # endif
177 # endif
178 # endif
179 # endif
180 # endif
181 #endif
Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.
Copyright 2005-2019 Pierre-Henri WUILLEMIN et Christophe GONZALES (LIP6) {prenom.nom}_at_lip6.fr.
Definition: agrum.h:25
Representation of a setA Set is a structure that contains arbitrary elements.
Definition: set.h:165