ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilSoapDataCollectionAdministration Class Reference
+ Inheritance diagram for ilSoapDataCollectionAdministration:
+ Collaboration diagram for ilSoapDataCollectionAdministration:

Public Member Functions

 exportDataCollectionContent ($sid, $target_ref_id, $table_id=null, $format=ilDclContentExporter::EXPORT_EXCEL, $filepath=null)
 Export DataCollection async. More...
 
- Public Member Functions inherited from ilSoapAdministration
 __construct ($use_nusoap=true)
 Constructor. More...
 
 initErrorWriter ()
 Overwrite error handler. More...
 
 __explodeSid ($sid)
 
 __setMessage ($a_str)
 
 __getMessage ()
 
 __appendMessage ($a_str)
 
 __setMessageCode ($a_code)
 
 __getMessageCode ()
 
 initAuth ($sid)
 Init authentication. More...
 
 initIlias ()
 
 __initAuthenticationObject ($a_auth_mode=AUTH_LOCAL)
 
 __raiseError ($a_message, $a_code)
 
 getNIC ($sid)
 get client information from current as xml result set More...
 
 isFault ($object)
 
 checkObjectAccess ($ref_id, $expected_type, $permission, $returnObject=false)
 check access for ref id: expected type, permission, return object instance if returnobject is true More...
 
 getInstallationInfoXML ()
 
 getClientInfoXML ($clientid)
 

Additional Inherited Members

- Static Public Member Functions inherited from ilSoapAdministration
static return_bytes ($val)
 calculate bytes from K,M,G modifiers e.g: 8M = 8 * 1024 * 1024 bytes More...
 
- Data Fields inherited from ilSoapAdministration
 $sauth = null
 
 $error_method = null
 
- Protected Attributes inherited from ilSoapAdministration
 $soap_check = true
 

Detailed Description

Definition at line 33 of file class.ilSoapDataCollectionAdministration.php.

Member Function Documentation

◆ exportDataCollectionContent()

ilSoapDataCollectionAdministration::exportDataCollectionContent (   $sid,
  $target_ref_id,
  $table_id = null,
  $format = ilDclContentExporter::EXPORT_EXCEL,
  $filepath = null 
)

Export DataCollection async.

Parameters
$sid
$target_ref_id
null | int$table_id
string$format
null | string$filepath
Returns
soap_fault|SoapFault

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

References $format, ilSoapAdministration\__getMessage(), ilSoapAdministration\__getMessageCode(), ilSoapAdministration\__raiseError(), ilObject\_isInTrash(), ilObjDataCollectionAccess\hasReadAccess(), ilSoapAdministration\initAuth(), and ilSoapAdministration\initIlias().

48  {
49  $this->initAuth($sid);
50  $this->initIlias();
51  if (!$this->__checkSession($sid)) {
52  return $this->__raiseError($this->__getMessage(), $this->__getMessageCode());
53  }
54 
55  require_once "Modules/DataCollection/classes/class.ilObjDataCollection.php";
56  if (!$target_obj = new ilObjDataCollection($target_ref_id)) {
57  return $this->__raiseError('No valid target given.', 'CLIENT');
58  }
59 
60  if (ilObject::_isInTrash($target_ref_id)) {
61  return $this->__raiseError(
62  "Parent with ID $target_ref_id has been deleted.",
63  'CLIENT_TARGET_DELETED'
64  );
65  }
66 
67  if (!ilObjDataCollectionAccess::hasReadAccess($target_ref_id)) {
68  return $this->__raiseError(
69  'Check access failed. No permission to read DataCollection',
70  "CLIENT_PERMISSION_ISSUE"
71  );
72  }
73 
74  try {
75  require_once "Modules/DataCollection/classes/Content/class.ilDclContentExporter.php";
76  $exporter = new ilDclContentExporter($target_ref_id, $table_id);
77  return $exporter->export($format, $filepath);
78  } catch (ilException $exception) {
79  return $this->__raiseError($exception->getMessage(), $exception->getCode());
80  }
81  }
$format
Definition: metadata.php:141
static _isInTrash($a_ref_id)
checks wether object is in trash
__raiseError($a_message, $a_code)
initAuth($sid)
Init authentication.
Hook-Class for exporting data-collections (used in SOAP-Class) This Class avoids duplicated code by r...
Class ilObjDataCollection.
+ Here is the call graph for this function:

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