org.autoplot.dom.ChangesSupport

Support class for encapsulating implementation of pendingChanges and mutator locks. PendingChanges are a way of notifying the bean and other clients using the bean that changes are coming to the bean. Clients should use registerPendingChange to indicate that changes are coming. performingChange indicates the change is in progress. changePerformed indicates to other clients and the bean that the change is complete. For example, event thread registers pending change and creates runnable object. A new thread is started. On the new thread, performingChange and changePerformed is called. mutatorLock() is a way for a client to get exclusive, read-only access to a bean. This also sets the valueAdjusting property. WARNING: this is improperly implemented, and clients must check valueIsAdjusting to see if another lock is out. See http://das2.org/wiki/index.php/Pending_changes


PROP_PENDINGCHANGES


PROP_VALUEADJUSTING

null, "", or a description of the change


addPropertyChangeListener

addPropertyChangeListener( java.beans.PropertyChangeListener listener ) → void

Parameters

listener - a PropertyChangeListener

Returns:

void (returns nothing)

[search for examples] [view on GitHub] [view on old javadoc] [view source]


getChangesPending

getChangesPending( ) → Map

return a map listing the pending changes. This is a thread-safe read-only copy.

Returns:

a map listing the pending changes.

[search for examples] [view on GitHub] [view on old javadoc] [view source]


isPendingChanges

isPendingChanges( ) → boolean

someone has registered a pending change. See getChangesPending.

Returns:

true if someone has registered a pending change.

[search for examples] [view on GitHub] [view on old javadoc] [view source]

isPendingChanges( Object lockObject ) → boolean

isValueAdjusting

isValueAdjusting( ) → String

Check if the bean state is rapidly changing. This returns the lock message, or null if the value is not adjusting.

Returns:

null or a message indicating that the value is adjusting.

[search for examples] [view on GitHub] [view on old javadoc] [view source]


removePropertyChangeListener

removePropertyChangeListener( java.beans.PropertyChangeListener listener ) → void

Parameters

listener - a PropertyChangeListener

Returns:

void (returns nothing)

[search for examples] [view on GitHub] [view on old javadoc] [view source]


toString

toString( ) → String

Returns:

java.lang.String

[search for examples] [view on GitHub] [view on old javadoc] [view source]