Interface for common queue operations
category | Zend |
---|---|
package | Zend_Queue |
subpackage | Adapter |
copyright | Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com) |
license | New BSD License |
__construct(array|\Zend_Config $options, \Zend_Queue $queue = null
) : void
array
\Zend_Config
\Zend_Queue
count(\Zend_Queue|null $queue = null
) : integer
\Zend_Queue
null
integer
create(string $name, integer $timeout = null
) : boolean
Visibility timeout is how long a message is left in the queue "invisible" to other readers. If the message is acknowleged (deleted) before the timeout, then the message is deleted. However, if the timeout expires then the message will be made available to other queue readers.
string
Queue name
integer
Default visibility timeout
boolean
delete(string $name) : boolean
Return false if the queue is not found, true if the queue exists.
string
Queue name
boolean
deleteMessage(\Zend_Queue_Message $message) : boolean
Return true if the message is deleted, false if the deletion is unsuccessful.
\Zend_Queue_Message
boolean
getCapabilities() : array
$array['function name'] = true or false true is supported, false is not supported.
array
getOptions() : array
array
getQueue() : \Zend_Queue
\Zend_Queue
getQueues() : array
Not all adapters support getQueues(); use isSupported('getQueues') to determine if the adapter supports this feature.
array
isExists(string $name) : boolean
Use isSupported('isExists') to determine if an adapter can test for queue existance.
string
Queue name
boolean
isSupported(string $name) : boolean
string
Function name
boolean
receive(integer|null $maxMessages= null
, integer|null $timeout= null
, \Zend_Queue|null $queue= null
) : \Zend_Queue_Message_Iterator
integer
null
Maximum number of messages to return
integer
null
Visibility timeout for these messages
\Zend_Queue
null
\Zend_Queue_Message_Iterator
send(mixed $message, \Zend_Queue|null $queue = null
) : \Zend_Queue_Message
mixed
Message to send to the active queue
\Zend_Queue
null
\Zend_Queue_Message
setQueue(\Zend_Queue $queue) : \Zend_Queue_Adapter_AdapterInterface
\Zend_Queue
\Zend_Queue_Adapter_AdapterInterface