Package io.debezium.connector.oracle
Class Scn
java.lang.Object
io.debezium.connector.oracle.Scn
- All Implemented Interfaces:
Comparable<Scn>
Oracle System Change Number implementation
- Author:
- Chris Cranford
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ScnRepresents an Scn that implies the maximum possible value of an SCN, useful as a placeholder.static final ScnRepresents an Scn without a value.static final ScnRepresents an Scn with value 1, useful for playing with inclusive/exclusive query boundaries.private final BigInteger -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns aSCnwhose value is(this + value).intCompares thisScnwith the specifiedScn.booleaninthashCode()booleanisNull()Returns whether thisScnis null and contains no value.longGet the Scn represented as alongdata type.Returns aScnwhose value is(this - value).toString()static ScnvalueOf(int value) Construct aScnfrom an integer value.static ScnvalueOf(long value) Construct aScnfrom a long value.static ScnConstruct aScnfrom a string value.
-
Field Details
-
MAX
Represents an Scn that implies the maximum possible value of an SCN, useful as a placeholder. -
NULL
Represents an Scn without a value. -
ONE
Represents an Scn with value 1, useful for playing with inclusive/exclusive query boundaries. -
scn
-
-
Constructor Details
-
Scn
-
-
Method Details
-
isNull
public boolean isNull()Returns whether thisScnis null and contains no value. -
valueOf
Construct aScnfrom an integer value.- Parameters:
value- integer value- Returns:
- instance of Scn
-
valueOf
Construct aScnfrom a long value.- Parameters:
value- long value- Returns:
- instance of Scn
-
valueOf
Construct aScnfrom a string value.- Parameters:
value- string value, should not be null- Returns:
- instance of Scn
-
longValue
public long longValue()Get the Scn represented as alongdata type. -
add
Returns aSCnwhose value is(this + value).- Parameters:
value- the value to be added to thisScn.- Returns:
this + value
-
subtract
Returns aScnwhose value is(this - value).- Parameters:
value- the value to be subtracted from thisScn.- Returns:
this - value
-
compareTo
Compares thisScnwith the specifiedScn.- Specified by:
compareToin interfaceComparable<Scn>- Parameters:
o-Scnto which thisScnis to be compared- Returns:
- -1, 0, or 1 as this {code Scn} is numerically less than, equal to, or greater than
o.
-
equals
-
hashCode
public int hashCode() -
toString
-