|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.springframework.binding.value.support.AbstractPropertyChangePublisher
org.springframework.binding.form.support.ReadOnlyFieldMetadata
public class ReadOnlyFieldMetadata
Field Summary |
---|
Fields inherited from class org.springframework.binding.value.support.AbstractPropertyChangePublisher |
---|
logger |
Fields inherited from interface org.springframework.binding.form.FieldMetadata |
---|
DIRTY_PROPERTY, ENABLED_PROPERTY, READ_ONLY_PROPERTY |
Constructor Summary | |
---|---|
ReadOnlyFieldMetadata(FormModel formModel,
Class propertyType)
|
|
ReadOnlyFieldMetadata(FormModel formModel,
Class propertyType,
Map userMetadata)
|
Method Summary | |
---|---|
Map |
getAllUserMetadata()
Returns all custom metadata associated with this property in the form of a Map. |
Class |
getPropertyType()
Return the type of this property. |
Object |
getUserMetadata(String key)
Returns custom metadata that may be associated with this property. |
boolean |
isDirty()
Returns whether or not the property is dirty. |
boolean |
isEnabled()
Returns whether or not the property is enabled. |
boolean |
isReadOnly()
Returns whether or not the property is read only. |
void |
setEnabled(boolean enabled)
Sets the enabled value for this property. |
void |
setReadOnly(boolean readOnly)
Sets whether or not this property is read only. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.springframework.binding.value.PropertyChangePublisher |
---|
addPropertyChangeListener, addPropertyChangeListener, removePropertyChangeListener, removePropertyChangeListener |
Constructor Detail |
---|
public ReadOnlyFieldMetadata(FormModel formModel, Class propertyType)
public ReadOnlyFieldMetadata(FormModel formModel, Class propertyType, Map userMetadata)
Method Detail |
---|
public Map getAllUserMetadata()
FieldMetadata
getAllUserMetadata
in interface FieldMetadata
public Class getPropertyType()
FieldMetadata
getPropertyType
in interface FieldMetadata
public Object getUserMetadata(String key)
FieldMetadata
getUserMetadata
in interface FieldMetadata
public boolean isDirty()
FieldMetadata
isDirty
in interface FieldMetadata
public boolean isEnabled()
FieldMetadata
A property is enabled if all of the following are true:
isEnabled
in interface FieldMetadata
public boolean isReadOnly()
FieldMetadata
A property is read only if any of the following are true:
isReadOnly
in interface FieldMetadata
public void setEnabled(boolean enabled)
FieldMetadata
It's expected that controls bound to this form property will listen for changes to this value and if possible modify their display/behaviour to reflect the new state.
This value will be propagated up to any descendants.
setEnabled
in interface FieldMetadata
enabled
- should this property be enabledpublic void setReadOnly(boolean readOnly)
FieldMetadata
It's expected that controls bound to this form property will listen for changes to this value and if possible modify their display/behaviour to reflect the new state. e.g. When this property becomes true a text component would grey its self out and prevent any editing.
This value will be propagated up to any descendants.
setReadOnly
in interface FieldMetadata
readOnly
- should this property be read only
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |