Class NeighborAdvertisePacketBuilder
- java.lang.Object
-
- org.opendaylight.yang.gen.v1.urn.opendaylight.genius.ipv6.nd.packet.rev160620.NeighborAdvertisePacketBuilder
-
- All Implemented Interfaces:
org.opendaylight.yangtools.concepts.Builder<NeighborAdvertisePacket>
,org.opendaylight.yangtools.concepts.CheckedBuilder<NeighborAdvertisePacket,java.lang.IllegalArgumentException>
,org.opendaylight.yangtools.concepts.Mutable
,org.opendaylight.yangtools.concepts.MutationBehaviour<org.opendaylight.yangtools.concepts.Mutable>
@Generated("mdsal-binding-generator") public class NeighborAdvertisePacketBuilder extends java.lang.Object implements org.opendaylight.yangtools.concepts.Builder<NeighborAdvertisePacket>
Class that buildsNeighborAdvertisePacketBuilder
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:
NeighborAdvertisePacketBuilder createTarget(int fooXyzzy, int barBaz) { return new NeighborAdvertisePacketBuilderBuilder() .setFoo(new FooBuilder().setXyzzy(fooXyzzy).build()) .setBar(new BarBuilder().setBaz(barBaz).build()) .build(); }
This pattern is supported by the immutable nature of NeighborAdvertisePacketBuilder, as instances can be freely passed around without worrying about synchronization issues.
As a side note: method chaining results in:
- very efficient Java bytecode, as the method invocation result, in this case the Builder reference, is
on the stack, so further method invocations just need to fill method arguments for the next method
invocation, which is terminated by
build()
, which is then returned from the method - better understanding by humans, as the scope of mutable state (the builder) is kept to a minimum and is very localized
- better optimization oportunities, as the object scope is minimized in terms of invocation (rather than method) stack, making escape analysis a lot easier. Given enough compiler (JIT/AOT) prowess, the cost of th builder object can be completely eliminated
- See Also:
NeighborAdvertisePacketBuilder
,Builder
-
-
Constructor Summary
Constructors Constructor Description NeighborAdvertisePacketBuilder()
NeighborAdvertisePacketBuilder(EthernetHeader arg)
NeighborAdvertisePacketBuilder(Icmp6Header arg)
NeighborAdvertisePacketBuilder(Ipv6Header arg)
NeighborAdvertisePacketBuilder(NeighborAdvertisePacket base)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description NeighborAdvertisePacketBuilder
addAugmentation(org.opendaylight.yangtools.yang.binding.Augmentation<NeighborAdvertisePacket> augmentation)
Add an augmentation to this builder's product.<E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<NeighborAdvertisePacket>>
E$$augmentation(java.lang.Class<E$$> augmentationType)
NeighborAdvertisePacket
build()
void
fieldsFrom(org.opendaylight.yangtools.yang.binding.DataObject arg)
Set fields from given grouping argument.org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address
getDestinationIpv6()
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress
getDestinationMac()
org.opendaylight.yangtools.yang.common.Uint16
getEthertype()
org.opendaylight.yangtools.yang.common.Uint32
getFlags()
org.opendaylight.yangtools.yang.common.Uint32
getFlowLabel()
org.opendaylight.yangtools.yang.common.Uint8
getHopLimit()
org.opendaylight.yangtools.yang.common.Uint16
getIcmp6Chksum()
org.opendaylight.yangtools.yang.common.Uint8
getIcmp6Code()
org.opendaylight.yangtools.yang.common.Uint8
getIcmp6Type()
org.opendaylight.yangtools.yang.common.Uint16
getIpv6Length()
org.opendaylight.yangtools.yang.common.Uint8
getNextHeader()
org.opendaylight.yangtools.yang.common.Uint8
getOptionType()
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address
getSourceIpv6()
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress
getSourceMac()
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address
getTargetAddress()
org.opendaylight.yangtools.yang.common.Uint8
getTargetAddrLength()
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress
getTargetLlAddress()
org.opendaylight.yangtools.yang.common.Uint8
getVersion()
NeighborAdvertisePacketBuilder
removeAugmentation(java.lang.Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<NeighborAdvertisePacket>> augmentationType)
Remove an augmentation from this builder's product.NeighborAdvertisePacketBuilder
setDestinationIpv6(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address value)
NeighborAdvertisePacketBuilder
setDestinationMac(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress value)
NeighborAdvertisePacketBuilder
setEthertype(java.lang.Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetEthertype(Uint16)
instead.NeighborAdvertisePacketBuilder
setEthertype(org.opendaylight.yangtools.yang.common.Uint16 value)
NeighborAdvertisePacketBuilder
setFlags(java.lang.Long value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetFlags(Uint32)
instead.NeighborAdvertisePacketBuilder
setFlags(org.opendaylight.yangtools.yang.common.Uint32 value)
NeighborAdvertisePacketBuilder
setFlowLabel(java.lang.Long value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetFlowLabel(Uint32)
instead.NeighborAdvertisePacketBuilder
setFlowLabel(org.opendaylight.yangtools.yang.common.Uint32 value)
NeighborAdvertisePacketBuilder
setHopLimit(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetHopLimit(Uint8)
instead.NeighborAdvertisePacketBuilder
setHopLimit(org.opendaylight.yangtools.yang.common.Uint8 value)
NeighborAdvertisePacketBuilder
setIcmp6Chksum(java.lang.Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetIcmp6Chksum(Uint16)
instead.NeighborAdvertisePacketBuilder
setIcmp6Chksum(org.opendaylight.yangtools.yang.common.Uint16 value)
NeighborAdvertisePacketBuilder
setIcmp6Code(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetIcmp6Code(Uint8)
instead.NeighborAdvertisePacketBuilder
setIcmp6Code(org.opendaylight.yangtools.yang.common.Uint8 value)
NeighborAdvertisePacketBuilder
setIcmp6Type(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetIcmp6Type(Uint8)
instead.NeighborAdvertisePacketBuilder
setIcmp6Type(org.opendaylight.yangtools.yang.common.Uint8 value)
NeighborAdvertisePacketBuilder
setIpv6Length(java.lang.Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetIpv6Length(Uint16)
instead.NeighborAdvertisePacketBuilder
setIpv6Length(org.opendaylight.yangtools.yang.common.Uint16 value)
NeighborAdvertisePacketBuilder
setNextHeader(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetNextHeader(Uint8)
instead.NeighborAdvertisePacketBuilder
setNextHeader(org.opendaylight.yangtools.yang.common.Uint8 value)
NeighborAdvertisePacketBuilder
setOptionType(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetOptionType(Uint8)
instead.NeighborAdvertisePacketBuilder
setOptionType(org.opendaylight.yangtools.yang.common.Uint8 value)
NeighborAdvertisePacketBuilder
setSourceIpv6(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address value)
NeighborAdvertisePacketBuilder
setSourceMac(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress value)
NeighborAdvertisePacketBuilder
setTargetAddress(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address value)
NeighborAdvertisePacketBuilder
setTargetAddrLength(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetTargetAddrLength(Uint8)
instead.NeighborAdvertisePacketBuilder
setTargetAddrLength(org.opendaylight.yangtools.yang.common.Uint8 value)
NeighborAdvertisePacketBuilder
setTargetLlAddress(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress value)
NeighborAdvertisePacketBuilder
setVersion(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetVersion(Uint8)
instead.NeighborAdvertisePacketBuilder
setVersion(org.opendaylight.yangtools.yang.common.Uint8 value)
-
-
-
Constructor Detail
-
NeighborAdvertisePacketBuilder
public NeighborAdvertisePacketBuilder()
-
NeighborAdvertisePacketBuilder
public NeighborAdvertisePacketBuilder(EthernetHeader arg)
-
NeighborAdvertisePacketBuilder
public NeighborAdvertisePacketBuilder(Ipv6Header arg)
-
NeighborAdvertisePacketBuilder
public NeighborAdvertisePacketBuilder(Icmp6Header arg)
-
NeighborAdvertisePacketBuilder
public NeighborAdvertisePacketBuilder(NeighborAdvertisePacket base)
-
-
Method Detail
-
fieldsFrom
public void fieldsFrom(org.opendaylight.yangtools.yang.binding.DataObject arg)
Set fields from given grouping argument. Valid argument is instance of one of following types:- org.opendaylight.yang.gen.v1.urn.opendaylight.genius.ipv6.nd.packet.rev160620.EthernetHeader
- org.opendaylight.yang.gen.v1.urn.opendaylight.genius.ipv6.nd.packet.rev160620.Icmp6Header
- org.opendaylight.yang.gen.v1.urn.opendaylight.genius.ipv6.nd.packet.rev160620.Ipv6Header
- Parameters:
arg
- grouping object- Throws:
java.lang.IllegalArgumentException
- if given argument is none of valid types or has property with incompatible value
-
getDestinationIpv6
public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address getDestinationIpv6()
-
getDestinationMac
public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress getDestinationMac()
-
getEthertype
public org.opendaylight.yangtools.yang.common.Uint16 getEthertype()
-
getFlags
public org.opendaylight.yangtools.yang.common.Uint32 getFlags()
-
getFlowLabel
public org.opendaylight.yangtools.yang.common.Uint32 getFlowLabel()
-
getHopLimit
public org.opendaylight.yangtools.yang.common.Uint8 getHopLimit()
-
getIcmp6Chksum
public org.opendaylight.yangtools.yang.common.Uint16 getIcmp6Chksum()
-
getIcmp6Code
public org.opendaylight.yangtools.yang.common.Uint8 getIcmp6Code()
-
getIcmp6Type
public org.opendaylight.yangtools.yang.common.Uint8 getIcmp6Type()
-
getIpv6Length
public org.opendaylight.yangtools.yang.common.Uint16 getIpv6Length()
-
getNextHeader
public org.opendaylight.yangtools.yang.common.Uint8 getNextHeader()
-
getOptionType
public org.opendaylight.yangtools.yang.common.Uint8 getOptionType()
-
getSourceIpv6
public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address getSourceIpv6()
-
getSourceMac
public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress getSourceMac()
-
getTargetAddrLength
public org.opendaylight.yangtools.yang.common.Uint8 getTargetAddrLength()
-
getTargetAddress
public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address getTargetAddress()
-
getTargetLlAddress
public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress getTargetLlAddress()
-
getVersion
public org.opendaylight.yangtools.yang.common.Uint8 getVersion()
-
augmentation
public <E$$ extends org.opendaylight.yangtools.yang.binding.Augmentation<NeighborAdvertisePacket>> E$$ augmentation(java.lang.Class<E$$> augmentationType)
-
setDestinationIpv6
public NeighborAdvertisePacketBuilder setDestinationIpv6(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address value)
-
setDestinationMac
public NeighborAdvertisePacketBuilder setDestinationMac(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress value)
-
setEthertype
public NeighborAdvertisePacketBuilder setEthertype(org.opendaylight.yangtools.yang.common.Uint16 value)
-
setEthertype
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setEthertype(java.lang.Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetEthertype(Uint16)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setFlags
public NeighborAdvertisePacketBuilder setFlags(org.opendaylight.yangtools.yang.common.Uint32 value)
-
setFlags
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setFlags(java.lang.Long value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetFlags(Uint32)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setFlowLabel
public NeighborAdvertisePacketBuilder setFlowLabel(org.opendaylight.yangtools.yang.common.Uint32 value)
-
setFlowLabel
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setFlowLabel(java.lang.Long value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetFlowLabel(Uint32)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setHopLimit
public NeighborAdvertisePacketBuilder setHopLimit(org.opendaylight.yangtools.yang.common.Uint8 value)
-
setHopLimit
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setHopLimit(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetHopLimit(Uint8)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setIcmp6Chksum
public NeighborAdvertisePacketBuilder setIcmp6Chksum(org.opendaylight.yangtools.yang.common.Uint16 value)
-
setIcmp6Chksum
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setIcmp6Chksum(java.lang.Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetIcmp6Chksum(Uint16)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setIcmp6Code
public NeighborAdvertisePacketBuilder setIcmp6Code(org.opendaylight.yangtools.yang.common.Uint8 value)
-
setIcmp6Code
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setIcmp6Code(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetIcmp6Code(Uint8)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setIcmp6Type
public NeighborAdvertisePacketBuilder setIcmp6Type(org.opendaylight.yangtools.yang.common.Uint8 value)
-
setIcmp6Type
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setIcmp6Type(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetIcmp6Type(Uint8)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setIpv6Length
public NeighborAdvertisePacketBuilder setIpv6Length(org.opendaylight.yangtools.yang.common.Uint16 value)
-
setIpv6Length
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setIpv6Length(java.lang.Integer value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetIpv6Length(Uint16)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setNextHeader
public NeighborAdvertisePacketBuilder setNextHeader(org.opendaylight.yangtools.yang.common.Uint8 value)
-
setNextHeader
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setNextHeader(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetNextHeader(Uint8)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setOptionType
public NeighborAdvertisePacketBuilder setOptionType(org.opendaylight.yangtools.yang.common.Uint8 value)
-
setOptionType
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setOptionType(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetOptionType(Uint8)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setSourceIpv6
public NeighborAdvertisePacketBuilder setSourceIpv6(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address value)
-
setSourceMac
public NeighborAdvertisePacketBuilder setSourceMac(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress value)
-
setTargetAddrLength
public NeighborAdvertisePacketBuilder setTargetAddrLength(org.opendaylight.yangtools.yang.common.Uint8 value)
-
setTargetAddrLength
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setTargetAddrLength(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetTargetAddrLength(Uint8)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
setTargetAddress
public NeighborAdvertisePacketBuilder setTargetAddress(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address value)
-
setTargetLlAddress
public NeighborAdvertisePacketBuilder setTargetLlAddress(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.MacAddress value)
-
setVersion
public NeighborAdvertisePacketBuilder setVersion(org.opendaylight.yangtools.yang.common.Uint8 value)
-
setVersion
@Deprecated(forRemoval=true) public NeighborAdvertisePacketBuilder setVersion(java.lang.Short value)
Deprecated, for removal: This API element is subject to removal in a future version.UsesetVersion(Uint8)
instead.Utility migration setter.- Parameters:
value
- field value in legacy type- Returns:
- this builder
-
addAugmentation
public NeighborAdvertisePacketBuilder addAugmentation(org.opendaylight.yangtools.yang.binding.Augmentation<NeighborAdvertisePacket> augmentation)
Add an augmentation to this builder's product.- Parameters:
augmentation
- augmentation to be added- Returns:
- this builder
- Throws:
java.lang.NullPointerException
- ifaugmentation
is null
-
removeAugmentation
public NeighborAdvertisePacketBuilder removeAugmentation(java.lang.Class<? extends org.opendaylight.yangtools.yang.binding.Augmentation<NeighborAdvertisePacket>> augmentationType)
Remove an augmentation from this builder's product. If this builder does not track such an augmentation type, this method does nothing.- Parameters:
augmentationType
- augmentation type to be removed- Returns:
- this builder
-
build
public NeighborAdvertisePacket build()
- Specified by:
build
in interfaceorg.opendaylight.yangtools.concepts.Builder<NeighborAdvertisePacket>
- Specified by:
build
in interfaceorg.opendaylight.yangtools.concepts.CheckedBuilder<NeighborAdvertisePacket,java.lang.IllegalArgumentException>
-
-