Package org.umlg.sqlg.structure
Record Class PropertyDefinition
java.lang.Object
java.lang.Record
org.umlg.sqlg.structure.PropertyDefinition
- Record Components:
propertyType
- The type of the propertymultiplicity
- The multiplicity of the propertydefaultLiteral
- The default value of the propertycheckConstraint
- A constraint on valid values for the property.temp
- Only to be used internally. If true then the multiplicity will not be validated.
public record PropertyDefinition(PropertyType propertyType, Multiplicity multiplicity, String defaultLiteral, String checkConstraint, boolean temp)
extends Record
Represents a Vertex or Edge property.
-
Constructor Summary
ConstructorDescriptionPropertyDefinition
(PropertyType propertyType, Multiplicity multiplicity, String defaultLiteral, String checkConstraint, boolean temp) Creates an instance of aPropertyDefinition
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecheckConstraint
record component.Returns the value of thedefaultLiteral
record component.final boolean
Indicates whether some other object is "equal to" this one.static PropertyDefinition
fromNotifyJson
(com.fasterxml.jackson.databind.JsonNode jsonNode) final int
hashCode()
Returns a hash code value for this object.Returns the value of themultiplicity
record component.static PropertyDefinition
of
(PropertyType propertyType) static PropertyDefinition
of
(PropertyType propertyType, Multiplicity multiplicity) static PropertyDefinition
of
(PropertyType propertyType, Multiplicity multiplicity, String defaultLiteral) static PropertyDefinition
of
(PropertyType propertyType, Multiplicity multiplicity, String defaultLiteral, String checkConstraint) Returns the value of thepropertyType
record component.boolean
temp()
Returns the value of thetemp
record component.static PropertyDefinition
temp
(PropertyType propertyType) com.fasterxml.jackson.databind.node.ObjectNode
final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
PropertyDefinition
public PropertyDefinition(PropertyType propertyType, Multiplicity multiplicity, String defaultLiteral, String checkConstraint, boolean temp) Creates an instance of aPropertyDefinition
record class.- Parameters:
propertyType
- the value for thepropertyType
record componentmultiplicity
- the value for themultiplicity
record componentdefaultLiteral
- the value for thedefaultLiteral
record componentcheckConstraint
- the value for thecheckConstraint
record componenttemp
- the value for thetemp
record component
-
-
Method Details
-
of
-
temp
-
of
-
of
public static PropertyDefinition of(PropertyType propertyType, Multiplicity multiplicity, String defaultLiteral) -
of
public static PropertyDefinition of(PropertyType propertyType, Multiplicity multiplicity, String defaultLiteral, String checkConstraint) -
toNotifyJson
public com.fasterxml.jackson.databind.node.ObjectNode toNotifyJson() -
fromNotifyJson
-
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 '=='. -
propertyType
Returns the value of thepropertyType
record component.- Returns:
- the value of the
propertyType
record component
-
multiplicity
Returns the value of themultiplicity
record component.- Returns:
- the value of the
multiplicity
record component
-
defaultLiteral
Returns the value of thedefaultLiteral
record component.- Returns:
- the value of the
defaultLiteral
record component
-
checkConstraint
Returns the value of thecheckConstraint
record component.- Returns:
- the value of the
checkConstraint
record component
-
temp
public boolean temp()Returns the value of thetemp
record component.- Returns:
- the value of the
temp
record component
-