Esempio n. 1
0
 public function __construct(Wsdl $wsdl, XMLDomElement $prt)
 {
     $ns = $prt->ownerDocument->documentElement->getAttribute("targetNamespace");
     parent::__construct($wsdl, $prt->getAttribute("name"), $ns);
     $operations = $prt->query("wsdl:operation");
     foreach ($operations as $operation) {
         $this->operations[$operation->getAttribute("name")] = new Operation($wsdl, $this, $operation);
     }
 }
Esempio n. 2
0
 public function __construct(Wsdl $wsdl, XMLDomElement $service)
 {
     $ns = $service->ownerDocument->documentElement->getAttribute("targetNamespace");
     parent::__construct($wsdl, $service->getAttribute("name"), $ns);
     $ports = $service->query("wsdl:port");
     foreach ($ports as $port) {
         $this->ports[$port->getAttribute("name")] = new Port($this, $port);
     }
 }
Esempio n. 3
0
 public function __construct(Wsdl $wsdl, PortType $port, XMLDomElement $operation)
 {
     parent::__construct($wsdl, $operation->getAttribute("name"), $port->getNs());
     foreach (array("input", "output") as $typeMessage) {
         $r = $operation->query("wsdl:{$typeMessage}", array("wsdl" => Wsdl::WSDL_NS));
         if ($r->length) {
             list($prefix, $name) = explode(":", $r->item(0)->getAttribute("message"));
             $ns = $operation->lookupNamespaceURI($prefix);
             $this->{$typeMessage} = $wsdl->getMessage($ns, $name);
         }
     }
     $faults = $operation->query("wsdl:fault", array("wsdl" => Wsdl::WSDL_NS));
     foreach ($faults as $fault) {
         list($prefix, $name) = explode(":", $fault->getAttribute("message"));
         $ns = $fault->lookupNamespaceURI($prefix);
         $this->faults[] = $wsdl->getMessage($ns, $name);
     }
     $this->ns = $operation->evaluate("string(ancestor::wsdl:definitions/@targetNamespace)", array("wsdl" => Wsdl::WSDL_NS));
 }
Esempio n. 4
0
 public function __construct(Wsdl $wsdl, XMLDomElement $msg)
 {
     $ns = $msg->ownerDocument->documentElement->getAttribute("targetNamespace");
     parent::__construct($wsdl, $msg->getAttribute("name"), $ns);
     $parts = $msg->query("wsdl:part", array("wsdl" => Wsdl::WSDL_NS));
     foreach ($parts as $part) {
         $this->parts[$part->getAttribute("name")] = new MessagePart($this, $part);
     }
     $this->data = $msg;
 }
Esempio n. 5
0
 public function __construct(Wsdl $wsdl, XMLDomElement $bind)
 {
     $ns = $bind->ownerDocument->documentElement->getAttribute("targetNamespace");
     parent::__construct($wsdl, $bind->getAttribute("name"), $ns);
     $this->data = $bind;
     list($prefix, $name) = explode(":", $bind->getAttribute("type"));
     $ns = $bind->lookupNamespaceURI($prefix);
     $this->portType = $wsdl->getPortType($ns, $name);
     $operations = $bind->query("wsdl:operation");
     foreach ($operations as $operation) {
         $this->operations[$operation->getAttribute("name")] = new BindingOperation($this, $operation);
     }
 }
Esempio n. 6
0
 public function __construct(Binding $binding, XMLDomElement $bind)
 {
     parent::__construct($binding->getWsdl(), $bind->getAttribute("name"), $binding->getNs());
     $this->data = $bind;
     $this->binding = $binding;
     $this->operation = $binding->getPortType()->getOperation($this->getName());
     $parts = $bind->query("wsdl:input|wsdl:output|wsdl:fault", array("wsdl" => Wsdl::WSDL_NS));
     foreach ($parts as $part) {
         switch ($part->localName) {
             case "input":
                 $this->input = new BindingMessage($this->operation->getInput(), $part);
                 break;
             case "output":
                 $this->output = new BindingMessage($this->operation->getOutput(), $part);
                 break;
         }
     }
 }