Package org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.openflow.provider.config.rev160510
Class OpenflowProviderConfigBuilder
java.lang.Object
org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.openflow.provider.config.rev160510.OpenflowProviderConfigBuilder
Class that builds
OpenflowProviderConfig
instances. Overall design of the class is that of a
fluent interface, where method chaining is used.
In general, this class is supposed to be used like this template:
OpenflowProviderConfig createOpenflowProviderConfig(int fooXyzzy, int barBaz) {
return new OpenflowProviderConfigBuilder()
.setFoo(new FooBuilder().setXyzzy(fooXyzzy).build())
.setBar(new BarBuilder().setBaz(barBaz).build())
.build();
}
This pattern is supported by the immutable nature of OpenflowProviderConfig, as instances can be freely passed around without worrying about synchronization issues.
As a side note: method chaining results in:
- very efficient Java bytecode, as the method invocation result, in this case the Builder reference, is
on the stack, so further method invocations just need to fill method arguments for the next method
invocation, which is terminated by
build()
, which is then returned from the method - better understanding by humans, as the scope of mutable state (the builder) is kept to a minimum and is very localized
- better optimization opportunities, as the object scope is minimized in terms of invocation (rather than method) stack, making escape analysis a lot easier. Given enough compiler (JIT/AOT) prowess, the cost of th builder object can be completely eliminated
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionConstruct an empty builder.Construct a builder initialized with state from specifiedOpenflowProviderConfig
. -
Method Summary
Modifier and TypeMethodDescriptionaddAugmentation
(org.opendaylight.yangtools.yang.binding.Augmentation<OpenflowProviderConfig> augmentation) Add an augmentation to this builder's product.<E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<OpenflowProviderConfig>>
E$$augmentation
(Class<E$$> augmentationType) Return the specified augmentation, if it is present in this builder.@NonNull OpenflowProviderConfig
build()
A newOpenflowProviderConfig
instance.Return current value associated with the property corresponding toOpenflowProviderConfig.getBarrierCountLimit()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getBarrierIntervalTimeoutLimit()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getBasicTimerDelay()
.org.opendaylight.yangtools.yang.common.Uint16
Return current value associated with the property corresponding toOpenflowProviderConfig.getDeviceConnectionHoldTimeInSeconds()
.org.opendaylight.yangtools.yang.common.Uint16
Return current value associated with the property corresponding toOpenflowProviderConfig.getDeviceConnectionRateLimitPerMin()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getDeviceDatastoreRemovalDelay()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getEchoReplyTimeout()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getEnableEqualRole()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getEnableFlowRemovedNotification()
.org.opendaylight.yangtools.yang.common.Uint32
Return current value associated with the property corresponding toOpenflowProviderConfig.getGlobalNotificationQuota()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getIsFlowStatisticsPollingOn()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getIsGroupStatisticsPollingOn()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getIsMeterStatisticsPollingOn()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getIsPortStatisticsPollingOn()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getIsQueueStatisticsPollingOn()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getIsStatisticsPollingOn()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getIsStatisticsRpcEnabled()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getIsTableStatisticsPollingOn()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getMaximumTimerDelay()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getRpcRequestsQuota()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getSkipTableFeatures()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getSwitchFeaturesMandatory()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getThreadPoolMaxThreads()
.org.opendaylight.yangtools.yang.common.Uint16
Return current value associated with the property corresponding toOpenflowProviderConfig.getThreadPoolMinThreads()
.org.opendaylight.yangtools.yang.common.Uint32
Return current value associated with the property corresponding toOpenflowProviderConfig.getThreadPoolTimeout()
.Return current value associated with the property corresponding toOpenflowProviderConfig.getUseSingleLayerSerialization()
.removeAugmentation
(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<OpenflowProviderConfig>> augmentationType) Remove an augmentation from this builder's product.Set the property corresponding toOpenflowProviderConfig.getBarrierCountLimit()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getBarrierIntervalTimeoutLimit()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getBasicTimerDelay()
to the specified value.setDeviceConnectionHoldTimeInSeconds
(org.opendaylight.yangtools.yang.common.Uint16 value) Set the property corresponding toOpenflowProviderConfig.getDeviceConnectionHoldTimeInSeconds()
to the specified value.setDeviceConnectionRateLimitPerMin
(org.opendaylight.yangtools.yang.common.Uint16 value) Set the property corresponding toOpenflowProviderConfig.getDeviceConnectionRateLimitPerMin()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getDeviceDatastoreRemovalDelay()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getEchoReplyTimeout()
to the specified value.setEnableEqualRole
(Boolean value) Set the property corresponding toOpenflowProviderConfig.getEnableEqualRole()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getEnableFlowRemovedNotification()
to the specified value.setGlobalNotificationQuota
(org.opendaylight.yangtools.yang.common.Uint32 value) Set the property corresponding toOpenflowProviderConfig.getGlobalNotificationQuota()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getIsFlowStatisticsPollingOn()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getIsGroupStatisticsPollingOn()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getIsMeterStatisticsPollingOn()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getIsPortStatisticsPollingOn()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getIsQueueStatisticsPollingOn()
to the specified value.setIsStatisticsPollingOn
(Boolean value) Set the property corresponding toOpenflowProviderConfig.getIsStatisticsPollingOn()
to the specified value.setIsStatisticsRpcEnabled
(Boolean value) Set the property corresponding toOpenflowProviderConfig.getIsStatisticsRpcEnabled()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getIsTableStatisticsPollingOn()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getMaximumTimerDelay()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getRpcRequestsQuota()
to the specified value.setSkipTableFeatures
(Boolean value) Set the property corresponding toOpenflowProviderConfig.getSkipTableFeatures()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getSwitchFeaturesMandatory()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getThreadPoolMaxThreads()
to the specified value.setThreadPoolMinThreads
(org.opendaylight.yangtools.yang.common.Uint16 value) Set the property corresponding toOpenflowProviderConfig.getThreadPoolMinThreads()
to the specified value.setThreadPoolTimeout
(org.opendaylight.yangtools.yang.common.Uint32 value) Set the property corresponding toOpenflowProviderConfig.getThreadPoolTimeout()
to the specified value.Set the property corresponding toOpenflowProviderConfig.getUseSingleLayerSerialization()
to the specified value.
-
Constructor Details
-
OpenflowProviderConfigBuilder
public OpenflowProviderConfigBuilder()Construct an empty builder. -
OpenflowProviderConfigBuilder
Construct a builder initialized with state from specifiedOpenflowProviderConfig
.- Parameters:
base
- OpenflowProviderConfig from which the builder should be initialized
-
-
Method Details
-
getBarrierCountLimit
Return current value associated with the property corresponding toOpenflowProviderConfig.getBarrierCountLimit()
.- Returns:
- current value
-
getBarrierIntervalTimeoutLimit
Return current value associated with the property corresponding toOpenflowProviderConfig.getBarrierIntervalTimeoutLimit()
.- Returns:
- current value
-
getBasicTimerDelay
Return current value associated with the property corresponding toOpenflowProviderConfig.getBasicTimerDelay()
.- Returns:
- current value
-
getDeviceConnectionHoldTimeInSeconds
public org.opendaylight.yangtools.yang.common.Uint16 getDeviceConnectionHoldTimeInSeconds()Return current value associated with the property corresponding toOpenflowProviderConfig.getDeviceConnectionHoldTimeInSeconds()
.- Returns:
- current value
-
getDeviceConnectionRateLimitPerMin
public org.opendaylight.yangtools.yang.common.Uint16 getDeviceConnectionRateLimitPerMin()Return current value associated with the property corresponding toOpenflowProviderConfig.getDeviceConnectionRateLimitPerMin()
.- Returns:
- current value
-
getDeviceDatastoreRemovalDelay
Return current value associated with the property corresponding toOpenflowProviderConfig.getDeviceDatastoreRemovalDelay()
.- Returns:
- current value
-
getEchoReplyTimeout
Return current value associated with the property corresponding toOpenflowProviderConfig.getEchoReplyTimeout()
.- Returns:
- current value
-
getEnableEqualRole
Return current value associated with the property corresponding toOpenflowProviderConfig.getEnableEqualRole()
.- Returns:
- current value
-
getEnableFlowRemovedNotification
Return current value associated with the property corresponding toOpenflowProviderConfig.getEnableFlowRemovedNotification()
.- Returns:
- current value
-
getGlobalNotificationQuota
public org.opendaylight.yangtools.yang.common.Uint32 getGlobalNotificationQuota()Return current value associated with the property corresponding toOpenflowProviderConfig.getGlobalNotificationQuota()
.- Returns:
- current value
-
getIsFlowStatisticsPollingOn
Return current value associated with the property corresponding toOpenflowProviderConfig.getIsFlowStatisticsPollingOn()
.- Returns:
- current value
-
getIsGroupStatisticsPollingOn
Return current value associated with the property corresponding toOpenflowProviderConfig.getIsGroupStatisticsPollingOn()
.- Returns:
- current value
-
getIsMeterStatisticsPollingOn
Return current value associated with the property corresponding toOpenflowProviderConfig.getIsMeterStatisticsPollingOn()
.- Returns:
- current value
-
getIsPortStatisticsPollingOn
Return current value associated with the property corresponding toOpenflowProviderConfig.getIsPortStatisticsPollingOn()
.- Returns:
- current value
-
getIsQueueStatisticsPollingOn
Return current value associated with the property corresponding toOpenflowProviderConfig.getIsQueueStatisticsPollingOn()
.- Returns:
- current value
-
getIsStatisticsPollingOn
Return current value associated with the property corresponding toOpenflowProviderConfig.getIsStatisticsPollingOn()
.- Returns:
- current value
-
getIsStatisticsRpcEnabled
Return current value associated with the property corresponding toOpenflowProviderConfig.getIsStatisticsRpcEnabled()
.- Returns:
- current value
-
getIsTableStatisticsPollingOn
Return current value associated with the property corresponding toOpenflowProviderConfig.getIsTableStatisticsPollingOn()
.- Returns:
- current value
-
getMaximumTimerDelay
Return current value associated with the property corresponding toOpenflowProviderConfig.getMaximumTimerDelay()
.- Returns:
- current value
-
getRpcRequestsQuota
Return current value associated with the property corresponding toOpenflowProviderConfig.getRpcRequestsQuota()
.- Returns:
- current value
-
getSkipTableFeatures
Return current value associated with the property corresponding toOpenflowProviderConfig.getSkipTableFeatures()
.- Returns:
- current value
-
getSwitchFeaturesMandatory
Return current value associated with the property corresponding toOpenflowProviderConfig.getSwitchFeaturesMandatory()
.- Returns:
- current value
-
getThreadPoolMaxThreads
Return current value associated with the property corresponding toOpenflowProviderConfig.getThreadPoolMaxThreads()
.- Returns:
- current value
-
getThreadPoolMinThreads
public org.opendaylight.yangtools.yang.common.Uint16 getThreadPoolMinThreads()Return current value associated with the property corresponding toOpenflowProviderConfig.getThreadPoolMinThreads()
.- Returns:
- current value
-
getThreadPoolTimeout
public org.opendaylight.yangtools.yang.common.Uint32 getThreadPoolTimeout()Return current value associated with the property corresponding toOpenflowProviderConfig.getThreadPoolTimeout()
.- Returns:
- current value
-
getUseSingleLayerSerialization
Return current value associated with the property corresponding toOpenflowProviderConfig.getUseSingleLayerSerialization()
.- Returns:
- current value
-
augmentation
public <E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<OpenflowProviderConfig>> E$$ augmentation(Class<E$$> augmentationType) Return the specified augmentation, if it is present in this builder.- Type Parameters:
E$$
- augmentation type- Parameters:
augmentationType
- augmentation type class- Returns:
- Augmentation object from this builder, or
null
if not present - Throws:
NullPointerException
- ifaugmentType
isnull
-
setBarrierCountLimit
Set the property corresponding toOpenflowProviderConfig.getBarrierCountLimit()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setBarrierIntervalTimeoutLimit
Set the property corresponding toOpenflowProviderConfig.getBarrierIntervalTimeoutLimit()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setBasicTimerDelay
Set the property corresponding toOpenflowProviderConfig.getBasicTimerDelay()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setDeviceConnectionHoldTimeInSeconds
public OpenflowProviderConfigBuilder setDeviceConnectionHoldTimeInSeconds(org.opendaylight.yangtools.yang.common.Uint16 value) Set the property corresponding toOpenflowProviderConfig.getDeviceConnectionHoldTimeInSeconds()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setDeviceConnectionRateLimitPerMin
public OpenflowProviderConfigBuilder setDeviceConnectionRateLimitPerMin(org.opendaylight.yangtools.yang.common.Uint16 value) Set the property corresponding toOpenflowProviderConfig.getDeviceConnectionRateLimitPerMin()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setDeviceDatastoreRemovalDelay
Set the property corresponding toOpenflowProviderConfig.getDeviceDatastoreRemovalDelay()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setEchoReplyTimeout
Set the property corresponding toOpenflowProviderConfig.getEchoReplyTimeout()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setEnableEqualRole
Set the property corresponding toOpenflowProviderConfig.getEnableEqualRole()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setEnableFlowRemovedNotification
Set the property corresponding toOpenflowProviderConfig.getEnableFlowRemovedNotification()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setGlobalNotificationQuota
public OpenflowProviderConfigBuilder setGlobalNotificationQuota(org.opendaylight.yangtools.yang.common.Uint32 value) Set the property corresponding toOpenflowProviderConfig.getGlobalNotificationQuota()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setIsFlowStatisticsPollingOn
Set the property corresponding toOpenflowProviderConfig.getIsFlowStatisticsPollingOn()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setIsGroupStatisticsPollingOn
Set the property corresponding toOpenflowProviderConfig.getIsGroupStatisticsPollingOn()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setIsMeterStatisticsPollingOn
Set the property corresponding toOpenflowProviderConfig.getIsMeterStatisticsPollingOn()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setIsPortStatisticsPollingOn
Set the property corresponding toOpenflowProviderConfig.getIsPortStatisticsPollingOn()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setIsQueueStatisticsPollingOn
Set the property corresponding toOpenflowProviderConfig.getIsQueueStatisticsPollingOn()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setIsStatisticsPollingOn
Set the property corresponding toOpenflowProviderConfig.getIsStatisticsPollingOn()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setIsStatisticsRpcEnabled
Set the property corresponding toOpenflowProviderConfig.getIsStatisticsRpcEnabled()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setIsTableStatisticsPollingOn
Set the property corresponding toOpenflowProviderConfig.getIsTableStatisticsPollingOn()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setMaximumTimerDelay
Set the property corresponding toOpenflowProviderConfig.getMaximumTimerDelay()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setRpcRequestsQuota
Set the property corresponding toOpenflowProviderConfig.getRpcRequestsQuota()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setSkipTableFeatures
Set the property corresponding toOpenflowProviderConfig.getSkipTableFeatures()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setSwitchFeaturesMandatory
Set the property corresponding toOpenflowProviderConfig.getSwitchFeaturesMandatory()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setThreadPoolMaxThreads
Set the property corresponding toOpenflowProviderConfig.getThreadPoolMaxThreads()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setThreadPoolMinThreads
public OpenflowProviderConfigBuilder setThreadPoolMinThreads(org.opendaylight.yangtools.yang.common.Uint16 value) Set the property corresponding toOpenflowProviderConfig.getThreadPoolMinThreads()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setThreadPoolTimeout
public OpenflowProviderConfigBuilder setThreadPoolTimeout(org.opendaylight.yangtools.yang.common.Uint32 value) Set the property corresponding toOpenflowProviderConfig.getThreadPoolTimeout()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
setUseSingleLayerSerialization
Set the property corresponding toOpenflowProviderConfig.getUseSingleLayerSerialization()
to the specified value.- Parameters:
value
- desired value- Returns:
- this builder
-
addAugmentation
public OpenflowProviderConfigBuilder addAugmentation(org.opendaylight.yangtools.yang.binding.Augmentation<OpenflowProviderConfig> augmentation) Add an augmentation to this builder's product.- Parameters:
augmentation
- augmentation to be added- Returns:
- this builder
- Throws:
NullPointerException
- ifaugmentation
is null
-
removeAugmentation
public OpenflowProviderConfigBuilder removeAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<OpenflowProviderConfig>> augmentationType) Remove an augmentation from this builder's product. If this builder does not track such an augmentation type, this method does nothing.- Parameters:
augmentationType
- augmentation type to be removed- Returns:
- this builder
-
build
A newOpenflowProviderConfig
instance.- Returns:
- A new
OpenflowProviderConfig
instance.
-