| | |
| | | import java.util.Map; |
| | | import java.util.Set; |
| | | |
| | | import org.forgerock.opendj.ldap.ByteSequence; |
| | | import org.forgerock.opendj.ldap.ByteString; |
| | | import org.forgerock.opendj.ldap.spi.IndexingOptions; |
| | | import org.opends.server.backends.jeb.AttributeIndex.BSKeyComparator; |
| | |
| | | public abstract class Indexer |
| | | { |
| | | /** |
| | | * The comparator for keys generated by this class. |
| | | */ |
| | | private static final KeyComparator comparator = new KeyComparator(); |
| | | private static final BSKeyComparator bsComparator = new BSKeyComparator(); |
| | | |
| | | /** |
| | | * Get the comparator that must be used to compare index keys generated by |
| | | * this class. |
| | | * |
| | |
| | | */ |
| | | public final Comparator<byte[]> getComparator() |
| | | { |
| | | return comparator; |
| | | return KeyComparator.INSTANCE; |
| | | } |
| | | |
| | | /** |
| | |
| | | * |
| | | * @return A byte string comparator. |
| | | */ |
| | | public final Comparator<ByteString> getBSComparator() |
| | | public final Comparator<ByteSequence> getBSComparator() |
| | | { |
| | | return bsComparator; |
| | | return BSKeyComparator.INSTANCE; |
| | | } |
| | | |
| | | /** |
| | |
| | | * used to name an index created using this object. |
| | | * @return A string representation of this object. |
| | | */ |
| | | @Override |
| | | public abstract String toString(); |
| | | } |