java.lang.Object
java.lang.Record
no.ntnu.principes.domain.onboarding.OnboardingStep
public record OnboardingStep(String title, String subtitle, javafx.scene.Node content, Supplier<Boolean> validate)
extends Record
Represents a single step in the onboarding process with UI elements and validation.
Each step contains content to display and optional validation logic to determine
if the user can proceed to the next step.
-
Constructor Summary
ConstructorsConstructorDescriptionOnboardingStep(String title, String subtitle, javafx.scene.Node content) Creates an onboarding step with automatic validation pass.OnboardingStep(String title, String subtitle, javafx.scene.Node content, Supplier<Boolean> validate) Creates an instance of aOnboardingSteprecord class. -
Method Summary
Modifier and TypeMethodDescriptionjavafx.scene.Nodecontent()Returns the value of thecontentrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.subtitle()Returns the value of thesubtitlerecord component.title()Returns the value of thetitlerecord component.final StringtoString()Returns a string representation of this record class.validate()Returns the value of thevalidaterecord component.
-
Constructor Details
-
OnboardingStep
Creates an onboarding step with automatic validation pass.- Parameters:
title- The main heading displayed for this stepsubtitle- The secondary text providing additional contextcontent- The JavaFX Node containing the UI elements for this step
-
OnboardingStep
public OnboardingStep(String title, String subtitle, javafx.scene.Node content, Supplier<Boolean> validate) Creates an instance of aOnboardingSteprecord class.- Parameters:
title- the value for thetitlerecord componentsubtitle- the value for thesubtitlerecord componentcontent- the value for thecontentrecord componentvalidate- the value for thevalidaterecord component
-
-
Method Details
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
title
Returns the value of thetitlerecord component.- Returns:
- the value of the
titlerecord component
-
subtitle
Returns the value of thesubtitlerecord component.- Returns:
- the value of the
subtitlerecord component
-
content
public javafx.scene.Node content()Returns the value of thecontentrecord component.- Returns:
- the value of the
contentrecord component
-
validate
Returns the value of thevalidaterecord component.- Returns:
- the value of the
validaterecord component
-