copy from opends/src/server/org/opends/server/synchronization/FakeOperationComparator.java
copy to opends/src/server/org/opends/server/synchronization/common/package-info.java
| File was copied from opends/src/server/org/opends/server/synchronization/FakeOperationComparator.java |
| | |
| | | * |
| | | * Portions Copyright 2006 Sun Microsystems, Inc. |
| | | */ |
| | | package org.opends.server.synchronization; |
| | | |
| | | import java.util.Comparator; |
| | | |
| | | /** |
| | | * This Class implements a Comparator that can be used to build TreeSet |
| | | * containing FakeOperations sorted by the ChangeNumber order. |
| | | * This package contains utilities that can are used by all the packages |
| | | * below org.opends.server.synchronization |
| | | * <br> |
| | | * The main classes of this core are : |
| | | * <ul> |
| | | * <li> |
| | | * <A HREF="ChangeNumber.html"><B>ChangeNumber</B></A> |
| | | * Define Change Numbers used to identify and to order the LDAP changes |
| | | * </li> |
| | | * <li> |
| | | * <A HREF="ServerState.html"><B>ServerStaten</B></A> |
| | | * This class is used to define and store the updatedness of any component |
| | | * of the synchronization architecture (i.e : to know which changes |
| | | * it has already processed). |
| | | * </li> |
| | | * </ul> |
| | | */ |
| | | public class FakeOperationComparator implements Comparator<FakeOperation> |
| | | { |
| | | /** |
| | | * {@inheritDoc} |
| | | */ |
| | | public int compare(FakeOperation op1, FakeOperation op2) |
| | | { |
| | | if (op1 == null) |
| | | return -1; |
| | | return op1.getChangeNumber().compareTo(op2.getChangeNumber()); |
| | | } |
| | | } |
| | | package org.opends.server.synchronization.common; |