public abstract class FileStore extends Object implements IFileStore
Modifier and Type | Field and Description |
---|---|
protected ArrayList<UpdateResource> |
updates |
Constructor and Description |
---|
FileStore() |
Modifier and Type | Method and Description |
---|---|
void |
addUpdate(UpdateResource update)
Add an update request to the set of changes that need to be made as a result of
applying this gramar
|
void |
commit(String comment,
IGramarContext context)
Commit to the file store all pending resource changes
|
void |
configure(Properties properties)
Configure the filestore with values from the given properties file.
|
protected void |
executeUpdates(String comment,
IGramarContext context) |
void |
free()
Free any cached resources
|
void |
reset()
Initialize to prepare for gramar application.
|
boolean |
sameBytes(String relpath,
InputStream proposed)
Return whether the file at the given path has the same byte content as the
given input stream.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createFolder, createProject, getFileByteContent, getFileContent, log, resourceExists, setFileContent, setFileContent
protected ArrayList<UpdateResource> updates
public boolean sameBytes(String relpath, InputStream proposed) throws IOException
IFileStore
sameBytes
in interface IFileStore
IOException
public void commit(String comment, IGramarContext context) throws GramarException
IFileStore
commit
in interface IFileStore
GramarException
protected void executeUpdates(String comment, IGramarContext context)
public void addUpdate(UpdateResource update)
IFileStore
addUpdate
in interface IFileStore
public void reset()
IFileStore
reset
in interface IFileStore
public void free()
IFileStore
free
in interface IFileStore
public void configure(Properties properties) throws GramarException
IFileStore
configure
in interface IFileStore
GramarException
Copyright © 2015. All rights reserved.