org.apache.wicket.util.collections
Class UrlExternalFormComparator
java.lang.Object
org.apache.wicket.util.collections.UrlExternalFormComparator
- All Implemented Interfaces:
- Comparator<URL>
public class UrlExternalFormComparator
- extends Object
- implements Comparator<URL>
A comparator of URL instances.
Comparing URLs with their implementation of #equals() is
bad because it may cause problems like DNS resolving, or other
slow checks. This comparator uses the external form of an URL
to make a simple comparison of two Strings.
- Since:
- 1.5.6
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UrlExternalFormComparator
public UrlExternalFormComparator()
compare
public int compare(URL url1,
URL url2)
- Specified by:
compare
in interface Comparator<URL>
Copyright © 2006-2012 Apache Software Foundation. All Rights Reserved.