package io.vertx.groovy.servicediscovery.types;
public class RedisDataSource_GroovyStaticExtension {
public static java.util.Map<String, Object> createRecord(io.vertx.servicediscovery.types.RedisDataSource j_receiver, java.lang.String name, java.util.Map<String, Object> location, java.util.Map<String, Object> metadata) {
return io.vertx.servicediscovery.types.RedisDataSource.createRecord(name,
location != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(location) : null,
metadata != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(metadata) : null) != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(io.vertx.servicediscovery.types.RedisDataSource.createRecord(name,
location != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(location) : null,
metadata != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(metadata) : null).toJson()) : null;
}
public static void getRedisClient(io.vertx.servicediscovery.types.RedisDataSource j_receiver, io.vertx.servicediscovery.ServiceDiscovery discovery, java.util.Map<String, Object> filter, io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.redis.RedisClient>> resultHandler) {
io.vertx.servicediscovery.types.RedisDataSource.getRedisClient(discovery,
filter != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(filter) : null,
resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.redis.RedisClient>>() {
public void handle(io.vertx.core.AsyncResult<io.vertx.redis.RedisClient> ar) {
resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
}
} : null);
}
public static void getRedisClient(io.vertx.servicediscovery.types.RedisDataSource j_receiver, io.vertx.servicediscovery.ServiceDiscovery discovery, java.util.function.Function<java.util.Map<String, Object>, java.lang.Boolean> filter, io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.redis.RedisClient>> resultHandler) {
io.vertx.servicediscovery.types.RedisDataSource.getRedisClient(discovery,
filter != null ? new java.util.function.Function<io.vertx.servicediscovery.Record, java.lang.Boolean>() {
public java.lang.Boolean apply(io.vertx.servicediscovery.Record t) {
java.util.Map<String, Object> o = t != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(t.toJson()) : null;
java.lang.Boolean p = filter.apply(o);
return p;
}
} : null,
resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.redis.RedisClient>>() {
public void handle(io.vertx.core.AsyncResult<io.vertx.redis.RedisClient> ar) {
resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
}
} : null);
}
public static void getRedisClient(io.vertx.servicediscovery.types.RedisDataSource j_receiver, io.vertx.servicediscovery.ServiceDiscovery discovery, java.util.Map<String, Object> filter, java.util.Map<String, Object> consumerConfiguration, io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.redis.RedisClient>> resultHandler) {
io.vertx.servicediscovery.types.RedisDataSource.getRedisClient(discovery,
filter != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(filter) : null,
consumerConfiguration != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(consumerConfiguration) : null,
resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.redis.RedisClient>>() {
public void handle(io.vertx.core.AsyncResult<io.vertx.redis.RedisClient> ar) {
resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
}
} : null);
}
public static void getRedisClient(io.vertx.servicediscovery.types.RedisDataSource j_receiver, io.vertx.servicediscovery.ServiceDiscovery discovery, java.util.function.Function<java.util.Map<String, Object>, java.lang.Boolean> filter, java.util.Map<String, Object> consumerConfiguration, io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.redis.RedisClient>> resultHandler) {
io.vertx.servicediscovery.types.RedisDataSource.getRedisClient(discovery,
filter != null ? new java.util.function.Function<io.vertx.servicediscovery.Record, java.lang.Boolean>() {
public java.lang.Boolean apply(io.vertx.servicediscovery.Record t) {
java.util.Map<String, Object> o = t != null ? io.vertx.core.impl.ConversionHelper.fromJsonObject(t.toJson()) : null;
java.lang.Boolean p = filter.apply(o);
return p;
}
} : null,
consumerConfiguration != null ? io.vertx.core.impl.ConversionHelper.toJsonObject(consumerConfiguration) : null,
resultHandler != null ? new io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.redis.RedisClient>>() {
public void handle(io.vertx.core.AsyncResult<io.vertx.redis.RedisClient> ar) {
resultHandler.handle(ar.map(event -> io.vertx.core.impl.ConversionHelper.fromObject(event)));
}
} : null);
}
}