DGtal
0.6.devel
|
#include <GreedySegmentation.h>
Public Types | |
typedef GreedySegmentation::SegmentComputer | SegmentComputer |
typedef SegmentComputer::ConstIterator | ConstIterator |
Public Member Functions | |
SegmentComputerIterator (const GreedySegmentation< TSegmentComputer > *aSegmentation, const TSegmentComputer &aSegmentComputer, const bool &aFlag) | |
SegmentComputerIterator (const SegmentComputerIterator &aOther) | |
SegmentComputerIterator & | operator= (const SegmentComputerIterator &aOther) |
~SegmentComputerIterator () | |
bool | isValid () const |
const SegmentComputer & | operator* () const |
SegmentComputer | get () const |
const SegmentComputer * | operator-> () const |
SegmentComputerIterator & | operator++ () |
void | next () |
bool | operator== (const SegmentComputerIterator &aOther) const |
bool | operator!= (const SegmentComputerIterator &aOther) const |
bool | intersectNext () const |
bool | intersectPrevious () const |
const ConstIterator | begin () const |
const ConstIterator | end () const |
Private Member Functions | |
void | longestSegment (const ConstIterator &it) |
bool | doesIntersectNext (const ConstIterator &it, const ConstIterator &itb, const ConstIterator &ite) |
bool | doesIntersectNext (const ConstIterator &it, const ConstIterator &itb, const ConstIterator &ite, IteratorType) |
bool | doesIntersectNext (const ConstIterator &it, const ConstIterator &itb, const ConstIterator &ite, CirculatorType) |
bool | doesIntersectNext (const ConstIterator &it) |
Private Attributes | |
const GreedySegmentation < TSegmentComputer > * | myS |
SegmentComputer | mySegmentComputer |
bool | myFlagIsValid |
bool | myFlagIntersectNext |
bool | myFlagIntersectPrevious |
bool | myFlagIsLast |
Friends | |
class | GreedySegmentation< TSegmentComputer > |
Aim: Specific iterator to visit all the segments of a greedy segmentation.
Description of template class 'SaturatedSegmentation::SegmentComputerIterator'
Definition at line 168 of file GreedySegmentation.h.
typedef SegmentComputer::ConstIterator DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::ConstIterator |
Definition at line 175 of file GreedySegmentation.h.
typedef GreedySegmentation::SegmentComputer DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::SegmentComputer |
Definition at line 174 of file GreedySegmentation.h.
|
inline |
Constructor.
Nb: complexity in O(n).
aSegmentation | the object that knows the range bounds |
aSegmentComputer | an online segment recognition algorithm |
aFlag | 'true' to build a valid object, 'false' otherwise |
Definition at line 160 of file GreedySegmentation.ih.
References DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::doesIntersectNext(), DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::longestSegment(), DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::myFlagIntersectPrevious, DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::myFlagIsValid, and DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::myS.
|
inline |
Copy constructor.
other | the iterator to clone. |
Definition at line 194 of file GreedySegmentation.ih.
|
inline |
|
inline |
Definition at line 319 of file GreedySegmentation.ih.
References DGtal::GreedySegmentation< TSegmentComputer >::mySegmentComputer.
|
inlineprivate |
Checks if the current segment intersects the next one.
it | end of the current segment |
itb | begin iterator of the underlying range |
ite | end iterator of the underlying range |
Definition at line 48 of file GreedySegmentation.ih.
Referenced by DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::SegmentComputerIterator().
|
inlineprivate |
Definition at line 57 of file GreedySegmentation.ih.
References DGtal::GreedySegmentation< TSegmentComputer >::mySegmentComputer.
|
inlineprivate |
Definition at line 77 of file GreedySegmentation.ih.
|
inlineprivate |
Checks if the current segment intersects the next one (if exists).
it | end of the current segment |
NB: no verification
Definition at line 86 of file GreedySegmentation.ih.
References DGtal::GreedySegmentation< TSegmentComputer >::mySegmentComputer.
|
inline |
Definition at line 327 of file GreedySegmentation.ih.
References DGtal::GreedySegmentation< TSegmentComputer >::mySegmentComputer.
|
inline |
Definition at line 254 of file GreedySegmentation.ih.
References DGtal::GreedySegmentation< TSegmentComputer >::mySegmentComputer.
|
inline |
Definition at line 301 of file GreedySegmentation.ih.
|
inline |
Definition at line 309 of file GreedySegmentation.ih.
|
inline |
Checks the validity/consistency of the object.
Definition at line 258 of file GreedySegmentation.h.
References DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::myFlagIsValid.
Referenced by DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::operator==().
|
inlineprivate |
Computes the longest possible segment from [it]
it | a given iterator |
Nb: complexity in O(n).
Definition at line 99 of file GreedySegmentation.ih.
References DGtal::GreedySegmentation< TSegmentComputer >::mySegmentComputer.
Referenced by DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::SegmentComputerIterator().
|
inline |
Goes to the next segment (if possible).
Nb: complexity in O(n).
Definition at line 135 of file GreedySegmentation.ih.
References DGtal::longestSegment(), and DGtal::GreedySegmentation< TSegmentComputer >::mySegmentComputer.
|
inline |
Inequality operator.
aOther | the iterator to compare with |
Definition at line 290 of file GreedySegmentation.ih.
|
inline |
Definition at line 237 of file GreedySegmentation.ih.
References DGtal::GreedySegmentation< TSegmentComputer >::mySegmentComputer.
|
inline |
Pre-increment. Goes to the next segment (if possible).
Nb: complexity in O(n).
Definition at line 262 of file GreedySegmentation.ih.
|
inline |
Definition at line 245 of file GreedySegmentation.ih.
References DGtal::GreedySegmentation< TSegmentComputer >::mySegmentComputer.
|
inline |
Assignment.
aOther | the iterator to copy. |
Definition at line 209 of file GreedySegmentation.ih.
References DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::myFlagIntersectNext, DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::myFlagIntersectPrevious, DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::myFlagIsLast, DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::myFlagIsValid, DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::myS, DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::mySegmentComputer, and DGtal::GreedySegmentation< TSegmentComputer >::mySegmentComputer.
|
inline |
Equality operator.
aOther | the iterator to compare with |
Definition at line 274 of file GreedySegmentation.ih.
References DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::isValid(), DGtal::GreedySegmentation< TSegmentComputer >::isValid(), DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::mySegmentComputer, and DGtal::GreedySegmentation< TSegmentComputer >::mySegmentComputer.
|
friend |
Definition at line 218 of file GreedySegmentation.h.
|
private |
A flag equal to TRUE if the current segment intersects the next one, FALSE otherwise (and FALSE if the current segment is the last one)
Definition at line 200 of file GreedySegmentation.h.
Referenced by DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::operator=().
|
private |
A flag equal to TRUE if the current segment intersects the previous one, FALSE otherwise (and FALSE if the current segment is the first one)
Definition at line 207 of file GreedySegmentation.h.
Referenced by DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::operator=(), and DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::SegmentComputerIterator().
|
private |
A flag equal to TRUE if *this has reached the end, FALSE otherwise
Definition at line 212 of file GreedySegmentation.h.
Referenced by DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::operator=().
|
private |
A flag equal to TRUE if *this is valid, FALSE otherwise
Definition at line 193 of file GreedySegmentation.h.
Referenced by DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::isValid(), DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::operator=(), and DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::SegmentComputerIterator().
|
private |
Pointer to the segmentation
Definition at line 183 of file GreedySegmentation.h.
Referenced by DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::operator=(), and DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::SegmentComputerIterator().
|
private |
The current segment
Definition at line 188 of file GreedySegmentation.h.
Referenced by DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::operator=(), and DGtal::GreedySegmentation< TSegmentComputer >::SegmentComputerIterator::operator==().