org.apache.myfaces.component.html.ext
Class SortCriterion

java.lang.Object
  extended by org.apache.myfaces.component.html.ext.SortCriterion
All Implemented Interfaces:
Serializable

public final class SortCriterion
extends Object
implements Serializable

See Also:
Serialized Form

Constructor Summary
SortCriterion(String property, boolean isAscending)
           
 
Method Summary
 boolean equals(Object obj)
           
 String getProperty()
          Gets the property that is identified by this class.
 int hashCode()
           
 boolean isAscending()
          Gets the direction in which the property of this class is sorted.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SortCriterion

public SortCriterion(String property,
                     boolean isAscending)
Method Detail

isAscending

public boolean isAscending()
Gets the direction in which the property of this class is sorted.

Returns:
true if the property identified by this class is sorted in ascending order.

getProperty

public String getProperty()
Gets the property that is identified by this class. This is the property that must be sorted by. If a collection of beans is being sorted, bean rules will be used to find a suitable getter method that matches this property. The value returned by the getter method will be sorted on. If a collection of Maps is being sorted, this property will be used as the key into each Map to get at the value being sorted.


equals

public boolean equals(Object obj)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2012 The Apache Software Foundation. All Rights Reserved.