ILIAS  Release_5_0_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilUserImporter Class Reference

Importer class for user data. More...

+ Inheritance diagram for ilUserImporter:
+ Collaboration diagram for ilUserImporter:

Public Member Functions

 init ()
 Initialisation.
 importXmlRepresentation ($a_entity, $a_id, $a_xml, $a_mapping)
 Import XML.
 finalProcessing ($a_mapping)
 Final processing.
- Public Member Functions inherited from ilXmlImporter
 __construct ()
 Constructor.
 setInstallId ($a_val)
 Set installation id.
 getInstallId ()
 Get installation id.
 setInstallUrl ($a_val)
 Set installation url.
 getInstallUrl ()
 Get installation url.
 setSchemaVersion ($a_val)
 Set schema version.
 getSchemaVersion ()
 Get schema version.
 setImportDirectory ($a_val)
 Set import directory.
 getImportDirectory ()
 Get import directory.
 setSkipEntities ($a_val)
 Set skip entities.
 getSkipEntities ()
 Get skip entities.

Additional Inherited Members

- Protected Attributes inherited from ilXmlImporter
 $skip_entities = array()

Detailed Description

Importer class for user data.

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

Definition at line 13 of file class.ilUserImporter.php.

Member Function Documentation

ilUserImporter::finalProcessing (   $a_mapping)

Final processing.

Parameters
arraymapping array

Reimplemented from ilXmlImporter.

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

{
if(is_array($this->ds->multi))
{
foreach($this->ds->multi as $usr_id => $values)
{
$usr_obj = new ilObjUser($usr_id);
if(isset($values["interests_general"]))
{
$usr_obj->setGeneralInterests($values["interests_general"]);
}
else
{
$usr_obj->setGeneralInterests();
}
if(isset($values["interests_help_offered"]))
{
$usr_obj->setOfferingHelp($values["interests_help_offered"]);
}
else
{
$usr_obj->setOfferingHelp();
}
if(isset($values["interests_help_looking"]))
{
$usr_obj->setLookingForHelp($values["interests_help_looking"]);
}
else
{
$usr_obj->setLookingForHelp();
}
$usr_obj->updateMultiTextFields();
}
}
}
ilUserImporter::importXmlRepresentation (   $a_entity,
  $a_id,
  $a_xml,
  $a_mapping 
)

Import XML.

Parameters
@return

Reimplemented from ilXmlImporter.

Definition at line 34 of file class.ilUserImporter.php.

References ilXmlImporter\getSchemaVersion().

{
include_once("./Services/DataSet/classes/class.ilDataSetImportParser.php");
$parser = new ilDataSetImportParser($a_entity, $this->getSchemaVersion(),
$a_xml, $this->ds, $a_mapping);
}

+ Here is the call graph for this function:

ilUserImporter::init ( )

Initialisation.

Reimplemented from ilXmlImporter.

Definition at line 19 of file class.ilUserImporter.php.

References ilXmlImporter\getImportDirectory().

{
include_once("./Services/User/classes/class.ilUserDataSet.php");
$this->ds = new ilUserDataSet();
$this->ds->setDSPrefix("ds");
$this->ds->setImportDirectory($this->getImportDirectory());
}

+ Here is the call graph for this function:


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