|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecthelma.framework.repository.AbstractRepository
helma.framework.repository.FileRepository
public class FileRepository
Repository implementation for directories providing file resources
Field Summary | |
---|---|
protected java.io.File |
directory
|
protected long |
lastChecksum
|
protected long |
lastChecksumTime
|
protected long |
lastModified
|
Constructor Summary | |
---|---|
FileRepository(java.io.File dir)
Constructs a FileRepository using the given directory as top-level repository |
|
FileRepository(java.io.File dir,
Repository parent)
Constructs a FileRepository using the given directory and top-level repository |
|
FileRepository(java.lang.String initArgs)
Constructs a FileRepository using the given argument |
Method Summary | |
---|---|
void |
create()
Creates the repository if does not exist yet |
protected Resource |
createResource(java.lang.String name)
Called to create a child resource for this repository |
boolean |
equals(java.lang.Object obj)
|
boolean |
exists()
Checks wether the repository actually (or still) exists |
long |
getChecksum()
Checksum of the repository and all its content. |
java.io.File |
getDirectory()
Get the repository's directory |
int |
hashCode()
|
boolean |
isScriptRoot()
Checks wether the repository is to be considered a top-level repository from a scripting point of view. |
long |
lastModified()
Returns the date the repository was last modified. |
java.lang.String |
toString()
Returns the repositories full name as string representation. |
void |
update()
Updates the content cache of the repository Gets called from within all methods returning sub-repositories or resources |
Methods inherited from class helma.framework.repository.AbstractRepository |
---|
getAllResources, getName, getParentRepository, getRepositories, getResource, getResources, getRootRepository, getShortName |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected java.io.File directory
protected long lastModified
protected long lastChecksum
protected long lastChecksumTime
Constructor Detail |
---|
public FileRepository(java.lang.String initArgs)
initArgs
- absolute path to the directorypublic FileRepository(java.io.File dir)
dir
- directorypublic FileRepository(java.io.File dir, Repository parent)
dir
- directoryparent
- the parent repository, or nullMethod Detail |
---|
public boolean exists()
Repository
public void create()
Repository
public boolean isScriptRoot()
public long lastModified()
Repository
public long getChecksum() throws java.io.IOException
Repository
java.io.IOException
public void update()
update
in class AbstractRepository
protected Resource createResource(java.lang.String name)
createResource
in class AbstractRepository
public java.io.File getDirectory()
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public java.lang.String toString()
AbstractRepository
toString
in class AbstractRepository
{getName()}
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |