public class Field extends Object implements Serializable
| Modifier and Type | Field and Description |
|---|---|
String |
alias
Name to use in the class if not present (normal case) then name is used
|
static byte |
ANSICHAR |
static byte |
AUTOTIMESTAMP |
static byte |
BIGIDENTITY |
static byte |
BIGSEQUENCE |
static byte |
BIGXML |
int |
bindPos |
static byte |
BLOB |
static byte |
BOOLEAN |
static byte |
BYTE |
static byte |
CHAR |
String |
checkValue
Check Constraint to applied to field by the database
|
Vector<String> |
comments
Array of comments associated with the field
|
static byte |
DATE |
static byte |
DATETIME |
static int |
DEFAULT_BIG_XML |
static int |
DEFAULT_XML |
String |
defaultValue
Default value to apply for the field on insert if not specified
|
int |
definePos |
static byte |
DOUBLE |
static byte |
DYNAMIC |
String |
enumLink |
Vector<Enum> |
enums |
String |
enumType |
static byte |
FLOAT |
static byte |
IDENTITY |
static byte |
INT |
boolean |
isCalc
Indicates the field is a calculated column on the database
|
boolean |
isExtStd
Indicates the field is EXT
|
boolean |
isExtStdOut |
boolean |
isIn
Indicates the field is INPUT
|
boolean |
isLiteral
Indicates the field can is a Literal
|
boolean |
isNull
Indicates the field can be NULL on the database
|
boolean |
isOut
Indicates the field is OUTPUT
|
boolean |
isPrimaryKey
Indicates field is used in the primary key
|
boolean |
isSequence
Indicates the field is a Sequence
|
int |
length
Length of field
|
String |
literalName |
static byte |
LONG |
static byte |
MONEY |
String |
name
Name to use in the database
|
int |
precision
No of digits in a numeric field
|
int |
scale
No of digits after the decimal point|comma
|
static byte |
SEQUENCE |
static byte |
SHORT |
static byte |
STATUS |
static byte |
TIME |
static byte |
TIMESTAMP |
static byte |
TLOB |
byte |
type
Type of field
|
static byte |
UID |
static byte |
USERSTAMP |
static byte |
UTF8 |
Vector<String> |
valueList |
static byte |
WANSICHAR |
static byte |
WCHAR |
static byte |
XML |
| Constructor and Description |
|---|
Field()
constructor ensures fields have correct default values
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
ansiIsNull()
Check for empty string as null type fields.
|
String |
getAlias() |
int |
getBindPos() |
String |
getCheckValue() |
Vector<String> |
getComments() |
String |
getDefaultValue() |
int |
getDefinePos() |
String |
getEnumLink() |
Vector<Enum> |
getEnums() |
String |
getEnumType() |
int |
getLength() |
String |
getLiteralName() |
String |
getName() |
int |
getPrecision() |
int |
getScale() |
byte |
getType() |
Vector<String> |
getValueList() |
boolean |
isCalc() |
boolean |
isCharEmptyAsNull()
Check for empty string as null type fields.
|
boolean |
isCharEmptyOrAnsiAsNull() |
boolean |
isEmptyAsNull()
Check for empty string as null type fields.
|
boolean |
isEmptyOrAnsiAsNull() |
boolean |
isExtStd() |
boolean |
isExtStdOut() |
boolean |
isIn() |
boolean |
isLiteral() |
boolean |
isNull() |
boolean |
isOut() |
boolean |
isPrimaryKey() |
boolean |
isSequence() |
void |
reader(DataInputStream ids) |
String |
replaceAll(String haystack,
String needle,
String replacement) |
void |
setEnumType(String enumType) |
String |
useLiteral()
If there is an literal uses that else returns name
|
String |
useLowerName()
If there is an alias uses that else returns name
|
String |
useName()
If there is an alias uses that else returns name
|
String |
useUpperName()
If there is an alias uses that else returns name
|
void |
writer(DataOutputStream ods) |
public String name
public String alias
public String defaultValue
public String checkValue
public byte type
public int length
public int precision
public int scale
public int bindPos
public int definePos
public String enumLink
public String enumType
public boolean isPrimaryKey
public boolean isSequence
public boolean isNull
public boolean isLiteral
public boolean isCalc
public boolean isIn
public boolean isOut
public boolean isExtStd
public boolean isExtStdOut
public String literalName
public static final byte BLOB
public static final byte BOOLEAN
public static final byte BYTE
public static final byte CHAR
public static final byte DATE
public static final byte DATETIME
public static final byte DOUBLE
public static final byte DYNAMIC
public static final byte FLOAT
public static final byte IDENTITY
public static final byte INT
public static final byte LONG
public static final byte MONEY
public static final byte SEQUENCE
public static final byte SHORT
public static final byte STATUS
public static final byte TIME
public static final byte TIMESTAMP
public static final byte TLOB
public static final byte USERSTAMP
public static final byte ANSICHAR
public static final byte UID
public static final byte XML
public static final byte BIGSEQUENCE
public static final byte BIGIDENTITY
public static final byte AUTOTIMESTAMP
public static final byte WCHAR
public static final byte WANSICHAR
public static final byte UTF8
public static final byte BIGXML
public static final int DEFAULT_XML
public static final int DEFAULT_BIG_XML
public String getName()
public String getAlias()
public String getDefaultValue()
public String getCheckValue()
public byte getType()
public int getLength()
public int getPrecision()
public int getScale()
public int getBindPos()
public int getDefinePos()
public String getEnumLink()
public String getEnumType()
public void setEnumType(String enumType)
public boolean isPrimaryKey()
public boolean isSequence()
public boolean isNull()
public boolean isLiteral()
public boolean isCalc()
public boolean isIn()
public boolean isOut()
public boolean isExtStd()
public boolean isExtStdOut()
public String getLiteralName()
public void reader(DataInputStream ids) throws IOException
IOExceptionpublic void writer(DataOutputStream ods) throws IOException
IOExceptionpublic String useName()
public String useLiteral()
public String useLowerName()
public String useUpperName()
public boolean isEmptyAsNull()
public boolean isCharEmptyAsNull()
public boolean ansiIsNull()
public boolean isEmptyOrAnsiAsNull()
public boolean isCharEmptyOrAnsiAsNull()
Copyright © 2019. All rights reserved.