public class IfMplsBuilder extends Object implements org.opendaylight.yangtools.concepts.Builder<IfMpls>
IfMplsBuilder
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:
IfMplsBuilder createTarget(int fooXyzzy, int barBaz) {
return new IfMplsBuilderBuilder()
.setFoo(new FooBuilder().setXyzzy(fooXyzzy).build())
.setBar(new BarBuilder().setBaz(barBaz).build())
.build();
}
This pattern is supported by the immutable nature of IfMplsBuilder, 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 methodIfMplsBuilder
,
Builder
Constructor and Description |
---|
IfMplsBuilder() |
IfMplsBuilder(IfMpls base) |
Modifier and Type | Method and Description |
---|---|
IfMpls |
build() |
List<Long> |
getLabelStack() |
Short |
getNumLabels() |
IfMplsBuilder |
setLabelStack(List<Long> values) |
IfMplsBuilder |
setNumLabels(Short value) |
public IfMplsBuilder()
public IfMplsBuilder(IfMpls base)
public Short getNumLabels()
public IfMplsBuilder setLabelStack(List<Long> values)
public IfMplsBuilder setNumLabels(Short value)
public IfMpls build()
build
in interface org.opendaylight.yangtools.concepts.CheckedBuilder<IfMpls,IllegalArgumentException>
Copyright © 2019 OpenDaylight. All rights reserved.