Plugins API documentation: Interface MetricsPlugin

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

## com.togethersoft.modules.qa.api
Interface MetricsPlugin

All Superinterfaces:
  Plugin

All Known Implementing Classes:
  MetricsPluginImpl

public interface MetricsPlugin
extends Plugin

Field Summary
`static java.lang.String` | `AGGR_AVERAGE` Result for enclosing object equas the arithmetic average of the results of its parts
`static java.lang.String` | `AGGR_MAXIMUM` Result for enclosing object equas the maximum result of its parts
`static java.lang.String` | `AGGR_MEDIAN`
`static java.lang.String` | `AGGR_MINIMUM` Result for enclosing object equas the minimum result of its parts
`static java.lang.String` | `AGGR_NONE` No aggregation
`static java.lang.String` | `AGGR_SUM` Result for enclosing object equas the sum of the results of its parts
`static int` | `SCOPE_CLASS` specifies that plugin results may be applied to the classes
`static int` | `SCOPE_PROJECT` specifies that plugin results may be applied only to the whole project

Method Summary
`java.lang.String` | `getDefaultAggregation()` Gets default aggregation for plugin.
`int` | `getDefaultLowerLimit()` Gets default lower limit value
`int` | `getDefaultUpperLimit()` Gets default upper limit value
`int` | `getScope()` Gets the scope on which plugin results are applicable.
`boolean` | `run(com.togethersoft.openapi.sci.SciObject obj, MetricsResult result)` Plugin entry point It is invoked for every package and every class selected in diagram as well as for each their subpackage and subclass.

Methods inherited from interface com.togethersoft.modules.qa.api.Plugin
`canProcessByteCode, createOptionsPane, getAbbreviation, getDefaultChoice, getDescriptionFileName, getGroupName, getOptionsPane, getPropertiesFileName, getTitle, load, prepare, restoreOptions, storeOptions`

Field Detail

### SCOPE_CLASS

    public static final int SCOPE_CLASS

  specifies that plugin results may be applied to the classes

### SCOPE_PROJECT

    public static final int SCOPE_PROJECT

  specifies that plugin results may be applied only to the whole project

### AGGR_NONE

    public static final java.lang.String AGGR_NONE

  No aggregation

### AGGR_SUM

    public static final java.lang.String AGGR_SUM

  Result for enclosing object equas the sum of the results of its parts

### AGGR_AVERAGE

    public static final java.lang.String AGGR_AVERAGE

  Result for enclosing object equas the arithmetic average of the results of its parts

### AGGR_MINIMUM

    public static final java.lang.String AGGR_MINIMUM

  Result for enclosing object equas the minimum result of its parts

### AGGR_MAXIMUM

    public static final java.lang.String AGGR_MAXIMUM

  Result for enclosing object equas the maximum result of its parts

### AGGR_MEDIAN

    public static final java.lang.String AGGR_MEDIAN

Method Detail

### run

    public boolean run(com.togethersoft.openapi.sci.SciObject obj,
                       MetricsResult result)

  Plugin entry point It is invoked for every package and every class selected in diagram as well as for each their subpackage and subclass.
  Parameters:
    `obj` - Source Code Interface object to process
    `result` - object to store processing results If returns `false`, further processing is stopped.
  Returns:
    `true` to proceed further objects, otherwise `false`

### getScope

    public int getScope()

  Gets the scope on which plugin results are applicable. It may be `SCOPE_PROJECT` or `SCOPE_CLASS`.
  Returns:
    `SCOPE_CLASS` if plugin results may be applied to the classes or `SCOPE_PROJECT` if they can be applied only to the whole project.

### getDefaultLowerLimit

    public int getDefaultLowerLimit()

  Gets default lower limit value
  Returns:
    default lower limit value

### getDefaultUpperLimit

    public int getDefaultUpperLimit()

  Gets default upper limit value
  Returns:
    default upper limit value

### getDefaultAggregation

    public java.lang.String getDefaultAggregation()

  Gets default aggregation for plugin. May be on of `AGGR_NONE`, `AGGR_SUM`, `AGGR_AVERAGE`, `AGGR_MINIMUM`, `AGGR_MAXIMUM` or `AGGR_MEDIAN`
  Returns:
    default aggregation

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