ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilNusoapUserAdministrationAdapter Class Reference
+ Collaboration diagram for ilNusoapUserAdministrationAdapter:

Public Member Functions

 __construct ($a_use_wsdl=true)
 
 start ()
 
 __enableWSDL ()
 
 __registerMethods ()
 

Data Fields

 $server = null
 

Protected Member Functions

 handleSoapPlugins ()
 Register any methods and types of SOAP plugins to the SOAP server. More...
 

Detailed Description

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

Constructor & Destructor Documentation

◆ __construct()

ilNusoapUserAdministrationAdapter::__construct (   $a_use_wsdl = true)

Definition at line 49 of file class.ilNusoapUserAdministrationAdapter.php.

References __enableWSDL(), and __registerMethods().

50  {
51  define('SERVICE_NAME', 'ILIASSoapWebservice');
52  define('SERVICE_NAMESPACE', 'urn:ilUserAdministration');
53  define('SERVICE_STYLE', 'rpc');
54  define('SERVICE_USE', 'encoded');
55  $this->server = new soap_server();
56  $this->server->decode_utf8 = false;
57  $this->server->class = "ilSoapFunctions";
58 
59  if ($a_use_wsdl) {
60  $this->__enableWSDL();
61  }
62 
63  $this->__registerMethods();
64  }
soap_server allows the user to create a SOAP server that is capable of receiving messages and returni...
Definition: nusoap.php:2313
+ Here is the call graph for this function:

Member Function Documentation

◆ __enableWSDL()

ilNusoapUserAdministrationAdapter::__enableWSDL ( )

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

Referenced by __construct().

75  {
76  $this->server->configureWSDL(SERVICE_NAME, SERVICE_NAMESPACE);
77 
78  return true;
79  }
+ Here is the caller graph for this function:

◆ __registerMethods()

ilNusoapUserAdministrationAdapter::__registerMethods ( )

Definition at line 82 of file class.ilNusoapUserAdministrationAdapter.php.

References $_GET, and handleSoapPlugins().

Referenced by __construct().

83  {
84 
85  // Add useful complex types. E.g. array("a","b") or array(1,2)
86  $this->server->wsdl->addComplexType(
87  'intArray',
88  'complexType',
89  'array',
90  '',
91  'SOAP-ENC:Array',
92  array(),
93  array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'xsd:int[]')),
94  'xsd:int'
95  );
96 
97  $this->server->wsdl->addComplexType(
98  'stringArray',
99  'complexType',
100  'array',
101  '',
102  'SOAP-ENC:Array',
103  array(),
104  array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'xsd:string[]')),
105  'xsd:string'
106  );
107 
108  $this->server->wsdl->addComplexType(
109  'doubleArray',
110  'complexType',
111  'array',
112  '',
113  'SOAP-ENC:Array',
114  array(),
115  array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType'=>'xsd:double[]')),
116  'xsd:double'
117  );
118 
119  // It's not possible to register classes in nusoap
120 
121  // login()
122  $this->server->register(
123  'login',
124  array('client' => 'xsd:string',
125  'username' => 'xsd:string',
126  'password' => 'xsd:string'),
127  array('sid' => 'xsd:string'),
128  SERVICE_NAMESPACE,
129  SERVICE_NAMESPACE . '#login',
130  SERVICE_STYLE,
131  SERVICE_USE,
132  'ILIAS login function'
133  );
134 
135  // loginCAS()
136  $this->server->register(
137  'loginCAS',
138  array('client' => 'xsd:string',
139  'PT' => 'xsd:string',
140  'user' => 'xsd:string'),
141  array('sid' => 'xsd:string'),
142  SERVICE_NAMESPACE,
143  SERVICE_NAMESPACE . '#loginCAS',
144  SERVICE_STYLE,
145  SERVICE_USE,
146  'ILIAS login function via CAS'
147  );
148  // loginLDAP()
149  $this->server->register(
150  'loginLDAP',
151  array('client' => 'xsd:string',
152  'username' => 'xsd:string',
153  'password' => 'xsd:string'),
154  array('sid' => 'xsd:string'),
155  SERVICE_NAMESPACE,
156  SERVICE_NAMESPACE . '#login',
157  SERVICE_STYLE,
158  SERVICE_USE,
159  'ILIAS login function via LDAP'
160  );
161 
162  // loginStudipUser()
163  $this->server->register(
164  'loginStudipUser',
165  array('sid' => 'xsd:string',
166  'user_id' => 'xsd:int'),
167  array('sid' => 'xsd:string'),
168  SERVICE_NAMESPACE,
169  SERVICE_NAMESPACE . '#loginStudipUser',
170  SERVICE_STYLE,
171  SERVICE_USE,
172  'ILIAS login function for Stud.IP-Connection. DEPRECATED: this method will be removed in ILIAS 5.3.'
173  );
174 
175  // logout()
176  $this->server->register(
177  'logout',
178  array('sid' => 'xsd:string'),
179  array('success' => 'xsd:boolean'),
180  SERVICE_NAMESPACE,
181  SERVICE_NAMESPACE . '#logout',
182  SERVICE_STYLE,
183  SERVICE_USE,
184  'ILIAS logout function'
185  );
186  // user_data definitions
187  $this->server->wsdl->addComplexType(
188  'ilUserData',
189  'complexType',
190  'struct',
191  'all',
192  '',
193  array('usr_id' => array('name' => 'usr_id','type' => 'xsd:int'),
194  'login' => array('name' => 'login', 'type' => 'xsd:string'),
195  'passwd' => array('name' => 'passwd', 'type' => 'xsd:string'),
196  'firstname' => array('name' => 'firstname', 'type' => 'xsd:string'),
197  'lastname' => array('name' => 'lastname', 'type' => 'xsd:string'),
198  'title' => array('name' => 'title', 'type' => 'xsd:string'),
199  'gender' => array('name' => 'gender', 'type' => 'xsd:string'),
200  'email' => array('name' => 'email', 'type' => 'xsd:string'),
201  'second_email' => array('name' => 'second_email', 'type' => 'xsd:string'),
202  'institution' => array('name' => 'institution', 'type' => 'xsd:string'),
203  'street' => array('name' => 'street', 'type' => 'xsd:string'),
204  'city' => array('name' => 'city', 'type' => 'xsd:string'),
205  'zipcode' => array('name' => 'zipcode', 'type' => 'xsd:string'),
206  'country' => array('name' => 'country', 'type' => 'xsd:string'),
207  'phone_office' => array('name' => 'phone_office', 'type' => 'xsd:string'),
208  'last_login' => array('name' => 'last_login', 'type' => 'xsd:string'),
209  'last_update' => array('name' => 'last_update', 'type' => 'xsd:string'),
210  'create_date' => array('name' => 'create_date', 'type' => 'xsd:string'),
211  'hobby' => array('name' => 'hobby', 'type' => 'xsd:string'),
212  'department' => array('name' => 'department', 'type' => 'xsd:string'),
213  'phone_home' => array('name' => 'phone_home', 'type' => 'xsd:string'),
214  'phone_mobile' => array('name' => 'phone_mobile', 'type' => 'xsd:string'),
215  'fax' => array('name' => 'fax', 'type' => 'xsd:string'),
216  'time_limit_owner' => array('name' => 'time_limit_owner', 'type' => 'xsd:int'),
217  'time_limit_unlimited' => array('name' => 'time_limit_unlimited', 'type' => 'xsd:int'),
218  'time_limit_from' => array('name' => 'time_limit_from', 'type' => 'xsd:int'),
219  'time_limit_until' => array('name' => 'time_limit_until', 'type' => 'xsd:int'),
220  'time_limit_message' => array('name' => 'time_limit_message', 'type' => 'xsd:int'),
221  'referral_comment' => array('name' => 'referral_comment', 'type' => 'xsd:string'),
222  'matriculation' => array('name' => 'matriculation', 'type' => 'xsd:string'),
223  'active' => array('name' => 'active', 'type' => 'xsd:int'),
224  'accepted_agreement' => array('name' => 'accepted_agreement','type' => 'xsd:boolean'),
225  'approve_date' => array('name' => 'approve_date', 'type' => 'xsd:string'),
226  'user_skin' => array('name' => 'user_skin', 'type' => 'xsd:string'),
227  'user_style' => array('name' => 'user_style', 'type' => 'xsd:string'),
228  'user_language' => array('name' => 'user_language', 'type' => 'xsd:string'),
229  'import_id' => array('name' => 'import_id', 'type' => 'xsd:string')
230  )
231  );
232 
233 
234  // lookupUser()
235  $this->server->register(
236  'lookupUser',
237  array('sid' => 'xsd:string',
238  'user_name' => 'xsd:string'),
239  array('usr_id' => 'xsd:int'),
240  SERVICE_NAMESPACE,
241  SERVICE_NAMESPACE . '#lookupUser',
242  SERVICE_STYLE,
243  SERVICE_USE,
244  'ILIAS lookupUser(): check if username exists. Return usr_id or 0 if lookup fails.'
245  );
246 
247 
248  // getUser()
249  $this->server->register(
250  'getUser',
251  array('sid' => 'xsd:string',
252  'user_id' => 'xsd:int'),
253  array('user_data' => 'tns:ilUserData'),
254  SERVICE_NAMESPACE,
255  SERVICE_NAMESPACE . '#getUser',
256  SERVICE_STYLE,
257  SERVICE_USE,
258  'ILIAS getUser(): get complete set of user data. DEPRECATED with release 5.2, will be deleted with 5.3. Use searchUsers() instead.'
259  );
260 
261  // deleteUser()
262  $this->server->register(
263  'deleteUser',
264  array('sid' => 'xsd:string',
265  'user_id' => 'xsd:int'),
266  array('success' => 'xsd:boolean'),
267  SERVICE_NAMESPACE,
268  SERVICE_NAMESPACE . '#deleteUser',
269  SERVICE_STYLE,
270  SERVICE_USE,
271  'ILIAS deleteUser(). Deletes all user related data (Bookmarks, Mails ...). DEPRECATED: Use importUsers() for deletion of user data.'
272  );
273 
274  // addCourse()
275  $this->server->register(
276  'addCourse',
277  array('sid' => 'xsd:string',
278  'target_id' => 'xsd:int',
279  'crs_xml' => 'xsd:string'),
280  array('course_id' => 'xsd:int'),
281  SERVICE_NAMESPACE,
282  SERVICE_NAMESPACE . '#addCourse',
283  SERVICE_STYLE,
284  SERVICE_USE,
285  'ILIAS addCourse(). Course import. See ilias_course_0_1.dtd for details about course xml structure'
286  );
287 
288  // deleteCourse()
289  $this->server->register(
290  'deleteCourse',
291  array('sid' => 'xsd:string',
292  'course_id' => 'xsd:int'),
293  array('success' => 'xsd:boolean'),
294  SERVICE_NAMESPACE,
295  SERVICE_NAMESPACE . '#deleteCourse',
296  SERVICE_STYLE,
297  SERVICE_USE,
298  'ILIAS deleteCourse(). Deletes a course. Delete courses are stored in "Trash" and can be undeleted in ' .
299  ' the ILIAS administration. '
300  );
301  // startBackgroundTaskWorker()
302  $this->server->register(
303  AsyncTaskManager::CMD_START_WORKER,
304  array('sid' => 'xsd:string'),
305  array('success' => 'xsd:boolean'),
306  SERVICE_NAMESPACE,
307  SERVICE_NAMESPACE . '#' . AsyncTaskManager::CMD_START_WORKER,
308  SERVICE_STYLE,
309  SERVICE_USE,
310  'ILIAS ' . AsyncTaskManager::CMD_START_WORKER . '().'
311  );
312 
313  // assignCourseMember()
314  $this->server->register(
315  'assignCourseMember',
316  array('sid' => 'xsd:string',
317  'course_id' => 'xsd:int',
318  'user_id' => 'xsd:int',
319  'type' => 'xsd:string'),
320  array('success' => 'xsd:boolean'),
321  SERVICE_NAMESPACE,
322  SERVICE_NAMESPACE . '#assignCourseMember',
323  SERVICE_STYLE,
324  SERVICE_USE,
325  'ILIAS assignCourseMember(). Assigns an user to an existing course. Type should be "Admin", "Tutor" or "Member"'
326  );
327 
328  // excludeCourseMember()
329  $this->server->register(
330  'excludeCourseMember',
331  array('sid' => 'xsd:string',
332  'course_id' => 'xsd:int',
333  'user_id' => 'xsd:int'),
334  array('success' => 'xsd:boolean'),
335  SERVICE_NAMESPACE,
336  SERVICE_NAMESPACE . '#excludeCourseMember',
337  SERVICE_STYLE,
338  SERVICE_USE,
339  'ILIAS excludeCourseMember(). Excludes an user from an existing course.'
340  );
341 
342  // isAssignedToCourse()
343  $this->server->register(
344  'isAssignedToCourse',
345  array('sid' => 'xsd:string',
346  'course_id' => 'xsd:int',
347  'user_id' => 'xsd:int'),
348  array('role' => 'xsd:int'),
349  SERVICE_NAMESPACE,
350  SERVICE_NAMESPACE . '#isAssignedToCourse',
351  SERVICE_STYLE,
352  SERVICE_USE,
353  'ILIAS isAssignedToCourse(). Checks whether an user is assigned to a given course. ' .
354  'Returns 0 => not assigned, 1 => course admin, 2 => course member or 3 => course tutor'
355  );
356 
357  // getCourseXML($sid,$course_id)
358  $this->server->register(
359  'getCourseXML',
360  array('sid' => 'xsd:string',
361  'course_id' => 'xsd:int'),
362  array('xml' => 'xsd:string'),
363  SERVICE_NAMESPACE,
364  SERVICE_NAMESPACE . '#getCourseXML',
365  SERVICE_STYLE,
366  SERVICE_USE,
367  'ILIAS getCourseXML(). Get a xml description of a specific course.'
368  );
369 
370  // updateCourse($sid,$course_id,$xml)
371  $this->server->register(
372  'updateCourse',
373  array('sid' => 'xsd:string',
374  'course_id' => 'xsd:int',
375  'xml' => 'xsd:string'),
376  array('success' => 'xsd:boolean'),
377  SERVICE_NAMESPACE,
378  SERVICE_NAMESPACE . '#updateCourse',
379  SERVICE_STYLE,
380  SERVICE_USE,
381  'ILIAS updateCourse(). Update course settings, assigned members, tutors, administrators with a ' .
382  'given xml description'
383  );
384 
385  // get obj_id by import id
386  $this->server->register(
387  'getObjIdByImportId',
388  array('sid' => 'xsd:string',
389  'import_id' => 'xsd:string'),
390  array('obj_id' => 'xsd:int'),
391  SERVICE_NAMESPACE,
392  SERVICE_NAMESPACE . '#getCourseIdByImportId',
393  SERVICE_STYLE,
394  SERVICE_USE,
395  'ILIAS getObjIdByImportId(). Get the obj_id of an ILIAS obj by a given import id.'
396  );
397 
398 
399  // get ref ids by import id
400  $this->server->register(
401  'getRefIdsByImportId',
402  array('sid' => 'xsd:string',
403  'import_id' => 'xsd:string'),
404  array('ref_ids' => 'tns:intArray'),
405  SERVICE_NAMESPACE,
406  SERVICE_NAMESPACE . '#getRefIdsByImportId',
407  SERVICE_STYLE,
408  SERVICE_USE,
409  'ILIAS getRefIdsByImportId(). Get all reference ids by a given import id.'
410  );
411 
412  // get obj_id by import id
413  $this->server->register(
414  'getRefIdsByObjId',
415  array('sid' => 'xsd:string',
416  'obj_id' => 'xsd:string'),
417  array('ref_ids' => 'tns:intArray'),
418  SERVICE_NAMESPACE,
419  SERVICE_NAMESPACE . '#getRefIdsByObjId',
420  SERVICE_STYLE,
421  SERVICE_USE,
422  'ILIAS getRefIdsByObjId(). Get all reference ids by a given object id.'
423  );
424 
425  // Object administration
426  $this->server->register(
427  'getObjectByReference',
428  array('sid' => 'xsd:string',
429  'reference_id' => 'xsd:int',
430  'user_id' => 'xsd:int'),
431  array('object_xml' => 'xsd:string'),
432  SERVICE_NAMESPACE,
433  SERVICE_NAMESPACE . '#getObjectByReference',
434  SERVICE_STYLE,
435  SERVICE_USE,
436  'ILIAS getObjectByReference(). Get XML-description of an ILIAS object. If a user id is given, ' .
437  'this methods also checks the permissions of that user on the object.'
438  );
439 
440  $this->server->register(
441  'getObjectsByTitle',
442  array('sid' => 'xsd:string',
443  'title' => 'xsd:string',
444  'user_id' => 'xsd:int'),
445  array('object_xml' => 'xsd:string'),
446  SERVICE_NAMESPACE,
447  SERVICE_NAMESPACE . '#getObjectsByTitle',
448  SERVICE_STYLE,
449  SERVICE_USE,
450  'ILIAS getObjectsByTitle(). Get XML-description of an ILIAS object with given title. ' .
451  'If a user id is given this method also checks the permissions of that user on the object.'
452  );
453 
454  $this->server->register(
455  'searchObjects',
456  array('sid' => 'xsd:string',
457  'types' => 'tns:stringArray',
458  'key' => 'xsd:string',
459  'combination' => 'xsd:string',
460  'user_id' => 'xsd:int'),
461  array('object_xml' => 'xsd:string'),
462  SERVICE_NAMESPACE,
463  SERVICE_NAMESPACE . '#searchObjects',
464  SERVICE_STYLE,
465  SERVICE_USE,
466  'ILIAS searchObjects(): Searches for objects. Key is within "title" or "description" ' .
467  'Typical calls are searchObject($sid,array("lm","crs"),"\"this and that\"","and"); ' .
468  ' If an optional user id is given, this methods also return the permissions for that user ' .
469  'on the found objects'
470  );
471 
472  $this->server->register(
473  'getTreeChilds',
474  array('sid' => 'xsd:string',
475  'ref_id' => 'xsd:int',
476  'types' => 'tns:stringArray',
477  'user_id' => 'xsd:int'),
478  array('object_xml' => 'xsd:string'),
479  SERVICE_NAMESPACE,
480  SERVICE_NAMESPACE . '#getTreeChilds',
481  SERVICE_STYLE,
482  SERVICE_USE,
483  'ILIAS getTreeChilds(): Get all child objects of a given object.' .
484  'Choose array of types to filter the output. Choose empty type array to receive all object types'
485  );
486 
487  $this->server->register(
488  'getXMLTree',
489  array('sid' => 'xsd:string',
490  'ref_id' => 'xsd:int',
491  'types' => 'tns:stringArray',
492  'user_id' => 'xsd:int'),
493  array('object_xml' => 'xsd:string'),
494  SERVICE_NAMESPACE,
495  SERVICE_NAMESPACE . '#getXMLTree',
496  SERVICE_STYLE,
497  SERVICE_USE,
498  'ILIAS getXMLTree(): Returns a xml stream with the subtree objects.'
499  );
500 
501 
502 
503  $this->server->register(
504  'addObject',
505  array('sid' => 'xsd:string',
506  'target_id' => 'xsd:int',
507  'object_xml' => 'xsd:string'),
508  array('ref_id' => 'xsd:int'),
509  SERVICE_NAMESPACE,
510  SERVICE_NAMESPACE . '#addObject',
511  SERVICE_STYLE,
512  SERVICE_USE,
513  'ILIAS addObject. Create new object based on xml description under a given node ' .
514  '("category,course,group or folder). Return created reference id of the new object.'
515  );
516 
517  $this->server->register(
518  'updateObjects',
519  array('sid' => 'xsd:string',
520  'object_xml' => 'xsd:string'),
521  array('success' => 'xsd:boolean'),
522  SERVICE_NAMESPACE,
523  SERVICE_NAMESPACE . '#updateObjects',
524  SERVICE_STYLE,
525  SERVICE_USE,
526  'ILIAS updateObjects. Update object data (title,description,owner)'
527  );
528 
529  $this->server->register(
530  'addReference',
531  array('sid' => 'xsd:string',
532  'source_id' => 'xsd:int',
533  'target_id' => 'xsd:int'),
534  array('ref_id' => 'xsd:int'),
535  SERVICE_NAMESPACE,
536  SERVICE_NAMESPACE . '#addReference',
537  SERVICE_STYLE,
538  SERVICE_USE,
539  'ILIAS addReference. Create new link of given object to new object. Return the new reference id'
540  );
541 
542  $this->server->register(
543  'deleteObject',
544  array('sid' => 'xsd:string',
545  'reference_id' => 'xsd:int'),
546  array('success' => 'xsd:boolean'),
547  SERVICE_NAMESPACE,
548  SERVICE_NAMESPACE . '#deleteObject',
549  SERVICE_STYLE,
550  SERVICE_USE,
551  'ILIAS deleteObject. Stores object in trash. If multiple references exist, only the reference is deleted '
552  );
553 
554 
555  $this->server->register(
556  'removeFromSystemByImportId',
557  array('sid' => 'xsd:string',
558  'import_id' => 'xsd:string'),
559  array('success' => 'xsd:boolean'),
560  SERVICE_NAMESPACE,
561  SERVICE_NAMESPACE . '#removeFromSystemByImportId',
562  SERVICE_STYLE,
563  SERVICE_USE,
564  'ILIAS removeFromSystemByImportId(). Removes an object identified by its import id permanently from the ' .
565  'system. All data will be deleted. There will be no possibility to restore it from the trash. Do not use ' .
566  'this function for deleting roles or users. Use deleteUser() or deleteRole() instead.'
567  );
568 
569  $this->server->register(
570  'addUserRoleEntry',
571  array('sid' => 'xsd:string',
572  'user_id' => 'xsd:int',
573  'role_id' => 'xsd:int'),
574  array('success' => 'xsd:boolean'),
575  SERVICE_NAMESPACE,
576  SERVICE_NAMESPACE . '#addUserRoleEntry',
577  SERVICE_STYLE,
578  SERVICE_USE,
579  'ILIAS addUserRoleEntry. Assign user to role.'
580  );
581 
582  $this->server->register(
583  'deleteUserRoleEntry',
584  array('sid' => 'xsd:string',
585  'user_id' => 'xsd:int',
586  'role_id' => 'xsd:int'),
587  array('success' => 'xsd:boolean'),
588  SERVICE_NAMESPACE,
589  SERVICE_NAMESPACE . '#deleteUserRoleEntry',
590  SERVICE_STYLE,
591  SERVICE_USE,
592  'ILIAS deleteUserRoleEntry. Deassign user from role.'
593  );
594 
595 
596  // Add complex type for operations e.g array(array('name' => 'read','ops_id' => 2),...)
597  $this->server->wsdl->addComplexType(
598  'ilOperation',
599  'complexType',
600  'struct',
601  'all',
602  '',
603  array('ops_id' => array('name' => 'ops_id',
604  'type' => 'xsd:int'),
605  'operation' => array('name' => 'operation',
606  'type' => 'xsd:string'),
607  'description' => array('name' => 'description',
608  'type' => 'xsd:string'))
609  );
610  // Now create an array of ilOperations
611  $this->server->wsdl->addComplexType(
612  'ilOperations',
613  'complexType',
614  'array',
615  '',
616  'SOAP-ENC:Array',
617  array(),
618  array(array('ref' => 'SOAP-ENC:arrayType',
619  'wsdl:arrayType' => 'tns:ilOperation[]')),
620  'tns:ilOperation'
621  );
622  $this->server->register(
623  'getOperations',
624  array('sid' => 'xsd:string'),
625  array('operations' => 'tns:ilOperations'),
626  SERVICE_NAMESPACE,
627  SERVICE_NAMESPACE . '#getOperations',
628  SERVICE_STYLE,
629  SERVICE_USE,
630  'ILIAS getOperations(): get complete set of RBAC operations.'
631  );
632 
633  $this->server->register(
634  'revokePermissions',
635  array('sid' => 'xsd:string',
636  'ref_id' => 'xsd:int',
637  'role_id' => 'xsd:int'),
638  array('success' => 'xsd:boolean'),
639  SERVICE_NAMESPACE,
640  SERVICE_NAMESPACE . '#revokePermissions',
641  SERVICE_STYLE,
642  SERVICE_USE,
643  'ILIAS revokePermissions(): Revoke all permissions for a specific role on an object.'
644  );
645 
646  $this->server->wsdl->addComplexType(
647  'ilOperationIds',
648  'complexType',
649  'array',
650  '',
651  'SOAP-ENC:Array',
652  array(),
653  array(array('ref' => 'SOAP-ENC:arrayType',
654  'wsdl:arrayType' => 'xsd:int[]')),
655  'xsd:int'
656  );
657 
658  $this->server->register(
659  'grantPermissions',
660  array('sid' => 'xsd:string',
661  'ref_id' => 'xsd:int',
662  'role_id' => 'xsd:int',
663  'operations' => 'tns:intArray'),
664  array('success' => 'xsd:boolean'),
665  SERVICE_NAMESPACE,
666  SERVICE_NAMESPACE . '#grantPermissions',
667  SERVICE_STYLE,
668  SERVICE_USE,
669  'ILIAS grantPermissions(): Grant permissions for a specific role on an object. ' .
670  '(Substitutes existing permission settings)'
671  );
672 
673  $this->server->register(
674  'getLocalRoles',
675  array('sid' => 'xsd:string',
676  'ref_id' => 'xsd:int'),
677  array('role_xml' => 'xsd:string'),
678  SERVICE_NAMESPACE,
679  SERVICE_NAMESPACE . '#getLocalRoles',
680  SERVICE_STYLE,
681  SERVICE_USE,
682  'ILIAS getLocalRoles(): Get all local roles assigned to an specific object.'
683  );
684 
685  $this->server->register(
686  'getUserRoles',
687  array('sid' => 'xsd:string',
688  'user_id' => 'xsd:int'),
689  array('role_xml' => 'xsd:string'),
690  SERVICE_NAMESPACE,
691  SERVICE_NAMESPACE . '#getLocalRoles',
692  SERVICE_STYLE,
693  SERVICE_USE,
694  'ILIAS getUserRoles(): Get all local roles assigned to an specific user. '
695  );
696 
697  $this->server->register(
698  'addRole',
699  array('sid' => 'xsd:string',
700  'target_id' => 'xsd:int',
701  'obj_xml' => 'xsd:string'),
702  array('role_ids' => 'tns:intArray'),
703  SERVICE_NAMESPACE,
704  SERVICE_NAMESPACE . '#addRole',
705  SERVICE_STYLE,
706  SERVICE_USE,
707  'ILIAS addRole(): Creates new role under given node. "target_id" is the reference id of an ILIAS ' .
708  'ILIAS object. E.g ref_id of crs,grp. If no role folder exists, a new role folder will be created.'
709  );
710 
711  $this->server->register(
712  'deleteRole',
713  array('sid' => 'xsd:string',
714  'role_id' => 'xsd:int'),
715  array('success' => 'xsd:boolean'),
716  SERVICE_NAMESPACE,
717  SERVICE_NAMESPACE . '#deleteRole',
718  SERVICE_STYLE,
719  SERVICE_USE,
720  'ILIAS deleteRole(): Deletes an role and all user assignments. Fails if it is the last role of an user'
721  );
722 
723  $this->server->register(
724  'addRoleFromTemplate',
725  array('sid' => 'xsd:string',
726  'target_id' => 'xsd:int',
727  'obj_xml' => 'xsd:string',
728  'role_template_id' => 'xsd:int'),
729  array('role_ids' => 'tns:intArray'),
730  SERVICE_NAMESPACE,
731  SERVICE_NAMESPACE . '#addRole',
732  SERVICE_STYLE,
733  SERVICE_USE,
734  'ILIAS addRole(): Creates new role under given node. "target_id" is the reference id of an ILIAS ' .
735  'ILIAS object. E.g ref_id of crs,grp. If no role folder exists, a new role folder will be created. ' .
736  'In addition to addRole the template permissions will be copied from the given role template'
737  );
738 
739  $this->server->register(
740  'getObjectTreeOperations',
741  array('sid' => 'xsd:string',
742  'ref_id' => 'xsd:int',
743  'user_id' => 'xsd:int'),
744  array('operations' => 'tns:ilOperations'),
745  SERVICE_NAMESPACE,
746  SERVICE_NAMESPACE . '#getPermissionsForObject',
747  SERVICE_STYLE,
748  SERVICE_USE,
749  'ILIAS getObjectTreeOperations(): Get all granted permissions for all references of ' .
750  'an object for a specific user. Returns array of granted operations or empty array'
751  );
752 
753  $this->server->register(
754  'addGroup',
755  array('sid' => 'xsd:string',
756  'target_id' => 'xsd:int',
757  'group_xml' => 'xsd:string'),
758  array('ref_id' => 'xsd:int'),
759  SERVICE_NAMESPACE,
760  SERVICE_NAMESPACE . '#addGroup',
761  SERVICE_STYLE,
762  SERVICE_USE,
763  'ILIAS addGroup(): Add grop according to valid group XML ' .
764  '@See ilias_group_0_1.dtd'
765  );
766 
767  $this->server->register(
768  'groupExists',
769  array('sid' => 'xsd:string',
770  'title' => 'xsd:string'),
771  array('exists' => 'xsd:boolean'),
772  SERVICE_NAMESPACE,
773  SERVICE_NAMESPACE . '#groupExists',
774  SERVICE_STYLE,
775  SERVICE_USE,
776  'ILIAS addGroup(): Check if group with given name exists. '
777  );
778 
779 
780  // getGroup
781  $this->server->register(
782  'getGroup',
783  array('sid' => 'xsd:string',
784  'ref_id' => 'xsd:int'),
785  array('group_xml' => 'xsd:string'),
786  SERVICE_NAMESPACE,
787  SERVICE_NAMESPACE . '#getGroup',
788  SERVICE_STYLE,
789  SERVICE_USE,
790  'ILIAS getGroup(): get xml description of grouip with given reference id.'
791  );
792 
793  // assignGroupMember()
794  $this->server->register(
795  'assignGroupMember',
796  array('sid' => 'xsd:string',
797  'group_id' => 'xsd:int',
798  'user_id' => 'xsd:int',
799  'type' => 'xsd:string'),
800  array('success' => 'xsd:boolean'),
801  SERVICE_NAMESPACE,
802  SERVICE_NAMESPACE . '#assignGroupMember',
803  SERVICE_STYLE,
804  SERVICE_USE,
805  'ILIAS assignGroupMember(). Assigns an user to an existing group. Type should be "Admin","Member"'
806  );
807 
808  // excludeGroupMember()
809  $this->server->register(
810  'excludeGroupMember',
811  array('sid' => 'xsd:string',
812  'group_id' => 'xsd:int',
813  'user_id' => 'xsd:int'),
814  array('success' => 'xsd:boolean'),
815  SERVICE_NAMESPACE,
816  SERVICE_NAMESPACE . '#excludeGroupMember',
817  SERVICE_STYLE,
818  SERVICE_USE,
819  'ILIAS excludeGroupMember(). Excludes an user from an existing group.'
820  );
821 
822  // isAssignedToGroup()
823  $this->server->register(
824  'isAssignedToGroup',
825  array('sid' => 'xsd:string',
826  'group_id' => 'xsd:int',
827  'user_id' => 'xsd:int'),
828  array('role' => 'xsd:int'),
829  SERVICE_NAMESPACE,
830  SERVICE_NAMESPACE . '#isAssignedToGroup',
831  SERVICE_STYLE,
832  SERVICE_USE,
833  'ILIAS isAssignedToGroup(). Checks whether an user is assigned to a given group. ' .
834  'Returns 0 => not assigned, 1 => group admin, 2 => group member'
835  );
836 
837 
838 
839  // ILIAS util functions
840  $this->server->register(
841  'sendMail',
842  array('sid' => 'xsd:string',
843  'rcp_to' => 'xsd:string',
844  'rcp_cc' => 'xsd:string',
845  'rcp_bcc' => 'xsd:string',
846  'sender' => 'xsd:string',
847  'subject' => 'xsd:string',
848  'message' => 'xsd:string',
849  'attachments' => 'xsd:string'),
850  array('status' => 'xsd:boolean'),
851  SERVICE_NAMESPACE,
852  SERVICE_NAMESPACE . '#sendMail',
853  SERVICE_STYLE,
854  SERVICE_USE,
855  'ILIAS sendMail(): Send mime mails according to xml description. Only for internal usage ' .
856  'Syntax, parameters may change in future releases'
857  );
858 
859  $this->server->register(
860  'distributeMails',
861  array('sid' => 'xsd:string',
862  'mail_xml' => 'xsd:string'),
863  array('status' => 'xsd:boolean'),
864  SERVICE_NAMESPACE,
865  SERVICE_NAMESPACE . '#sendMail',
866  SERVICE_STYLE,
867  SERVICE_USE,
868  'ILIAS distributeMails(): Distribute ILIAS mails according according to the mail setting of the recipients as ' .
869  'ILIAS internal mail or as e-mail.'
870  );
871 
872  // Clone functions
873  $this->server->register(
874  'ilClone',
875  array('sid' => 'xsd:string','copy_identifier' => 'xsd:int'),
876  array('new_ref_id' => 'xsd:int'),
877  SERVICE_NAMESPACE,
878  SERVICE_NAMESPACE . '#ilClone',
879  SERVICE_STYLE,
880  SERVICE_USE,
881  'ILIAS ilClone(): Only for internal usage.' .
882  'Syntax, parameters may change in future releases. '
883  );
884 
885  $this->server->register(
886  'handleECSTasks',
887  array('sid' => 'xsd:string','server_id' => 'xsd:int'),
888  array('success' => 'xsd:boolean'),
889  SERVICE_NAMESPACE,
890  SERVICE_NAMESPACE . '#handleECSTasks',
891  SERVICE_STYLE,
892  SERVICE_USE,
893  'ILIAS handleECSTasks(): Only for internal usage.' .
894  'Syntax, parameters may change in future releases. '
895  );
896 
897  $this->server->register(
898  'ilCloneDependencies',
899  array('sid' => 'xsd:string','copy_identifier' => 'xsd:int'),
900  array('success' => 'xsd:boolean'),
901  SERVICE_NAMESPACE,
902  SERVICE_NAMESPACE . '#ilCloneDependencies',
903  SERVICE_STYLE,
904  SERVICE_USE,
905  'ILIAS ilCloneDependencies(): Only for internal usage.' .
906  'Syntax, parameters may change in future releases. '
907  );
908 
909  $this->server->register(
910  'saveQuestionResult',
911  array('sid' => 'xsd:string',
912  'user_id' => 'xsd:int',
913  'test_id' => 'xsd:int',
914  'question_id' => 'xsd:int',
915  'pass' => 'xsd:int',
916  'solution' => 'tns:stringArray'),
917  array('status' => 'xsd:boolean'),
918  SERVICE_NAMESPACE,
919  SERVICE_NAMESPACE . '#saveQuestionResult',
920  SERVICE_STYLE,
921  SERVICE_USE,
922  'ILIAS saveQuesionResult: Typically called from an external assessment question to save the user input. DEPRECATED since ILIAS 3.9'
923  );
924 
925  $this->server->register(
926  'saveQuestion',
927  array('sid' => 'xsd:string',
928  'active_id' => 'xsd:long',
929  'question_id' => 'xsd:long',
930  'pass' => 'xsd:int',
931  'solution' => 'tns:stringArray'),
932  array('status' => 'xsd:boolean'),
933  SERVICE_NAMESPACE,
934  SERVICE_NAMESPACE . '#saveQuestion',
935  SERVICE_STYLE,
936  SERVICE_USE,
937  'ILIAS saveQuestion: Saves the result of a question in a given test pass for the active test user. The active user is identified by the active ID, which assigns a user to a test.'
938  );
939 
940  $this->server->register(
941  'saveQuestionSolution',
942  array('sid' => 'xsd:string',
943  'active_id' => 'xsd:long',
944  'question_id' => 'xsd:long',
945  'pass' => 'xsd:int',
946  'solution' => 'xsd:string'),
947  array('status' => 'xsd:string'),
948  SERVICE_NAMESPACE,
949  SERVICE_NAMESPACE . '#saveQuestionSolution',
950  SERVICE_STYLE,
951  SERVICE_USE,
952  'ILIAS saveQuestionSolution: Saves the result of a question in a given test pass for the active test user. The active user is identified by the active ID, which assigns a user to a test. The solution has to be an XML string which contains <values><value>VALUE</value><value>VALUE</value><points>POINTS</points>...</values> where the triplet (value,value,points) can repeat n times. The result string is either TRUE or it contains an error message.'
953  );
954 
955  $this->server->register(
956  'getQuestionSolution',
957  array('sid' => 'xsd:string',
958  'active_id' => 'xsd:long',
959  'question_id' => 'xsd:int',
960  'pass' => 'xsd:int'),
961  array('solution' => 'tns:stringArray'),
962  SERVICE_NAMESPACE,
963  SERVICE_NAMESPACE . '#getQuestionSolution',
964  SERVICE_STYLE,
965  SERVICE_USE,
966  'ILIAS getQuestionSolution: Typically called from external assessment questions to retrieve the previous input of a user.'
967  );
968 
969  $this->server->register(
970  'getTestUserData',
971  array('sid' => 'xsd:string',
972  'active_id' => 'xsd:long'),
973  array('userdata' => 'tns:stringArray'),
974  SERVICE_NAMESPACE,
975  SERVICE_NAMESPACE . '#getTestUserData',
976  SERVICE_STYLE,
977  SERVICE_USE,
978  'ILIAS getTestUserData: Typically called from external assessment questions to retrieve data of the active user. The returned string array values are fullname, title, firstname, lastname, login.'
979  );
980 
981  $this->server->register(
982  'getPositionOfQuestion',
983  array('sid' => 'xsd:string',
984  'active_id' => 'xsd:long',
985  'question_id' => 'xsd:int',
986  'pass' => 'xsd:int'),
987  array('position' => 'xsd:int'),
988  SERVICE_NAMESPACE,
989  SERVICE_NAMESPACE . '#getPositionOfQuestion',
990  SERVICE_STYLE,
991  SERVICE_USE,
992  'ILIAS getPositionOfQuestion: Returns the position of a given question for a given user in a given test pass.'
993  );
994 
995  $this->server->register(
996  'getPreviousReachedPoints',
997  array('sid' => 'xsd:string',
998  'active_id' => 'xsd:long',
999  'question_id' => 'xsd:int',
1000  'pass' => 'xsd:int'),
1001  array('position' => 'tns:doubleArray'),
1002  SERVICE_NAMESPACE,
1003  SERVICE_NAMESPACE . '#getPreviousReachedPoints',
1004  SERVICE_STYLE,
1005  SERVICE_USE,
1006  'ILIAS getPreviousReachedPoints: Returns an array of reached points for the previous questions in a given test pass.'
1007  );
1008 
1009  $this->server->register(
1010  'getNrOfQuestionsInPass',
1011  array('sid' => 'xsd:string',
1012  'active_id' => 'xsd:long',
1013  'pass' => 'xsd:int'),
1014  array('count' => 'xsd:int'),
1015  SERVICE_NAMESPACE,
1016  SERVICE_NAMESPACE . '#getNrOfQuestionsInPass',
1017  SERVICE_STYLE,
1018  SERVICE_USE,
1019  'ILIAS getNrOfQuestionsInPass: Returns the question count for a given test user in a given pass.'
1020  );
1021 
1022  $this->server->register(
1023  'getStructureObjects',
1024  array('sid' => 'xsd:string',
1025  'ref_id' => 'xsd:int'),
1026  array('xml' => 'xsd:string'),
1027  SERVICE_NAMESPACE,
1028  SERVICE_NAMESPACE . '#getStructureObjects',
1029  SERVICE_STYLE,
1030  SERVICE_USE,
1031  'ILIAS getStructureObjects: delivers structure of content objects like learning modules (chapters/pages) or glossary (terms)'
1032  );
1033 
1034  // importUsers()
1035  $this->server->register(
1036  'importUsers',
1037  array('sid' => 'xsd:string',
1038  'folder_id' => 'xsd:int',
1039  'usr_xml' => 'xsd:string',
1040  'conflict_rule' => 'xsd:int',
1041  'send_account_mail' => 'xsd:int'),
1042  array('protocol' => 'xsd:string'),
1043  SERVICE_NAMESPACE,
1044  SERVICE_NAMESPACE . '#importUsers',
1045  SERVICE_STYLE,
1046  SERVICE_USE,
1047  'ILIAS import users into folder id, which should be ref_id of folder or user folder (-1:System user folder, 0: checks access at user level, otherwise refid): conflict_rule: IL_FAIL_ON_CONFLICT = 1, IL_UPDATE_ON_CONFLICT = 2, IL_IGNORE_ON_CONFLICT = 3. The Return-Value is a protocol with the columns userid, login, action, message, following xmlresultset dtd. Send Account Mail = 0 deactivates sending a mail to each user, 1 activates it'
1048  );
1049 
1050  $this->server->register(
1051  'getRoles',
1052  array('sid' => 'xsd:string',
1053  'role_type' => 'xsd:string',
1054  'id' => 'xsd:string'),
1055  array('role_xml' => 'xsd:string'),
1056  SERVICE_NAMESPACE,
1057  SERVICE_NAMESPACE . '#getRoles',
1058  SERVICE_STYLE,
1059  SERVICE_USE,
1060  'ILIAS getRoles():if id equals -1, get all roles specified by type (global|local|user|user_login|template or empty), if type is empty all roles with all types are delivered, if id > -1 and role_type <> user or user_login, delivers all roles which belong to a repository object with specified ref_id, if roletype is user a numeric id is interpreted as userid, if roletype is user_login it is interpreted as login,if roletype is template all role templates will be listed'
1061  );
1062 
1063  $this->server->register(
1064  'getUsersForContainer',
1065  array('sid' => 'xsd:string',
1066  'ref_id' => 'xsd:int',
1067  'attach_roles' => 'xsd:int',
1068  'active' => 'xsd:int'),
1069  array('user_xml' => 'xsd:string'),
1070  SERVICE_NAMESPACE,
1071  SERVICE_NAMESPACE . '#getUsersForContainer',
1072  SERVICE_STYLE,
1073  SERVICE_USE,
1074  'ILIAS getUsersForContainer(): get all users of a specific ref_id, which can be crs, group, category or user folder (value: -1). Choose if all roles of a user should be attached (1) or not (0). set active to -1 to get all, 0, to get inactive users only, 1 to get active users only'
1075  );
1076 
1077  $this->server->register(
1078  'getUsersForRole',
1079  array('sid' => 'xsd:string',
1080  'role_id' => 'xsd:int',
1081  'attach_roles' => 'xsd:int',
1082  'active' => 'xsd:int'),
1083  array('user_xml' => 'xsd:string'),
1084  SERVICE_NAMESPACE,
1085  SERVICE_NAMESPACE . '#getUsersForRole',
1086  SERVICE_STYLE,
1087  SERVICE_USE,
1088  'ILIAS getUsersForRole(): get all users of a role with specified id, specify attach_roles to 1, to attach all role assignmnents; specify active: 1, to import active only, 0: inactive only, -1: both'
1089  );
1090 
1091  $this->server->register(
1092  'searchUser',
1093  array('sid' => 'xsd:string',
1094  'key_fields' => 'tns:stringArray',
1095  'query_operator' => 'xsd:string',
1096  'key_values' => 'tns:stringArray',
1097  'attach_roles' => 'xsd:int',
1098  'active' => 'xsd:int'),
1099  array('user_xml' => 'xsd:string'),
1100  SERVICE_NAMESPACE,
1101  SERVICE_NAMESPACE . '#searchUsers',
1102  SERVICE_STYLE,
1103  SERVICE_USE,
1104  'ILIAS searchUser(): get all users, which match a query, consisting of the keyfields, matched with values of the field values, concatenated with the logical query operator. Specify attach_roles to 1, to attach all role assignmnents; specify active: 1, to import active only, 0: inactive only, -1: both'
1105  );
1106 
1107  // Mail Functions
1108  // Check whether current user has new mail
1109  $this->server->register(
1110  'hasNewMail',
1111  array('sid' => 'xsd:string'),
1112  array('status' => 'xsd:boolean'),
1113  SERVICE_NAMESPACE,
1114  SERVICE_NAMESPACE . '#hasNewMail',
1115  SERVICE_STYLE,
1116  SERVICE_USE,
1117  'ILIAS hasNewMail(): Checks whether the current authenticated user has a new mail.'
1118  );
1119 
1120  $this->server->register(
1121  'getNIC',
1122  array('sid' => 'xsd:string'),
1123  array('xmlresultset' => 'xsd:string'),
1124  SERVICE_NAMESPACE,
1125  SERVICE_NAMESPACE . '#getNIC',
1126  SERVICE_STYLE,
1127  SERVICE_USE,
1128  'ILIAS getNIC(): DEPRECATED: use getClientInfoXML instead. was: return client information from current client as xml result set containing installation_id, installation_version, installation_url, installation_description, installation_language_default as columns'
1129  );
1130 
1131  $this->server->register(
1132  'getExerciseXML',
1133  array('sid' => 'xsd:string', "ref_id" => 'xsd:int', "attachment_mode" => "xsd:int"),
1134  array('exercisexml' => 'xsd:string'),
1135  SERVICE_NAMESPACE,
1136  SERVICE_NAMESPACE . '#getExerciseXML',
1137  SERVICE_STYLE,
1138  SERVICE_USE,
1139  'ILIAS getExerciseXML(): returns xml description of exercise. Attachment mode: 0 - no file contents, 1 - plain content (base64encoded), 2 zlib + base64, 3 gzip + base64)'
1140  );
1141 
1142  $this->server->register(
1143  'addExercise',
1144  array('sid' => 'xsd:string', "target_id" => 'xsd:int', "xml" => "xsd:string"),
1145  array('refid' => 'xsd:int'),
1146  SERVICE_NAMESPACE,
1147  SERVICE_NAMESPACE . '#addExercise',
1148  SERVICE_STYLE,
1149  SERVICE_USE,
1150  'ILIAS addExercise(): create exercise, put it into target (ref_id) and update exercise properties from xml (see ilias_exercise_3_8.dtd for details). Obj_id must not be set!'
1151  );
1152 
1153  $this->server->register(
1154  'updateExercise',
1155  array('sid' => 'xsd:string', 'ref_id' => 'xsd:int', 'xml' => 'xsd:string'),
1156  array('success' => 'xsd:boolean'),
1157  SERVICE_NAMESPACE,
1158  SERVICE_NAMESPACE . '#updateExercise',
1159  SERVICE_STYLE,
1160  SERVICE_USE,
1161  'ILIAS updateExercise():update existing exercise, update exercise properties from xml (see ilias_exercise_3_8.dtd for details). obj_id in xml must match according obj id of refid.!'
1162  );
1163 
1164  $this->server->register(
1165  'getFileXML',
1166  array('sid' => 'xsd:string', 'ref_id' => 'xsd:int', 'attachment_mode' => 'xsd:int'),
1167  array('filexml' => 'xsd:string'),
1168  SERVICE_NAMESPACE,
1169  SERVICE_NAMESPACE . '#getFileXML',
1170  SERVICE_STYLE,
1171  SERVICE_USE,
1172  'ILIAS getFileXML(): returns xml description of file. Attachment mode: 0 - no file contents, 1 - plain content (base64encoded), 2 zlib + base64, 3 gzip + base64)'
1173  );
1174 
1175  $this->server->register(
1176  'addFile',
1177  array('sid' => 'xsd:string', 'target_id' => 'xsd:int', 'xml' => 'xsd:string'),
1178  array('refid' => 'xsd:int'),
1179  SERVICE_NAMESPACE,
1180  SERVICE_NAMESPACE . '#addFile',
1181  SERVICE_STYLE,
1182  SERVICE_USE,
1183  'ILIAS addFile(): create file, put it into target (ref_id) and update file properties from xml (see ilias_file_3_8.dtd for details). Obj_id must not be set!'
1184  );
1185 
1186  $this->server->register(
1187  'updateFile',
1188  array('sid' => 'xsd:string', 'ref_id' => 'xsd:int', 'xml' => 'xsd:string'),
1189  array('success' => 'xsd:boolean'),
1190  SERVICE_NAMESPACE,
1191  SERVICE_NAMESPACE . '#updateFile',
1192  SERVICE_STYLE,
1193  SERVICE_USE,
1194  'ILIAS updateFile():update existing file, update file properties from xml (see ilias_file_3_8.dtd for details). obj_id in xml must match according obj id of refid.!'
1195  );
1196 
1197 
1198  $this->server->register(
1199  'getUserXML',
1200  array('sid' => 'xsd:string', 'user_ids' => 'tns:intArray', 'attach_roles' => 'xsd:int'),
1201  array('xml' => 'xsd:string'),
1202  SERVICE_NAMESPACE,
1203  SERVICE_NAMESPACE . '#resolveUsers',
1204  SERVICE_STYLE,
1205  SERVICE_USE,
1206  'ILIAS getUserXML(): get xml records for user ids, e.g. retrieved vom members of course xml. Returns user xml dtds. ids are numeric ids of user'
1207  );
1208 
1209 
1210  // get objs ids by ref id
1211  $this->server->register(
1212  'getObjIdsByRefIds',
1213  array('sid' => 'xsd:string',
1214  'ref_ids' => 'tns:intArray'),
1215  array('obj_ids' => 'tns:intArray'),
1216  SERVICE_NAMESPACE,
1217  SERVICE_NAMESPACE . '#getRefIdsByImportId',
1218  SERVICE_STYLE,
1219  SERVICE_USE,
1220  'ILIAS getObjIdsForRefIds: Returns a array of object ids which match the references id, given by a comma seperated string. Returns an array of ref ids, in the same order as object ids. Therefore, there might by duplicates'
1221  );
1222 
1223  $this->server->register(
1224  'updateGroup',
1225  array('sid' => 'xsd:string', 'ref_id' => 'xsd:int', 'xml' => 'xsd:string'),
1226  array('success' => 'xsd:boolean'),
1227  SERVICE_NAMESPACE,
1228  SERVICE_NAMESPACE . '#updateGroup',
1229  SERVICE_STYLE,
1230  SERVICE_USE,
1231  'ILIAS updateGroup(): update existing group using ref id and group xml (see DTD).'
1232  );
1233 
1234 
1235 
1236  $this->server->register(
1237  'getIMSManifestXML',
1238  array('sid' => 'xsd:string', 'ref_id' => 'xsd:int'),
1239  array('xml' => 'xsd:string'),
1240  SERVICE_NAMESPACE,
1241  SERVICE_NAMESPACE . '#getIMSManifestXML',
1242  SERVICE_STYLE,
1243  SERVICE_USE,
1244  'ILIAS getIMSManifestXML(): returns xml of ims manifest file (scorm learning module) referred by refid'
1245  );
1246 
1247  $this->server->register(
1248  'hasSCORMCertificate',
1249  array('sid' => 'xsd:string', 'ref_id' => 'xsd:int', 'usr_id' => 'xsd:int'),
1250  array('success' => 'xsd:boolean'),
1251  SERVICE_NAMESPACE,
1252  SERVICE_NAMESPACE . '#hasSCORMCertificate',
1253  SERVICE_STYLE,
1254  SERVICE_USE,
1255  'ILIAS hasSCORMCertificate(): returns true if a certficate is available for a user referred by usr_id in a SCORM learning module referred by ref_id'
1256  );
1257 
1258  $this->server->register(
1259  'getSCORMCompletionStatus',
1260  array('sid' => 'xsd:string', 'usr_id' => 'xsd:int', 'ref_id' => 'xsd:int'),
1261  array('status' => 'xsd:string'),
1262  SERVICE_NAMESPACE,
1263  SERVICE_NAMESPACE . '#getSCORMCompletionStatus',
1264  SERVICE_STYLE,
1265  SERVICE_USE,
1266  'ILIAS getSCORMCompletionStatus(): returns a completion status of a scorm module'
1267  );
1268 
1269  $this->server->register(
1270  'copyObject',
1271  array('sid' => 'xsd:string', 'xml' => 'xsd:string'),
1272  array('xml' => 'xsd:int'),
1273  SERVICE_NAMESPACE,
1274  SERVICE_NAMESPACE . '#copyObject',
1275  SERVICE_STYLE,
1276  SERVICE_USE,
1277  'ILIAS copyObject(): returns reference of copy, if copy is created directly, or the ref id of the target if copy is in progress.'
1278  );
1279 
1280  $this->server->register(
1281  'moveObject',
1282  array('sid' => 'xsd:string', 'ref_id' => 'xsd:int', 'target_id' => 'xsd:int'),
1283  array('result' => 'xsd:boolean'),
1284  SERVICE_NAMESPACE,
1285  SERVICE_NAMESPACE . '#moveObject',
1286  SERVICE_STYLE,
1287  SERVICE_USE,
1288  'ILIAS moveObject(): returns true, if object with refid could be successfully moved to target id, other it raises an error.'
1289  );
1290 
1291 
1292  $this->server->register(
1293  'getTestResults',
1294  array('sid' => 'xsd:string', 'ref_id' => 'xsd:int', 'sum_only' => 'xsd:boolean'),
1295  array('xml' => 'xsd:string'),
1296  SERVICE_NAMESPACE,
1297  SERVICE_NAMESPACE . '#getTestResults',
1298  SERVICE_STYLE,
1299  SERVICE_USE,
1300  'ILIAS getTestResults(): returns XMLResultSet with
1301  sum only = true: user_id, login, firstname, lastname, matriculation, maximum points, received points
1302  sum only = false: user_id, login, firstname, lastname, matriculation, question id, question title, question points, received points'
1303  );
1304 
1305  $this->server->register(
1306  'removeTestResults',
1307  array(
1308  'sid' => 'xsd:string',
1309  'ref_id' => 'xsd:int',
1310  'user_ids' => 'tns:intArray'),
1311  array('success' => 'xsd:boolean'),
1312  SERVICE_NAMESPACE,
1313  SERVICE_NAMESPACE . '#removeTestResults',
1314  SERVICE_STYLE,
1315  SERVICE_USE,
1316  'ILIAS removeTestResults(): remove test results for the chosen users'
1317  );
1318 
1319  $this->server->register(
1320  'getCoursesForUser',
1321  array('sid' => 'xsd:string', 'parameters' => 'xsd:string'),
1322  array('xml' => 'xsd:string'),
1323  SERVICE_NAMESPACE,
1324  SERVICE_NAMESPACE . '#getCoursesForUser',
1325  SERVICE_STYLE,
1326  SERVICE_USE,
1327  'ILIAS getTestResults(): returns XMLResultSet with columns ref_id, course xml. $parameters has to contain a column user_id and a column status. Status is a logical AND combined value of (MEMBER = 1, TUTOR = 2, ADMIN = 4, OWNER = 8) and determines which courses should be returned.'
1328  );
1329 
1330  $this->server->register(
1331  'getGroupsForUser',
1332  array('sid' => 'xsd:string', 'parameters' => 'xsd:string'),
1333  array('xml' => 'xsd:string'),
1334  SERVICE_NAMESPACE,
1335  SERVICE_NAMESPACE . '#getGroupsForUser',
1336  SERVICE_STYLE,
1337  SERVICE_USE,
1338  'ILIAS getTestResults(): returns XMLResultSet with columns ref_id, group xml. $parameters has to contain a column user_id and a column status. Status is a logical AND combined value of (MEMBER = 1, TUTOR = 2, OWNER = 4) and determines which groups should be returned.'
1339  );
1340 
1341  $this->server->register(
1342  'getPathForRefId',
1343  array('sid' => 'xsd:string', 'ref_id' => 'xsd:int'),
1344  array('xml' => 'xsd:string'),
1345  SERVICE_NAMESPACE,
1346  SERVICE_NAMESPACE . '#getPathForRefId',
1347  SERVICE_STYLE,
1348  SERVICE_USE,
1349  'ILIAS getPathForRefId(): returns XMLResultSet with columns ref_id, type and title.'
1350  );
1351 
1352  $this->server->register(
1353  'searchRoles',
1354  array('sid' => 'xsd:string', 'key' => 'xsd:string', 'combination' => 'xsd:string', 'role_type' => 'xsd:string'),
1355  array('xml' => 'xsd:string'),
1356  SERVICE_NAMESPACE,
1357  SERVICE_NAMESPACE . '#searchRoles',
1358  SERVICE_STYLE,
1359  SERVICE_USE,
1360  'ILIAS searchRoles(): returns XML following role dtd with search results for given role type and search terms.'
1361  );
1362 
1363  $this->server->register(
1364  'getInstallationInfoXML',
1365  array(),
1366  array('xml' => 'xsd:string'),
1367  SERVICE_NAMESPACE,
1368  SERVICE_NAMESPACE . '#getInstallationInfoXML',
1369  SERVICE_STYLE,
1370  SERVICE_USE,
1371  'ILIAS getInstallationInfoXML(): returns XML following installation_info dtd'
1372  );
1373 
1374  $this->server->register(
1375  'getClientInfoXML',
1376  array('clientid' => 'xsd:string'),
1377  array('xml' => 'xsd:string'),
1378  SERVICE_NAMESPACE,
1379  SERVICE_NAMESPACE . '#getClientInfoXML',
1380  SERVICE_STYLE,
1381  SERVICE_USE,
1382  'ILIAS getClientInfoXML(): returns XML following installation_info dtd, contains the client the data of given client id'
1383  );
1384 
1385  $this->server->register(
1386  'getSkillCompletionDateForTriggerRefId',
1387  array('sid' => 'xsd:string',
1388  'user_id' => 'xsd:string',
1389  'ref_id' => 'xsd:string'),
1390  array('dates' => 'xsd:string'),
1391  SERVICE_NAMESPACE,
1392  SERVICE_NAMESPACE . '#getSkillCompletionDateForTriggerRefId',
1393  SERVICE_STYLE,
1394  SERVICE_USE,
1395  'ILIAS getSkillCompletionDateForTriggerRefId(). Get completion dates for skill trigger ref ids.'
1396  );
1397 
1398  $this->server->register(
1399  'checkSkillUserCertificateForTriggerRefId',
1400  array('sid' => 'xsd:string',
1401  'user_id' => 'xsd:string',
1402  'ref_id' => 'xsd:string'),
1403  array('have_certificates' => 'xsd:string'),
1404  SERVICE_NAMESPACE,
1405  SERVICE_NAMESPACE . '#checkSkillUserCertificateForTriggerRefId',
1406  SERVICE_STYLE,
1407  SERVICE_USE,
1408  'ILIAS checkSkillUserCertificateForTriggerRefId(). Check user certificates for trigger ref ids.'
1409  );
1410 
1411  $this->server->register(
1412  'getSkillTriggerOfAllCertificates',
1413  array('sid' => 'xsd:string',
1414  'user_id' => 'xsd:string'),
1415  array('certificate_triggers' => 'xsd:string'),
1416  SERVICE_NAMESPACE,
1417  SERVICE_NAMESPACE . '#getSkillTriggerOfAllCertificates',
1418  SERVICE_STYLE,
1419  SERVICE_USE,
1420  'ILIAS getSkillTriggerOfAllCertificates(). Check get all trigger with certificate for a user.'
1421  );
1422 
1423  $this->server->register(
1424  'getUserIdBySid',
1425  array('sid' => 'xsd:string'),
1426  array('usr_id' => 'xsd:int'),
1427  SERVICE_NAMESPACE,
1428  SERVICE_NAMESPACE . '#getUserIdBySid',
1429  SERVICE_STYLE,
1430  SERVICE_USE,
1431  'ILIAS getUserIdBySid(): returns an ILIAS usr_id for the given sid'
1432  );
1433 
1434  $this->server->register(
1435  'deleteExpiredDualOptInUserObjects',
1436  array('sid' => 'xsd:string',
1437  'usr_id' => 'xsd:int'),
1438  array('status' => 'xsd:boolean'),
1439  SERVICE_NAMESPACE,
1440  SERVICE_NAMESPACE . '#deleteExpiredDualOptInUserObjects',
1441  SERVICE_STYLE,
1442  SERVICE_USE,
1443  'ILIAS deleteExpiredDualOptInUserObjects(): Deletes expired user accounts caused by unconfirmed registration links in "dual opt in" registration method'
1444  );
1445 
1446 
1447  $this->server->register(
1448  'readWebLink',
1449  array('sid' => 'xsd:string', "ref_id" => 'xsd:int'),
1450  array('weblinkxml' => 'xsd:string'),
1451  SERVICE_NAMESPACE,
1452  SERVICE_NAMESPACE . '#readWebLink',
1453  SERVICE_STYLE,
1454  SERVICE_USE,
1455  'ILIAS readWebLink(): returns xml description of a weblink container.'
1456  );
1457 
1458  $this->server->register(
1459  'createWebLink',
1460  array('sid' => 'xsd:string', "target_id" => 'xsd:int', "xml" => "xsd:string"),
1461  array('refid' => 'xsd:int'),
1462  SERVICE_NAMESPACE,
1463  SERVICE_NAMESPACE . '#createWebLink',
1464  SERVICE_STYLE,
1465  SERVICE_USE,
1466  'ILIAS createWebLink(): create web link container, put it into target (ref_id) and update weblink container from xml (see ilias_weblink_4_0.dtd for details). Obj_id must not be set!'
1467  );
1468 
1469  $this->server->register(
1470  'updateWebLink',
1471  array('sid' => 'xsd:string', 'ref_id' => 'xsd:int', 'xml' => 'xsd:string'),
1472  array('success' => 'xsd:boolean'),
1473  SERVICE_NAMESPACE,
1474  SERVICE_NAMESPACE . '#updateWebLink',
1475  SERVICE_STYLE,
1476  SERVICE_USE,
1477  'ILIAS updateWebLink():update existing weblink, update weblink properties from xml (see ilias_weblink_4_0.dtd for details).'
1478  );
1479 
1480  // mcs-patch start
1481  $this->server->register(
1482  'getLearningProgressChanges',
1483  array('sid' => 'xsd:string', 'timestamp' => 'xsd:string', 'include_ref_ids' => 'xsd:boolean', 'type_filter' => 'tns:stringArray'),
1484  array('lp_data' => 'xsd:string'),
1485  SERVICE_NAMESPACE,
1486  SERVICE_NAMESPACE . '#getLearningProgressChanges',
1487  SERVICE_STYLE,
1488  SERVICE_USE,
1489  'ILIAS getLearningProgressChanges(): Get learning progress changes after a given timestamp.'
1490  );
1491  // mcs-patch end
1492 
1493 
1494 
1495  $this->server->register(
1496  'deleteProgress',
1497  array(
1498  'sid' => 'xsd:string',
1499  'ref_ids' => 'tns:intArray',
1500  'usr_ids' => 'tns:intArray',
1501  'type_filter' => 'tns:stringArray',
1502  'progress_filter' => 'tns:intArray'
1503  ),
1504  array('status' => 'xsd:boolean'),
1505  SERVICE_NAMESPACE,
1506  SERVICE_NAMESPACE . '#deleteProgress',
1507  SERVICE_STYLE,
1508  SERVICE_USE,
1509  'Delete user progress data of objects. '
1510  );
1511 
1512 
1513  $this->server->register(
1514  'getProgressInfo',
1515  array(
1516  'sid' => 'xsd:string',
1517  'ref_id' => 'xsd:int',
1518  'progress_filter' => 'tns:intArray'
1519  ),
1520  array('user_results' => 'xsd:string'),
1521  SERVICE_NAMESPACE,
1522  SERVICE_NAMESPACE . '#getProgressInfo',
1523  SERVICE_STYLE,
1524  SERVICE_USE,
1525  'Get object learning progress information'
1526  );
1527 
1528 
1529  $this->server->register(
1530  'exportDataCollectionContent',
1531  array(
1532  'sid' => 'xsd:string',
1533  'ref_id' => 'xsd:int',
1534  'table_id' => 'xsd:int',
1535  'format' => 'xsd:string',
1536  'filepath' => 'xsd:string'
1537  ),
1538  array('export_path' => 'xsd:string'),
1539  SERVICE_NAMESPACE,
1540  SERVICE_NAMESPACE . '#exportDataCollectionTableContent',
1541  SERVICE_STYLE,
1542  SERVICE_USE,
1543  'Generate DataCollectionContent Export'
1544  );
1545 
1546  $this->server->register(
1547  'processBackgroundTask',
1548  array(
1549  'sid' => 'xsd:string',
1550  'task_id' => 'xsd:int'
1551  ),
1552  array('status' => 'xsd:boolean'),
1553  SERVICE_NAMESPACE,
1554  SERVICE_NAMESPACE . '#processBackgroundTask',
1555  SERVICE_STYLE,
1556  SERVICE_USE,
1557  'Process task in background'
1558  );
1559 
1560  $this->server->register(
1561  'addDesktopItems',
1562  [
1563  'sid' => 'xsd:string',
1564  'user_id' => 'xsd:int',
1565  'reference_ids' => 'tns:intArray'
1566  ],
1567  [
1568  'num_added' => 'xsd:int'
1569  ],
1570  SERVICE_NAMESPACE,
1571  SERVICE_NAMESPACE . '#addDesktopItems',
1572  SERVICE_STYLE,
1573  SERVICE_USE,
1574  'Add desktop items for user'
1575  );
1576 
1577  $this->server->register(
1578  'removeDesktopItems',
1579  [
1580  'sid' => 'xsd:string',
1581  'user_id' => 'xsd:int',
1582  'reference_ids' => 'tns:intArray'
1583  ],
1584  [
1585  'num_added' => 'xsd:int'
1586  ],
1587  SERVICE_NAMESPACE,
1588  SERVICE_NAMESPACE . '#removeDesktopItems',
1589  SERVICE_STYLE,
1590  SERVICE_USE,
1591  'Remove desktop items for user'
1592  );
1593 
1594  // If a client ID is submitted, there might be some SOAP plugins registering methods/types
1595  if (isset($_GET['client_id'])) {
1596  $this->handleSoapPlugins();
1597  }
1598 
1599  return true;
1600  }
handleSoapPlugins()
Register any methods and types of SOAP plugins to the SOAP server.
$_GET["client_id"]
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ handleSoapPlugins()

ilNusoapUserAdministrationAdapter::handleSoapPlugins ( )
protected

Register any methods and types of SOAP plugins to the SOAP server.

Definition at line 1605 of file class.ilNusoapUserAdministrationAdapter.php.

References $DIC, $type, ilContext\CONTEXT_SOAP, ilContext\CONTEXT_SOAP_NO_AUTH, ilContext\init(), and ilInitialisation\initILIAS().

Referenced by __registerMethods().

1606  {
1607  // Note: We need a context that does not handle authentication at this point, because this is
1608  // handled by an actual SOAP request which always contains the session ID and client
1612 
1613  global $DIC;
1614 
1615  $ilPluginAdmin = $DIC['ilPluginAdmin'];
1616  $soapHook = new ilSoapHook($ilPluginAdmin);
1617  foreach ($soapHook->getWsdlTypes() as $type) {
1618  $this->server->wsdl->addComplexType(
1619  $type->getName(),
1620  $type->getTypeClass(),
1621  $type->getPhpType(),
1622  $type->getCompositor(),
1623  $type->getRestrictionBase(),
1624  $type->getElements(),
1625  $type->getAttributes(),
1626  $type->getArrayType()
1627  );
1628  }
1629  foreach ($soapHook->getSoapMethods() as $method) {
1630  $this->server->register(
1631  $method->getName(),
1632  $method->getInputParams(),
1633  $method->getOutputParams(),
1634  $method->getServiceNamespace(),
1635  $method->getServiceNamespace() . '#' . $method->getName(),
1636  $method->getServiceStyle(),
1637  $method->getServiceUse(),
1638  $method->getDocumentation()
1639  );
1640  }
1641  }
$type
global $DIC
Definition: saml.php:7
const CONTEXT_SOAP_NO_AUTH
static initILIAS()
ilias initialisation
Class ilSoapHook.
static init($a_type)
Init context by type.
const CONTEXT_SOAP
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ start()

ilNusoapUserAdministrationAdapter::start ( )

Definition at line 66 of file class.ilNusoapUserAdministrationAdapter.php.

References exit.

67  {
68  $postdata = file_get_contents("php://input");
69  $this->server->service($postdata);
70  exit();
71  }
exit
Definition: backend.php:16

Field Documentation

◆ $server

ilNusoapUserAdministrationAdapter::$server = null

Definition at line 46 of file class.ilNusoapUserAdministrationAdapter.php.


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