Example:
$messages = $subscription->pull();
foreach ($messages as $message) {
echo $message->data();
}
public pull ( array $options = [] ) : Generator |
||
$options | array | [optional] { Configuration Options @type bool $returnImmediately If set, the system will respond immediately, even if no messages are available. Otherwise, wait until new messages are available. @type int $maxMessages Limit the amount of messages pulled. } |
return | Generator |