public class PacketInMessageBuilder extends Object implements org.opendaylight.yangtools.concepts.Builder<PacketInMessage>
PacketInMessageBuilder
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:
PacketInMessageBuilder createTarget(int fooXyzzy, int barBaz) {
return new PacketInMessageBuilderBuilder()
.setFoo(new FooBuilder().setXyzzy(fooXyzzy).build())
.setBar(new BarBuilder().setBaz(barBaz).build())
.build();
}
This pattern is supported by the immutable nature of PacketInMessageBuilder, 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 methodPacketInMessageBuilder
,
Builder
Constructor and Description |
---|
PacketInMessageBuilder() |
PacketInMessageBuilder(OfHeader arg) |
PacketInMessageBuilder(PacketIn arg) |
PacketInMessageBuilder(PacketInMessage base) |
PacketInMessageBuilder(RawPacket arg) |
Modifier and Type | Method and Description |
---|---|
PacketInMessageBuilder |
addAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<PacketInMessage>> augmentationType,
org.opendaylight.yangtools.yang.binding.Augmentation<PacketInMessage> augmentationValue) |
<E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<PacketInMessage>> |
augmentation(Class<E$$> augmentationType) |
PacketInMessage |
build() |
void |
fieldsFrom(org.opendaylight.yangtools.yang.binding.DataObject arg)
Set fields from given grouping argument.
|
ConnectionCookie |
getConnectionCookie() |
FlowCookie |
getFlowCookie() |
org.opendaylight.yang.gen.v1.urn.opendaylight.inventory.rev130819.NodeConnectorRef |
getIngress() |
Match |
getMatch() |
Class<? extends PacketInReason> |
getPacketInReason() |
byte[] |
getPayload() |
TableId |
getTableId() |
Short |
getVersion() |
Long |
getXid() |
PacketInMessageBuilder |
removeAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<PacketInMessage>> augmentationType) |
PacketInMessageBuilder |
setConnectionCookie(ConnectionCookie value) |
PacketInMessageBuilder |
setFlowCookie(FlowCookie value) |
PacketInMessageBuilder |
setIngress(org.opendaylight.yang.gen.v1.urn.opendaylight.inventory.rev130819.NodeConnectorRef value) |
PacketInMessageBuilder |
setMatch(Match value) |
PacketInMessageBuilder |
setPacketInReason(Class<? extends PacketInReason> value) |
PacketInMessageBuilder |
setPayload(byte[] value) |
PacketInMessageBuilder |
setTableId(TableId value) |
PacketInMessageBuilder |
setVersion(Short value) |
PacketInMessageBuilder |
setXid(Long value) |
public PacketInMessageBuilder()
public PacketInMessageBuilder(PacketIn arg)
public PacketInMessageBuilder(RawPacket arg)
public PacketInMessageBuilder(OfHeader arg)
public PacketInMessageBuilder(PacketInMessage base)
public void fieldsFrom(org.opendaylight.yangtools.yang.binding.DataObject arg)
arg
- grouping objectIllegalArgumentException
- if given argument is none of valid typespublic ConnectionCookie getConnectionCookie()
public FlowCookie getFlowCookie()
public org.opendaylight.yang.gen.v1.urn.opendaylight.inventory.rev130819.NodeConnectorRef getIngress()
public Match getMatch()
public Class<? extends PacketInReason> getPacketInReason()
public byte[] getPayload()
public TableId getTableId()
public Short getVersion()
public Long getXid()
public <E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<PacketInMessage>> E$$ augmentation(Class<E$$> augmentationType)
public PacketInMessageBuilder setConnectionCookie(ConnectionCookie value)
public PacketInMessageBuilder setFlowCookie(FlowCookie value)
public PacketInMessageBuilder setIngress(org.opendaylight.yang.gen.v1.urn.opendaylight.inventory.rev130819.NodeConnectorRef value)
public PacketInMessageBuilder setMatch(Match value)
public PacketInMessageBuilder setPacketInReason(Class<? extends PacketInReason> value)
public PacketInMessageBuilder setPayload(byte[] value)
public PacketInMessageBuilder setTableId(TableId value)
public PacketInMessageBuilder setVersion(Short value)
public PacketInMessageBuilder setXid(Long value)
public PacketInMessageBuilder addAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<PacketInMessage>> augmentationType, org.opendaylight.yangtools.yang.binding.Augmentation<PacketInMessage> augmentationValue)
public PacketInMessageBuilder removeAugmentation(Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<PacketInMessage>> augmentationType)
public PacketInMessage build()
build
in interface org.opendaylight.yangtools.concepts.CheckedBuilder<PacketInMessage,IllegalArgumentException>
Copyright © 2020 OpenDaylight. All rights reserved.