org.escot
Class StringAdapter
java.lang.Object
|
+--org.escot.BasicFeature
|
+--org.escot.BasicValue
|
+--org.escot.BasicString
|
+--org.escot.StringAdapter
- All Implemented Interfaces:
- ChangeListener, DocumentListener, EscotAssociated, EscotFeature, EventListener, PropertyChangeListener, StringProperty
- public class StringAdapter
- extends BasicString
- implements PropertyChangeListener, DocumentListener
Adapts a String property. If the property
is bound, registers for change events and relays the change.
If the target is a JTextComponent, register as a DocumentListener on the document, and
track changes to the document property.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
StringAdapter
public StringAdapter(Object target,
PropertyDescriptor desc)
updateValueFromTarget
protected void updateValueFromTarget()
insertUpdate
public void insertUpdate(DocumentEvent e)
- Specified by:
insertUpdate in interface DocumentListener
removeUpdate
public void removeUpdate(DocumentEvent e)
- Specified by:
removeUpdate in interface DocumentListener
changedUpdate
public void changedUpdate(DocumentEvent e)
- Specified by:
changedUpdate in interface DocumentListener
addDocumentListenerToTarget
protected void addDocumentListenerToTarget(DocumentListener listener)
getValueFromTarget
protected Object getValueFromTarget()
propertyChange
public void propertyChange(PropertyChangeEvent evt)
- Specified by:
propertyChange in interface PropertyChangeListener
getTextValue
public String getTextValue()
- Description copied from class:
BasicString
- Returns the value of this DataItem.
- Overrides:
getTextValue in class BasicString
- Following copied from interface:
org.escot.StringProperty
- Returns:
- the String for this StringProperty
setTextValue
public void setTextValue(String s)
throws NotMutableException
- Description copied from class:
BasicString
- Sets the value of this DataItem.
- Overrides:
setTextValue in class BasicString