NodeComparator (JaCoCo 0.6.3.201306030806 API)
Date: 2013-06-03

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jacoco.core.analysis
Class NodeComparator

    java.lang.Object
      org.jacoco.core.analysis.NodeComparator

All Implemented Interfaces:
  Serializable, Comparator<ICoverageNode>

    public class NodeComparator

extends Object
implements Comparator<ICoverageNode>, Serializable

Comparator to compare `ICoverageNode` objects by different counter criteria.

See Also:
  `CounterComparator.on(ICoverageNode.CounterEntity)`, Serialized Form

Method Summary
`int` | `compare(ICoverageNode n1, ICoverageNode n2)`
`NodeComparator` | `second(Comparator<ICoverageNode> second)` Creates a new composite comparator with a second search criterion.
`
`<T extends ICoverageNode> List<T>`
` | `sort(Collection<T> summaries)` Returns a sorted copy of the given collection of `ICoverageNode` elements.

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`

Method Detail

### second

    public NodeComparator second(Comparator<ICoverageNode> second)

  Creates a new composite comparator with a second search criterion.

  Parameters:
    `second` - second criterion comparator
  Returns:
    composite comparator

### sort

    public <T extends ICoverageNode> List<T> sort(Collection<T> summaries)

  Returns a sorted copy of the given collection of `ICoverageNode` elements.

  Type Parameters:
    `T` - actual type of the elements
  Parameters:
    `summaries` - collection to create a copy of
  Returns:
    sorted copy

### compare

    public int compare(ICoverageNode n1,
                       ICoverageNode n2)

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

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009-2013 Mountainminds GmbH & Co. KG. All Rights Reserved.