Define mandatory functions in a dedicated interface#315
Define mandatory functions in a dedicated interface#315luziusmeisser wants to merge 2 commits intoCMTA:devfrom
Conversation
Created an interface that contains all mandatory functionality according to the specifications. - Add functions with name "freeze" and "unfreeze" to the reference implementation (is in specification, but not in reference implementation) - Add function "isFrozen" to list of mandatory functions (makes sense if there is freeze) - Add function termsURI to the mandatory function (that's the minimum to be compliant with the law) I did not add pause, unpause and deactivateContract to the mandatory interface as I think the standard should be open to alternative approaches.
Also renamed parameter "bool freeze" to "bool frozen" in some functions to prevent shadow warnings. Also, generally, bool parameters should be named with adjectives, whereas functions should be verbs.
|
Hello Luzius, Thanks a lot for your PR, very cool initiative. Just some quick comment:
Although I see a mandatory interface as useful for clarity, the CMTAT codebase is also intended to be used in an international context and for different cases (stablecoin, structured products). In this case, the legal criteria may change. |
Created an interface that contains all mandatory functionality according to the specifications.
I did not add pause, unpause and deactivateContract to the mandatory interface as I think the standard should be open to alternative approaches.