public PersistentMap(Map<K, V> collection, boolean clone) { if (collection instanceof SortedMap) throw new IllegalArgumentException("Should not be a SortedMap: " + collection); if (collection != null) init(clone ? new HashMap<K, V>(collection) : collection, null, false); }
@Override public void doInitialize() { init(new HashMap<K, V>(), null, false); }
@Override public void doInitialize(Map<K, V> map, boolean empty) { init(empty ? new HashMap<K, V>() : map, null, false); }
@Override public void doInitialize(Map<K, V> map, boolean empty) { init(empty ? new HashMap<K, V>() : map, null, false); }
public PersistentMap(Map<K, V> collection, boolean clone) { if (collection instanceof SortedMap) throw new IllegalArgumentException("Should not be a SortedMap: " + collection); if (collection != null) init(clone ? new HashMap<K, V>(collection) : collection, null, false); }
public PersistentMap(Map<K, V> collection, boolean clone) { if (collection instanceof SortedMap) throw new IllegalArgumentException("Should not be a SortedMap: " + collection); if (collection != null) init(clone ? new HashMap<K, V>(collection) : collection, null, false); }
@SuppressWarnings("unchecked") @Override protected void updateFromSnapshot(ObjectInput in, PersistentCollectionSnapshot snapshot) { if (snapshot.isInitialized()) init(new HashMap<K, V>((Map<K, V>)snapshot.getElementsAsMap()), snapshot.getDetachedState(), snapshot.isDirty()); else init(null, snapshot.getDetachedState(), false); }
@SuppressWarnings("unchecked") @Override protected void updateFromSnapshot(ObjectInput in, PersistentCollectionSnapshot snapshot) { if (snapshot.isInitialized()) init(new HashMap<K, V>((Map<K, V>)snapshot.getElementsAsMap()), snapshot.getDetachedState(), snapshot.isDirty()); else init(null, snapshot.getDetachedState(), false); }
@SuppressWarnings("unchecked") @Override protected void updateFromSnapshot(ObjectInput in, PersistentCollectionSnapshot snapshot) { if (snapshot.isInitialized()) init(new HashMap<K, V>((Map<K, V>)snapshot.getElementsAsMap()), snapshot.getDetachedState(), snapshot.isDirty()); else init(null, snapshot.getDetachedState(), false); }
public PersistentMap<K, V> clone(boolean uninitialize) { PersistentMap<K, V> map = new PersistentMap<K, V>(); if (wasInitialized() && !uninitialize) map.init(getCollection(), null, isDirty()); return map; } }
public PersistentMap<K, V> clone(boolean uninitialize) { PersistentMap<K, V> map = new PersistentMap<K, V>(); if (wasInitialized() && !uninitialize) map.init(getCollection(), null, isDirty()); return map; } }
public PersistentMap<K, V> clone(boolean uninitialize) { PersistentMap<K, V> map = new PersistentMap<K, V>(); if (wasInitialized() && !uninitialize) map.init(getCollection(), null, isDirty()); return map; } }