BALL  1.4.79
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
fragmentIterator.h
Go to the documentation of this file.
1 // -*- Mode: C++; tab-width: 2; -*-
2 // vi: set ts=2:
3 //
4 // $Id: fragmentIterator.h,v 1.20 2005/10/23 12:02:18 oliver Exp $
5 //
6 
7 #ifndef BALL_KERNEL_FRAGMENTITERATOR_H
8 #define BALL_KERNEL_FRAGMENTITERATOR_H
9 
10 #ifndef BALL_KERNEL_ITERATOR_H
11 # include <BALL/KERNEL/iterator.h>
12 #endif
13 
14 #ifndef BALL_KERNEL_PREDICATE_H
15 # include <BALL/KERNEL/predicate.h>
16 #endif
17 
18 #ifndef BALL_CONCEPT_STDITERATORWRAPPER_H
20 #endif
21 
22 namespace BALL
23 {
31  {
32  public:
33 
34  inline FragmentIteratorTraits();
35 
36  FragmentIteratorTraits(const Composite& composite);
37 
38  inline FragmentIteratorTraits(const FragmentIteratorTraits& traits);
39 
40  FragmentIteratorTraits& operator = (const FragmentIteratorTraits& traits);
41 
42  void resetPredicate();
43  };
44 
47  {
48  predicate_ = &RTTI::getDefault<KernelPredicate<Fragment> >();
49  }
50 
52  : CompositeIteratorTraits(composite)
53  {
54  predicate_ = &RTTI::getDefault<KernelPredicate<Fragment> >();
55  }
56 
58  : CompositeIteratorTraits(traits)
59  {
60  }
61 
63  {
65  return *this;
66  }
67 
69  {
70  predicate_ = &RTTI::getDefault<KernelPredicate<Fragment> >();
71  }
72 
74  typedef BidirectionalIterator
77 
82 
84  typedef std::reverse_iterator<FragmentIterator> FragmentReverseIterator;
85 
87  typedef std::reverse_iterator<FragmentConstIterator> FragmentConstReverseIterator;
88 
91 
92 } // namespace BALL
93 #endif // BALL_KERNEL_FRAGMENTITERATOR_H
FragmentIteratorTraits & operator=(const FragmentIteratorTraits &traits)
std::reverse_iterator< FragmentConstIterator > FragmentConstReverseIterator
BidirectionalIterator< Composite, Fragment, Composite::CompositeIterator, FragmentIteratorTraits > FragmentIterator
#define IteratorWrapper(type)
#define ConstIteratorWrapper(type)
const UnaryPredicate< Composite > * predicate_
The predicate.
Definition: iterator.h:235
CompositeIteratorTraits & operator=(const CompositeIteratorTraits &traits)
Assignment operator.
Definition: iterator.h:259
BidirectionalIterator< Composite, Composite, Composite *, CompositeIteratorTraits > CompositeIterator
Definition: composite.h:1468
Mutable bidirectional iterator.
std::reverse_iterator< FragmentIterator > FragmentReverseIterator
ConstBidirectionalIterator< Composite, Fragment, Composite::CompositeIterator, FragmentIteratorTraits > FragmentConstIterator
#define BALL_EXPORT
Definition: COMMON/global.h:50