Package io.mateu.dtos
Record Class ButtonDto
java.lang.Object
java.lang.Record
io.mateu.dtos.ButtonDto
- All Implemented Interfaces:
ComponentMetadataDto
public record ButtonDto(String label, String iconOnLeft, String iconOnRight, String image, ButtonColorDto color, ButtonVariantDto variant, ButtonStyleDto buttonStyle, ButtonSizeDto size, boolean autofocus, boolean disabled, String actionId, Object parameters)
extends Record
implements ComponentMetadataDto
A button
-
Constructor Summary
ConstructorsConstructorDescriptionButtonDto(String label, String iconOnLeft, String iconOnRight, String image, ButtonColorDto color, ButtonVariantDto variant, ButtonStyleDto buttonStyle, ButtonSizeDto size, boolean autofocus, boolean disabled, String actionId, Object parameters) Creates an instance of aButtonDtorecord class. -
Method Summary
Modifier and TypeMethodDescriptionactionId()Returns the value of theactionIdrecord component.booleanReturns the value of theautofocusrecord component.Returns the value of thebuttonStylerecord component.color()Returns the value of thecolorrecord component.booleandisabled()Returns the value of thedisabledrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of theiconOnLeftrecord component.Returns the value of theiconOnRightrecord component.image()Returns the value of theimagerecord component.label()Returns the value of thelabelrecord component.Returns the value of theparametersrecord component.size()Returns the value of thesizerecord component.final StringtoString()Returns a string representation of this record class.variant()Returns the value of thevariantrecord component.
-
Constructor Details
-
ButtonDto
public ButtonDto(String label, String iconOnLeft, String iconOnRight, String image, ButtonColorDto color, ButtonVariantDto variant, ButtonStyleDto buttonStyle, ButtonSizeDto size, boolean autofocus, boolean disabled, String actionId, Object parameters) Creates an instance of aButtonDtorecord class.- Parameters:
label- the value for thelabelrecord componenticonOnLeft- the value for theiconOnLeftrecord componenticonOnRight- the value for theiconOnRightrecord componentimage- the value for theimagerecord componentcolor- the value for thecolorrecord componentvariant- the value for thevariantrecord componentbuttonStyle- the value for thebuttonStylerecord componentsize- the value for thesizerecord componentautofocus- the value for theautofocusrecord componentdisabled- the value for thedisabledrecord componentactionId- the value for theactionIdrecord componentparameters- the value for theparametersrecord 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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
label
Returns the value of thelabelrecord component.- Returns:
- the value of the
labelrecord component
-
iconOnLeft
Returns the value of theiconOnLeftrecord component.- Returns:
- the value of the
iconOnLeftrecord component
-
iconOnRight
Returns the value of theiconOnRightrecord component.- Returns:
- the value of the
iconOnRightrecord component
-
image
Returns the value of theimagerecord component.- Returns:
- the value of the
imagerecord component
-
color
Returns the value of thecolorrecord component.- Returns:
- the value of the
colorrecord component
-
variant
Returns the value of thevariantrecord component.- Returns:
- the value of the
variantrecord component
-
buttonStyle
Returns the value of thebuttonStylerecord component.- Returns:
- the value of the
buttonStylerecord component
-
size
Returns the value of thesizerecord component.- Returns:
- the value of the
sizerecord component
-
autofocus
public boolean autofocus()Returns the value of theautofocusrecord component.- Returns:
- the value of the
autofocusrecord component
-
disabled
public boolean disabled()Returns the value of thedisabledrecord component.- Returns:
- the value of the
disabledrecord component
-
actionId
Returns the value of theactionIdrecord component.- Returns:
- the value of the
actionIdrecord component
-
parameters
Returns the value of theparametersrecord component.- Returns:
- the value of the
parametersrecord component
-