Created
April 5, 2018 07:14
-
-
Save kyriediculous/61df91b0383a7af799181ab6e37cdadd to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity ^0.4.19; | |
import './CMCEnabled.sol'; | |
contract Storage is CMCEnabled { | |
uint public x; | |
function setX(uint _x) external isCMCEnabled("Storage") { | |
x = _x; | |
} | |
} | |
contract Controller is CMCEnabled { | |
function setX(uint _x) external isCMCEnabled("UserEntry") { | |
Storage(ContractProvider(CMC).contracts("Storage")).setX(_x); | |
} | |
} | |
contract UserEntry is CMCEnabled { | |
function setX(uint _x) external { | |
Controller(ContractProvider(CMC).contracts("Controller")).setX(_x); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment