21 template<
class MorphType>
31 template<
class MorphType>
43 template<
class MorphType>
46 _morphs = copy._morphs;
54 template<
class MorphType>
64 template<
class MorphType>
67 return (_morphs == other._morphs);
75 template<
class MorphType>
78 return (_morphs != other._morphs);
86 template<
class MorphType>
89 return (_morphs < other._morphs);
99 template<
class MorphType>
102 if (_morphs.size() != other._morphs.size()) {
103 return (
int)_morphs.size() - (int)other._morphs.size();
105 for (
size_t i = 0; i < _morphs.size(); i++) {
106 int compare = _morphs[i].compare_to(other._morphs[i], threshold);
119 template<
class MorphType>
122 return _morphs.begin();
130 template<
class MorphType>
133 return _morphs.begin();
141 template<
class MorphType>
144 return _morphs.end();
152 template<
class MorphType>
155 return _morphs.end();
163 template<
class MorphType>
166 return _morphs.size();
174 template<
class MorphType>
177 return _morphs.empty();
191 template<
class MorphType>
194 pair<iterator, bool> result;
195 TYPENAME Morphs::iterator mi;
196 for (mi = _morphs.begin(); mi != _morphs.end(); ++mi) {
197 if ((*mi) == value) {
200 result.second =
false;
206 _morphs.push_back(value);
207 result.first = _morphs.begin() + _morphs.size() - 1;
208 result.second =
true;
217 template<
class MorphType>
228 template<
class MorphType>
230 write(ostream &out,
int indent_level,
const string &tag,
231 int num_dimensions)
const {
234 for (i = begin(); i != end(); ++i) {
235 indent(out, indent_level);
236 i->output(out, tag, num_dimensions);
pair< iterator, bool > insert(const MorphType &value)
This is similar to the insert() interface for sets, except it does not guarantee that the resulting l...
void clear()
Empties the list of morphs.
A collection of <Dxyz>'s or <Duv>'s or some such.
int compare_to(const EggMorphList< MorphType > &other, double threshold) const
compare_to() compares a different space than the operator methods, which only check the morph's name...