PropsLibrary
minProfitTime
Wait before trades can be cashed out with < minProfit
function minProfitTime(struct PropsSchema schema) internal view returns (uint256)
setMinProfitTime
function setMinProfitTime(struct PropsSchema schema, uint256 value) internal
minMargin
Minimum margin increment.
function minMargin(struct PropsSchema schema) internal view returns (uint256)
Dev note
Prevents the creation of very small positions, which would be unprofitable to liquidate after gas fees.
setMinMargin
function setMinMargin(struct PropsSchema schema, uint256 value) internal
maxShift
function maxShift(struct PropsSchema schema) internal view returns (FPUnsigned)
Dev note
scaling factor for price shift that balances long and short exposure
setMaxShift
function setMaxShift(struct PropsSchema schema, FPUnsigned value) internal
helpfulShiftScaler
function helpfulShiftScaler(struct PropsSchema schema) internal view returns (FPUnsigned)
Dev note
scale price shift to 1/3 (giving more favorable prices) for orders that reduce net exposure
setHelpfulShiftScalar
function setHelpfulShiftScalar(struct PropsSchema schema, FPUnsigned value) internal
isTradeEnabled
function isTradeEnabled(struct PropsSchema schema) internal view returns (bool)
setTradeEnabled
function setTradeEnabled(struct PropsSchema schema, bool value) internal
maxPositionProfit
max profit as multiple of margin. default 900%
function maxPositionProfit(struct PropsSchema schema) internal view returns (FPUnsigned)
setMaxPositionProfit
function setMaxPositionProfit(struct PropsSchema schema, FPUnsigned value) internal
utilizationMultiplier
Total open interest (long + short) is limited to 10x the vault balance.
function utilizationMultiplier(struct PropsSchema schema) internal view returns (FPUnsigned)
setUtilizationMultiplier
function setUtilizationMultiplier(struct PropsSchema schema, FPUnsigned value) internal
maxExposureMultiplier
Open interest of a product is limited to 3x its proportional share of getMaxExposure().
function maxExposureMultiplier(struct PropsSchema schema) internal view returns (FPUnsigned)
setMaxExposureMultiplier
function setMaxExposureMultiplier(struct PropsSchema schema, FPUnsigned value) internal
isManagerOnlyForOpen
function isManagerOnlyForOpen(struct PropsSchema schema) internal view returns (bool)
setIsManagerOnlyForOpen
function setIsManagerOnlyForOpen(struct PropsSchema schema, bool value) internal
isManagerOnlyForClose
function isManagerOnlyForClose(struct PropsSchema schema) internal view returns (bool)
setIsManagerOnlyForClose
function setIsManagerOnlyForClose(struct PropsSchema schema, bool value) internal
isAllowPublicLiquidator
function isAllowPublicLiquidator(struct PropsSchema schema) internal view returns (bool)
setAllowPublicLiquidator
function setAllowPublicLiquidator(struct PropsSchema schema, bool value) internal
isLiquidator
function isLiquidator(struct PropsSchema schema, address account) internal view returns (bool)
setLiquidator
function setLiquidator(struct PropsSchema schema, address account, bool value) internal
isExchangeManager
function isExchangeManager(struct PropsSchema schema, address account) internal view returns (bool)
setExchangeManager
function setExchangeManager(struct PropsSchema schema, address account, bool value) internal
isAccountManager
function isAccountManager(
struct PropsSchema schema,
address account,
address manager
) internal view returns (
bool
)
setAccountManager
function setAccountManager(struct PropsSchema schema, address account, address manager, bool value) internal
isAuthorizedManager
function isAuthorizedManager(
struct PropsSchema schema,
address account,
address manager
) internal view returns (
bool
)
setDefaults
function setDefaults(struct PropsSchema schema) internal