org.olat.course.nodes.wiki
Class WikiEditController

java.lang.Object
  extended by org.olat.core.gui.control.DefaultController
      extended by org.olat.core.gui.control.controller.BasicController
          extended by org.olat.core.gui.control.generic.tabbable.TabbableDefaultController
              extended by org.olat.core.gui.control.generic.tabbable.ActivateableTabbableDefaultController
                  extended by org.olat.course.nodes.wiki.WikiEditController
All Implemented Interfaces:
Controller, ControllerEventListener, Disposable, Activateable, TabbableController

public class WikiEditController
extends ActivateableTabbableDefaultController
implements ControllerEventListener

Description:
Edit controller for single page course nodes

Initial Date: Oct 12, 2004

Author:
Felix Jost

Field Summary
static java.lang.String PANE_TAB_ACCESSIBILITY
           
static java.lang.String PANE_TAB_WIKICONFIG
           
static java.lang.String PANE_TAB_WIKIDISPLAYCONFIG
           
 
Constructor Summary
WikiEditController(ModuleConfiguration config, UserRequest ureq, WindowControl wControl, WikiCourseNode wikiCourseNode, ICourse course, UserCourseEnvironment euce)
          Constructor for wiki page editor controller
 
Method Summary
 void addTabs(TabbedPane tabbedPane)
          Add tabs to the given tabbed pane
 void event(UserRequest ureq, Component source, Event event)
          abstract event method for subclasses.
 void event(UserRequest urequest, Controller source, Event event)
          the only method of the interface controllereventlistener.
 java.lang.String[] getPaneKeys()
           
 TabbedPane getTabbedPane()
           
static RepositoryEntry getWikiReference(ModuleConfiguration config, boolean strict)
           
static RepositoryEntry getWikiRepoReference(ModuleConfiguration config, boolean strict)
           
static boolean isModuleConfigValid(ModuleConfiguration moduleConfiguration)
           
static void removeWikiReference(ModuleConfiguration moduleConfig)
          remove ref to wiki from the config
static void setWikiRepoReference(RepositoryEntry re, ModuleConfiguration moduleConfiguration)
          set an repository reference to an wiki course node
 
Methods inherited from class org.olat.core.gui.control.generic.tabbable.ActivateableTabbableDefaultController
activate
 
Methods inherited from class org.olat.core.gui.control.generic.tabbable.TabbableDefaultController
getInitialComponent
 
Methods inherited from class org.olat.core.gui.control.DefaultController
addControllerListener, addLoggingResourceable, dispatchEvent, dispatchEvent, dispose, getControllerCount, getUserActivityLogger, getWindowControlForDebug, isDisposed, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.olat.core.gui.control.ControllerEventListener
dispatchEvent
 
Methods inherited from interface org.olat.core.gui.control.Controller
addControllerListener, dispatchEvent, dispose, getInitialComponent, getUserActivityLogger, getWindowControlForDebug, isDisposed
 

Field Detail

PANE_TAB_ACCESSIBILITY

public static final java.lang.String PANE_TAB_ACCESSIBILITY
See Also:
Constant Field Values

PANE_TAB_WIKICONFIG

public static final java.lang.String PANE_TAB_WIKICONFIG
See Also:
Constant Field Values

PANE_TAB_WIKIDISPLAYCONFIG

public static final java.lang.String PANE_TAB_WIKIDISPLAYCONFIG
See Also:
Constant Field Values
Constructor Detail

WikiEditController

public WikiEditController(ModuleConfiguration config,
                          UserRequest ureq,
                          WindowControl wControl,
                          WikiCourseNode wikiCourseNode,
                          ICourse course,
                          UserCourseEnvironment euce)
Constructor for wiki page editor controller

Parameters:
config - The node module configuration
ureq - The user request
wikiCourseNode - The current wiki page course node
course -
Method Detail

event

public void event(UserRequest ureq,
                  Component source,
                  Event event)
Description copied from class: DefaultController
abstract event method for subclasses. the event received from the component we are listening to are always rerouted to this method here, except when the component has been disposed, in which case the events are simply ignored.

See Also:
DefaultController.event(org.olat.core.gui.UserRequest, org.olat.core.gui.components.Component, org.olat.core.gui.control.Event)

event

public void event(UserRequest urequest,
                  Controller source,
                  Event event)
Description copied from class: DefaultController
the only method of the interface controllereventlistener. always gets called when a controller we 'subscribed' to fires an event. we provide a default implementation here since there are many controllers which are standalone and need no subcontrollers

See Also:
DefaultController.event(org.olat.core.gui.UserRequest, org.olat.core.gui.control.Controller, org.olat.core.gui.control.Event)

addTabs

public void addTabs(TabbedPane tabbedPane)
Description copied from interface: TabbableController
Add tabs to the given tabbed pane

Specified by:
addTabs in interface TabbableController
Parameters:
tabbedPane - The tabbed pane
See Also:
org.olat.core.gui.control.generic.tabbable.TabbableController#addTabs(org.olat.core.gui.components.TabbedPane)

getPaneKeys

public java.lang.String[] getPaneKeys()
Specified by:
getPaneKeys in class ActivateableTabbableDefaultController
Returns:
translation keys for the panes
See Also:
ActivateableTabbableDefaultController.getPaneKeys()

getTabbedPane

public TabbedPane getTabbedPane()
Specified by:
getTabbedPane in class ActivateableTabbableDefaultController
Returns:
tabbed pane
See Also:
ActivateableTabbableDefaultController.getTabbedPane()

getWikiRepoReference

public static RepositoryEntry getWikiRepoReference(ModuleConfiguration config,
                                                   boolean strict)
Parameters:
config - the moduleConfig
strict - an assertion exception is thrown if no entry is found when strict is set to true, otherwise, null is returned
Returns:
the repositoryentry or null if not in strict mode and no entry found
Throws:
AssertException - when in strict mode and no entry is found

setWikiRepoReference

public static void setWikiRepoReference(RepositoryEntry re,
                                        ModuleConfiguration moduleConfiguration)
set an repository reference to an wiki course node

Parameters:
re -
moduleConfiguration -

isModuleConfigValid

public static boolean isModuleConfigValid(ModuleConfiguration moduleConfiguration)
Parameters:
moduleConfiguration -
Returns:
boolean

getWikiReference

public static RepositoryEntry getWikiReference(ModuleConfiguration config,
                                               boolean strict)
Parameters:
config - the moduleConfig
strict - an assertion exception is thrown if no entry is found when strict is set to true, otherwise, null is returned
Returns:
the repositoryentry or null if not in strict mode and no entry found
Throws:
AssertException - when in strict mode and no entry is found

removeWikiReference

public static void removeWikiReference(ModuleConfiguration moduleConfig)
remove ref to wiki from the config

Parameters:
moduleConfig -