Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

ApxUSDDeployer

Git Source

Inherits: AccessManaged, Deployer

Title: ApxUSDDeployer

Deploys ApxUSD (implementation + proxy) and initializes in a single transaction

Non-upgradable; deploy is restricted via AccessManager. Init params are set in the constructor.

State Variables

name

Token name for the deployed ApxUSD (e.g. "Apyx USD")

string public name

symbol

Token symbol for the deployed ApxUSD (e.g. "apxUSD")

string public symbol

denyList

Deny list (AddressList) for the deployed ApxUSD

address public denyList

supplyCap

Maximum total supply for the deployed ApxUSD (e.g. 1_000_000e18)

uint256 public supplyCap

Functions

constructor

Sets the AccessManager authority and ApxUSD init params used by deploy()

constructor(string memory _name, string memory _symbol, address _authority, address _denyList, uint256 _supplyCap)
    AccessManaged(_authority);

Parameters

NameTypeDescription
_namestringToken name for the deployed ApxUSD (e.g. "Apyx USD")
_symbolstringToken symbol for the deployed ApxUSD (e.g. "apxUSD")
_authorityaddressAddress of the AccessManager contract (used for this deployer and for each deployed ApxUSD)
_denyListaddress
_supplyCapuint256Maximum total supply for the deployed ApxUSD (e.g. 1_000_000e18)

deploy

Deploys ApxUSD implementation, proxy, and initializes in one transaction using constructor params

Only callable through AccessManager (restricted)

function deploy() external restricted returns (address proxy);

Returns

NameTypeDescription
proxyaddressThe address of the deployed ApxUSD proxy (use this as the stablecoin address)