org.olat.course.nodes.iq
Class IQEditController

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.iq.IQEditController
All Implemented Interfaces:
Controller, ControllerEventListener, Disposable, Activateable, TabbableController

public class IQEditController
extends ActivateableTabbableDefaultController
implements ControllerEventListener

Description:
Edit controller for the qti test, selftest and survey course node

Initial Date: Oct 13, 2004

Author:
Felix Jost

Field Summary
static java.lang.String CONFIG_KEY_ALLOW_RELATIVE_LINKS
          configuration key: should relative links like ../otherfolder/my.css be allowed?
static java.lang.String CONFIG_KEY_ATTEMPTS
          configuration key: max attempts
static java.lang.String CONFIG_KEY_CUTVALUE
          configuration key: cut value (socre > cut = passed)
static java.lang.String CONFIG_KEY_DATE_DEPENDENT_RESULTS
           
static java.lang.String CONFIG_KEY_DISCLAIMER
          configuration key: the disclaimer text
static java.lang.String CONFIG_KEY_DISPLAYMENU
          configuration key: display menu switch
static java.lang.String CONFIG_KEY_ENABLECANCEL
          configuration key: enable cancel switch
static java.lang.String CONFIG_KEY_ENABLEMENU
          configuration key: enable menu switch
static java.lang.String CONFIG_KEY_ENABLESCOREINFO
          configuration key: enable 'show score infos' on start page
static java.lang.String CONFIG_KEY_ENABLESUSPEND
          configuration key: enable suspend switch
static java.lang.String CONFIG_KEY_FILE
          configuration key for the filename
static java.lang.String CONFIG_KEY_MAXSCORE
          configuration key: maximal score
static java.lang.String CONFIG_KEY_MINSCORE
          configuration key: minimal score
static java.lang.String CONFIG_KEY_QUESTIONPROGRESS
          configuration key: enable question progress switch
static java.lang.String CONFIG_KEY_QUESTIONTITLE
          configuration key: enable question progress switch
static java.lang.String CONFIG_KEY_RENDERMENUOPTION
          configuration key: all questions, section titles only
static java.lang.String CONFIG_KEY_REPOSITORY_SOFTKEY
          configuration key: repository sof key reference to qti file
static java.lang.String CONFIG_KEY_RESULT_ON_FINISH
           
static java.lang.String CONFIG_KEY_RESULT_ON_HOME_PAGE
           
static java.lang.String CONFIG_KEY_RESULTS_END_DATE
           
static java.lang.String CONFIG_KEY_RESULTS_START_DATE
           
static java.lang.String CONFIG_KEY_SCOREPROGRESS
          configuration key: enable score progress switch
static java.lang.String CONFIG_KEY_SEQUENCE
          configuration key: question sequence: item or selection
static java.lang.String CONFIG_KEY_SUMMARY
          configuration key: show summary: compact or detailed
static java.lang.String CONFIG_KEY_TYPE
          configuration key: mode
static java.lang.String PANE_TAB_ACCESSIBILITY
           
static java.lang.String PANE_TAB_IQCONFIG_SELF
           
static java.lang.String PANE_TAB_IQCONFIG_SURV
           
static java.lang.String PANE_TAB_IQCONFIG_TEST
           
 java.lang.String PANE_TAB_IQCONFIG_XXX
           
 
Constructor Summary
IQEditController(UserRequest ureq, WindowControl wControl, ICourse course, IQSELFCourseNode courseNode, CourseGroupManager groupMgr, UserCourseEnvironment euce)
          Constructor for the IMS QTI edit controller for a self-test course node
IQEditController(UserRequest ureq, WindowControl wControl, ICourse course, IQSURVCourseNode courseNode, CourseGroupManager groupMgr, UserCourseEnvironment euce)
          Constructor for the IMS QTI edit controller for a survey course node
IQEditController(UserRequest ureq, WindowControl wControl, ICourse course, IQTESTCourseNode courseNode, CourseGroupManager groupMgr, UserCourseEnvironment euce)
          Constructor for the IMS QTI edit controller for a test course node
 
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.
static RepositoryEntry getIQReference(ModuleConfiguration config, boolean strict)
          Ge the qti file soft key repository reference
 java.lang.String[] getPaneKeys()
           
 TabbedPane getTabbedPane()
           
static void removeIQReference(ModuleConfiguration moduleConfiguration)
          Remove the reference to the repository entry.
static void setIQReference(RepositoryEntry re, ModuleConfiguration moduleConfiguration)
          Set the referenced repository entry.
 void updateModuleConfigFromQTIFile(OLATResource res)
          Update the module configuration from the qti file: read min/max/cut values
 
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_IQCONFIG_XXX

public final java.lang.String PANE_TAB_IQCONFIG_XXX

PANE_TAB_IQCONFIG_SURV

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

PANE_TAB_IQCONFIG_SELF

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

PANE_TAB_IQCONFIG_TEST

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

PANE_TAB_ACCESSIBILITY

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

CONFIG_KEY_REPOSITORY_SOFTKEY

public static final java.lang.String CONFIG_KEY_REPOSITORY_SOFTKEY
configuration key: repository sof key reference to qti file

See Also:
Constant Field Values

CONFIG_KEY_DISCLAIMER

public static final java.lang.String CONFIG_KEY_DISCLAIMER
configuration key: the disclaimer text

See Also:
Constant Field Values

CONFIG_KEY_ENABLEMENU

public static final java.lang.String CONFIG_KEY_ENABLEMENU
configuration key: enable menu switch

See Also:
Constant Field Values

CONFIG_KEY_DISPLAYMENU

public static final java.lang.String CONFIG_KEY_DISPLAYMENU
configuration key: display menu switch

See Also:
Constant Field Values

CONFIG_KEY_RENDERMENUOPTION

public static final java.lang.String CONFIG_KEY_RENDERMENUOPTION
configuration key: all questions, section titles only

See Also:
Constant Field Values

CONFIG_KEY_SCOREPROGRESS

public static final java.lang.String CONFIG_KEY_SCOREPROGRESS
configuration key: enable score progress switch

See Also:
Constant Field Values

CONFIG_KEY_ENABLECANCEL

public static final java.lang.String CONFIG_KEY_ENABLECANCEL
configuration key: enable cancel switch

See Also:
Constant Field Values

CONFIG_KEY_ENABLESUSPEND

public static final java.lang.String CONFIG_KEY_ENABLESUSPEND
configuration key: enable suspend switch

See Also:
Constant Field Values

CONFIG_KEY_QUESTIONPROGRESS

public static final java.lang.String CONFIG_KEY_QUESTIONPROGRESS
configuration key: enable question progress switch

See Also:
Constant Field Values

CONFIG_KEY_QUESTIONTITLE

public static final java.lang.String CONFIG_KEY_QUESTIONTITLE
configuration key: enable question progress switch

See Also:
Constant Field Values

CONFIG_KEY_SEQUENCE

public static final java.lang.String CONFIG_KEY_SEQUENCE
configuration key: question sequence: item or selection

See Also:
Constant Field Values

CONFIG_KEY_TYPE

public static final java.lang.String CONFIG_KEY_TYPE
configuration key: mode

See Also:
Constant Field Values

CONFIG_KEY_SUMMARY

public static final java.lang.String CONFIG_KEY_SUMMARY
configuration key: show summary: compact or detailed

See Also:
Constant Field Values

CONFIG_KEY_ATTEMPTS

public static final java.lang.String CONFIG_KEY_ATTEMPTS
configuration key: max attempts

See Also:
Constant Field Values

CONFIG_KEY_MINSCORE

public static final java.lang.String CONFIG_KEY_MINSCORE
configuration key: minimal score

See Also:
Constant Field Values

CONFIG_KEY_MAXSCORE

public static final java.lang.String CONFIG_KEY_MAXSCORE
configuration key: maximal score

See Also:
Constant Field Values

CONFIG_KEY_CUTVALUE

public static final java.lang.String CONFIG_KEY_CUTVALUE
configuration key: cut value (socre > cut = passed)

See Also:
Constant Field Values

CONFIG_KEY_FILE

public static final java.lang.String CONFIG_KEY_FILE
configuration key for the filename

See Also:
Constant Field Values

CONFIG_KEY_ALLOW_RELATIVE_LINKS

public static final java.lang.String CONFIG_KEY_ALLOW_RELATIVE_LINKS
configuration key: should relative links like ../otherfolder/my.css be allowed?

See Also:
Constant Field Values

CONFIG_KEY_ENABLESCOREINFO

public static final java.lang.String CONFIG_KEY_ENABLESCOREINFO
configuration key: enable 'show score infos' on start page

See Also:
Constant Field Values

CONFIG_KEY_DATE_DEPENDENT_RESULTS

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

CONFIG_KEY_RESULTS_START_DATE

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

CONFIG_KEY_RESULTS_END_DATE

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

CONFIG_KEY_RESULT_ON_FINISH

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

CONFIG_KEY_RESULT_ON_HOME_PAGE

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

IQEditController

public IQEditController(UserRequest ureq,
                        WindowControl wControl,
                        ICourse course,
                        IQTESTCourseNode courseNode,
                        CourseGroupManager groupMgr,
                        UserCourseEnvironment euce)
Constructor for the IMS QTI edit controller for a test course node

Parameters:
ureq - The user request
wControl - The window controller
course - The course
courseNode - The test course node
groupMgr -
euce -

IQEditController

public IQEditController(UserRequest ureq,
                        WindowControl wControl,
                        ICourse course,
                        IQSELFCourseNode courseNode,
                        CourseGroupManager groupMgr,
                        UserCourseEnvironment euce)
Constructor for the IMS QTI edit controller for a self-test course node

Parameters:
ureq - The user request
wControl - The window controller
course - The course
courseNode - The self course node
groupMgr -
euce -

IQEditController

public IQEditController(UserRequest ureq,
                        WindowControl wControl,
                        ICourse course,
                        IQSURVCourseNode courseNode,
                        CourseGroupManager groupMgr,
                        UserCourseEnvironment euce)
Constructor for the IMS QTI edit controller for a survey course node

Parameters:
ureq - The user request
wControl - The window controller
course - The course
courseNode - The survey course node
groupMgr -
euce -
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.TabbableDefaultController#addTabs(org.olat.core.gui.components.TabbedPane)

getIQReference

public static RepositoryEntry getIQReference(ModuleConfiguration config,
                                             boolean strict)
Ge the qti file soft key repository reference

Parameters:
config -
strict -
Returns:
RepositoryEntry

setIQReference

public static void setIQReference(RepositoryEntry re,
                                  ModuleConfiguration moduleConfiguration)
Set the referenced repository entry.

Parameters:
re -
moduleConfiguration -

removeIQReference

public static void removeIQReference(ModuleConfiguration moduleConfiguration)
Remove the reference to the repository entry.

Parameters:
moduleConfiguration -

updateModuleConfigFromQTIFile

public void updateModuleConfigFromQTIFile(OLATResource res)
Update the module configuration from the qti file: read min/max/cut values

Parameters:
res -

getPaneKeys

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

getTabbedPane

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