DataColumn
Overview
A DataColumn represents the definition of an individual field in a DataTable. Descendant classes, such as CalculatedDataColumn and LookupDataColumn exist for more specialized field types, but a regular DataColumn represents a real
field that is physically stored as part of the data table.
You will not usually create or deal with DataColumn yourself, but work with fields through the properties exposed by DataTable and DataRow. If necessary, you can query a DataTable for a list of all defined columns via its getColumns method, and inspect them individually as DataColumn or subclass thereof.
Location
- Reference: com.remobjects.dataabstract.jar
- Package: com.remobjects.dataabstract.data
- Ancestry: Object | DataColumn
constructor
Emty constructor that creates an instance of the DataColumn
constructor
DataColumn()
constructor (String)
Creates an instance of a column with the given name. Default data type is String.
constructor(aName: String)
DataColumn(String aName)
Parameters:
- aName: Given column name.
constructor (String, Class)
Creates an instance of a column with the given name and value type.
constructor(aName: String; aDataType: Class)
DataColumn(String aName, Class aDataType)
Parameters:
- aName: Given column name.
- aDataType: Given column data type.
AllowNull
property AllowNull: Boolean read write;
Boolean AllowNull { __get; __set; }
AutoInc
property AutoInc: Boolean read write;
Boolean AutoInc { __get; __set; }
AutoIncStart
property AutoIncStart: Int64 read write;
Int64 AutoIncStart { __get; __set; }
AutoIncStep
property AutoIncStep: Int64 read write;
Int64 AutoIncStep { __get; __set; }
Caption
property Caption: String read write;
String Caption { __get; __set; }
clone
Creates a clone of the current DataColumn.
method clone: DataColumn
DataColumn clone()
ColumnName
property ColumnName: String read write;
String ColumnName { __get; __set; }
DataType
property DataType: Class read write;
Class DataType { __get; __set; }
DefaultValue
property DefaultValue: Object read write;
Object DefaultValue { __get; __set; }
intSetReadOnly protected
method intSetReadOnly(aValue: Boolean)
void intSetReadOnly(Boolean aValue)
Parameters:
- aValue:
MaxLength
property MaxLength: Integer read write;
Integer MaxLength { __get; __set; }
Ordinal
property Ordinal: Integer read write;
Integer Ordinal { __get; __set; }
Properties
property Properties: PropertyCollection read;
PropertyCollection Properties { __get; }
ReadOnly
property ReadOnly: Boolean read write;
Boolean ReadOnly { __get; __set; }
setAutoInc
Helper method to set incrementation mode of the column. Allows to enable autoincrementation, set its start value and increment value in one call.
method setAutoInc(aValue: Boolean; aStart: Long; aStep: Long)
void setAutoInc(Boolean aValue, Long aStart, Long aStep)
Parameters:
- aValue: true - if auto inc enabled; otherwise - false.
- aStart: The start value of values' incrementation
- aStep: The increment/step value by which row's value wil be increased
Table
AllowNull
property AllowNull: Boolean read write;
Boolean AllowNull { __get; __set; }
AutoInc
property AutoInc: Boolean read write;
Boolean AutoInc { __get; __set; }
AutoIncStart
property AutoIncStart: Int64 read write;
Int64 AutoIncStart { __get; __set; }
AutoIncStep
property AutoIncStep: Int64 read write;
Int64 AutoIncStep { __get; __set; }
Caption
property Caption: String read write;
String Caption { __get; __set; }
ColumnName
property ColumnName: String read write;
String ColumnName { __get; __set; }
DataType
property DataType: Class read write;
Class DataType { __get; __set; }
DefaultValue
property DefaultValue: Object read write;
Object DefaultValue { __get; __set; }
MaxLength
property MaxLength: Integer read write;
Integer MaxLength { __get; __set; }
Ordinal
property Ordinal: Integer read write;
Integer Ordinal { __get; __set; }
Properties
property Properties: PropertyCollection read;
PropertyCollection Properties { __get; }
ReadOnly
property ReadOnly: Boolean read write;
Boolean ReadOnly { __get; __set; }
Table
constructor
Emty constructor that creates an instance of the DataColumn
constructor
DataColumn()
constructor (String)
Creates an instance of a column with the given name. Default data type is String.
constructor(aName: String)
DataColumn(String aName)
Parameters:
- aName: Given column name.
constructor (String, Class)
Creates an instance of a column with the given name and value type.
constructor(aName: String; aDataType: Class)
DataColumn(String aName, Class aDataType)
Parameters:
- aName: Given column name.
- aDataType: Given column data type.
clone
Creates a clone of the current DataColumn.
method clone: DataColumn
DataColumn clone()
intSetReadOnly protected
method intSetReadOnly(aValue: Boolean)
void intSetReadOnly(Boolean aValue)
Parameters:
- aValue:
setAutoInc
Helper method to set incrementation mode of the column. Allows to enable autoincrementation, set its start value and increment value in one call.
method setAutoInc(aValue: Boolean; aStart: Long; aStep: Long)
void setAutoInc(Boolean aValue, Long aStart, Long aStep)
Parameters:
- aValue: true - if auto inc enabled; otherwise - false.
- aStart: The start value of values' incrementation
- aStep: The increment/step value by which row's value wil be increased