18 #ifndef __itkLabelObjectLineComparator_h
19 #define __itkLabelObjectLineComparator_h
40 template<
typename TLabelObjectLine >
44 bool operator()(TLabelObjectLine
const & l1, TLabelObjectLine
const & l2)
const
46 const typename TLabelObjectLine::IndexType & idx1 = l1.GetIndex();
47 const typename TLabelObjectLine::IndexType & idx2 = l2.GetIndex();
49 for (
int i = TLabelObjectLine::ImageDimension - 1; i >= 0; i-- )
51 if ( idx1[i] < idx2[i] )
55 else if ( idx1[i] > idx2[i] )
60 return l1.GetLength() < l2.GetLength();
Performs a comparison of l1 < l2. Returns true if l1 is strictly less than l2.
bool operator()(TLabelObjectLine const &l1, TLabelObjectLine const &l2) const