Package com.codeborne.selenide
Record Class CheckResult
java.lang.Object
java.lang.Record
com.codeborne.selenide.CheckResult
public record CheckResult(CheckResult.Verdict verdict, @Nullable String message, @Nullable Object actualValue, LocalDateTime timestamp)
extends Record
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionCheckResult(boolean checkSucceeded, @Nullable Object actualValue) CheckResult(CheckResult.Verdict verdict, @Nullable Object actualValue) CheckResult(CheckResult.Verdict verdict, @Nullable String message, @Nullable Object actualValue, LocalDateTime timestamp) Creates an instance of aCheckResultrecord class. -
Method Summary
Modifier and TypeMethodDescriptionstatic CheckResultaccepted()static CheckResult@Nullable ObjectReturns the value of theactualValuerecord component.final booleanIndicates whether some other object is "equal to" this one.<T> @Nullable T<T> TgetActualValueOrElse(T defaultValue) getMessageOrElse(Supplier<String> defaultMessage) final inthashCode()Returns a hash code value for this object.@Nullable Stringmessage()Returns the value of themessagerecord component.static CheckResult<T> TReturns the value of thetimestamprecord component.toString()Returns a string representation of this record class.verdict()Returns the value of theverdictrecord component.
-
Constructor Details
-
CheckResult
-
CheckResult
-
CheckResult
public CheckResult(CheckResult.Verdict verdict, @Nullable String message, @Nullable Object actualValue, LocalDateTime timestamp) Creates an instance of aCheckResultrecord class.- Parameters:
verdict- the value for theverdictrecord componentmessage- the value for themessagerecord componentactualValue- the value for theactualValuerecord componenttimestamp- the value for thetimestamprecord component
-
-
Method Details
-
rejected
-
accepted
-
accepted
-
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. -
getMessageOrElse
-
getActualValue
public <T> @Nullable T getActualValue() -
getActualValueOrElse
public <T> T getActualValueOrElse(T defaultValue) -
requireActualValue
public <T> T requireActualValue() -
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. All components in this record class are compared withObjects::equals(Object,Object). -
verdict
Returns the value of theverdictrecord component.- Returns:
- the value of the
verdictrecord component
-
message
Returns the value of themessagerecord component.- Returns:
- the value of the
messagerecord component
-
actualValue
Returns the value of theactualValuerecord component.- Returns:
- the value of the
actualValuerecord component
-
timestamp
Returns the value of thetimestamprecord component.- Returns:
- the value of the
timestamprecord component
-