ILIAS  Release_5_0_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilAssQuestionPreviewSettings Class Reference
+ Collaboration diagram for ilAssQuestionPreviewSettings:

Public Member Functions

 __construct ($contextRefId)
 init ()
 setContextRefId ($contextRefId)
 getContextRefId ()
 setGenericFeedbackEnabled ($genericFeedbackEnabled)
 isGenericFeedbackEnabled ()
 setSpecificFeedbackEnabled ($specificFeedbackEnabled)
 isSpecificFeedbackEnabled ()
 setHintProvidingEnabled ($hintProvidingEnabled)
 isHintProvidingEnabled ()
 setBestSolutionEnabled ($bestSolutionEnabled)
 isBestSolutionEnabled ()
 isInstantFeedbackNavigationRequired ()
 isHintProvidingNavigationRequired ()

Private Member Functions

 isTestRefId ()
 initSettingsWithTestObject ()
 initSettingsFromPostParameters ()

Private Attributes

 $contextRefId = null
 $genericFeedbackEnabled = false
 $specificFeedbackEnabled = false
 $hintProvidingEnabled = false
 $bestSolutionEnabled = false

Detailed Description

Definition at line 11 of file class.ilAssQuestionPreviewSettings.php.

Constructor & Destructor Documentation

ilAssQuestionPreviewSettings::__construct (   $contextRefId)

Definition at line 23 of file class.ilAssQuestionPreviewSettings.php.

References $contextRefId.

{
$this->contextRefId = $contextRefId;
}

Member Function Documentation

ilAssQuestionPreviewSettings::getContextRefId ( )

Definition at line 73 of file class.ilAssQuestionPreviewSettings.php.

References $contextRefId.

{
}
ilAssQuestionPreviewSettings::init ( )

Definition at line 28 of file class.ilAssQuestionPreviewSettings.php.

References initSettingsFromPostParameters(), initSettingsWithTestObject(), and isTestRefId().

{
if( $this->isTestRefId() )
{
}
else
{
}
}

+ Here is the call graph for this function:

ilAssQuestionPreviewSettings::initSettingsFromPostParameters ( )
private

Definition at line 58 of file class.ilAssQuestionPreviewSettings.php.

References setBestSolutionEnabled(), setGenericFeedbackEnabled(), setHintProvidingEnabled(), and setSpecificFeedbackEnabled().

Referenced by init().

{
// get from post or from toolbar instance if possible
$this->setBestSolutionEnabled(true);
}

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

ilAssQuestionPreviewSettings::initSettingsWithTestObject ( )
private

Definition at line 47 of file class.ilAssQuestionPreviewSettings.php.

References ilObjectFactory\getInstanceByRefId(), setBestSolutionEnabled(), setGenericFeedbackEnabled(), setHintProvidingEnabled(), and setSpecificFeedbackEnabled().

Referenced by init().

{
$testOBJ = ilObjectFactory::getInstanceByRefId($this->contextRefId);
$testOBJ->loadFromDb();
$this->setGenericFeedbackEnabled($testOBJ->getGenericAnswerFeedback());
$this->setSpecificFeedbackEnabled($testOBJ->getSpecificAnswerFeedback());
$this->setHintProvidingEnabled($testOBJ->isOfferingQuestionHintsEnabled());
$this->setBestSolutionEnabled($testOBJ->getInstantFeedbackSolution());
}

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

ilAssQuestionPreviewSettings::isBestSolutionEnabled ( )

Definition at line 113 of file class.ilAssQuestionPreviewSettings.php.

References $bestSolutionEnabled.

Referenced by isInstantFeedbackNavigationRequired().

+ Here is the caller graph for this function:

ilAssQuestionPreviewSettings::isGenericFeedbackEnabled ( )

Definition at line 83 of file class.ilAssQuestionPreviewSettings.php.

References $genericFeedbackEnabled.

Referenced by isInstantFeedbackNavigationRequired().

+ Here is the caller graph for this function:

ilAssQuestionPreviewSettings::isHintProvidingEnabled ( )

Definition at line 103 of file class.ilAssQuestionPreviewSettings.php.

References $hintProvidingEnabled.

Referenced by isHintProvidingNavigationRequired().

+ Here is the caller graph for this function:

ilAssQuestionPreviewSettings::isHintProvidingNavigationRequired ( )

Definition at line 138 of file class.ilAssQuestionPreviewSettings.php.

References isHintProvidingEnabled().

{
return $this->isHintProvidingEnabled();
}

+ Here is the call graph for this function:

ilAssQuestionPreviewSettings::isInstantFeedbackNavigationRequired ( )

Definition at line 118 of file class.ilAssQuestionPreviewSettings.php.

References isBestSolutionEnabled(), isGenericFeedbackEnabled(), and isSpecificFeedbackEnabled().

{
if( $this->isGenericFeedbackEnabled() )
{
return true;
}
{
return true;
}
if( $this->isBestSolutionEnabled() )
{
return true;
}
return false;
}

+ Here is the call graph for this function:

ilAssQuestionPreviewSettings::isSpecificFeedbackEnabled ( )

Definition at line 93 of file class.ilAssQuestionPreviewSettings.php.

References $specificFeedbackEnabled.

Referenced by isInstantFeedbackNavigationRequired().

+ Here is the caller graph for this function:

ilAssQuestionPreviewSettings::isTestRefId ( )
private

Definition at line 40 of file class.ilAssQuestionPreviewSettings.php.

References ilObject\_lookupType().

Referenced by init().

{
$objectType = ilObject::_lookupType($this->contextRefId, true);
return $objectType == 'tst';
}

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

ilAssQuestionPreviewSettings::setBestSolutionEnabled (   $bestSolutionEnabled)

Definition at line 108 of file class.ilAssQuestionPreviewSettings.php.

References $bestSolutionEnabled.

Referenced by initSettingsFromPostParameters(), and initSettingsWithTestObject().

{
$this->bestSolutionEnabled = $bestSolutionEnabled;
}

+ Here is the caller graph for this function:

ilAssQuestionPreviewSettings::setContextRefId (   $contextRefId)

Definition at line 68 of file class.ilAssQuestionPreviewSettings.php.

References $contextRefId.

{
$this->contextRefId = $contextRefId;
}
ilAssQuestionPreviewSettings::setGenericFeedbackEnabled (   $genericFeedbackEnabled)

Definition at line 78 of file class.ilAssQuestionPreviewSettings.php.

References $genericFeedbackEnabled.

Referenced by initSettingsFromPostParameters(), and initSettingsWithTestObject().

{
$this->genericFeedbackEnabled = $genericFeedbackEnabled;
}

+ Here is the caller graph for this function:

ilAssQuestionPreviewSettings::setHintProvidingEnabled (   $hintProvidingEnabled)

Definition at line 98 of file class.ilAssQuestionPreviewSettings.php.

References $hintProvidingEnabled.

Referenced by initSettingsFromPostParameters(), and initSettingsWithTestObject().

{
$this->hintProvidingEnabled = $hintProvidingEnabled;
}

+ Here is the caller graph for this function:

ilAssQuestionPreviewSettings::setSpecificFeedbackEnabled (   $specificFeedbackEnabled)

Definition at line 88 of file class.ilAssQuestionPreviewSettings.php.

References $specificFeedbackEnabled.

Referenced by initSettingsFromPostParameters(), and initSettingsWithTestObject().

{
$this->specificFeedbackEnabled = $specificFeedbackEnabled;
}

+ Here is the caller graph for this function:

Field Documentation

ilAssQuestionPreviewSettings::$bestSolutionEnabled = false
private
ilAssQuestionPreviewSettings::$contextRefId = null
private
ilAssQuestionPreviewSettings::$genericFeedbackEnabled = false
private
ilAssQuestionPreviewSettings::$hintProvidingEnabled = false
private
ilAssQuestionPreviewSettings::$specificFeedbackEnabled = false
private

The documentation for this class was generated from the following file: