Ticket #377: patchSoapv1_1.diff

File patchSoapv1_1.diff, 199.0 kB (added by sylvain261, 10 months ago)

Nouveau patch

  • build/manifests/jelix-dev.mn

    old new  
    134134  index.php.tpl 
    135135  jsonrpc.php.tpl 
    136136  rdf.php.tpl 
     137  soap.php.tpl 
    137138cd lib/jelix-scripts/templates/scripts 
    138139  cmdline.php.tpl 
    139140cd lib/jelix-scripts/templates/var/config/ 
  • build/manifests/jelix-lib.mn

    old new  
    3232! defaultconfig.ini.php 
    3333* jConfigCompiler.class.php 
    3434  jInstallChecker.class.php 
     35  jSoapCoordinator.class.php 
    3536 
    3637cd lib/jelix/core/request 
    3738  jClassicRequest.class.php 
     
    4142  jXulRequest.class.php 
    4243  jRdfRequest.class.php 
    4344  jCssRequest.class.php 
     45  jSoapRequest.class.php 
    4446 
    4547cd lib/jelix/core/response 
    4648  jResponseBinary.class.php 
     
    6466  jResponseCss.class.php 
    6567  jResponseLatexToPdf.class.php 
    6668  jResponseTcpdf.class.php 
     69  jResponseSoap.class.php 
    6770 
    6871cd lib/jelix/core-modules/jelix 
    6972  module.xml 
     
    8992  install_jacl.schema.mysql.sql 
    9093  install_jacl.datas.mysql.sql 
    9194  install_jsession.schema.mysql.sql 
    92   delete.pgsql.sql 
    93   install_jacl.schema.pgsql.sql 
    94   install_jacl.datas.pgsql.sql 
    95   install_jsession.schema.pgsql.sql 
    96  
    9795cd lib/jelix/core-modules/jelix/locales/en_US 
    9896  acldb.ISO-8859-1.properties 
    99   acldb.ISO-8859-15.properties 
    10097  acldb.UTF-8.properties 
    10198  auth.ISO-8859-1.properties 
    102   auth.ISO-8859-15.properties 
    10399  auth.UTF-8.properties 
    104100  common.ISO-8859-1.properties 
    105   common.ISO-8859-15.properties 
    106101  common.UTF-8.properties 
    107102  crud.ISO-8859-1.properties 
    108   crud.ISO-8859-15.properties 
    109103  crud.UTF-8.properties 
    110104  dao.ISO-8859-1.properties 
    111   dao.ISO-8859-15.properties 
    112105  dao.UTF-8.properties 
    113106  daoxml.ISO-8859-1.properties 
    114   daoxml.ISO-8859-15.properties 
    115107  daoxml.UTF-8.properties 
    116108  db.ISO-8859-1.properties 
    117   db.ISO-8859-15.properties 
    118109  db.UTF-8.properties 
    119110  errors.ISO-8859-1.properties 
    120   errors.ISO-8859-15.properties 
    121111  errors.UTF-8.properties 
    122112  format.ISO-8859-1.properties 
    123   format.ISO-8859-15.properties 
    124113  format.UTF-8.properties 
    125114  formserr.ISO-8859-1.properties 
    126   formserr.ISO-8859-15.properties 
    127115  formserr.UTF-8.properties 
    128116  jelix.ISO-8859-1.properties 
    129   jelix.ISO-8859-15.properties 
    130117  jelix.UTF-8.properties 
    131118  ui.ISO-8859-1.properties 
    132   ui.ISO-8859-15.properties 
    133119  ui.UTF-8.properties 
    134120cd lib/jelix/core-modules/jelix/locales/en_EN 
    135121  acldb.ISO-8859-1.properties 
    136   acldb.ISO-8859-15.properties 
    137122  acldb.UTF-8.properties 
    138123  auth.ISO-8859-1.properties 
    139   auth.ISO-8859-15.properties 
    140124  auth.UTF-8.properties 
    141125  common.ISO-8859-1.properties 
    142   common.ISO-8859-15.properties 
    143126  common.UTF-8.properties 
    144127  crud.ISO-8859-1.properties 
    145   crud.ISO-8859-15.properties 
    146128  crud.UTF-8.properties 
    147129  dao.ISO-8859-1.properties 
    148   dao.ISO-8859-15.properties 
    149130  dao.UTF-8.properties 
    150131  daoxml.ISO-8859-1.properties 
    151   daoxml.ISO-8859-15.properties 
    152132  daoxml.UTF-8.properties 
    153133  db.ISO-8859-1.properties 
    154   db.ISO-8859-15.properties 
    155134  db.UTF-8.properties 
    156135  errors.ISO-8859-1.properties 
    157   errors.ISO-8859-15.properties 
    158136  errors.UTF-8.properties 
    159137  format.ISO-8859-1.properties 
    160   format.ISO-8859-15.properties 
    161138  format.UTF-8.properties 
    162139  formserr.ISO-8859-1.properties 
    163   formserr.ISO-8859-15.properties 
    164140  formserr.UTF-8.properties 
    165141  jelix.ISO-8859-1.properties 
    166   jelix.ISO-8859-15.properties 
    167142  jelix.UTF-8.properties 
    168143  ui.ISO-8859-1.properties 
    169   ui.ISO-8859-15.properties 
    170144  ui.UTF-8.properties 
    171145cd lib/jelix/core-modules/jelix/locales/fr_FR 
    172146  acldb.ISO-8859-1.properties 
    173   acldb.ISO-8859-15.properties 
    174147  acldb.UTF-8.properties 
    175148  auth.ISO-8859-1.properties 
    176   auth.ISO-8859-15.properties 
    177149  auth.UTF-8.properties 
    178150  common.ISO-8859-1.properties 
    179   common.ISO-8859-15.properties 
    180151  common.UTF-8.properties 
    181152  crud.ISO-8859-1.properties 
    182   crud.ISO-8859-15.properties 
    183153  crud.UTF-8.properties 
    184154  dao.ISO-8859-1.properties 
    185   dao.ISO-8859-15.properties 
    186155  dao.UTF-8.properties 
    187156  daoxml.ISO-8859-1.properties 
    188   daoxml.ISO-8859-15.properties 
    189157  daoxml.UTF-8.properties 
    190158  db.ISO-8859-1.properties 
    191   db.ISO-8859-15.properties 
    192159  db.UTF-8.properties 
    193160  errors.ISO-8859-1.properties 
    194   errors.ISO-8859-15.properties 
    195161  errors.UTF-8.properties 
    196162  format.ISO-8859-1.properties 
    197   format.ISO-8859-15.properties 
    198163  format.UTF-8.properties 
    199164  formserr.ISO-8859-1.properties 
    200   formserr.ISO-8859-15.properties 
    201165  formserr.UTF-8.properties 
    202166  jelix.ISO-8859-1.properties 
    203   jelix.ISO-8859-15.properties 
    204167  jelix.UTF-8.properties 
    205168  ui.ISO-8859-1.properties 
    206   ui.ISO-8859-15.properties 
    207169  ui.UTF-8.properties 
    208170cd lib/jelix/core-modules/jelix/templates 
    209171  404.xul.tpl 
     
    268230  jXmlRpc.class.php 
    269231  jZipCreator.class.php 
    270232* jZone.class.php 
     233  jWSDL.class.php 
    271234 
    272235cd lib/jelix-modules 
    273236  LICENCE 
     
    294257  authsw.coord.ini.php 
    295258cd lib/jelix-modules/jauth/locales/en_US 
    296259  auth.ISO-8859-1.properties 
    297   auth.ISO-8859-15.properties 
    298260  auth.UTF-8.properties 
    299261  autherror.ISO-8859-1.properties 
    300   autherror.ISO-8859-15.properties 
    301262  autherror.UTF-8.properties 
    302263cd lib/jelix-modules/jauth/locales/en_EN 
    303264  auth.ISO-8859-1.properties 
    304   auth.ISO-8859-15.properties 
    305265  auth.UTF-8.properties 
    306266  autherror.ISO-8859-1.properties 
    307   autherror.ISO-8859-15.properties 
    308267  autherror.UTF-8.properties 
    309268cd lib/jelix-modules/jauth/locales/fr_FR 
    310269  auth.ISO-8859-1.properties 
    311   auth.ISO-8859-15.properties 
    312   auth.UTF-8.properties 
    313270  autherror.ISO-8859-1.properties 
    314   autherror.ISO-8859-15.properties 
     271  auth.UTF-8.properties 
    315272  autherror.UTF-8.properties 
    316273cd lib/jelix-modules/jauth/templates 
    317274  login.form.tpl 
    318275  index.tpl 
    319276cd lib/jelix-modules/jauth/zones 
    320277! loginform.zone.php 
     278cd lib/jelix-modules/jWSDL 
     279  module.xml 
     280cd lib/jelix-modules/jWSDL/controllers 
     281  WSDL.classic.php 
     282cd lib/jelix-modules/jWSDL/templates 
     283  soap_doc.tpl 
     284cd lib/jelix-modules/jWSDL/locales/en_EN 
     285  errors.ISO-8859-1.properties 
     286  errors.UTF-8.properties 
     287cd lib/jelix-modules/jWSDL/locales/en_US 
     288  errors.ISO-8859-1.properties 
     289  errors.UTF-8.properties 
     290cd lib/jelix-modules/jWSDL/locales/fr_FR 
     291  errors.ISO-8859-1.properties 
     292  errors.UTF-8.properties 
    321293 
    322  
    323294cd lib/jelix-plugins 
    324295  LICENCE 
    325296  INSTALL 
     
    546517! jquery.date_input.es_ES.js 
    547518cd lib/jelix-www/jquery/dimensions 
    548519c jquery.dimensions.js 
     520cd lib/jelix-www/wshelper/css 
     521  doc.css 
     522cd lib/jelix-www/wshelper/images/doc/ 
     523  back.gif 
     524  backbottom.jpg 
     525  backtop.jpg 
     526  warning.gif 
    549527 
    550528cd lib/clearbricks 
    551529  LICENCE 
     
    593571cd lib/tcpdf/config/lang 
    594572! eng.php 
    595573 
     574cd lib/wshelper 
     575  CREDITS 
     576  LICENCE 
     577  README 
     578  IPPhpDoc.class.php 
     579  IPReflectionClass.class.php 
     580  IPReflectionCommentParser.class.php 
     581  IPReflectionMethod.class.php 
     582  IPReflectionProperty.class.php 
     583  IPXMLSchema.class.php 
     584  WSDLException.class.php 
     585  WSDLStruct.class.php 
     586  WSException.class.php 
  • lib/jelix-modules/jWSDL/module.xml

    old new  
     1<?xml version="1.0" encoding="UTF-8"?> 
     2<module xmlns="http://jelix.org/ns/module/1.0"> 
     3 
     4</module> 
  • lib/jelix-modules/jWSDL/controllers/WSDL.classic.php

    old new  
     1<?php 
     2/** 
     3* @package     jelix-modules 
     4* @subpackage  jelix 
     5* @author      Sylvain de Vathaire 
     6* @copyright   2008 Sylvain de Vathaire 
     7* @licence     http://www.gnu.org/licenses/gpl.html GNU General Public Licence, see LICENCE file 
     8*/ 
     9 
     10/** 
     11 * jWSDL class 
     12 */ 
     13require(JELIX_LIB_UTILS_PATH.'jWSDL.class.php'); 
     14 
     15 
     16/** 
     17 * @package    jelix-modules 
     18 * @subpackage jelix 
     19 */ 
     20class WSDLCtrl extends jController { 
     21 
     22   /** 
     23    * Display the web service documentation for the requested service 
     24    */ 
     25    public function index() { 
     26        $rep = $this->getResponse('html', true); 
     27 
     28        $webservices = jWSDL::getSoapControllers(); 
     29 
     30        if(sizeof($webservices) != 0){ 
     31            $service = $this->param('service'); 
     32 
     33            if (empty($service)) { 
     34                $module = $webservices[0]['module']; 
     35                $controller = $webservices[0]['class']; 
     36            }else{ 
     37                if(!strpos($service, '~')===FALSE){ 
     38                    list($module, $controller) =  explode('~',$service); 
     39                } 
     40                if (empty($module) || empty($controller)) { 
     41                    throw new JException("jWSDL~errors.service.param.invalid"); 
     42                } 
     43            } 
     44 
     45            //Used for documentation of data structures classes 
     46            $className = $this->param('className'); 
     47 
     48            $wsdl = new jWSDL($module, $controller); 
     49            $doc = $wsdl->doc($className); 
     50            $doc['menu'] = $webservices; 
     51            $rep->body->assign("doc", $doc); 
     52            $rep->title = "Documentation - ".$controller; 
     53        }else{ 
     54            $rep->title = "Documentation -  Web services"; 
     55        } 
     56        $rep->addCSSLink($GLOBALS['gJConfig']->urlengine['basePath'].'jelix/wshelper/css/doc.css'); 
     57        $rep->bodyTpl = 'jWSDL~soap_doc'; 
     58        return $rep; 
     59    } 
     60 
     61    /** 
     62    * Return the WSDL file for a soap web service 
     63    */ 
     64    public function wsdl() { 
     65 
     66        $rep = $this->getResponse('xml'); 
     67        $rep->sendXMLHeader = FALSE; 
     68 
     69        $service = $this->param('service'); 
     70 
     71        if (empty($service)) { 
     72            throw new JException("jWSDL~errors.service.param.required"); 
     73        } 
     74 
     75        if(!strpos($service, '~')===FALSE){ 
     76            list($module, $controller) =  explode('~',$service); 
     77        } 
     78        if (empty($module) || empty($controller)) { 
     79            throw new JException("jWSDL~errors.service.param.invalid"); 
     80        } 
     81 
     82        $wsdl = new jWSDL($module, $controller); 
     83        $rep->content = $wsdl->getWSDLFile(); 
     84 
     85        return $rep; 
     86    } 
     87} 
     88?> 
  • lib/jelix-modules/jWSDL/controllers/WSDL.classic.php

    old new  
     1<?php 
     2/** 
     3* @package     jelix-modules 
     4* @subpackage  jelix 
     5* @author      Sylvain de Vathaire 
     6* @copyright   2008 Sylvain de Vathaire 
     7* @licence     http://www.gnu.org/licenses/gpl.html GNU General Public Licence, see LICENCE file 
     8*/ 
     9 
     10/** 
     11 * jWSDL class 
     12 */ 
     13require(JELIX_LIB_UTILS_PATH.'jWSDL.class.php'); 
     14 
     15 
     16/** 
     17 * @package    jelix-modules 
     18 * @subpackage jelix 
     19 */ 
     20class WSDLCtrl extends jController { 
     21 
     22   /** 
     23    * Display the web service documentation for the requested service 
     24    */ 
     25    public function index() { 
     26        $rep = $this->getResponse('html', true); 
     27 
     28        $webservices = jWSDL::getSoapControllers(); 
     29 
     30        if(sizeof($webservices) != 0){ 
     31            $service = $this->param('service'); 
     32 
     33            if (empty($service)) { 
     34                $module = $webservices[0]['module']; 
     35                $controller = $webservices[0]['class']; 
     36            }else{ 
     37                if(!strpos($service, '~')===FALSE){ 
     38                    list($module, $controller) =  explode('~',$service); 
     39                } 
     40                if (empty($module) || empty($controller)) { 
     41                    throw new JException("jWSDL~errors.service.param.invalid"); 
     42                } 
     43            } 
     44 
     45            //Used for documentation of data structures classes 
     46            $className = $this->param('className'); 
     47 
     48            $wsdl = new jWSDL($module, $controller); 
     49            $doc = $wsdl->doc($className); 
     50            $doc['menu'] = $webservices; 
     51            $rep->body->assign("doc", $doc); 
     52            $rep->title = "Documentation - ".$controller; 
     53        }else{ 
     54            $rep->title = "Documentation -  Web services"; 
     55        } 
     56        $rep->addCSSLink($GLOBALS['gJConfig']->urlengine['basePath'].'jelix/wshelper/css/doc.css'); 
     57        $rep->bodyTpl = 'jWSDL~soap_doc'; 
     58        return $rep; 
     59    } 
     60 
     61    /** 
     62    * Return the WSDL file for a soap web service 
     63    */ 
     64    public function wsdl() { 
     65 
     66        $rep = $this->getResponse('xml'); 
     67        $rep->sendXMLHeader = FALSE; 
     68 
     69        $service = $this->param('service'); 
     70 
     71        if (empty($service)) { 
     72            throw new JException("jWSDL~errors.service.param.required"); 
     73        } 
     74 
     75        if(!strpos($service, '~')===FALSE){ 
     76            list($module, $controller) =  explode('~',$service); 
     77        } 
     78        if (empty($module) || empty($controller)) { 
     79            throw new JException("jWSDL~errors.service.param.invalid"); 
     80        } 
     81 
     82        $wsdl = new jWSDL($module, $controller); 
     83        $rep->content = $wsdl->getWSDLFile(); 
     84 
     85        return $rep; 
     86    } 
     87} 
     88?> 
  • lib/jelix-modules/jWSDL/locales/en_EN/errors.ISO-8859-1.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Invalid service name (Syntax is $module~$controller) 
     3service.param.required=(115)Service name is required 
     4wsdl.generation=(116)Error during WSDL generation : %s 
  • lib/jelix-modules/jWSDL/locales/en_EN/errors.UTF-8.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Invalid service name (Syntax is $module~$controller) 
     3service.param.required=(115)Service name is required 
     4wsdl.generation=(116)Error during WSDL generation : %s 
  • lib/jelix-modules/jWSDL/locales/en_EN/errors.ISO-8859-1.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Invalid service name (Syntax is $module~$controller) 
     3service.param.required=(115)Service name is required 
     4wsdl.generation=(116)Error during WSDL generation : %s 
  • lib/jelix-modules/jWSDL/locales/en_EN/errors.UTF-8.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Invalid service name (Syntax is $module~$controller) 
     3service.param.required=(115)Service name is required 
     4wsdl.generation=(116)Error during WSDL generation : %s 
  • lib/jelix-modules/jWSDL/locales/en_US/errors.ISO-8859-1.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Invalid service name (Syntax is $module~$controller) 
     3service.param.required=(115)Service name is required 
     4wsdl.generation=(116)Error during WSDL generation : %s 
  • lib/jelix-modules/jWSDL/locales/en_US/errors.UTF-8.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Invalid service name (Syntax is $module~$controller) 
     3service.param.required=(115)Service name is required 
     4wsdl.generation=(116)Error during WSDL generation : %s 
  • lib/jelix-modules/jWSDL/locales/en_US/errors.ISO-8859-1.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Invalid service name (Syntax is $module~$controller) 
     3service.param.required=(115)Service name is required 
     4wsdl.generation=(116)Error during WSDL generation : %s 
  • lib/jelix-modules/jWSDL/locales/en_US/errors.UTF-8.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Invalid service name (Syntax is $module~$controller) 
     3service.param.required=(115)Service name is required 
     4wsdl.generation=(116)Error during WSDL generation : %s 
  • lib/jelix-modules/jWSDL/locales/fr_FR/errors.ISO-8859-1.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Nom de service invalide (La syntaxe est $module~$controller) 
     3service.param.required=(115)Nom de service requis 
     4wsdl.generation=(116)Erreur durant la g�ration du WSDL : %s 
  • lib/jelix-modules/jWSDL/locales/fr_FR/errors.UTF-8.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Nom de service invalide (La syntaxe est $module~$controller) 
     3service.param.required=(115)Nom de service requis 
     4wsdl.generation=(116)Erreur durant la génération du WSDL : %s 
  • lib/jelix-modules/jWSDL/locales/fr_FR/errors.ISO-8859-1.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Nom de service invalide (La syntaxe est $module~$controller) 
     3service.param.required=(115)Nom de service requis 
     4wsdl.generation=(116)Erreur durant la g�ration du WSDL : %s 
  • lib/jelix-modules/jWSDL/locales/fr_FR/errors.UTF-8.properties

    old new  
     1# jWSDL RUNTIME ERRORS 
     2service.param.invalid=(114)Nom de service invalide (La syntaxe est $module~$controller) 
     3service.param.required=(115)Nom de service requis 
     4wsdl.generation=(116)Erreur durant la génération du WSDL : %s 
  • lib/jelix-modules/jWSDL/module.xml

    old new  
     1<?xml version="1.0" encoding="UTF-8"?> 
     2<module xmlns="http://jelix.org/ns/module/1.0"> 
     3 
     4</module> 
  • lib/jelix-modules/jWSDL/templates/soap_doc.tpl

    old new  
     1<div id="main"> 
     2<div id="mainheader"> 
     3{if isset($doc)} 
     4<div id="mainheaderpadded"> 
     5        <h1>{$doc['class']->name|replace:'Ctrl':''} 
     6        {if substr($doc['class']->name, strlen($doc['class']->name) -4) == 'Ctrl'} 
     7            <a target='_blank' href="{jurl 'jWSDL~WSDL:wsdl', array("service"=>$doc['service'])}">&#160;[WSDL]</a> 
     8        {/if} 
     9        </h1> 
     10</div> 
     11</div> 
     12<div id="mainpadded"> 
     13    <table cellpadding="0" cellspacing="0"> 
     14    <tr> 
     15    <td id="menu"> 
     16        <h2>Services</h2> 
     17        {foreach $doc['menu'] as $webservice} 
     18            <a href="{jurl 'jWSDL~WSDL:index', array("service"=>$webservice['service'])}">{$webservice['class']}</a><br /> 
     19        {/foreach} 
     20    </td> 
     21    <td id="content"> 
     22            <h2>Full description</h2> 
     23            <p>{$doc['class']->fullDescription}</p> 
     24             
     25            {if(sizeof($doc['class']->properties))} 
     26                <h2>Properties</h2> 
     27                {foreach $doc['class']->properties as $propertie} 
     28                    <a name="property_{$propertie->name}"></a> 
     29                    <div class="property"> 
     30                    <b>{$propertie->name}</b><br /> 
     31                    {if  $propertie->type == ''} 
     32                        <div class='warning'><img src='{$j_basepath}/jelix/wshelper/images/doc/warning.gif'/> missing type info</div><br /> 
     33                    {else} 
     34                        {if $propertie->type =='int' || $propertie->type =='string' || $propertie->type =='boolean' || $propertie->type =='double' || $propertie->type =='float' ||$propertie->type =='void'} 
     35                            <i>type {$propertie->type}</i><br /> 
     36                        {else} 
     37                                <i>type <a href="{jurl 'jWSDL~WSDL:index', array('service'=>$doc['service'], 'className'=>str_replace('[]' , '',$propertie->type))}">{$propertie->type}</a></i><br /> 
     38                        {/if} 
     39                    {/if} 
     40                    {$propertie->fullDescription} 
     41                    </div> 
     42                {/foreach} 
     43            {/if} 
     44 
     45            {if(sizeof($doc['class']->methods))} 
     46                <h2>Methods</h2> 
     47                {foreach $doc['class']->methods as $method} 
     48                    <a name="method_{$method->name}"></a> 
     49                    <div class="method"> 
     50                    <b>{$method->name}</b> ( 
     51                        {assign $i=0} 
     52                        {foreach $method->parameters as $param} 
     53                        {$param->name}{assign $i=$i+1}{if($i!=(sizeof($method->parameters)))},{/if}{/foreach} 
     54                        ) 
     55                    <br /> 
     56                    {if  $method->return == ''} 
     57                        <div class='warning'><img src='{$j_basepath}/jelix/wshelper/images/doc/warning.gif'/> missing return value</div><br /> 
     58                    {else} 
     59                        {if $method->return =='int' || $method->return =='string' || $method->return =='boolean' || $method->return =='double' || $method->return =='float' || $method->return =='void'} 
     60                            <i>return {$method->return}</i><br /> 
     61                        {else} 
     62                                <i>return <a href="{jurl 'jWSDL~WSDL:index', array('service'=>$doc['service'], 'className'=>str_replace('[]' , '',$method->return))}">{$method->return}</a></i><br /> 
     63                        {/if} 
     64 
     65                    {/if} 
     66                    {$method->fullDescription}<br /><br /> 
     67                    </div> 
     68                {/foreach} 
     69            {/if} 
     70    </td> 
     71    </tr> 
     72    </table> 
     73{else} 
     74<div id="mainheaderpadded"> 
     75    <h2>No web servives available</h2> 
     76</div> 
     77{/if} 
     78</div> 
     79<div id="mainfooter"><img src="{$j_basepath}/jelix/wshelper/images/doc/backbottom.jpg" /></div> 
     80</div> 
  • lib/jelix-modules/jWSDL/templates/soap_doc.tpl

    old new  
     1<div id="main"> 
     2<div id="mainheader"> 
     3{if isset($doc)} 
     4<div id="mainheaderpadded"> 
     5        <h1>{$doc['class']->name|replace:'Ctrl':''} 
     6        {if substr($doc['class']->name, strlen($doc['class']->name) -4) == 'Ctrl'} 
     7            <a target='_blank' href="{jurl 'jWSDL~WSDL:wsdl', array("service"=>$doc['service'])}">&#160;[WSDL]</a> 
     8        {/if} 
     9        </h1> 
     10</div> 
     11</div> 
     12<div id="mainpadded"> 
     13    <table cellpadding="0" cellspacing="0"> 
     14    <tr> 
     15    <td id="menu"> 
     16        <h2>Services</h2> 
     17        {foreach $doc['menu'] as $webservice} 
     18            <a href="{jurl 'jWSDL~WSDL:index', array("service"=>$webservice['service'])}">{$webservice['class']}</a><br /> 
     19        {/foreach} 
     20    </td> 
     21    <td id="content"> 
     22            <h2>Full description</h2> 
     23            <p>{$doc['class']->fullDescription}</p> 
     24             
     25            {if(sizeof($doc['class']->properties))} 
     26                <h2>Properties</h2> 
     27                {foreach $doc['class']->properties as $propertie} 
     28                    <a name="property_{$propertie->name}"></a> 
     29                    <div class="property"> 
     30                    <b>{$propertie->name}</b><br /> 
     31                    {if  $propertie->type == ''} 
     32                        <div class='warning'><img src='{$j_basepath}/jelix/wshelper/images/doc/warning.gif'/> missing type info</div><br /> 
     33                    {else} 
     34                        {if $propertie->type =='int' || $propertie->type =='string' || $propertie->type =='boolean' || $propertie->type =='double' || $propertie->type =='float' ||$propertie->type =='void'} 
     35                            <i>type {$propertie->type}</i><br /> 
     36                        {else} 
     37                                <i>type <a href="{jurl 'jWSDL~WSDL:index', array('service'=>$doc['service'], 'className'=>str_replace('[]' , '',$propertie->type))}">{$propertie->type}</a></i><br /> 
     38                        {/if} 
     39                    {/if} 
     40                    {$propertie->fullDescription} 
     41                    </div> 
     42                {/foreach} 
     43            {/if} 
     44 
     45            {if(sizeof($doc['class']->methods))} 
     46                <h2>Methods</h2> 
     47                {foreach $doc['class']->methods as $method} 
     48                    <a name="method_{$method->name}"></a> 
     49                    <div class="method"> 
     50                    <b>{$method->name}</b> ( 
     51                        {assign $i=0} 
     52                        {foreach $method->parameters as $param} 
     53                        {$param->name}{assign $i=$i+1}{if($i!=(sizeof($method->parameters)))},{/if}{/foreach} 
     54                        ) 
     55                    <br /> 
     56                    {if  $method->return == ''} 
     57                        <div class='warning'><img src='{$j_basepath}/jelix/wshelper/images/doc/warning.gif'/> missing return value</div><br /> 
     58                    {else} 
     59                        {if $method->return =='int' || $method->return =='string' || $method->return =='boolean' || $method->return =='double' || $method->return =='float' || $method->return =='void'} 
     60                            <i>return {$method->return}</i><br /> 
     61                        {else} 
     62                                <i>return <a href="{jurl 'jWSDL~WSDL:index', array('service'=>$doc['service'], 'className'=>str_replace('[]' , '',$method->return))}">{$method->return}</a></i><br /> 
     63                        {/if} 
     64 
     65                    {/if} 
     66                    {$method->fullDescription}<br /><br /> 
     67                    </div> 
     68                {/foreach} 
     69            {/if} 
     70    </td> 
     71    </tr> 
     72    </table> 
     73{else} 
     74<div id="mainheaderpadded"> 
     75    <h2>No web servives available</h2> 
     76</div> 
     77{/if} 
     78</div> 
     79<div id="mainfooter"><img src="{$j_basepath}/jelix/wshelper/images/doc/backbottom.jpg" /></div> 
     80</div> 
  • lib/jelix-scripts/templates/www/soap.php.tpl

    old new  
     1<?php 
     2/** 
     3* @package       {$appname} 
     4* @subpackage    www 
     5* @author 
     6* @contributor 
     7* @copyright 
     8*/ 
     9 
     10require_once ('../../lib/jelix/init.php'); 
     11require_once ('../../testapp/application.init.php'); 
     12require_once (JELIX_LIB_CORE_PATH.'jSoapCoordinator.class.php'); 
     13require_once (JELIX_LIB_CORE_PATH.'request/jSoapRequest.class.php'); 
     14 
     15 
     16$config_file = 'index/config.ini.php'; 
     17$jelix = new JSoapCoordinator($config_file); 
     18$jelix->processSoap(new JSoapRequest()); 
     19?> 
  • lib/jelix-www/wshelper/css/doc.css

    old new  
     1body { 
     2        margin:0; 
     3        padding:0; 
     4        text-align: center; 
     5        background: #ffffff url("../images/doc/back.gif") repeat-y center; 
     6} 
     7body, table, th, td, p, div { 
     8        font-family: Arial, Helvetica; 
     9        font-size: 12pt; 
     10        line-height:1.4; 
     11} 
     12#main { 
     13        margin-right: auto; 
     14        margin-left: auto; 
     15        text-align: left; 
     16        width: 980px; 
     17} 
     18#mainpadded { 
     19        padding: 0px 40px 80px 40px; 
     20} 
     21#mainheader { 
     22        background: #ffffff url("../images/doc/backtop.jpg") no-repeat; 
     23        height: 180px; 
     24} 
     25#mainheaderpadded { 
     26        padding: 130px 40px 0px 40px; 
     27        text-align: right; 
     28} 
     29td { 
     30        vertical-align: top; 
     31} 
     32td#menu { 
     33        width: 300px; 
     34} 
     35td#content { 
     36} 
     37div.method { 
     38        padding-left: 10px; 
     39        margin-bottom: 20px; 
     40        border-left: 2px solid #C0C0C0; 
     41} 
     42div.methodwarning { 
     43        padding-left: 10px; 
     44        margin-bottom: 20px; 
     45        border-left: 4px solid #FF0000; 
     46} 
     47div.property { 
     48        padding-left: 10px; 
     49        margin-bottom: 20px; 
     50        border-left: 2px solid #C0C0C0; 
     51} 
     52div.propertywarning { 
     53        padding-left: 10px; 
     54        margin-bottom: 20px; 
     55        border-left: 4px solid #FF0000; 
     56} 
     57div.warning { 
     58        font-weight: bold; 
     59        color: #FF0000; 
     60        float: left; 
     61} 
     62a { 
     63        color: #FFA619; 
     64        text-decoration: none; 
     65        font-weight: bold; 
     66} 
     67a:hover { 
     68        text-decoration: underline; 
     69} 
     70p { 
     71        margin-top: 5px; 
     72        margin-bottom: 10px; 
     73} 
     74h1 { 
     75        margin-top: 0px; 
     76        margin-bottom: 10px; 
     77        padding: 0px; 
     78        font-family: Verdana, Helvetica; 
     79        font-size: 20pt; 
     80        color: #000000; 
     81} 
     82h2 { 
     83        margin-top: 0px; 
     84        margin-bottom: 10px; 
     85        font-family: Verdana, Helvetica; 
     86        font-size: 16pt; 
     87        color: #000000; 
     88} 
  • lib/jelix-www/wshelper/css/doc.css

    old new  
     1body { 
     2        margin:0; 
     3        padding:0; 
     4        text-align: center; 
     5        background: #ffffff url("../images/doc/back.gif") repeat-y center; 
     6} 
     7body, table, th, td, p, div { 
     8        font-family: Arial, Helvetica; 
     9        font-size: 12pt; 
     10        line-height:1.4; 
     11} 
     12#main { 
     13        margin-right: auto; 
     14        margin-left: auto; 
     15        text-align: left; 
     16        width: 980px; 
     17} 
     18#mainpadded { 
     19        padding: 0px 40px 80px 40px; 
     20} 
     21#mainheader { 
     22        background: #ffffff url("../images/doc/backtop.jpg") no-repeat; 
     23        height: 180px; 
     24} 
     25#mainheaderpadded { 
     26        padding: 130px 40px 0px 40px; 
     27        text-align: right; 
     28} 
     29td { 
     30        vertical-align: top; 
     31} 
     32td#menu { 
     33        width: 300px; 
     34} 
     35td#content { 
     36} 
     37div.method { 
     38        padding-left: 10px; 
     39        margin-bottom: 20px; 
     40        border-left: 2px solid #C0C0C0; 
     41} 
     42div.methodwarning { 
     43        padding-left: 10px; 
     44        margin-bottom: 20px; 
     45        border-left: 4px solid #FF0000; 
     46} 
     47div.property { 
     48        padding-left: 10px; 
     49        margin-bottom: 20px; 
     50        border-left: 2px solid #C0C0C0; 
     51} 
     52div.propertywarning { 
     53        padding-left: 10px; 
     54        margin-bottom: 20px; 
     55        border-left: 4px solid #FF0000; 
     56} 
     57div.warning { 
     58        font-weight: bold; 
     59        color: #FF0000; 
     60        float: left; 
     61} 
     62a { 
     63        color: #FFA619; 
     64        text-decoration: none; 
     65        font-weight: bold; 
     66} 
     67a:hover { 
     68        text-decoration: underline; 
     69} 
     70p { 
     71        margin-top: 5px; 
     72        margin-bottom: 10px; 
     73} 
     74h1 { 
     75        margin-top: 0px; 
     76        margin-bottom: 10px; 
     77        padding: 0px; 
     78        font-family: Verdana, Helvetica; 
     79        font-size: 20pt; 
     80        color: #000000; 
     81} 
     82h2 { 
     83        margin-top: 0px; 
     84        margin-bottom: 10px; 
     85        font-family: Verdana, Helvetica; 
     86        font-size: 16pt; 
     87        color: #000000; 
     88} 
  • lib/jelix/core/defaultconfig.ini.php

    old new  
    4545css= jResponseCss 
    4646ltx2pdf= jResponseLatexToPdf 
    4747tcpdf = jResponseTcpdf 
     48soap=jResponseSoap 
    4849 
    4950[_coreResponses] 
    5051html = jResponseHtml 
     
    6768css= jResponseCss 
    6869ltx2pdf= jResponseLatexToPdf 
    6970tcpdf = jResponseTcpdf 
     71soap=jResponseSoap 
    7072 
    7173[error_handling] 
    7274messageLogFormat = "%date%\t[%code%]\t%msg%\t%file%\t%line%\n" 
     
    201203 
    202204[sessions] 
    203205shared_session = off 
    204 ; You can change the session name by setting the following parameter (only accepts alpha-numeric chars) : 
    205 ; name = "mySessionName" 
    206 ; 
    207206; Use alternative storage engines for sessions 
    208207; 
    209208; usage : 
  • lib/jelix/core/jCoordinator.class.php

    old new  
    44* @subpackage   core 
    55* @author       Laurent Jouanneau 
    66* @contributor  Thibault PIRONT < nuKs > 
     7* @contributor  Sylvain de Vathaire < sylvain261 > 
    78* @copyright    2005-2008 laurent Jouanneau 
    89* @copyright    2007 Thibault PIRONT 
     10* @copyright    2008 Sylvain DE VATHAIRE 
    911* @link         http://www.jelix.org 
    1012* @licence      GNU Lesser General Public Licence see LICENCE file or http://www.gnu.org/licenses/lgpl.html 
    1113*/ 
     
    9799            set_error_handler('jErrorHandler'); 
    98100            set_exception_handler('JExceptionHandler'); 
    99101        } 
    100 #if PHP50 
    101         if(function_exists('date_default_timezone_set')){ 
    102             date_default_timezone_set($gJConfig->timeZone); 
    103         } 
    104 #else 
    105102        date_default_timezone_set($gJConfig->timeZone); 
    106 #endif 
    107103        $this->_loadPlugins(); 
    108104    } 
    109105 
     
    201197            } 
    202198        } 
    203199 
    204         $this->response = $ctrl->{$this->action->method}(); 
     200        $this->callAction($ctrl); 
    205201 
    206202        if($this->response == null){ 
    207203            throw new jException('jelix~errors.response.missing',$this->action->toString()); 
     
    225221    } 
    226222 
    227223    /** 
     224     * Call the action of the controller 
     225     * @param jController $ctrl 
     226     */ 
     227    protected function callAction($ctrl){ 
     228            $this->response = $ctrl->{$this->action->method}(); 
     229    } 
     230 
     231    /** 
    228232     * get the controller corresponding to the selector 
    229233     * @param jSelectorAct $selector 
    230234     */ 
  • lib/jelix/core/jSoapCoordinator.class.php

    old new  
     1<?php 
     2/** 
     3* @package      jelix 
     4* @subpackage   core 
     5* @author       Sylvain de Vathaire 
     6* @copyright    2008 Sylvain DE VATHAIRE 
     7* @link         http://www.jelix.org 
     8* @licence      GNU Lesser General Public Licence see LICENCE file or http://www.gnu.org/licenses/lgpl.html 
     9*/ 
     10 
     11 
     12/** 
     13 * jWSDL utility class 
     14 */ 
     15require_once(JELIX_LIB_UTILS_PATH.'jWSDL.class.php'); 
     16 
     17 
     18/** 
     19 * Specialisation of the main class of the jelix core for soap purpose 
     20 * 
     21 * @package  jelix 
     22 * @subpackage core 
     23 * @see jCoordinator 
     24 */ 
     25class jSoapCoordinator extends jCoordinator { 
     26 
     27    /** 
     28     * Soap requests arguments 
     29     * @var array 
     30     */ 
     31    var $soapArgs; 
     32 
     33    /** 
     34     * WSDL utility object 
     35     * @var jWSDL 
     36     */ 
     37    var $wsdl; 
     38 
     39    /** 
     40     * Call the action of the controller 
     41     * @param jController $ctrl 
     42     */ 
     43    protected function callAction($ctrl){ 
     44        $this->response = call_user_func_array (array($ctrl, $this->action->method),$this->soapArgs); 
     45    } 
     46 
     47    /** 
     48     * Intercept the soapServer method call in order to handle the call thrue the process method 
     49     * Return php variables, the soap server will transform it in a soap response 
     50     */ 
     51    function __call($func,$args){ 
     52        $this->soapArgs = $args; 
     53        $this->request->params['action'] = $this->request->params['action'].':'.$func; 
     54        $this->process($this->request); 
     55        return $this->response->response; 
     56    } 
     57 
     58    /** 
     59     * Intercept the soapServer method call in order to handle the call thrue the process method 
     60     * Return php variables, the soap server will transform it in a soap response 
     61     */ 
     62    public function processSoap($request){ 
     63 
     64        global $gJConfig; 
     65        $this->request = $request; 
     66 
     67        $this->soapServer = $this->getSoapServer(new jWSDL($this->request->params['module'], $this->request->params['action'])); 
     68        $this->soapServer->setObject($this); 
     69        $this->soapServer->handle($this->request->soapMsg); 
    &