Enum Class FeeLeg
- All Implemented Interfaces:
Serializable, Comparable<FeeLeg>, Constable
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe fee is always charged in the BASE asset on both sides.The fee is always charged in the QUOTE asset on both sides (amount * price * rate) — the convention for perpetual/derivatives venues (USDT-settled) and for simplified cash-PnL backtests.Default. -
Method Summary
-
Enum Constant Details
-
RECEIVED
Default. The fee is charged in the asset the fill receives: a BUY pays its fee in the BASE asset (you receive slightly less base —amount * rate), a SELL in the QUOTE asset (amount * price * rate). This is the everyday spot mechanic (Binance, Coinbase) and the canonical default the conformance fixtures encode. -
QUOTE
The fee is always charged in the QUOTE asset on both sides (amount * price * rate) — the convention for perpetual/derivatives venues (USDT-settled) and for simplified cash-PnL backtests. -
BASE
The fee is always charged in the BASE asset on both sides. RESERVED: no real venue charges spot fees this way, so it is not implemented — selecting it throws until a concrete need appears (kept as an enum slot so the contract is closed and forward-compatible).
-
-
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
-