public function toXMLString() { $str = ''; $str .= parent::toXMLString(); if ($this->AuthorizationID != null) { $str .= '<urn:AuthorizationID>' . PPUtils::escapeInvalidXmlCharsRegex($this->AuthorizationID) . '</urn:AuthorizationID>'; } if ($this->Amount != null) { $str .= '<urn:Amount'; $str .= $this->Amount->toXMLString(); $str .= '</urn:Amount>'; } if ($this->CompleteType != null) { $str .= '<urn:CompleteType>' . PPUtils::escapeInvalidXmlCharsRegex($this->CompleteType) . '</urn:CompleteType>'; } if ($this->Note != null) { $str .= '<urn:Note>' . PPUtils::escapeInvalidXmlCharsRegex($this->Note) . '</urn:Note>'; } if ($this->InvoiceID != null) { $str .= '<urn:InvoiceID>' . PPUtils::escapeInvalidXmlCharsRegex($this->InvoiceID) . '</urn:InvoiceID>'; } if ($this->EnhancedData != null) { $str .= '<ebl:EnhancedData>'; $str .= $this->EnhancedData->toXMLString(); $str .= '</ebl:EnhancedData>'; } if ($this->Descriptor != null) { $str .= '<urn:Descriptor>' . PPUtils::escapeInvalidXmlCharsRegex($this->Descriptor) . '</urn:Descriptor>'; } if ($this->MerchantStoreDetails != null) { $str .= '<ebl:MerchantStoreDetails>'; $str .= $this->MerchantStoreDetails->toXMLString(); $str .= '</ebl:MerchantStoreDetails>'; } if ($this->MsgSubID != null) { $str .= '<urn:MsgSubID>' . PPUtils::escapeInvalidXmlCharsRegex($this->MsgSubID) . '</urn:MsgSubID>'; } return $str; }
public function toXMLString() { $str = ''; $str .= parent::toXMLString(); if ($this->AuthorizationID != null) { //prop is not a collection //prop not complex //prop is not value $str .= '<urn:AuthorizationID>' . $this->AuthorizationID . '</urn:AuthorizationID>'; } if ($this->Amount != null) { //prop is not a collection //prop is complex //prop is not enum //prop containsattribute $str .= '<urn:Amount'; $str .= $this->Amount->toXMLString(); $str .= '</urn:Amount>'; } if ($this->CompleteType != null) { //prop is not a collection //prop not complex //prop is not value $str .= '<urn:CompleteType>' . $this->CompleteType . '</urn:CompleteType>'; } if ($this->Note != null) { //prop is not a collection //prop not complex //prop is not value $str .= '<urn:Note>' . $this->Note . '</urn:Note>'; } if ($this->InvoiceID != null) { //prop is not a collection //prop not complex //prop is not value $str .= '<urn:InvoiceID>' . $this->InvoiceID . '</urn:InvoiceID>'; } if ($this->EnhancedData != null) { //prop is not a collection //prop is complex //prop is not enum //does not contain attribute or is attribute $str .= '<ebl:EnhancedData>'; $str .= $this->EnhancedData->toXMLString(); $str .= '</ebl:EnhancedData>'; } if ($this->Descriptor != null) { //prop is not a collection //prop not complex //prop is not value $str .= '<urn:Descriptor>' . $this->Descriptor . '</urn:Descriptor>'; } if ($this->MerchantStoreDetails != null) { //prop is not a collection //prop is complex //prop is not enum //does not contain attribute or is attribute $str .= '<ebl:MerchantStoreDetails>'; $str .= $this->MerchantStoreDetails->toXMLString(); $str .= '</ebl:MerchantStoreDetails>'; } if ($this->MsgSubID != null) { //prop is not a collection //prop not complex //prop is not value $str .= '<urn:MsgSubID>' . $this->MsgSubID . '</urn:MsgSubID>'; } return $str; }