Package io.pravega.client.tables.impl
Class VersionImpl
- java.lang.Object
-
- io.pravega.client.tables.impl.VersionImpl
-
- All Implemented Interfaces:
Version,java.io.Serializable
public class VersionImpl extends java.lang.Object implements Version, java.io.Serializable
Version of a Key in a Table.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static longNO_SEGMENT_IDDenotes the lack of any Segment.-
Fields inherited from interface io.pravega.client.tables.Version
NO_VERSION, NOT_EXISTS
-
-
Constructor Summary
Constructors Constructor Description VersionImpl(long segmentId, TableSegmentKeyVersion segmentVersion)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description VersionImplasImpl()Returns the actual instance.protected booleancanEqual(java.lang.Object other)booleanequals(java.lang.Object o)static VersionImplfromString(java.lang.String str)Deserializes theVersionImplfrom its serialized form obtained from callingtoString().longgetSegmentVersion()The internal version inside the Table Segment for this Key.inthashCode()java.lang.StringtoString()Serializes theVersionto a human readable string.
-
-
-
Field Detail
-
NO_SEGMENT_ID
public static final long NO_SEGMENT_ID
Denotes the lack of any Segment.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
VersionImpl
@ConstructorProperties({"segmentId","segmentVersion"}) public VersionImpl(long segmentId, TableSegmentKeyVersion segmentVersion)
-
-
Method Detail
-
getSegmentVersion
public long getSegmentVersion()
The internal version inside the Table Segment for this Key.- Returns:
- The Segment Version
-
asImpl
public VersionImpl asImpl()
Description copied from interface:VersionReturns the actual instance. This method prevents other classes from implementing this interface.
-
toString
public java.lang.String toString()
Description copied from interface:VersionSerializes theVersionto a human readable string.
-
fromString
public static VersionImpl fromString(java.lang.String str)
Deserializes theVersionImplfrom its serialized form obtained from callingtoString().- Parameters:
str- A serializedVersionImpl.- Returns:
- The
VersionImplobject.
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
canEqual
protected boolean canEqual(java.lang.Object other)
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-