MoCBucketContainer
View Source: contracts/MoCBucketContainer.sol
↗ Extends: MoCBase, Governed ↘ Derived Contracts: MoCBProxManager
MoCBucketContainer - version: 0.1.12
Structs
BProxBalance
⚠ This has been deprecated since the Proposal to remove leveraged positions from the protocol was approved, however it is necessary to maintain the contracts and their documentation for legacy support.
MoCBucket
Contract Members
Constants & Variables
BucketMovement
Parameters
from
bytes32
to
bytes32
reserves
uint256
stableTokens
uint256
BucketCreation
Parameters
name
bytes32
cobj
uint256
BucketStateUpdate
Parameters
name
bytes32
nReserve
uint256
nStable
uint256
nRiskProx
uint256
inrateBag
uint256
Modifiers
onlyBaseBucket
Arguments
bucket
bytes32
bucketStateUpdate
Arguments
bucket
bytes32
Functions
getBucketNBTC
Arguments
bucket
bytes32
getBucketNBPro
Arguments
bucket
bytes32
getBucketNDoc
Arguments
bucket
bytes32
getBucketCobj
Arguments
bucket
bytes32
getInrateBag
Arguments
bucket
bytes32
setBucketCobj
Sets the objective coverage (cobj) on an specficied bucket.
Arguments
_bucket
bytes32
_cobj
uint256
isBucketBase
returns true if the bucket is a base bucket
Arguments
bucket
bytes32
Name of the bucket
isBucketEmpty
returns true if the bucket have docs in it
Arguments
bucket
bytes32
Name of the bucket
getActiveAddresses
Returns all the address that currently have bprox position for this bucket
Arguments
bucket
bytes32
bucket of the active address
getActiveAddressesCount
Returns all the address that currently have bprox position for this bucket
Arguments
bucket
bytes32
bucket of the active address
addValuesToBucket
Add values to all variables of the bucket
Arguments
bucketName
bytes32
Name of the bucket
btc
uint256
BTC amount [using reservePrecision]
doc
uint256
Doc amount [using mocPrecision]
bprox
uint256
BPro amount [using mocPrecision]
substractValuesFromBucket
Substract values to all variables of the bucket
Arguments
bucketName
bytes32
Name of the bucket
btc
uint256
BTC amount [using reservePrecision]
doc
uint256
Doc amount [using mocPrecision]
bprox
uint256
BPro amount [using mocPrecision]
deliverInrate
Moves BTC from inrateBag to main BTC bucket bag
Arguments
bucketName
bytes32
Name of the bucket to operate
amount
uint256
value to move from inrateBag to main bag [using reservePrecision]
recoverInrate
Removes Interests rate from Inrate bag
Returns
Retrieved value
Arguments
bucketName
bytes32
Name of the bucket to operate
amount
uint256
value to move from inrateBag to main bag [using reservePrecision]
payInrate
Moves BTC from origin bucket to destination bucket inrateBag
Arguments
bucketName
bytes32
name of the bucket to from which takes
btcAmount
uint256
value to add to main bag [using reservePrecision]
moveBtcAndDocs
Move Btcs and Docs from one bucket to another
Arguments
from
bytes32
Name of bucket from where the BTCs will be removed
to
bytes32
Name of bucket from where the BTCs will be added
btc
uint256
BTCs amount [using reservePrecision]
docs
uint256
Docs amount [using mocPrecision]
liquidateBucket
Clears completely the origin bucket, removing all Docs, RBTCs and bproxs
Arguments
toLiquidate
bytes32
Bucket to be cleared out
destination
bytes32
Bucket that will receive the Docs and RBTCs
emptyBucket
Clears Docs and BTC from bucket origin and sends them to destination bucket
Arguments
origin
bytes32
Bucket to clear out
destination
bytes32
Destination bucket
isAvailableBucket
checks if a bucket exists
Arguments
bucket
bytes32
name of the bucket
clearBucketBalances
Put all bucket BProx balances in zero
Arguments
bucketName
bytes32
Bucket to clear out
createBucket
Creates bucket
Arguments
name
bytes32
Name of the bucket
cobj
uint256
Target Coverage of the bucket
isBase
bool
Indicates if it is a base bucket (true) or not (false)
Last updated