Type of Smart Contract
Other
Additional Contract Information
Type of Smart Contract (if Other)
Factory for rate providers that quote a constant rate
Contract Source Code
https://basescan.org/address/0xc0555b555857AAf2b5b28601eaAcFba2F8BBFB09#code
Asset Contract Source Code
No response
Additional Links
https://basescan.org/address/0xc0555b555857AAf2b5b28601eaAcFba2F8BBFB09#code
https://arbiscan.io/address/0xF502791715F287989374c452Fa78b475A3194a90
Protocol Documentation
No response
Protocol Audits
No response
Terms and Conditions
Additional Comments & Clarifications
This is a factory that creates ConstantRateProvider contracts. These are rate providers that always quote the same value. They are used as a scaling rate to scale the order of magnitude of (e.g.,) WETH amounts into the order of magnitude of (e.g.,) USD amounts for Gyro volatile pools. The pool curve itself is responsible for representing the actual price, not the rateprovider.
We made this factory to reduce review effort for future ConstantRateProvider deployments, under the assumption that future constant rateproviders deployed from the factory can be whitelisted automatically.
Operation
The factory is analogous to the pool factories. It exposes a single method, .create(uint256 value). When this is called (by anyone), the following happens:
- A new
ConstantRateProvider is deployed that always quotes the given value.
- An event
RateProviderCreated(address) is emitted with the address of the new ConstantRateProvider.
- The new rateprovider is registered in the factory so that
factory.isRateProviderFromFactory(rateprovider) will return true in the following.
State and Control
The ConstantRateProviders created by this factory do not have any mutable state and no permissioned control. The factory itself has no mutable state beyond the isRateProviderFromFactory mapping and no permissioned control.
Type of Smart Contract
Other
Additional Contract Information
Type of Smart Contract (if Other)
Factory for rate providers that quote a constant rate
Contract Source Code
https://basescan.org/address/0xc0555b555857AAf2b5b28601eaAcFba2F8BBFB09#code
Asset Contract Source Code
No response
Additional Links
https://basescan.org/address/0xc0555b555857AAf2b5b28601eaAcFba2F8BBFB09#code
https://arbiscan.io/address/0xF502791715F287989374c452Fa78b475A3194a90
Protocol Documentation
No response
Protocol Audits
No response
Terms and Conditions
Additional Comments & Clarifications
This is a factory that creates ConstantRateProvider contracts. These are rate providers that always quote the same value. They are used as a scaling rate to scale the order of magnitude of (e.g.,) WETH amounts into the order of magnitude of (e.g.,) USD amounts for Gyro volatile pools. The pool curve itself is responsible for representing the actual price, not the rateprovider.
We made this factory to reduce review effort for future ConstantRateProvider deployments, under the assumption that future constant rateproviders deployed from the factory can be whitelisted automatically.
Operation
The factory is analogous to the pool factories. It exposes a single method,
.create(uint256 value). When this is called (by anyone), the following happens:ConstantRateProvideris deployed that always quotes the givenvalue.RateProviderCreated(address)is emitted with the address of the new ConstantRateProvider.factory.isRateProviderFromFactory(rateprovider)will return true in the following.State and Control
The ConstantRateProviders created by this factory do not have any mutable state and no permissioned control. The factory itself has no mutable state beyond the
isRateProviderFromFactorymapping and no permissioned control.