Package io.wcm.sling.commons.resource
Class NameResourceComparator
java.lang.Object
io.wcm.sling.commons.resource.NameResourceComparator
- All Implemented Interfaces:
Serializable,Comparator<org.apache.sling.api.resource.Resource>
@ProviderType
public final class NameResourceComparator
extends Object
implements Comparator<org.apache.sling.api.resource.Resource>, Serializable
Orders resources alphabetically by name (ascending).
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintcompare(org.apache.sling.api.resource.Resource o1, org.apache.sling.api.resource.Resource o2) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Constructor Details
-
NameResourceComparator
public NameResourceComparator()
-
-
Method Details
-
compare
public int compare(org.apache.sling.api.resource.Resource o1, org.apache.sling.api.resource.Resource o2) - Specified by:
comparein interfaceComparator<org.apache.sling.api.resource.Resource>
-