PAMI\Client\IClient
Interface for an ami client.
PHP Version 5
- Author: Marcelo Gornstein <marcelog@gmail.com>
- License: http://marcelog.github.com/PAMI/ Apache License 2.0
Synopsis
interface IClient
{
- // methods
- public void open()
- public void process()
- public string registerEventListener()
- public void unregisterEventListener()
- public void close()
- public Response send()
- public void setLogger()
Methods
public
- close() — Closes the connection to ami.
- open() — Opens a tcp connection to ami.
- process() — Main processing loop. Also called from send(), you should call this in your own application in order to continue reading events and responses from ami.
- registerEventListener() — Registers the given listener so it can receive events. Returns the generated id for this new listener. You can pass in a an IEventListener, a Closure, and an array containing the object and name of the method to invoke. Can specify an optional predicate to invoke before calling the callback.
- send() — Sends a message to ami.
- setLogger() — Sets the logger implementation.
- unregisterEventListener() — Unregisters an event listener.