java.lang.Object
java.lang.Record
org.itsallcode.jdbc.identifier.QualifiedIdentifier
- Record Components:
id
- list of identifiers
- All Implemented Interfaces:
Identifier
A qualified identifier, e.g. table name and schema name.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of aQualifiedIdentifier
record class. -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.id()
Returns the value of theid
record component.static Identifier
Create a new qualified identifier.static Identifier
of
(Identifier... ids) Create a new qualified identifier.quote()
Put the name in quotes.toString()
Returns a string representation of this record class.
-
Constructor Details
-
QualifiedIdentifier
Creates an instance of aQualifiedIdentifier
record class.- Parameters:
id
- the value for theid
record component
-
-
Method Details
-
of
Create a new qualified identifier.- Parameters:
ids
- the IDs- Returns:
- a new instance
-
of
Create a new qualified identifier.- Parameters:
ids
- the simple IDs- Returns:
- a new instance
-
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.- Specified by:
toString
in interfaceIdentifier
- Specified by:
toString
in classRecord
- Returns:
- a string representation of this object
-
quote
Description copied from interface:Identifier
Put the name in quotes.- Specified by:
quote
in interfaceIdentifier
- Returns:
- quoted name
-
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)
. -
id
Returns the value of theid
record component.- Returns:
- the value of the
id
record component
-