public class ObservablePersistentSortedMap<K,V> extends com.sun.javafx.collections.ObservableMapWrapper<K,V> implements UnsafePersistentCollection<java.util.SortedMap<K,V>>
PersistentCollection.ChangeListener<C>, PersistentCollection.InitializationCallback<C>, PersistentCollection.InitializationListener<C>, PersistentCollection.Initializer<C>| Constructor and Description |
|---|
ObservablePersistentSortedMap(PersistentSortedMap<K,V> persistentSortedMap) |
| Modifier and Type | Method and Description |
|---|---|
void |
addListener(PersistentCollection.ChangeListener<java.util.SortedMap<K,V>> listener)
Register a change listener
|
void |
addListener(PersistentCollection.InitializationListener<java.util.SortedMap<K,V>> listener)
Register a initialization listener
|
void |
clearDirty()
Clear the dirty state of the collection
|
PersistentCollection<java.util.SortedMap<K,V>> |
clone(boolean uninitialize)
Clone a persistent collection
|
void |
dirty()
Mark the collection as dirty
|
boolean |
equals(java.lang.Object object) |
Loader<java.util.SortedMap<K,V>> |
getLoader()
Loader for the collection
|
int |
hashCode() |
void |
initialize(java.util.SortedMap<K,V> map,
PersistentCollection.Initializer<java.util.SortedMap<K,V>> initializer)
Mark the collection as initialized, called after the content is loaded
|
void |
initializing()
Mark the collection as currently initializing so next access do not trigger loading
|
PersistentSortedMap<K,V> |
internalPersistentCollection() |
boolean |
isDirty()
Is the collection dirty ?
|
void |
readExternal(java.io.ObjectInput in) |
void |
removeListener(PersistentCollection.ChangeListener<java.util.SortedMap<K,V>> listener)
Unregister a change listener
|
void |
removeListener(PersistentCollection.InitializationListener<java.util.SortedMap<K,V>> listener)
Unregister a initialization listener
|
void |
setLoader(Loader<java.util.SortedMap<K,V>> loader)
Set a loader for the collection
|
java.lang.String |
toString() |
void |
uninitialize()
Unload the collection and unset its initialized state
|
boolean |
wasInitialized()
Was the collection was initialized
|
void |
withInitialized(PersistentCollection.InitializationCallback<java.util.SortedMap<K,V>> callback)
Execute the specified callback after ensuring the collection has been loaded
If it was not loaded, the callack is called asynchronously after loading is complete
|
void |
writeExternal(java.io.ObjectOutput out) |
public ObservablePersistentSortedMap(PersistentSortedMap<K,V> persistentSortedMap)
public void writeExternal(java.io.ObjectOutput out)
throws java.io.IOException
writeExternal in interface java.io.Externalizablejava.io.IOExceptionpublic void readExternal(java.io.ObjectInput in)
throws java.io.IOException,
java.lang.ClassNotFoundException
readExternal in interface java.io.Externalizablejava.io.IOExceptionjava.lang.ClassNotFoundExceptionpublic boolean wasInitialized()
PersistentCollectionwasInitialized in interface PersistentCollection<java.util.SortedMap<K,V>>public void uninitialize()
PersistentCollectionuninitialize in interface PersistentCollection<java.util.SortedMap<K,V>>public void initialize(java.util.SortedMap<K,V> map, PersistentCollection.Initializer<java.util.SortedMap<K,V>> initializer)
PersistentCollectioninitialize in interface PersistentCollection<java.util.SortedMap<K,V>>public void initializing()
PersistentCollectioninitializing in interface PersistentCollection<java.util.SortedMap<K,V>>public PersistentCollection<java.util.SortedMap<K,V>> clone(boolean uninitialize)
PersistentCollectionclone in interface PersistentCollection<java.util.SortedMap<K,V>>uninitialize - true to get an uninitialized clone of a lazy collectionpublic Loader<java.util.SortedMap<K,V>> getLoader()
PersistentCollectiongetLoader in interface PersistentCollection<java.util.SortedMap<K,V>>public void setLoader(Loader<java.util.SortedMap<K,V>> loader)
PersistentCollectionsetLoader in interface PersistentCollection<java.util.SortedMap<K,V>>loader - loader that will be called when a lazy collection is accessedpublic boolean isDirty()
PersistentCollectionisDirty in interface PersistentCollection<java.util.SortedMap<K,V>>public void dirty()
PersistentCollectiondirty in interface PersistentCollection<java.util.SortedMap<K,V>>public void clearDirty()
PersistentCollectionclearDirty in interface PersistentCollection<java.util.SortedMap<K,V>>public void addListener(PersistentCollection.ChangeListener<java.util.SortedMap<K,V>> listener)
PersistentCollectionaddListener in interface PersistentCollection<java.util.SortedMap<K,V>>listener - listenerpublic void removeListener(PersistentCollection.ChangeListener<java.util.SortedMap<K,V>> listener)
PersistentCollectionremoveListener in interface PersistentCollection<java.util.SortedMap<K,V>>listener - listenerpublic void addListener(PersistentCollection.InitializationListener<java.util.SortedMap<K,V>> listener)
PersistentCollectionaddListener in interface PersistentCollection<java.util.SortedMap<K,V>>listener - listenerpublic void removeListener(PersistentCollection.InitializationListener<java.util.SortedMap<K,V>> listener)
PersistentCollectionremoveListener in interface PersistentCollection<java.util.SortedMap<K,V>>listener - listenerpublic void withInitialized(PersistentCollection.InitializationCallback<java.util.SortedMap<K,V>> callback)
PersistentCollectionwithInitialized in interface PersistentCollection<java.util.SortedMap<K,V>>callback - callback method to executepublic PersistentSortedMap<K,V> internalPersistentCollection()
internalPersistentCollection in interface UnsafePersistentCollection<java.util.SortedMap<K,V>>public java.lang.String toString()
public int hashCode()