Package de.obqo.decycle.check
Class SlicedConstraint
- java.lang.Object
-
- de.obqo.decycle.check.SlicedConstraint
-
- All Implemented Interfaces:
Constraint
- Direct Known Subclasses:
DirectLayeringConstraint,LayeringConstraint
public abstract class SlicedConstraint extends Object implements Constraint
ASlicedConstraintrepresents some dependency rules for the slices of aSlicing. Such constraint is defined by a list oflayers, each containing a set of slices (i.e. a set of slice node names). The actual dependencies in aSlicingmust match the dependencies defined by this constraint and its layers.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface de.obqo.decycle.check.Constraint
Constraint.Violation
-
-
Constructor Summary
Constructors Constructor Description SlicedConstraint(SliceType sliceType, List<Layer> layers, String arrow)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected booleancontainsBothNodes(int i, int j)StringgetShortString()protected intindexOf(Node node)protected abstract booleanisViolatedBy(Edge edge)protected booleannodesAreInTheSameOneOfLayer(int i, int j)protected booleannodesAreInWrongOrder(int i, int j)StringtoString()List<Constraint.Violation>violations(SlicingSource slicingSource)
-
-
-
Method Detail
-
isViolatedBy
protected abstract boolean isViolatedBy(Edge edge)
-
indexOf
protected final int indexOf(Node node)
-
containsBothNodes
protected final boolean containsBothNodes(int i, int j)
-
nodesAreInWrongOrder
protected final boolean nodesAreInWrongOrder(int i, int j)
-
nodesAreInTheSameOneOfLayer
protected final boolean nodesAreInTheSameOneOfLayer(int i, int j)
-
violations
public List<Constraint.Violation> violations(SlicingSource slicingSource)
- Specified by:
violationsin interfaceConstraint
-
getShortString
public String getShortString()
- Specified by:
getShortStringin interfaceConstraint
-
-