TwoKeyPlasmaSingletoneRegistry
contract TwoKeyPlasmaSingletoneRegistry
Index
Reference
Events
ProxiesDeployed
event ProxiesDeployed(address logicProxy, address storageProxy)- Parameters:
logicProxy- addressstorageProxy- address
Modifiers
onlyMaintainer
modifier onlyMaintainer()
Functions
addVersion
function addVersion(string contractName, string version, address implementation) publicRegisters a new version with its implementation address.
- Modifiers:
- onlyMaintainer
- Parameters:
contractName- stringversion- representing the version name of the new implementation to be registeredimplementation- representing the address of the new implementation to be registered
addVersionDuringCreation
function addVersionDuringCreation(string contractLogicName, string contractStorageName, address contractLogicImplementation, address contractStorageImplementation, string version) public- Modifiers:
- onlyMaintainer
- Parameters:
contractLogicName- stringcontractStorageName- stringcontractLogicImplementation- addresscontractStorageImplementation- addressversion- string
createProxy
function createProxy(string contractName, string contractNameStorage, string version) publicCreates an upgradeable proxy for both Storage and Logic.
- Modifiers:
- onlyMaintainer
- Parameters:
contractName- stringcontractNameStorage- stringversion- representing the first version to be set for the proxy
deployProxy
function deployProxy(string contractName, string version) internal returns (address)- Parameters:
contractName- stringversion- string- Returns:
- address
fallback
function () publicgetContractProxyAddress
function getContractProxyAddress(string _contractName) public view returns (address)Function to return address of proxy for specific contract.
- Parameters:
_contractName- is the name of the contract we'd like to get proxy address- Returns:
- is the address of the proxy for the specific contract
getLatestContractVersion
function getLatestContractVersion(string contractName) public view returns (string)Gets the latest contract version.
- Parameters:
contractName- is the name of the contract- Returns:
- string representation of the last version
getVersion
function getVersion(string contractName, string version) public view returns (address)Tells the address of the implementation for a given version.
- Parameters:
contractName- stringversion- to query the implementation of- Returns:
- address of the implementation registered for the given version
upgradeContract
function upgradeContract(string contractName, string version) public- Parameters:
contractName- stringversion- string