Package io.vertx.rxjava3.core
Class RxHelper
- java.lang.Object
-
- io.vertx.rxjava3.core.RxHelper
-
public class RxHelper extends Object
- Author:
- Julien Viet
-
-
Constructor Summary
Constructors Constructor Description RxHelper()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Scheduler
blockingScheduler(Vertx vertx)
Create a scheduler for aVertx
object, actions can be blocking, they are not executed on Vertx event loop.static Scheduler
blockingScheduler(Vertx vertx, boolean ordered)
Create a scheduler for aVertx
object, actions can be blocking, they are not executed on Vertx event loop.static Scheduler
blockingScheduler(WorkerExecutor executor)
Create a scheduler for aWorkerExecutor
object, actions are executed on the threads of this executor.static Single<String>
deployVerticle(Vertx vertx, Verticle verticle)
Deploy a verticle you have created yourself, using an RxJava vertx instance.static Single<String>
deployVerticle(Vertx vertx, Verticle verticle, DeploymentOptions options)
LikedeployVerticle(Vertx, Verticle)
, butDeploymentOptions
are provided to configure the deployment.static Scheduler
scheduler(Context context)
Create a scheduler for aContext
, actions are executed on the event loop of this context.static Scheduler
scheduler(Vertx vertx)
Create a scheduler for aVertx
object, actions are executed on the event loop.
-
-
-
Method Detail
-
blockingScheduler
public static Scheduler blockingScheduler(WorkerExecutor executor)
Create a scheduler for aWorkerExecutor
object, actions are executed on the threads of this executor.- Parameters:
executor
- the worker executor object- Returns:
- the scheduler
-
blockingScheduler
public static Scheduler blockingScheduler(Vertx vertx, boolean ordered)
Create a scheduler for aVertx
object, actions can be blocking, they are not executed on Vertx event loop.- Parameters:
vertx
- the vertx objectordered
- if true then if when tasks are scheduled several times on the same context, the executions for that context will be executed serially, not in parallel. if false then they will be no ordering guarantees- Returns:
- the scheduler
-
deployVerticle
public static Single<String> deployVerticle(Vertx vertx, Verticle verticle)
Deploy a verticle you have created yourself, using an RxJava vertx instance.- Parameters:
vertx
- the vertx instanceverticle
- the verticle instance to deploy- Returns:
- the response observable
-
deployVerticle
public static Single<String> deployVerticle(Vertx vertx, Verticle verticle, DeploymentOptions options)
LikedeployVerticle(Vertx, Verticle)
, butDeploymentOptions
are provided to configure the deployment.- Parameters:
vertx
- the vertx instanceverticle
- the verticle instance to deployoptions
- the deployment options.- Returns:
- the response observable
-
blockingScheduler
public static Scheduler blockingScheduler(Vertx vertx)
Create a scheduler for aVertx
object, actions can be blocking, they are not executed on Vertx event loop.- Parameters:
vertx
- the vertx object- Returns:
- the scheduler
-
scheduler
public static Scheduler scheduler(Context context)
Create a scheduler for aContext
, actions are executed on the event loop of this context.- Parameters:
context
- the context object- Returns:
- the scheduler
-
-