Class FlowModAddMatchFromValueBuilder
- java.lang.Object
-
- org.opendaylight.yang.gen.v1.urn.opendaylight.openflowjava.nx.action.rev140421.flow.mod.spec.flow.mod.spec.flow.mod.add.match.from.value._case.FlowModAddMatchFromValueBuilder
-
- All Implemented Interfaces:
org.opendaylight.yangtools.concepts.Builder<FlowModAddMatchFromValue>
,org.opendaylight.yangtools.concepts.CheckedBuilder<FlowModAddMatchFromValue,IllegalArgumentException>
,org.opendaylight.yangtools.concepts.Mutable
,org.opendaylight.yangtools.concepts.MutationBehaviour<org.opendaylight.yangtools.concepts.Mutable>
@Generated("mdsal-binding-generator") public class FlowModAddMatchFromValueBuilder extends Object implements org.opendaylight.yangtools.concepts.Builder<FlowModAddMatchFromValue>
Class that buildsFlowModAddMatchFromValueBuilder
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:
FlowModAddMatchFromValueBuilder createTarget(int fooXyzzy, int barBaz) { return new FlowModAddMatchFromValueBuilderBuilder() .setFoo(new FooBuilder().setXyzzy(fooXyzzy).build()) .setBar(new BarBuilder().setBaz(barBaz).build()) .build(); }
This pattern is supported by the immutable nature of FlowModAddMatchFromValueBuilder, 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 oportunities, 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:
FlowModAddMatchFromValueBuilder
,Builder
-
-
Constructor Summary
Constructors Constructor Description FlowModAddMatchFromValueBuilder()
FlowModAddMatchFromValueBuilder(FlowModAddMatchFromValue base)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description FlowModAddMatchFromValueBuilder
addAugmentation(org.opendaylight.yangtools.yang.binding.Augmentation<FlowModAddMatchFromValue> augmentation)
Add an augmentation to this builder's product.<E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<FlowModAddMatchFromValue>>
E$$augmentation(Class<E$$> augmentationType)
FlowModAddMatchFromValue
build()
org.opendaylight.yangtools.yang.common.Uint16
getFlowModNumBits()
org.opendaylight.yangtools.yang.common.Uint32
getSrcField()
org.opendaylight.yangtools.yang.common.Uint16
getSrcOfs()
org.opendaylight.yangtools.yang.common.Uint16
getValue()
FlowModAddMatchFromValueBuilder
removeAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<FlowModAddMatchFromValue>> augmentationType)
Remove an augmentation from this builder's product.FlowModAddMatchFromValueBuilder
setFlowModNumBits(Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetFlowModNumBits(Uint16)
instead.FlowModAddMatchFromValueBuilder
setFlowModNumBits(org.opendaylight.yangtools.yang.common.Uint16 value)
FlowModAddMatchFromValueBuilder
setSrcField(Long value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetSrcField(Uint32)
instead.FlowModAddMatchFromValueBuilder
setSrcField(org.opendaylight.yangtools.yang.common.Uint32 value)
FlowModAddMatchFromValueBuilder
setSrcOfs(Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetSrcOfs(Uint16)
instead.FlowModAddMatchFromValueBuilder
setSrcOfs(org.opendaylight.yangtools.yang.common.Uint16 value)
FlowModAddMatchFromValueBuilder
setValue(Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetValue(Uint16)
instead.FlowModAddMatchFromValueBuilder
setValue(org.opendaylight.yangtools.yang.common.Uint16 value)
-
-
-
Constructor Detail
-
FlowModAddMatchFromValueBuilder
public FlowModAddMatchFromValueBuilder()
-
FlowModAddMatchFromValueBuilder
public FlowModAddMatchFromValueBuilder(FlowModAddMatchFromValue base)
-
-
Method Detail
-
getFlowModNumBits
public org.opendaylight.yangtools.yang.common.Uint16 getFlowModNumBits()
-
getSrcField
public org.opendaylight.yangtools.yang.common.Uint32 getSrcField()
-
getSrcOfs
public org.opendaylight.yangtools.yang.common.Uint16 getSrcOfs()
-
getValue
public org.opendaylight.yangtools.yang.common.Uint16 getValue()
-
augmentation
public <E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<FlowModAddMatchFromValue>> E$$ augmentation(Class<E$$> augmentationType)
-
setFlowModNumBits
public FlowModAddMatchFromValueBuilder setFlowModNumBits(org.opendaylight.yangtools.yang.common.Uint16 value)
-
setFlowModNumBits
@Deprecated(forRemoval=true) public FlowModAddMatchFromValueBuilder setFlowModNumBits(Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetFlowModNumBits(Uint16)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setSrcField
public FlowModAddMatchFromValueBuilder setSrcField(org.opendaylight.yangtools.yang.common.Uint32 value)
-
setSrcField
@Deprecated(forRemoval=true) public FlowModAddMatchFromValueBuilder setSrcField(Long value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetSrcField(Uint32)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setSrcOfs
public FlowModAddMatchFromValueBuilder setSrcOfs(org.opendaylight.yangtools.yang.common.Uint16 value)
-
setSrcOfs
@Deprecated(forRemoval=true) public FlowModAddMatchFromValueBuilder setSrcOfs(Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetSrcOfs(Uint16)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setValue
public FlowModAddMatchFromValueBuilder setValue(org.opendaylight.yangtools.yang.common.Uint16 value)
-
setValue
@Deprecated(forRemoval=true) public FlowModAddMatchFromValueBuilder setValue(Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetValue(Uint16)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
addAugmentation
public FlowModAddMatchFromValueBuilder addAugmentation(org.opendaylight.yangtools.yang.binding.Augmentation<FlowModAddMatchFromValue> 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 FlowModAddMatchFromValueBuilder removeAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<FlowModAddMatchFromValue>> 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
public FlowModAddMatchFromValue build()
- Specified by:
build
in interfaceorg.opendaylight.yangtools.concepts.Builder<FlowModAddMatchFromValue>
- Specified by:
build
in interfaceorg.opendaylight.yangtools.concepts.CheckedBuilder<FlowModAddMatchFromValue,IllegalArgumentException>
-
-