routingDsl.GET("/setlang/:to").routeTo(FunctionUtil.function(new I18NRoute())); routingDsl.GET("/lang/getCurrent").routeTo(() -> ok(I18NProvider.getInstance().getDefaultLanguage())); routingDsl.GET("/assets/*file").routeTo(FunctionUtil.function(new Assets(ASSETS_ROOT_DIRECTORY))); switch (r.getFunctionType()) { case Supplier: ppm.routeTo(FunctionUtil.function0(r.getSupplier())); break; case Function: ppm.routeTo(FunctionUtil.function(r.getFunction())); break; case BiFunction:
/** * Route with three parameters. * * @param <A1> the first type parameter * @param <A2> the second type parameter * @param <A3> the third type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingAsync(RequestFunctions.Params3)} instead. */ @Deprecated public <A1, A2, A3> RoutingDsl routeAsync(F.Function3<A1, A2, A3, ? extends CompletionStage<Result>> action) { return build(3, action, F.Function3.class); }
routingDsl.GET("/setlang/:to").routeTo(FunctionUtil.function(new I18NRoute())); routingDsl.GET("/lang/getCurrent").routeTo(() -> ok(I18NProvider.getInstance().getDefaultLanguage())); routingDsl.GET("/assets/*file").routeTo(FunctionUtil.function(new Assets(ASSETS_ROOT_DIRECTORY))); switch (r.getFunctionType()) { case Supplier: ppm.routeTo(FunctionUtil.function0(r.getSupplier())); break; case Function: ppm.routeTo(FunctionUtil.function(r.getFunction())); break; case BiFunction:
routingDsl.GET("/transformprocess").routeTo(FunctionUtil.function0((() -> { try { if (transform == null) routingDsl.POST("/transformprocess").routeTo(FunctionUtil.function0((() -> { try { TransformProcess transformProcess = TransformProcess.fromJson(getJsonText()); routingDsl.POST("/transformincremental").routeTo(FunctionUtil.function0((() -> { try { SingleCSVRecord record = objectMapper.readValue(getJsonText(), SingleCSVRecord.class); routingDsl.POST("/transform").routeTo(FunctionUtil.function0((() -> { try { BatchCSVRecord batch = transform(objectMapper.readValue(getJsonText(), BatchCSVRecord.class)); routingDsl.POST("/transformincrementalarray").routeTo(FunctionUtil.function0((() -> { try { SingleCSVRecord record = objectMapper.readValue(getJsonText(), SingleCSVRecord.class); routingDsl.POST("/transformarray").routeTo(FunctionUtil.function0((() -> { try { BatchCSVRecord batchCSVRecord = objectMapper.readValue(getJsonText(), BatchCSVRecord.class);
routingDsl.GET("/setlang/:to").routeTo(FunctionUtil.function(new I18NRoute())); routingDsl.GET("/lang/getCurrent").routeTo(() -> ok(I18NProvider.getInstance().getDefaultLanguage())); routingDsl.GET("/assets/*file").routeTo(FunctionUtil.function(new Assets(ASSETS_ROOT_DIRECTORY))); switch (r.getFunctionType()) { case Supplier: ppm.routeTo(FunctionUtil.function0(r.getSupplier())); break; case Function: ppm.routeTo(FunctionUtil.function(r.getFunction())); break; case BiFunction:
log.info("Starting server on port " + statusServerPort); RoutingDsl dsl = new RoutingDsl(); dsl.GET("/ids/").routeTo(new F.Function0<Result>() { dsl.GET("/state/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.GET("/type/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.GET("/started/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.GET("/connectioninfo/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.POST("/updatestatus/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable {
log.info("Starting server on port " + statusServerPort); RoutingDsl dsl = new RoutingDsl(); dsl.GET("/ids/").routeTo(new F.Function0<Result>() { dsl.GET("/state/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.GET("/type/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.GET("/started/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.GET("/connectioninfo/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.POST("/updatestatus/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable {
routingDsl.GET("/transformprocess").routeTo(FunctionUtil.function0((() -> { try { if (transform == null) routingDsl.POST("/transformprocess").routeTo(FunctionUtil.function0((() -> { try { ImageTransformProcess transformProcess = ImageTransformProcess.fromJson(getJsonText()); routingDsl.POST("/transformincrementalarray").routeTo(FunctionUtil.function0((() -> { try { SingleImageRecord record = objectMapper.readValue(getJsonText(), SingleImageRecord.class); routingDsl.POST("/transformarray").routeTo(FunctionUtil.function0((() -> { try { BatchImageRecord batch = objectMapper.readValue(getJsonText(), BatchImageRecord.class);
log.info("Starting server on port " + statusServerPort); RoutingDsl dsl = new RoutingDsl(); dsl.GET("/ids/").routeTo(new F.Function0<Result>() { dsl.GET("/state/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.GET("/type/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.GET("/started/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.GET("/connectioninfo/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable { dsl.POST("/updatestatus/:id").routeTo(new F.Function<String, Result>() { @Override public Result apply(String id) throws Throwable {
/** * Route with three parameters. * * @param <A1> the first type parameter * @param <A2> the second type parameter * @param <A3> the third type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingTo(RequestFunctions.Params3)} instead. */ @Deprecated public <A1, A2, A3> RoutingDsl routeTo(F.Function3<A1, A2, A3, Result> action) { return build(3, action, F.Function3.class); }
/** * Route with three parameters. * * @param <A1> the first type parameter * @param <A2> the second type parameter * @param <A3> the third type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingTo(RequestFunctions.Params3)} instead. */ @Deprecated public <A1, A2, A3> RoutingDsl routeTo(F.Function3<A1, A2, A3, Result> action) { return build(3, action, F.Function3.class); }
/** * Route with three parameters. * * @param <A1> the first type parameter * @param <A2> the second type parameter * @param <A3> the third type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingAsync(RequestFunctions.Params3)} instead. */ @Deprecated public <A1, A2, A3> RoutingDsl routeAsync(F.Function3<A1, A2, A3, ? extends CompletionStage<Result>> action) { return build(3, action, F.Function3.class); }
/** * Route with three parameters. * * @param <A1> the first type parameter * @param <A2> the second type parameter * @param <A3> the third type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingAsync(RequestFunctions.Params3)} instead. */ @Deprecated public <A1, A2, A3> RoutingDsl routeAsync(F.Function3<A1, A2, A3, ? extends CompletionStage<Result>> action) { return build(3, action, F.Function3.class); }
/** * Route with three parameters. * * @param <A1> the first type parameter * @param <A2> the second type parameter * @param <A3> the third type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingTo(RequestFunctions.Params3)} instead. */ @Deprecated public <A1, A2, A3> RoutingDsl routeTo(F.Function3<A1, A2, A3, Result> action) { return build(3, action, F.Function3.class); }
/** * Route with two parameters. * * @param <A1> the first type parameter * @param <A2> the second type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingTo(RequestFunctions.Params2)} instead. */ @Deprecated public <A1, A2> RoutingDsl routeTo(BiFunction<A1, A2, Result> action) { return build(2, action, BiFunction.class); }
/** * Route with two parameters. * * @param <A1> the first type parameter * @param <A2> the second type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingAsync(RequestFunctions.Params2)} instead. */ @Deprecated public <A1, A2> RoutingDsl routeAsync(BiFunction<A1, A2, ? extends CompletionStage<Result>> action) { return build(2, action, BiFunction.class); }
/** * Route with two parameters. * * @param <A1> the first type parameter * @param <A2> the second type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingAsync(RequestFunctions.Params2)} instead. */ @Deprecated public <A1, A2> RoutingDsl routeAsync(BiFunction<A1, A2, ? extends CompletionStage<Result>> action) { return build(2, action, BiFunction.class); }
/** * Route with two parameters. * * @param <A1> the first type parameter * @param <A2> the second type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingTo(RequestFunctions.Params2)} instead. */ @Deprecated public <A1, A2> RoutingDsl routeTo(BiFunction<A1, A2, Result> action) { return build(2, action, BiFunction.class); }
/** * Route with one parameter. * * @param <A1> the first type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingAsync(RequestFunctions.Params1)} instead. */ @Deprecated public <A1> RoutingDsl routeAsync(Function<A1, ? extends CompletionStage<Result>> action) { return build(1, action, Function.class); }
/** * Route with two parameters. * * @param <A1> the first type parameter * @param <A2> the second type parameter * @param action The action to execute. * @return This router builder. * * @deprecated Deprecated as of 2.7.0. Use {@link #routingAsync(RequestFunctions.Params2)} instead. */ @Deprecated public <A1, A2> RoutingDsl routeAsync(BiFunction<A1, A2, ? extends CompletionStage<Result>> action) { return build(2, action, BiFunction.class); }