Interface IViolationSummary
- All Known Implementing Classes:
ViolationSummary
public interface IViolationSummary
This interface provides methods which allow to get information on the summary about the
IViolation
, time, distance, type
and cost.
An instance of the class ViolationSummary
will capture all violations of an
ILogicEntityRoute
. For example if
the maximal allowed distance of a CapacityResource
is violated the number of total violations (numViolations) and the number of distance violations
(numViolationsRouteDistance) will be incremented. In addition, a normalized cost will be calculated. It is important
to calculate this normalized cost to add up the costs of different violations to a total cost. The higher this
total cost is the lower is the likeness that this route is the optimal route. The optimization
process always tries to minimize this total cost.
- Since:
- 26/07/2018
- Version:
- 14/10/2019
- Author:
- DNA
-
Method Summary
Modifier and TypeMethodDescriptiondouble
Gets the costs after theAnchorNode
that were caused by theOptimizer
puttingNodes
after theanchor Node
, which might happen because theRoute
is very full.double
Gets the cost for banningResources
.double
Gets the total cost added bycapacity violations
in pickup and delivery optimizations, usually for not having loaded enough or for having loaded too much.double
double
Gets the cost forcolor capacity usage
.double
Gets the total cost added for the distance.double
Gets the total cost added for being too early.double
Deprecated.double
Gets the cost forrestrictions
that do not have their own violation.double
Gets the total cost added for being too late.double
Gets the cost for not getting themandatory Resource
.double
Gets the cost for being abovemax route distance
double
Gets the cost for being abovemax route time
.double
Gets miscellaneous costs.double
double
Gets cost caused byNode type
.double
Gets cost forpreferred Resource constraints
.double
Gets total cost added byrelationship violations
.double
Gets the cost forResources
being out of workdouble
double
Gets the cost forroute time
.double
Gets the cost for staying overtimedouble
Gets thecost
oftime compactness
.double
Gets the cost for not getting thepreferred Resource
.double
Deprecated.double
Gets theNode fix costs
.int
Gets the number ofIViolation
, the default value is 0.int
Gets the number ofIViolation
that were caused by theOptimizer
puttingNodes
after theanchor Node
, which might happen because theRoute
is very full.int
Gets the number ofIViolation
that were caused byINodeColor
capacity.int
Deprecated.int
int
Gets the number ofIViolation
that were caused by theNode
time window, the default value is 0.int
Gets the number ofIViolation
that were caused by being too early, the default value is 0.int
Gets the number ofIViolation
that were caused by being too late, the default value is 0.int
Gets the number ofIViolation
that were caused by theNode type
, the default value is 0.int
Gets the number ofIViolation
that were caused byrelationships
, the default value is 0.int
Gets the number ofIViolation
that were caused by routecapacity
, the default value is 0.int
Gets the number ofIViolation
that were caused by route distance, the default value is 0.int
Gets the number ofIViolation
that were caused when theResource
was working longer than the allowedmaximal working time
.double
Gets theResource fix costs
.double
Gets the fix cost forResources
that have to do aovernight stay
.int
Gets total time that aResource
was early inseconds
.int
Gets total time that aResurce
was late inseconds
.
-
Method Details
-
getNumViolations
int getNumViolations()Gets the number ofIViolation
, the default value is 0.- Returns:
- the numViolations
-
getNumViolationsRouteTime
int getNumViolationsRouteTime()Gets the number ofIViolation
that were caused when theResource
was working longer than the allowedmaximal working time
.- Returns:
- the int number of route time violations
- See Also:
-
getNumViolationsRouteDistance
int getNumViolationsRouteDistance()Gets the number ofIViolation
that were caused by route distance, the default value is 0.- Returns:
- the int number of route distance violations
-
getNumViolationsRouteCapacity
int getNumViolationsRouteCapacity()Gets the number ofIViolation
that were caused by routecapacity
, the default value is 0.- Returns:
- int number of route capacity violations
-
getNumViolationsNodeTimewindow
int getNumViolationsNodeTimewindow()Gets the number ofIViolation
that were caused by theNode
time window, the default value is 0.- Returns:
- int number of node time window violations
-
getNumViolationsNodeTimewindowEarly
int getNumViolationsNodeTimewindowEarly()Gets the number ofIViolation
that were caused by being too early, the default value is 0.- Returns:
- int number of violations for being too early
-
getNumViolationsNodeTimewindowLate
int getNumViolationsNodeTimewindowLate()Gets the number ofIViolation
that were caused by being too late, the default value is 0.- Returns:
- int number of violations for being too late
-
getNumViolationsNodeType
int getNumViolationsNodeType()Gets the number ofIViolation
that were caused by theNode type
, the default value is 0.- Returns:
- int number of violations because of the node type
-
getNumViolationsRelationships
int getNumViolationsRelationships()Gets the number ofIViolation
that were caused byrelationships
, the default value is 0.- Returns:
- int number of relationship violations
-
getNumViolationsDailyBreak
Deprecated.Gets the number ofIViolation
that were caused by breaks, the default value is 0.- Returns:
- int number of break violations
-
getNumViolationsColorNodeCapacity
int getNumViolationsColorNodeCapacity()Gets the number ofIViolation
that were caused byINodeColor
capacity.- Returns:
- the int number of nodeColorCapacity violations
-
getNumViolationsAfterEndAnchor
int getNumViolationsAfterEndAnchor()Gets the number ofIViolation
that were caused by theOptimizer
puttingNodes
after theanchor Node
, which might happen because theRoute
is very full.- Returns:
- the int number of violations after the anchor node
-
getNumViolationsMissedServiceHours
int getNumViolationsMissedServiceHours() -
getCostMissedServiceHour
double getCostMissedServiceHour() -
getTotalLateTime
int getTotalLateTime()Gets total time that aResurce
was late inseconds
.- Returns:
- the int total late time
-
getTotalEarlyTime
int getTotalEarlyTime()Gets total time that aResource
was early inseconds
.- Returns:
- int total early time
-
getCostEarly
double getCostEarly()Gets the total cost added for being too early.- Returns:
- the double early cost
-
getCostLate
double getCostLate()Gets the total cost added for being too late.- Returns:
- the double late cost
-
getCostCapacity
double getCostCapacity()Gets the total cost added bycapacity violations
in pickup and delivery optimizations, usually for not having loaded enough or for having loaded too much.- Returns:
- the double cost for capacity violations
-
getCostRelationship
double getCostRelationship()Gets total cost added byrelationship violations
.- Returns:
- the double cost for relationship violations
-
getCostDistance
double getCostDistance()Gets the total cost added for the distance.- Returns:
- the double cost for distance
-
getCostMaxRouteDistance
double getCostMaxRouteDistance()Gets the cost for being abovemax route distance
- Returns:
- the costMaxRouteDistance
-
getCostMaxRouteTime
double getCostMaxRouteTime()Gets the cost for being abovemax route time
.- Returns:
- the costMaxRouteTime
-
getCostNodeType
double getCostNodeType()Gets cost caused byNode type
.- Returns:
- the double cost
-
getCostPreferredResource
double getCostPreferredResource()Gets cost forpreferred Resource constraints
.- Returns:
- the double cost
-
getCostRouteTime
double getCostRouteTime()Gets the cost forroute time
.- Returns:
- the double cost
-
getCostUnPreferredResource
double getCostUnPreferredResource()Gets the cost for not getting thepreferred Resource
.- Returns:
- the double cost
-
getCostMandatoryResource
double getCostMandatoryResource()Gets the cost for not getting themandatory Resource
.- Returns:
- the double cost
-
getCostBannedResource
double getCostBannedResource()Gets the cost for banningResources
.- Returns:
- the costBannedResource
-
getCostTimeCompactness
double getCostTimeCompactness()Gets thecost
oftime compactness
.Time compactness
is when theOptimizers
tries to make Resources visitNodes
at the beginning of theirOpeningHours
.- Returns:
- the costTimeCompactness
-
getResourceFixCost
double getResourceFixCost()Gets theResource fix costs
.- Returns:
- the double cost
-
getCostGeoUnclustered
Deprecated.GetsViolationSummary.costGeoUnclustered
, the default value is 0.0.- Returns:
- the costGeoUnclustered
-
getIMoveCost
Deprecated.Gets theViolationSummary.costIMove
, the default value is 0.0.- Returns:
- the costIMove
-
getStayOutFixCost
double getStayOutFixCost()Gets the fix cost forResources
that have to do aovernight stay
.- Returns:
- the double cost
-
getNodeFixCost
double getNodeFixCost()Gets theNode fix costs
.- Returns:
- the double cost
-
getCostResourceOutOfWork
double getCostResourceOutOfWork()Gets the cost forResources
being out of work- Returns:
- the double cost
-
getCostStayOvertime
double getCostStayOvertime()Gets the cost for staying overtime- Returns:
- the double cost
-
getCostInjectedRestriction
double getCostInjectedRestriction()Gets the cost forrestrictions
that do not have their own violation. This is used as a bucket forrestriction costs
.- Returns:
- the double cost
-
getCostMisc
double getCostMisc()Gets miscellaneous costs.- Returns:
- the double cost
-
getCostColorCapacityUsage
double getCostColorCapacityUsage()Gets the cost forcolor capacity usage
.- Returns:
- the double cost
-
getCostAfterEndAnchor
double getCostAfterEndAnchor()Gets the costs after theAnchorNode
that were caused by theOptimizer
puttingNodes
after theanchor Node
, which might happen because theRoute
is very full.- Returns:
- the double cost
-
getCostRouteDistancePattern
double getCostRouteDistancePattern() -
getCostCapacityOverload
double getCostCapacityOverload()
-