/** * Get the raw JSON message for the event. This will be null for SOCKET_CREATED or SOCKET_CLOSED events as there is * no message involved. If the returned message is modified, {@link io.vertx.rxjava.ext.bridge.BaseBridgeEvent#setRawMessage} should be called with the * new message. * @return the raw JSON message for the event */ public JsonObject getRawMessage() { JsonObject ret = delegate.getRawMessage(); return ret; }
/** * Get the raw JSON message for the event. This will be null for SOCKET_CREATED or SOCKET_CLOSED events as there is * no message involved. * @param message the raw message * @return this reference, so it can be used fluently */ public io.vertx.rxjava.ext.bridge.BaseBridgeEvent setRawMessage(JsonObject message) { delegate.setRawMessage(message); return this; }
/** * Set the result. Any handler will be called, if there is one, and the future will be marked as completed. * @param result the result */ public void complete(Boolean result) { delegate.complete(result); }
public static <U>io.vertx.core.Future<java.lang.Object> map(io.vertx.ext.bridge.BaseBridgeEvent j_receiver, java.util.function.Function<java.lang.Boolean, java.lang.Object> mapper) { return io.vertx.core.impl.ConversionHelper.fromObject(j_receiver.map(mapper != null ? new java.util.function.Function<java.lang.Boolean, java.lang.Object>() { public java.lang.Object apply(java.lang.Boolean t) { java.lang.Boolean o = t; java.lang.Object p = mapper.apply(o); return io.vertx.core.impl.ConversionHelper.toObject(p); } } : null)); } public static java.util.Map<String, Object> getRawMessage(io.vertx.ext.bridge.BaseBridgeEvent j_receiver) {
/** * Map the failure of a future to a specific <code>value</code>.<p> * * When this future fails, this <code>value</code> will complete the future returned by this method call.<p> * * When this future succeeds, the result will be propagated to the returned future. * @param value the value that eventually completes the mapped future * @return the mapped future */ public io.vertx.rxjava.core.Future<Boolean> otherwise(Boolean value) { io.vertx.rxjava.core.Future<Boolean> ret = io.vertx.rxjava.core.Future.newInstance(delegate.otherwise(value), io.vertx.lang.rx.TypeArg.unknown()); return ret; }
/** * Compose this future with a provided <code>next</code> future.<p> * * When this (the one on which <code>compose</code> is called) future succeeds, the <code>handler</code> will be called with * the completed value, this handler should complete the next future.<p> * * If the <code>handler</code> throws an exception, the returned future will be failed with this exception.<p> * * When this future fails, the failure will be propagated to the <code>next</code> future and the <code>handler</code> * will not be called. * @param handler the handler * @param next the next future * @return the next future, used for chaining */ public <U> io.vertx.rxjava.core.Future<U> compose(Handler<Boolean> handler, io.vertx.rxjava.core.Future<U> next) { io.vertx.rxjava.core.Future<U> ret = io.vertx.rxjava.core.Future.newInstance(delegate.compose(handler, next.getDelegate()), next.__typeArg_0); return ret; }
/** * @return an handler completing this future */ public Handler<AsyncResult<Boolean>> completer() { if (cached_0 != null) { return cached_0; } Handler<AsyncResult<Boolean>> ret = delegate.completer(); cached_0 = ret; return ret; }
/** * Map the failure of a future to <code>null</code>.<p> * * This is a convenience for <code>future.otherwise((T) null)</code>.<p> * * When this future fails, the <code>null</code> value will complete the future returned by this method call.<p> * * When this future succeeds, the result will be propagated to the returned future. * @return the mapped future */ public io.vertx.rxjava.core.Future<Boolean> otherwiseEmpty() { io.vertx.rxjava.core.Future<Boolean> ret = io.vertx.rxjava.core.Future.newInstance(delegate.otherwiseEmpty(), io.vertx.lang.rx.TypeArg.unknown()); return ret; }
/** * Handles a failure of this Future by returning the result of another Future. * If the mapper fails, then the returned future will be failed with this failure. * @param mapper A function which takes the exception of a failure and returns a new future. * @return A recovered future */ public io.vertx.rxjava.core.Future<Boolean> recover(Function<Throwable, io.vertx.rxjava.core.Future<Boolean>> mapper) { io.vertx.rxjava.core.Future<Boolean> ret = io.vertx.rxjava.core.Future.newInstance(delegate.recover(new java.util.function.Function<java.lang.Throwable,io.vertx.core.Future<java.lang.Boolean>>() { public io.vertx.core.Future<java.lang.Boolean> apply(java.lang.Throwable arg) { io.vertx.rxjava.core.Future<Boolean> ret = mapper.apply(arg); return ret.getDelegate(); } }), io.vertx.lang.rx.TypeArg.unknown()); return ret; }
/** * @return the handler for the result */ public Handler<AsyncResult<Boolean>> getHandler() { Handler<AsyncResult<Boolean>> ret = delegate.getHandler(); return ret; }
/** * Apply a <code>mapper</code> function on this future.<p> * * When this future succeeds, the <code>mapper</code> will be called with the completed value and this mapper * returns a value. This value will complete the future returned by this method call.<p> * * If the <code>mapper</code> throws an exception, the returned future will be failed with this exception.<p> * * When this future fails, the failure will be propagated to the returned future and the <code>mapper</code> * will not be called. * @param mapper the mapper function * @return the mapped future */ public <U> io.vertx.rxjava.core.Future<U> map(Function<Boolean, U> mapper) { io.vertx.rxjava.core.Future<U> ret = io.vertx.rxjava.core.Future.newInstance(delegate.map(mapper), io.vertx.lang.rx.TypeArg.unknown()); return ret; }
/** * Map the failure of a future to a specific <code>value</code>.<p> * * When this future fails, this <code>value</code> will complete the future returned by this method call.<p> * * When this future succeeds, the result will be propagated to the returned future. * @param value the value that eventually completes the mapped future * @return the mapped future */ public io.vertx.rxjava.core.Future<Boolean> otherwise(Boolean value) { io.vertx.rxjava.core.Future<Boolean> ret = io.vertx.rxjava.core.Future.newInstance(delegate.otherwise(value), io.vertx.lang.rx.TypeArg.unknown()); return ret; }
/** * Compose this future with a provided <code>next</code> future.<p> * * When this (the one on which <code>compose</code> is called) future succeeds, the <code>handler</code> will be called with * the completed value, this handler should complete the next future.<p> * * If the <code>handler</code> throws an exception, the returned future will be failed with this exception.<p> * * When this future fails, the failure will be propagated to the <code>next</code> future and the <code>handler</code> * will not be called. * @param handler the handler * @param next the next future * @return the next future, used for chaining */ public <U> io.vertx.rxjava.core.Future<U> compose(Handler<Boolean> handler, io.vertx.rxjava.core.Future<U> next) { io.vertx.rxjava.core.Future<U> ret = io.vertx.rxjava.core.Future.newInstance(delegate.compose(handler, next.getDelegate()), next.__typeArg_0); return ret; }
/** * @return an handler completing this future */ public Handler<AsyncResult<Boolean>> completer() { if (cached_0 != null) { return cached_0; } Handler<AsyncResult<Boolean>> ret = delegate.completer(); cached_0 = ret; return ret; }
/** * Map the failure of a future to <code>null</code>.<p> * * This is a convenience for <code>future.otherwise((T) null)</code>.<p> * * When this future fails, the <code>null</code> value will complete the future returned by this method call.<p> * * When this future succeeds, the result will be propagated to the returned future. * @return the mapped future */ public io.vertx.rxjava.core.Future<Boolean> otherwiseEmpty() { io.vertx.rxjava.core.Future<Boolean> ret = io.vertx.rxjava.core.Future.newInstance(delegate.otherwiseEmpty(), io.vertx.lang.rx.TypeArg.unknown()); return ret; }
/** * Handles a failure of this Future by returning the result of another Future. * If the mapper fails, then the returned future will be failed with this failure. * @param mapper A function which takes the exception of a failure and returns a new future. * @return A recovered future */ public io.vertx.rxjava.core.Future<Boolean> recover(Function<Throwable, io.vertx.rxjava.core.Future<Boolean>> mapper) { io.vertx.rxjava.core.Future<Boolean> ret = io.vertx.rxjava.core.Future.newInstance(delegate.recover(new java.util.function.Function<java.lang.Throwable,io.vertx.core.Future<java.lang.Boolean>>() { public io.vertx.core.Future<java.lang.Boolean> apply(java.lang.Throwable arg) { io.vertx.rxjava.core.Future<Boolean> ret = mapper.apply(arg); return ret.getDelegate(); } }), io.vertx.lang.rx.TypeArg.unknown()); return ret; }
/** * Get the raw JSON message for the event. This will be null for SOCKET_CREATED or SOCKET_CLOSED events as there is * no message involved. * @param message the raw message * @return this reference, so it can be used fluently */ public io.vertx.rxjava.ext.bridge.BaseBridgeEvent setRawMessage(JsonObject message) { delegate.setRawMessage(message); return this; }
/** * Get the raw JSON message for the event. This will be null for SOCKET_CREATED or SOCKET_CLOSED events as there is * no message involved. If the returned message is modified, {@link io.vertx.rxjava.ext.bridge.BaseBridgeEvent#setRawMessage} should be called with the * new message. * @return the raw JSON message for the event */ public JsonObject getRawMessage() { JsonObject ret = delegate.getRawMessage(); return ret; }
/** * Apply a <code>mapper</code> function on this future.<p> * * When this future succeeds, the <code>mapper</code> will be called with the completed value and this mapper * returns a value. This value will complete the future returned by this method call.<p> * * If the <code>mapper</code> throws an exception, the returned future will be failed with this exception.<p> * * When this future fails, the failure will be propagated to the returned future and the <code>mapper</code> * will not be called. * @param mapper the mapper function * @return the mapped future */ public <U> io.vertx.rxjava.core.Future<U> map(Function<Boolean, U> mapper) { io.vertx.rxjava.core.Future<U> ret = io.vertx.rxjava.core.Future.newInstance(delegate.map(mapper), io.vertx.lang.rx.TypeArg.unknown()); return ret; }
/** * Apply a <code>mapper</code> function on this future.<p> * * When this future fails, the <code>mapper</code> will be called with the completed value and this mapper * returns a value. This value will complete the future returned by this method call.<p> * * If the <code>mapper</code> throws an exception, the returned future will be failed with this exception.<p> * * When this future succeeds, the result will be propagated to the returned future and the <code>mapper</code> * will not be called. * @param mapper the mapper function * @return the mapped future */ public io.vertx.rxjava.core.Future<Boolean> otherwise(Function<Throwable, Boolean> mapper) { io.vertx.rxjava.core.Future<Boolean> ret = io.vertx.rxjava.core.Future.newInstance(delegate.otherwise(mapper), io.vertx.lang.rx.TypeArg.unknown()); return ret; }