/** * Deserialize an object value from the given stream. */ public static Object deserialize(InputStream in, StoreContext ctx) { try { if (ctx == null) return new ClassResolvingObjectInputStream(in).readObject(); return new PersistentObjectInputStream(in, ctx).readObject(); } catch (Exception e) { throw new StoreException(e); } }
public Proxy newMapProxy(Class type, Class keyType, Class elementType, Comparator compare,boolean autoOff) { type = toProxyableMapType(type); ProxyMap proxy = getFactoryProxyMap(type); return proxy.newInstance((_assertType) ? keyType : null, (_assertType) ? elementType : null, compare, _trackChanges, autoOff); }
/** * Call before invoking {@link List#add(int,Object)} on super. */ public static void beforeAdd(ProxyCollection coll, int index, Object value){ assertAllowedType(value, coll.getElementType()); dirty(coll, true); }
public boolean add(Object o) { Proxies.assertAllowedType(o, _elementType); Proxies.dirty(this, false); _ct.added(o); return true; }
protected Object writeReplace() throws ObjectStreamException { if (isDelayLoad()) { load(); } return Proxies.writeReplace(this, true); }
protected Object writeReplace() throws ObjectStreamException { if (isDelayLoad()) { load(); } return Proxies.writeReplace(this, true); }
protected Object writeReplace() throws ObjectStreamException { if (isDelayLoad()) { load(); } return Proxies.writeReplace(this, true); }
protected Object writeReplace() throws ObjectStreamException { if (isDelayLoad()) { load(); } return Proxies.writeReplace(this, true); }
/** * Call before invoking {@link Map#remove} on super. */ public static boolean beforeRemove(ProxyMap map, Object key) { dirty(map, false); return map.containsKey(key); }
/** * Call after invoking {@link LinkedList#removeLast} on super. */ public static Object afterRemoveLast(ProxyCollection coll, Object removed) { return afterRemove(coll, coll.size(), removed); }
@Override public ProxyCollection newInstance(Class paramClass, Comparator paramComparator, boolean paramBoolean1, boolean paramBoolean2) { DelayedArrayListProxy proxy = new DelayedArrayListProxy(); proxy.elementType = paramClass; proxy.changeTracker = new DelayedCollectionChangeTrackerImpl(proxy, true, true, paramBoolean2); return proxy; }
public ProxyCollection newInstance(Class paramClass, Comparator paramComparator, boolean paramBoolean1, boolean paramBoolean2) { DelayedPriorityQueueProxy localproxy = new DelayedPriorityQueueProxy(); localproxy.elementType = paramClass; if (paramBoolean1) localproxy.changeTracker = new DelayedCollectionChangeTrackerImpl( localproxy, true, false, paramBoolean2); return localproxy; }
public ProxyCollection newInstance(Class paramClass, Comparator paramComparator, boolean paramBoolean1, boolean paramBoolean2) { DelayedLinkedHashSetProxy localproxy = new DelayedLinkedHashSetProxy(); localproxy.elementType = paramClass; if (paramBoolean1) localproxy.changeTracker = new DelayedCollectionChangeTrackerImpl( localproxy, false, false, paramBoolean2); return localproxy; }
@Override public ProxyCollection newInstance(Class paramClass, Comparator paramComparator, boolean paramBoolean1, boolean paramBoolean2) { DelayedLinkedListProxy localproxy = new DelayedLinkedListProxy(); localproxy.elementType = paramClass; if (paramBoolean1) localproxy.changeTracker = new DelayedCollectionChangeTrackerImpl( localproxy, true, true, paramBoolean2); return localproxy; }
public Proxy newMapProxy(Class type, Class keyType, Class elementType, Comparator compare,boolean autoOff) { type = toProxyableMapType(type); ProxyMap proxy = getFactoryProxyMap(type); return proxy.newInstance((_assertType) ? keyType : null, (_assertType) ? elementType : null, compare, _trackChanges, autoOff); }
/** * Call before invoking {@link Map#remove} on super. */ public static boolean beforeRemove(ProxyMap map, Object key) { dirty(map, false); return map.containsKey(key); }
@Override public ProxyCollection newInstance(Class paramClass, Comparator paramComparator, boolean paramBoolean1, boolean paramBoolean2) { DelayedArrayListProxy proxy = new DelayedArrayListProxy(); proxy.elementType = paramClass; proxy.changeTracker = new DelayedCollectionChangeTrackerImpl(proxy, true, true, paramBoolean2); return proxy; }