ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
ilTestExportFactory Class Reference
+ Collaboration diagram for ilTestExportFactory:

Public Member Functions

 __construct (ilObjTest $testOBJ)
 
 getExporter ($mode="xml")
 

Protected Attributes

 $testOBJ
 

Detailed Description

Definition at line 25 of file class.ilTestExportFactory.php.

Constructor & Destructor Documentation

◆ __construct()

ilTestExportFactory::__construct ( ilObjTest  $testOBJ)

Definition at line 32 of file class.ilTestExportFactory.php.

References $testOBJ.

33  {
34  $this->testOBJ = $testOBJ;
35  }

Member Function Documentation

◆ getExporter()

ilTestExportFactory::getExporter (   $mode = "xml")
Parameters
string$mode
Returns
ilTestExportDynamicQuestionSet|ilTestExportFixedQuestionSet|ilTestExportRandomQuestionSet

Definition at line 41 of file class.ilTestExportFactory.php.

Referenced by ilTestExportFactoryTest\testGetExporter().

42  {
43  if ($this->testOBJ->isFixedTest()) {
44  return new ilTestExportFixedQuestionSet($this->testOBJ, $mode);
45  } elseif ($this->testOBJ->isRandomTest()) {
46  return new ilTestExportRandomQuestionSet($this->testOBJ, $mode);
47  }
48  return new ilTestExportDynamicQuestionSet($this->testOBJ, $mode);
49  }
+ Here is the caller graph for this function:

Field Documentation

◆ $testOBJ

ilTestExportFactory::$testOBJ
protected

Definition at line 30 of file class.ilTestExportFactory.php.

Referenced by __construct().


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