Package sc.fiji.snt.analysis.curation
Record Class PlausibilityCheck.Warning
java.lang.Object
java.lang.Record
sc.fiji.snt.analysis.curation.PlausibilityCheck.Warning
- Record Components:
checkName- the name of the check that produced this warningseverity- the severity levelmessage- human-readable description of the issuelocation- the spatial location of the issue (may benull)affectedPaths- the paths involved in this warning (nevernull, may be empty)value- the measured value that triggered the warningthreshold- the threshold that was exceededimpact- normalized fraction in[0, 1]indicating what portion of the reconstruction is affected if this warning is a true error.Double.NaNwhen not yet computed. SeePlausibilityCheck.ImpactKind.
- All Implemented Interfaces:
Comparable<PlausibilityCheck.Warning>
- Enclosing class:
PlausibilityCheck
public static record PlausibilityCheck.Warning(String checkName, PlausibilityCheck.Severity severity, String message, PointInImage location, List<Path> affectedPaths, double value, double threshold, double impact)
extends Record
implements Comparable<PlausibilityCheck.Warning>
A plausibility warning produced by a check.
-
Constructor Summary
ConstructorsConstructorDescriptionWarning(String checkName, PlausibilityCheck.Severity severity, String message, PointInImage location, List<Path> affectedPaths, double value, double threshold) Convenience constructor for callers that don't yet know the impact (filled in later byPlausibilityMonitor).Warning(String checkName, PlausibilityCheck.Severity severity, String message, PointInImage location, List<Path> affectedPaths, double value, double threshold, double impact) Compact constructor: guarantees affectedPaths is never null. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theaffectedPathsrecord component.Returns the value of thecheckNamerecord component.intfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.doubleimpact()Returns the value of theimpactrecord component.location()Returns the value of thelocationrecord component.message()Returns the value of themessagerecord component.severity()Returns the value of theseverityrecord component.doubleReturns the value of thethresholdrecord component.final StringtoString()Returns a string representation of this record class.doublevalue()Returns the value of thevaluerecord component.withImpact(double newImpact) Returns a copy of this warning withimpactreplaced.
-
Constructor Details
-
Warning
public Warning(String checkName, PlausibilityCheck.Severity severity, String message, PointInImage location, List<Path> affectedPaths, double value, double threshold, double impact) Compact constructor: guarantees affectedPaths is never null. -
Warning
public Warning(String checkName, PlausibilityCheck.Severity severity, String message, PointInImage location, List<Path> affectedPaths, double value, double threshold) Convenience constructor for callers that don't yet know the impact (filled in later byPlausibilityMonitor).
-
-
Method Details
-
withImpact
Returns a copy of this warning withimpactreplaced. -
compareTo
- Specified by:
compareToin interfaceComparable<PlausibilityCheck.Warning>
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
checkName
Returns the value of thecheckNamerecord component.- Returns:
- the value of the
checkNamerecord component
-
severity
Returns the value of theseverityrecord component.- Returns:
- the value of the
severityrecord component
-
message
Returns the value of themessagerecord component.- Returns:
- the value of the
messagerecord component
-
location
Returns the value of thelocationrecord component.- Returns:
- the value of the
locationrecord component
-
affectedPaths
Returns the value of theaffectedPathsrecord component.- Returns:
- the value of the
affectedPathsrecord component
-
value
public double value()Returns the value of thevaluerecord component.- Returns:
- the value of the
valuerecord component
-
threshold
public double threshold()Returns the value of thethresholdrecord component.- Returns:
- the value of the
thresholdrecord component
-
impact
public double impact()Returns the value of theimpactrecord component.- Returns:
- the value of the
impactrecord component
-