org.cip4.jdflib.core
Class KElement.SingleAttributeComparator

java.lang.Object
  extended by org.cip4.jdflib.core.KElement.SingleXPathComparator
      extended by org.cip4.jdflib.core.KElement.SingleAttributeComparator
All Implemented Interfaces:
Comparator<KElement>
Enclosing class:
KElement

public static class KElement.SingleAttributeComparator
extends KElement.SingleXPathComparator

sorts according to the value of one attribute
if the attribute is numeric, compare numerically, else lexical comparison is done

Author:
prosirai

Constructor Summary
KElement.SingleAttributeComparator(String pAttName, boolean pInvert)
          if the attribute is numeric, compare numerically, else lexical comparison is done
 
Method Summary
 
Methods inherited from class org.cip4.jdflib.core.KElement.SingleXPathComparator
compare
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
equals
 

Constructor Detail

KElement.SingleAttributeComparator

public KElement.SingleAttributeComparator(String pAttName,
                                          boolean pInvert)
if the attribute is numeric, compare numerically, else lexical comparison is done

Parameters:
pAttName - the attribute to use for comparing
pInvert - if true, sort backwards


Copyright © 2013. All Rights Reserved.