forked from dmtrs/yii-aws-sqs
-
Notifications
You must be signed in to change notification settings - Fork 3
/
AWSMessage.php
52 lines (44 loc) · 977 Bytes
/
AWSMessage.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
<?php
class AWSMessage extends CModel
{
const AWS_VISIBILITY_TIMEOUT = 'VisibilityTimeout';
const AWS_SENT_TIMESTAMP = 'SentTimestamp';
const AWS_SENDER_ID = 'SenderId';
/**
* @var mixed body of the message
*/
public $body;
/**
* @var string id of the message
*/
public $id;
/**
* @var string receiptHandle
*/
public $receiptHandle;
/**
* @var string md5 of the message body
*/
public $md5;
/**
* @var int Timestamp when the message was created
*/
public $sentTimestamp;
/**
* @var string The id of the sender
*/
public $senderId;
public function attributeNames()
{
return array('body','id','receiptHandle','md5','sentTimestamp','senderId');
}
/**
* Magic method to cast object to string
*
* @return string the message's body
*/
public function __toString()
{
return $this->body;
}
}