All Packages  Class Hierarchy  This Package  Previous  Next  Index

Interface w3c.jigsaw.admin.RemoteResource

public interface RemoteResource
The client side view of a server-side resource. The whole servers state are exported through resources, which allows the administration application to discover and query it using a homogeneous interface. All methods will throw a RemoteAccessException in case of network failure.

See Also:
RemoteBroker

Method Index

 o delete()
Delete that resource, and detach it from its container.
 o enumerateResourceIdentifiers()
 o getAttributes()
Get the target resource list of attributes.
 o getClassHierarchy()
Get the target resource class hierarchy.
 o getFilters()
Get the filters attached to that resource.
 o getValue(String)
 o getValues(String[])
 o isContainer()
 o isFiltered()
Is this resource a filtered resource ?
 o loadResource(String)
 o registerFilter(String, String)
Attach a new filter to that resource.
 o registerResource(String, String)
Register a new resource within this container.
 o setValue(String, Object)
 o setValues(String[], Object[])
Set a set of attribute values in one shot.
 o unregisterFilter(RemoteResource)
Unregister a given filter from that resource.

Methods

 o getClassHierarchy
 public abstract String[] getClassHierarchy() throws RemoteAccessException
Get the target resource class hierarchy. This method will return the class hierarchy as an array of String. The first string in the array is the name of the resource class itself, the last string will always be java.lang.Object.

Returns:
A String array givimg the target resource's class description.
Throws: RemoteAccessException
If somenetwork failure occured.
 o delete
 public abstract void delete() throws RemoteAccessException
Delete that resource, and detach it from its container.

Throws: RemoteAccessException
If somenetwork failure occured.
 o getAttributes
 public abstract Attribute[] getAttributes() throws RemoteAccessException
Get the target resource list of attributes. This method returns the target resource attributes description. The resulting array contains instances of the Attribute class, one item per described attributes.

Even though this returns all the attribute resources, only the ones that are advertized as being editable can be set through this interface.

Returns:
An array of Attribute.
Throws: RemoteAccessException
If somenetwork failure occured.
 o getValue
 public abstract Object getValue(String attr) throws RemoteAccessException
Parameters:
name - The attribute whose value is to be fetched, encoded as its name.
Throws: RemoteAccessException
If somenetwork failure occured.
 o getValues
 public abstract Object[] getValues(String attrs[]) throws RemoteAccessException
Parameters:
attrs - The (ordered) set of attributes whose value is to be fetched.
Returns:
An (ordered) set of values, one per queried attribute.
Throws: RemoteAccessException
If somenetwork failure occured.
 o setValue
 public abstract void setValue(String attr,
                               Object value) throws RemoteAccessException
Parameters:
attr - The attribute to set, encoded as it's name.
value - The new value for that attribute.
Throws: RemoteAccessException
If somenetwork failure occured.
 o setValues
 public abstract void setValues(String attrs[],
                                Object values[]) throws RemoteAccessException
Set a set of attribute values in one shot. This method guarantees that either all setting is done, or none of them are.

Parameters:
attrs - The (ordered) list of attribute to set, encoded as their names.
values - The (ordered) list of values, for each of the above attributes.
Throws: RemoteAccessException
If somenetwork failure occured.
 o isContainer
 public abstract boolean isContainer() throws RemoteAccessException
Throws: RemoteAccessException
If somenetwork failure occured.
 o enumerateResourceIdentifiers
 public abstract String[] enumerateResourceIdentifiers() throws RemoteAccessException
Throws: RemoteAccessException
If somenetwork failure occured.
 o loadResource
 public abstract RemoteResource loadResource(String identifier) throws RemoteAccessException
Throws: RemoteAccessException
If somenetwork failure occured.
 o registerResource
 public abstract RemoteResource registerResource(String id,
                                                 String classname) throws RemoteAccessException
Register a new resource within this container.

Parameters:
id - The identifier of the resource to be created.
classname - The name of the class of the resource to be added.
 o isFiltered
 public abstract boolean isFiltered() throws RemoteAccessException
Is this resource a filtered resource ?

Returns:
A boolean, true if the resource is filtered and it currently has some filters attached, false otherwise.
 o getFilters
 public abstract RemoteResource[] getFilters() throws RemoteAccessException
Get the filters attached to that resource. Each filter is itself a resource, so it is returned as an instance of a remote resource.

Returns:
A (posssibly null) array of filters attached to that resource.
 o unregisterFilter
 public abstract void unregisterFilter(RemoteResource filter) throws RemoteAccessException
Unregister a given filter from that resource.

Parameters:
filter - The filter to unregister.
 o registerFilter
 public abstract RemoteResource registerFilter(String identifier,
                                               String classname) throws RemoteAccessException
Attach a new filter to that resource.

Parameters:
identifier - The name for this filter (if any).
clsname - The name of the filter's class.
Returns:
A remote handle to the (remotely) created filter instance.

All Packages  Class Hierarchy  This Package  Previous  Next  Index