public class OfBuilder extends Object implements org.opendaylight.yangtools.concepts.Builder<Of>
OfBuilder 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:
OfBuilder createTarget(int fooXyzzy, int barBaz) {
return new OfBuilderBuilder()
.setFoo(new FooBuilder().setXyzzy(fooXyzzy).build())
.setBar(new BarBuilder().setBaz(barBaz).build())
.build();
}
This pattern is supported by the immutable nature of OfBuilder, as instances can be freely passed around without worrying about synchronization issues.
As a side note: method chaining results in:
build(), which is then returned from the methodOfBuilder,
Builder| Constructor and Description |
|---|
OfBuilder() |
OfBuilder(Object arg) |
OfBuilder(ObjectHeader arg) |
OfBuilder(Of base) |
| Modifier and Type | Method and Description |
|---|---|
OfBuilder |
addAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<Of>> augmentationType,
org.opendaylight.yangtools.yang.binding.Augmentation<Of> augmentationValue) |
<E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<Of>> |
augmentation(Class<E$$> augmentationType) |
Of |
build() |
void |
fieldsFrom(org.opendaylight.yangtools.yang.binding.DataObject arg)
Set fields from given grouping argument.
|
OfId |
getCode() |
Tlvs |
getTlvs() |
Boolean |
isIgnore() |
Boolean |
isProcessingRule() |
OfBuilder |
removeAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<Of>> augmentationType) |
OfBuilder |
setCode(OfId value) |
OfBuilder |
setIgnore(Boolean value) |
OfBuilder |
setProcessingRule(Boolean value) |
OfBuilder |
setTlvs(Tlvs value) |
public OfBuilder()
public OfBuilder(Object arg)
public OfBuilder(ObjectHeader arg)
public OfBuilder(Of base)
public void fieldsFrom(org.opendaylight.yangtools.yang.binding.DataObject arg)
arg - grouping objectIllegalArgumentException - if given argument is none of valid typespublic OfId getCode()
public Tlvs getTlvs()
public Boolean isIgnore()
public Boolean isProcessingRule()
public <E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<Of>> E$$ augmentation(Class<E$$> augmentationType)
public OfBuilder addAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<Of>> augmentationType, org.opendaylight.yangtools.yang.binding.Augmentation<Of> augmentationValue)
public OfBuilder removeAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<Of>> augmentationType)
public Of build()
build in interface org.opendaylight.yangtools.concepts.CheckedBuilder<Of,IllegalArgumentException>Copyright © 2020 OpenDaylight. All rights reserved.