Module litebridge.orm
Package org.litebridgedb.orm.expression
Record Class ProtoNestableBasicExprSpec
java.lang.Object
java.lang.Record
org.litebridgedb.orm.expression.ProtoNestableBasicExprSpec
- Record Components:
type- The type of expression to create.target- The target expression; typically a column name to select viaSelectColumnSpecorSelectFieldSpec.alias- The column alias to use, ornullif not specified.
- All Implemented Interfaces:
ExpressionSpec,ProtoExpressionSpec,ProtoNestableExpressionSpec,Resolvable
public record ProtoNestableBasicExprSpec(Class<? extends ExpressionSpec> type, ProtoExpressionSpec target, @Nullable String alias)
extends Record
implements ProtoNestableExpressionSpec
Proto-expression that allows nesting other proto-expressions.
This record is used to create a nested chain of expression instances (e.g. UpperSpec) when table information is available.
-
Constructor Summary
ConstructorsConstructorDescriptionProtoNestableBasicExprSpec(Class<? extends ExpressionSpec> type, String column, @Nullable String alias) Constructs a new ProtoNestableBasicExprSpec instance via column name.ProtoNestableBasicExprSpec(Class<? extends ExpressionSpec> type, ProtoExpressionSpec target, @Nullable String alias) Creates an instance of aProtoNestableBasicExprSpecrecord class. -
Method Summary
Modifier and TypeMethodDescription@Nullable Stringalias()Returns the value of thealiasrecord component.@Nullable Object @Nullable []args()Gets any extra expression-specific arguments.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.target()Returns the value of thetargetrecord component.final StringtoString()Returns a string representation of this record class.Class<? extends ExpressionSpec> 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 org.litebridgedb.orm.expression.ProtoNestableExpressionSpec
column
-
Constructor Details
-
ProtoNestableBasicExprSpec
public ProtoNestableBasicExprSpec(Class<? extends ExpressionSpec> type, ProtoExpressionSpec target, @Nullable String alias) Creates an instance of aProtoNestableBasicExprSpecrecord class. -
ProtoNestableBasicExprSpec
public ProtoNestableBasicExprSpec(Class<? extends ExpressionSpec> type, String column, @Nullable String alias) Constructs a new ProtoNestableBasicExprSpec instance via column name.- Parameters:
type- The type of expression to create.column- The target column name to select.alias- The column alias to use, ornullif not specified.
-
-
Method Details
-
args
Description copied from interface:ProtoExpressionSpecGets any extra expression-specific arguments.- Specified by:
argsin interfaceProtoExpressionSpec- Returns:
- the extra arguments, or
nullif none
-
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). -
type
Returns the value of thetyperecord component.- Specified by:
typein interfaceResolvable- Returns:
- the value of the
typerecord component
-
target
Returns the value of thetargetrecord component.- Specified by:
targetin interfaceProtoNestableExpressionSpec- Returns:
- the value of the
targetrecord component
-
alias
Returns the value of thealiasrecord component.- Specified by:
aliasin interfaceProtoExpressionSpec- Returns:
- the value of the
aliasrecord component
-