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 long
NO_SEGMENT_ID
Denotes 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 VersionImpl
asImpl()
Returns the actual instance.protected boolean
canEqual(java.lang.Object other)
boolean
equals(java.lang.Object o)
static VersionImpl
fromString(java.lang.String str)
Deserializes theVersionImpl
from its serialized form obtained from callingtoString()
.long
getSegmentVersion()
The internal version inside the Table Segment for this Key.int
hashCode()
java.lang.String
toString()
Serializes theVersion
to 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:Version
Returns the actual instance. This method prevents other classes from implementing this interface.
-
toString
public java.lang.String toString()
Description copied from interface:Version
Serializes theVersion
to a human readable string.
-
fromString
public static VersionImpl fromString(java.lang.String str)
Deserializes theVersionImpl
from its serialized form obtained from callingtoString()
.- Parameters:
str
- A serializedVersionImpl
.- Returns:
- The
VersionImpl
object.
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
canEqual
protected boolean canEqual(java.lang.Object other)
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-