Module to add items to a Multibinder. The method's return
type and binding annotation determines what Optional this will contribute to. For example,
@ProvidesIntoOptional(DEFAULT)
@Named("url")
String provideFooUrl(FooManager fm) { return fm.getUrl(); }
@ProvidesIntoOptional(ACTUAL)
@Named("url")
String provideBarUrl(BarManager bm) { return bm.getUrl(); }
will set the default value of @Named("url") Optional<String> to foo's URL, and then
override it to bar's URL.
| Modifier and Type | Class and Description |
|---|---|
| public static enum |
| Modifier and Type | Method and Description |
|---|---|
| public ProvidesIntoOptional. |
| value | back to summary |
|---|---|
| public ProvidesIntoOptional. Specifies if the binding is for the actual or default value. | |
| Modifier and Type | Field and Description |
|---|---|
| public static final ProvidesIntoOptional. | ACTUAL
Corresponds to |
| public static final ProvidesIntoOptional. | DEFAULT
Corresponds to |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static ProvidesIntoOptional. | |
| public static ProvidesIntoOptional. |
| ACTUAL | back to summary |
|---|---|
| public static final ProvidesIntoOptional. Corresponds to | |
| DEFAULT | back to summary |
|---|---|
| public static final ProvidesIntoOptional. Corresponds to | |
| Type | back to summary |
|---|---|
| private Type() | |
| valueOf | back to summary |
|---|---|
| public static ProvidesIntoOptional. | |
| values | back to summary |
|---|---|
| public static ProvidesIntoOptional. | |