Loading...
Searching...
No Matches
moleculeIterator.h
Go to the documentation of this file.
// -*- Mode: C++; tab-width: 2; -*-
// vi: set ts=2:
//
// $Id: moleculeIterator.h,v 1.16 2005/10/23 12:02:19 oliver Exp $
//
#ifndef BALL_KERNEL_MOLECULEITERATOR_H
#define BALL_KERNEL_MOLECULEITERATOR_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 MoleculeIteratorTraits
: public CompositeIteratorTraits
{
public:
MoleculeIteratorTraits()
: CompositeIteratorTraits()
{
predicate_ = &RTTI::getDefault<KernelPredicate<Molecule> >();
}
MoleculeIteratorTraits(const Composite& composite)
: CompositeIteratorTraits(composite)
{
predicate_ = &RTTI::getDefault<KernelPredicate<Molecule> >();
}
MoleculeIteratorTraits(const MoleculeIteratorTraits& traits, bool /* deep */ = true)
: CompositeIteratorTraits(traits)
{
}
MoleculeIteratorTraits &operator = (const MoleculeIteratorTraits& traits)
{
CompositeIteratorTraits::operator=(traits);
return *this;
}
void resetPredicate()
{
predicate_ = &RTTI::getDefault<KernelPredicate<Molecule> >();
}
};
typedef BidirectionalIterator
<Composite, Molecule, Composite::CompositeIterator, MoleculeIteratorTraits>
MoleculeIterator;
typedef ConstBidirectionalIterator
<Composite, Molecule, Composite::CompositeIterator, MoleculeIteratorTraits>
MoleculeConstIterator;
typedef std::reverse_iterator<MoleculeIterator> MoleculeReverseIterator;
typedef std::reverse_iterator<MoleculeConstIterator> MoleculeConstReverseIterator;
IteratorWrapper(Molecule)
ConstIteratorWrapper(Molecule)
} // namespace BALL
#endif // BALL_KERNEL_MOLECULEITERATOR_H
BALL_EXPORT
#define BALL_EXPORT
Definition COMMON/global.h:50
predicate.h
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::MoleculeIteratorTraits
Definition moleculeIterator.h:29
BALL::MoleculeIteratorTraits::MoleculeIteratorTraits
MoleculeIteratorTraits(const MoleculeIteratorTraits &traits, bool=true)
Definition moleculeIterator.h:44
BALL::MoleculeIteratorTraits::resetPredicate
void resetPredicate()
Definition moleculeIterator.h:55
BALL::MoleculeIteratorTraits::MoleculeIteratorTraits
MoleculeIteratorTraits()
Definition moleculeIterator.h:32
BALL::MoleculeIteratorTraits::MoleculeIteratorTraits
MoleculeIteratorTraits(const Composite &composite)
Definition moleculeIterator.h:38
BALL::Molecule
Definition molecule.h:31
iterator.h
BALL::RTTI::getDefault
const T & getDefault()
Definition rtti.h:75
BALL
Definition constants.h:13
BALL::MoleculeConstIterator
ConstBidirectionalIterator< Composite, Molecule, Composite::CompositeIterator, MoleculeIteratorTraits > MoleculeConstIterator
Definition moleculeIterator.h:70
BALL::MoleculeIterator
BidirectionalIterator< Composite, Molecule, Composite::CompositeIterator, MoleculeIteratorTraits > MoleculeIterator
Definition moleculeIterator.h:65
BALL::MoleculeReverseIterator
std::reverse_iterator< MoleculeIterator > MoleculeReverseIterator
Definition moleculeIterator.h:73
BALL::MoleculeConstReverseIterator
std::reverse_iterator< MoleculeConstIterator > MoleculeConstReverseIterator
Definition moleculeIterator.h:76
stdIteratorWrapper.h
ConstIteratorWrapper
#define ConstIteratorWrapper(type)
Definition stdIteratorWrapper.h:17
IteratorWrapper
#define IteratorWrapper(type)
Definition stdIteratorWrapper.h:4