diff --git a/OEPS/OEP-59.mediawiki b/OEPS/OEP-59.mediawiki new file mode 100644 index 0000000..c55f83d --- /dev/null +++ b/OEPS/OEP-59.mediawiki @@ -0,0 +1,48 @@ +
+  OEP: 59
+  Title: Composite Smart Contract Standard
+  Author: Jawax 
+  Type: Standard
+  Status: Accepted
+  Created: 2019-07-31
+
+ +==Abstract== + +Given the existence of an abundance of OEP standards, a method for detection should be implemented. + +This OEP proposes a solution to the scenarios where a smart contract supports multiple existing standards. + +The OEP is a specification for creating a smart contract which conforms with two or more other OEPs. + +==Motivation== + +A standard interface which allows the detection of implemented standards on the Ontology blockchain to be conveniently used by other applications. + +==Specification== + +===Methods=== + +====supportedStandards==== + +
+def supportedStandards()
+
+ +Returns an array of string values in the format "OEP-X" where X corresponds to an existing OEP standard. + +For example, an OEP-4 contract implementing this standard would return ["OEP-4", "OEP-59"]. + +====supports==== + +
+def supports(standard)
+
+ +Returns a boolean whether the contract supports the standard. + +For example, supports("OEP-4") would return true if supportedStandards() returns ["OEP-4", "OEP-59"]. + +===Implementation=== + +OEP-4/59: [[https://github.com/jwang35412/OEP4-Example/blob/master/contract.py | python example]]