src/PAMI/Message/Message.php
public function serialize()
    {
        $result = array();
        foreach ($this->getKeys() as $k => $v) {
            $result[] = $k . ': ' . $v;
        }
        foreach ($this->getVariables() as $k => $v) {
            if (is_array($v)) {
                foreach ($v as $singleValue) {
                    $result[] = $this->serializeVariable($k, $singleValue);
                }
            } else {
                $result[] = $this->serializeVariable($k, $v);
            }
        }
        $mStr = $this->finishMessage(implode(self::EOL, $result));
        return $mStr;
    }
public function serialize()
    {
        $result = array();
        foreach ($this->getKeys() as $k => $v) {
            $result[] = $k . ': ' . $v;
        }
        foreach ($this->getVariables() as $k => $v) {
            if (is_array($v)) {
                foreach ($v as $singleValue) {
                    $result[] = $this->serializeVariable($k, $singleValue);
                }
            } else {
                $result[] = $this->serializeVariable($k, $v);
            }
        }
        $mStr = $this->finishMessage(implode(self::EOL, $result));
        return $mStr;
    }
public function serialize ( ) { $ result = array ( ) ; foreach ( $ this -> getKeys ( ) as $ k => $ v ) { $ result [ ] = $ k . ': ' . $ v ; } foreach ( $ this -> getVariables ( ) as $ k => $ v ) { if ( is_array ( $ v ) ) { foreach ( $ v as $ singleValue ) { $ result [ ] = $ this -> serializeVariable ( $ k , $ singleValue ) ; } } else { $ result [ ] = $ this -> serializeVariable ( $ k , $ v ) ; } } $ mStr = $ this -> finishMessage ( implode ( self :: EOL , $ result ) ) ; return $ mStr ; }
Gives a string representation for this message, ready to be sent to
ami.

@return string
Gives a string representation for this message ready to be sent to ami .