@Beta public enum PayloadVersion extends Enum<PayloadVersion> implements org.opendaylight.yangtools.concepts.WritableObject
This version effectively defines the protocol version between actors participating on a particular shard. A shard participant instance should oppose RAFT candidates which produce persistence of an unsupported version. If a follower encounters an unsupported version it must not become fully-operational, as it does not have an accurate view of shard state.
| Enum Constant and Description | 
|---|
| BORONInitial ABI version, as shipped with Boron Simultaneous release. | 
| NEON_SR2Revised payload version. | 
| TEST_FUTURE_VERSIONVersion which is newer than any other version. | 
| TEST_PAST_VERSIONVersion which is older than any other version. | 
| Modifier and Type | Method and Description | 
|---|---|
| static PayloadVersion | current()Return the codebase-native persistence version. | 
| abstract NormalizedNodeStreamVersion | getStreamVersion()Return the NormalizedNode stream version corresponding to this particular ABI. | 
| static PayloadVersion | readFrom(DataInput in)Read an  PayloadVersionfrom aDataInput. | 
| short | shortValue()Return the unsigned short integer identifying this version. | 
| static PayloadVersion | valueOf(short version)Return the  PayloadVersioncorresponding to an unsigned short integer. | 
| static PayloadVersion | valueOf(String name)Returns the enum constant of this type with the specified name. | 
| static PayloadVersion[] | values()Returns an array containing the constants of this enum type, in
the order they are declared. | 
| void | writeTo(DataOutput out) | 
public static final PayloadVersion TEST_PAST_VERSION
public static final PayloadVersion BORON
public static final PayloadVersion NEON_SR2
BORON, but messages bearing QNames in any shape
 are using NormalizedNodeStreamVersion.NEON_SR2, which improves encoding.public static final PayloadVersion TEST_FUTURE_VERSION
public static PayloadVersion[] values()
for (PayloadVersion c : PayloadVersion.values()) System.out.println(c);
public static PayloadVersion valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic short shortValue()
@Nonnull public abstract NormalizedNodeStreamVersion getStreamVersion()
@Nonnull public static PayloadVersion current()
PayloadVersion@Nonnull public static PayloadVersion valueOf(short version) throws FutureVersionException, PastVersionException
PayloadVersion corresponding to an unsigned short integer. This method is provided for callers
 which provide their own recovery strategy in case of version incompatibility.version - Short integer as returned from shortValue()PayloadVersionFutureVersionException - if the specified integer identifies a future versionPastVersionException - if the specified integer identifies a past version which is no longer supportedpublic void writeTo(DataOutput out) throws IOException
writeTo in interface org.opendaylight.yangtools.concepts.WritableObjectIOException@Nonnull public static PayloadVersion readFrom(@Nonnull DataInput in) throws IOException
PayloadVersion from a DataInput. This method is provided for callers which do not have
 a recovery strategy for dealing with unsupported versions.in - Input from which to readPayloadVersionIOException - If read fails or an unsupported version is encounteredCopyright © 2019 OpenDaylight. All rights reserved.