class Message (View source)

Properties

string $topic
string $payload
int $mid
int $qos
bool $retain

Methods

static bool
topicMatchesSub(string $topic, string $subscription)

Returns true if the supplied topic matches the supplied description, and otherwise false.

static array
tokeniseTopic(string $topic)

Tokenise a topic or subscription string into an array of strings representing the topic hierarchy.

Details

static bool topicMatchesSub(string $topic, string $subscription)

Returns true if the supplied topic matches the supplied description, and otherwise false.

Parameters

string $topic

The topic to match

string $subscription

The subscription to match

Return Value

bool

static array tokeniseTopic(string $topic)

Tokenise a topic or subscription string into an array of strings representing the topic hierarchy.

Parameters

string $topic

Return Value

array