Class ReferenceResult
java.lang.Object
es.urjc.etsii.grafo.experiment.reference.ReferenceResult
Reference result for an instance
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionSet scoreSet scoreSet scoreGet score if present, never NaN.Get score if present, never NaN.long
Get execution time in nanosecondsdouble
get time in seconds needed to generate this reference valuelong
Get time to best in nanosecondsdouble
get time in seconds needed to generate this reference valueboolean
Is the current reference value returned bygetScores()
optimal?void
setOptimalValue
(boolean isOptimal) Specify if the values provided inaddScores(Map)
is optimal.setTimeInSeconds
(double timeInSeconds) Setter for the fieldtimeInSeconds
.setTimeInSeconds
(String timeInSeconds) Setter for the fieldtimeInSeconds
.setTimeToBestInSeconds
(double timeToBestInSeconds) Setter for the fieldtimeToBestInSeconds
.setTimeToBestInSeconds
(String timeToBestInSeconds) Setter for the fieldtimeToBestInSeconds
.toString()
-
Constructor Details
-
ReferenceResult
public ReferenceResult()
-
-
Method Details
-
getScores
Get score if present, never NaN.- Returns:
- optional score
-
getScore
Get score if present, never NaN.- Returns:
- optional score
-
getTimeInSeconds
public double getTimeInSeconds()get time in seconds needed to generate this reference value- Returns:
- time in seconds
-
getTimeToBestInSeconds
public double getTimeToBestInSeconds()get time in seconds needed to generate this reference value- Returns:
- time to best in seconds
-
addScores
Set score- Parameters:
scores
- score- Returns:
- ReferenceResult
-
addScore
Set score- Parameters:
objectiveName
- objective namescore
- score- Returns:
- ReferenceResult
-
addScore
Set score- Parameters:
objectiveName
- objective namescore
- score- Returns:
- ReferenceResult
-
setTimeInSeconds
Setter for the field
timeInSeconds
.- Parameters:
timeInSeconds
- a double.- Returns:
- ReferenceResult
-
setTimeInSeconds
Setter for the field
timeInSeconds
.- Parameters:
timeInSeconds
- aString
object.- Returns:
- ReferenceResult
-
setTimeToBestInSeconds
Setter for the field
timeToBestInSeconds
.- Parameters:
timeToBestInSeconds
- a double.- Returns:
- ReferenceResult
-
setTimeToBestInSeconds
Setter for the field
timeToBestInSeconds
.- Parameters:
timeToBestInSeconds
- aString
object.- Returns:
- ReferenceResult
-
getTimeInNanos
public long getTimeInNanos()Get execution time in nanoseconds- Returns:
- execution time in nanoseconds
-
getTimeToBestInNanos
public long getTimeToBestInNanos()Get time to best in nanoseconds- Returns:
- time to best in nanoseconds
-
isOptimalValue
public boolean isOptimalValue()Is the current reference value returned bygetScores()
optimal?- Returns:
- True if the value returned by getScore is known to be optimal, false otherwise
-
setOptimalValue
public void setOptimalValue(boolean isOptimal) Specify if the values provided inaddScores(Map)
is optimal. If not specified, defaults to false.- Parameters:
isOptimal
- True if the value returned by getScore is known to be optimal, false otherwise
-
toString
-