directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r809415 - in /directory/shared/branches/shared-schema: ldap-schema/src/main/resources/schema/schema/apache/comparators/ ldap/src/main/java/org/apache/directory/shared/ldap/schema/comparators/ ldap/src/main/java/org/apache/directory/shared/l...
Date Sun, 30 Aug 2009 20:47:25 GMT
Author: akarasulu
Date: Sun Aug 30 20:47:24 2009
New Revision: 809415

URL: http://svn.apache.org/viewvc?rev=809415&view=rev
Log:
moved comparator which now extends LdapComparator and change fcqn in schema so it is in the
right place

Added:
    directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/comparators/LongComparator.java
      - copied, changed from r809383, directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/util/LongComparator.java
Removed:
    directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/util/LongComparator.java
Modified:
    directory/shared/branches/shared-schema/ldap-schema/src/main/resources/schema/schema/apache/comparators/1.3.6.1.4.1.18060.0.4.1.1.2.ldif

Modified: directory/shared/branches/shared-schema/ldap-schema/src/main/resources/schema/schema/apache/comparators/1.3.6.1.4.1.18060.0.4.1.1.2.ldif
URL: http://svn.apache.org/viewvc/directory/shared/branches/shared-schema/ldap-schema/src/main/resources/schema/schema/apache/comparators/1.3.6.1.4.1.18060.0.4.1.1.2.ldif?rev=809415&r1=809414&r2=809415&view=diff
==============================================================================
--- directory/shared/branches/shared-schema/ldap-schema/src/main/resources/schema/schema/apache/comparators/1.3.6.1.4.1.18060.0.4.1.1.2.ldif
(original)
+++ directory/shared/branches/shared-schema/ldap-schema/src/main/resources/schema/schema/apache/comparators/1.3.6.1.4.1.18060.0.4.1.1.2.ldif
Sun Aug 30 20:47:24 2009
@@ -7,4 +7,4 @@
 objectclass: top
 entrycsn: 20090818052728.264000Z#000000#000#000000
 m-oid: 1.3.6.1.4.1.18060.0.4.1.1.2
-m-fqcn: org.apache.directory.shared.ldap.util.LongComparator
+m-fqcn: org.apache.directory.shared.ldap.schema.comparators.LongComparator

Copied: directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/comparators/LongComparator.java
(from r809383, directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/util/LongComparator.java)
URL: http://svn.apache.org/viewvc/directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/comparators/LongComparator.java?p2=directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/comparators/LongComparator.java&p1=directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/util/LongComparator.java&r1=809383&r2=809415&rev=809415&view=diff
==============================================================================
--- directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/util/LongComparator.java
(original)
+++ directory/shared/branches/shared-schema/ldap/src/main/java/org/apache/directory/shared/ldap/schema/comparators/LongComparator.java
Sun Aug 30 20:47:24 2009
@@ -17,10 +17,10 @@
  *  under the License. 
  *  
  */
-package org.apache.directory.shared.ldap.util;
+package org.apache.directory.shared.ldap.schema.comparators;
 
-import java.io.Serializable;
-import java.util.Comparator;
+
+import org.apache.directory.shared.ldap.schema.LdapComparator;
 
 
 /**
@@ -29,7 +29,7 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Revision: 437007 $
  */
-public class LongComparator implements Comparator<Object>, Serializable
+public class LongComparator extends LdapComparator<Long>
 {
     /** A instance of this comparator */
     public static final LongComparator INSTANCE = new LongComparator();
@@ -47,13 +47,11 @@
      * @param obj2 Second object
      * @return 1 if obj1 > obj2, 0 if obj1 == obj2, -1 if obj1 < obj2
      */
-    public int compare( Object obj1, Object obj2 )
+    public int compare( Long obj1, Long obj2 )
     {
         try
         {
-            Long long1 = (Long)obj1;
-            Long long2 = (Long)obj2;
-            return long1.compareTo( long2 );
+            return obj1.compareTo( obj2 );
         }
         catch ( NullPointerException npe )
         {



Mime
View raw message