Record Class FieldAndJoinTable
java.lang.Object
java.lang.Record
com.kingsrook.qqq.backend.core.model.metadata.fields.FieldAndJoinTable
Wrapper (record) that holds a QFieldMetaData and a QTableMetaData -
With a factory method (`get()`) to go from the use-case of, a String that's
"joinTable.fieldName" or "fieldName" to the pair.
Note that the "joinTable" member here - could be the "mainTable" passed in
to that `get()` method.
-
Constructor Summary
ConstructorsConstructorDescriptionFieldAndJoinTable(QFieldMetaData field, QTableMetaData joinTable) Creates an instance of aFieldAndJoinTablerecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.field()Returns the value of thefieldrecord component.static FieldAndJoinTableget(QTableMetaData mainTable, String fieldName) given a table, and a field-name string (which should either be the name of a field on that table, or another tableName + "." + fieldName (from that table) - get back the pair of table invalid input: '&' field metaData that the input string is talking about.static FieldAndJoinTableget(QTableMetaData mainTable, String fieldName, Collection<QueryJoin> queryJoins) given a table, and a field-name string (which should either be the name of a field on that table, or another tableName + "." + fieldName (from that table - or an alias insteaad of tableName) - get back the pair of table invalid input: '&' field metaData that the input string is talking about.getLabel(QTableMetaData mainTable) final inthashCode()Returns a hash code value for this object.Returns the value of thejoinTablerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
FieldAndJoinTable
Creates an instance of aFieldAndJoinTablerecord class.- Parameters:
field- the value for thefieldrecord componentjoinTable- the value for thejoinTablerecord component
-
-
Method Details
-
get
given a table, and a field-name string (which should either be the name of a field on that table, or another tableName + "." + fieldName (from that table) - get back the pair of table invalid input: '&' field metaData that the input string is talking about.- Throws:
QException
-
get
public static FieldAndJoinTable get(QTableMetaData mainTable, String fieldName, Collection<QueryJoin> queryJoins) throws QException given a table, and a field-name string (which should either be the name of a field on that table, or another tableName + "." + fieldName (from that table - or an alias insteaad of tableName) - get back the pair of table invalid input: '&' field metaData that the input string is talking about.- Throws:
QException
-
getLabel
-
toString
-
hashCode
-
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). -
field
Returns the value of thefieldrecord component.- Returns:
- the value of the
fieldrecord component
-
joinTable
Returns the value of thejoinTablerecord component.- Returns:
- the value of the
joinTablerecord component
-