public class DefaultForeingKey extends java.lang.Object implements Persistent, ForeingKey, EditableForeingKey, Cloneable
ForeingKey.ContextForeingKey
MAX_AVAILABLE_VALUES
Constructor and Description |
---|
DefaultForeingKey() |
Modifier and Type | Method and Description |
---|---|
void |
clean() |
ForeingKey |
clone()
Creates a copy of the object.
|
ForeingKey.ContextForeingKey |
createContext() |
DynObjectValueItem[] |
getAvailableValues(ForeingKey.ContextForeingKey context) |
java.lang.Object |
getCode(ForeingKey.ContextForeingKey context,
Feature feature) |
java.lang.String |
getCodeName() |
boolean |
getEnsureReferentialIntegrity() |
Feature |
getFeature(ForeingKey.ContextForeingKey context,
java.lang.Object codeValue) |
java.util.List<Feature> |
getFeatures(ForeingKey.ContextForeingKey context) |
FeatureStore |
getFeatureStore(ForeingKey.ContextForeingKey context) |
FeatureType |
getFeatureType(ForeingKey.ContextForeingKey context) |
java.lang.String |
getFieldName() |
java.lang.String |
getLabel(ForeingKey.ContextForeingKey context,
Feature feature) |
java.lang.String |
getLabel(ForeingKey.ContextForeingKey context,
java.lang.Object codeValue) |
Expression |
getLabelExpression(ForeingKey.ContextForeingKey context) |
java.lang.String |
getLabelFormula() |
java.lang.String |
getLabelForValue(java.lang.Object value) |
FeatureQuery |
getQuery(ForeingKey.ContextForeingKey context,
java.lang.Object codeValue) |
StoresRepository |
getStoresRepository(ForeingKey.ContextForeingKey context) |
StoresRepository |
getStoresRepository(java.lang.String tableName) |
java.lang.String |
getTableName() |
boolean |
hasAvailableValues() |
boolean |
isClosedList()
Indicates whether the foreign key reference to a closed list of values.
|
boolean |
isEmpty() |
boolean |
isForeingKey() |
boolean |
isInAvailableValues(java.lang.Object valueToCheck) |
void |
loadFromState(PersistentState state)
Set the state of the object from the state passed as parameter.
|
static void |
registerPersistenceDefinition() |
void |
saveToState(PersistentState state)
Saves the internal state of the object on the provided
PersistentState object.
|
void |
setClosedList(boolean selectable)
Indicates whether the foreign key reference to a closed list of values.
|
void |
setCodeName(java.lang.String codeName) |
void |
setDescriptor(FeatureAttributeDescriptor descriptor) |
void |
setEnsureReferentialIntegrity(boolean ensureReferentialIntegrity)
If the data store supports it, it ensures that referential integrity is respected.
|
void |
setForeingKey(boolean foreingKey) |
void |
setLabelFormula(java.lang.String labelFormula) |
void |
setTableName(java.lang.String tableName) |
void |
unbind() |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
cloneQuietly, cloneQuietly
public void setDescriptor(FeatureAttributeDescriptor descriptor)
public java.lang.String getFieldName()
public void unbind()
unbind
in interface EditableForeingKey
public boolean isClosedList()
ForeingKey
isClosedList
in interface ForeingKey
public void setClosedList(boolean selectable)
EditableForeingKey
setClosedList
in interface EditableForeingKey
public boolean isForeingKey()
isForeingKey
in interface ForeingKey
public void setForeingKey(boolean foreingKey)
setForeingKey
in interface EditableForeingKey
public java.lang.String getLabelFormula()
getLabelFormula
in interface ForeingKey
public void setLabelFormula(java.lang.String labelFormula)
setLabelFormula
in interface EditableForeingKey
public java.lang.String getCodeName()
getCodeName
in interface ForeingKey
public void setCodeName(java.lang.String codeName)
setCodeName
in interface EditableForeingKey
public java.lang.String getTableName()
getTableName
in interface ForeingKey
public void setTableName(java.lang.String tableName)
setTableName
in interface EditableForeingKey
public boolean isEmpty()
isEmpty
in interface ForeingKey
public void clean()
clean
in interface EditableForeingKey
public ForeingKey.ContextForeingKey createContext()
createContext
in interface ForeingKey
public StoresRepository getStoresRepository(ForeingKey.ContextForeingKey context)
getStoresRepository
in interface ForeingKey
public FeatureStore getFeatureStore(ForeingKey.ContextForeingKey context)
getFeatureStore
in interface ForeingKey
public FeatureType getFeatureType(ForeingKey.ContextForeingKey context)
getFeatureType
in interface ForeingKey
public java.util.List<Feature> getFeatures(ForeingKey.ContextForeingKey context)
getFeatures
in interface ForeingKey
public java.lang.Object getCode(ForeingKey.ContextForeingKey context, Feature feature)
getCode
in interface ForeingKey
public FeatureQuery getQuery(ForeingKey.ContextForeingKey context, java.lang.Object codeValue)
getQuery
in interface ForeingKey
public Feature getFeature(ForeingKey.ContextForeingKey context, java.lang.Object codeValue)
getFeature
in interface ForeingKey
public java.lang.String getLabel(ForeingKey.ContextForeingKey context, java.lang.Object codeValue)
getLabel
in interface ForeingKey
public Expression getLabelExpression(ForeingKey.ContextForeingKey context)
getLabelExpression
in interface ForeingKey
public java.lang.String getLabel(ForeingKey.ContextForeingKey context, Feature feature)
getLabel
in interface ForeingKey
public DynObjectValueItem[] getAvailableValues(ForeingKey.ContextForeingKey context)
getAvailableValues
in interface ForeingKey
public java.lang.String getLabelForValue(java.lang.Object value)
getLabelForValue
in interface ForeingKey
public void loadFromState(PersistentState state) throws PersistenceException
Persistent
loadFromState
in interface Persistent
PersistenceException
public void saveToState(PersistentState state) throws PersistenceException
Persistent
saveToState
in interface Persistent
PersistenceException
public static void registerPersistenceDefinition()
public ForeingKey clone() throws java.lang.CloneNotSupportedException
Cloneable
clone
in class java.lang.Object
java.lang.CloneNotSupportedException
- if the instance of the object cannot
be cloned. As this is extending Cloneable
so its sure
it implements it, so this exception may be used for problems on specific
object instances.Object#clone()}.
public boolean getEnsureReferentialIntegrity()
getEnsureReferentialIntegrity
in interface ForeingKey
public void setEnsureReferentialIntegrity(boolean ensureReferentialIntegrity)
ForeingKey
setEnsureReferentialIntegrity
in interface ForeingKey
public boolean isInAvailableValues(java.lang.Object valueToCheck)
isInAvailableValues
in interface ForeingKey
public boolean hasAvailableValues()
hasAvailableValues
in interface ForeingKey
public StoresRepository getStoresRepository(java.lang.String tableName)