| java.lang.Object vqwiki.WikiBase
WikiBase | public class WikiBase (Code) | | Base class for Wiki. Handles all basic Viki stuff.
author: $author$ version: $Revision: 685 $ |
Method Summary | |
public void | addReadOnlyTopic(String virtualWiki, String topicName) | public void | addTopicListener(TopicListener listener) | public void | addVirtualWiki(String virtualWiki) | public synchronized String | cook(BufferedReader in, String virtualWiki) | public synchronized String | cook(BufferedReader in, String virtualWiki, String formatLexClass, String layoutLexClass, String linkLexClass, boolean export) | public synchronized boolean | exists(String virtualWiki, String topicName) | protected String | fileBase() | public ChangeLog | getChangeLogInstance() | public Handler | getHandler() | public static WikiBase | getInstance() Get a reference of this class. | public Notify | getNotifyInstance(String virtualWiki, String topic) | public Collection | getOrphanedTopics(String virtualWiki) | public Collection | getReadOnlyTopics(String virtualWiki) | public SearchEngine | getSearchEngineInstance() Get an instance to the search enginge. | public String | getTemplate(String virtualWiki, String name) | public Collection | getTemplates(String virtualWiki) | public Collection | getToDoWikiTopics(String virtualWiki) | public Usergroup | getUsergroupInstance() | public VersionManager | getVersionManagerInstance() | public int | getVirtualWikiCount() | public Collection | getVirtualWikiList() | public WikiMembers | getWikiMembersInstance(String virtualWiki) | public synchronized boolean | holdsLock(String virtualWiki, String topicName, String key) | public static void | initialise() | public boolean | isAdminOnlyTopic(Locale locale, String virtualWiki, String topicName) Return true if the given topic is marked as "admin only", i.e. | protected boolean | isTopicReadOnly(String virtualWiki, String topicName) | public Collection | listRecentChanges(String virtualWiki, int numDays) | public synchronized boolean | lockTopic(String virtualWiki, String topicName, String key) | public void | panic() | public Collection | purgeDeletes(String virtualWiki) | public void | purgeVersionsOlderThan(String virtualWiki, DBDate date) | public synchronized String | readCooked(String virtualWiki, String topicName) Returns a topic's content that has been formatted to Wiki conventions. | public synchronized String | readCooked(String virtualWiki, String topicName, String formatLexClass, String layoutLexClass, String linkLexClass, boolean export) | public static String | readDefaultTopic(String topicName) | public synchronized String | readRaw(String virtualWiki, String topicName) Reads a file and returns the raw contents. | public void | removeReadOnlyTopic(String virtualWiki, String topicName) | public void | saveAsTemplate(String virtualWiki, String templateName, String contents) | public synchronized void | unlockTopic(String virtualWiki, String topicName) | public synchronized void | write(String virtualWiki, String contents, boolean convertTabs, String topicName, String user) |
DATABASE | final public static int DATABASE(Code) | | The topics are stored in a database
|
DEFAULT_VWIKI | final public static String DEFAULT_VWIKI(Code) | | Name of the default wiki
|
FILE | final public static int FILE(Code) | | The topics are stored in a flat file
|
LDAP | final public static int LDAP(Code) | | Members are retrieved from LDAP
|
PLUGINS_DIR | final public static String PLUGINS_DIR(Code) | | Name of the Plugins-Directory
|
handler | protected Handler handler(Code) | | The handler that looks after read/write operations for a persitence type
|
addReadOnlyTopic | public void addReadOnlyTopic(String virtualWiki, String topicName) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! Parameters: topicName - TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
addTopicListener | public void addTopicListener(TopicListener listener)(Code) | | Register a topic listener
Parameters: listener - listener |
cook | public synchronized String cook(BufferedReader in, String virtualWiki, String formatLexClass, String layoutLexClass, String linkLexClass, boolean export) throws ClassNotFoundException, NoSuchMethodException, InstantiationException, IllegalAccessException, InvocationTargetException, IOException(Code) | | TODO: DOCUMENT ME!
Parameters: in - TODO: DOCUMENT ME! Parameters: virtualWiki - TODO: DOCUMENT ME! Parameters: formatLexClass - TODO: DOCUMENT ME! Parameters: layoutLexClass - TODO: DOCUMENT ME! Parameters: linkLexClass - TODO: DOCUMENT ME! TODO: DOCUMENT ME! throws: ClassNotFoundException - TODO: DOCUMENT ME! throws: NoSuchMethodException - TODO: DOCUMENT ME! throws: InstantiationException - TODO: DOCUMENT ME! throws: IllegalAccessException - TODO: DOCUMENT ME! throws: InvocationTargetException - TODO: DOCUMENT ME! throws: IOException - TODO: DOCUMENT ME! |
exists | public synchronized boolean exists(String virtualWiki, String topicName) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! Parameters: topicName - TODO: DOCUMENT ME! TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
fileBase | protected String fileBase()(Code) | | TODO: DOCUMENT ME!
TODO: DOCUMENT ME! |
getHandler | public Handler getHandler()(Code) | | return the current handler instance
the current handler instance |
getInstance | public static WikiBase getInstance() throws Exception(Code) | | Get a reference of this class. Implements singleton pattern.
Instance of this class throws: Exception - If the storage produces errors |
getNotifyInstance | public Notify getNotifyInstance(String virtualWiki, String topic) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! Parameters: topic - TODO: DOCUMENT ME! TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
getReadOnlyTopics | public Collection getReadOnlyTopics(String virtualWiki) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
getSearchEngineInstance | public SearchEngine getSearchEngineInstance() throws Exception(Code) | | Get an instance to the search enginge.
Reference to the SearchEngine throws: Exception - the current search engine |
getToDoWikiTopics | public Collection getToDoWikiTopics(String virtualWiki) throws Exception(Code) | | Find all topics that haven't been written but are linked to
|
getUsergroupInstance | public Usergroup getUsergroupInstance() throws Exception(Code) | | Get an instance of the user group
Reference to the SearchEngine throws: Exception - the current search engine |
getVirtualWikiCount | public int getVirtualWikiCount()(Code) | | get a count of the number of virtual wikis in the system
the number of virtual wikis |
getVirtualWikiList | public Collection getVirtualWikiList() throws Exception(Code) | | Return a list of all virtual wikis on the server
|
getWikiMembersInstance | public WikiMembers getWikiMembersInstance(String virtualWiki) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
holdsLock | public synchronized boolean holdsLock(String virtualWiki, String topicName, String key) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! Parameters: topicName - TODO: DOCUMENT ME! Parameters: key - TODO: DOCUMENT ME! TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
initialise | public static void initialise() throws Exception(Code) | | TODO: DOCUMENT ME!
throws: Exception - TODO: DOCUMENT ME! |
isAdminOnlyTopic | public boolean isAdminOnlyTopic(Locale locale, String virtualWiki, String topicName) throws Exception(Code) | | Return true if the given topic is marked as "admin only", i.e. it is present in the admin only topics topic
Parameters: virtualWiki - Parameters: topicName - |
isTopicReadOnly | protected boolean isTopicReadOnly(String virtualWiki, String topicName) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! Parameters: topicName - TODO: DOCUMENT ME! TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
lockTopic | public synchronized boolean lockTopic(String virtualWiki, String topicName, String key) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! Parameters: topicName - TODO: DOCUMENT ME! Parameters: key - TODO: DOCUMENT ME! TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
panic | public void panic()(Code) | | Do emergency repairs by clearing all locks and deleting recent changes files
|
purgeDeletes | public Collection purgeDeletes(String virtualWiki) throws Exception(Code) | | Purge deleted files
a collection of strings that are the deleted topic names |
purgeVersionsOlderThan | public void purgeVersionsOlderThan(String virtualWiki, DBDate date) throws Exception(Code) | | purge versions older than a certain date
|
readCooked | public synchronized String readCooked(String virtualWiki, String topicName) throws Exception(Code) | | Returns a topic's content that has been formatted to Wiki conventions.
Parameters: virtualWiki - the virtual wiki to use Parameters: topicName - the topic |
readCooked | public synchronized String readCooked(String virtualWiki, String topicName, String formatLexClass, String layoutLexClass, String linkLexClass, boolean export) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! Parameters: topicName - TODO: DOCUMENT ME! Parameters: formatLexClass - TODO: DOCUMENT ME! Parameters: layoutLexClass - TODO: DOCUMENT ME! Parameters: linkLexClass - TODO: DOCUMENT ME! TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
readDefaultTopic | public static String readDefaultTopic(String topicName) throws Exception(Code) | | Finds a default topic file and returns the contents
|
readRaw | public synchronized String readRaw(String virtualWiki, String topicName) throws Exception(Code) | | Reads a file and returns the raw contents. Used for the editing version.
|
removeReadOnlyTopic | public void removeReadOnlyTopic(String virtualWiki, String topicName) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! Parameters: topicName - TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
unlockTopic | public synchronized void unlockTopic(String virtualWiki, String topicName) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! Parameters: topicName - TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
write | public synchronized void write(String virtualWiki, String contents, boolean convertTabs, String topicName, String user) throws Exception(Code) | | TODO: DOCUMENT ME!
Parameters: virtualWiki - TODO: DOCUMENT ME! Parameters: contents - TODO: DOCUMENT ME! Parameters: convertTabs - TODO: DOCUMENT ME! Parameters: topicName - TODO: DOCUMENT ME! throws: Exception - TODO: DOCUMENT ME! |
|
|