title: Zend Framework Classmap not respected by autodiscovery?
body: <p>I create a complete pluggin in Wordpress using ZendFramework and now i'd like to expose a webservice to access the data because i need to create a c# importation application.</p>
  
  <p>The problem i'm facing is that even though i set the type of a webservice return to a specific type, the classmap is not kicking in and transforming the type. For example:</p>
  
  <pre><code>/**
   * Retursn all events registered on the sgm web interface
   * 
   * @return models_event[]
   */
  public function getAllEvents(){
      return models_event::getEvents();
  }
  </code></pre>
  
  <p>defines that the class returned in a models_event array. If i launch the WSDL section, i get a complex type added as "models_event" but heres what's wrong:</p>
  
  <pre><code>    $autodiscover = new Zend_Soap_AutoDiscover(array(
          'classmap' =&gt; array(
              'event' =&gt; "models_event",
          ),
          'encoding' =&gt; 'utf-8'
      ));
      $autodiscover-&gt;setComplexTypeStrategy(new Zend_Soap_Wsdl_Strategy_ArrayOfTypeComplex());
      $autodiscover-&gt;setClass('models_webservice');
      $autodiscover-&gt;handle();
  </code></pre>
  
  <p>I class mapped models_event to event. So my WSDL should export the complex type:</p>
  
  <pre><code>&lt;xsd:complexType name="ArrayOfmodels_event"&gt;
      &lt;xsd:complexContent&gt;
          &lt;xsd:restriction base="soap-enc:Array"&gt;
              &lt;xsd:attribute ref="soap-enc:arrayType" wsdl:arrayType="tns:models_event[]"/&gt;
          &lt;/xsd:restriction&gt;
      &lt;/xsd:complexContent&gt;
  &lt;/xsd:complexType&gt;
  &lt;xsd:complexType name="models_event"&gt;
      &lt;xsd:all/&gt;
  &lt;/xsd:complexType&gt;
  </code></pre>
  
  <p>But as you can see it is returning a models_event[] complexe type and models_event complex type... i'm all messed up... Why is it doing this?</p>