@etherisc/gif-next 0.0.2-d3543ee-217 → 0.0.2-d96b9e1-825

Sign up to get free protection for your applications and to get access to all the features.
Files changed (322) hide show
  1. package/README.md +76 -0
  2. package/artifacts/contracts/components/BaseComponent.sol/BaseComponent.dbg.json +4 -0
  3. package/artifacts/contracts/components/{Component.sol/Component.json → BaseComponent.sol/BaseComponent.json} +26 -57
  4. package/artifacts/contracts/components/IBaseComponent.sol/IBaseComponent.dbg.json +4 -0
  5. package/artifacts/contracts/{instance/component/IComponent.sol/IComponentContract.json → components/IBaseComponent.sol/IBaseComponent.json} +26 -57
  6. package/artifacts/contracts/components/IPoolComponent.sol/IPoolComponent.dbg.json +4 -0
  7. package/artifacts/contracts/components/IPoolComponent.sol/IPoolComponent.json +356 -0
  8. package/artifacts/contracts/components/IProductComponent.sol/IProductComponent.dbg.json +4 -0
  9. package/artifacts/contracts/components/{IPool.sol/IPoolComponent.json → IProductComponent.sol/IProductComponent.json} +89 -65
  10. package/artifacts/contracts/components/Pool.sol/Pool.dbg.json +1 -1
  11. package/artifacts/contracts/components/Pool.sol/Pool.json +134 -75
  12. package/artifacts/contracts/components/Product.sol/Product.dbg.json +1 -1
  13. package/artifacts/contracts/components/Product.sol/Product.json +72 -113
  14. package/artifacts/contracts/experiment/errors/Require.sol/Require.dbg.json +1 -1
  15. package/artifacts/contracts/experiment/errors/Revert.sol/Revert.dbg.json +1 -1
  16. package/artifacts/contracts/experiment/inheritance/A.sol/A.dbg.json +1 -1
  17. package/artifacts/contracts/experiment/inheritance/A.sol/AShared.dbg.json +1 -1
  18. package/artifacts/contracts/experiment/inheritance/B.sol/B.dbg.json +1 -1
  19. package/artifacts/contracts/experiment/inheritance/C.sol/C.dbg.json +1 -1
  20. package/artifacts/contracts/experiment/inheritance/IA.sol/IA.dbg.json +1 -1
  21. package/artifacts/contracts/experiment/inheritance/IA.sol/ISharedA.dbg.json +1 -1
  22. package/artifacts/contracts/experiment/inheritance/IB.sol/IB.dbg.json +1 -1
  23. package/artifacts/contracts/experiment/inheritance/IC.sol/IC.dbg.json +1 -1
  24. package/artifacts/contracts/experiment/statemachine/Dummy.sol/LifeCycleModule.dbg.json +1 -1
  25. package/artifacts/contracts/experiment/statemachine/Dummy.sol/LifeCycleModule.json +2 -2
  26. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISM.dbg.json +1 -1
  27. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISMEE.dbg.json +1 -1
  28. package/artifacts/contracts/experiment/statemachine/SM.sol/SM.dbg.json +1 -1
  29. package/artifacts/contracts/experiment/statemachine/SM.sol/SM.json +2 -2
  30. package/artifacts/contracts/experiment/statemachine/SimpleStateMachine.sol/SimpleStateMachine.dbg.json +1 -1
  31. package/artifacts/contracts/experiment/statemachine/SimpleStateMachine.sol/SimpleStateMachine.json +2 -2
  32. package/artifacts/contracts/experiment/types/TypeA.sol/TypeALib.dbg.json +1 -1
  33. package/artifacts/contracts/experiment/types/TypeB.sol/TypeBLib.dbg.json +1 -1
  34. package/artifacts/contracts/instance/IInstance.sol/IInstance.dbg.json +1 -1
  35. package/artifacts/contracts/instance/IInstance.sol/IInstance.json +719 -332
  36. package/artifacts/contracts/instance/IInstanceLinked.sol/IInstanceLinked.dbg.json +4 -0
  37. package/artifacts/contracts/instance/{component/IComponent.sol → IInstanceLinked.sol}/IInstanceLinked.json +1 -1
  38. package/artifacts/contracts/instance/Instance.sol/Instance.dbg.json +1 -1
  39. package/artifacts/contracts/instance/Instance.sol/Instance.json +962 -531
  40. package/artifacts/contracts/instance/base/ComponentServiceBase.sol/ComponentServiceBase.dbg.json +4 -0
  41. package/artifacts/contracts/instance/{component/ComponentModule.sol/ComponentModule.json → base/ComponentServiceBase.sol/ComponentServiceBase.json} +133 -132
  42. package/artifacts/contracts/instance/base/IInstanceBase.sol/IInstanceBase.dbg.json +4 -0
  43. package/artifacts/contracts/instance/{product/ProductService.sol/ProductModule.json → base/IInstanceBase.sol/IInstanceBase.json} +18 -30
  44. package/artifacts/contracts/instance/base/IKeyValueStore.sol/IKeyValueStore.dbg.json +4 -0
  45. package/artifacts/contracts/instance/base/IKeyValueStore.sol/IKeyValueStore.json +511 -0
  46. package/artifacts/contracts/instance/base/ILifecycle.sol/ILifecycle.dbg.json +4 -0
  47. package/artifacts/contracts/instance/{lifecycle/ILifecycle.sol/ILifecycleModule.json → base/ILifecycle.sol/ILifecycle.json} +10 -77
  48. package/artifacts/contracts/instance/base/IService.sol/IService.dbg.json +4 -0
  49. package/artifacts/contracts/instance/base/IService.sol/IService.json +300 -0
  50. package/artifacts/contracts/instance/base/InstanceBase.sol/InstanceBase.dbg.json +4 -0
  51. package/artifacts/contracts/instance/base/InstanceBase.sol/InstanceBase.json +326 -0
  52. package/artifacts/contracts/instance/base/KeyValueStore.sol/KeyValueStore.dbg.json +4 -0
  53. package/artifacts/contracts/instance/base/KeyValueStore.sol/KeyValueStore.json +692 -0
  54. package/artifacts/contracts/instance/base/Lifecycle.sol/Lifecycle.dbg.json +4 -0
  55. package/artifacts/contracts/instance/base/Lifecycle.sol/Lifecycle.json +169 -0
  56. package/artifacts/contracts/instance/base/ModuleBase.sol/ModuleBase.dbg.json +4 -0
  57. package/artifacts/contracts/instance/base/ModuleBase.sol/ModuleBase.json +10 -0
  58. package/artifacts/contracts/instance/base/ServiceBase.sol/ServiceBase.dbg.json +4 -0
  59. package/artifacts/contracts/instance/base/ServiceBase.sol/ServiceBase.json +300 -0
  60. package/artifacts/contracts/instance/module/access/Access.sol/AccessModule.dbg.json +4 -0
  61. package/artifacts/contracts/instance/{access → module/access}/Access.sol/AccessModule.json +85 -152
  62. package/artifacts/contracts/instance/module/access/IAccess.sol/IAccess.dbg.json +4 -0
  63. package/artifacts/contracts/instance/{access → module/access}/IAccess.sol/IAccess.json +1 -1
  64. package/artifacts/contracts/instance/module/access/IAccess.sol/IAccessModule.dbg.json +4 -0
  65. package/artifacts/contracts/instance/{access → module/access}/IAccess.sol/IAccessModule.json +96 -99
  66. package/artifacts/contracts/instance/module/bundle/BundleModule.sol/BundleModule.dbg.json +4 -0
  67. package/artifacts/contracts/instance/module/bundle/BundleModule.sol/BundleModule.json +296 -0
  68. package/artifacts/contracts/instance/module/bundle/IBundle.sol/IBundle.dbg.json +4 -0
  69. package/artifacts/contracts/instance/module/bundle/IBundle.sol/IBundle.json +10 -0
  70. package/artifacts/contracts/instance/module/bundle/IBundle.sol/IBundleModule.dbg.json +4 -0
  71. package/artifacts/contracts/instance/module/bundle/IBundle.sol/IBundleModule.json +296 -0
  72. package/artifacts/contracts/instance/module/compensation/CompensationModule.sol/CompensationModule.dbg.json +4 -0
  73. package/artifacts/contracts/instance/module/compensation/CompensationModule.sol/CompensationModule.json +10 -0
  74. package/artifacts/contracts/instance/module/compensation/ICompensation.sol/ICompensation.dbg.json +4 -0
  75. package/artifacts/contracts/instance/module/compensation/ICompensation.sol/ICompensation.json +10 -0
  76. package/artifacts/contracts/instance/module/compensation/ICompensation.sol/ICompensationModule.dbg.json +4 -0
  77. package/artifacts/contracts/instance/module/compensation/ICompensation.sol/ICompensationModule.json +10 -0
  78. package/artifacts/contracts/instance/module/component/ComponentModule.sol/ComponentModule.dbg.json +4 -0
  79. package/artifacts/contracts/instance/module/component/ComponentModule.sol/ComponentModule.json +188 -0
  80. package/artifacts/contracts/instance/module/component/IComponent.sol/IComponent.dbg.json +4 -0
  81. package/artifacts/contracts/instance/{component → module/component}/IComponent.sol/IComponent.json +1 -1
  82. package/artifacts/contracts/instance/module/component/IComponent.sol/IComponentModule.dbg.json +4 -0
  83. package/artifacts/contracts/instance/{component → module/component}/IComponent.sol/IComponentModule.json +33 -62
  84. package/artifacts/contracts/instance/module/policy/IPolicy.sol/IPolicy.dbg.json +4 -0
  85. package/artifacts/contracts/instance/{policy → module/policy}/IPolicy.sol/IPolicy.json +1 -1
  86. package/artifacts/contracts/instance/module/policy/IPolicy.sol/IPolicyModule.dbg.json +4 -0
  87. package/artifacts/contracts/instance/{policy → module/policy}/IPolicy.sol/IPolicyModule.json +132 -125
  88. package/artifacts/contracts/instance/module/policy/PolicyModule.sol/PolicyModule.dbg.json +4 -0
  89. package/artifacts/contracts/instance/{policy → module/policy}/PolicyModule.sol/PolicyModule.json +132 -125
  90. package/artifacts/contracts/instance/module/pool/IPoolModule.sol/IPool.dbg.json +4 -0
  91. package/artifacts/contracts/instance/{pool → module/pool}/IPoolModule.sol/IPool.json +1 -1
  92. package/artifacts/contracts/instance/module/pool/IPoolModule.sol/IPoolModule.dbg.json +4 -0
  93. package/artifacts/contracts/instance/{pool → module/pool}/IPoolModule.sol/IPoolModule.json +67 -47
  94. package/artifacts/contracts/instance/module/pool/PoolModule.sol/PoolModule.dbg.json +4 -0
  95. package/artifacts/contracts/instance/{pool → module/pool}/PoolModule.sol/PoolModule.json +51 -57
  96. package/artifacts/contracts/instance/module/risk/IRisk.sol/IRisk.dbg.json +4 -0
  97. package/artifacts/contracts/instance/module/risk/IRisk.sol/IRisk.json +10 -0
  98. package/artifacts/contracts/instance/module/risk/IRisk.sol/IRiskModule.dbg.json +4 -0
  99. package/artifacts/contracts/instance/module/risk/IRisk.sol/IRiskModule.json +10 -0
  100. package/artifacts/contracts/instance/module/risk/RiskModule.sol/RiskModule.dbg.json +4 -0
  101. package/artifacts/contracts/instance/module/risk/RiskModule.sol/RiskModule.json +10 -0
  102. package/artifacts/contracts/instance/module/treasury/ITreasury.sol/ITreasury.dbg.json +4 -0
  103. package/artifacts/contracts/instance/{treasury → module/treasury}/ITreasury.sol/ITreasury.json +1 -1
  104. package/artifacts/contracts/instance/module/treasury/ITreasury.sol/ITreasuryModule.dbg.json +4 -0
  105. package/artifacts/contracts/instance/{treasury → module/treasury}/ITreasury.sol/ITreasuryModule.json +100 -57
  106. package/artifacts/contracts/instance/module/treasury/TokenHandler.sol/TokenHandler.dbg.json +4 -0
  107. package/artifacts/contracts/instance/module/treasury/TokenHandler.sol/TokenHandler.json +76 -0
  108. package/artifacts/contracts/instance/module/treasury/TreasuryModule.sol/TreasuryModule.dbg.json +4 -0
  109. package/artifacts/contracts/instance/{treasury → module/treasury}/TreasuryModule.sol/TreasuryModule.json +100 -57
  110. package/artifacts/contracts/instance/service/ComponentOwnerService.sol/ComponentOwnerService.dbg.json +4 -0
  111. package/artifacts/contracts/instance/service/ComponentOwnerService.sol/ComponentOwnerService.json +491 -0
  112. package/artifacts/contracts/instance/service/IComponentOwnerService.sol/IComponentOwnerService.dbg.json +4 -0
  113. package/artifacts/contracts/instance/service/IComponentOwnerService.sol/IComponentOwnerService.json +364 -0
  114. package/artifacts/contracts/instance/service/IPoolService.sol/IPoolService.dbg.json +4 -0
  115. package/artifacts/contracts/instance/service/IPoolService.sol/IPoolService.json +376 -0
  116. package/artifacts/contracts/instance/service/IProductService.sol/IProductService.dbg.json +4 -0
  117. package/artifacts/contracts/instance/service/IProductService.sol/IProductService.json +477 -0
  118. package/artifacts/contracts/instance/service/PoolService.sol/PoolService.dbg.json +4 -0
  119. package/artifacts/contracts/instance/service/PoolService.sol/PoolService.json +471 -0
  120. package/artifacts/contracts/instance/service/ProductService.sol/ProductService.dbg.json +4 -0
  121. package/artifacts/contracts/instance/service/ProductService.sol/ProductService.json +673 -0
  122. package/artifacts/contracts/registry/ChainNft.sol/ChainNft.dbg.json +1 -1
  123. package/artifacts/contracts/registry/ChainNft.sol/ChainNft.json +65 -2
  124. package/artifacts/contracts/registry/IChainNft.sol/IChainNft.dbg.json +1 -1
  125. package/artifacts/contracts/registry/IRegistry.sol/IRegistry.dbg.json +1 -1
  126. package/artifacts/contracts/registry/IRegistry.sol/IRegistry.json +147 -30
  127. package/artifacts/contracts/registry/IRegistryLinked.sol/IRegistryLinked.dbg.json +4 -0
  128. package/artifacts/contracts/registry/IRegistryLinked.sol/IRegistryLinked.json +24 -0
  129. package/artifacts/contracts/registry/Registry.sol/Registry.dbg.json +1 -1
  130. package/artifacts/contracts/registry/Registry.sol/Registry.json +241 -25
  131. package/artifacts/contracts/shared/ERC165.sol/ERC165.dbg.json +4 -0
  132. package/artifacts/contracts/shared/ERC165.sol/ERC165.json +35 -0
  133. package/artifacts/contracts/shared/IOwnable.sol/IOwnable.dbg.json +4 -0
  134. package/artifacts/contracts/{registry/IRegistry.sol → shared/IOwnable.sol}/IOwnable.json +1 -1
  135. package/artifacts/contracts/shared/IRegisterable.sol/IRegisterable.dbg.json +4 -0
  136. package/artifacts/contracts/{registry/IRegistry.sol → shared/IRegisterable.sol}/IRegisterable.json +16 -61
  137. package/artifacts/contracts/shared/IVersionable.sol/IVersionable.dbg.json +4 -0
  138. package/artifacts/contracts/shared/IVersionable.sol/IVersionable.json +164 -0
  139. package/artifacts/contracts/shared/Registerable.sol/Registerable.dbg.json +4 -0
  140. package/artifacts/contracts/{registry/Registry.sol → shared/Registerable.sol}/Registerable.json +16 -61
  141. package/artifacts/contracts/shared/Versionable.sol/Versionable.dbg.json +4 -0
  142. package/artifacts/contracts/shared/Versionable.sol/Versionable.json +164 -0
  143. package/artifacts/contracts/test/TestFee.sol/TestFee.dbg.json +4 -0
  144. package/artifacts/contracts/test/TestFee.sol/TestFee.json +119 -0
  145. package/artifacts/contracts/test/TestPool.sol/TestPool.dbg.json +4 -0
  146. package/artifacts/contracts/test/TestPool.sol/TestPool.json +387 -0
  147. package/artifacts/contracts/test/TestProduct.sol/TestProduct.dbg.json +4 -0
  148. package/artifacts/contracts/test/TestProduct.sol/TestProduct.json +393 -0
  149. package/artifacts/contracts/test/TestRegisterable.sol/TestRegisterable.dbg.json +4 -0
  150. package/artifacts/contracts/test/TestRegisterable.sol/TestRegisterable.json +137 -0
  151. package/artifacts/contracts/test/TestRoleId.sol/TestRoleId.dbg.json +4 -0
  152. package/artifacts/contracts/test/TestRoleId.sol/TestRoleId.json +82 -0
  153. package/artifacts/contracts/test/TestService.sol/TestService.dbg.json +4 -0
  154. package/artifacts/contracts/test/TestService.sol/TestService.json +379 -0
  155. package/artifacts/contracts/test/TestToken.sol/TestUsdc.dbg.json +4 -0
  156. package/artifacts/contracts/test/TestToken.sol/TestUsdc.json +338 -0
  157. package/artifacts/contracts/test/TestVersion.sol/TestVersion.dbg.json +4 -0
  158. package/artifacts/contracts/test/TestVersion.sol/TestVersion.json +218 -0
  159. package/artifacts/contracts/test/TestVersionable.sol/TestVersionable.dbg.json +4 -0
  160. package/artifacts/contracts/test/TestVersionable.sol/TestVersionable.json +206 -0
  161. package/artifacts/contracts/types/AddressSet.sol/LibAddressSet.dbg.json +4 -0
  162. package/artifacts/contracts/types/AddressSet.sol/LibAddressSet.json +10 -0
  163. package/artifacts/contracts/types/Blocknumber.sol/BlocknumberLib.dbg.json +1 -1
  164. package/artifacts/contracts/types/ChainId.sol/ChainIdLib.dbg.json +1 -1
  165. package/artifacts/contracts/types/Fee.sol/FeeLib.dbg.json +4 -0
  166. package/artifacts/contracts/types/Fee.sol/FeeLib.json +218 -0
  167. package/artifacts/contracts/types/Key32.sol/Key32Lib.dbg.json +4 -0
  168. package/artifacts/contracts/types/Key32.sol/Key32Lib.json +111 -0
  169. package/artifacts/contracts/types/NftId.sol/NftIdLib.dbg.json +1 -1
  170. package/artifacts/contracts/types/NftId.sol/NftIdLib.json +65 -4
  171. package/artifacts/contracts/types/NftIdSet.sol/LibNftIdSet.dbg.json +4 -0
  172. package/artifacts/contracts/types/NftIdSet.sol/LibNftIdSet.json +10 -0
  173. package/artifacts/contracts/types/ObjectType.sol/ObjectTypeLib.dbg.json +1 -1
  174. package/artifacts/contracts/types/ObjectType.sol/ObjectTypeLib.json +2 -2
  175. package/artifacts/contracts/types/StateId.sol/StateIdLib.dbg.json +1 -1
  176. package/artifacts/contracts/types/StateId.sol/StateIdLib.json +2 -2
  177. package/artifacts/contracts/types/Timestamp.sol/TimestampLib.dbg.json +1 -1
  178. package/artifacts/contracts/types/Timestamp.sol/TimestampLib.json +64 -2
  179. package/artifacts/contracts/types/UFixed.sol/UFixedMathLib.dbg.json +1 -1
  180. package/artifacts/contracts/types/UFixed.sol/UFixedMathLib.json +58 -58
  181. package/artifacts/contracts/types/Version.sol/VersionLib.dbg.json +4 -0
  182. package/artifacts/contracts/types/Version.sol/VersionLib.json +139 -0
  183. package/artifacts/contracts/types/Version.sol/VersionPartLib.dbg.json +4 -0
  184. package/artifacts/contracts/types/Version.sol/VersionPartLib.json +30 -0
  185. package/contracts/components/BaseComponent.sol +88 -0
  186. package/contracts/components/IBaseComponent.sol +19 -0
  187. package/contracts/components/IPoolComponent.sol +57 -0
  188. package/contracts/components/{IProduct.sol → IProductComponent.sol} +9 -6
  189. package/contracts/components/Pool.sol +140 -18
  190. package/contracts/components/Product.sol +53 -25
  191. package/contracts/instance/IInstance.sol +38 -11
  192. package/contracts/instance/IInstanceLinked.sol +8 -0
  193. package/contracts/instance/Instance.sol +44 -48
  194. package/contracts/instance/base/ComponentServiceBase.sol +42 -0
  195. package/contracts/instance/base/IInstanceBase.sol +14 -0
  196. package/contracts/instance/base/IKeyValueStore.sol +49 -0
  197. package/contracts/instance/{lifecycle → base}/ILifecycle.sol +4 -21
  198. package/contracts/instance/base/IService.sol +15 -0
  199. package/contracts/instance/base/InstanceBase.sol +80 -0
  200. package/contracts/instance/base/KeyValueStore.sol +147 -0
  201. package/contracts/instance/{lifecycle/LifecycleModule.sol → base/Lifecycle.sol} +36 -29
  202. package/contracts/instance/base/ModuleBase.sol +52 -0
  203. package/contracts/instance/base/ServiceBase.sol +37 -0
  204. package/contracts/instance/module/access/Access.sol +149 -0
  205. package/contracts/instance/module/access/IAccess.sol +53 -0
  206. package/contracts/instance/module/bundle/BundleModule.sol +136 -0
  207. package/contracts/instance/module/bundle/IBundle.sol +58 -0
  208. package/contracts/instance/module/compensation/CompensationModule.sol +8 -0
  209. package/contracts/instance/module/compensation/ICompensation.sol +10 -0
  210. package/contracts/instance/module/component/ComponentModule.sol +95 -0
  211. package/contracts/instance/module/component/IComponent.sol +53 -0
  212. package/contracts/instance/module/policy/IPolicy.sol +60 -0
  213. package/contracts/instance/module/policy/PolicyModule.sol +76 -0
  214. package/contracts/instance/module/pool/IPoolModule.sol +41 -0
  215. package/contracts/instance/module/pool/PoolModule.sol +87 -0
  216. package/contracts/instance/module/risk/IRisk.sol +10 -0
  217. package/contracts/instance/module/risk/RiskModule.sol +8 -0
  218. package/contracts/instance/{treasury → module/treasury}/ITreasury.sol +27 -15
  219. package/contracts/instance/module/treasury/TokenHandler.sol +48 -0
  220. package/contracts/instance/{treasury → module/treasury}/TreasuryModule.sol +43 -59
  221. package/contracts/instance/service/ComponentOwnerService.sol +170 -0
  222. package/contracts/instance/service/IComponentOwnerService.sol +22 -0
  223. package/contracts/instance/service/IPoolService.sol +30 -0
  224. package/contracts/instance/service/IProductService.sol +58 -0
  225. package/contracts/instance/service/PoolService.sol +123 -0
  226. package/contracts/instance/service/ProductService.sol +354 -0
  227. package/contracts/registry/ChainNft.sol +61 -37
  228. package/contracts/registry/IRegistry.sol +24 -34
  229. package/contracts/registry/IRegistryLinked.sol +8 -0
  230. package/contracts/registry/Registry.sol +284 -85
  231. package/contracts/shared/ERC165.sol +21 -0
  232. package/contracts/shared/IOwnable.sol +6 -0
  233. package/contracts/shared/IRegisterable.sol +24 -0
  234. package/contracts/shared/IVersionable.sol +52 -0
  235. package/contracts/shared/Registerable.sol +86 -0
  236. package/contracts/shared/Versionable.sol +89 -0
  237. package/contracts/test/TestFee.sol +25 -0
  238. package/contracts/test/TestPool.sol +22 -0
  239. package/contracts/test/TestProduct.sol +44 -0
  240. package/contracts/test/TestRegisterable.sol +19 -0
  241. package/contracts/test/TestRoleId.sol +14 -0
  242. package/contracts/test/TestService.sol +32 -0
  243. package/contracts/test/TestToken.sol +26 -0
  244. package/contracts/test/TestVersion.sol +44 -0
  245. package/contracts/test/TestVersionable.sol +17 -0
  246. package/contracts/types/AddressSet.sol +58 -0
  247. package/contracts/types/Fee.sol +39 -20
  248. package/contracts/types/Key32.sol +45 -0
  249. package/contracts/types/NftId.sol +22 -1
  250. package/contracts/types/NftIdSet.sol +60 -0
  251. package/contracts/types/ObjectType.sol +22 -14
  252. package/contracts/types/RoleId.sol +36 -0
  253. package/contracts/types/StateId.sol +13 -3
  254. package/contracts/types/Timestamp.sol +22 -1
  255. package/contracts/types/UFixed.sol +15 -15
  256. package/contracts/types/Version.sol +95 -0
  257. package/package.json +8 -3
  258. package/artifacts/contracts/components/Component.sol/Component.dbg.json +0 -4
  259. package/artifacts/contracts/components/Component.sol/InstanceLinked.dbg.json +0 -4
  260. package/artifacts/contracts/components/Component.sol/InstanceLinked.json +0 -35
  261. package/artifacts/contracts/components/IPool.sol/IPoolComponent.dbg.json +0 -4
  262. package/artifacts/contracts/components/IProduct.sol/IProductComponent.dbg.json +0 -4
  263. package/artifacts/contracts/components/IProduct.sol/IProductComponent.json +0 -74
  264. package/artifacts/contracts/instance/access/Access.sol/AccessModule.dbg.json +0 -4
  265. package/artifacts/contracts/instance/access/IAccess.sol/IAccess.dbg.json +0 -4
  266. package/artifacts/contracts/instance/access/IAccess.sol/IAccessCheckRole.dbg.json +0 -4
  267. package/artifacts/contracts/instance/access/IAccess.sol/IAccessCheckRole.json +0 -35
  268. package/artifacts/contracts/instance/access/IAccess.sol/IAccessComponentTypeRoles.dbg.json +0 -4
  269. package/artifacts/contracts/instance/access/IAccess.sol/IAccessComponentTypeRoles.json +0 -50
  270. package/artifacts/contracts/instance/access/IAccess.sol/IAccessModule.dbg.json +0 -4
  271. package/artifacts/contracts/instance/component/ComponentModule.sol/ComponentModule.dbg.json +0 -4
  272. package/artifacts/contracts/instance/component/ComponentModule.sol/ComponentOwnerService.dbg.json +0 -4
  273. package/artifacts/contracts/instance/component/ComponentModule.sol/ComponentOwnerService.json +0 -202
  274. package/artifacts/contracts/instance/component/IComponent.sol/IComponent.dbg.json +0 -4
  275. package/artifacts/contracts/instance/component/IComponent.sol/IComponentContract.dbg.json +0 -4
  276. package/artifacts/contracts/instance/component/IComponent.sol/IComponentModule.dbg.json +0 -4
  277. package/artifacts/contracts/instance/component/IComponent.sol/IComponentOwnerService.dbg.json +0 -4
  278. package/artifacts/contracts/instance/component/IComponent.sol/IComponentOwnerService.json +0 -141
  279. package/artifacts/contracts/instance/component/IComponent.sol/IInstanceLinked.dbg.json +0 -4
  280. package/artifacts/contracts/instance/lifecycle/ILifecycle.sol/ILifecycle.dbg.json +0 -4
  281. package/artifacts/contracts/instance/lifecycle/ILifecycle.sol/ILifecycle.json +0 -134
  282. package/artifacts/contracts/instance/lifecycle/ILifecycle.sol/ILifecycleModule.dbg.json +0 -4
  283. package/artifacts/contracts/instance/lifecycle/LifecycleModule.sol/LifecycleModule.dbg.json +0 -4
  284. package/artifacts/contracts/instance/lifecycle/LifecycleModule.sol/LifecycleModule.json +0 -221
  285. package/artifacts/contracts/instance/policy/IPolicy.sol/IPolicy.dbg.json +0 -4
  286. package/artifacts/contracts/instance/policy/IPolicy.sol/IPolicyModule.dbg.json +0 -4
  287. package/artifacts/contracts/instance/policy/PolicyModule.sol/PolicyModule.dbg.json +0 -4
  288. package/artifacts/contracts/instance/pool/IPoolModule.sol/IPool.dbg.json +0 -4
  289. package/artifacts/contracts/instance/pool/IPoolModule.sol/IPoolModule.dbg.json +0 -4
  290. package/artifacts/contracts/instance/pool/PoolModule.sol/PoolModule.dbg.json +0 -4
  291. package/artifacts/contracts/instance/product/IProductService.sol/IProductModule.dbg.json +0 -4
  292. package/artifacts/contracts/instance/product/IProductService.sol/IProductModule.json +0 -75
  293. package/artifacts/contracts/instance/product/IProductService.sol/IProductService.dbg.json +0 -4
  294. package/artifacts/contracts/instance/product/IProductService.sol/IProductService.json +0 -127
  295. package/artifacts/contracts/instance/product/ProductService.sol/ProductModule.dbg.json +0 -4
  296. package/artifacts/contracts/instance/product/ProductService.sol/ProductService.dbg.json +0 -4
  297. package/artifacts/contracts/instance/product/ProductService.sol/ProductService.json +0 -196
  298. package/artifacts/contracts/instance/treasury/ITreasury.sol/ITreasury.dbg.json +0 -4
  299. package/artifacts/contracts/instance/treasury/ITreasury.sol/ITreasuryModule.dbg.json +0 -4
  300. package/artifacts/contracts/instance/treasury/TokenHandler.sol/TokenHandler.dbg.json +0 -4
  301. package/artifacts/contracts/instance/treasury/TokenHandler.sol/TokenHandler.json +0 -45
  302. package/artifacts/contracts/instance/treasury/TreasuryModule.sol/TreasuryModule.dbg.json +0 -4
  303. package/artifacts/contracts/registry/IRegistry.sol/IOwnable.dbg.json +0 -4
  304. package/artifacts/contracts/registry/IRegistry.sol/IRegisterable.dbg.json +0 -4
  305. package/artifacts/contracts/registry/IRegistry.sol/IRegistryLinked.dbg.json +0 -4
  306. package/artifacts/contracts/registry/IRegistry.sol/IRegistryLinked.json +0 -49
  307. package/artifacts/contracts/registry/Registry.sol/Registerable.dbg.json +0 -4
  308. package/artifacts/contracts/registry/Registry.sol/RegistryLinked.dbg.json +0 -4
  309. package/artifacts/contracts/registry/Registry.sol/RegistryLinked.json +0 -60
  310. package/contracts/components/Component.sol +0 -77
  311. package/contracts/components/IPool.sol +0 -15
  312. package/contracts/instance/access/Access.sol +0 -165
  313. package/contracts/instance/access/IAccess.sol +0 -63
  314. package/contracts/instance/component/ComponentModule.sol +0 -274
  315. package/contracts/instance/component/IComponent.sol +0 -74
  316. package/contracts/instance/policy/IPolicy.sol +0 -50
  317. package/contracts/instance/policy/PolicyModule.sol +0 -114
  318. package/contracts/instance/pool/IPoolModule.sol +0 -23
  319. package/contracts/instance/pool/PoolModule.sol +0 -81
  320. package/contracts/instance/product/IProductService.sol +0 -36
  321. package/contracts/instance/product/ProductService.sol +0 -136
  322. package/contracts/instance/treasury/TokenHandler.sol +0 -24
@@ -189,14 +189,19 @@
189
189
  "internalType": "UFixed",
190
190
  "name": "a",
191
191
  "type": "uint256"
192
+ },
193
+ {
194
+ "internalType": "UFixed",
195
+ "name": "b",
196
+ "type": "uint256"
192
197
  }
193
198
  ],
194
- "name": "ftoi",
199
+ "name": "gt",
195
200
  "outputs": [
196
201
  {
197
- "internalType": "uint256",
198
- "name": "",
199
- "type": "uint256"
202
+ "internalType": "bool",
203
+ "name": "isGreaterThan",
204
+ "type": "bool"
200
205
  }
201
206
  ],
202
207
  "stateMutability": "pure",
@@ -210,17 +215,17 @@
210
215
  "type": "uint256"
211
216
  },
212
217
  {
213
- "internalType": "enum UFixedMathLib.Rounding",
214
- "name": "rounding",
215
- "type": "UFixedMathLib.Rounding"
218
+ "internalType": "UFixed",
219
+ "name": "b",
220
+ "type": "uint256"
216
221
  }
217
222
  ],
218
- "name": "ftoi",
223
+ "name": "gte",
219
224
  "outputs": [
220
225
  {
221
- "internalType": "uint256",
222
- "name": "",
223
- "type": "uint256"
226
+ "internalType": "bool",
227
+ "name": "isGreaterThan",
228
+ "type": "bool"
224
229
  }
225
230
  ],
226
231
  "stateMutability": "pure",
@@ -232,18 +237,13 @@
232
237
  "internalType": "UFixed",
233
238
  "name": "a",
234
239
  "type": "uint256"
235
- },
236
- {
237
- "internalType": "UFixed",
238
- "name": "b",
239
- "type": "uint256"
240
240
  }
241
241
  ],
242
- "name": "gt",
242
+ "name": "gtz",
243
243
  "outputs": [
244
244
  {
245
245
  "internalType": "bool",
246
- "name": "isGreaterThan",
246
+ "name": "isZero",
247
247
  "type": "bool"
248
248
  }
249
249
  ],
@@ -263,7 +263,7 @@
263
263
  "type": "uint256"
264
264
  }
265
265
  ],
266
- "name": "gte",
266
+ "name": "lt",
267
267
  "outputs": [
268
268
  {
269
269
  "internalType": "bool",
@@ -280,13 +280,18 @@
280
280
  "internalType": "UFixed",
281
281
  "name": "a",
282
282
  "type": "uint256"
283
+ },
284
+ {
285
+ "internalType": "UFixed",
286
+ "name": "b",
287
+ "type": "uint256"
283
288
  }
284
289
  ],
285
- "name": "gtz",
290
+ "name": "lte",
286
291
  "outputs": [
287
292
  {
288
293
  "internalType": "bool",
289
- "name": "isZero",
294
+ "name": "isGreaterThan",
290
295
  "type": "bool"
291
296
  }
292
297
  ],
@@ -296,12 +301,17 @@
296
301
  {
297
302
  "inputs": [
298
303
  {
299
- "internalType": "uint256",
304
+ "internalType": "UFixed",
300
305
  "name": "a",
301
306
  "type": "uint256"
307
+ },
308
+ {
309
+ "internalType": "UFixed",
310
+ "name": "b",
311
+ "type": "uint256"
302
312
  }
303
313
  ],
304
- "name": "itof",
314
+ "name": "mul",
305
315
  "outputs": [
306
316
  {
307
317
  "internalType": "UFixed",
@@ -315,17 +325,17 @@
315
325
  {
316
326
  "inputs": [
317
327
  {
318
- "internalType": "uint256",
328
+ "internalType": "UFixed",
319
329
  "name": "a",
320
330
  "type": "uint256"
321
331
  },
322
332
  {
323
- "internalType": "int8",
324
- "name": "exp",
325
- "type": "int8"
333
+ "internalType": "UFixed",
334
+ "name": "b",
335
+ "type": "uint256"
326
336
  }
327
337
  ],
328
- "name": "itof",
338
+ "name": "sub",
329
339
  "outputs": [
330
340
  {
331
341
  "internalType": "UFixed",
@@ -342,19 +352,14 @@
342
352
  "internalType": "UFixed",
343
353
  "name": "a",
344
354
  "type": "uint256"
345
- },
346
- {
347
- "internalType": "UFixed",
348
- "name": "b",
349
- "type": "uint256"
350
355
  }
351
356
  ],
352
- "name": "lt",
357
+ "name": "toInt",
353
358
  "outputs": [
354
359
  {
355
- "internalType": "bool",
356
- "name": "isGreaterThan",
357
- "type": "bool"
360
+ "internalType": "uint256",
361
+ "name": "",
362
+ "type": "uint256"
358
363
  }
359
364
  ],
360
365
  "stateMutability": "pure",
@@ -368,17 +373,17 @@
368
373
  "type": "uint256"
369
374
  },
370
375
  {
371
- "internalType": "UFixed",
372
- "name": "b",
373
- "type": "uint256"
376
+ "internalType": "enum UFixedMathLib.Rounding",
377
+ "name": "rounding",
378
+ "type": "UFixedMathLib.Rounding"
374
379
  }
375
380
  ],
376
- "name": "lte",
381
+ "name": "toIntWithRounding",
377
382
  "outputs": [
378
383
  {
379
- "internalType": "bool",
380
- "name": "isGreaterThan",
381
- "type": "bool"
384
+ "internalType": "uint256",
385
+ "name": "",
386
+ "type": "uint256"
382
387
  }
383
388
  ],
384
389
  "stateMutability": "pure",
@@ -387,17 +392,17 @@
387
392
  {
388
393
  "inputs": [
389
394
  {
390
- "internalType": "UFixed",
395
+ "internalType": "uint256",
391
396
  "name": "a",
392
397
  "type": "uint256"
393
398
  },
394
399
  {
395
- "internalType": "UFixed",
396
- "name": "b",
397
- "type": "uint256"
400
+ "internalType": "int8",
401
+ "name": "exp",
402
+ "type": "int8"
398
403
  }
399
404
  ],
400
- "name": "mul",
405
+ "name": "toUFixed",
401
406
  "outputs": [
402
407
  {
403
408
  "internalType": "UFixed",
@@ -411,17 +416,12 @@
411
416
  {
412
417
  "inputs": [
413
418
  {
414
- "internalType": "UFixed",
419
+ "internalType": "uint256",
415
420
  "name": "a",
416
421
  "type": "uint256"
417
- },
418
- {
419
- "internalType": "UFixed",
420
- "name": "b",
421
- "type": "uint256"
422
422
  }
423
423
  ],
424
- "name": "sub",
424
+ "name": "toUFixed",
425
425
  "outputs": [
426
426
  {
427
427
  "internalType": "UFixed",
@@ -446,8 +446,8 @@
446
446
  "type": "function"
447
447
  }
448
448
  ],
449
- "bytecode": "0x611461610053600b82828239805160001a607314610046577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe730000000000000000000000000000000000000000301460806040526004361061014c5760003560e01c8063b4773329116100c2578063d05b045211610086578063d05b045214610409578063dd45daa114610439578063ea6515c414610469578063eb646d7114610499578063f30ed598146104b7578063f70dd33e146104d55761014c565b8063b47733291461032b578063b67d77c51461035b578063bc1b392d1461038b578063c8a4ac9c146103a9578063cc8b7b73146103d95761014c565b806332148d731161011457806332148d731461020b578063753b14a51461023b578063771602f71461026b5780637a858b971461029b57806392ae8ce0146102cb578063a391c15b146102fb5761014c565b8063059f8b1614610151578063118fc88c1461016f5780631a12cd471461019f57806321e5749b146101bd578063313ce567146101ed575b600080fd5b610159610505565b6040516101669190610b5e565b60405180910390f35b61018960048036038101906101849190610baa565b610519565b6040516101969190610c05565b60405180910390f35b6101a761052d565b6040516101b49190610c3c565b60405180910390f35b6101d760048036038101906101d29190610baa565b610532565b6040516101e49190610c05565b60405180910390f35b6101f5610546565b6040516102029190610b5e565b60405180910390f35b61022560048036038101906102209190610baa565b610552565b6040516102329190610c05565b60405180910390f35b61025560048036038101906102509190610c57565b610566565b6040516102629190610c05565b60405180910390f35b61028560048036038101906102809190610baa565b610578565b6040516102929190610cbf565b60405180910390f35b6102b560048036038101906102b09190610c57565b61058c565b6040516102c29190610c05565b60405180910390f35b6102e560048036038101906102e09190610d06565b61059e565b6040516102f29190610cbf565b60405180910390f35b61031560048036038101906103109190610baa565b6105c3565b6040516103229190610cbf565b60405180910390f35b61034560048036038101906103409190610baa565b6105d7565b6040516103529190610c05565b60405180910390f35b61037560048036038101906103709190610baa565b6105eb565b6040516103829190610cbf565b60405180910390f35b6103936105ff565b6040516103a09190610cbf565b60405180910390f35b6103c360048036038101906103be9190610baa565b610604565b6040516103d09190610cbf565b60405180910390f35b6103f360048036038101906103ee9190610baa565b610618565b6040516104009190610cbf565b60405180910390f35b610423600480360381019061041e9190610c57565b61062c565b6040516104309190610b5e565b60405180910390f35b610453600480360381019061044e9190610d5f565b610640565b6040516104609190610cbf565b60405180910390f35b610483600480360381019061047e9190610baa565b610713565b6040516104909190610c05565b60405180910390f35b6104a1610727565b6040516104ae9190610b5e565b60405180910390f35b6104bf610747565b6040516104cc9190610e16565b60405180910390f35b6104ef60048036038101906104ea9190610e56565b61074c565b6040516104fc9190610b5e565b60405180910390f35b601260000b600a6105169190610ff8565b81565b6000610525838361083d565b905092915050565b601281565b600061053e838361084a565b905092915050565b6000601260ff16905090565b600061055e8383610857565b905092915050565b600061057182610864565b9050919050565b60006105848383610870565b905092915050565b600061059782610886565b9050919050565b6000601260000b600a6105b19190610ff8565b826105bc9190611043565b9050919050565b60006105cf8383610892565b905092915050565b60006105e383836108f1565b905092915050565b60006105f783836108ff565b905092915050565b600090565b6000610610838361095e565b905092915050565b6000610624838361097b565b905092915050565b600061063982600261074c565b9050919050565b6000808260126106509190611085565b60000b1215610694576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161068b9061113b565b60405180910390fd5b60408260126106a39190611085565b60000b13156106e7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016106de906111a7565b60405180910390fd5b8160126106f49190611085565b600a61070091906111d4565b8361070b9190611043565b905092915050565b600061071f83836109b0565b905092915050565b6002601260000b600a61073a9190610ff8565b610744919061124e565b81565b600281565b600060028081111561076157610760610d9f565b5b82600281111561077457610773610d9f565b5b036107c5576107be6002601260000b600a61078f9190610ff8565b610799919061124e565b846107a4919061127f565b6001601260000b600a6107b79190610ff8565b60006109be565b9050610837565b600060028111156107d9576107d8610d9f565b5b8260028111156107ec576107eb610d9f565b5b036108165761080f836001601260000b600a6108089190610ff8565b60006109be565b9050610837565b610834836001601260000b600a61082d9190610ff8565b60016109be565b90505b92915050565b6000818310905092915050565b6000818311905092915050565b6000818314905092915050565b60008082149050919050565b6000818361087e919061127f565b905092915050565b60008082119050919050565b60008082116108d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108cd906112ff565b60405180910390fd5b6108e983670de0b6b3a764000084610a34565b905092915050565b600081831015905092915050565b600061090b83836108f1565b61094a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109419061136b565b60405180910390fd5b8183610956919061138b565b905092915050565b60006109738383670de0b6b3a7640000610a34565b905092915050565b6000610987838361084a565b1561099d5761099683836108ff565b90506109aa565b6109a782846108ff565b90505b92915050565b600081831115905092915050565b6000806109cc868686610a34565b9050600160028111156109e2576109e1610d9f565b5b8360028111156109f5576109f4610d9f565b5b148015610a13575060008480610a0e57610a0d61121f565b5b868809115b15610a2857600181610a25919061127f565b90505b80915050949350505050565b6000806000801985870985870292508281108382030391505060008103610a6f57838281610a6557610a6461121f565b5b0492505050610b3e565b808411610ab1576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610aa89061140b565b60405180910390fd5b60008486880990508281118203915080830392506000600186190186169050808604955080840493506001818260000304019050808302841793506000600287600302189050808702600203810290508087026002038102905080870260020381029050808702600203810290508087026002038102905080870260020381029050808502955050505050505b9392505050565b6000819050919050565b610b5881610b45565b82525050565b6000602082019050610b736000830184610b4f565b92915050565b600080fd5b610b8781610b45565b8114610b9257600080fd5b50565b600081359050610ba481610b7e565b92915050565b60008060408385031215610bc157610bc0610b79565b5b6000610bcf85828601610b95565b9250506020610be085828601610b95565b9150509250929050565b60008115159050919050565b610bff81610bea565b82525050565b6000602082019050610c1a6000830184610bf6565b92915050565b60008160000b9050919050565b610c3681610c20565b82525050565b6000602082019050610c516000830184610c2d565b92915050565b600060208284031215610c6d57610c6c610b79565b5b6000610c7b84828501610b95565b91505092915050565b6000819050919050565b6000610ca9610ca4610c9f84610b45565b610c84565b610b45565b9050919050565b610cb981610c8e565b82525050565b6000602082019050610cd46000830184610cb0565b92915050565b610ce381610b45565b8114610cee57600080fd5b50565b600081359050610d0081610cda565b92915050565b600060208284031215610d1c57610d1b610b79565b5b6000610d2a84828501610cf1565b91505092915050565b610d3c81610c20565b8114610d4757600080fd5b50565b600081359050610d5981610d33565b92915050565b60008060408385031215610d7657610d75610b79565b5b6000610d8485828601610cf1565b9250506020610d9585828601610d4a565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110610ddf57610dde610d9f565b5b50565b6000819050610df082610dce565b919050565b6000610e0082610de2565b9050919050565b610e1081610df5565b82525050565b6000602082019050610e2b6000830184610e07565b92915050565b60038110610e3e57600080fd5b50565b600081359050610e5081610e31565b92915050565b60008060408385031215610e6d57610e6c610b79565b5b6000610e7b85828601610b95565b9250506020610e8c85828601610e41565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008160011c9050919050565b6000808291508390505b6001851115610f1c57808604811115610ef857610ef7610e96565b5b6001851615610f075780820291505b8081029050610f1585610ec5565b9450610edc565b94509492505050565b600082610f355760019050610ff1565b81610f435760009050610ff1565b8160018114610f595760028114610f6357610f92565b6001915050610ff1565b60ff841115610f7557610f74610e96565b5b8360020a915084821115610f8c57610f8b610e96565b5b50610ff1565b5060208310610133831016604e8410600b8410161715610fc75782820a905083811115610fc257610fc1610e96565b5b610ff1565b610fd48484846001610ed2565b92509050818404811115610feb57610fea610e96565b5b81810290505b9392505050565b600061100382610b45565b915061100e83610b45565b925061103b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f25565b905092915050565b600061104e82610b45565b915061105983610b45565b925082820261106781610b45565b9150828204841483151761107e5761107d610e96565b5b5092915050565b600061109082610c20565b915061109b83610c20565b925082820190507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808112607f821317156110d8576110d7610e96565b5b92915050565b600082825260208201905092915050565b7f4552524f523a464d2d3031303a4558504f4e454e545f544f4f5f534d414c4c00600082015250565b6000611125601f836110de565b9150611130826110ef565b602082019050919050565b6000602082019050818103600083015261115481611118565b9050919050565b7f4552524f523a464d2d3031313a4558504f4e454e545f544f4f5f4c4152474500600082015250565b6000611191601f836110de565b915061119c8261115b565b602082019050919050565b600060208201905081810360008301526111c081611184565b9050919050565b600060ff82169050919050565b60006111df82610b45565b91506111ea836111c7565b92506112177fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f25565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061125982610b45565b915061126483610b45565b9250826112745761127361121f565b5b828204905092915050565b600061128a82610b45565b915061129583610b45565b92508282019050808211156112ad576112ac610e96565b5b92915050565b7f4552524f523a55464d2d3032303a44495649534f525f5a45524f000000000000600082015250565b60006112e9601a836110de565b91506112f4826112b3565b602082019050919050565b60006020820190508181036000830152611318816112dc565b9050919050565b7f4552524f523a55464d2d3031303a4e454741544956455f524553554c54000000600082015250565b6000611355601d836110de565b91506113608261131f565b602082019050919050565b6000602082019050818103600083015261138481611348565b9050919050565b600061139682610b45565b91506113a183610b45565b92508282039050818111156113b9576113b8610e96565b5b92915050565b7f4d6174683a206d756c446976206f766572666c6f770000000000000000000000600082015250565b60006113f56015836110de565b9150611400826113bf565b602082019050919050565b60006020820190508181036000830152611424816113e8565b905091905056fea2646970667358221220af1ecc6c0c2b56505c376d0dd83afbf44fd70dba799e8cf7e1bf20908bc5c61764736f6c63430008140033",
450
- "deployedBytecode": "0x730000000000000000000000000000000000000000301460806040526004361061014c5760003560e01c8063b4773329116100c2578063d05b045211610086578063d05b045214610409578063dd45daa114610439578063ea6515c414610469578063eb646d7114610499578063f30ed598146104b7578063f70dd33e146104d55761014c565b8063b47733291461032b578063b67d77c51461035b578063bc1b392d1461038b578063c8a4ac9c146103a9578063cc8b7b73146103d95761014c565b806332148d731161011457806332148d731461020b578063753b14a51461023b578063771602f71461026b5780637a858b971461029b57806392ae8ce0146102cb578063a391c15b146102fb5761014c565b8063059f8b1614610151578063118fc88c1461016f5780631a12cd471461019f57806321e5749b146101bd578063313ce567146101ed575b600080fd5b610159610505565b6040516101669190610b5e565b60405180910390f35b61018960048036038101906101849190610baa565b610519565b6040516101969190610c05565b60405180910390f35b6101a761052d565b6040516101b49190610c3c565b60405180910390f35b6101d760048036038101906101d29190610baa565b610532565b6040516101e49190610c05565b60405180910390f35b6101f5610546565b6040516102029190610b5e565b60405180910390f35b61022560048036038101906102209190610baa565b610552565b6040516102329190610c05565b60405180910390f35b61025560048036038101906102509190610c57565b610566565b6040516102629190610c05565b60405180910390f35b61028560048036038101906102809190610baa565b610578565b6040516102929190610cbf565b60405180910390f35b6102b560048036038101906102b09190610c57565b61058c565b6040516102c29190610c05565b60405180910390f35b6102e560048036038101906102e09190610d06565b61059e565b6040516102f29190610cbf565b60405180910390f35b61031560048036038101906103109190610baa565b6105c3565b6040516103229190610cbf565b60405180910390f35b61034560048036038101906103409190610baa565b6105d7565b6040516103529190610c05565b60405180910390f35b61037560048036038101906103709190610baa565b6105eb565b6040516103829190610cbf565b60405180910390f35b6103936105ff565b6040516103a09190610cbf565b60405180910390f35b6103c360048036038101906103be9190610baa565b610604565b6040516103d09190610cbf565b60405180910390f35b6103f360048036038101906103ee9190610baa565b610618565b6040516104009190610cbf565b60405180910390f35b610423600480360381019061041e9190610c57565b61062c565b6040516104309190610b5e565b60405180910390f35b610453600480360381019061044e9190610d5f565b610640565b6040516104609190610cbf565b60405180910390f35b610483600480360381019061047e9190610baa565b610713565b6040516104909190610c05565b60405180910390f35b6104a1610727565b6040516104ae9190610b5e565b60405180910390f35b6104bf610747565b6040516104cc9190610e16565b60405180910390f35b6104ef60048036038101906104ea9190610e56565b61074c565b6040516104fc9190610b5e565b60405180910390f35b601260000b600a6105169190610ff8565b81565b6000610525838361083d565b905092915050565b601281565b600061053e838361084a565b905092915050565b6000601260ff16905090565b600061055e8383610857565b905092915050565b600061057182610864565b9050919050565b60006105848383610870565b905092915050565b600061059782610886565b9050919050565b6000601260000b600a6105b19190610ff8565b826105bc9190611043565b9050919050565b60006105cf8383610892565b905092915050565b60006105e383836108f1565b905092915050565b60006105f783836108ff565b905092915050565b600090565b6000610610838361095e565b905092915050565b6000610624838361097b565b905092915050565b600061063982600261074c565b9050919050565b6000808260126106509190611085565b60000b1215610694576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161068b9061113b565b60405180910390fd5b60408260126106a39190611085565b60000b13156106e7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016106de906111a7565b60405180910390fd5b8160126106f49190611085565b600a61070091906111d4565b8361070b9190611043565b905092915050565b600061071f83836109b0565b905092915050565b6002601260000b600a61073a9190610ff8565b610744919061124e565b81565b600281565b600060028081111561076157610760610d9f565b5b82600281111561077457610773610d9f565b5b036107c5576107be6002601260000b600a61078f9190610ff8565b610799919061124e565b846107a4919061127f565b6001601260000b600a6107b79190610ff8565b60006109be565b9050610837565b600060028111156107d9576107d8610d9f565b5b8260028111156107ec576107eb610d9f565b5b036108165761080f836001601260000b600a6108089190610ff8565b60006109be565b9050610837565b610834836001601260000b600a61082d9190610ff8565b60016109be565b90505b92915050565b6000818310905092915050565b6000818311905092915050565b6000818314905092915050565b60008082149050919050565b6000818361087e919061127f565b905092915050565b60008082119050919050565b60008082116108d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108cd906112ff565b60405180910390fd5b6108e983670de0b6b3a764000084610a34565b905092915050565b600081831015905092915050565b600061090b83836108f1565b61094a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109419061136b565b60405180910390fd5b8183610956919061138b565b905092915050565b60006109738383670de0b6b3a7640000610a34565b905092915050565b6000610987838361084a565b1561099d5761099683836108ff565b90506109aa565b6109a782846108ff565b90505b92915050565b600081831115905092915050565b6000806109cc868686610a34565b9050600160028111156109e2576109e1610d9f565b5b8360028111156109f5576109f4610d9f565b5b148015610a13575060008480610a0e57610a0d61121f565b5b868809115b15610a2857600181610a25919061127f565b90505b80915050949350505050565b6000806000801985870985870292508281108382030391505060008103610a6f57838281610a6557610a6461121f565b5b0492505050610b3e565b808411610ab1576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610aa89061140b565b60405180910390fd5b60008486880990508281118203915080830392506000600186190186169050808604955080840493506001818260000304019050808302841793506000600287600302189050808702600203810290508087026002038102905080870260020381029050808702600203810290508087026002038102905080870260020381029050808502955050505050505b9392505050565b6000819050919050565b610b5881610b45565b82525050565b6000602082019050610b736000830184610b4f565b92915050565b600080fd5b610b8781610b45565b8114610b9257600080fd5b50565b600081359050610ba481610b7e565b92915050565b60008060408385031215610bc157610bc0610b79565b5b6000610bcf85828601610b95565b9250506020610be085828601610b95565b9150509250929050565b60008115159050919050565b610bff81610bea565b82525050565b6000602082019050610c1a6000830184610bf6565b92915050565b60008160000b9050919050565b610c3681610c20565b82525050565b6000602082019050610c516000830184610c2d565b92915050565b600060208284031215610c6d57610c6c610b79565b5b6000610c7b84828501610b95565b91505092915050565b6000819050919050565b6000610ca9610ca4610c9f84610b45565b610c84565b610b45565b9050919050565b610cb981610c8e565b82525050565b6000602082019050610cd46000830184610cb0565b92915050565b610ce381610b45565b8114610cee57600080fd5b50565b600081359050610d0081610cda565b92915050565b600060208284031215610d1c57610d1b610b79565b5b6000610d2a84828501610cf1565b91505092915050565b610d3c81610c20565b8114610d4757600080fd5b50565b600081359050610d5981610d33565b92915050565b60008060408385031215610d7657610d75610b79565b5b6000610d8485828601610cf1565b9250506020610d9585828601610d4a565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110610ddf57610dde610d9f565b5b50565b6000819050610df082610dce565b919050565b6000610e0082610de2565b9050919050565b610e1081610df5565b82525050565b6000602082019050610e2b6000830184610e07565b92915050565b60038110610e3e57600080fd5b50565b600081359050610e5081610e31565b92915050565b60008060408385031215610e6d57610e6c610b79565b5b6000610e7b85828601610b95565b9250506020610e8c85828601610e41565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008160011c9050919050565b6000808291508390505b6001851115610f1c57808604811115610ef857610ef7610e96565b5b6001851615610f075780820291505b8081029050610f1585610ec5565b9450610edc565b94509492505050565b600082610f355760019050610ff1565b81610f435760009050610ff1565b8160018114610f595760028114610f6357610f92565b6001915050610ff1565b60ff841115610f7557610f74610e96565b5b8360020a915084821115610f8c57610f8b610e96565b5b50610ff1565b5060208310610133831016604e8410600b8410161715610fc75782820a905083811115610fc257610fc1610e96565b5b610ff1565b610fd48484846001610ed2565b92509050818404811115610feb57610fea610e96565b5b81810290505b9392505050565b600061100382610b45565b915061100e83610b45565b925061103b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f25565b905092915050565b600061104e82610b45565b915061105983610b45565b925082820261106781610b45565b9150828204841483151761107e5761107d610e96565b5b5092915050565b600061109082610c20565b915061109b83610c20565b925082820190507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808112607f821317156110d8576110d7610e96565b5b92915050565b600082825260208201905092915050565b7f4552524f523a464d2d3031303a4558504f4e454e545f544f4f5f534d414c4c00600082015250565b6000611125601f836110de565b9150611130826110ef565b602082019050919050565b6000602082019050818103600083015261115481611118565b9050919050565b7f4552524f523a464d2d3031313a4558504f4e454e545f544f4f5f4c4152474500600082015250565b6000611191601f836110de565b915061119c8261115b565b602082019050919050565b600060208201905081810360008301526111c081611184565b9050919050565b600060ff82169050919050565b60006111df82610b45565b91506111ea836111c7565b92506112177fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f25565b905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061125982610b45565b915061126483610b45565b9250826112745761127361121f565b5b828204905092915050565b600061128a82610b45565b915061129583610b45565b92508282019050808211156112ad576112ac610e96565b5b92915050565b7f4552524f523a55464d2d3032303a44495649534f525f5a45524f000000000000600082015250565b60006112e9601a836110de565b91506112f4826112b3565b602082019050919050565b60006020820190508181036000830152611318816112dc565b9050919050565b7f4552524f523a55464d2d3031303a4e454741544956455f524553554c54000000600082015250565b6000611355601d836110de565b91506113608261131f565b602082019050919050565b6000602082019050818103600083015261138481611348565b9050919050565b600061139682610b45565b91506113a183610b45565b92508282039050818111156113b9576113b8610e96565b5b92915050565b7f4d6174683a206d756c446976206f766572666c6f770000000000000000000000600082015250565b60006113f56015836110de565b9150611400826113bf565b602082019050919050565b60006020820190508181036000830152611424816113e8565b905091905056fea2646970667358221220af1ecc6c0c2b56505c376d0dd83afbf44fd70dba799e8cf7e1bf20908bc5c61764736f6c63430008140033",
449
+ "bytecode": "0x611461610053600b82828239805160001a607314610046577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe730000000000000000000000000000000000000000301460806040526004361061014c5760003560e01c80637a858b97116100c2578063c8a4ac9c11610086578063c8a4ac9c14610409578063cc8b7b7314610439578063df73901114610469578063ea6515c414610499578063eb646d71146104c9578063f30ed598146104e75761014c565b80637a858b971461032b578063a391c15b1461035b578063b47733291461038b578063b67d77c5146103bb578063bc1b392d146103eb5761014c565b8063313ce56711610114578063313ce5671461021d57806332148d731461023b57806344aa68361461026b57806345ebb61e1461029b578063753b14a5146102cb578063771602f7146102fb5761014c565b8063059f8b1614610151578063118fc88c1461016f5780631488c8451461019f5780631a12cd47146101cf57806321e5749b146101ed575b600080fd5b610159610505565b6040516101669190610b5e565b60405180910390f35b61018960048036038101906101849190610baa565b610519565b6040516101969190610c05565b60405180910390f35b6101b960048036038101906101b49190610c85565b61052d565b6040516101c69190610d00565b60405180910390f35b6101d7610600565b6040516101e49190610d2a565b60405180910390f35b61020760048036038101906102029190610baa565b610605565b6040516102149190610c05565b60405180910390f35b610225610619565b6040516102329190610b5e565b60405180910390f35b61025560048036038101906102509190610baa565b610625565b6040516102629190610c05565b60405180910390f35b61028560048036038101906102809190610d45565b610639565b6040516102929190610b5e565b60405180910390f35b6102b560048036038101906102b09190610d72565b61064d565b6040516102c29190610d00565b60405180910390f35b6102e560048036038101906102e09190610d45565b610672565b6040516102f29190610c05565b60405180910390f35b61031560048036038101906103109190610baa565b610684565b6040516103229190610d00565b60405180910390f35b61034560048036038101906103409190610d45565b610698565b6040516103529190610c05565b60405180910390f35b61037560048036038101906103709190610baa565b6106aa565b6040516103829190610d00565b60405180910390f35b6103a560048036038101906103a09190610baa565b6106be565b6040516103b29190610c05565b60405180910390f35b6103d560048036038101906103d09190610baa565b6106d2565b6040516103e29190610d00565b60405180910390f35b6103f36106e6565b6040516104009190610d00565b60405180910390f35b610423600480360381019061041e9190610baa565b6106eb565b6040516104309190610d00565b60405180910390f35b610453600480360381019061044e9190610baa565b6106ff565b6040516104609190610d00565b60405180910390f35b610483600480360381019061047e9190610dc4565b610713565b6040516104909190610b5e565b60405180910390f35b6104b360048036038101906104ae9190610baa565b610804565b6040516104c09190610c05565b60405180910390f35b6104d1610818565b6040516104de9190610b5e565b60405180910390f35b6104ef610838565b6040516104fc9190610e7b565b60405180910390f35b601260000b600a6105169190610ff8565b81565b6000610525838361083d565b905092915050565b60008082601261053d9190611043565b60000b1215610581576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610578906110f9565b60405180910390fd5b60408260126105909190611043565b60000b13156105d4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105cb90611165565b60405180910390fd5b8160126105e19190611043565b600a6105ed9190611192565b836105f891906111dd565b905092915050565b601281565b6000610611838361084a565b905092915050565b6000601260ff16905090565b60006106318383610857565b905092915050565b6000610646826002610713565b9050919050565b6000601260000b600a6106609190610ff8565b8261066b91906111dd565b9050919050565b600061067d82610864565b9050919050565b60006106908383610870565b905092915050565b60006106a382610886565b9050919050565b60006106b68383610892565b905092915050565b60006106ca83836108f1565b905092915050565b60006106de83836108ff565b905092915050565b600090565b60006106f7838361095e565b905092915050565b600061070b838361097b565b905092915050565b600060028081111561072857610727610e04565b5b82600281111561073b5761073a610e04565b5b0361078c576107856002601260000b600a6107569190610ff8565b610760919061124e565b8461076b919061127f565b6001601260000b600a61077e9190610ff8565b60006109b0565b90506107fe565b600060028111156107a05761079f610e04565b5b8260028111156107b3576107b2610e04565b5b036107dd576107d6836001601260000b600a6107cf9190610ff8565b60006109b0565b90506107fe565b6107fb836001601260000b600a6107f49190610ff8565b60016109b0565b90505b92915050565b60006108108383610a26565b905092915050565b6002601260000b600a61082b9190610ff8565b610835919061124e565b81565b600281565b6000818310905092915050565b6000818311905092915050565b6000818314905092915050565b60008082149050919050565b6000818361087e919061127f565b905092915050565b60008082119050919050565b60008082116108d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108cd906112ff565b60405180910390fd5b6108e983670de0b6b3a764000084610a34565b905092915050565b600081831015905092915050565b600061090b83836108f1565b61094a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109419061136b565b60405180910390fd5b8183610956919061138b565b905092915050565b60006109738383670de0b6b3a7640000610a34565b905092915050565b6000610987838361084a565b1561099d5761099683836108ff565b90506109aa565b6109a782846108ff565b90505b92915050565b6000806109be868686610a34565b9050600160028111156109d4576109d3610e04565b5b8360028111156109e7576109e6610e04565b5b148015610a05575060008480610a00576109ff61121f565b5b868809115b15610a1a57600181610a17919061127f565b90505b80915050949350505050565b600081831115905092915050565b6000806000801985870985870292508281108382030391505060008103610a6f57838281610a6557610a6461121f565b5b0492505050610b3e565b808411610ab1576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610aa89061140b565b60405180910390fd5b60008486880990508281118203915080830392506000600186190186169050808604955080840493506001818260000304019050808302841793506000600287600302189050808702600203810290508087026002038102905080870260020381029050808702600203810290508087026002038102905080870260020381029050808502955050505050505b9392505050565b6000819050919050565b610b5881610b45565b82525050565b6000602082019050610b736000830184610b4f565b92915050565b600080fd5b610b8781610b45565b8114610b9257600080fd5b50565b600081359050610ba481610b7e565b92915050565b60008060408385031215610bc157610bc0610b79565b5b6000610bcf85828601610b95565b9250506020610be085828601610b95565b9150509250929050565b60008115159050919050565b610bff81610bea565b82525050565b6000602082019050610c1a6000830184610bf6565b92915050565b610c2981610b45565b8114610c3457600080fd5b50565b600081359050610c4681610c20565b92915050565b60008160000b9050919050565b610c6281610c4c565b8114610c6d57600080fd5b50565b600081359050610c7f81610c59565b92915050565b60008060408385031215610c9c57610c9b610b79565b5b6000610caa85828601610c37565b9250506020610cbb85828601610c70565b9150509250929050565b6000819050919050565b6000610cea610ce5610ce084610b45565b610cc5565b610b45565b9050919050565b610cfa81610ccf565b82525050565b6000602082019050610d156000830184610cf1565b92915050565b610d2481610c4c565b82525050565b6000602082019050610d3f6000830184610d1b565b92915050565b600060208284031215610d5b57610d5a610b79565b5b6000610d6984828501610b95565b91505092915050565b600060208284031215610d8857610d87610b79565b5b6000610d9684828501610c37565b91505092915050565b60038110610dac57600080fd5b50565b600081359050610dbe81610d9f565b92915050565b60008060408385031215610ddb57610dda610b79565b5b6000610de985828601610b95565b9250506020610dfa85828601610daf565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110610e4457610e43610e04565b5b50565b6000819050610e5582610e33565b919050565b6000610e6582610e47565b9050919050565b610e7581610e5a565b82525050565b6000602082019050610e906000830184610e6c565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008160011c9050919050565b6000808291508390505b6001851115610f1c57808604811115610ef857610ef7610e96565b5b6001851615610f075780820291505b8081029050610f1585610ec5565b9450610edc565b94509492505050565b600082610f355760019050610ff1565b81610f435760009050610ff1565b8160018114610f595760028114610f6357610f92565b6001915050610ff1565b60ff841115610f7557610f74610e96565b5b8360020a915084821115610f8c57610f8b610e96565b5b50610ff1565b5060208310610133831016604e8410600b8410161715610fc75782820a905083811115610fc257610fc1610e96565b5b610ff1565b610fd48484846001610ed2565b92509050818404811115610feb57610fea610e96565b5b81810290505b9392505050565b600061100382610b45565b915061100e83610b45565b925061103b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f25565b905092915050565b600061104e82610c4c565b915061105983610c4c565b925082820190507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808112607f8213171561109657611095610e96565b5b92915050565b600082825260208201905092915050565b7f4552524f523a464d2d3031303a4558504f4e454e545f544f4f5f534d414c4c00600082015250565b60006110e3601f8361109c565b91506110ee826110ad565b602082019050919050565b60006020820190508181036000830152611112816110d6565b9050919050565b7f4552524f523a464d2d3031313a4558504f4e454e545f544f4f5f4c4152474500600082015250565b600061114f601f8361109c565b915061115a82611119565b602082019050919050565b6000602082019050818103600083015261117e81611142565b9050919050565b600060ff82169050919050565b600061119d82610b45565b91506111a883611185565b92506111d57fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f25565b905092915050565b60006111e882610b45565b91506111f383610b45565b925082820261120181610b45565b9150828204841483151761121857611217610e96565b5b5092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061125982610b45565b915061126483610b45565b9250826112745761127361121f565b5b828204905092915050565b600061128a82610b45565b915061129583610b45565b92508282019050808211156112ad576112ac610e96565b5b92915050565b7f4552524f523a55464d2d3032303a44495649534f525f5a45524f000000000000600082015250565b60006112e9601a8361109c565b91506112f4826112b3565b602082019050919050565b60006020820190508181036000830152611318816112dc565b9050919050565b7f4552524f523a55464d2d3031303a4e454741544956455f524553554c54000000600082015250565b6000611355601d8361109c565b91506113608261131f565b602082019050919050565b6000602082019050818103600083015261138481611348565b9050919050565b600061139682610b45565b91506113a183610b45565b92508282039050818111156113b9576113b8610e96565b5b92915050565b7f4d6174683a206d756c446976206f766572666c6f770000000000000000000000600082015250565b60006113f560158361109c565b9150611400826113bf565b602082019050919050565b60006020820190508181036000830152611424816113e8565b905091905056fea2646970667358221220bf772f319279e8a730fb378a682a66e501c7fed8a14e78e8f812c310a6c4cffc64736f6c63430008140033",
450
+ "deployedBytecode": "0x730000000000000000000000000000000000000000301460806040526004361061014c5760003560e01c80637a858b97116100c2578063c8a4ac9c11610086578063c8a4ac9c14610409578063cc8b7b7314610439578063df73901114610469578063ea6515c414610499578063eb646d71146104c9578063f30ed598146104e75761014c565b80637a858b971461032b578063a391c15b1461035b578063b47733291461038b578063b67d77c5146103bb578063bc1b392d146103eb5761014c565b8063313ce56711610114578063313ce5671461021d57806332148d731461023b57806344aa68361461026b57806345ebb61e1461029b578063753b14a5146102cb578063771602f7146102fb5761014c565b8063059f8b1614610151578063118fc88c1461016f5780631488c8451461019f5780631a12cd47146101cf57806321e5749b146101ed575b600080fd5b610159610505565b6040516101669190610b5e565b60405180910390f35b61018960048036038101906101849190610baa565b610519565b6040516101969190610c05565b60405180910390f35b6101b960048036038101906101b49190610c85565b61052d565b6040516101c69190610d00565b60405180910390f35b6101d7610600565b6040516101e49190610d2a565b60405180910390f35b61020760048036038101906102029190610baa565b610605565b6040516102149190610c05565b60405180910390f35b610225610619565b6040516102329190610b5e565b60405180910390f35b61025560048036038101906102509190610baa565b610625565b6040516102629190610c05565b60405180910390f35b61028560048036038101906102809190610d45565b610639565b6040516102929190610b5e565b60405180910390f35b6102b560048036038101906102b09190610d72565b61064d565b6040516102c29190610d00565b60405180910390f35b6102e560048036038101906102e09190610d45565b610672565b6040516102f29190610c05565b60405180910390f35b61031560048036038101906103109190610baa565b610684565b6040516103229190610d00565b60405180910390f35b61034560048036038101906103409190610d45565b610698565b6040516103529190610c05565b60405180910390f35b61037560048036038101906103709190610baa565b6106aa565b6040516103829190610d00565b60405180910390f35b6103a560048036038101906103a09190610baa565b6106be565b6040516103b29190610c05565b60405180910390f35b6103d560048036038101906103d09190610baa565b6106d2565b6040516103e29190610d00565b60405180910390f35b6103f36106e6565b6040516104009190610d00565b60405180910390f35b610423600480360381019061041e9190610baa565b6106eb565b6040516104309190610d00565b60405180910390f35b610453600480360381019061044e9190610baa565b6106ff565b6040516104609190610d00565b60405180910390f35b610483600480360381019061047e9190610dc4565b610713565b6040516104909190610b5e565b60405180910390f35b6104b360048036038101906104ae9190610baa565b610804565b6040516104c09190610c05565b60405180910390f35b6104d1610818565b6040516104de9190610b5e565b60405180910390f35b6104ef610838565b6040516104fc9190610e7b565b60405180910390f35b601260000b600a6105169190610ff8565b81565b6000610525838361083d565b905092915050565b60008082601261053d9190611043565b60000b1215610581576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610578906110f9565b60405180910390fd5b60408260126105909190611043565b60000b13156105d4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105cb90611165565b60405180910390fd5b8160126105e19190611043565b600a6105ed9190611192565b836105f891906111dd565b905092915050565b601281565b6000610611838361084a565b905092915050565b6000601260ff16905090565b60006106318383610857565b905092915050565b6000610646826002610713565b9050919050565b6000601260000b600a6106609190610ff8565b8261066b91906111dd565b9050919050565b600061067d82610864565b9050919050565b60006106908383610870565b905092915050565b60006106a382610886565b9050919050565b60006106b68383610892565b905092915050565b60006106ca83836108f1565b905092915050565b60006106de83836108ff565b905092915050565b600090565b60006106f7838361095e565b905092915050565b600061070b838361097b565b905092915050565b600060028081111561072857610727610e04565b5b82600281111561073b5761073a610e04565b5b0361078c576107856002601260000b600a6107569190610ff8565b610760919061124e565b8461076b919061127f565b6001601260000b600a61077e9190610ff8565b60006109b0565b90506107fe565b600060028111156107a05761079f610e04565b5b8260028111156107b3576107b2610e04565b5b036107dd576107d6836001601260000b600a6107cf9190610ff8565b60006109b0565b90506107fe565b6107fb836001601260000b600a6107f49190610ff8565b60016109b0565b90505b92915050565b60006108108383610a26565b905092915050565b6002601260000b600a61082b9190610ff8565b610835919061124e565b81565b600281565b6000818310905092915050565b6000818311905092915050565b6000818314905092915050565b60008082149050919050565b6000818361087e919061127f565b905092915050565b60008082119050919050565b60008082116108d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108cd906112ff565b60405180910390fd5b6108e983670de0b6b3a764000084610a34565b905092915050565b600081831015905092915050565b600061090b83836108f1565b61094a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109419061136b565b60405180910390fd5b8183610956919061138b565b905092915050565b60006109738383670de0b6b3a7640000610a34565b905092915050565b6000610987838361084a565b1561099d5761099683836108ff565b90506109aa565b6109a782846108ff565b90505b92915050565b6000806109be868686610a34565b9050600160028111156109d4576109d3610e04565b5b8360028111156109e7576109e6610e04565b5b148015610a05575060008480610a00576109ff61121f565b5b868809115b15610a1a57600181610a17919061127f565b90505b80915050949350505050565b600081831115905092915050565b6000806000801985870985870292508281108382030391505060008103610a6f57838281610a6557610a6461121f565b5b0492505050610b3e565b808411610ab1576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610aa89061140b565b60405180910390fd5b60008486880990508281118203915080830392506000600186190186169050808604955080840493506001818260000304019050808302841793506000600287600302189050808702600203810290508087026002038102905080870260020381029050808702600203810290508087026002038102905080870260020381029050808502955050505050505b9392505050565b6000819050919050565b610b5881610b45565b82525050565b6000602082019050610b736000830184610b4f565b92915050565b600080fd5b610b8781610b45565b8114610b9257600080fd5b50565b600081359050610ba481610b7e565b92915050565b60008060408385031215610bc157610bc0610b79565b5b6000610bcf85828601610b95565b9250506020610be085828601610b95565b9150509250929050565b60008115159050919050565b610bff81610bea565b82525050565b6000602082019050610c1a6000830184610bf6565b92915050565b610c2981610b45565b8114610c3457600080fd5b50565b600081359050610c4681610c20565b92915050565b60008160000b9050919050565b610c6281610c4c565b8114610c6d57600080fd5b50565b600081359050610c7f81610c59565b92915050565b60008060408385031215610c9c57610c9b610b79565b5b6000610caa85828601610c37565b9250506020610cbb85828601610c70565b9150509250929050565b6000819050919050565b6000610cea610ce5610ce084610b45565b610cc5565b610b45565b9050919050565b610cfa81610ccf565b82525050565b6000602082019050610d156000830184610cf1565b92915050565b610d2481610c4c565b82525050565b6000602082019050610d3f6000830184610d1b565b92915050565b600060208284031215610d5b57610d5a610b79565b5b6000610d6984828501610b95565b91505092915050565b600060208284031215610d8857610d87610b79565b5b6000610d9684828501610c37565b91505092915050565b60038110610dac57600080fd5b50565b600081359050610dbe81610d9f565b92915050565b60008060408385031215610ddb57610dda610b79565b5b6000610de985828601610b95565b9250506020610dfa85828601610daf565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110610e4457610e43610e04565b5b50565b6000819050610e5582610e33565b919050565b6000610e6582610e47565b9050919050565b610e7581610e5a565b82525050565b6000602082019050610e906000830184610e6c565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008160011c9050919050565b6000808291508390505b6001851115610f1c57808604811115610ef857610ef7610e96565b5b6001851615610f075780820291505b8081029050610f1585610ec5565b9450610edc565b94509492505050565b600082610f355760019050610ff1565b81610f435760009050610ff1565b8160018114610f595760028114610f6357610f92565b6001915050610ff1565b60ff841115610f7557610f74610e96565b5b8360020a915084821115610f8c57610f8b610e96565b5b50610ff1565b5060208310610133831016604e8410600b8410161715610fc75782820a905083811115610fc257610fc1610e96565b5b610ff1565b610fd48484846001610ed2565b92509050818404811115610feb57610fea610e96565b5b81810290505b9392505050565b600061100382610b45565b915061100e83610b45565b925061103b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f25565b905092915050565b600061104e82610c4c565b915061105983610c4c565b925082820190507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808112607f8213171561109657611095610e96565b5b92915050565b600082825260208201905092915050565b7f4552524f523a464d2d3031303a4558504f4e454e545f544f4f5f534d414c4c00600082015250565b60006110e3601f8361109c565b91506110ee826110ad565b602082019050919050565b60006020820190508181036000830152611112816110d6565b9050919050565b7f4552524f523a464d2d3031313a4558504f4e454e545f544f4f5f4c4152474500600082015250565b600061114f601f8361109c565b915061115a82611119565b602082019050919050565b6000602082019050818103600083015261117e81611142565b9050919050565b600060ff82169050919050565b600061119d82610b45565b91506111a883611185565b92506111d57fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f25565b905092915050565b60006111e882610b45565b91506111f383610b45565b925082820261120181610b45565b9150828204841483151761121857611217610e96565b5b5092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061125982610b45565b915061126483610b45565b9250826112745761127361121f565b5b828204905092915050565b600061128a82610b45565b915061129583610b45565b92508282019050808211156112ad576112ac610e96565b5b92915050565b7f4552524f523a55464d2d3032303a44495649534f525f5a45524f000000000000600082015250565b60006112e9601a8361109c565b91506112f4826112b3565b602082019050919050565b60006020820190508181036000830152611318816112dc565b9050919050565b7f4552524f523a55464d2d3031303a4e454741544956455f524553554c54000000600082015250565b6000611355601d8361109c565b91506113608261131f565b602082019050919050565b6000602082019050818103600083015261138481611348565b9050919050565b600061139682610b45565b91506113a183610b45565b92508282039050818111156113b9576113b8610e96565b5b92915050565b7f4d6174683a206d756c446976206f766572666c6f770000000000000000000000600082015250565b60006113f560158361109c565b9150611400826113bf565b602082019050919050565b60006020820190508181036000830152611424816113e8565b905091905056fea2646970667358221220bf772f319279e8a730fb378a682a66e501c7fed8a14e78e8f812c310a6c4cffc64736f6c63430008140033",
451
451
  "linkReferences": {},
452
452
  "deployedLinkReferences": {}
453
453
  }
@@ -0,0 +1,4 @@
1
+ {
2
+ "_format": "hh-sol-dbg-1",
3
+ "buildInfo": "../../../build-info/746f2ad7b0d888e05db828a61f6d5e10.json"
4
+ }
@@ -0,0 +1,139 @@
1
+ {
2
+ "_format": "hh-sol-artifact-1",
3
+ "contractName": "VersionLib",
4
+ "sourceName": "contracts/types/Version.sol",
5
+ "abi": [
6
+ {
7
+ "inputs": [
8
+ {
9
+ "internalType": "Version",
10
+ "name": "version",
11
+ "type": "uint24"
12
+ }
13
+ ],
14
+ "name": "toInt",
15
+ "outputs": [
16
+ {
17
+ "internalType": "uint256",
18
+ "name": "",
19
+ "type": "uint256"
20
+ }
21
+ ],
22
+ "stateMutability": "pure",
23
+ "type": "function"
24
+ },
25
+ {
26
+ "inputs": [
27
+ {
28
+ "internalType": "Version",
29
+ "name": "version",
30
+ "type": "uint24"
31
+ }
32
+ ],
33
+ "name": "toMajorPart",
34
+ "outputs": [
35
+ {
36
+ "internalType": "VersionPart",
37
+ "name": "major",
38
+ "type": "uint8"
39
+ }
40
+ ],
41
+ "stateMutability": "pure",
42
+ "type": "function"
43
+ },
44
+ {
45
+ "inputs": [
46
+ {
47
+ "internalType": "uint256",
48
+ "name": "major",
49
+ "type": "uint256"
50
+ },
51
+ {
52
+ "internalType": "uint256",
53
+ "name": "minor",
54
+ "type": "uint256"
55
+ },
56
+ {
57
+ "internalType": "uint256",
58
+ "name": "patch",
59
+ "type": "uint256"
60
+ }
61
+ ],
62
+ "name": "toVersion",
63
+ "outputs": [
64
+ {
65
+ "internalType": "Version",
66
+ "name": "",
67
+ "type": "uint24"
68
+ }
69
+ ],
70
+ "stateMutability": "pure",
71
+ "type": "function"
72
+ },
73
+ {
74
+ "inputs": [
75
+ {
76
+ "internalType": "uint256",
77
+ "name": "versionPart",
78
+ "type": "uint256"
79
+ }
80
+ ],
81
+ "name": "toVersionPart",
82
+ "outputs": [
83
+ {
84
+ "internalType": "VersionPart",
85
+ "name": "",
86
+ "type": "uint8"
87
+ }
88
+ ],
89
+ "stateMutability": "pure",
90
+ "type": "function"
91
+ },
92
+ {
93
+ "inputs": [
94
+ {
95
+ "internalType": "Version",
96
+ "name": "version",
97
+ "type": "uint24"
98
+ }
99
+ ],
100
+ "name": "toVersionParts",
101
+ "outputs": [
102
+ {
103
+ "internalType": "VersionPart",
104
+ "name": "major",
105
+ "type": "uint8"
106
+ },
107
+ {
108
+ "internalType": "VersionPart",
109
+ "name": "minor",
110
+ "type": "uint8"
111
+ },
112
+ {
113
+ "internalType": "VersionPart",
114
+ "name": "patch",
115
+ "type": "uint8"
116
+ }
117
+ ],
118
+ "stateMutability": "pure",
119
+ "type": "function"
120
+ },
121
+ {
122
+ "inputs": [],
123
+ "name": "zeroVersion",
124
+ "outputs": [
125
+ {
126
+ "internalType": "Version",
127
+ "name": "",
128
+ "type": "uint24"
129
+ }
130
+ ],
131
+ "stateMutability": "pure",
132
+ "type": "function"
133
+ }
134
+ ],
135
+ "bytecode": "0x610656610053600b82828239805160001a607314610046577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe730000000000000000000000000000000000000000301460806040526004361061006c5760003560e01c806304b8f6c5146100715780632efe01131461008f57806349a7111a146100bf57806355601007146100f15780638e4ad86c14610121578063c9e66e2914610151575b600080fd5b610079610181565b60405161008691906102fa565b60405180910390f35b6100a960048036038101906100a49190610350565b610186565b6040516100b691906102fa565b60405180910390f35b6100d960048036038101906100d491906103cf565b61020e565b6040516100e89392919061043a565b60405180910390f35b61010b600480360381019061010691906103cf565b610279565b6040516101189190610480565b60405180910390f35b61013b6004803603810190610136919061049b565b610288565b60405161014891906104c8565b60405180910390f35b61016b600480360381019061016691906103cf565b610292565b60405161017891906104c8565b60405180910390f35b600090565b60006101008410801561019a575061010083105b80156101a7575061010082105b6101e6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101dd90610566565b60405180910390fd5b81600884901b601086901b6101fb91906105b5565b61020591906105b5565b90509392505050565b600080600080849050600060108262ffffff16901c905060108160ff16901b60ff168261023b91906105e9565b9150600060088362ffffff16901c9050600060088260ff16901b60ff168461026391906105e9565b9050828282965096509650505050509193909250565b60008162ffffff169050919050565b6000819050919050565b600080829050600060108262ffffff16901c90508092505050919050565b600062ffffff82169050919050565b6000819050919050565b60006102e46102df6102da846102b0565b6102bf565b6102b0565b9050919050565b6102f4816102c9565b82525050565b600060208201905061030f60008301846102eb565b92915050565b600080fd5b6000819050919050565b61032d8161031a565b811461033857600080fd5b50565b60008135905061034a81610324565b92915050565b60008060006060848603121561036957610368610315565b5b60006103778682870161033b565b93505060206103888682870161033b565b92505060406103998682870161033b565b9150509250925092565b6103ac816102b0565b81146103b757600080fd5b50565b6000813590506103c9816103a3565b92915050565b6000602082840312156103e5576103e4610315565b5b60006103f3848285016103ba565b91505092915050565b600060ff82169050919050565b600061042461041f61041a846103fc565b6102bf565b6103fc565b9050919050565b61043481610409565b82525050565b600060608201905061044f600083018661042b565b61045c602083018561042b565b610469604083018461042b565b949350505050565b61047a8161031a565b82525050565b60006020820190506104956000830184610471565b92915050565b6000602082840312156104b1576104b0610315565b5b60006104bf8482850161033b565b91505092915050565b60006020820190506104dd600083018461042b565b92915050565b600082825260208201905092915050565b7f4552524f523a5652532d3031303a56455253494f4e5f504152545f544f4f5f4260008201527f4947000000000000000000000000000000000000000000000000000000000000602082015250565b60006105506022836104e3565b915061055b826104f4565b604082019050919050565b6000602082019050818103600083015261057f81610543565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006105c08261031a565b91506105cb8361031a565b92508282019050808211156105e3576105e2610586565b5b92915050565b60006105f4826102b0565b91506105ff836102b0565b9250828203905062ffffff81111561061a57610619610586565b5b9291505056fea2646970667358221220e9dfc763417bd7f39d2043c21beb9c3cd830888e6733558a1b20cddf8a286b5564736f6c63430008140033",
136
+ "deployedBytecode": "0x730000000000000000000000000000000000000000301460806040526004361061006c5760003560e01c806304b8f6c5146100715780632efe01131461008f57806349a7111a146100bf57806355601007146100f15780638e4ad86c14610121578063c9e66e2914610151575b600080fd5b610079610181565b60405161008691906102fa565b60405180910390f35b6100a960048036038101906100a49190610350565b610186565b6040516100b691906102fa565b60405180910390f35b6100d960048036038101906100d491906103cf565b61020e565b6040516100e89392919061043a565b60405180910390f35b61010b600480360381019061010691906103cf565b610279565b6040516101189190610480565b60405180910390f35b61013b6004803603810190610136919061049b565b610288565b60405161014891906104c8565b60405180910390f35b61016b600480360381019061016691906103cf565b610292565b60405161017891906104c8565b60405180910390f35b600090565b60006101008410801561019a575061010083105b80156101a7575061010082105b6101e6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101dd90610566565b60405180910390fd5b81600884901b601086901b6101fb91906105b5565b61020591906105b5565b90509392505050565b600080600080849050600060108262ffffff16901c905060108160ff16901b60ff168261023b91906105e9565b9150600060088362ffffff16901c9050600060088260ff16901b60ff168461026391906105e9565b9050828282965096509650505050509193909250565b60008162ffffff169050919050565b6000819050919050565b600080829050600060108262ffffff16901c90508092505050919050565b600062ffffff82169050919050565b6000819050919050565b60006102e46102df6102da846102b0565b6102bf565b6102b0565b9050919050565b6102f4816102c9565b82525050565b600060208201905061030f60008301846102eb565b92915050565b600080fd5b6000819050919050565b61032d8161031a565b811461033857600080fd5b50565b60008135905061034a81610324565b92915050565b60008060006060848603121561036957610368610315565b5b60006103778682870161033b565b93505060206103888682870161033b565b92505060406103998682870161033b565b9150509250925092565b6103ac816102b0565b81146103b757600080fd5b50565b6000813590506103c9816103a3565b92915050565b6000602082840312156103e5576103e4610315565b5b60006103f3848285016103ba565b91505092915050565b600060ff82169050919050565b600061042461041f61041a846103fc565b6102bf565b6103fc565b9050919050565b61043481610409565b82525050565b600060608201905061044f600083018661042b565b61045c602083018561042b565b610469604083018461042b565b949350505050565b61047a8161031a565b82525050565b60006020820190506104956000830184610471565b92915050565b6000602082840312156104b1576104b0610315565b5b60006104bf8482850161033b565b91505092915050565b60006020820190506104dd600083018461042b565b92915050565b600082825260208201905092915050565b7f4552524f523a5652532d3031303a56455253494f4e5f504152545f544f4f5f4260008201527f4947000000000000000000000000000000000000000000000000000000000000602082015250565b60006105506022836104e3565b915061055b826104f4565b604082019050919050565b6000602082019050818103600083015261057f81610543565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006105c08261031a565b91506105cb8361031a565b92508282019050808211156105e3576105e2610586565b5b92915050565b60006105f4826102b0565b91506105ff836102b0565b9250828203905062ffffff81111561061a57610619610586565b5b9291505056fea2646970667358221220e9dfc763417bd7f39d2043c21beb9c3cd830888e6733558a1b20cddf8a286b5564736f6c63430008140033",
137
+ "linkReferences": {},
138
+ "deployedLinkReferences": {}
139
+ }
@@ -0,0 +1,4 @@
1
+ {
2
+ "_format": "hh-sol-dbg-1",
3
+ "buildInfo": "../../../build-info/746f2ad7b0d888e05db828a61f6d5e10.json"
4
+ }
@@ -0,0 +1,30 @@
1
+ {
2
+ "_format": "hh-sol-artifact-1",
3
+ "contractName": "VersionPartLib",
4
+ "sourceName": "contracts/types/Version.sol",
5
+ "abi": [
6
+ {
7
+ "inputs": [
8
+ {
9
+ "internalType": "VersionPart",
10
+ "name": "x",
11
+ "type": "uint8"
12
+ }
13
+ ],
14
+ "name": "toInt",
15
+ "outputs": [
16
+ {
17
+ "internalType": "uint256",
18
+ "name": "",
19
+ "type": "uint256"
20
+ }
21
+ ],
22
+ "stateMutability": "pure",
23
+ "type": "function"
24
+ }
25
+ ],
26
+ "bytecode": "0x61014c610053600b82828239805160001a607314610046577f4e487b7100000000000000000000000000000000000000000000000000000000600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600436106100355760003560e01c8063ac43d8341461003a575b600080fd5b610054600480360381019061004f91906100b5565b61006a565b60405161006191906100fb565b60405180910390f35b60008160ff169050919050565b600080fd5b600060ff82169050919050565b6100928161007c565b811461009d57600080fd5b50565b6000813590506100af81610089565b92915050565b6000602082840312156100cb576100ca610077565b5b60006100d9848285016100a0565b91505092915050565b6000819050919050565b6100f5816100e2565b82525050565b600060208201905061011060008301846100ec565b9291505056fea2646970667358221220971f855535d4d0bcc77f8cc0059f55647d69b8fdbd159fd425f6ab7091afefbb64736f6c63430008140033",
27
+ "deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600436106100355760003560e01c8063ac43d8341461003a575b600080fd5b610054600480360381019061004f91906100b5565b61006a565b60405161006191906100fb565b60405180910390f35b60008160ff169050919050565b600080fd5b600060ff82169050919050565b6100928161007c565b811461009d57600080fd5b50565b6000813590506100af81610089565b92915050565b6000602082840312156100cb576100ca610077565b5b60006100d9848285016100a0565b91505092915050565b6000819050919050565b6100f5816100e2565b82525050565b600060208201905061011060008301846100ec565b9291505056fea2646970667358221220971f855535d4d0bcc77f8cc0059f55647d69b8fdbd159fd425f6ab7091afefbb64736f6c63430008140033",
28
+ "linkReferences": {},
29
+ "deployedLinkReferences": {}
30
+ }
@@ -0,0 +1,88 @@
1
+ // SPDX-License-Identifier: Apache-2.0
2
+ pragma solidity ^0.8.19;
3
+
4
+ import {IERC20Metadata} from "@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol";
5
+
6
+ import {IRegisterable} from "../shared/IRegisterable.sol";
7
+ import {Registerable} from "../shared/Registerable.sol";
8
+
9
+ import {IRegistry} from "../registry/IRegistry.sol";
10
+ import {IInstance} from "../instance/IInstance.sol";
11
+
12
+ import {IInstance} from "../instance/IInstance.sol";
13
+ import {IComponent, IComponentModule} from "../instance/module/component/IComponent.sol";
14
+ import {IComponentOwnerService} from "../instance/service/IComponentOwnerService.sol";
15
+ import {IBaseComponent} from "./IBaseComponent.sol";
16
+ import {NftId} from "../types/NftId.sol";
17
+
18
+ abstract contract BaseComponent is
19
+ Registerable,
20
+ IBaseComponent
21
+ {
22
+ IComponentOwnerService internal _componentOwnerService;
23
+
24
+ address internal _deployer;
25
+ address internal _wallet;
26
+ IERC20Metadata internal _token;
27
+ IInstance internal _instance;
28
+
29
+ constructor(
30
+ address registry,
31
+ NftId instanceNftId,
32
+ address token
33
+ )
34
+ Registerable(registry, instanceNftId)
35
+ {
36
+ IRegistry.ObjectInfo memory instanceInfo = _registry.getObjectInfo(instanceNftId);
37
+ _instance = IInstance(instanceInfo.objectAddress);
38
+ require(
39
+ _instance.supportsInterface(type(IInstance).interfaceId),
40
+ ""
41
+ );
42
+
43
+ _componentOwnerService = _instance.getComponentOwnerService();
44
+ _wallet = address(this);
45
+ _token = IERC20Metadata(token);
46
+ }
47
+
48
+ // from registerable
49
+ function register() public override(IRegisterable, Registerable) returns (NftId componentId) {
50
+ require(msg.sender == getOwner(), "");
51
+ require(
52
+ address(_registry) != address(0),
53
+ "ERROR:COB-001:REGISTRY_ZERO"
54
+ );
55
+ require(
56
+ _registry.isRegistered(address(_instance)),
57
+ "ERROR:COB:INSTANCE_NOT_REGISTERED"
58
+ );
59
+
60
+ componentId = _componentOwnerService.register(this);
61
+ }
62
+
63
+ // from component contract
64
+ function lock() external onlyOwner override {
65
+ _componentOwnerService.lock(this);
66
+ }
67
+
68
+ function unlock() external onlyOwner override {
69
+ _componentOwnerService.unlock(this);
70
+ }
71
+
72
+ function getWallet()
73
+ external
74
+ view
75
+ override
76
+ returns (address walletAddress)
77
+ {
78
+ return _wallet;
79
+ }
80
+
81
+ function getToken() external view override returns (IERC20Metadata token) {
82
+ return _token;
83
+ }
84
+
85
+ function getInstance() external view override returns (IInstance instance) {
86
+ return _instance;
87
+ }
88
+ }
@@ -0,0 +1,19 @@
1
+ // SPDX-License-Identifier: Apache-2.0
2
+ pragma solidity ^0.8.19;
3
+
4
+ import {IERC20Metadata} from "@openzeppelin/contracts/token/ERC20/extensions/IERC20Metadata.sol";
5
+
6
+ import {IRegisterable} from "../shared/IRegisterable.sol";
7
+ import {IInstanceLinked} from "../instance/IInstanceLinked.sol";
8
+
9
+ interface IBaseComponent is IRegisterable, IInstanceLinked {
10
+
11
+ function lock() external;
12
+
13
+ function unlock() external;
14
+
15
+ function getToken() external view returns (IERC20Metadata token);
16
+
17
+ function getWallet() external view returns (address walletAddress);
18
+
19
+ }