Facilitates storing the BP binIds and ratios as immutables which avoids storage operations when minting/burning BP positions.
State Variables
_binCount
uint8 private immutable _binCount;
binIds12345678
bytes32 private immutable binIds12345678;
binIds910111213141516
bytes32 private immutable binIds910111213141516;
binIds1718192021222324
bytes32 private immutable binIds1718192021222324;
ratios12
bytes32 private immutable ratios12;
ratios34
bytes32 private immutable ratios34;
ratios56
bytes32 private immutable ratios56;
ratios78
bytes32 private immutable ratios78;
ratios910
bytes32 private immutable ratios910;
ratios1112
bytes32 private immutable ratios1112;
ratios1314
bytes32 private immutable ratios1314;
ratios1516
bytes32 private immutable ratios1516;
ratios1718
bytes32 private immutable ratios1718;
ratios1920
bytes32 private immutable ratios1920;
ratios2122
bytes32 private immutable ratios2122;
ratios2324
bytes32 private immutable ratios2324;
Functions
constructor
constructor(uint8 binCount_, bytes32[3] memory binIds, bytes32[12] memory ratios);
_getBinIds
function _getBinIds() internal view returns (uint32[] memory binIds_);
_getRatios
function _getRatios() internal view returns (uint128[] memory ratios_);
_getRatio
function _getRatio(uint256 index) private view returns (uint128 value);
_getRatioBytes
function _getRatioBytes(uint256 index) private view returns (bytes32 ratiosBytes);
_getBinId
function _getBinId(uint256 index) internal view returns (uint32 value);
_getBinIdBytes
function _getBinIdBytes(uint256 index) private view returns (bytes32 binIdBytes);
Last updated