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