Package net.sourceforge.pmd.lang.metrics
Interface MetricOption
-
public interface MetricOption
Option to pass to a metric. Options modify the behaviour of a metric. You must bundle them into aMetricOptions
to pass them all to a metric.Options must implement hashCode and equals.
Combining options together may be done with a decorator pattern. If you use an AST visitor to compute your metric, look at the Cyclo metric in the Java framework for an example (the decorator pattern is not applicable as is on a visitor, a modified version of it has been implemented for the Java framework).
- Since:
- 6.0.0
- Author:
- Clément Fournier
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description String
name()
Returns the name of the option constant.String
valueName()
Returns the name of the option as it should be used in properties.
-