ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
inc.soap_functions.php
Go to the documentation of this file.
1 <?php
2 /*
3  +-----------------------------------------------------------------------------+
4  | ILIAS open source |
5  +-----------------------------------------------------------------------------+
6  | Copyright (c) 1998-2006 ILIAS open source, University of Cologne |
7  | |
8  | This program is free software; you can redistribute it and/or |
9  | modify it under the terms of the GNU General Public License |
10  | as published by the Free Software Foundation; either version 2 |
11  | of the License, or (at your option) any later version. |
12  | |
13  | This program is distributed in the hope that it will be useful, |
14  | but WITHOUT ANY WARRANTY; without even the implied warranty of |
15  | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
16  | GNU General Public License for more details. |
17  | |
18  | You should have received a copy of the GNU General Public License |
19  | along with this program; if not, write to the Free Software |
20  | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
21  +-----------------------------------------------------------------------------+
22  */
23 
24 
35 
36  // These functions are wrappers for soap, since it cannot register methods inside classes
37 
38  // USER ADMINISTRATION
39  public static function login($client,$username,$password)
40  {
41  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
42 
43  $sua = new ilSoapUserAdministration();
44 
45  return $sua->login($client,$username,$password);
46  }
47 
48  public static function loginCAS($client, $PT, $user)
49  {
50  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
51 
52  $sua = new ilSoapUserAdministration();
53 
54  return $sua->loginCAS($client, $PT, $user);
55  }
56 
57  public static function loginLDAP($client, $username, $password)
58  {
59  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
60 
61  $sua = new ilSoapUserAdministration();
62 
63  return $sua->loginLDAP($client, $username, $password);
64  }
65 
69  public static function loginStudipUser($sid,$user_id)
70  {
71  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
72 
73  $sua = new ilSoapUserAdministration();
74 
75  return $sua->loginStudipUser($sid,$user_id);
76  }
77 
78 
79  public static function logout($sid)
80  {
81  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
82 
83  $sua = new ilSoapUserAdministration();
84 
85  return $sua->logout($sid);
86  }
87  public static function lookupUser($sid,$user_name)
88  {
89  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
90 
91  $sua = new ilSoapUserAdministration();
92 
93  return $sua->lookupUser($sid,$user_name);
94  }
95 
96  public static function getUser($sid,$user_id)
97  {
98  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
99 
100  $sua = new ilSoapUserAdministration();
101 
102  return $sua->getUser($sid,$user_id);
103  }
104 
105 
106 
109  public static function deleteUser($sid,$user_id)
110  {
111  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
112 
113  $sua = new ilSoapUserAdministration();
114 
115  return $sua->deleteUser($sid,$user_id);
116  }
117 
118 
119  // COURSE ADMINSTRATION
120  public static function addCourse($sid,$target_id,$crs_xml)
121  {
122  include_once './webservice/soap/classes/class.ilSoapCourseAdministration.php';
123 
124  $sca = new ilSoapCourseAdministration();
125 
126  return $sca->addCourse($sid,$target_id,$crs_xml);
127  }
128  public static function deleteCourse($sid,$course_id)
129  {
130  include_once './webservice/soap/classes/class.ilSoapCourseAdministration.php';
131 
132  $sca = new ilSoapCourseAdministration();
133 
134  return $sca->deleteCourse($sid,$course_id);
135  }
136  public static function assignCourseMember($sid,$course_id,$user_id,$type)
137  {
138  include_once './webservice/soap/classes/class.ilSoapCourseAdministration.php';
139 
140  $sca = new ilSoapCourseAdministration();
141 
142  return $sca->assignCourseMember($sid,$course_id,$user_id,$type);
143  }
144  public static function isAssignedToCourse($sid,$course_id,$user_id)
145  {
146  include_once './webservice/soap/classes/class.ilSoapCourseAdministration.php';
147 
148  $sca = new ilSoapCourseAdministration();
149 
150  return $sca->isAssignedToCourse($sid,$course_id,$user_id);
151  }
152 
153  public static function excludeCourseMember($sid,$course_id,$user_id)
154  {
155  include_once './webservice/soap/classes/class.ilSoapCourseAdministration.php';
156 
157  $sca = new ilSoapCourseAdministration();
158 
159  return $sca->excludeCourseMember($sid,$course_id,$user_id);
160  }
161  public static function getCourseXML($sid,$course_id)
162  {
163  include_once './webservice/soap/classes/class.ilSoapCourseAdministration.php';
164 
165  $sca = new ilSoapCourseAdministration();
166 
167  return $sca->getCourseXML($sid,$course_id);
168  }
169  public static function updateCourse($sid,$course_id,$xml)
170  {
171  include_once './webservice/soap/classes/class.ilSoapCourseAdministration.php';
172 
173  $sca = new ilSoapCourseAdministration();
174 
175  return $sca->updateCourse($sid,$course_id,$xml);
176  }
177  // Object admninistration
178  public static function getObjIdByImportId($sid,$import_id)
179  {
180  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
181 
182  $soa = new ilSoapObjectAdministration();
183 
184  return $soa->getObjIdByImportId($sid,$import_id);
185  }
186 
187  public static function getRefIdsByImportId($sid,$import_id)
188  {
189  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
190 
191  $soa = new ilSoapObjectAdministration();
192 
193  return $soa->getRefIdsByImportId($sid,$import_id);
194  }
195  public static function getRefIdsByObjId($sid,$object_id)
196  {
197  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
198 
199  $soa = new ilSoapObjectAdministration();
200 
201  return $soa->getRefIdsByObjId($sid,$object_id);
202  }
203 
204 
205  public static function getObjectByReference($sid,$a_ref_id,$user_id)
206  {
207  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
208 
209  $soa = new ilSoapObjectAdministration();
210 
211  return $soa->getObjectByReference($sid,$a_ref_id,$user_id);
212  }
213 
214  public static function getObjectsByTitle($sid,$a_title,$user_id)
215  {
216  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
217 
218  $soa = new ilSoapObjectAdministration();
219 
220  return $soa->getObjectsByTitle($sid,$a_title,$user_id);
221  }
222 
223  public static function addObject($sid,$a_target_id,$a_xml)
224  {
225  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
226 
227  $soa = new ilSoapObjectAdministration();
228 
229  return $soa->addObject($sid,$a_target_id,$a_xml);
230  }
231 
232  public static function addReference($sid,$a_source_id,$a_target_id)
233  {
234  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
235 
236  $soa = new ilSoapObjectAdministration();
237 
238  return $soa->addReference($sid,$a_source_id,$a_target_id);
239  }
240 
241  public static function deleteObject($sid,$reference_id)
242  {
243  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
244 
245  $soa = new ilSoapObjectAdministration();
246 
247  return $soa->deleteObject($sid,$reference_id);
248  }
249 
250  public static function removeFromSystemByImportId($sid,$import_id)
251  {
252  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
253 
254  $soa = new ilSoapObjectAdministration();
255 
256  return $soa->removeFromSystemByImportId($sid,$import_id);
257  }
258 
259  public static function updateObjects($sid,$obj_xml)
260  {
261  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
262 
263  $soa = new ilSoapObjectAdministration();
264 
265  return $soa->updateObjects($sid,$obj_xml);
266  }
267  public static function searchObjects($sid,$types,$key,$combination,$user_id)
268  {
269  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
270 
271  $soa = new ilSoapObjectAdministration();
272 
273  return $soa->searchObjects($sid,$types,$key,$combination,$user_id);
274  }
275 
276  public static function getTreeChilds($sid,$ref_id,$types,$user_id)
277  {
278  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
279 
280  $soa = new ilSoapObjectAdministration();
281 
282  return $soa->getTreeChilds($sid,$ref_id,$types,$user_id);
283  }
284 
285  public static function getXMLTree($sid,$ref_id,$types,$user_id)
286  {
287  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
288 
289  $soa = new ilSoapObjectAdministration();
290 
291  return $soa->getXMLTree($sid,$ref_id,$types,$user_id);
292  }
293 
294 
295 
296  // Rbac Tree public static function s
297  public static function getOperations($sid)
298  {
299  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
300 
301  $soa = new ilSoapRBACAdministration();
302 
303  return $soa->getOperations($sid);
304  }
305 
306 
307  public static function addUserRoleEntry($sid,$user_id,$role_id)
308  {
309  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
310 
311  $soa = new ilSoapRBACAdministration();
312 
313  return $soa->addUserRoleEntry($sid,$user_id,$role_id);
314  }
315 
316  public static function deleteUserRoleEntry($sid,$user_id,$role_id)
317  {
318  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
319 
320  $soa = new ilSoapRBACAdministration();
321 
322  return $soa->deleteUserRoleEntry($sid,$user_id,$role_id);
323  }
324 
325  public static function revokePermissions($sid,$ref_id,$role_id)
326  {
327  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
328 
329  $soa = new ilSoapRBACAdministration();
330 
331  return $soa->revokePermissions($sid,$ref_id,$role_id);
332  }
333 
334  public static function grantPermissions($sid,$ref_id,$role_id,$permissions)
335  {
336  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
337 
338  $soa = new ilSoapRBACAdministration();
339 
340  return $soa->grantPermissions($sid,$ref_id,$role_id,$permissions);
341  }
342 
343  public static function getLocalRoles($sid,$ref_id)
344  {
345  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
346 
347  $soa = new ilSoapRBACAdministration();
348 
349  return $soa->getLocalRoles($sid,$ref_id);
350  }
351 
352  public static function getUserRoles($sid,$user_id)
353  {
354  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
355 
356  $soa = new ilSoapRBACAdministration();
357 
358  return $soa->getUserRoles($sid,$user_id);
359  }
360 
361  public static function deleteRole($sid,$role_id)
362  {
363  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
364 
365  $soa = new ilSoapRBACAdministration();
366 
367  return $soa->deleteRole($sid,$role_id);
368  }
369 
370  public static function addRole($sid,$target_id,$obj_xml)
371  {
372  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
373 
374  $soa = new ilSoapRBACAdministration();
375 
376  return $soa->addRole($sid,$target_id,$obj_xml);
377  }
378  public static function addRoleFromTemplate($sid,$target_id,$obj_xml,$template_id)
379  {
380  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
381 
382  $soa = new ilSoapRBACAdministration();
383 
384  return $soa->addRoleFromTemplate($sid,$target_id,$obj_xml,$template_id);
385  }
386 
387  public static function getObjectTreeOperations($sid,$ref_id,$user_id)
388  {
389  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
390 
391  $soa = new ilSoapRBACAdministration();
392 
393  return $soa->getObjectTreeOperations($sid,$ref_id,$user_id);
394  }
395 
396  public static function addGroup($sid,$target_id,$group_xml)
397  {
398  include_once './webservice/soap/classes/class.ilSoapGroupAdministration.php';
399 
400  $soa = new ilSoapGroupAdministration();
401 
402  return $soa->addGroup($sid,$target_id,$group_xml);
403  }
404 
405  public static function groupExists($sid,$title)
406  {
407  include_once './webservice/soap/classes/class.ilSoapGroupAdministration.php';
408 
409  $soa = new ilSoapGroupAdministration();
410 
411  return $soa->groupExists($sid,$title);
412  }
413  public static function getGroup($sid,$ref_id)
414  {
415  include_once './webservice/soap/classes/class.ilSoapGroupAdministration.php';
416 
417  $soa = new ilSoapGroupAdministration();
418 
419  return $soa->getGroup($sid,$ref_id);
420  }
421 
422  public static function assignGroupMember($sid,$group_id,$user_id,$type)
423  {
424  include_once './webservice/soap/classes/class.ilSoapGroupAdministration.php';
425 
426  $sca = new ilSoapGroupAdministration();
427 
428  return $sca->assignGroupMember($sid,$group_id,$user_id,$type);
429  }
430  public static function isAssignedToGroup($sid,$group_id,$user_id)
431  {
432  include_once './webservice/soap/classes/class.ilSoapGroupAdministration.php';
433 
434  $sca = new ilSoapGroupAdministration();
435 
436  return $sca->isAssignedToGroup($sid,$group_id,$user_id);
437  }
438 
439  public static function excludeGroupMember($sid,$group_id,$user_id)
440  {
441  include_once './webservice/soap/classes/class.ilSoapGroupAdministration.php';
442 
443  $sca = new ilSoapGroupAdministration();
444 
445  return $sca->excludeGroupMember($sid,$group_id,$user_id,$type);
446  }
447 
448 
449  public static function sendMail($sid,$to,$cc,$bcc,$sender,$subject,$message,$attach)
450  {
451  include_once './webservice/soap/classes/class.ilSoapUtils.php';
452 
453  $sou = new ilSoapUtils();
454  $sou->disableSOAPCheck();
455  $sou->ignoreUserAbort();
456 
457  return $sou->sendMail($sid,$to,$cc,$bcc,$sender,$subject,$message,$attach);
458  }
459 
460  public static function distributeMails($sid,$mail_xml)
461  {
462  include_once './webservice/soap/classes/class.ilSoapUtils.php';
463 
464  $sou = new ilSoapUtils();
465  return $sou->distributeMails($sid,$mail_xml);
466 
467  }
468 
469  public static function ilClone($sid,$copy_identifier)
470  {
471  include_once './webservice/soap/classes/class.ilSoapUtils.php';
472 
473  $sou = new ilSoapUtils();
474  $sou->disableSOAPCheck();
475  $sou->ignoreUserAbort();
476 
477  return $sou->ilClone($sid,$copy_identifier);
478  }
479  public static function ilCloneDependencies($sid,$copy_identifier)
480  {
481  include_once './webservice/soap/classes/class.ilSoapUtils.php';
482 
483  $sou = new ilSoapUtils();
484  $sou->disableSOAPCheck();
485  $sou->ignoreUserAbort();
486 
487  return $sou->ilCloneDependencies($sid,$copy_identifier);
488  }
489 
490  public static function handleECSTasks($sid,$a_server_id)
491  {
492  include_once './webservice/soap/classes/class.ilSoapUtils.php';
493 
494  $sou = new ilSoapUtils();
495  $sou->disableSoapCheck();
496  $sou->ignoreUserAbort();
497 
498  return $sou->handleECSTasks($sid,$a_server_id);
499  }
500 
501  public static function saveQuestionResult($sid,$user_id,$test_id,$question_id,$pass,$solution)
502  {
503  include_once './webservice/soap/classes/class.ilSoapTestAdministration.php';
504 
505  $sass = new ilSoapTestAdministration();
506 
507  return $sass->saveQuestionResult($sid,$user_id,$test_id,$question_id,$pass,$solution);
508  }
509 
510  public static function saveQuestion($sid,$active_id,$question_id,$pass,$solution)
511  {
512  include_once './webservice/soap/classes/class.ilSoapTestAdministration.php';
513 
514  $sass = new ilSoapTestAdministration();
515 
516  return $sass->saveQuestion($sid,$active_id,$question_id,$pass,$solution);
517  }
518 
519  public static function saveQuestionSolution($sid,$active_id,$question_id,$pass,$solution)
520  {
521  include_once './webservice/soap/classes/class.ilSoapTestAdministration.php';
522 
523  $sass = new ilSoapTestAdministration();
524 
525  return $sass->saveQuestionSolution($sid,$active_id,$question_id,$pass,$solution);
526  }
527 
528  public static function getQuestionSolution($sid,$active_id,$question_id,$pass)
529  {
530  include_once './webservice/soap/classes/class.ilSoapTestAdministration.php';
531 
532  $sass = new ilSoapTestAdministration();
533 
534  return $sass->getQuestionSolution($sid,$active_id,$question_id,$pass);
535  }
536 
537  public static function getTestUserData($sid,$active_id)
538  {
539  include_once './webservice/soap/classes/class.ilSoapTestAdministration.php';
540 
541  $sass = new ilSoapTestAdministration();
542 
543  return $sass->getTestUserData($sid,$active_id);
544  }
545 
546  public static function getNrOfQuestionsInPass($sid, $active_id, $pass)
547  {
548  include_once './webservice/soap/classes/class.ilSoapTestAdministration.php';
549 
550  $sass = new ilSoapTestAdministration();
551 
552  return $sass->getNrOfQuestionsInPass($sid, $active_id, $pass);
553  }
554 
555  public static function getPositionOfQuestion($sid, $active_id, $question_id, $pass)
556  {
557  include_once './webservice/soap/classes/class.ilSoapTestAdministration.php';
558 
559  $sass = new ilSoapTestAdministration();
560 
561  return $sass->getPositionOfQuestion($sid, $active_id, $question_id, $pass);
562  }
563 
564  public static function getPreviousReachedPoints($sid, $active_id, $question_id, $pass)
565  {
566  include_once './webservice/soap/classes/class.ilSoapTestAdministration.php';
567 
568  $sass = new ilSoapTestAdministration();
569 
570  return $sass->getPreviousReachedPoints($sid, $active_id, $question_id, $pass);
571  }
572 
573  public static function saveTempFileAsMediaObject($sid,$name,$tmp_name)
574  {
575  include_once './webservice/soap/classes/class.ilSoapUtils.php';
576 
577  $sou = new ilSoapUtils();
578  $sou->disableSOAPCheck();
579 
580  return $sou->saveTempFileAsMediaObject($sid, $name, $tmp_name);
581  }
582 
583  public static function getMobsOfObject($sid, $a_type, $a_id)
584  {
585  include_once './webservice/soap/classes/class.ilSoapUtils.php';
586 
587  $sou = new ilSoapUtils();
588  $sou->disableSOAPCheck();
589 
590  return $sou->getMobsOfObject($sid, $a_type, $a_id);
591  }
592 
593  public static function getStructureObjects ($sid, $ref_id) {
594  include_once './webservice/soap/classes/class.ilSoapStructureObjectAdministration.php';
595 
597 
598  return $sca->getStructureObjects ($sid, $ref_id);
599  }
600 
601  public static function getRoles($sid, $role_type, $id)
602  {
603  include_once './webservice/soap/classes/class.ilSoapRBACAdministration.php';
604 
605  $soa = new ilSoapRBACAdministration();
606 
607  return $soa->getRoles($sid, $role_type, $id);
608  }
609 
610  public static function importUsers ($sid, $folder_id, $usr_xml, $conflict_rule, $send_account_mail)
611  {
612  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
613 
614  $sua = new ilSoapUserAdministration();
615 
616  return $sua->importUsers($sid, $folder_id, $usr_xml, $conflict_rule, $send_account_mail);
617  }
618 
619  public static function getUsersForContainer ($sid, $ref_id, $attach_roles, $active)
620  {
621  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
622 
623  $sua = new ilSoapUserAdministration();
624 
625  return $sua->getUsersForContainer($sid, $ref_id, $attach_roles, $active);
626  }
627 
628  public static function getUsersForRole ($sid, $role_id, $attach_roles, $active)
629  {
630  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
631 
632  $sua = new ilSoapUserAdministration();
633 
634  return $sua->getUserForRole($sid, $role_id, $attach_roles, $active);
635  }
636 
637 
638  public static function searchUser ($sid, $a_keyfields, $query_operator, $a_keyvalues, $attach_roles, $active) {
639  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
640 
641  $sua = new ilSoapUserAdministration();
642 
643  return $sua->searchUser ($sid, $a_keyfields, $query_operator, $a_keyvalues, $attach_roles, $active);
644 
645  }
646 
647  public static function hasNewMail($sid)
648  {
649  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
650 
651  $sua = new ilSoapUserAdministration();
652 
653  return $sua->hasNewMail($sid);
654  }
655 
656  public static function getNIC($sid) {
657  include_once './webservice/soap/classes/class.ilSoapAdministration.php';
658  $soa = new ilSoapAdministration();
659  return $soa->getNIC($sid);
660  }
661 
662  public static function getExerciseXML ($sid, $ref_id, $attachFileContentsMode) {
663  include_once './webservice/soap/classes/class.ilSoapExerciseAdministration.php';
664  $sta = new ilSoapExerciseAdministration();
665  return $sta->getExerciseXML($sid, $ref_id, $attachFileContentsMode);
666 
667  }
668 
669 
670  public static function updateExercise ($sid, $ref_id, $xml) {
671  include_once './webservice/soap/classes/class.ilSoapExerciseAdministration.php';
672  $sta = new ilSoapExerciseAdministration();
673  return $sta->updateExercise($sid, $ref_id, $xml);
674 
675  }
676 
677  public static function addExercise ($sid, $ref_id, $xml) {
678  include_once './webservice/soap/classes/class.ilSoapExerciseAdministration.php';
679  $sta = new ilSoapExerciseAdministration();
680  return $sta->addExercise($sid, $ref_id, $xml);
681 
682  }
683 
684  public static function getFileXML ($sid, $ref_id, $attachFileContentsMode)
685  {
686  include_once './webservice/soap/classes/class.ilSoapFileAdministration.php';
687  $sta = new ilSoapFileAdministration();
688  return $sta->getFileXML($sid, $ref_id, $attachFileContentsMode);
689 
690  }
691 
692 
693  public static function updateFile ($sid, $ref_id, $xml)
694  {
695  include_once './webservice/soap/classes/class.ilSoapFileAdministration.php';
696  $sta = new ilSoapFileAdministration();
697  return $sta->updateFile($sid, $ref_id, $xml);
698 
699  }
700 
701  public static function addFile ($sid, $ref_id, $xml)
702  {
703  include_once './webservice/soap/classes/class.ilSoapFileAdministration.php';
704  $sta = new ilSoapFileAdministration();
705  return $sta->addFile($sid, $ref_id, $xml);
706 
707  }
708 
709  public static function getObjIdsByRefIds($sid, $ref_ids)
710  {
711  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
712 
713  $soa = new ilSoapObjectAdministration();
714 
715  return $soa->getObjIdsByRefIds($sid, $ref_ids);
716  }
717 
718  public static function getUserXML($sid,$user_ids, $attach_roles)
719  {
720  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
721 
722  $sua = new ilSoapUserAdministration();
723 
724  return $sua->getUserXML($sid, $user_ids, $attach_roles);
725  }
726 
727  public static function updateGroup($sid, $ref_id, $grp_xml)
728  {
729  include_once './webservice/soap/classes/class.ilSoapGroupAdministration.php';
730 
731  $sua = new ilSoapGroupAdministration();
732 
733  return $sua->updateGroup($sid,$ref_id, $grp_xml);
734  }
735 
736  public static function getIMSManifestXML($sid, $ref_id) {
737  include_once './webservice/soap/classes/class.ilSoapSCORMAdministration.php';
738 
739  $sua = new ilSoapSCORMAdministration();
740 
741  return $sua->getIMSManifestXML($sid,$ref_id);
742  }
743 
744  public static function hasSCORMCertificate($sid, $ref_id, $usr_id) {
745  include_once './webservice/soap/classes/class.ilSoapSCORMAdministration.php';
746 
747  $sua = new ilSoapSCORMAdministration();
748 
749  return $sua->hasSCORMCertificate($sid,$ref_id,$usr_id);
750  }
751 
757  public static function copyObject($sid, $copy_settings_xml) {
758  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
759 
760  $soa = new ilSoapObjectAdministration();
761 
762  return $soa->copyObject($sid, $copy_settings_xml);
763 
764  }
765 
772  public static function moveObject($sid, $ref_id, $target_id)
773  {
774  include_once './webservice/soap/classes/class.ilSoapObjectAdministration.php';
775 
776  $soa = new ilSoapObjectAdministration();
777 
778  return $soa->moveObject($sid, $ref_id, $target_id);
779  }
780 
781 
792  public static function getTestResults ($sid, $ref_id,$sum_only) {
793  include_once './webservice/soap/classes/class.ilSoapTestAdministration.php';
794 
795  $soa = new ilSoapTestAdministration();
796 
797  return $soa->getTestResults($sid, $ref_id,$sum_only);
798 
799  }
800 
810  public static function removeTestResults ($sid, $ref_id, $a_user_ids)
811  {
812  include_once './webservice/soap/classes/class.ilSoapTestAdministration.php';
813 
814  $soa = new ilSoapTestAdministration();
815  return $soa->removeTestResults($sid, $ref_id,$a_user_ids);
816  }
817 
825  public static function getCoursesForUser($sid, $parameters) {
826  include_once 'webservice/soap/classes/class.ilSoapCourseAdministration.php';
827  $soc = new ilSoapCourseAdministration();
828  return $soc->getCoursesForUser($sid, $parameters);
829  }
830 
838  public static function getGroupsForUser($sid, $parameters) {
839  include_once 'webservice/soap/classes/class.ilSoapGroupAdministration.php';
840  $soc = new ilSoapGroupAdministration();
841  return $soc->getGroupsForUser($sid, $parameters);
842  }
843 
844  public static function getPathForRefId($sid, $ref_id) {
845  include_once 'webservice/soap/classes/class.ilSoapObjectAdministration.php';
846  $soa = new ilSoapObjectAdministration();
847  return $soa->getPathForRefId($sid, $ref_id);
848  }
849 
850  public static function searchRoles ($sid, $key, $combination, $role_type)
851  {
852  include_once 'webservice/soap/classes/class.ilSoapRBACAdministration.php';
853  $roa = new ilSoapRBACAdministration();
854  return $roa->searchRoles($sid, $key, $combination, $role_type);
855  }
856 
857 
858  public static function getInstallationInfoXML() {
859  include_once 'webservice/soap/classes/class.ilSoapAdministration.php';
860  $roa = new ilSoapAdministration();
861  return $roa->getInstallationInfoXML();
862  }
863 
864  public static function getClientInfoXML($clientid) {
865  include_once 'webservice/soap/classes/class.ilSoapAdministration.php';
866  $roa = new ilSoapAdministration();
867  return $roa->getClientInfoXML($clientid);
868  }
869 
875  public static function buildHTTPPath() {
876  if($_SERVER["HTTPS"] == "on")
877  {
878  $protocol = 'https://';
879  }
880  else
881  {
882  $protocol = 'http://';
883  }
884  $host = $_SERVER['HTTP_HOST'];
885 
886  $path = dirname($_SERVER['REQUEST_URI']);
887 
888  //dirname cuts the last directory from a directory path e.g content/classes return content
889  include_once 'Services/Utilities/classes/class.ilUtil.php';
891 
892  $dirs = explode('/',$module);
893  $uri = $path;
894  foreach($dirs as $dir)
895  {
896  $uri = dirname($uri);
897  }
898  return ilUtil::removeTrailingPathSeparators($protocol.$host.$uri);
899  }
900 
901  public static function getSCORMCompletionStatus($sid, $usr_id, $a_ref_id)
902  {
903  include_once './webservice/soap/classes/class.ilSoapSCORMAdministration.php';
904 
905  $sua = new ilSoapSCORMAdministration();
906 
907  return $sua->getSCORMCompletionStatus($sid, $usr_id, $a_ref_id);
908  }
909 
910  public static function getUserIdBySid($sid)
911  {
912  include_once './webservice/soap/classes/class.ilSoapUserAdministration.php';
913 
914  $sua = new ilSoapUserAdministration();
915 
916  return $sua->getUserIdBySid($sid);
917  }
918 
919  public static function readWebLink($sid,$ref_id)
920  {
921  include_once './webservice/soap/classes/class.ilSoapWebLinkAdministration.php';
922 
923  $swa = new ilSoapWebLinkAdministration();
924  return $swa->readWebLink($sid, $ref_id);
925  }
926 
927  public static function createWebLink($sid,$ref_id,$xml)
928  {
929  include_once './webservice/soap/classes/class.ilSoapWebLinkAdministration.php';
930 
931  $swa = new ilSoapWebLinkAdministration();
932  return $swa->createWebLink($sid, $ref_id,$xml);
933  }
934 
935  public static function updateWebLink($sid,$ref_id,$xml)
936  {
937  include_once './webservice/soap/classes/class.ilSoapWebLinkAdministration.php';
938 
939  $swa = new ilSoapWebLinkAdministration();
940  return $swa->updateWebLink($sid, $ref_id,$xml);
941  }
942 
956  public static function deleteExpiredDualOptInUserObjects($sid, $usr_id)
957  {
958  include_once './webservice/soap/classes/class.ilSoapUtils.php';
959 
960  $sou = new ilSoapUtils();
961  $sou->disableSOAPCheck();
962  $sou->ignoreUserAbort();
963 
964  return $sou->deleteExpiredDualOptInUserObjects($sid, $usr_id);
965  }
966 
967  /*
968  public static function getSkillCompletionDateForTriggerRefId($sid, $usr_id, $a_ref_id)
969  {
970  include_once './webservice/soap/classes/class.ilSoapSkillAdministration.php';
971  $s = new ilSoapSkillAdministration();
972 
973  $res = $s->getCompletionDateForTriggerRefId($sid, $usr_id, $a_ref_id);
974  return $res;
975  }
976 
977  public static function checkSkillUserCertificateForTriggerRefId($sid, $usr_id, $a_ref_id)
978  {
979  include_once './webservice/soap/classes/class.ilSoapSkillAdministration.php';
980 
981  $s = new ilSoapSkillAdministration();
982  return $s->checkUserCertificateForTriggerRefId($sid, $usr_id, $a_ref_id);
983  }
984 
985  public static function getSkillTriggerOfAllCertificates($sid, $usr_id)
986  {
987  include_once './webservice/soap/classes/class.ilSoapSkillAdministration.php';
988 
989  $s = new ilSoapSkillAdministration();
990  return $s->getTriggerOfAllCertificates($sid, $usr_id);
991  }
992  */
993 
1002  public static function deleteProgress($sid, $ref_ids, $usr_ids, $type_filter, $progress_filter)
1003  {
1004  include_once './webservice/soap/classes/class.ilSoapLearningProgressAdministration.php';
1006  return $sla->deleteProgress($sid, $ref_ids, $usr_ids, $type_filter, $progress_filter);
1007  }
1008  // mcs-patch start
1009  public static function getLearningProgressChanges($sid, $timestamp, $include_ref_ids, $type_filter)
1010  {
1011  include_once './webservice/soap/classes/class.ilSoapLearningProgressAdministration.php';
1012 
1014 
1015  return $s->getLearningProgressChanges($sid, $timestamp, $include_ref_ids, $type_filter);
1016  }
1017  // mcs-patch end
1018 
1019 
1027  public static function getProgressInfo($sid, $ref_id, $progress_filter)
1028  {
1029  include_once './webservice/soap/classes/class.ilSoapLearningProgressAdministration.php';
1031  return $sla->getProgressInfo($sid, $ref_id, $progress_filter);
1032 
1033  }
1034 
1046  public static function exportDataCollectionContent($sid, $data_collection_id, $table_id = null, $format = "xls", $filepath = null) {
1047  include_once './webservice/soap/classes/class.ilSoapDataCollectionAdministration.php';
1049  return $dcl->exportDataCollectionContent($sid, $data_collection_id, $table_id, $format, $filepath);
1050  }
1051 
1060  public static function processBackgroundTask($sid, $task_id) {
1061  include_once './webservice/soap/classes/class.ilSoapBackgroundTaskAdministration.php';
1063  return $bg->processBackgroundTask($sid, $task_id);
1064  }
1065 
1066 }
1067 
1068 ?>
static removeFromSystemByImportId($sid, $import_id)
static isAssignedToGroup($sid, $group_id, $user_id)
static getLocalRoles($sid, $ref_id)
static getObjIdsByRefIds($sid, $ref_ids)
static getOperations($sid)
static deleteUser($sid, $user_id)
$path
Definition: aliased.php:25
static updateExercise($sid, $ref_id, $xml)
if((!isset($_SERVER['DOCUMENT_ROOT'])) OR(empty($_SERVER['DOCUMENT_ROOT']))) $_SERVER['DOCUMENT_ROOT']
static searchRoles($sid, $key, $combination, $role_type)
$template_id
Definition: example_062.php:89
static loginStudipUser($sid, $user_id)
static getUserRoles($sid, $user_id)
static processBackgroundTask($sid, $task_id)
Process background task.
static getInstallationInfoXML()
static grantPermissions($sid, $ref_id, $role_id, $permissions)
static getPositionOfQuestion($sid, $active_id, $question_id, $pass)
This class handles all DB changes necessary for fraunhofer.
static getUsersForContainer($sid, $ref_id, $attach_roles, $active)
static login($client, $username, $password)
static getUsersForRole($sid, $role_id, $attach_roles, $active)
static removeTestResults($sid, $ref_id, $a_user_ids)
Remove test results of user.
static getClientInfoXML($clientid)
static deleteUserRoleEntry($sid, $user_id, $role_id)
static revokePermissions($sid, $ref_id, $role_id)
static getSCORMCompletionStatus($sid, $usr_id, $a_ref_id)
static ilClone($sid, $copy_identifier)
static getGroup($sid, $ref_id)
static getQuestionSolution($sid, $active_id, $question_id, $pass)
static importUsers($sid, $folder_id, $usr_xml, $conflict_rule, $send_account_mail)
static excludeGroupMember($sid, $group_id, $user_id)
static getCourseXML($sid, $course_id)
static deleteProgress($sid, $ref_ids, $usr_ids, $type_filter, $progress_filter)
Delete progress.
static updateObjects($sid, $obj_xml)
static createWebLink($sid, $ref_id, $xml)
$target_id
Definition: goto.php:51
static searchUser($sid, $a_keyfields, $query_operator, $a_keyvalues, $attach_roles, $active)
static getRefIdsByImportId($sid, $import_id)
static saveQuestionResult($sid, $user_id, $test_id, $question_id, $pass, $solution)
static assignCourseMember($sid, $course_id, $user_id, $type)
static handleECSTasks($sid, $a_server_id)
static assignGroupMember($sid, $group_id, $user_id, $type)
static readWebLink($sid, $ref_id)
static deleteObject($sid, $reference_id)
static getObjectTreeOperations($sid, $ref_id, $user_id)
static addGroup($sid, $target_id, $group_xml)
static addCourse($sid, $target_id, $crs_xml)
static getUser($sid, $user_id)
static copyObject($sid, $copy_settings_xml)
copy object in repository $sid session id $settings_xml contains copy wizard settings following ilias...
static deleteRole($sid, $role_id)
static loginCAS($client, $PT, $user)
static addReference($sid, $a_source_id, $a_target_id)
static moveObject($sid, $ref_id, $target_id)
move object in repository
static searchObjects($sid, $types, $key, $combination, $user_id)
static buildHTTPPath()
builds http path if no client is available
static deleteExpiredDualOptInUserObjects($sid, $usr_id)
Static method for soap webservice: deleteExpiredDualOptInUserObjects.
static getIMSManifestXML($sid, $ref_id)
static hasNewMail($sid)
$client
$a_type
Definition: workflow.php:93
static addUserRoleEntry($sid, $user_id, $role_id)
static getGroupsForUser($sid, $parameters)
return courses for users depending on the status
static distributeMails($sid, $mail_xml)
static getUserXML($sid, $user_ids, $attach_roles)
static getStructureObjects($sid, $ref_id)
static getRoles($sid, $role_type, $id)
static deleteCourse($sid, $course_id)
static sendMail($sid, $to, $cc, $bcc, $sender, $subject, $message, $attach)
static lookupUser($sid, $user_name)
static getTestResults($sid, $ref_id, $sum_only)
get results of test
static getMobsOfObject($sid, $a_type, $a_id)
Soap methods for adminstrating web links.
static saveQuestionSolution($sid, $active_id, $question_id, $pass, $solution)
static addFile($sid, $ref_id, $xml)
static getFileXML($sid, $ref_id, $attachFileContentsMode)
static hasSCORMCertificate($sid, $ref_id, $usr_id)
static excludeCourseMember($sid, $course_id, $user_id)
static groupExists($sid, $title)
static getExerciseXML($sid, $ref_id, $attachFileContentsMode)
static getRefIdsByObjId($sid, $object_id)
static getLearningProgressChanges($sid, $timestamp, $include_ref_ids, $type_filter)
static getObjectByReference($sid, $a_ref_id, $user_id)
static removeTrailingPathSeparators($path)
static loginLDAP($client, $username, $password)
static addExercise($sid, $ref_id, $xml)
static saveQuestion($sid, $active_id, $question_id, $pass, $solution)
static getUserIdBySid($sid)
static getPreviousReachedPoints($sid, $active_id, $question_id, $pass)
static getProgressInfo($sid, $ref_id, $progress_filter)
Get learning progress info.
foreach($mandatory_scripts as $file) $timestamp
Definition: buildRTE.php:81
static getXMLTree($sid, $ref_id, $types, $user_id)
static addRoleFromTemplate($sid, $target_id, $obj_xml, $template_id)
static getObjectsByTitle($sid, $a_title, $user_id)
static updateCourse($sid, $course_id, $xml)
static ilCloneDependencies($sid, $copy_identifier)
static getPathForRefId($sid, $ref_id)
$ref_id
Definition: sahs_server.php:39
static getObjIdByImportId($sid, $import_id)
static updateWebLink($sid, $ref_id, $xml)
const ILIAS_MODULE
Definition: server.php:14
static getTreeChilds($sid, $ref_id, $types, $user_id)
static getCoursesForUser($sid, $parameters)
return courses for users depending on the status
static exportDataCollectionContent($sid, $data_collection_id, $table_id=null, $format="xls", $filepath=null)
Exports a given table of a datacollection into xls.
static addObject($sid, $a_target_id, $a_xml)
static getTestUserData($sid, $active_id)
static isAssignedToCourse($sid, $course_id, $user_id)
static getNrOfQuestionsInPass($sid, $active_id, $pass)
static updateGroup($sid, $ref_id, $grp_xml)
static saveTempFileAsMediaObject($sid, $name, $tmp_name)
static addRole($sid, $target_id, $obj_xml)
static updateFile($sid, $ref_id, $xml)