Class MapProxy<K,V>

java.lang.Object
org.zkoss.bind.proxy.MapProxy<K,V>
All Implemented Interfaces:
Serializable, Map<K,V>, javassist.util.proxy.Proxy, FormProxyObject

public class MapProxy<K,V> extends Object implements Map<K,V>, javassist.util.proxy.Proxy, FormProxyObject, Serializable
A proxy object to implement Map
Since:
8.0.0
Author:
jumperchen
See Also:
  • Constructor Details

  • Method Details

    • getOriginObject

      public Object getOriginObject()
      Description copied from interface: FormProxyObject
      Returns the origin object.
      Specified by:
      getOriginObject in interface FormProxyObject
    • replaceOrigin

      protected Object replaceOrigin(Object origin)
    • entrySet

      public Set<Map.Entry<K,V>> entrySet()
      Specified by:
      entrySet in interface Map<K,V>
    • resetFromOrigin

      public void resetFromOrigin()
      Description copied from interface: FormProxyObject
      Resets all of the changes of this form from the origin object.
      Specified by:
      resetFromOrigin in interface FormProxyObject
    • submitToOrigin

      public void submitToOrigin(BindContext ctx)
      Description copied from interface: FormProxyObject
      Saves all of the changes of this form to the origin object.
      Specified by:
      submitToOrigin in interface FormProxyObject
    • onDirtyChange

      public void onDirtyChange()
    • onDataChange

      public void onDataChange(Object o)
    • setDirty

      protected void setDirty(boolean d)
    • isFormDirty

      public boolean isFormDirty()
      Description copied from interface: FormProxyObject
      Returns whether the form proxy object is dirty or not, including all of its attributes.
      Specified by:
      isFormDirty in interface FormProxyObject
    • setHandler

      public void setHandler(javassist.util.proxy.MethodHandler mi)
      Specified by:
      setHandler in interface javassist.util.proxy.Proxy
    • size

      public int size()
      Specified by:
      size in interface Map<K,V>
    • isEmpty

      public boolean isEmpty()
      Specified by:
      isEmpty in interface Map<K,V>
    • containsKey

      public boolean containsKey(Object key)
      Specified by:
      containsKey in interface Map<K,V>
    • containsValue

      public boolean containsValue(Object value)
      Specified by:
      containsValue in interface Map<K,V>
    • get

      public V get(Object key)
      Specified by:
      get in interface Map<K,V>
    • put

      public V put(K key, V value)
      Specified by:
      put in interface Map<K,V>
    • remove

      public V remove(Object key)
      Specified by:
      remove in interface Map<K,V>
    • putAll

      public void putAll(Map<? extends K,? extends V> m)
      Specified by:
      putAll in interface Map<K,V>
    • clear

      public void clear()
      Specified by:
      clear in interface Map<K,V>
    • keySet

      public Set<K> keySet()
      Specified by:
      keySet in interface Map<K,V>
    • values

      public Collection<V> values()
      Specified by:
      values in interface Map<K,V>
    • setFormOwner

      public void setFormOwner(Object owner, FormBinding binding)
      Description copied from interface: FormProxyObject
      Sets the owner of this form with its binding.
      Specified by:
      setFormOwner in interface FormProxyObject
      Parameters:
      owner - the object associated with this form.
    • cacheSavePropertyBinding

      public void cacheSavePropertyBinding(String property, SavePropertyBinding s)
      Description copied from interface: FormProxyObject
      Cache save property binding by property string
      Specified by:
      cacheSavePropertyBinding in interface FormProxyObject
      Parameters:
      property - the property of save property binding
      s - the save property binding
    • collectCachedSavePropertyBinding

      public Set<org.zkoss.util.Pair<String,SavePropertyBinding>> collectCachedSavePropertyBinding()
      Description copied from interface: FormProxyObject
      Collect all of collect cached save property bindings
      Specified by:
      collectCachedSavePropertyBinding in interface FormProxyObject
    • setPath

      public void setPath(String property, ProxyNode parent)
      Description copied from interface: FormProxyObject
      Set the property of current form proxy object and it's creator
      Specified by:
      setPath in interface FormProxyObject
      Parameters:
      property - p the property
      parent - parent the parent proxy node