All Packages Class Hierarchy This Package Previous Next Index
Interface org.webmacro.broker.ResourceMap
- public interface ResourceMap
A ResourceMap gives you what may be a more convenient way to
access the ResourceBroker. It also allows for more convenient
use of the Broker using Property introspection.
Each ResourceMap is associated with exactly one type. The
type string is assumed in each call to the ResourceMap, where
you supply only the name. The interface is very much like the
Dictionary interface, except that teh ResourceMap can raise
a variety of exceptions.
This class is just syntactic sugar over the ResourceBroker.
- See Also:
- Property
-
get(String)
- Get the ResourceEvent with the supplied name.
-
put(String, Object)
- Create and store the ResourceEvent with the supplied name
and optional argument.
-
remove(String)
- Remove the ResourceEvent with this name.
get
public abstract ResourceEvent get(String name) throws InvalidArgumentException, ResourceUnavailableException
- Get the ResourceEvent with the supplied name.
- Throws: ResourceUnavailableException
- request refused
- Throws: InvalidArgumentException
- no such type
- See Also:
- request
remove
public abstract void remove(String name) throws InvalidArgumentException, ResourceUnavailableException
- Remove the ResourceEvent with this name.
- Throws: ResourceUnavailableException
- request refused
- Throws: InvalidArgumentException
- no such type
- See Also:
- ResourceBroker
put
public abstract ResourceEvent put(String name,
Object argument) throws InvalidArgumentException, ResourceUnavailableException
- Create and store the ResourceEvent with the supplied name
and optional argument. Note that you do not need to use this
method (and cannot) for normal storage of an object you have
modified. Nor can you use it to replace an object--it will
fail if the resource already exists.
- Throws: ResourceUnavailableException
- request refused
- Throws: InvalidArgumentException
- no such type
- See Also:
- ResourceEvent
All Packages Class Hierarchy This Package Previous Next Index