org.zeroexchange.money.currency
Class AbstractCurrencyManager

java.lang.Object
  extended by org.zeroexchange.money.currency.AbstractCurrencyManager
All Implemented Interfaces:
CurrencyManager
Direct Known Subclasses:
CHECreditManager

public abstract class AbstractCurrencyManager
extends Object
implements CurrencyManager

Author:
black

Constructor Summary
AbstractCurrencyManager()
           
 
Method Summary
 BigDecimal getHourPrice(BigDecimal rate, ZECurrency currencyCode, User user)
          
 BigDecimal getHourRate(BigDecimal hourPrice, ZECurrency currencyCode, User user)
          
protected  BigDecimal getMaxRate()
           
 boolean isOutlayAllowed(ZECurrency currencyCode, User user, BigDecimal amount)
          Returns true if user is allowed outlay of the specified amount.
 void setMaxRate(BigDecimal maxRate)
           
 void setMinimalAveragePrice(BigDecimal minimalAveragePrice)
           
 void setMinRate(BigDecimal minRate)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.zeroexchange.money.currency.CurrencyManager
freeAmount, getAllowedDebt, getAvailableAmount, getSupportedCurrencyCodes, isMoneyMovementEnabled, reserveAmount, writeOn
 

Constructor Detail

AbstractCurrencyManager

public AbstractCurrencyManager()
Method Detail

setMinimalAveragePrice

public void setMinimalAveragePrice(BigDecimal minimalAveragePrice)

setMinRate

public void setMinRate(BigDecimal minRate)

setMaxRate

public void setMaxRate(BigDecimal maxRate)

getMaxRate

protected BigDecimal getMaxRate()

getHourRate

public BigDecimal getHourRate(BigDecimal hourPrice,
                              ZECurrency currencyCode,
                              User user)

Specified by:
getHourRate in interface CurrencyManager

getHourPrice

public BigDecimal getHourPrice(BigDecimal rate,
                               ZECurrency currencyCode,
                               User user)

Specified by:
getHourPrice in interface CurrencyManager

isOutlayAllowed

public boolean isOutlayAllowed(ZECurrency currencyCode,
                               User user,
                               BigDecimal amount)
Returns true if user is allowed outlay of the specified amount.

Specified by:
isOutlayAllowed in interface CurrencyManager


Copyright © 2013. All Rights Reserved.