Metric: Implements

User Description

The Implements metric is used to get information about how many interfaces are implemented by a function block.

Metric Calculation

A function block can extend exactly one function block and implement multiple interfaces. An interface can extend multiple interfaces, but cannot implement other interfaces.

A function block can implement none or several interfaces. The number of direct implemented interfaces is counted.

NOTE: If the function block extends another function block or an interface extends other interface, the derived implemented interfaces are not considered.

Example

Implements calculation example for IEC-61131-3 code:

FB_Test extends FB_Base implements IF_Test1, IF_Test2

FB_Base implements IF_Test4

IF_Test2 extends IF_Test3, IF_Test5

Implements Results

Implements (FB_Test) = 2
Implements (FB_Base) = 1