public class TOID
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
TOID.TOIDRange |
Constructor and Description |
---|
TOID(int ledgerSequence,
int transactionOrder,
int operationIndex)
Constructor for TOID.
|
Modifier and Type | Method and Description |
---|---|
static TOID |
afterLedger(int ledgerSequence)
Creates a new TOID that represents the ledger time **after** any contents (e.g.
|
boolean |
equals(java.lang.Object o) |
static TOID |
fromInt64(long value)
Converts a signed 64-bit integer to a TOID.
|
int |
getLedgerSequence() |
int |
getOperationIndex() |
int |
getTransactionOrder() |
int |
hashCode() |
void |
incrementOperationIndex()
Increments the operation order by 1, rolling over to the next ledger if overflow occurs.
|
static TOID.TOIDRange |
ledgerRangeInclusive(int from,
int to)
The inclusive range representation between two ledgers inclusive.
|
long |
toInt64()
Converts the TOID to a signed 64-bit integer.
|
java.lang.String |
toString() |
public TOID(int ledgerSequence, int transactionOrder, int operationIndex)
ledgerSequence
- The ledger sequence the operation was validated in.transactionOrder
- The order that the transaction was applied within the ledger where it
was validated. The application order value starts at 1. The maximum supported number of
transactions per operation is 1,048,575.operationIndex
- The index of the operation within that parent transaction. The operation
index value starts at 1. The maximum supported number of operations per transaction is
4095.public long toInt64()
public static TOID fromInt64(long value)
value
- The signed 64-bit integer to convert.public void incrementOperationIndex()
public static TOID afterLedger(int ledgerSequence)
ledgerSequence
- The ledger sequence.public static TOID.TOIDRange ledgerRangeInclusive(int from, int to)
from
- The start ledger sequence.to
- The end ledger sequence.public int getLedgerSequence()
public int getTransactionOrder()
public int getOperationIndex()
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object