src/Guzzle/Service/Command/LocationVisitor/Request/XmlVisitor.php
protected function addXmlObject(\XMLWriter $xmlWriter, Parameter $param, &$value)
    {
        $noAttributes = array();
        // add values which have attributes
        foreach ($value as $name => $v) {
            if ($property = $param->getProperty($name)) {
                if ($property->getData('xmlAttribute')) {
                    $this->addXml($xmlWriter, $property, $v);
                } else {
                    $noAttributes[] = array('value' => $v, 'property' => $property);
                }
            }
        }
        // now add values with no attributes
        foreach ($noAttributes as $element) {
            $this->addXml($xmlWriter, $element['property'], $element['value']);
        }
    }
protected function addXmlObject(\XMLWriter $xmlWriter, Parameter $param, &$value)
    {
        $noAttributes = array();
        // add values which have attributes
        foreach ($value as $name => $v) {
            if ($property = $param->getProperty($name)) {
                if ($property->getData('xmlAttribute')) {
                    $this->addXml($xmlWriter, $property, $v);
                } else {
                    $noAttributes[] = array('value' => $v, 'property' => $property);
                }
            }
        }
        // now add values with no attributes
        foreach ($noAttributes as $element) {
            $this->addXml($xmlWriter, $element['property'], $element['value']);
        }
    }
protected function addXmlObject ( \ XMLWriter $ xmlWriter , Parameter $ param , & $ value ) { $ noAttributes = array ( ) ; // add values which have attributes foreach ( $ value as $ name => $ v ) { if ( $ property = $ param -> getProperty ( $ name ) ) { if ( $ property -> getData ( 'xmlAttribute' ) ) { $ this -> addXml ( $ xmlWriter , $ property , $ v ) ; } else { $ noAttributes [ ] = array ( 'value' => $ v , 'property' => $ property ) ; } } } // now add values with no attributes foreach ( $ noAttributes as $ element ) { $ this -> addXml ( $ xmlWriter , $ element [ 'property' ] , $ element [ 'value' ] ) ; } }
Add an object to the XML
Add an object to the XML