public class FileSystemProvider extends AbstractFileProvider
All files have ".txt" appended to make life easier for those who insist on using Windows or other software which makes assumptions on the files contents based on its name.
Nested Class Summary
Fields Modifier and Type Field Description
static java.lang.StringAll metadata is stored in a file with this extension.
Fields inherited from class org.apache.wiki.providers.AbstractFileProvider
DEFAULT_ENCODING, DEFAULT_MAX_PROPKEYLENGTH, DEFAULT_MAX_PROPLIMIT, DEFAULT_MAX_PROPVALUELENGTH, FILE_EXT, m_encoding, m_engine, MAX_PROPKEYLENGTH, MAX_PROPLIMIT, MAX_PROPVALUELENGTH, PROP_CUSTOMPROP_MAXKEYLENGTH, PROP_CUSTOMPROP_MAXLIMIT, PROP_CUSTOMPROP_MAXVALUELENGTH, PROP_PAGEDIR
Constructors Constructor Description
Modifier and Type Method Description
(java.lang.String pageName)Removes an entire page from the repository.
(java.lang.String page, int version)Always returns the latest version, since FileSystemProvider does not support versioning.
(java.lang.String from, java.lang.String to)Move a page
Page page, java.lang.String text)(Attempts to save the page text for page "page".
Methods inherited from class org.apache.wiki.providers.AbstractFileProvider
addCustomProperties, deleteVersion, findPage, findPages, getAllChangedSince, getAllPages, getCustomProperties, getPageCount, getPageText, getProviderInfo, getVersionHistory, initialize, mangleName, pageExists, pageExists, setCustomProperties, unmangleName, validateCustomPageProperties
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
putPageTextAttempts to save the page text for page "page". Note that the provider creates a new version regardless of what the version parameter of the WikiPage is.
getPageInfoAlways returns the latest version, since FileSystemProvider does not support versioning. Returns info about the page.
deletePageRemoves an entire page from the repository. The implementations should really do no more security checks, since that is the domain of the PageManager. Just delete it as efficiently as you can. You should also delete any auxiliary files that belong to this page, IF they were created by this provider.
The reason why this is named differently from deleteVersion() (logically, this method should be an overloaded version) is that I want to be absolutely sure I don't accidentally use the wrong method. With overloading something like that happens sometimes...
movePageMove a page
from- Name of the page to move.
to- New name of the page.
ProviderException- If the page could not be moved for some reason.