public class FileSite extends WebSite
WebSite.Servlet
Refresh_Prop
Constructor and Description |
---|
FileSite() |
Modifier and Type | Method and Description |
---|---|
protected void |
deleteEntityImpl(Entity anEntity)
Delete entity file and entity table data file.
|
protected void |
deleteFileImpl(WebFile aFile)
Deletes file.
|
protected void |
deleteRowImpl(Row aRow)
Deletes a given row.
|
void |
deleteSite()
Deletes this data source, assuming it corresponds to something that can be deleted, like a database.
|
protected void |
flushImpl()
Override to Saves changes if any made.
|
protected Entity |
getEntityImpl(java.lang.String aName)
Get entity by loading from entity file.
|
protected java.util.List<Row> |
getEntityRows(Entity anEntity)
Returns the list of rows for a given entity.
|
protected byte[] |
getFileBytesImpl(WebFile aFile)
Gets file bytes.
|
protected WebFile |
getFileImpl(java.lang.String aPath)
Returns a file at
|
protected java.util.List<WebFile> |
getFilesImpl(WebFile aFile)
Returns files at path.
|
long |
getModifiedTime(WebFile aFile)
Override to get modified time from Java file.
|
protected java.util.List<Row> |
getRowsImpl(Entity anEntity,
Query aQuery)
Returns a set of rows for the given properties and condition.
|
protected java.io.File |
getStandardFile(java.lang.String aPath)
Returns the Java file for RMFile.
|
protected java.io.File |
getStandardFile(WebFile aFile)
Returns the Java file for a WebFile.
|
protected WebFile |
getTableDataFile(java.lang.String aName,
boolean doCreate)
Returns the file for the given entity.
|
protected WebFile |
getTableEntityFile(java.lang.String aName,
boolean doCreate)
Returns the file for the given entity.
|
protected void |
saveEntityFile(Entity anEntity)
Save entity files for changed entities.
|
protected void |
saveEntityFiles()
Save entity files for changed entities.
|
protected void |
saveEntityImpl(Entity anEntity)
Save entity by saving entity bytes to entity file.
|
protected void |
saveFileImpl(WebFile aFile)
Writes file bytes.
|
protected void |
saveRowImpl(Row aRow)
Inserts or updates a given row.
|
protected void |
setModifiedTimeImpl(WebFile aFile,
long aTime)
Saves the modified time for a file to underlying file system.
|
addDeepChangeListener, bulkImport, createClassLoader, createDataTable, createDataTableImpl, createEntity, createEntityImpl, createFile, createFileImpl, createRow, createRow, createRowImpl, createSandbox, createSandboxURL, createSandboxURLS, createSchema, createSite, createURL, deleteEntity, deleteFile, deleteRow, flush, getClassLoader, getDataTable, getDataTables, getEntity, getExists, getFile, getHostName, getJSONKeys, getName, getPassword, getPath, getProp, getRequest, getResponse, getRootDirectory, getRow, getRow, getRowImpl, getRows, getSandbox, getSchema, getServlet, getURL, getURL, getURLString, getUserName, handleDelete, handleGet, handleHead, handlePut, isRunning, propertyChange, refresh, refreshFile, refreshFileImpl, removeDeepChangeListener, saveEntity, saveFile, saveRow, setClassLoader, setExists, setModifiedTime, setPassword, setProp, setSandbox, setServlet, setURL, setUserName, toString
addPropertyChangeListener, animUpdate, firePropertyChange, firePropertyChange, firePropertyChange, getPCEvent, removePropertyChangeListener, sendPropertyChange
addListener, clone, getListener, getListenerCount, getListenerCount, getListenerList, getListeners, hasListeners, removeListener
protected WebFile getFileImpl(java.lang.String aPath)
getFileImpl
in class WebSite
protected java.util.List<WebFile> getFilesImpl(WebFile aFile) throws java.lang.Exception
getFilesImpl
in class WebSite
java.lang.Exception
protected byte[] getFileBytesImpl(WebFile aFile) throws java.lang.Exception
getFileBytesImpl
in class WebSite
java.lang.Exception
protected void saveFileImpl(WebFile aFile) throws java.lang.Exception
saveFileImpl
in class WebSite
java.lang.Exception
protected void deleteFileImpl(WebFile aFile) throws java.lang.Exception
deleteFileImpl
in class WebSite
java.lang.Exception
public long getModifiedTime(WebFile aFile)
getModifiedTime
in class WebSite
protected void setModifiedTimeImpl(WebFile aFile, long aTime) throws java.lang.Exception
setModifiedTimeImpl
in class WebSite
java.lang.Exception
protected Entity getEntityImpl(java.lang.String aName) throws java.lang.Exception
getEntityImpl
in class WebSite
java.lang.Exception
protected void saveEntityImpl(Entity anEntity) throws java.lang.Exception
saveEntityImpl
in class WebSite
java.lang.Exception
protected void deleteEntityImpl(Entity anEntity) throws java.lang.Exception
deleteEntityImpl
in class WebSite
java.lang.Exception
protected java.util.List<Row> getRowsImpl(Entity anEntity, Query aQuery)
getRowsImpl
in class WebSite
protected void saveRowImpl(Row aRow)
saveRowImpl
in class WebSite
protected void deleteRowImpl(Row aRow)
deleteRowImpl
in class WebSite
protected void saveEntityFiles() throws java.lang.Exception
java.lang.Exception
protected void saveEntityFile(Entity anEntity) throws java.lang.Exception
java.lang.Exception
protected void flushImpl() throws java.lang.Exception
protected WebFile getTableEntityFile(java.lang.String aName, boolean doCreate)
protected WebFile getTableDataFile(java.lang.String aName, boolean doCreate)
protected java.util.List<Row> getEntityRows(Entity anEntity)
public void deleteSite() throws java.lang.Exception
deleteSite
in class WebSite
java.lang.Exception
protected java.io.File getStandardFile(WebFile aFile)
getStandardFile
in class WebSite
protected java.io.File getStandardFile(java.lang.String aPath)