org.olat.ims.qti.process
Class AssessmentInstance

java.lang.Object
  extended by org.olat.ims.qti.process.AssessmentInstance
All Implemented Interfaces:
java.io.Serializable

public class AssessmentInstance
extends java.lang.Object
implements java.io.Serializable

Author:
Felix Jost
See Also:
Serialized Form

Field Summary
static java.lang.String QMD_ENTRY_MENU_NO
           
static java.lang.String QMD_ENTRY_MENU_YES
           
static java.lang.String QMD_ENTRY_SEQUENCE_ITEM
           
static java.lang.String QMD_ENTRY_SEQUENCE_SECTION
           
static java.lang.String QMD_ENTRY_SUMMARY_COMPACT
           
static java.lang.String QMD_ENTRY_SUMMARY_DETAILED
           
static java.lang.String QMD_ENTRY_SUMMARY_NONE
           
static java.lang.String QMD_ENTRY_SUMMARY_SECTION
           
static java.lang.String QMD_ENTRY_TYPE_ASSESS
           
static java.lang.String QMD_ENTRY_TYPE_SELF
           
static java.lang.String QMD_ENTRY_TYPE_SURVEY
           
static java.lang.String QMD_LABEL_MENU
           
static java.lang.String QMD_LABEL_SEQUENCE
           
static java.lang.String QMD_LABEL_TYPE
           
static int SUMMARY_COMPACT
           
static int SUMMARY_DETAILED
           
static int SUMMARY_NONE
           
static int SUMMARY_SECTION
           
 
Constructor Summary
AssessmentInstance()
          Constructor for AssessmentInstance.
AssessmentInstance(long repositoryEntryKey, long assessID, Resolver resolver, Persister persistor, ModuleConfiguration modConfig)
           
 
Method Summary
 void addObjectBankRef(java.lang.String sourceBankRef)
           
 void close()
          Method close.
 long getAssessID()
          Returns the assessID.
 AssessmentContext getAssessmentContext()
           
 java.lang.String getFormattedType()
          Return this instance's type as readable string
static java.lang.String getFormattedType(int iType)
          Return the type code as readable string.
 Navigator getNavigator()
          Returns the navigator.
 Persister getPersister()
           
 long getRepositoryEntryKey()
          Returns the dlVersionID.
 Resolver getResolver()
           
 java.util.List getSourceBankRefs()
           
 int getSummaryType()
          Get the summary type
static int getSummaryType(java.lang.String confSummary)
          Maps the configured summary to the summary types.
 int getType()
           
 boolean isAssess()
           
 boolean isClosed()
           
 boolean isDisplayTitles()
           
 boolean isMenu()
           
 boolean isPreview()
           
 boolean isResuming()
           
 boolean isSectionPage()
           
 boolean isSelfAssess()
           
 boolean isSurvey()
           
 void persist()
           
 void resume()
           
 void setPersister(Persister persister)
          Sets the persistor.
 void setPreview(boolean b)
           
 void setResolver(Resolver resolver)
          Sets the resolver.
 void setResuming(boolean resuming)
          Sets the resuming.
 void start()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SUMMARY_NONE

public static final int SUMMARY_NONE
See Also:
Constant Field Values

SUMMARY_COMPACT

public static final int SUMMARY_COMPACT
See Also:
Constant Field Values

SUMMARY_DETAILED

public static final int SUMMARY_DETAILED
See Also:
Constant Field Values

SUMMARY_SECTION

public static final int SUMMARY_SECTION
See Also:
Constant Field Values

QMD_LABEL_TYPE

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

QMD_ENTRY_TYPE_ASSESS

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

QMD_ENTRY_TYPE_SELF

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

QMD_ENTRY_TYPE_SURVEY

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

QMD_LABEL_MENU

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

QMD_ENTRY_MENU_YES

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

QMD_ENTRY_MENU_NO

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

QMD_LABEL_SEQUENCE

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

QMD_ENTRY_SEQUENCE_SECTION

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

QMD_ENTRY_SEQUENCE_ITEM

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

QMD_ENTRY_SUMMARY_NONE

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

QMD_ENTRY_SUMMARY_COMPACT

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

QMD_ENTRY_SUMMARY_DETAILED

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

QMD_ENTRY_SUMMARY_SECTION

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

AssessmentInstance

public AssessmentInstance()
Constructor for AssessmentInstance. Needed for deserialisation


AssessmentInstance

public AssessmentInstance(long repositoryEntryKey,
                          long assessID,
                          Resolver resolver,
                          Persister persistor,
                          ModuleConfiguration modConfig)
Parameters:
repositoryEntryKey -
assessID -
resolver -
persistor - the Persistor, may be null
modConfig -
Method Detail

getType

public int getType()

getFormattedType

public java.lang.String getFormattedType()
Return this instance's type as readable string

Returns:
String

getFormattedType

public static java.lang.String getFormattedType(int iType)
Return the type code as readable string.

Parameters:
iType -
Returns:
String

isAssess

public boolean isAssess()

isSelfAssess

public boolean isSelfAssess()

isSurvey

public boolean isSurvey()

resume

public void resume()

getNavigator

public Navigator getNavigator()
Returns the navigator.

Returns:
Navigator

start

public void start()

getAssessmentContext

public AssessmentContext getAssessmentContext()
Returns:
AssessmentContext

isMenu

public boolean isMenu()
Returns:
boolean

isDisplayTitles

public boolean isDisplayTitles()
Returns:
boolean

isSectionPage

public boolean isSectionPage()
Returns:
boolean

getSummaryType

public int getSummaryType()
Get the summary type

Returns:

getSummaryType

public static int getSummaryType(java.lang.String confSummary)
Maps the configured summary to the summary types.

Parameters:
confSummary -
Returns:
the summaryType if valid input confSummary, else throws a AssertException!

close

public void close()
Method close.


getResolver

public Resolver getResolver()
Returns:
Resolver

setResolver

public void setResolver(Resolver resolver)
Sets the resolver.

Parameters:
resolver - The resolver to set

getPersister

public Persister getPersister()
Returns:
Persister

setPersister

public void setPersister(Persister persister)
Sets the persistor.

Parameters:
persistor - The persistor to set

persist

public void persist()

getAssessID

public long getAssessID()
Returns the assessID.

Returns:
long

getRepositoryEntryKey

public long getRepositoryEntryKey()
Returns the dlVersionID.

Returns:
long

addObjectBankRef

public void addObjectBankRef(java.lang.String sourceBankRef)
Parameters:
sourceBankRef -

getSourceBankRefs

public java.util.List getSourceBankRefs()
Returns:
List of all references to sourcebanks that have been used in this run of the assessment

isClosed

public boolean isClosed()
Returns:

isResuming

public boolean isResuming()
Returns:
boolean

setResuming

public void setResuming(boolean resuming)
Sets the resuming.

Parameters:
resuming - The resuming to set

isPreview

public boolean isPreview()
Returns:

setPreview

public void setPreview(boolean b)
Parameters:
b -