: Class ControlResource

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.w3c.jigsaw.http
Class ControlResource

    java.lang.Object
      |
      +--org.w3c.tools.resources.AttributeHolder
            |
            +--org.w3c.tools.resources.Resource
                  |
                  +--org.w3c.tools.resources.FramedResource
                        |
                        +--org.w3c.tools.resources.AbstractContainer
                              |
                              +--org.w3c.jigsaw.http.ControlResource

public class ControlResource
extends AbstractContainer

Field Summary
`protected ResourceReference` | `self`
`protected httpd` | `server`

Fields inherited from class org.w3c.tools.resources.FramedResource
`ATTR_OID, attrListener, debugEvent, event_disabled, framesRef, structListener`

Fields inherited from class org.w3c.tools.resources.Resource
`ATTR_CONTEXT, ATTR_HELP_URL, ATTR_IDENTIFIER, ATTR_LAST_MODIFIED, ATTR_PARENT, ATTR_RESOURCE_FRAMES, ATTR_STORE_ENTRY, ATTR_URL`

Fields inherited from class org.w3c.tools.resources.AttributeHolder
`attributes, values`

Constructor Summary
`ControlResource(httpd server)`

Method Summary
`ResourceReference` | `createDefaultResource(java.lang.String name)` Create a default child resource in that container.
`void` | `delete(java.lang.String name)` Remove a child resource from that container.
`java.util.Enumeration` | `enumerateResourceIdentifiers(boolean all)` Enumerate children resource identifiers.
`ServerInterface` | `getServer()` Get the server this resource is served by.
`java.lang.Object` | `getValue(int idx, java.lang.Object def)` Generic get of an attribute value.
`ResourceReference` | `lookup(java.lang.String name)` Lookup a children in the container.
`void` | `registerResource(java.lang.String n, Resource c, java.util.Hashtable d)` Initialize and register the given resource within that container.
`protected void` | `saveProperties()`

Methods inherited from class org.w3c.tools.resources.AbstractContainer
`attributeChanged, enumerateResourceIdentifiers, resourceCreated, resourceModified, resourceRemoved, resourceUnloaded, updateDefaultChildAttributes`

Methods inherited from class org.w3c.tools.resources.FramedResource
`addAttributeChangedListener, addStructureChangedListener, collectFramesReference, delete, disableEvent, displayEvent, enableEvent, eventDisabled, fireAttributeChangeEvent, fireStructureChangedEvent, fireStructureChangedEvent, frameAdded, frameModified, frameRemoved, getClone, getFrame, getFrame, getFrameReference, getFrameReference, getFramesReference, getOid, initialize, lookup, markModified, notifyUnload, perform, performFrames, postAttributeChangeEvent, postEvent, postStructureChangedEvent, postStructureChangedEvent, processEvent, registerFrame, registerFrameIfNone, removeAttributeChangedListener, removeStructureChangedListener, setSilentValue, setSilentValue, setValue, unregisterFrame`

Methods inherited from class org.w3c.tools.resources.Resource
`acceptUnload, checkMultipleLock, collectFrames, getContext, getFrame, getFrames, getHelpURL, getHelpURL, getIdentifier, getLastModified, getParent, getResourceReference, getSpace, getSpaceEntry, getStoreEntry, getURLPath, getValue, isInitialized, isUnloaded, setContext, setContext, setValue, updateAttributes`

Methods inherited from class org.w3c.tools.resources.AttributeHolder
`definesAttribute, definesAttribute, getAttributes, getBoolean, getChar, getClone, getClone, getDouble, getFloat, getInt, getLong, getString, getValue, initialize, lookupAttribute, pickleValues, print, setBoolean, setChar, setDouble, setFloat, setInt, setLong, setString, setValue, unsafeGetValue`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### server

    protected httpd server

### self

    protected ResourceReference self

Constructor Detail

### ControlResource

    public ControlResource(httpd server)

Method Detail

### registerResource

    public void registerResource(java.lang.String n,
                                 Resource c,
                                 java.util.Hashtable d)

  Description copied from class: AbstractContainer
  Initialize and register the given resource within that container.
  Overrides:
    registerResource in class AbstractContainer
  Tags copied from class: AbstractContainer
  Parameters:
    `name` - The identifier for the resource.
    `resource` - An unitialized resource instance.
    `defs` - A default set of init attribute values (may be null).
  Throws:
    InvalidResourceException - If an error occurs during the registration.

### delete

    public void delete(java.lang.String name)

  Description copied from class: AbstractContainer
  Remove a child resource from that container.
  Overrides:
    delete in class AbstractContainer
  Tags copied from class: AbstractContainer
  Parameters:
    `name` - The name of the child to remove.
  Throws:
    MultipleLockException - If someone else has locked the resource.

### createDefaultResource

    public ResourceReference createDefaultResource(java.lang.String name)

  Description copied from class: AbstractContainer
  Create a default child resource in that container. This method is called by the editor to add a default resource in the container under the given name. The meaning of default is left up to the container here.
  Overrides:
    createDefaultResource in class AbstractContainer
  Tags copied from class: AbstractContainer
  Parameters:
    `name` - The identifier for the new resource.

### saveProperties

    protected void saveProperties()

### lookup

    public ResourceReference lookup(java.lang.String name)

  Description copied from class: AbstractContainer
  Lookup a children in the container.
  Overrides:
    lookup in class AbstractContainer
  Tags copied from class: AbstractContainer
  Parameters:
    `name` - The name of the children to lookup. the resource from its store.

### getServer

    public ServerInterface getServer()

  Get the server this resource is served by.
  Overrides:
    getServer in class Resource
  Returns:
    The first instance of Jigsaw this resource was attached to.

### getValue

    public java.lang.Object getValue(int idx,
                                     java.lang.Object def)

  Description copied from class: AttributeHolder
  Generic get of an attribute value. Retreive an attribute value from its index in the resource's attribute list.
  Overrides:
    getValue in class Resource
  Tags copied from class: AttributeHolder
  Parameters:
    `idx` - The index of the attribute whose value is queried.
    `def` - The default value (if the attribute isn't defined).
  Returns:
    An object, giving the attribute value, or the provided default if this attribute isn't currently define for the resource.
  Throws:
    IllegalAttributeAccess - if the given index doesn't match any of the resource's attributes.

### enumerateResourceIdentifiers

    public java.util.Enumeration enumerateResourceIdentifiers(boolean all)

  Description copied from class: AbstractContainer
  Enumerate children resource identifiers.
  Overrides:
    enumerateResourceIdentifiers in class AbstractContainer
  Tags copied from class: AbstractContainer
  Parameters:
    `all` - Should all resources be enumerated ? Resources are often created on demand only, this flag allows the caller to tell the container about wether it is interested only in already created resources, or in all resources (even the one that have not yet been created).
  Returns:
    An String enumeration, one element per child.

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD