java.lang.Object
java.lang.Record
st.orm.IntegrityViolation.Length
- Record Components:
table- the table the column belongs to, ornullwhen it is not known.type- the entity type of the write, ornullwhen it is not known.fields- the field of the column; empty when the database does not name it.maxLength- the column's length in characters, known for a violationvalidatefound;nullfor one the database reported.
- All Implemented Interfaces:
IntegrityViolation
- Enclosing interface:
IntegrityViolation
public static record IntegrityViolation.Length(@Nullable String table, @Nullable Class<? extends Data> type, List<Metamodel<?,?>> fields, @Nullable Integer maxLength)
extends Record
implements IntegrityViolation
A string longer than its column. SQL state
22001, string data right truncation. A column's length is
no named constraint.- Since:
- 1.16
-
Nested Class Summary
Nested classes/interfaces inherited from interface st.orm.IntegrityViolation
IntegrityViolation.Check, IntegrityViolation.ForeignKey, IntegrityViolation.Length, IntegrityViolation.NotNull, IntegrityViolation.NumericRange, IntegrityViolation.Referenced, IntegrityViolation.Unique -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.fields()Returns the value of thefieldsrecord component.final inthashCode()Returns a hash code value for this object.@Nullable IntegerReturns the value of themaxLengthrecord component.@Nullable Stringtable()Returns the value of thetablerecord component.final StringtoString()Returns a string representation of this record class.type()Returns the value of thetyperecord component.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface st.orm.IntegrityViolation
constraint, on
-
Constructor Details
-
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). -
table
Returns the value of thetablerecord component.- Specified by:
tablein interfaceIntegrityViolation- Returns:
- the value of the
tablerecord component
-
type
Returns the value of thetyperecord component.- Specified by:
typein interfaceIntegrityViolation- Returns:
- the value of the
typerecord component
-
fields
Returns the value of thefieldsrecord component.- Specified by:
fieldsin interfaceIntegrityViolation- Returns:
- the value of the
fieldsrecord component
-
maxLength
Returns the value of themaxLengthrecord component.- Returns:
- the value of the
maxLengthrecord component
-