Package | Description |
---|---|
ratpack.exec |
The execution management.
|
ratpack.func |
General functional (i.e. Single Abstract Method) types.
|
ratpack.http.client |
The HTTP client.
|
ratpack.impose | |
ratpack.jdbctx | |
ratpack.test | |
ratpack.test.embed |
Support for creating embedded applications at test time, for testing Ratpack features and extensions.
|
ratpack.util |
General purpose types and utilities.
|
Modifier and Type | Method and Description |
---|---|
default <B,A> Promise<A> |
Promise.around(Factory<? extends B> before,
BiFunction<? super B,? super ExecResult<T>,? extends ExecResult<A>> after)
Facilitates capturing a value before the the promise is subscribed and using it to later augment the result.
|
default <T> Promise<T> |
Operation.flatMap(Factory<? extends Promise<T>> factory) |
static <T> Promise<T> |
Promise.flatten(Factory<? extends Promise<T>> factory)
Creates a promise for the promise produced by the given factory.
|
static Operation |
Operation.flatten(Factory<Operation> factory)
Create an operation that delegates to another operation.
|
static <T> Promise<T> |
Blocking.get(Factory<T> factory)
Performs a blocking operation on a separate thread, returning a promise for its value.
|
default <T> Promise<T> |
Operation.map(Factory<? extends T> factory) |
static <T> Promise<T> |
Promise.ofLazy(Factory<T> factory)
Deprecated.
replaced by
Promise.sync(Factory) } |
static <T> Promise<T> |
Promise.sync(Factory<T> factory)
Creates a promise for the value synchronously produced by the given factory.
|
static <T> Promise<T> |
Promise.wrap(Factory<? extends Promise<T>> factory)
Deprecated.
since 1.5, replaced by
Promise.flatten(Factory) . |
Modifier and Type | Method and Description |
---|---|
static <T> Factory<T> |
Factory.constant(T item)
Creates a factory that always returns the given item.
|
Modifier and Type | Method and Description |
---|---|
default RequestSpec |
RequestSpec.sslContext(Factory<javax.net.ssl.SSLContext> factory)
Deprecated.
since 1.5, no replacement.
|
Modifier and Type | Method and Description |
---|---|
<T> T |
Impositions.impose(Factory<? extends T> during)
Delegates to
Impositions.impose(Impositions, Factory) , with this as the impositions. |
static <T> T |
Impositions.impose(Impositions impositions,
Factory<? extends T> during)
Sets impositions that will be available during execution of the given function, from this thread.
|
Modifier and Type | Method and Description |
---|---|
static Transaction |
Transaction.bound(Factory<? extends java.sql.Connection> connectionFactory)
Creates a transaction implementation that delegates to the execution bound transaction.
|
static Transaction |
Transaction.create(Factory<? extends java.sql.Connection> connectionFactory)
Creates a new transaction.
|
static Transaction |
Transaction.get(Factory<? extends java.sql.Connection> connectionFactory)
Returns the current transaction if present, otherwise a newly created transaction.
|
default <T> Promise<T> |
Transaction.wrap(Factory<? extends Promise<T>> promiseFactory)
Executes the given factory and yields the resultant promise in a transaction.
|
Modifier and Type | Method and Description |
---|---|
static ServerBackedApplicationUnderTest |
ServerBackedApplicationUnderTest.of(Factory<? extends RatpackServer> ratpackServer)
Creates a new instance backed by the server returned by the given function.
|
Modifier and Type | Method and Description |
---|---|
static EmbeddedApp |
EmbeddedApp.fromServer(Factory<? extends RatpackServer> server)
Creates an embedded application for the given server.
|
Modifier and Type | Method and Description |
---|---|
static <T> T |
Exceptions.uncheck(Factory<T> factory)
Executes the given factory, returning its result and unchecking any exceptions it throws.
|