org.apache.tinkerpop.gremlin.process.traversal.step.util

## Class ElementValueComparator<V>

- java.lang.Object
- - org.apache.tinkerpop.gremlin.process.traversal.step.util.ElementValueComparator<V>

- All Implemented Interfaces:
    Serializable, Comparator<Element>

      public final class ElementValueComparator<V>
      extends Object
      implements Comparator<Element>, Serializable

  Author:
    Marko A. Rodriguez (http://markorodriguez.com)
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ElementValueComparator(String propertyKey, Comparator<V> valueComparator)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `compare(Element elementA, Element elementB)`
    `String` | `getPropertyKey()`
    `Comparator<V>` | `getValueComparator()`
    `String` | `toString()`

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

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

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

      `comparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong`

- - ### Constructor Detail

    - #### ElementValueComparator

          public ElementValueComparator(String propertyKey,
                                        Comparator<V> valueComparator)

  - ### Method Detail

    - #### getPropertyKey

          public String getPropertyKey()

    - #### getValueComparator

          public Comparator<V> getValueComparator()

    - #### compare

          public int compare(Element elementA,
                             Element elementB)

      Specified by:
        `compare` in interface `Comparator<Element>`

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

Copyright © 2013–2018 Apache Software Foundation. All rights reserved.