public enum TransactionType extends Enum<TransactionType>
Enum Constant and Description |
---|
AbsoluteMajority |
Any |
None |
SimpleMajority |
SuperMajority |
Modifier and Type | Method and Description |
---|---|
boolean |
success(int size,
int successCount) |
static TransactionType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static TransactionType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final TransactionType None
public static final TransactionType Any
public static final TransactionType SimpleMajority
public static final TransactionType SuperMajority
public static final TransactionType AbsoluteMajority
public static TransactionType[] values()
for (TransactionType c : TransactionType.values()) System.out.println(c);
public static TransactionType valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic boolean success(int size, int successCount)
Copyright © 2021. All rights reserved.