ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
ilSOAPStructureObjectAdministration Class Reference
+ Inheritance diagram for ilSOAPStructureObjectAdministration:
+ Collaboration diagram for ilSOAPStructureObjectAdministration:

Public Member Functions

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

Additional Inherited Members

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

Detailed Description

Member Function Documentation

◆ getStructureObjects()

ilSOAPStructureObjectAdministration::getStructureObjects (   $sid,
  $ref_id 
)

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

References $filename, $ref_id, ilSoapAdministration\__getMessage(), ilSoapAdministration\__getMessageCode(), ilSoapAdministration\__raiseError(), ilObjectFactory\getInstanceByRefId(), ilSoapAdministration\initAuth(), and ilSoapAdministration\initIlias().

39  {
40  $this->initAuth($sid);
41  $this->initIlias();
42 
43  if(!$this->__checkSession($sid))
44  {
45  return $this->__raiseError($this->__getMessage(),$this->__getMessageCode());
46  }
47 
48  if(!$target_obj =& ilObjectFactory::getInstanceByRefId($ref_id, false))
49  {
50  return $this->__raiseError('No valid reference id given.', 'Client');
51  }
52 
53  $structureReaderClassname = "ilSoap".strtoupper($target_obj->getType())."StructureReader";
54  $filename = "./webservice/soap/classes/class.".$structureReaderClassname.".php";
55 
56  if (!file_exists($filename))
57  {
58  return $this->__raiseError("Object type '".$target_obj->getType()."'is not supported.", 'Client');
59  }
60 
61  include_once $filename;
62 
63  $structureReader = new $structureReaderClassname($target_obj);
64 
65  include_once './webservice/soap/classes/class.ilSoapStructureObjectXMLWriter.php';
66 
67  $xml_writer = new ilSoapStructureObjectXMLWriter();
68 
69  $structureObject = & $structureReader->getStructureObject();
70 
71  $xml_writer->setStructureObject ($structureObject);
72 
73  if(!$xml_writer->start())
74  {
75  return $this->__raiseError('Cannot create object xml !','Server');
76  }
77 
78  return $xml_writer->getXML();
79 
80  }
__raiseError($a_message, $a_code)
$ref_id
Definition: sahs_server.php:39
initAuth($sid)
Init authentication.
static getInstanceByRefId($a_ref_id, $stop_on_error=true)
get an instance of an Ilias object by reference id
+ Here is the call graph for this function:

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