Interface MetricKey<N extends Node>

  • Type Parameters:
    N - Type of nodes the metric can be computed on

    public interface MetricKey<N extends Node>
    Key identifying a metric. Such keys must implement the hashCode method. Enums are well fitted to serve as metric keys.
    Since:
    5.8.0
    Author:
    Clément Fournier
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      Metric<N> getCalculator()
      Returns the object used to calculate the metric.
      java.lang.String name()
      Returns the name of the metric.
      boolean supports​(N node)
      Returns true if the metric held by this key can be computed on this node.
    • Method Detail

      • name

        java.lang.String name()
        Returns the name of the metric.
        Returns:
        The name of the metric
      • getCalculator

        Metric<N> getCalculator()
        Returns the object used to calculate the metric.
        Returns:
        The calculator
      • supports

        boolean supports​(N node)
        Returns true if the metric held by this key can be computed on this node.
        Parameters:
        node - The node to test
        Returns:
        Whether or not the metric can be computed on this node