Class Violation
java.lang.Object
com.dna.jopt.member.unit.violation.Violation
- All Implemented Interfaces:
IViolation,Serializable,Cloneable
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopy()Gets the attribute.Gets the category.intgetCode()Gets the code that is identifying this IViolationGets thesubAttribute.getValue()Deprecated.Gets the routes, which are triggering the violation.Gets theviolationActors.Gets the violation description.Gets theviolationValue, the default value is"".voidSets the value.voidsetViolationActorRoutes(List<ILogicEntityRoute> routes) Sets the routes, which are triggering the violation.voidsetViolationActors(List<IOptimizationElement> elements) Gets theviolationActors.toString()Returns thecategory, theattribute, thevalueand theviolationValue.
-
Constructor Details
-
Violation
-
-
Method Details
-
setViolationActors
Description copied from interface:IViolationGets theviolationActors.- Specified by:
setViolationActorsin interfaceIViolation- Parameters:
elements- the arrayList containing IOptimizationElements
-
getViolationActors
Description copied from interface:IViolationGets theviolationActors.- Specified by:
getViolationActorsin interfaceIViolation- Returns:
- the arraylist violationActors containing IOptimizationElements
-
setViolationActorRoutes
Description copied from interface:IViolationSets the routes, which are triggering the violation.- Specified by:
setViolationActorRoutesin interfaceIViolation- Parameters:
routes- the new violation actor routes
-
getViolationActorRoutes
Description copied from interface:IViolationGets the routes, which are triggering the violation. This method may return an empty list even though violations are present- Specified by:
getViolationActorRoutesin interfaceIViolation- Returns:
- the violation actor routes
-
getCategory
Description copied from interface:IViolationGets the category.- Specified by:
getCategoryin interfaceIViolation- Returns:
- the category
-
getAttribute
Description copied from interface:IViolationGets the attribute.- Specified by:
getAttributein interfaceIViolation- Returns:
- the attribute
-
getSubAttribute
Description copied from interface:IViolationGets thesubAttribute.- Specified by:
getSubAttributein interfaceIViolation- Returns:
- the subAttribute
-
setValue
Description copied from interface:IViolationSets the value.- Specified by:
setValuein interfaceIViolation- Parameters:
violationDesc- the value descviolationValue- the violation value
-
getValue
Deprecated.- Specified by:
getValuein interfaceIViolation- Returns:
- the value
-
getViolationDescription
Description copied from interface:IViolationGets the violation description.- Specified by:
getViolationDescriptionin interfaceIViolation- Returns:
- the violation description
-
getCode
public int getCode()Description copied from interface:IViolationGets the code that is identifying this IViolation- Specified by:
getCodein interfaceIViolation- Returns:
- the code
-
toString
Description copied from interface:IViolationReturns thecategory, theattribute, thevalueand theviolationValue. IfgetViolationActors()is notemptyadds all theidsof all current actors.- Specified by:
toStringin interfaceIViolation- Overrides:
toStringin classObject- Returns:
- category, attribute, value and id of all actors
-
copy
Description copied from interface:IViolation- Specified by:
copyin interfaceIViolation- Returns:
- a copy of the Violation with the category, attribute, value and code
-
getViolationValue
Description copied from interface:IViolationGets theviolationValue, the default value is"".- Specified by:
getViolationValuein interfaceIViolation- Returns:
- the violationvalue
-