org.apache.directory.mavibot.btree.comparator

## Class CharComparator

- java.lang.Object
- - org.apache.directory.mavibot.btree.comparator.CharComparator

- All Implemented Interfaces:
    Comparator<Character>

      public class CharComparator
      extends Object
      implements Comparator<Character>

  Compares chars
  Author:
    Apache Directory Project

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static CharComparator` | `INSTANCE` A static instance of a CharComparator

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `compare(Character char1, Character char2)` Compare two chars.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface java.util.Comparator

      `equals`

- - ### Field Detail

    - #### INSTANCE

          public static final CharComparator INSTANCE

      A static instance of a CharComparator

  - ### Method Detail

    - #### compare

          public int compare(Character char1,
                    Character char2)

      Compare two chars.
      Specified by:
        `compare` in interface `Comparator<Character>`
      Parameters:
        `char1` - First char
        `char2` - Second char
      Returns:
        1 if char1 > char2, 0 if char1 == char2, -1 if char1 < char2

Copyright © 2012–2015 Apache Mavibot Project Parent. All rights reserved.