Package io.jmix.datatools.datamodel
Record Class AttributeDescriptor
java.lang.Object
java.lang.Record
io.jmix.datatools.datamodel.AttributeDescriptor
- Record Components:
name- attribute namejavaType- displayed Java typemandatory- whether a value is requireddynamic- whether the attribute is defined at runtime rather than on the classpathcolumn- physical column, ornullwhen the attribute has no column of its ownnoColumnText- text shown in place of a column name whencolumnisnullrelation- relation to another entity, ornullwhen the attribute is not a reference
@NullMarked
public record AttributeDescriptor(String name, String javaType, boolean mandatory, boolean dynamic, @Nullable AttributeDescriptor.ColumnDescriptor column, @Nullable String noColumnText, @Nullable AttributeDescriptor.RelationDescriptor relation)
extends Record
Description of an attribute contributed to the data model.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordPhysical column of a contributed attribute.static final recordRelation declared by a contributed attribute. -
Constructor Summary
ConstructorsConstructorDescriptionAttributeDescriptor(String name, String javaType, boolean mandatory, boolean dynamic, @Nullable AttributeDescriptor.ColumnDescriptor column, @Nullable String noColumnText, @Nullable AttributeDescriptor.RelationDescriptor relation) Creates an instance of aAttributeDescriptorrecord class. -
Method Summary
Modifier and TypeMethodDescription@Nullable AttributeDescriptor.ColumnDescriptorcolumn()Returns the value of thecolumnrecord component.booleandynamic()Returns the value of thedynamicrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.javaType()Returns the value of thejavaTyperecord component.booleanReturns the value of themandatoryrecord component.name()Returns the value of thenamerecord component.@Nullable StringReturns the value of thenoColumnTextrecord component.@Nullable AttributeDescriptor.RelationDescriptorrelation()Returns the value of therelationrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
AttributeDescriptor
public AttributeDescriptor(String name, String javaType, boolean mandatory, boolean dynamic, @Nullable AttributeDescriptor.ColumnDescriptor column, @Nullable String noColumnText, @Nullable AttributeDescriptor.RelationDescriptor relation) Creates an instance of aAttributeDescriptorrecord class.- Parameters:
name- the value for thenamerecord componentjavaType- the value for thejavaTyperecord componentmandatory- the value for themandatoryrecord componentdynamic- the value for thedynamicrecord componentcolumn- the value for thecolumnrecord componentnoColumnText- the value for thenoColumnTextrecord componentrelation- the value for therelationrecord 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 '=='. -
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
javaType
Returns the value of thejavaTyperecord component.- Returns:
- the value of the
javaTyperecord component
-
mandatory
public boolean mandatory()Returns the value of themandatoryrecord component.- Returns:
- the value of the
mandatoryrecord component
-
dynamic
public boolean dynamic()Returns the value of thedynamicrecord component.- Returns:
- the value of the
dynamicrecord component
-
column
Returns the value of thecolumnrecord component.- Returns:
- the value of the
columnrecord component
-
noColumnText
Returns the value of thenoColumnTextrecord component.- Returns:
- the value of the
noColumnTextrecord component
-
relation
Returns the value of therelationrecord component.- Returns:
- the value of the
relationrecord component
-