Package nxt.account
Enum Class AccountLedger.LedgerHolding
- All Implemented Interfaces:
Serializable,Comparable<AccountLedger.LedgerHolding>,Constable
- Enclosing class:
- AccountLedger
Ledger holdings
When adding a new holding, do not change the existing code assignments since
they are stored in the holding_type field of the account_ledger table.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescription -
Method Summary
Modifier and TypeMethodDescriptionstatic AccountLedger.LedgerHoldingfromCode(int code) Get the holding from the holding codeintgetCode()Return the holding codeabstract HoldingTypeThe HoldingType for this LedgerHoldingbooleanCheck if the holding is unconfirmedstatic AccountLedger.LedgerHoldingReturns the enum constant of this class with the specified name.static AccountLedger.LedgerHolding[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
UNCONFIRMED_COIN_BALANCE
-
COIN_BALANCE
-
UNCONFIRMED_ASSET_BALANCE
-
ASSET_BALANCE
-
UNCONFIRMED_CURRENCY_BALANCE
-
CURRENCY_BALANCE
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
isUnconfirmed
public boolean isUnconfirmed()Check if the holding is unconfirmed- Returns:
- TRUE if the holding is unconfirmed
-
getCode
public int getCode()Return the holding code- Returns:
- Holding code
-
getHoldingType
The HoldingType for this LedgerHolding- Returns:
- HoldingType
-
fromCode
Get the holding from the holding code- Parameters:
code- Holding code- Returns:
- Holding
-