public final class ColumnDetails
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
ColumnDetails.Builder
Used for constructing a
TableDetails object. |
Constructor and Description |
---|
ColumnDetails(TableDetails table,
com.incorta.io.Record.ColumnDef columnDef,
java.lang.String originalType,
java.util.Collection<ColumnDetails> refersTo)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
static ColumnDetails.Builder |
builder()
Creates a new builder object.
|
com.incorta.io.Record.ColumnDef |
getColumnDef()
Returns the underlying column definition.
|
java.lang.String |
getLabel()
Returns the column label.
|
java.lang.String |
getName()
Returns the column name.
|
java.lang.String |
getOriginalType()
Returns the column type as defined in the data source.
|
java.util.List<ColumnDetails> |
getRefersTo()
Returns the list of columns that this column refers to.
|
TableDetails |
getTable()
Returns the table details of the table that this column is part of.
|
com.incorta.io.Record.Type |
getType()
Returns the column type.
|
boolean |
isForeignKey()
Returns a boolean flag indicating whether this column is a foreign key (i.e.
|
boolean |
isKey()
Returns a boolean flag indicating whether this is a key column.
|
java.lang.String |
toString() |
public ColumnDetails(TableDetails table, com.incorta.io.Record.ColumnDef columnDef, java.lang.String originalType, java.util.Collection<ColumnDetails> refersTo)
table
- Table detailscolumnDef
- Underlying column definition (including name, label and type)originalType
- The column type as defined in the original data sourcerefersTo
- List of columns that this column refers to (used for joins)public com.incorta.io.Record.ColumnDef getColumnDef()
Record.ColumnDef
objectpublic final java.lang.String getName()
public java.lang.String getLabel()
public final com.incorta.io.Record.Type getType()
public final boolean isKey()
true
if this is a key column, false
otherwisepublic TableDetails getTable()
TableDetails
objectpublic java.lang.String getOriginalType()
public java.util.List<ColumnDetails> getRefersTo()
ColumnDetails
objects representing target columnspublic boolean isForeignKey()
true
if this column is a foreign key, false
otherwise.public java.lang.String toString()
toString
in class java.lang.Object
public static ColumnDetails.Builder builder()
ColumnDetails.Builder
instance