File indexing completed on 2024-12-29 05:27:26

0001 <?php
0002 /**
0003  * Zend Framework
0004  *
0005  * LICENSE
0006  *
0007  * This source file is subject to the new BSD license that is bundled
0008  * with this package in the file LICENSE.txt.
0009  * It is also available through the world-wide-web at this URL:
0010  * http://framework.zend.com/license/new-bsd
0011  * If you did not receive a copy of the license and are unable to
0012  * obtain it through the world-wide-web, please send an email
0013  * to license@zend.com so we can send you a copy immediately.
0014  *
0015  * @category   Zend
0016  * @package    Zend_Amf
0017  * @subpackage Value
0018  * @copyright  Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
0019  * @license    http://framework.zend.com/license/new-bsd     New BSD License
0020  * @version    $Id$
0021  */
0022 
0023 /** Zend_Amf_Value_Messaging_AsyncMessage */
0024 // require_once 'Zend/Amf/Value/Messaging/AsyncMessage.php';
0025 
0026 /**
0027  * This is the type of message returned by the MessageBroker
0028  * to endpoints after the broker has routed an endpoint's message
0029  * to a service.
0030  *
0031  * flex.messaging.messages.AcknowledgeMessage
0032  *
0033  * @package    Zend_Amf
0034  * @subpackage Value
0035  * @copyright  Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
0036  * @license    http://framework.zend.com/license/new-bsd     New BSD License
0037  */
0038 class Zend_Amf_Value_Messaging_AcknowledgeMessage extends Zend_Amf_Value_Messaging_AsyncMessage
0039 {
0040     /**
0041      * Create a new Acknowledge Message
0042      *
0043      * @param unknown_type $message
0044      */
0045     public function __construct($message)
0046     {
0047         $this->clientId    = $this->generateId();
0048         $this->destination = null;
0049         $this->messageId   = $this->generateId();
0050         $this->timestamp   = time().'00';
0051         $this->timeToLive  = 0;
0052         $this->headers     = new STDClass();
0053         $this->body        = null;
0054 
0055         // correleate the two messages
0056         if ($message && isset($message->messageId)) {
0057             $this->correlationId = $message->messageId;
0058         }
0059     }
0060 }