|
Moodle
2.2.1
http://www.collinsharper.com
|
00001 <?php 00032 class Zend_Amf_Value_Messaging_AbstractMessage 00033 { 00037 public $clientId; 00038 00042 public $destination; 00043 00047 public $messageId; 00048 00052 public $timestamp; 00053 00057 public $timeToLive; 00058 00062 public $headers; 00063 00067 public $body; 00068 00078 public function generateId() 00079 { 00080 return sprintf( 00081 '%08X-%04X-%04X-%02X%02X-%012X', 00082 mt_rand(), 00083 mt_rand(0, 65535), 00084 bindec(substr_replace( 00085 sprintf('%016b', mt_rand(0, 65535)), '0100', 11, 4) 00086 ), 00087 bindec(substr_replace(sprintf('%08b', mt_rand(0, 255)), '01', 5, 2)), 00088 mt_rand(0, 255), 00089 mt_rand() 00090 ); 00091 } 00092 }