public class ColumnDefinitionPacket extends Object implements com.singlestore.jdbc.client.Column, com.singlestore.jdbc.message.ServerMessage
| Constructor and Description |
|---|
ColumnDefinitionPacket(com.singlestore.jdbc.client.ReadableByteBuf buf,
boolean extendedInfo)
Generate object from mysql packet
|
| Modifier and Type | Method and Description |
|---|---|
static ColumnDefinitionPacket |
create(String name,
com.singlestore.jdbc.client.DataType type,
int flags)
Generate column definition from name
|
boolean |
equals(Object o) |
String |
getColumnAlias()
retrieve column alias if any
|
String |
getColumnName()
retrieve column name if any
|
int |
getColumnType(Configuration conf)
return column type from column server type
|
byte |
getDecimals()
get number of decimal
|
Codec<?> |
getDefaultCodec(Configuration conf)
return column codec from column server type
|
int |
getDisplaySize()
get display size
|
String |
getExtTypeName()
retrieve extended metadata name if any
|
int |
getFlags()
Retrieve metadata flag
|
long |
getLength()
column maximum length if known
|
int |
getPrecision()
Return metadata precision.
|
String |
getSchema()
get column schema
|
String |
getTable()
retrieve table name if any
|
String |
getTableAlias()
retrieve table alias if any
|
com.singlestore.jdbc.client.DataType |
getType()
server data type
|
String |
getTypeName(Configuration conf) |
boolean |
hasDefault()
Column has a default value
|
int |
hashCode() |
boolean |
isAutoIncrement()
Column autoincrement
|
boolean |
isBinary()
indicate if column is of binary type.
|
boolean |
isPrimaryKey()
Is column a primary key
|
boolean |
isSigned()
Is column signed (for number only)
|
void |
useAliasAsName()
Use column alias as name
|
public ColumnDefinitionPacket(com.singlestore.jdbc.client.ReadableByteBuf buf,
boolean extendedInfo)
buf - mysql packet bufferextendedInfo - support extended informationpublic static ColumnDefinitionPacket create(String name, com.singlestore.jdbc.client.DataType type, int flags)
name - column nametype - server typeflags - columns flagspublic String getSchema()
com.singlestore.jdbc.client.ColumngetSchema in interface com.singlestore.jdbc.client.Columnpublic String getTableAlias()
com.singlestore.jdbc.client.ColumngetTableAlias in interface com.singlestore.jdbc.client.Columnpublic String getTable()
com.singlestore.jdbc.client.ColumngetTable in interface com.singlestore.jdbc.client.Columnpublic String getColumnAlias()
com.singlestore.jdbc.client.ColumngetColumnAlias in interface com.singlestore.jdbc.client.Columnpublic String getColumnName()
com.singlestore.jdbc.client.ColumngetColumnName in interface com.singlestore.jdbc.client.Columnpublic long getLength()
com.singlestore.jdbc.client.ColumngetLength in interface com.singlestore.jdbc.client.Columnpublic com.singlestore.jdbc.client.DataType getType()
com.singlestore.jdbc.client.ColumngetType in interface com.singlestore.jdbc.client.Columnpublic String getTypeName(Configuration conf)
getTypeName in interface com.singlestore.jdbc.client.Columnpublic byte getDecimals()
com.singlestore.jdbc.client.ColumngetDecimals in interface com.singlestore.jdbc.client.Columnpublic boolean isSigned()
com.singlestore.jdbc.client.ColumnisSigned in interface com.singlestore.jdbc.client.Columnpublic int getDisplaySize()
com.singlestore.jdbc.client.ColumngetDisplaySize in interface com.singlestore.jdbc.client.Columnpublic boolean isPrimaryKey()
com.singlestore.jdbc.client.ColumnisPrimaryKey in interface com.singlestore.jdbc.client.Columnpublic boolean isAutoIncrement()
com.singlestore.jdbc.client.ColumnisAutoIncrement in interface com.singlestore.jdbc.client.Columnpublic boolean hasDefault()
com.singlestore.jdbc.client.ColumnhasDefault in interface com.singlestore.jdbc.client.Columnpublic boolean isBinary()
com.singlestore.jdbc.client.ColumnisBinary in interface com.singlestore.jdbc.client.Columnpublic int getFlags()
com.singlestore.jdbc.client.ColumngetFlags in interface com.singlestore.jdbc.client.Columnpublic String getExtTypeName()
com.singlestore.jdbc.client.ColumngetExtTypeName in interface com.singlestore.jdbc.client.Columnpublic int getPrecision()
getPrecision in interface com.singlestore.jdbc.client.Columnpublic int getColumnType(Configuration conf)
com.singlestore.jdbc.client.ColumngetColumnType in interface com.singlestore.jdbc.client.Columnconf - configurationpublic Codec<?> getDefaultCodec(Configuration conf)
com.singlestore.jdbc.client.ColumngetDefaultCodec in interface com.singlestore.jdbc.client.Columnconf - configurationpublic void useAliasAsName()
com.singlestore.jdbc.client.ColumnuseAliasAsName in interface com.singlestore.jdbc.client.ColumnCopyright © 2023 SingleStore. All rights reserved.