Class JdbcQueryColumn
java.lang.Object
com.northconcepts.datapipeline.foundations.core.Bean
com.northconcepts.datapipeline.foundations.jdbc.JdbcQueryColumn
- All Implemented Interfaces:
DataExceptionContributor,JsonSerializable,RecordSerializable,XmlSerializable,Serializable
Metadata for one result column of a
JdbcQuery, read from JDBC ResultSetMetaData by
JdbcConnection.loadQueries().- See Also:
-
Field Summary
FieldsFields inherited from interface com.northconcepts.datapipeline.core.RecordSerializable
SERIALIZED_CLASS_NAME, TYPEFields inherited from interface com.northconcepts.datapipeline.core.XmlSerializable
XML_SERIALIZED_CLASS_NAME -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfromRecord(Record source) Loads this instance's state from a record and returnsthis(for fluid API call chaining).Returns the fully-qualified class name of the values the JDBC driver returns for this column.Class<?> Returns the Java type for the column's values, chosen from the connection's type overrides or SQL-to-Java type mapper.getName()Returns the column label: itsASalias, or its name when there is none.Returns the label as a camel-case Java identifier, e.g.intgetScale()Returns the number of digits to the right of the decimal point (0 where not applicable).intgetSize()Returns the column's maximum width in characters (the JDBC display size).intReturns the column'sjava.sql.Typescode.booleanbooleanbooleanIndicates if the column is known to allow nulls (false when the driver reports no nulls or unknown).booleanbooleanIndicates if the column can be used in a WHERE clause.booleanisSigned()booleanvoidsetAutoIncrement(boolean autoIncrement) voidsetCatalogName(String catalogName) setClassName(String className) Sets the fully-qualified class name of the values the JDBC driver returns for this column.voidsetCurrency(boolean currency) voidsetDatabaseTypeName(String databaseTypeName) setJavaType(Class<?> javaType) Sets the Java type for the column's values, normally chosen byJdbcConnection.loadQueries().Sets the column label: itsASalias, or its name when there is none.voidsetNullable(boolean nullable) Indicates if the column is known to allow nulls (false when the driver reports no nulls or unknown).voidsetReadOnly(boolean readOnly) voidsetScale(int scale) Sets the number of digits to the right of the decimal point (0 where not applicable).voidsetSchemaName(String schemaName) voidsetSearchable(boolean searchable) Indicates if the column can be used in a WHERE clause.setSigned(boolean signed) voidsetSize(int size) Sets the column's maximum width in characters (the JDBC display size).voidsetSqlType(int sqlType) Sets the column'sjava.sql.Typescode.voidsetTableName(String tableName) voidsetWritable(boolean writable) toRecord()Converts this object's state to a record thatRecordSerializable.fromRecord(Record)can load.Methods inherited from class com.northconcepts.datapipeline.foundations.core.Bean
addExceptionProperties, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.northconcepts.datapipeline.core.DataExceptionContributor
addExceptionProperties, exception, exception, exceptionMethods inherited from interface com.northconcepts.datapipeline.core.RecordSerializable
fromJson, fromJson, toJson, toJson, toJsonMethods inherited from interface com.northconcepts.datapipeline.core.XmlSerializable
fromXml, fromXml, fromXmlElement, toXml, toXml, toXml, toXml, toXml, toXmlElement
-
Field Details
-
NAME_COMPARATOR
-
-
Constructor Details
-
JdbcQueryColumn
public JdbcQueryColumn()
-
-
Method Details
-
getName
Returns the column label: itsASalias, or its name when there is none. -
setName
Sets the column label: itsASalias, or its name when there is none. -
getSqlType
public int getSqlType()Returns the column'sjava.sql.Typescode. -
setSqlType
public void setSqlType(int sqlType) Sets the column'sjava.sql.Typescode. -
getDatabaseTypeName
-
setDatabaseTypeName
-
getSize
public int getSize()Returns the column's maximum width in characters (the JDBC display size). -
setSize
public void setSize(int size) Sets the column's maximum width in characters (the JDBC display size). -
getScale
public int getScale()Returns the number of digits to the right of the decimal point (0 where not applicable). -
setScale
public void setScale(int scale) Sets the number of digits to the right of the decimal point (0 where not applicable). -
isNullable
public boolean isNullable()Indicates if the column is known to allow nulls (false when the driver reports no nulls or unknown). -
setNullable
public void setNullable(boolean nullable) Indicates if the column is known to allow nulls (false when the driver reports no nulls or unknown). -
getTableName
-
setTableName
-
getSchemaName
-
setSchemaName
-
getCatalogName
-
setCatalogName
-
isAutoIncrement
public boolean isAutoIncrement() -
setAutoIncrement
public void setAutoIncrement(boolean autoIncrement) -
isCurrency
public boolean isCurrency() -
setCurrency
public void setCurrency(boolean currency) -
isReadOnly
public boolean isReadOnly() -
setReadOnly
public void setReadOnly(boolean readOnly) -
isSearchable
public boolean isSearchable()Indicates if the column can be used in a WHERE clause. -
setSearchable
public void setSearchable(boolean searchable) Indicates if the column can be used in a WHERE clause. -
isWritable
public boolean isWritable() -
setWritable
public void setWritable(boolean writable) -
getJavaType
Returns the Java type for the column's values, chosen from the connection's type overrides or SQL-to-Java type mapper. -
setJavaType
Sets the Java type for the column's values, normally chosen byJdbcConnection.loadQueries(). -
getNameAsJavaIdentifier
Returns the label as a camel-case Java identifier, e.g.firstNameforFIRST_NAME. -
getClassName
Returns the fully-qualified class name of the values the JDBC driver returns for this column. -
setClassName
Sets the fully-qualified class name of the values the JDBC driver returns for this column. -
isSigned
public boolean isSigned() -
setSigned
-
toRecord
Description copied from interface:RecordSerializableConverts this object's state to a record thatRecordSerializable.fromRecord(Record)can load.- Specified by:
toRecordin interfaceRecordSerializable- Overrides:
toRecordin classBean
-
fromRecord
Description copied from interface:RecordSerializableLoads this instance's state from a record and returnsthis(for fluid API call chaining). For fluid API call chaining, the overridden method should change the declared return type to its class.- Specified by:
fromRecordin interfaceRecordSerializable- Overrides:
fromRecordin classBean- Parameters:
source-- Returns:
- this instance.
-