public class DstBuilder extends Object implements org.opendaylight.yangtools.concepts.Builder<Dst>
DstBuilder
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:
DstBuilder createTarget(int fooXyzzy, int barBaz) {
return new DstBuilderBuilder()
.setFoo(new FooBuilder().setXyzzy(fooXyzzy).build())
.setBar(new BarBuilder().setBaz(barBaz).build())
.build();
}
This pattern is supported by the immutable nature of DstBuilder, 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 methodDstBuilder
,
Builder
Constructor and Description |
---|
DstBuilder() |
DstBuilder(Dst base) |
DstBuilder(DstChoiceGrouping arg) |
DstBuilder(RangeGrouping arg) |
Modifier and Type | Method and Description |
---|---|
DstBuilder |
addAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<Dst>> augmentationType,
org.opendaylight.yangtools.yang.binding.Augmentation<Dst> augmentationValue) |
<E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<Dst>> |
augmentation(Class<E$$> augmentationType) |
Dst |
build() |
void |
fieldsFrom(org.opendaylight.yangtools.yang.binding.DataObject arg)
Set fields from given grouping argument.
|
DstChoice |
getDstChoice() |
Integer |
getEnd() |
Integer |
getStart() |
DstBuilder |
removeAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<Dst>> augmentationType) |
DstBuilder |
setDstChoice(DstChoice value) |
DstBuilder |
setEnd(Integer value) |
DstBuilder |
setStart(Integer value) |
public DstBuilder()
public DstBuilder(DstChoiceGrouping arg)
public DstBuilder(RangeGrouping arg)
public DstBuilder(Dst base)
public void fieldsFrom(org.opendaylight.yangtools.yang.binding.DataObject arg)
arg
- grouping objectIllegalArgumentException
- if given argument is none of valid typespublic DstChoice getDstChoice()
public Integer getEnd()
public Integer getStart()
public <E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<Dst>> E$$ augmentation(Class<E$$> augmentationType)
public DstBuilder setDstChoice(DstChoice value)
public DstBuilder setEnd(Integer value)
public DstBuilder setStart(Integer value)
public DstBuilder addAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<Dst>> augmentationType, org.opendaylight.yangtools.yang.binding.Augmentation<Dst> augmentationValue)
public DstBuilder removeAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<Dst>> augmentationType)
public Dst build()
build
in interface org.opendaylight.yangtools.concepts.CheckedBuilder<Dst,IllegalArgumentException>
Copyright © 2020 OpenDaylight. All rights reserved.