public function addMethod(WebServiceMethod $method) { if (array_key_exists($method->getName(), $this->methods)) { if (in_array($method, $this->methods)) { return false; } $method->setName($method->getName() . "_" . str_replace(" ", "_", microtime(false))); } $this->methods[$method->getName()] = $method; }
private function parseMessageInput($messageName, WebServiceMethod &$method) { /*DomElement*/ $messageNode = null; for ($i = 0; $i < $this->definitions->length; $i++) { /*DOMElement*/ $item = XmlUtil::getDOMElement($this->definitions->item($i)); if (XmlUtil::cleearNS($item->nodeName) == "message" && XmlUtil::cleearNS($item->getAttribute("name")) == $messageName) { $messageNode = $item; break; } } $partNodes = $messageNode->getElementsByTagName("part"); for ($i = 0; $i < $partNodes->length; $i++) { /*DOMElement*/ $item = XmlUtil::getDOMElement($partNodes->item($i)); $webServiceType = new WebServiceType(); $webServiceType->setName(XmlUtil::cleearNS($item->getAttribute("name"))); $webServiceType->setType($this->parseType(XmlUtil::cleearNS($item->getAttribute("element")))); $method->addArgument($webServiceType); } }