public class ColumnInfo extends Object
| 修飾子とタイプ | フィールドと説明 |
|---|---|
protected boolean |
_autoIncrement |
protected boolean |
_canBeNullObject |
protected ClassificationMeta |
_classificationMeta |
protected String |
_columnAlias |
protected String |
_columnComment |
protected String |
_columnDbName |
protected String |
_columnDbType |
protected Integer |
_columnSize |
protected ColumnSqlName |
_columnSqlName |
protected String |
_columnSynonym |
protected boolean |
_commonColumn |
protected DBMeta |
_dbmeta |
protected Integer |
_decimalDigits |
protected String |
_defaultValue |
protected boolean |
_foreignKey |
protected List<String> |
_foreignPropList |
protected boolean |
_notNull |
protected Class<?> |
_objectNativeType |
protected DBMeta.OptimisticLockType |
_optimisticLockType |
protected boolean |
_primary |
protected Class<?> |
_propertyAccessType |
protected PropertyGateway |
_propertyGateway |
protected PropertyMethodFinder |
_propertyMethodFinder |
protected String |
_propertyName |
protected Method |
_readMethod |
protected List<String> |
_referrerPropList |
protected Method |
_writeMethod |
protected static List<String> |
EMPTY_LIST
The empty read-only list for empty property.
|
protected static Set<String> |
JAVA8_DATE_TYPE_SET
The set of type name for Java8Time judgment.
|
protected static String |
JAVA8_JUST_DATE_TYPE
The type name of Java8Time's just date.
|
protected static String |
JAVA8_JUST_TIME_TYPE
The type name of Java8Time's just time.
|
protected static String |
JAVA8_JUST_TIMESTAMP_TYPE
The type name of Java8Time's just time-stamp.
|
| コンストラクタと説明 |
|---|
ColumnInfo(DBMeta dbmeta,
String columnDbName,
String columnSqlName,
String columnSynonym,
String columnAlias,
Class<?> objectNativeType,
String propertyName,
Class<?> propertyAccessType,
boolean primary,
boolean autoIncrement,
boolean notNull,
String columnDbType,
Integer columnSize,
Integer decimalDigits,
String defaultValue,
boolean commonColumn,
DBMeta.OptimisticLockType optimisticLockType,
String columnComment,
List<String> foreignPropList,
List<String> referrerPropList,
ClassificationMeta classificationMeta,
boolean canBeNullObject,
PropertyMethodFinder propertyMethodFinder) |
| 修飾子とタイプ | メソッドと説明 |
|---|---|
protected void |
assertObjectNotNull(String variableName,
Object value) |
protected boolean |
assignableObjectNativeTypeJava8Date() |
protected boolean |
assignableObjectNativeTypeUtilDate() |
boolean |
canBeNullObject()
Can the column be null object?
|
<VALUE> VALUE |
convertToObjectNativeType(Object value)
Convert the value to object native type.
|
void |
diveIntoFlexibleMap(Map<String,ColumnInfo> flexibleMap)
Dive into flexible map by flexible keys.
|
protected <VALUE> VALUE |
doConvertToObjectNativeType(Object value) |
boolean |
equals(Object obj) |
protected PropertyGateway |
findPropertyGateway() |
protected Method |
findReadMethod() |
protected Method |
findWriteMethod() |
static List<String> |
generateFlexibleKeyList(String columnDbName,
String columnSynonym,
String propertyName)
Generate the list of flexible keys.
|
ClassificationMeta |
getClassificationMeta()
Get the meta of classification related to the column.
|
String |
getColumnAlias()
Get the alias of the column.
|
String |
getColumnComment()
Get the comment of the column.
|
String |
getColumnDbName()
Get the DB name of the column.
|
String |
getColumnDbType()
Get the DB type of the column.
|
Integer |
getColumnSize()
Get the size of the column.
|
ColumnSqlName |
getColumnSqlName()
Get the SQL name of the column.
|
String |
getColumnSynonym()
Get the synonym of the column.
|
DBMeta |
getDBMeta()
Get the DB meta of the column's table.
|
Integer |
getDecimalDigits()
Get the decimal digits of the column.
|
String |
getDefaultValue()
Get the default value of the column.
|
protected List<String> |
getFlexibleKeyList()
Get the list of flexible keys for this column.
|
List<ForeignInfo> |
getForeignInfoList()
Get the read-only list of the foreign info related to this column.
|
Class<?> |
getGenericType()
Get the generic type of property type for list property.
|
Class<?> |
getObjectNativeType()
Get the native type mapped to object for the column.
|
Class<?> |
getPropertyAccessType()
Get the type of property access for the column.
|
PropertyGateway |
getPropertyGateway()
Get the property gateway for the column.
|
String |
getPropertyName()
Get the name of property for the column.
|
Method |
getReadMethod()
Get the read method for entity reflection.
|
List<ReferrerInfo> |
getReferrerInfoList()
Get the read-only list of the referrer info related to this column.
|
Method |
getWriteMethod()
Get the write method for entity reflection.
|
int |
hashCode() |
protected String |
initCap(String name) |
boolean |
isAutoIncrement()
Is the column auto increment?
|
boolean |
isCommonColumn()
Is the column a part of common columns?
|
boolean |
isForeignKey()
Is the column a part of any foreign key?
|
boolean |
isNotNull()
Is the column not null?
|
boolean |
isObjectNativeTypeDate()
Is the object native type Date?
|
boolean |
isObjectNativeTypeJustDate()
Is the object native type just (equals) date?
|
boolean |
isObjectNativeTypeJustTime()
Is the object native type just (equals) time?
|
boolean |
isObjectNativeTypeJustTimestamp()
Is the object native type just (equals) time-stamp?
|
boolean |
isObjectNativeTypeNumber()
Is the object native type Number?
|
boolean |
isObjectNativeTypeString()
Is the object native type String?
|
boolean |
isOptimisticLock()
Is the column for optimistic lock?
|
boolean |
isPrimary()
Is the column a part of primary keys?
|
boolean |
isUpdateDate()
Is the column update-date for optimistic lock?
|
boolean |
isVersionNo()
Is the column version-no for optimistic lock?
|
protected boolean |
justObjectNativeJava8Date() |
protected boolean |
justObjectNativeJava8Time() |
protected boolean |
justObjectNativeJava8Timestamp() |
protected boolean |
justObjectNativeTypeUtilDate() |
protected boolean |
justObjectNativeTypeUtilTime() |
protected boolean |
justObjectNativeTypeUtilTimestamp() |
<PROPERTY> PROPERTY |
read(Entity entity)
Read the value from the entity by its gateway (means no reflection).
|
String |
toString() |
void |
write(Entity entity,
Object value)
Write the value to the entity by its gateway (means no reflection).
|
protected static final List<String> EMPTY_LIST
protected static final String JAVA8_JUST_DATE_TYPE
protected static final String JAVA8_JUST_TIMESTAMP_TYPE
protected static final String JAVA8_JUST_TIME_TYPE
protected static final Set<String> JAVA8_DATE_TYPE_SET
protected final DBMeta _dbmeta
protected final String _columnDbName
protected final ColumnSqlName _columnSqlName
protected final String _columnSynonym
protected final String _columnAlias
protected final String _propertyName
protected final Class<?> _objectNativeType
protected final Class<?> _propertyAccessType
protected final boolean _primary
protected final boolean _autoIncrement
protected final boolean _notNull
protected final String _columnDbType
protected final Integer _columnSize
protected final Integer _decimalDigits
protected final String _defaultValue
protected final boolean _commonColumn
protected final DBMeta.OptimisticLockType _optimisticLockType
protected final String _columnComment
protected final boolean _foreignKey
protected final ClassificationMeta _classificationMeta
protected final boolean _canBeNullObject
protected final PropertyGateway _propertyGateway
protected final PropertyMethodFinder _propertyMethodFinder
protected final Method _readMethod
protected final Method _writeMethod
public ColumnInfo(DBMeta dbmeta, String columnDbName, String columnSqlName, String columnSynonym, String columnAlias, Class<?> objectNativeType, String propertyName, Class<?> propertyAccessType, boolean primary, boolean autoIncrement, boolean notNull, String columnDbType, Integer columnSize, Integer decimalDigits, String defaultValue, boolean commonColumn, DBMeta.OptimisticLockType optimisticLockType, String columnComment, List<String> foreignPropList, List<String> referrerPropList, ClassificationMeta classificationMeta, boolean canBeNullObject, PropertyMethodFinder propertyMethodFinder)
public PropertyGateway getPropertyGateway()
public <PROPERTY> PROPERTY read(Entity entity)
PROPERTY - The type of the property.entity - The target entity of this column to read. (NotNull)public Method getReadMethod()
public void write(Entity entity, Object value)
entity - The target entity of this column to write. (NotNull)value - The written value. (NullAllowed: if null, null value is written)public Method getWriteMethod()
public Class<?> getGenericType()
protected PropertyGateway findPropertyGateway()
protected Method findReadMethod()
protected Method findWriteMethod()
public <VALUE> VALUE convertToObjectNativeType(Object value)
VALUE - The type of column value.value - The conversion target value. (NullAllowed: if null, returns null)protected <VALUE> VALUE doConvertToObjectNativeType(Object value)
public void diveIntoFlexibleMap(Map<String,ColumnInfo> flexibleMap)
flexibleMap - The flexible map for column. (NotNull)protected List<String> getFlexibleKeyList()
public static List<String> generateFlexibleKeyList(String columnDbName, String columnSynonym, String propertyName)
columnDbName - The DB name of column. (NotNull)columnSynonym - The DB synonym name of column. (NotNull)propertyName - The property name of column. (NotNull)public DBMeta getDBMeta()
public String getColumnDbName()
public ColumnSqlName getColumnSqlName()
public String getColumnSynonym()
public String getColumnAlias()
public Class<?> getObjectNativeType()
public boolean isObjectNativeTypeString()
public boolean isObjectNativeTypeNumber()
public boolean isObjectNativeTypeDate()
protected boolean assignableObjectNativeTypeUtilDate()
protected boolean assignableObjectNativeTypeJava8Date()
public boolean isObjectNativeTypeJustDate()
protected boolean justObjectNativeTypeUtilDate()
protected boolean justObjectNativeJava8Date()
public boolean isObjectNativeTypeJustTimestamp()
protected boolean justObjectNativeTypeUtilTimestamp()
protected boolean justObjectNativeJava8Timestamp()
public boolean isObjectNativeTypeJustTime()
protected boolean justObjectNativeTypeUtilTime()
protected boolean justObjectNativeJava8Time()
public String getPropertyName()
public Class<?> getPropertyAccessType()
public boolean isPrimary()
public boolean isAutoIncrement()
public boolean isNotNull()
public String getColumnDbType()
public Integer getColumnSize()
public Integer getDecimalDigits()
public String getDefaultValue()
public boolean isCommonColumn()
public boolean isOptimisticLock()
public boolean isVersionNo()
public boolean isUpdateDate()
public String getColumnComment()
public List<ForeignInfo> getForeignInfoList()
public List<ReferrerInfo> getReferrerInfoList()
public boolean isForeignKey()
public ClassificationMeta getClassificationMeta()
public boolean canBeNullObject()
Copyright © 2014–2015 The DBFlute Project. All rights reserved.