public abstract class AbstractCollectionProxy<E> extends Object implements Collection<E>, javassist.util.proxy.Proxy, FormProxyObject, Serializable, FormProxyObjectListener
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
_dirty |
protected boolean |
isImmutableElements |
| Constructor and Description |
|---|
AbstractCollectionProxy(Collection<E> origin,
Annotation[] callerAnnots) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(E e) |
boolean |
addAll(Collection<? extends E> c) |
void |
addFormProxyObjectListener(FormProxyObjectListener l)
Add listener
|
void |
clear() |
boolean |
contains(Object o) |
boolean |
containsAll(Collection<?> c) |
protected <T extends Collection<E>> |
getCache() |
Object |
getOriginObject()
Returns the origin object.
|
protected abstract Collection<E> |
initCache() |
boolean |
isEmpty() |
boolean |
isFormDirty()
Returns whether the form proxy object is dirty or not, including all
of its attributes.
|
Iterator<E> |
iterator() |
void |
onDataChange(Object o)
Call when the data in FormProxyObject change
|
void |
onDirtyChange()
Call when setting form.dirty true
|
boolean |
remove(Object o) |
boolean |
removeAll(Collection<?> c) |
protected Object |
replaceOrigin(Object origin) |
void |
resetFromOrigin()
Resets all of the changes of this form from the origin object.
|
boolean |
retainAll(Collection<?> c) |
protected void |
setDirty(boolean d) |
void |
setFormOwner(Object owner,
FormBinding binding)
Sets the owner of this form with its binding.
|
void |
setHandler(javassist.util.proxy.MethodHandler mi) |
int |
size() |
void |
submitToOrigin(BindContext ctx)
Saves all of the changes of this form to the origin object.
|
protected static boolean |
testEquals(Object e,
Object o) |
Object[] |
toArray() |
<T> T[] |
toArray(T[] a) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitequals, hashCodeprotected boolean _dirty
protected boolean isImmutableElements
public AbstractCollectionProxy(Collection<E> origin, Annotation[] callerAnnots)
protected abstract Collection<E> initCache()
protected <T extends Collection<E>> T getCache()
public Object getOriginObject()
FormProxyObjectgetOriginObject in interface FormProxyObjectpublic void addFormProxyObjectListener(FormProxyObjectListener l)
FormProxyObjectaddFormProxyObjectListener in interface FormProxyObjectpublic void onDirtyChange()
FormProxyObjectListeneronDirtyChange in interface FormProxyObjectListenerpublic void onDataChange(Object o)
FormProxyObjectListeneronDataChange in interface FormProxyObjectListenerprotected void setDirty(boolean d)
public void setHandler(javassist.util.proxy.MethodHandler mi)
setHandler in interface javassist.util.proxy.Proxypublic int size()
size in interface Collection<E>public boolean isEmpty()
isEmpty in interface Collection<E>public boolean contains(Object o)
contains in interface Collection<E>public void clear()
clear in interface Collection<E>public Object[] toArray()
toArray in interface Collection<E>public <T> T[] toArray(T[] a)
toArray in interface Collection<E>public boolean add(E e)
add in interface Collection<E>public boolean remove(Object o)
remove in interface Collection<E>public boolean addAll(Collection<? extends E> c)
addAll in interface Collection<E>public boolean containsAll(Collection<?> c)
containsAll in interface Collection<E>public boolean removeAll(Collection<?> c)
removeAll in interface Collection<E>public boolean isFormDirty()
FormProxyObjectisFormDirty in interface FormProxyObjectpublic boolean retainAll(Collection<?> c)
retainAll in interface Collection<E>public void resetFromOrigin()
FormProxyObjectresetFromOrigin in interface FormProxyObjectpublic void submitToOrigin(BindContext ctx)
FormProxyObjectsubmitToOrigin in interface FormProxyObjectpublic void setFormOwner(Object owner, FormBinding binding)
FormProxyObjectsetFormOwner in interface FormProxyObjectowner - the object associated with this form.Copyright © 2015. All rights reserved.