public class BinderUtils extends Object
Constructor and Description |
---|
BinderUtils() |
Modifier and Type | Method and Description |
---|---|
static <S,A> void |
bindBlockingApi(com.google.inject.Binder binder,
Class<S> sync,
Class<A> async)
adds an explicit binding for an interface which synchronously blocks on similar calls to an
async type. |
static <S,A> void |
bindHttpApi(com.google.inject.Binder binder,
Class<S> sync,
Class<A> async)
adds an explicit binding for
async by parsing its annotations. |
public static <S,A> void bindHttpApi(com.google.inject.Binder binder, Class<S> sync, Class<A> async)
async
by parsing its annotations. Then. adds an explicit binding for an
interface which synchronously blocks on similar calls to an async
type.S
- sync interface that blocksA
- async type where all methods have same args as sync
, but returns ListenableFuture
binder
- guice bindersync
- type interface that blocksasync
- type type that returns ListenableFuture
public static <S,A> void bindBlockingApi(com.google.inject.Binder binder, Class<S> sync, Class<A> async)
async
type.S
- sync interface that blocksA
- async type where all methods have same args as sync
, but returns ListenableFuture
binder
- guice bindersync
- type interface that blocksasync
- type type that returns ListenableFuture
Copyright © 2009-2013 jclouds. All Rights Reserved.