Inheritance: extends AbstractModel
Ejemplo n.º 1
0
 /**
  * @param MethodModel $method
  * @return string
  */
 protected function getMethodParameters(MethodModel $method)
 {
     $parameters = array();
     if (is_array($method->getParameterType())) {
         foreach ($method->getParameterType() as $parameterName => $parameterType) {
             $parameters[] = $this->getMethodParameter($parameterType, $parameterName);
         }
     } else {
         $parameters[] = $this->getMethodParameter($method->getParameterType());
     }
     return implode(', ', $parameters);
 }
Ejemplo n.º 2
0
 /**
  * @param MethodModel $method
  * @return string
  */
 public static function getOperationMethodReturnType(MethodModel $method, Generator $generator)
 {
     $returnType = $method->getReturnType();
     if (($struct = $generator->getStruct($returnType)) instanceof StructModel && $struct->getIsStruct() && !$struct->getIsRestriction()) {
         $returnType = $struct->getPackagedName(true);
     }
     return $returnType;
 }
Ejemplo n.º 3
0
 /**
  * @see \WsdlToPhp\PackageGenerator\Parser\Wsdl\AbstractTagInputOutputParser::setKnownType()
  * @return TagInput
  */
 protected function setKnownType(Method $method, $knownType)
 {
     $method->setParameterType($knownType);
     return $this;
 }
Ejemplo n.º 4
0
 /**
  * @param MethodModel $method
  * @return string
  */
 public static function getOperationMethodReturnType(MethodModel $method, Generator $generator)
 {
     $returnType = $method->getReturnType();
     if (($struct = $generator->getStruct($returnType)) instanceof StructModel && !$struct->getIsRestriction()) {
         if ($struct->getIsStruct()) {
             $returnType = $struct->getPackagedName(true);
         } elseif ($struct->isArray()) {
             if (($structInheritance = $struct->getInheritanceStruct()) instanceof StructModel) {
                 $returnType = sprintf('%s[]', $structInheritance->getPackagedName(true));
             } else {
                 $returnType = $struct->getInheritance();
             }
         }
     }
     return $returnType;
 }
Ejemplo n.º 5
0
 /**
  * @param Method $method
  * @param string $soapHeaderName
  * @return bool
  */
 protected function isSoapHeaderAlreadyDefined(Method $method, $soapHeaderName)
 {
     $methodSoapHeaders = $method->getMetaValue(self::META_SOAP_HEADER_NAMES, array());
     return in_array($soapHeaderName, $methodSoapHeaders, true);
 }