PHP 클래스 PAMI\Message\Message

파일 보기 프로젝트 열기: marcelog/pami

보호된 프로퍼티들

프로퍼티 타입 설명
$createdDate integer Created date (unix timestamp).
$keys string[] Metadata. Message "keys" i.e: Action: login
$lines string[] Message content, line by line. This is what it gets sent or received literally.
$variables string[] Metadata. Message variables (key/value).

공개 메소드들

메소드 설명
__construct ( ) : void Constructor.
__sleep ( ) : string[] Serialize function.
getActionID ( ) : string Returns key: 'ActionID'.
getCreatedDate ( ) : integer Returns created date.
getKey ( string $key ) : string Returns a key by name.
getKeys ( ) : string[] Returns all keys for this message.
getVariable ( string $key ) : string Returns a variable by name.
getVariables ( ) : string[] Returns all variabels for this message.
serialize ( ) : string Gives a string representation for this message, ready to be sent to ami.
setVariable ( string $key, string $value ) : void Adds a variable to this message.

보호된 메소드들

메소드 설명
finishMessage ( $message ) : string Returns the end of message token appended to the end of a given message.
setKey ( string $key, string $value ) : void Adds a variable to this message.

비공개 메소드들

메소드 설명
serializeVariable ( string $key, string $value ) : string Returns the string representation for an ami action variable.

메소드 상세

__construct() 공개 메소드

Constructor.
public __construct ( ) : void
리턴 void

__sleep() 공개 메소드

Serialize function.
public __sleep ( ) : string[]
리턴 string[]

finishMessage() 보호된 메소드

Returns the end of message token appended to the end of a given message.
protected finishMessage ( $message ) : string
리턴 string

getActionID() 공개 메소드

Returns key: 'ActionID'.
public getActionID ( ) : string
리턴 string

getCreatedDate() 공개 메소드

Returns created date.
public getCreatedDate ( ) : integer
리턴 integer

getKey() 공개 메소드

Returns a key by name.
public getKey ( string $key ) : string
$key string Key name (i.e: Action).
리턴 string

getKeys() 공개 메소드

Returns all keys for this message.
public getKeys ( ) : string[]
리턴 string[]

getVariable() 공개 메소드

Returns a variable by name.
public getVariable ( string $key ) : string
$key string Variable name.
리턴 string

getVariables() 공개 메소드

Returns all variabels for this message.
public getVariables ( ) : string[]
리턴 string[]

serialize() 공개 메소드

Gives a string representation for this message, ready to be sent to ami.
public serialize ( ) : string
리턴 string

setKey() 보호된 메소드

Adds a variable to this message.
protected setKey ( string $key, string $value ) : void
$key string Key name (i.e: Action).
$value string Key value.
리턴 void

setVariable() 공개 메소드

Adds a variable to this message.
public setVariable ( string $key, string $value ) : void
$key string Variable name.
$value string Variable value.
리턴 void

프로퍼티 상세

$createdDate 보호되어 있는 프로퍼티

Created date (unix timestamp).
protected int $createdDate
리턴 integer

$keys 보호되어 있는 프로퍼티

Metadata. Message "keys" i.e: Action: login
protected string[] $keys
리턴 string[]

$lines 보호되어 있는 프로퍼티

Message content, line by line. This is what it gets sent or received literally.
protected string[] $lines
리턴 string[]

$variables 보호되어 있는 프로퍼티

Metadata. Message variables (key/value).
protected string[] $variables
리턴 string[]