function start()
 {
     global $rbacreview;
     if (!is_array($this->roles)) {
         return false;
     }
     $this->__buildHeader();
     include_once './Services/AccessControl/classes/class.ilObjRole.php';
     include_once './webservice/soap/classes/class.ilObjectXMLWriter.php';
     foreach ($this->roles as $role) {
         // if role type is not empty and does not match, then continue;
         if (!empty($this->role_type) && strcasecmp($this->role_type, $role["role_type"]) != 0) {
             continue;
         }
         if ($rbacreview->isRoleDeleted($role["obj_id"])) {
             continue;
         }
         $attrs = array('role_type' => ucwords($role["role_type"]), 'id' => "il_" . IL_INST_ID . "_role_" . $role["obj_id"]);
         // open tag
         $this->xmlStartTag("Role", $attrs);
         $this->xmlElement('Title', null, $role["title"]);
         $this->xmlElement('Description', null, $role["description"]);
         $this->xmlElement('Translation', null, ilObjRole::_getTranslation($role["title"]));
         if ($ref_id = ilUtil::__extractRefId($role["title"])) {
             $ownerObj = IlObjectFactory::getInstanceByRefId($ref_id, false);
             if (is_object($ownerObj)) {
                 $attrs = array("obj_id" => "il_" . IL_INST_ID . "_" . $ownerObj->getType() . "_" . $ownerObj->getId(), "ref_id" => $ownerObj->getRefId(), "type" => $ownerObj->getType());
                 $this->xmlStartTag('AssignedObject', $attrs);
                 $this->xmlElement('Title', null, $ownerObj->getTitle());
                 $this->xmlElement('Description', null, $ownerObj->getDescription());
                 ilObjectXMLWriter::appendPathToObject($this, $ref_id);
                 $this->xmlEndTag('AssignedObject', $attrs);
             }
         }
         $this->xmlEndTag("Role");
     }
     $this->__buildFooter();
     return true;
 }
 function __appendPath($refid)
 {
     ilObjectXMLWriter::appendPathToObject($this, $refid);
 }