org.w3c.jigsaw.zip
Class ZipDirectoryResource
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.DirectoryResource
|
+--org.w3c.jigsaw.zip.ZipDirectoryResource
- public class ZipDirectoryResource
- extends org.w3c.tools.resources.DirectoryResource
Field Summary |
protected static int |
ATTR_ENTRYPATH
Attribute index - The index for our entry path. |
protected static int |
ATTR_ZIPFILE
Attributes index - The filename attribute. |
protected java.util.Hashtable |
directories
|
Fields inherited from class org.w3c.tools.resources.DirectoryResource |
ATTR_DIRECTORY,
ATTR_DIRSTAMP,
ATTR_EXTENSIBLE,
ATTR_INDEXER |
Fields inherited from class org.w3c.tools.resources.ContainerResource |
acquired,
ATTR_KEY |
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,
slowpickle,
values |
Method Summary |
org.w3c.tools.resources.ResourceReference |
createDirectoryResource(java.lang.String name)
Create a DirectoryResource and the physical directory too. |
org.w3c.tools.resources.ResourceReference |
createResource(java.lang.String name)
Create a Resource and the physical file too. |
protected boolean |
entryExists(java.lang.String name)
|
protected java.util.Enumeration |
enumerateAllResourceIdentifiers()
Enumerate all available children resource identifiers. |
java.util.Enumeration |
enumerateResourceIdentifiers(boolean all)
Enumerate all available children resource identifiers. |
java.lang.String |
getEntryPath()
|
java.io.File |
getZipFile()
Get this zip file. |
protected org.w3c.tools.resources.Resource |
index(java.lang.String name,
java.util.Hashtable defs,
org.w3c.tools.resources.RequestInterface req)
Index a Resource. |
void |
initialize(java.lang.Object[] values)
|
void |
reindex()
Reindex recursivly all the resources from this DirectoryResource. |
protected org.w3c.tools.resources.ResourceContext |
updateDefaultChildAttributes(java.util.Hashtable attrs)
Initialize and register a new resource into this directory. |
Methods inherited from class org.w3c.tools.resources.DirectoryResource |
createDefaultResource,
createDefaultResource,
createResource,
delete,
getDirectory,
getDirStamp,
getExtensibleFlag,
getIndexedName,
getIndexer,
lookup,
resourceRemoved,
setValue,
verify |
Methods inherited from class org.w3c.tools.resources.ContainerResource |
acquireChildren,
addResource,
delete,
deleteChildren,
getChildrenSpaceEntry,
getClone,
getKey,
getMatchingCharsCount,
getSpaceEntry,
internalLookup,
lookup,
notifyUnload,
registerResource,
replace,
resourceCreated,
resourceModified |
Methods inherited from class org.w3c.tools.resources.AbstractContainer |
attributeChanged,
enumerateResourceIdentifiers,
resourceUnloaded |
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,
markModified,
perform,
performFrames,
postAttributeChangeEvent,
postEvent,
postStructureChangedEvent,
postStructureChangedEvent,
processEvent,
registerFrame,
registerFrameIfNone,
removeAttributeChangedListener,
removeStructureChangedListener,
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,
isInitialized,
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,
pickle,
print,
setBoolean,
setChar,
setDouble,
setFloat,
setInt,
setLong,
setString,
setValue,
unpickle,
unpickle,
unpickle,
unpickleInstance,
unpickleInstance |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
ATTR_ZIPFILE
protected static int ATTR_ZIPFILE
- Attributes index - The filename attribute.
ATTR_ENTRYPATH
protected static int ATTR_ENTRYPATH
- Attribute index - The index for our entry path.
directories
protected java.util.Hashtable directories
ZipDirectoryResource
public ZipDirectoryResource()
getZipFile
public java.io.File getZipFile()
- Get this zip file.
getEntryPath
public java.lang.String getEntryPath()
enumerateAllResourceIdentifiers
protected java.util.Enumeration enumerateAllResourceIdentifiers()
- Enumerate all available children resource identifiers.
This method requires that we create all our pending resources.
- Returns:
- An enumeration of all our resources.
- Overrides:
- enumerateAllResourceIdentifiers in class org.w3c.tools.resources.DirectoryResource
reindex
public void reindex()
- Reindex recursivly all the resources from this DirectoryResource.
- Overrides:
- reindex in class org.w3c.tools.resources.DirectoryResource
updateDefaultChildAttributes
protected org.w3c.tools.resources.ResourceContext updateDefaultChildAttributes(java.util.Hashtable attrs)
- Initialize and register a new resource into this directory.
- Parameters:
resource
- The uninitialized resource to be added.- Overrides:
- updateDefaultChildAttributes in class org.w3c.tools.resources.DirectoryResource
enumerateResourceIdentifiers
public java.util.Enumeration enumerateResourceIdentifiers(boolean all)
- Enumerate all available children resource identifiers.
This method requires that we create all our pending resources
if we are in the extensible mode...too bad !
- Returns:
- An enumeration of all our resources.
- Overrides:
- enumerateResourceIdentifiers in class org.w3c.tools.resources.DirectoryResource
entryExists
protected boolean entryExists(java.lang.String name)
index
protected org.w3c.tools.resources.Resource index(java.lang.String name,
java.util.Hashtable defs,
org.w3c.tools.resources.RequestInterface req)
- Index a Resource. Call the indexer.
- Parameters:
name
- The name of the resource to index.defs
- The defaults attributes.req
- The protocol request.- Returns:
- A resource instance.
- Overrides:
- index in class org.w3c.tools.resources.DirectoryResource
- See Also:
SampleResourceIndexer
createResource
public org.w3c.tools.resources.ResourceReference createResource(java.lang.String name)
- Create a Resource and the physical file too.
- Parameters:
name
- the name of the resource.- Returns:
- A ResourceReference instance.
- Overrides:
- createResource in class org.w3c.tools.resources.DirectoryResource
createDirectoryResource
public org.w3c.tools.resources.ResourceReference createDirectoryResource(java.lang.String name)
- Create a DirectoryResource and the physical directory too.
- Parameters:
name
- the name of the resource.- Returns:
- A ResourceReference instance.
- Overrides:
- createDirectoryResource in class org.w3c.tools.resources.DirectoryResource
initialize
public void initialize(java.lang.Object[] values)
- Overrides:
- initialize in class org.w3c.tools.resources.DirectoryResource