com.dyuproject.ioc.config
Class References

java.lang.Object
  extended by com.dyuproject.ioc.config.References
All Implemented Interfaces:
org.mortbay.util.ajax.JSON.Convertible
Direct Known Subclasses:
OverrideReferences

public class References
extends Object
implements org.mortbay.util.ajax.JSON.Convertible

A collection of multiple Reference objects.

Author:
David Yu
Date created:
Feb 20, 2009

Constructor Summary
References()
           
References(Map<String,Object> map)
           
 
Method Summary
 void addRefs(References refs)
          Add refs to this References object.
 void destroy()
          Destroy this object and all its references to other objects.
 void fromJSON(Map map)
           
 Object get(String key)
          Gets a referenced object with the given key.
static References getLast(References refs)
          Looks up the References starting from the last.
static Object getRef(String key, References refs)
          Gets a referenced object from the provided refs.
 Object put(String key, Object value)
          Puts a referenced object with the given key.
 void putAll(Map<String,Object> map)
          Puts a collection of referenced objects.
 void toJSON(org.mortbay.util.ajax.JSON.Output out)
           
static void wrapRefs(References refs, References wrapper)
          Wraps the refs into the wrapper.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

References

public References()

References

public References(Map<String,Object> map)
Method Detail

getLast

public static References getLast(References refs)
Looks up the References starting from the last.


wrapRefs

public static void wrapRefs(References refs,
                            References wrapper)
Wraps the refs into the wrapper.


getRef

public static Object getRef(String key,
                            References refs)
Gets a referenced object from the provided refs.


addRefs

public final void addRefs(References refs)
Add refs to this References object.


put

public final Object put(String key,
                        Object value)
Puts a referenced object with the given key.


get

public final Object get(String key)
Gets a referenced object with the given key.


putAll

public final void putAll(Map<String,Object> map)
Puts a collection of referenced objects.


fromJSON

public final void fromJSON(Map map)
Specified by:
fromJSON in interface org.mortbay.util.ajax.JSON.Convertible

toJSON

public final void toJSON(org.mortbay.util.ajax.JSON.Output out)
Specified by:
toJSON in interface org.mortbay.util.ajax.JSON.Convertible

destroy

public final void destroy()
Destroy this object and all its references to other objects.



Copyright © 2008-2013. All Rights Reserved.