ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
ilIndividualAssessmentDataSet Class Reference

Individual Assessment dataset class. More...

+ Inheritance diagram for ilIndividualAssessmentDataSet:
+ Collaboration diagram for ilIndividualAssessmentDataSet:

Public Member Functions

 getSupportedVersions ()
 
 getXmlNamespace ($a_entity, $a_schema_version)
 
 readData ($a_entity, $a_version, $a_ids)
 Read data from Cache for a given entity and ID(s) More...
 
- Public Member Functions inherited from ilDataSet
 __construct ()
 Constructor. More...
 
 init ($a_entity, $a_schema_version)
 Init. More...
 
 getSupportedVersions ()
 Get supported version. More...
 
 readData ($a_entity, $a_version, $a_ids)
 Read data from DB. More...
 
 setExportDirectories ($a_relative, $a_absolute)
 Set export directories. More...
 
 setImportDirectory ($a_val)
 Set import directory. More...
 
 getImportDirectory ()
 Get import directory. More...
 
 setDSPrefix ($a_val)
 Set XML dataset namespace prefix. More...
 
 getDSPrefix ()
 Get XML dataset namespace prefix. More...
 
 getDSPrefixString ()
 
 getDirectDataFromQuery ($a_query, $a_convert_to_leading_upper=true, $a_set=true)
 Get data from query.This is a standard procedure, all db field names are directly mapped to abstract fields. More...
 
 convertToLeadingUpper ($a_str)
 Make xyz_abc a XyzAbc string. More...
 
 getJsonRepresentation ()
 Get json representation. More...
 
 getXmlRepresentation ($a_entity, $a_schema_version, $a_ids, $a_field="", $a_omit_header=false, $a_omit_types=false)
 Get xml representation <dataset install_id="123" install_url="..."> <types entity="table_name" version="4.0.1"> <ftype name="field_1" type="text"> <ftype name="field_2" type="date"> <ftype name="field_3" type="integer"> </types> <types ...> ... More...
 
 addRecordsXml ($a_writer, $a_prefixes, $a_entity, $a_schema_version, $a_ids, $a_field="")
 Add records xml. More...
 
 afterXmlRecordWriting ($a_entity, $a_version, $a_set)
 After xml record writing hook record. More...
 
 getNamespaces (&$namespaces, $a_entity, $a_schema_version)
 Get xml namespaces. More...
 
 getXmlRecord ($a_entity, $a_version, $a_set)
 Get xml record for version. More...
 
 getJsonRecord ($a_set)
 Get json record for version. More...
 
 getXmlTypes ($a_entity, $a_version)
 Get xml types. More...
 
 getJsonTypes ($a_entity, $a_version)
 Get json types. More...
 
 getXMLEntityName ($a_entity, $a_version)
 Get entity name for xml (may be overwritten) More...
 
 getXMLEntityTag ($a_entity, $a_schema_version)
 Get entity tag. More...
 
 getJsonEntityName ($a_entity, $a_version)
 Get entity name for json (may be overwritten) More...
 
 setImport ($a_val)
 Set import object. More...
 
 getImport ()
 Get import object. More...
 
 setCurrentInstallationId ($a_val)
 Set current installation id. More...
 
 getCurrentInstallationId ()
 Get current installation id. More...
 

Protected Member Functions

 getTypes ($a_entity, $a_version)
 Map XML attributes of entities to datatypes (text, integer...) More...
 
 getDependencies ($a_entity, $a_version, $a_rec, $a_ids)
 Return dependencies form entities to other entities (in our case these are all the DB relations) More...
 
 _readData ($a_entity, $a_ids)
 Build data array, data is read from cache except iass object itself. More...
 
- Protected Member Functions inherited from ilDataSet
 getTypes ($a_entity, $a_version)
 Get (abstract) types for (abstract) field names. More...
 
 getXmlNamespace ($a_entity, $a_schema_version)
 Get xml namespace. More...
 
 createObjectExportId ($a_type, $a_id)
 Build ilias export id. More...
 
 parseObjectExportId ($a_id, $a_fallback_id=NULL)
 Parse export id. More...
 

Additional Inherited Members

- Data Fields inherited from ilDataSet
 $dircnt
 
const EXPORT_NO_INST_ID = 1
 
const EXPORT_ID_ILIAS_LOCAL = 2
 
const EXPORT_ID_ILIAS_LOCAL_INVALID = 3
 
const EXPORT_ID_ILIAS_REMOTE = 4
 
const EXPORT_ID_ILIAS_REMOTE_INVALID = 5
 
const EXPORT_ID = 6
 
const EXPORT_ID_INVALID = 7
 
- Protected Attributes inherited from ilDataSet
 $current_installation_id = ""
 

Detailed Description

Member Function Documentation

◆ _readData()

ilIndividualAssessmentDataSet::_readData (   $a_entity,
  $a_ids 
)
protected

Build data array, data is read from cache except iass object itself.

Parameters
string$a_entity
array$a_ids

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

References $data, ilObject\_lookupType(), array, and data.

Referenced by readData().

88  {
89  switch ($a_entity) {
90  case 'iass':
91  foreach ($a_ids as $iass_id) {
92  if (ilObject::_lookupType($iass_id) == 'iass') {
93  $obj = new ilObjIndividualAssessment($iass_id, false);
94  $data = array(
95  'id' => $bibl_id,
96  'title' => $obj->getTitle(),
97  'description' => $obj->getDescription(),
98  'content' => $obj->getSettings()->content(),
99  'recordTemplate' => $obj->getSettings()->recordTemplate(),
100  );
101  $this->data[] = $data;
102  }
103  }
104  break;
105  default:
106  }
107  }
Add some data
For the purpose of streamlining the grading and learning-process status definition outside of tests...
Create styles array
The data for the language used.
static _lookupType($a_id, $a_reference=false)
lookup object type
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getDependencies()

ilIndividualAssessmentDataSet::getDependencies (   $a_entity,
  $a_version,
  $a_rec,
  $a_ids 
)
protected

Return dependencies form entities to other entities (in our case these are all the DB relations)

Parameters
string$a_entity
string$a_version
array$a_rec
array$a_ids
Returns
array

Definition at line 63 of file class.ilIndividualAssessmentDataSet.php.

63  {
64  return false;
65  }

◆ getSupportedVersions()

ilIndividualAssessmentDataSet::getSupportedVersions ( )
Returns
array

Definition at line 15 of file class.ilIndividualAssessmentDataSet.php.

References array.

15  {
16  return array('5.2.0');
17  }
Create styles array
The data for the language used.

◆ getTypes()

ilIndividualAssessmentDataSet::getTypes (   $a_entity,
  $a_version 
)
protected

Map XML attributes of entities to datatypes (text, integer...)

Parameters
string$a_entity
string$a_version
Returns
array

Definition at line 38 of file class.ilIndividualAssessmentDataSet.php.

References array.

38  {
39  switch ($a_entity) {
40  case 'iass':
41  return array(
42  "id" => "integer",
43  "title" => "text",
44  "description" => "text",
45  "content" => "text",
46  "recordTemplate" => "text",
47  );
48  default:
49  return array();
50  }
51  }
Create styles array
The data for the language used.

◆ getXmlNamespace()

ilIndividualAssessmentDataSet::getXmlNamespace (   $a_entity,
  $a_schema_version 
)
Parameters
string$a_entity
string$a_schema_version
Returns
string

Definition at line 26 of file class.ilIndividualAssessmentDataSet.php.

26  {
27  return 'http://www.ilias.de/xml/Modules/IndividualAssessment/'.$a_entity;
28  }

◆ readData()

ilIndividualAssessmentDataSet::readData (   $a_entity,
  $a_version,
  $a_ids 
)

Read data from Cache for a given entity and ID(s)

Parameters
string$a_entity
string$a_version
array$a_idsone or multiple ids

Definition at line 74 of file class.ilIndividualAssessmentDataSet.php.

References _readData(), array, and data.

74  {
75  $this->data = array();
76  if (!is_array($a_ids)) {
77  $a_ids = array($a_ids);
78  }
79  $this->_readData($a_entity, $a_ids);
80  }
Add some data
_readData($a_entity, $a_ids)
Build data array, data is read from cache except iass object itself.
Create styles array
The data for the language used.
+ Here is the call graph for this function:

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