{ReferenceCurveFactory_v1} facilitates the deployment of ReferenceCurve contracts and their associated modules for the Inverter Network, ensuring seamless creation and configuration of various components in a single transaction. Source: src/factories/ReferenceCurveFactory_v1.sol. Interfaces: IReferenceCurveFactory_v1.

Functions

attachPresaleWithTreasury

Attaches a separate fee treasury and a presale to a ReferenceCurve that this factory created. Parameters Returns IReferenceCurveFactory_v1.sol#L316

createReferenceCurve

Creates a new ReferenceCurve with its issuance token and its modules in one transaction. Parameters Returns IReferenceCurveFactory_v1.sol#L279

createReferenceCurveWithRecovery

Parameters Returns IReferenceCurveFactory_v1.sol#L70

renounceAllowedDeployer

Removes the deployment permission of the caller. IReferenceCurveFactory_v1.sol#L329

setAllowedDeployer

Sets the deployment permission for an address. Parameters IReferenceCurveFactory_v1.sol#L337

setMarketFreezeSafes

Sets the freeze Safe pair of market guardians created later. Parameters IReferenceCurveFactory_v1.sol#L348

setOpenDeployment

Sets whether deployment is open to all addresses. Parameters IReferenceCurveFactory_v1.sol#L341

View functions

getIssuanceTokenDeployer

Returns the curve-bound token deployer that the factory uses. Returns IReferenceCurveFactory_v1.sol#L362

getMarketFreezeSafes

Returns the freeze Safe pair of market guardians created later. Returns IReferenceCurveFactory_v1.sol#L355

getModuleFactory

Returns the address of the ModuleFactory contract. Returns IReferenceCurveFactory_v1.sol#L225

getReferenceCurveByID

Returns the ReferenceCurve address for a given ReferenceCurve ID. Parameters Returns IReferenceCurveFactory_v1.sol#L233

getReferenceCurveIDCounter

Returns the current ReferenceCurve ID counter. Returns IReferenceCurveFactory_v1.sol#L240

isAllowedDeployer

Returns whether the given address is an allowed deployer. Parameters Returns IReferenceCurveFactory_v1.sol#L245

isOpenDeployment

Returns whether deployment is open to all addresses. Returns IReferenceCurveFactory_v1.sol#L252

Events

ReferenceCurveCreated

Event emitted when a new ReferenceCurve is created. Parameters IReferenceCurveFactory_v1.sol#L86

ReferenceCurveFactory__DeployerSet

Event emitted when a deployer permission is changed. Parameters IReferenceCurveFactory_v1.sol#L97

ReferenceCurveFactory__MarketFreezeGuardianCreated

A freeze guardian was created for a new market. Parameters IReferenceCurveFactory_v1.sol#L216

ReferenceCurveFactory__MarketFreezeSafesSet

The freeze Safe pair of new market guardians was set. Parameters IReferenceCurveFactory_v1.sol#L209

ReferenceCurveFactory__OpenDeploymentSet

Event emitted when open deployment is toggled. Parameters IReferenceCurveFactory_v1.sol#L103

ReferenceCurveFactory__PresaleAttached

Event emitted when a separate fee treasury and a presale are attached to a ReferenceCurve. Parameters IReferenceCurveFactory_v1.sol#L111

ReferenceCurveFactoryInitialized

Event emitted when the ReferenceCurveFactory is initialized. Parameters IReferenceCurveFactory_v1.sol#L92

Errors

ReferenceCurveFactory__CallerNotCurveAdmin

Caller does not hold DEFAULT_ADMIN_ROLE on the curve’s authorizer. IReferenceCurveFactory_v1.sol#L134

ReferenceCurveFactory__CreditFacilityMarketMismatch

The Presale’s CreditFacility has a different curve or authorizer. Parameters IReferenceCurveFactory_v1.sol#L144

ReferenceCurveFactory__InvalidAddress

Given address is invalid (zero address). IReferenceCurveFactory_v1.sol#L125

ReferenceCurveFactory__InvalidAuthorizerModule

The authorizer config does not name an expected authorizer, or the created authorizer does not report its interfaces. IReferenceCurveFactory_v1.sol#L169

ReferenceCurveFactory__InvalidCurveConfigData

The curve config data is shorter than one word, or its first word, the issuance token slot, is not zero. IReferenceCurveFactory_v1.sol#L161

ReferenceCurveFactory__InvalidCurveModule

The curve config does not name an expected curve module. IReferenceCurveFactory_v1.sol#L164

ReferenceCurveFactory__InvalidFeeTreasuryModule

The fee treasury config does not name an expected treasury, or the created treasury does not report its interfaces. IReferenceCurveFactory_v1.sol#L174

ReferenceCurveFactory__InvalidId

Given ReferenceCurve ID is invalid. IReferenceCurveFactory_v1.sol#L122

ReferenceCurveFactory__InvalidMarketFreezeSafes

The freeze Safes are equal, or one of them has no code. IReferenceCurveFactory_v1.sol#L157

ReferenceCurveFactory__InvalidOptionalModule

An optional module config uses a title that is not accepted. IReferenceCurveFactory_v1.sol#L182

ReferenceCurveFactory__InvalidPresaleModule

The presale config does not name a Presale_v1 module. IReferenceCurveFactory_v1.sol#L140

ReferenceCurveFactory__InvalidReserveManagerModule

The reserve manager config does not name a ReserveManager_v1, or the created module does not report the ReserveManager interface or starts with a liability. IReferenceCurveFactory_v1.sol#L179

ReferenceCurveFactory__InvalidTreasuryModule

The treasury config does not name a SplitterTreasury_v1 module. IReferenceCurveFactory_v1.sol#L137

ReferenceCurveFactory__IssuanceTokenMismatch

The issuance token does not belong to the market curve. Parameters IReferenceCurveFactory_v1.sol#L191

ReferenceCurveFactory__MarketGuardianMismatch

The freeze guardian does not hold the market freeze Safes. Parameters IReferenceCurveFactory_v1.sol#L195

ReferenceCurveFactory__ModuleLinkMismatch

A module does not point to the partner that the factory created for the same market. Parameters IReferenceCurveFactory_v1.sol#L187

ReferenceCurveFactory__NotAllowed

Caller is not allowed to deploy. IReferenceCurveFactory_v1.sol#L128

ReferenceCurveFactory__PresaleAlreadyAttached

A presale is already attached to the given ReferenceCurve. IReferenceCurveFactory_v1.sol#L147

ReferenceCurveFactory__ReentrantCall

A presale attachment was re-entered while it was executing. IReferenceCurveFactory_v1.sol#L131

ReferenceCurveFactory__ReferenceCurveMismatch

The ReferenceCurve of the given ID is not the expected curve. Parameters IReferenceCurveFactory_v1.sol#L152

ReferenceCurveFactory__TokenCapBelowCurveCapacity

The cap of the issuance token is below the capacity of the initial curve segments. Parameters IReferenceCurveFactory_v1.sol#L201