org.w3c.tools.resources
Class ExternalContainer
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.tools.resources.ContainerResource
org.w3c.tools.resources.ExternalContainer
- All Implemented Interfaces:
- java.lang.Cloneable, java.util.EventListener, ContainerInterface, AttributeChangedListener, FrameEventListener, StructureChangedListener
- Direct Known Subclasses:
- AuthRealm, IndexersCatalog, RealmsCatalog, TemplateContainer
public abstract class ExternalContainer
- extends ContainerResource
A Container which manage an external store, outside the space.
Field Summary |
protected java.io.File |
repository
Our external repository. |
protected boolean |
transientFlag
Our transientFlag, is true that container must not be saved. |
Methods inherited from class org.w3c.tools.resources.ContainerResource |
addResource, delete, deleteChildren, enumerateResourceIdentifiers, getChildrenSpaceEntry, getClone, getKey, getMatchingCharsCount, getSpaceEntry, internalLookup, lookup, lookup, notifyUnload, registerResource, replace, resourceCreated, resourceModified, resourceRemoved, updateDefaultChildAttributes |
Methods inherited from class org.w3c.tools.resources.FramedResource |
addAttributeChangedListener, addStructureChangedListener, collectFramesReference, disableEvent, displayEvent, enableEvent, eventDisabled, fireAttributeChangeEvent, fireStructureChangedEvent, fireStructureChangedEvent, frameAdded, frameModified, frameRemoved, getFrame, getFrame, getFrameReference, getFrameReference, getFramesReference, getOid, 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, getServer, getSpace, getStoreEntry, getURLPath, getValue, getValue, initialize, isInitialized, isUnloaded, pickleValues, setContext, setContext, setValue, unsafeGetContext, unsafeGetFrame, unsafeGetFrames, unsafeGetIdentifier, unsafeGetResourceReference, unsafeGetURLPath, unsafeGetValue, updateAttributes |
Methods inherited from class org.w3c.tools.resources.AttributeHolder |
definesAttribute, definesAttribute, getAttributes, getBoolean, getChar, getClone, getClone, getDouble, getFloat, getInt, getLong, getString, getValue, lookupAttribute, print, setBoolean, setChar, setDouble, setFloat, setInt, setLong, setString, setValue, unsafeDefinesAttribute, unsafeGetDouble, unsafeGetString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
transientFlag
protected boolean transientFlag
- Our transientFlag, is true that container must not be saved.
repository
protected java.io.File repository
- Our external repository.
ExternalContainer
public ExternalContainer(java.lang.String identifier,
ResourceContext context,
boolean transientFlag)
- Parameters:
id
- The identifier.context
- The default context.transientFlag
- The transient flag.
ExternalContainer
public ExternalContainer()
createDefaultResource
public ResourceReference createDefaultResource(java.lang.String name)
- Description copied from class:
ContainerResource
- 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 ContainerResource
- Parameters:
name
- The identifier for the new resource.
markModified
public void markModified()
- Mark this resource as having been modified.
- Overrides:
markModified
in class FramedResource
acquireChildren
protected void acquireChildren()
- acquire children and notify space if we will be saved.
- Overrides:
acquireChildren
in class ContainerResource
delete
public void delete()
throws MultipleLockException
- Delete this Resource instance , and remove it from its store.
This method will erase definitely this resource, for ever, by removing
it from its resource store (when doable).
- Overrides:
delete
in class ContainerResource
- Throws:
MultipleLockException
- if someone has locked this resource.
getRepository
public abstract java.io.File getRepository(ResourceContext context)
- Get The repository for this external container.
Warning: called in the constructor!
- Parameters:
context
- The container context.
- Returns:
- A File instance
initialize
public void initialize(java.lang.Object[] values)
- Description copied from class:
ContainerResource
- Initialize ourself.
As we are a container resource that really contains something, we make
sure our URL ends properly with a slash.
- Overrides:
initialize
in class ContainerResource
- Parameters:
values
- Our default attribute values.