src/XQueue/Maileon/API/ContactEvents/ContactEventType.php
function fromXML($xmlElement)
    {
        if (isset($xmlElement->id)) $this->id = $xmlElement->id;
        if (isset($xmlElement->name)) $this->name = $xmlElement->name;
        if (isset($xmlElement->active)) $this->active = $xmlElement->active;
        if (isset($xmlElement->anonymizable)) $this->anonymizable = $xmlElement->anonymizable;
        if (isset($xmlElement->description)) $this->description = $xmlElement->description;
        if (isset($xmlElement->created)) $this->created = $xmlElement->created;
        if (isset($xmlElement->updated)) $this->updated = $xmlElement->updated;

        if (isset($xmlElement->attributes)) {
            $this->attributes = array();
            foreach ($xmlElement->attributes->children() as $xmlAttribute) {
                $attribute = array();
                if (isset($xmlAttribute->name)) $attribute['name'] = trim($xmlAttribute->name);
                if (isset($xmlAttribute->datatype)) $attribute['datatype'] = DataType::getDataType($xmlAttribute->datatype);
                if (isset($xmlAttribute->description)) $attribute['description'] = trim($xmlAttribute->description);
                if (isset($xmlAttribute->required)) $attribute['required'] = $xmlAttribute->required;
                array_push($this->attributes, $attribute);
            }
        }
    }
function fromXML($xmlElement)
    {
        if (isset($xmlElement->id)) $this->id = $xmlElement->id;
        if (isset($xmlElement->name)) $this->name = $xmlElement->name;
        if (isset($xmlElement->active)) $this->active = $xmlElement->active;
        if (isset($xmlElement->anonymizable)) $this->anonymizable = $xmlElement->anonymizable;
        if (isset($xmlElement->description)) $this->description = $xmlElement->description;
        if (isset($xmlElement->created)) $this->created = $xmlElement->created;
        if (isset($xmlElement->updated)) $this->updated = $xmlElement->updated;

        if (isset($xmlElement->attributes)) {
            $this->attributes = array();
            foreach ($xmlElement->attributes->children() as $xmlAttribute) {
                $attribute = array();
                if (isset($xmlAttribute->name)) $attribute['name'] = trim($xmlAttribute->name);
                if (isset($xmlAttribute->datatype)) $attribute['datatype'] = DataType::getDataType($xmlAttribute->datatype);
                if (isset($xmlAttribute->description)) $attribute['description'] = trim($xmlAttribute->description);
                if (isset($xmlAttribute->required)) $attribute['required'] = $xmlAttribute->required;
                array_push($this->attributes, $attribute);
            }
        }
    }
function fromXML ( $ xmlElement ) { if ( isset ( $ xmlElement -> id ) ) $ this -> id = $ xmlElement -> id ; if ( isset ( $ xmlElement -> name ) ) $ this -> name = $ xmlElement -> name ; if ( isset ( $ xmlElement -> active ) ) $ this -> active = $ xmlElement -> active ; if ( isset ( $ xmlElement -> anonymizable ) ) $ this -> anonymizable = $ xmlElement -> anonymizable ; if ( isset ( $ xmlElement -> description ) ) $ this -> description = $ xmlElement -> description ; if ( isset ( $ xmlElement -> created ) ) $ this -> created = $ xmlElement -> created ; if ( isset ( $ xmlElement -> updated ) ) $ this -> updated = $ xmlElement -> updated ; if ( isset ( $ xmlElement -> attributes ) ) { $ this -> attributes = array ( ) ; foreach ( $ xmlElement -> attributes -> children ( ) as $ xmlAttribute ) { $ attribute = array ( ) ; if ( isset ( $ xmlAttribute -> name ) ) $ attribute [ 'name' ] = trim ( $ xmlAttribute -> name ) ; if ( isset ( $ xmlAttribute -> datatype ) ) $ attribute [ 'datatype' ] = DataType :: getDataType ( $ xmlAttribute -> datatype ) ; if ( isset ( $ xmlAttribute -> description ) ) $ attribute [ 'description' ] = trim ( $ xmlAttribute -> description ) ; if ( isset ( $ xmlAttribute -> required ) ) $ attribute [ 'required' ] = $ xmlAttribute -> required ; array_push ( $ this -> attributes , $ attribute ) ; } } }
Initializes this contact event type from an XML representation.

@param SimpleXMLElement $xmlElement
the serialized XML representation to use
Initializes this contact event type from an XML representation .