Package su.onno.ui
Record Class ActionSpec.FormDefaults
java.lang.Object
java.lang.Record
su.onno.ui.ActionSpec.FormDefaults
- Enclosing class:
ActionSpec
public static record ActionSpec.FormDefaults(Map<String,String> values, Map<String,List<Map<String,String>>> rows)
extends Record
Values an action form opens with, computed server-side at open time by the
formDefaults hook: values seed the
scalar inputs (keyed by input key), rows seed the row groups (keyed by group key,
each row a column → value map — the same wire shape the form submits back). Either
map may be empty; a key the form doesn't declare is ignored by the client.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.static ActionSpec.FormDefaultsDefaults carrying only row-group rows.static ActionSpec.FormDefaultsDefaults carrying only scalar input values.rows()Returns the value of therowsrecord component.final StringtoString()Returns a string representation of this record class.values()Returns the value of thevaluesrecord component.
-
Constructor Details
-
FormDefaults
Creates an instance of aFormDefaultsrecord class.- Parameters:
values- the value for thevaluesrecord componentrows- the value for therowsrecord component
-
-
Method Details
-
ofRows
Defaults carrying only row-group rows. -
ofValues
Defaults carrying only scalar input values. -
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). -
values
Returns the value of thevaluesrecord component.- Returns:
- the value of the
valuesrecord component
-
rows
Returns the value of therowsrecord component.- Returns:
- the value of the
rowsrecord component
-