public final class ChannelConfiguration extends Object
TimeoutException will be thrown.| Modifier and Type | Class and Description |
|---|---|
static class |
ChannelConfiguration.Builder<TYPE>
Builder of channel configurations.
|
static interface |
ChannelConfiguration.Configurable<TYPE>
Interface defining a configurable object.
|
| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT
Constant indicating the default value of an integer attribute.
|
static ChannelConfiguration |
DEFAULT_CONFIGURATION
Empty configuration constant.
The configuration has all the options set to their default. |
| Modifier and Type | Method and Description |
|---|---|
static ChannelConfiguration.Builder<ChannelConfiguration> |
builder()
Returns a channel configuration builder.
|
ChannelConfiguration.Builder<ChannelConfiguration> |
builderFrom()
Returns a channel configuration builder initialized with this configuration.
|
static ChannelConfiguration.Builder<ChannelConfiguration> |
builderFrom(ChannelConfiguration initialConfiguration)
Returns a channel configuration builder initialized with the specified configuration.
|
boolean |
equals(Object o) |
Runner |
getAsyncRunnerOr(Runner valueIfNotSet)
Returns the runner used for asynchronous inputs (null by default).
|
int |
getChannelMaxSizeOr(int valueIfNotSet)
Returns the maximum number of buffered data (DEFAULT by default).
|
InvocationConfiguration.OrderType |
getChannelOrderTypeOr(InvocationConfiguration.OrderType valueIfNotSet)
Returns the data order (null by default).
|
TimeDuration |
getChannelTimeoutOr(TimeDuration valueIfNotSet)
Returns the maximum timeout while waiting for an object to be passed to the channel (null by
default).
|
Log.Level |
getLogLevelOr(Log.Level valueIfNotSet)
Returns the log level (null by default).
|
Log |
getLogOr(Log valueIfNotSet)
Returns the log instance (null by default).
|
InvocationConfiguration.TimeoutActionType |
getReadTimeoutActionOr(InvocationConfiguration.TimeoutActionType valueIfNotSet)
Returns the action to be taken if the timeout elapses before a readable output is available
(null by default).
|
TimeDuration |
getReadTimeoutOr(TimeDuration valueIfNotSet)
Returns the timeout for the channel to produce a readable output (null by default).
|
int |
hashCode() |
InvocationConfiguration |
toInputChannelConfiguration()
Converts this configuration into an invocation one by applying the matching options to the
invocation input channel.
|
InvocationConfiguration |
toInvocationConfiguration()
Converts this configuration into an invocation one by mapping the matching options.
|
InvocationConfiguration |
toOutputChannelConfiguration()
Converts this configuration into an invocation one by applying the matching options to the
invocation output channel.
|
String |
toString() |
public static final int DEFAULT
public static final ChannelConfiguration DEFAULT_CONFIGURATION
@NotNull public static ChannelConfiguration.Builder<ChannelConfiguration> builder()
@NotNull public static ChannelConfiguration.Builder<ChannelConfiguration> builderFrom(@Nullable ChannelConfiguration initialConfiguration)
initialConfiguration - the initial configuration.@NotNull public ChannelConfiguration.Builder<ChannelConfiguration> builderFrom()
public Runner getAsyncRunnerOr(@Nullable Runner valueIfNotSet)
valueIfNotSet - the default value if none was set.public int getChannelMaxSizeOr(int valueIfNotSet)
valueIfNotSet - the default value if none was set.public InvocationConfiguration.OrderType getChannelOrderTypeOr(@Nullable InvocationConfiguration.OrderType valueIfNotSet)
valueIfNotSet - the default value if none was set.public TimeDuration getChannelTimeoutOr(@Nullable TimeDuration valueIfNotSet)
valueIfNotSet - the default value if none was set.public Log.Level getLogLevelOr(@Nullable Log.Level valueIfNotSet)
valueIfNotSet - the default value if none was set.public Log getLogOr(@Nullable Log valueIfNotSet)
valueIfNotSet - the default value if none was set.public InvocationConfiguration.TimeoutActionType getReadTimeoutActionOr(@Nullable InvocationConfiguration.TimeoutActionType valueIfNotSet)
valueIfNotSet - the default value if none was set.public TimeDuration getReadTimeoutOr(@Nullable TimeDuration valueIfNotSet)
valueIfNotSet - the default value if none was set.@NotNull public InvocationConfiguration toInputChannelConfiguration()
@NotNull public InvocationConfiguration toInvocationConfiguration()
@NotNull public InvocationConfiguration toOutputChannelConfiguration()