mirror of
https://github.com/bisq-network/bisq.git
synced 2025-02-22 14:42:37 +01:00
Add getOptionalTakerFee and getOptionalMakerFee to Tradeable
This commit is contained in:
parent
080255ce11
commit
a5eec8c998
1 changed files with 8 additions and 0 deletions
|
@ -64,4 +64,12 @@ public interface Tradable extends PersistablePayload {
|
|||
default Optional<Coin> getOptionalTxFee() {
|
||||
return asTradeModel().map(TradeModel::getTxFee);
|
||||
}
|
||||
|
||||
default Optional<Coin> getOptionalTakerFee() {
|
||||
return asTradeModel().map(TradeModel::getTakerFee);
|
||||
}
|
||||
|
||||
default Optional<Coin> getOptionalMakerFee() {
|
||||
return asTradeModel().map(TradeModel::getMakerFee).or(() -> Optional.ofNullable(getOffer().getMakerFee()));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue