4include_once 
'./Services/WebServices/ECS/classes/class.ilECSConnector.php';
 
    5include_once 
'./Services/WebServices/ECS/classes/class.ilECSConnectorException.php';
 
    6include_once 
'./Services/WebServices/ECS/classes/Connectors/class.ilECSEnrolmentStatus.php';
 
   35                        $this->path_postfix = 
'/campusconnect/member_status/'. (int) $a_enrole_id;
 
   37                if($a_details and $a_enrole_id)
 
   39                        $this->path_postfix .= 
'/details';
 
   48                                $this->
addHeader(
'Accept', 
'application/json');
 
   52                                #$this->addHeader('Accept', 'text/uri-list'); 
   54                        $this->curl->setOpt(CURLOPT_HTTPHEADER, $this->
getHeader());
 
   57                        if(substr(
$res, 0, 4) == 
'http')
 
   59                                $json = file_get_contents(
$res);
 
   70                                include_once 
'./Services/WebServices/ECS/classes/class.ilECSEContentDetails.php';
 
   73                                $details->loadFromJson($ecs_result->getResult());
 
   78                                include_once 
'./Services/WebServices/ECS/classes/Connectors/class.ilECSEnrolmentStatus.php';
 
   80                                $enrolment->loadFromJson($ecs_result->getResult());
 
   98                $ilLog->write(__METHOD__.
': Add new enrolment status');
 
  100                $this->path_postfix = 
'/campusconnect/member_status';
 
  106                        $this->
addHeader(
'Content-Type', 
'application/json');
 
  107                        $this->
addHeader(
'Accept', 
'application/json');
 
  109                        #$this->addHeader(ilECSConnector::HEADER_MEMBERSHIPS, 1); 
  111                        $this->curl->setOpt(CURLOPT_HTTPHEADER, $this->
getHeader());
 
  112                        $this->curl->setOpt(CURLOPT_POST,
true);
 
  113                        $this->curl->setOpt(CURLOPT_POSTFIELDS,json_encode($enrolment));
 
  116                        $info = $this->curl->getInfo(CURLINFO_HTTP_CODE);
 
  118                        $ilLog->write(__METHOD__.
': Checking HTTP status...');
 
  119                        if(
$info != self::HTTP_CODE_CREATED)
 
  121                                $ilLog->write(__METHOD__.
': Cannot create auth resource, did not receive HTTP 201. ');
 
  122                                $ilLog->write(__METHOD__.
': POST was: '.print_r($enrolment,TRUE));
 
  126                        $ilLog->write(__METHOD__.
': ... got HTTP 201 (created)');
 
  129                        $enrolment_res = 
$result->getResult();
 
  131                        $ilLog->write(__METHOD__.
': ... Received result: '.print_r($enrolment_res,TRUE));
 
  133                        return $enrolment_res;
 
addHeader($a_name, $a_value)
Add Header.
prepareConnection()
prepare connection
setHeader($a_header_strings)
Presentation of ecs content details (http://...campusconnect/courselinks/id/details)
Connector for course member ressource.
addEnrolmentStatus(ilECSEnrolmentStatus $enrolment, $a_target_mid)
Add new enrolment status.
getEnrolmentStatus($a_enrole_id=0, $a_details=false)
Get single directory tree.
__construct(ilECSSetting $settings=null)
Constructor.
$GLOBALS['PHPCAS_CLIENT']
This global variable is used by the interface class phpCAS.