Represents an event that occurs on the event bus bridge.
Please consult the documentation for a full explanation.
package |
Default |
---|
__construct()
complete( $arg0 = null) : void
complete()
Set the result. Any handler will be called, if there is one, and the promise will be marked as completed.
Any handler set on the associated promise will be called.
param $result [boolean] the result complete($result)
boolean
fail( $arg0) : void
param $cause [\Exception] the failure cause fail($cause)
Calls @see \io\vertx\jphp\core\Promise::fail with the message
.
param $message [string] the failure message fail($message)
string | \Exception
future() : \io\vertx\jphp\ext\web\handler\sockjs\Future<Boolean>
\io\vertx\jphp\ext\web\handler\sockjs\Future
the {@link Future} associated with this promise, it can be used to be aware of the promise completion
getRawMessage() : array
array
the raw JSON message for the event
setRawMessage( $arg0) : $this
array
$this
this reference, so it can be used fluently
socket() : \io\vertx\jphp\ext\web\handler\sockjs\SockJSSocket
tryComplete( $arg0 = null) : boolean
tryComplete()
Like @see \io\vertx\jphp\core\Promise::complete but returns false
when the promise is already completed instead of throwing
an \java.lang.IllegalStateException, it returns true
otherwise.
param $result [boolean] the result tryComplete($result)
boolean
boolean
{@code false} when the future is already completed
tryFail( $arg0) : boolean
param $cause [\Exception] the failure cause tryFail($cause)
Calls @see \io\vertx\jphp\core\Promise::fail with the message
.
param $message [string] the failure message tryFail($message)
string | \Exception
boolean
{@code false} when the future is already completed
type() : string
string
the type of the event