• Main Page
  • Related Pages
  • Modules
  • Namespaces
  • Data Structures
  • Files
  • File List
  • Globals

webservice/soap/classes/class.ilSoapGLOStructureReader.php

Go to the documentation of this file.
00001 <?php
00002 
00003 /*
00004    +-----------------------------------------------------------------------------+
00005    | ILIAS open source                                                           |
00006    +-----------------------------------------------------------------------------+
00007    | Copyright (c) 1998-2001 ILIAS open source, University of Cologne            |
00008    |                                                                             |
00009    | This program is free software; you can redistribute it and/or               |
00010    | modify it under the terms of the GNU General Public License                 |
00011    | as published by the Free Software Foundation; either version 2              |
00012    | of the License, or (at your option) any later version.                      |
00013    |                                                                             |
00014    | This program is distributed in the hope that it will be useful,             |
00015    | but WITHOUT ANY WARRANTY; without even the implied warranty of              |
00016    | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the               |
00017    | GNU General Public License for more details.                                |
00018    |                                                                             |
00019    | You should have received a copy of the GNU General Public License           |
00020    | along with this program; if not, write to the Free Software                 |
00021    | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA. |
00022    +-----------------------------------------------------------------------------+
00023   */
00024 
00025 
00035 include_once "./webservice/soap/classes/class.ilSoapStructureReader.php";
00036 include_once "./webservice/soap/classes/class.ilSoapStructureObjectFactory.php";
00037 include_once "./Modules/Glossary/classes/class.ilGlossaryDefinition.php";
00038 
00039 class ilSoapGLOStructureReader extends ilSoapStructureReader
00040 {
00041 
00042         function ilSoapGLOStructureReader ($object)
00043         {
00044                 parent::ilSoapStructureReader($object);
00045         }
00046 
00047         function _parseStructure () {
00048             /* @var $object ilObjGlossary */
00049 
00050             $terms = $this->object->getTermlist();
00051 
00052             foreach ($terms as $term)
00053                 {
00054 
00055                     /* @var $termStructureObject ilSoapGLOTermStructureObject*/
00056                     $termStructureObject = ilSoapStructureObjectFactory::getInstance (
00057                       $term["id"], "git", $term["term"], "", $this->getObject()->getRefId());
00058 
00059                     $this->structureObject->addStructureObject($termStructureObject);
00060 
00061                     $defs = ilGlossaryDefinition::getDefinitionList($term["id"]);
00062 
00063                     foreach ($defs as $def) {
00064                         $defStructureObject = ilSoapStructureObjectFactory::getInstance(
00065                           $def["id"], "gdf", $def["short_text"], "", $this->getObject()->getRefId());
00066 
00067                 $termStructureObject->addStructureObject($defStructureObject);
00068                     }
00069 
00070                    // print_r($defs);
00071 
00072                 }
00073 
00074 
00075         }
00076 }
00077 
00078 ?>

Generated on Fri Dec 13 2013 17:57:03 for ILIAS Release_3_9_x_branch .rev 46835 by  doxygen 1.7.1