Loading...
Searching...
No Matches
fragmentIterator.h
Go to the documentation of this file.
// -*- Mode: C++; tab-width: 2; -*-
// vi: set ts=2:
//
// $Id: fragmentIterator.h,v 1.20 2005/10/23 12:02:18 oliver Exp $
//
#ifndef BALL_KERNEL_FRAGMENTITERATOR_H
#define BALL_KERNEL_FRAGMENTITERATOR_H
#ifndef BALL_KERNEL_ITERATOR_H
# include <BALL/KERNEL/iterator.h>
#endif
#ifndef BALL_KERNEL_PREDICATE_H
# include <BALL/KERNEL/predicate.h>
#endif
#ifndef BALL_CONCEPT_STDITERATORWRAPPER_H
# include <BALL/CONCEPT/stdIteratorWrapper.h>
#endif
namespace BALL
{
class BALL_EXPORT FragmentIteratorTraits
: public CompositeIteratorTraits
{
public:
inline FragmentIteratorTraits();
FragmentIteratorTraits(const Composite& composite);
inline FragmentIteratorTraits(const FragmentIteratorTraits& traits);
FragmentIteratorTraits& operator = (const FragmentIteratorTraits& traits);
void resetPredicate();
};
inline FragmentIteratorTraits::FragmentIteratorTraits()
: CompositeIteratorTraits()
{
predicate_ = &RTTI::getDefault<KernelPredicate<Fragment> >();
}
inline FragmentIteratorTraits::FragmentIteratorTraits(const Composite& composite)
: CompositeIteratorTraits(composite)
{
predicate_ = &RTTI::getDefault<KernelPredicate<Fragment> >();
}
inline FragmentIteratorTraits::FragmentIteratorTraits(const FragmentIteratorTraits& traits)
: CompositeIteratorTraits(traits)
{
}
inline FragmentIteratorTraits& FragmentIteratorTraits::operator = (const FragmentIteratorTraits& traits)
{
CompositeIteratorTraits::operator=(traits);
return *this;
}
inline void FragmentIteratorTraits::resetPredicate()
{
predicate_ = &RTTI::getDefault<KernelPredicate<Fragment> >();
}
typedef BidirectionalIterator
<Composite, Fragment, Composite::CompositeIterator, FragmentIteratorTraits>
FragmentIterator;
typedef ConstBidirectionalIterator
<Composite, Fragment, Composite::CompositeIterator, FragmentIteratorTraits>
FragmentConstIterator;
typedef std::reverse_iterator<FragmentIterator> FragmentReverseIterator;
typedef std::reverse_iterator<FragmentConstIterator> FragmentConstReverseIterator;
IteratorWrapper(Fragment)
ConstIteratorWrapper(Fragment)
} // namespace BALL
#endif // BALL_KERNEL_FRAGMENTITERATOR_H
BALL_EXPORT
#define BALL_EXPORT
Definition COMMON/global.h:50
predicate.h
BALL::BidirectionalIterator
Mutable bidirectional iterator.
Definition bidirectionalIterator.h:260
BALL::CompositeIteratorTraits::predicate_
const UnaryPredicate< Composite > * predicate_
The predicate.
Definition iterator.h:235
BALL::CompositeIteratorTraits::CompositeIteratorTraits
CompositeIteratorTraits()
Default constructor.
Definition iterator.h:238
BALL::CompositeIteratorTraits::operator=
CompositeIteratorTraits & operator=(const CompositeIteratorTraits &traits)
Assignment operator.
Definition iterator.h:259
BALL::Composite
Definition composite.h:74
BALL::Composite::CompositeIterator
BidirectionalIterator< Composite, Composite, Composite *, CompositeIteratorTraits > CompositeIterator
Definition composite.h:1468
BALL::ConstBidirectionalIterator
Definition bidirectionalIterator.h:25
BALL::FragmentIteratorTraits
Definition fragmentIterator.h:31
BALL::FragmentIteratorTraits::operator=
FragmentIteratorTraits & operator=(const FragmentIteratorTraits &traits)
Definition fragmentIterator.h:62
BALL::FragmentIteratorTraits::resetPredicate
void resetPredicate()
Definition fragmentIterator.h:68
BALL::FragmentIteratorTraits::FragmentIteratorTraits
FragmentIteratorTraits()
Definition fragmentIterator.h:45
BALL::Fragment
Definition fragment.h:22
iterator.h
BALL::RTTI::getDefault
const T & getDefault()
Definition rtti.h:75
BALL
Definition constants.h:13
BALL::FragmentIterator
BidirectionalIterator< Composite, Fragment, Composite::CompositeIterator, FragmentIteratorTraits > FragmentIterator
Definition fragmentIterator.h:76
BALL::FragmentReverseIterator
std::reverse_iterator< FragmentIterator > FragmentReverseIterator
Definition fragmentIterator.h:84
BALL::FragmentConstIterator
ConstBidirectionalIterator< Composite, Fragment, Composite::CompositeIterator, FragmentIteratorTraits > FragmentConstIterator
Definition fragmentIterator.h:81
BALL::FragmentConstReverseIterator
std::reverse_iterator< FragmentConstIterator > FragmentConstReverseIterator
Definition fragmentIterator.h:87
stdIteratorWrapper.h
ConstIteratorWrapper
#define ConstIteratorWrapper(type)
Definition stdIteratorWrapper.h:17
IteratorWrapper
#define IteratorWrapper(type)
Definition stdIteratorWrapper.h:4