Package org.apache.catalina.servlets
Class DataSourcePropertyStore
java.lang.Object
org.apache.catalina.servlets.DataSourcePropertyStore
- All Implemented Interfaces:
WebdavServlet.PropertyStore
WebDAV dead properties storage backed by a DataSource. Usually table and column names
are configurable, but for simplicity this is not the case.
The schema is:
table properties ( path, namespace, name, node )
path: the resource path
namespace: the node namespace
name: the local name in the namespace
node: the full serialized XML node including the name
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected DataSourceDataSource instance being used.protected static final StringManager -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCopy resource.voidDelete specified resource.voiddestroy()Destroy the store.voidinit()Initialize the store.voidPeriodic event for maintenance tasks.booleanGenerate propfind XML fragments for dead properties.voidproppatch(String resource, ArrayList<WebdavServlet.ProppatchOperation> operations) Apply proppatch to the specified resource.voidsetDataSourceName(String dataSourceName)
-
Field Details
-
sm
-
dataSource
DataSource instance being used.
-
-
Constructor Details
-
DataSourcePropertyStore
public DataSourcePropertyStore()
-
-
Method Details
-
getDataSourceName
- Returns:
- the dataSourceName
-
setDataSourceName
- Parameters:
dataSourceName- the dataSourceName to set
-
init
public void init()Description copied from interface:WebdavServlet.PropertyStoreInitialize the store. This is tied to the Servlet lifecycle and is called by its init method.- Specified by:
initin interfaceWebdavServlet.PropertyStore
-
destroy
public void destroy()Description copied from interface:WebdavServlet.PropertyStoreDestroy the store. This is tied to the Servlet lifecycle and is called by its destroy method.- Specified by:
destroyin interfaceWebdavServlet.PropertyStore
-
periodicEvent
public void periodicEvent()Description copied from interface:WebdavServlet.PropertyStorePeriodic event for maintenance tasks.- Specified by:
periodicEventin interfaceWebdavServlet.PropertyStore
-
copy
Description copied from interface:WebdavServlet.PropertyStoreCopy resource. Dead properties should be copied to the destination path.- Specified by:
copyin interfaceWebdavServlet.PropertyStore- Parameters:
source- the copy source pathdestination- the copy destination path
-
delete
Description copied from interface:WebdavServlet.PropertyStoreDelete specified resource. Dead properties on a deleted resource should be deleted.- Specified by:
deletein interfaceWebdavServlet.PropertyStore- Parameters:
resource- the path of the resource to delete
-
propfind
Description copied from interface:WebdavServlet.PropertyStoreGenerate propfind XML fragments for dead properties.- Specified by:
propfindin interfaceWebdavServlet.PropertyStore- Parameters:
resource- the resource pathproperty- the dead property, if null then all dead properties must be writtennameOnly- true if only the property name element should be generatedgeneratedXML- the current generated XML for the PROPFIND response- Returns:
- true if a property was specified and a corresponding dead property was found on the resource, false otherwise
-
proppatch
Description copied from interface:WebdavServlet.PropertyStoreApply proppatch to the specified resource.- Specified by:
proppatchin interfaceWebdavServlet.PropertyStore- Parameters:
resource- the resource path on which to apply the proppatchoperations- the set and remove to apply, the final status codes of the result should be set on each operation
-