|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.w3c.tools.resources.ResourceContext
public class ResourceContext
The resource context.
Field Summary | |
---|---|
protected ResourceReference |
container
The ResourceReference of the resource container. |
static boolean |
debug
debug flag |
java.util.Hashtable |
modules
The set of registered modules. |
protected ResourceContext |
parent
Our parent context, if any. |
protected ResourceReference |
reference
The ResourceReference of our resource. |
protected ServerInterface |
server
The server of that resource context. |
protected ResourceSpace |
space
Our Resource Space. |
Constructor Summary | |
---|---|
ResourceContext(ContainerResource container)
Create a ResourceContext from a container. |
|
ResourceContext(ResourceContext parent)
Create a ResourceContext from the parent context. |
|
ResourceContext(ResourceReference rr_container)
Create a ResourceContext from a container ResourceReference. |
|
ResourceContext(ResourceSpace space,
ServerInterface server)
Create a ResourceContext. |
|
ResourceContext(ServerInterface server)
Create a ResourceContext. |
Method Summary | |
---|---|
ResourceReference |
getContainer()
Get the container of the resource. |
java.lang.Object |
getModule(java.lang.String name)
Lookup a module within that context, and up the hierarchy of contexts. |
java.lang.Object |
getModule(java.lang.String name,
boolean inherited)
Lookup a module within that resource context. |
ResourceContext |
getParent()
Get that context's ancestor. |
ResourceReference |
getResourceReference()
Get the ResourceReference of the resource. |
ServerInterface |
getServer()
Get the server this context is attached to. |
ResourceSpace |
getSpace()
Get our Resource Space. |
void |
registerModule(java.lang.String name,
java.lang.Object impl)
Register a module within that resource context. |
void |
setResourceReference(ResourceReference reference)
Set the ResourceReference of the resource. |
void |
setSpace(ResourceSpace space)
Set the Resource Space. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static boolean debug
protected ResourceContext parent
public java.util.Hashtable modules
protected ResourceSpace space
protected ServerInterface server
protected ResourceReference reference
protected ResourceReference container
Constructor Detail |
---|
public ResourceContext(ContainerResource container)
container
- The resource container.public ResourceContext(ResourceReference rr_container)
container
- The resource reference of the container.
Must be an instance of ContainerResource.public ResourceContext(ResourceContext parent)
parent
- The parent resource context.public ResourceContext(ResourceSpace space, ServerInterface server)
space
- The ResourceSpace.server
- The server.public ResourceContext(ServerInterface server)
server
- The server.Method Detail |
---|
public ResourceReference getContainer()
public ResourceReference getResourceReference()
public void setResourceReference(ResourceReference reference)
reference
- The ResourceReference to set.public ResourceSpace getSpace()
public void setSpace(ResourceSpace space)
space
- Our Resource Space.public ServerInterface getServer()
public ResourceContext getParent()
public void registerModule(java.lang.String name, java.lang.Object impl)
name
- The module's name.impl
- The module's implementation.public java.lang.Object getModule(java.lang.String name, boolean inherited)
name
- Name of the module to look for.inherited
- Also look within the contexts hierarchy for an
inherited module having that name.public java.lang.Object getModule(java.lang.String name)
name
- The module's name.
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |