@etherisc/gif-next 0.0.2-ebbe63d → 0.0.2-efdb520-159

Sign up to get free protection for your applications and to get access to all the features.
Files changed (275) hide show
  1. package/README.md +220 -1
  2. package/artifacts/contracts/components/BaseComponent.sol/BaseComponent.dbg.json +4 -0
  3. package/artifacts/contracts/components/BaseComponent.sol/BaseComponent.json +174 -0
  4. package/artifacts/contracts/components/IBaseComponent.sol/IBaseComponent.dbg.json +4 -0
  5. package/artifacts/contracts/components/IBaseComponent.sol/IBaseComponent.json +174 -0
  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/IProductComponent.sol/IProductComponent.json +279 -0
  10. package/artifacts/contracts/components/Pool.sol/Pool.dbg.json +4 -0
  11. package/artifacts/contracts/components/Pool.sol/Pool.json +387 -0
  12. package/artifacts/contracts/components/Product.sol/Product.dbg.json +4 -0
  13. package/artifacts/contracts/components/Product.sol/Product.json +305 -0
  14. package/artifacts/contracts/experiment/errors/Require.sol/Require.dbg.json +4 -0
  15. package/artifacts/contracts/experiment/errors/Require.sol/Require.json +105 -0
  16. package/artifacts/contracts/experiment/errors/Revert.sol/Revert.dbg.json +4 -0
  17. package/artifacts/contracts/experiment/errors/Revert.sol/Revert.json +105 -0
  18. package/artifacts/contracts/experiment/inheritance/A.sol/A.dbg.json +4 -0
  19. package/artifacts/contracts/experiment/inheritance/A.sol/A.json +128 -0
  20. package/artifacts/contracts/experiment/inheritance/A.sol/AShared.dbg.json +4 -0
  21. package/artifacts/contracts/experiment/inheritance/A.sol/AShared.json +42 -0
  22. package/artifacts/contracts/experiment/inheritance/B.sol/B.dbg.json +4 -0
  23. package/artifacts/contracts/experiment/inheritance/B.sol/B.json +76 -0
  24. package/artifacts/contracts/experiment/inheritance/C.sol/C.dbg.json +4 -0
  25. package/artifacts/contracts/experiment/inheritance/C.sol/C.json +89 -0
  26. package/artifacts/contracts/experiment/inheritance/IA.sol/IA.dbg.json +4 -0
  27. package/artifacts/contracts/experiment/inheritance/IA.sol/IA.json +128 -0
  28. package/artifacts/contracts/experiment/inheritance/IA.sol/ISharedA.dbg.json +4 -0
  29. package/artifacts/contracts/experiment/inheritance/IA.sol/ISharedA.json +37 -0
  30. package/artifacts/contracts/experiment/inheritance/IB.sol/IB.dbg.json +4 -0
  31. package/artifacts/contracts/experiment/inheritance/IB.sol/IB.json +50 -0
  32. package/artifacts/contracts/experiment/inheritance/IC.sol/IC.dbg.json +4 -0
  33. package/artifacts/contracts/experiment/inheritance/IC.sol/IC.json +63 -0
  34. package/artifacts/contracts/experiment/statemachine/Dummy.sol/LifeCycleModule.dbg.json +4 -0
  35. package/artifacts/contracts/experiment/statemachine/Dummy.sol/LifeCycleModule.json +59 -0
  36. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISM.dbg.json +4 -0
  37. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISM.json +124 -0
  38. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISMEE.dbg.json +4 -0
  39. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISMEE.json +74 -0
  40. package/artifacts/contracts/experiment/statemachine/SM.sol/SM.dbg.json +4 -0
  41. package/artifacts/contracts/experiment/statemachine/SM.sol/SM.json +124 -0
  42. package/artifacts/contracts/experiment/statemachine/SimpleStateMachine.sol/SimpleStateMachine.dbg.json +4 -0
  43. package/artifacts/contracts/experiment/statemachine/SimpleStateMachine.sol/SimpleStateMachine.json +207 -0
  44. package/artifacts/contracts/experiment/types/TypeA.sol/TypeALib.dbg.json +4 -0
  45. package/artifacts/contracts/experiment/types/TypeA.sol/TypeALib.json +10 -0
  46. package/artifacts/contracts/experiment/types/TypeB.sol/TypeBLib.dbg.json +4 -0
  47. package/artifacts/contracts/experiment/types/TypeB.sol/TypeBLib.json +10 -0
  48. package/artifacts/contracts/instance/IInstance.sol/IInstance.dbg.json +4 -0
  49. package/artifacts/contracts/instance/IInstance.sol/IInstance.json +2022 -0
  50. package/artifacts/contracts/instance/IInstanceLinked.sol/IInstanceLinked.dbg.json +4 -0
  51. package/artifacts/contracts/instance/IInstanceLinked.sol/IInstanceLinked.json +24 -0
  52. package/artifacts/contracts/instance/IServiceLinked.sol/IServiceLinked.dbg.json +4 -0
  53. package/artifacts/contracts/instance/IServiceLinked.sol/IServiceLinked.json +50 -0
  54. package/artifacts/contracts/instance/Instance.sol/Instance.dbg.json +4 -0
  55. package/artifacts/contracts/instance/Instance.sol/Instance.json +2288 -0
  56. package/artifacts/contracts/instance/InstanceBase.sol/InstanceBase.dbg.json +4 -0
  57. package/artifacts/contracts/instance/InstanceBase.sol/InstanceBase.json +313 -0
  58. package/artifacts/contracts/instance/module/access/Access.sol/AccessModule.dbg.json +4 -0
  59. package/artifacts/contracts/instance/module/access/Access.sol/AccessModule.json +333 -0
  60. package/artifacts/contracts/instance/module/access/IAccess.sol/IAccess.dbg.json +4 -0
  61. package/artifacts/contracts/instance/module/access/IAccess.sol/IAccess.json +10 -0
  62. package/artifacts/contracts/instance/module/access/IAccess.sol/IAccessModule.dbg.json +4 -0
  63. package/artifacts/contracts/instance/module/access/IAccess.sol/IAccessModule.json +333 -0
  64. package/artifacts/contracts/instance/module/bundle/BundleModule.sol/BundleModule.dbg.json +4 -0
  65. package/artifacts/contracts/instance/module/bundle/BundleModule.sol/BundleModule.json +276 -0
  66. package/artifacts/contracts/instance/module/bundle/IBundle.sol/IBundle.dbg.json +4 -0
  67. package/artifacts/contracts/instance/module/bundle/IBundle.sol/IBundle.json +10 -0
  68. package/artifacts/contracts/instance/module/bundle/IBundle.sol/IBundleModule.dbg.json +4 -0
  69. package/artifacts/contracts/instance/module/bundle/IBundle.sol/IBundleModule.json +276 -0
  70. package/artifacts/contracts/instance/module/component/ComponentModule.sol/ComponentModule.dbg.json +4 -0
  71. package/artifacts/contracts/instance/module/component/ComponentModule.sol/ComponentModule.json +188 -0
  72. package/artifacts/contracts/instance/module/component/IComponent.sol/IComponent.dbg.json +4 -0
  73. package/artifacts/contracts/instance/module/component/IComponent.sol/IComponent.json +10 -0
  74. package/artifacts/contracts/instance/module/component/IComponent.sol/IComponentModule.dbg.json +4 -0
  75. package/artifacts/contracts/instance/module/component/IComponent.sol/IComponentModule.json +188 -0
  76. package/artifacts/contracts/instance/module/lifecycle/ILifecycle.sol/ILifecycle.dbg.json +4 -0
  77. package/artifacts/contracts/instance/module/lifecycle/ILifecycle.sol/ILifecycle.json +134 -0
  78. package/artifacts/contracts/instance/module/lifecycle/ILifecycle.sol/ILifecycleModule.dbg.json +4 -0
  79. package/artifacts/contracts/instance/module/lifecycle/ILifecycle.sol/ILifecycleModule.json +182 -0
  80. package/artifacts/contracts/instance/module/lifecycle/LifecycleModule.sol/LifecycleModule.dbg.json +4 -0
  81. package/artifacts/contracts/instance/module/lifecycle/LifecycleModule.sol/LifecycleModule.json +221 -0
  82. package/artifacts/contracts/instance/module/policy/IPolicy.sol/IPolicy.dbg.json +4 -0
  83. package/artifacts/contracts/instance/module/policy/IPolicy.sol/IPolicy.json +10 -0
  84. package/artifacts/contracts/instance/module/policy/IPolicy.sol/IPolicyModule.dbg.json +4 -0
  85. package/artifacts/contracts/instance/module/policy/IPolicy.sol/IPolicyModule.json +261 -0
  86. package/artifacts/contracts/instance/module/policy/PolicyModule.sol/PolicyModule.dbg.json +4 -0
  87. package/artifacts/contracts/instance/module/policy/PolicyModule.sol/PolicyModule.json +261 -0
  88. package/artifacts/contracts/instance/module/pool/IPoolModule.sol/IPool.dbg.json +4 -0
  89. package/artifacts/contracts/instance/module/pool/IPoolModule.sol/IPool.json +10 -0
  90. package/artifacts/contracts/instance/module/pool/IPoolModule.sol/IPoolModule.dbg.json +4 -0
  91. package/artifacts/contracts/instance/module/pool/IPoolModule.sol/IPoolModule.json +149 -0
  92. package/artifacts/contracts/instance/module/pool/PoolModule.sol/PoolModule.dbg.json +4 -0
  93. package/artifacts/contracts/instance/module/pool/PoolModule.sol/PoolModule.json +149 -0
  94. package/artifacts/contracts/instance/module/product/IProductModule.sol/IProductModule.dbg.json +4 -0
  95. package/artifacts/contracts/instance/module/product/IProductModule.sol/IProductModule.json +10 -0
  96. package/artifacts/contracts/instance/module/product/ProductModule.sol/ProductModule.dbg.json +4 -0
  97. package/artifacts/contracts/instance/module/product/ProductModule.sol/ProductModule.json +10 -0
  98. package/artifacts/contracts/instance/module/treasury/ITreasury.sol/ITreasury.dbg.json +4 -0
  99. package/artifacts/contracts/instance/module/treasury/ITreasury.sol/ITreasury.json +10 -0
  100. package/artifacts/contracts/instance/module/treasury/ITreasury.sol/ITreasuryModule.dbg.json +4 -0
  101. package/artifacts/contracts/instance/module/treasury/ITreasury.sol/ITreasuryModule.json +538 -0
  102. package/artifacts/contracts/instance/module/treasury/TokenHandler.sol/TokenHandler.dbg.json +4 -0
  103. package/artifacts/contracts/instance/module/treasury/TokenHandler.sol/TokenHandler.json +76 -0
  104. package/artifacts/contracts/instance/module/treasury/TreasuryModule.sol/TreasuryModule.dbg.json +4 -0
  105. package/artifacts/contracts/instance/module/treasury/TreasuryModule.sol/TreasuryModule.json +538 -0
  106. package/artifacts/contracts/instance/service/ComponentOwnerService.sol/ComponentOwnerService.dbg.json +4 -0
  107. package/artifacts/contracts/instance/service/ComponentOwnerService.sol/ComponentOwnerService.json +519 -0
  108. package/artifacts/contracts/instance/service/ComponentServiceBase.sol/ComponentServiceBase.dbg.json +4 -0
  109. package/artifacts/contracts/instance/service/ComponentServiceBase.sol/ComponentServiceBase.json +300 -0
  110. package/artifacts/contracts/instance/service/IComponentOwnerService.sol/IComponentOwnerService.dbg.json +4 -0
  111. package/artifacts/contracts/instance/service/IComponentOwnerService.sol/IComponentOwnerService.json +364 -0
  112. package/artifacts/contracts/instance/service/IPoolService.sol/IPoolService.dbg.json +4 -0
  113. package/artifacts/contracts/instance/service/IPoolService.sol/IPoolService.json +376 -0
  114. package/artifacts/contracts/instance/service/IProductService.sol/IProductService.dbg.json +4 -0
  115. package/artifacts/contracts/instance/service/IProductService.sol/IProductService.json +477 -0
  116. package/artifacts/contracts/instance/service/IService.sol/IService.dbg.json +4 -0
  117. package/artifacts/contracts/instance/service/IService.sol/IService.json +300 -0
  118. package/artifacts/contracts/instance/service/PoolService.sol/PoolService.dbg.json +4 -0
  119. package/artifacts/contracts/instance/service/PoolService.sol/PoolService.json +499 -0
  120. package/artifacts/contracts/instance/service/ProductService.sol/ProductService.dbg.json +4 -0
  121. package/artifacts/contracts/instance/service/ProductService.sol/ProductService.json +685 -0
  122. package/artifacts/contracts/instance/service/ServiceBase.sol/ServiceBase.dbg.json +4 -0
  123. package/artifacts/contracts/instance/service/ServiceBase.sol/ServiceBase.json +300 -0
  124. package/artifacts/contracts/registry/ChainNft.sol/ChainNft.dbg.json +4 -0
  125. package/artifacts/contracts/registry/ChainNft.sol/ChainNft.json +597 -0
  126. package/artifacts/contracts/registry/IChainNft.sol/IChainNft.dbg.json +4 -0
  127. package/artifacts/contracts/registry/IChainNft.sol/IChainNft.json +452 -0
  128. package/artifacts/contracts/registry/IRegistry.sol/IRegistry.dbg.json +4 -0
  129. package/artifacts/contracts/registry/IRegistry.sol/IRegistry.json +305 -0
  130. package/artifacts/contracts/registry/IRegistryLinked.sol/IRegistryLinked.dbg.json +4 -0
  131. package/artifacts/contracts/registry/IRegistryLinked.sol/IRegistryLinked.json +24 -0
  132. package/artifacts/contracts/registry/Registry.sol/Registry.dbg.json +4 -0
  133. package/artifacts/contracts/registry/Registry.sol/Registry.json +472 -0
  134. package/artifacts/contracts/shared/ERC165.sol/ERC165.dbg.json +4 -0
  135. package/artifacts/contracts/shared/ERC165.sol/ERC165.json +35 -0
  136. package/artifacts/contracts/shared/IOwnable.sol/IOwnable.dbg.json +4 -0
  137. package/artifacts/contracts/shared/IOwnable.sol/IOwnable.json +24 -0
  138. package/artifacts/contracts/shared/IRegisterable.sol/IRegisterable.dbg.json +4 -0
  139. package/artifacts/contracts/shared/IRegisterable.sol/IRegisterable.json +121 -0
  140. package/artifacts/contracts/shared/IVersionable.sol/IVersionable.dbg.json +4 -0
  141. package/artifacts/contracts/shared/IVersionable.sol/IVersionable.json +164 -0
  142. package/artifacts/contracts/shared/Registerable.sol/Registerable.dbg.json +4 -0
  143. package/artifacts/contracts/shared/Registerable.sol/Registerable.json +121 -0
  144. package/artifacts/contracts/shared/Versionable.sol/Versionable.dbg.json +4 -0
  145. package/artifacts/contracts/shared/Versionable.sol/Versionable.json +164 -0
  146. package/artifacts/contracts/test/TestFee.sol/TestFee.dbg.json +4 -0
  147. package/artifacts/contracts/test/TestFee.sol/TestFee.json +95 -0
  148. package/artifacts/contracts/test/TestPool.sol/TestPool.dbg.json +4 -0
  149. package/artifacts/contracts/test/TestPool.sol/TestPool.json +387 -0
  150. package/artifacts/contracts/test/TestProduct.sol/TestProduct.dbg.json +4 -0
  151. package/artifacts/contracts/test/TestProduct.sol/TestProduct.json +393 -0
  152. package/artifacts/contracts/test/TestRegisterable.sol/TestRegisterable.dbg.json +4 -0
  153. package/artifacts/contracts/test/TestRegisterable.sol/TestRegisterable.json +137 -0
  154. package/artifacts/contracts/test/TestRoleId.sol/TestRoleId.dbg.json +4 -0
  155. package/artifacts/contracts/test/TestRoleId.sol/TestRoleId.json +82 -0
  156. package/artifacts/contracts/test/TestService.sol/TestService.dbg.json +4 -0
  157. package/artifacts/contracts/test/TestService.sol/TestService.json +407 -0
  158. package/artifacts/contracts/test/TestToken.sol/TestUsdc.dbg.json +4 -0
  159. package/artifacts/contracts/test/TestToken.sol/TestUsdc.json +338 -0
  160. package/artifacts/contracts/test/TestVersion.sol/TestVersion.dbg.json +4 -0
  161. package/artifacts/contracts/test/TestVersion.sol/TestVersion.json +222 -0
  162. package/artifacts/contracts/test/TestVersionable.sol/TestVersionable.dbg.json +4 -0
  163. package/artifacts/contracts/test/TestVersionable.sol/TestVersionable.json +230 -0
  164. package/artifacts/contracts/types/AddressSet.sol/LibAddressSet.dbg.json +4 -0
  165. package/artifacts/contracts/types/AddressSet.sol/LibAddressSet.json +10 -0
  166. package/artifacts/contracts/types/Blocknumber.sol/BlocknumberLib.dbg.json +4 -0
  167. package/artifacts/contracts/types/Blocknumber.sol/BlocknumberLib.json +174 -0
  168. package/artifacts/contracts/types/ChainId.sol/ChainIdLib.dbg.json +4 -0
  169. package/artifacts/contracts/types/ChainId.sol/ChainIdLib.json +10 -0
  170. package/artifacts/contracts/types/NftId.sol/NftIdLib.dbg.json +4 -0
  171. package/artifacts/contracts/types/NftId.sol/NftIdLib.json +92 -0
  172. package/artifacts/contracts/types/NftIdSet.sol/LibNftIdSet.dbg.json +4 -0
  173. package/artifacts/contracts/types/NftIdSet.sol/LibNftIdSet.json +10 -0
  174. package/artifacts/contracts/types/ObjectType.sol/ObjectTypeLib.dbg.json +4 -0
  175. package/artifacts/contracts/types/ObjectType.sol/ObjectTypeLib.json +92 -0
  176. package/artifacts/contracts/types/StateId.sol/StateIdLib.dbg.json +4 -0
  177. package/artifacts/contracts/types/StateId.sol/StateIdLib.json +92 -0
  178. package/artifacts/contracts/types/Timestamp.sol/TimestampLib.dbg.json +4 -0
  179. package/artifacts/contracts/types/Timestamp.sol/TimestampLib.json +236 -0
  180. package/artifacts/contracts/types/UFixed.sol/UFixedMathLib.dbg.json +4 -0
  181. package/artifacts/contracts/types/UFixed.sol/UFixedMathLib.json +453 -0
  182. package/artifacts/contracts/types/Version.sol/VersionLib.dbg.json +4 -0
  183. package/artifacts/contracts/types/Version.sol/VersionLib.json +78 -0
  184. package/artifacts/contracts/types/Version.sol/VersionPartLib.dbg.json +4 -0
  185. package/artifacts/contracts/types/Version.sol/VersionPartLib.json +30 -0
  186. package/contracts/components/BaseComponent.sol +89 -0
  187. package/contracts/components/IBaseComponent.sol +19 -0
  188. package/contracts/components/IPoolComponent.sol +57 -0
  189. package/contracts/components/IProductComponent.sol +19 -0
  190. package/contracts/components/Pool.sol +174 -0
  191. package/contracts/components/Product.sol +117 -0
  192. package/contracts/experiment/errors/Require.sol +38 -0
  193. package/contracts/experiment/errors/Revert.sol +44 -0
  194. package/contracts/experiment/inheritance/A.sol +53 -0
  195. package/contracts/experiment/inheritance/B.sol +28 -0
  196. package/contracts/experiment/inheritance/C.sol +34 -0
  197. package/contracts/experiment/inheritance/IA.sol +13 -0
  198. package/contracts/experiment/inheritance/IB.sol +10 -0
  199. package/contracts/experiment/inheritance/IC.sol +12 -0
  200. package/contracts/experiment/statemachine/Dummy.sol +27 -0
  201. package/contracts/experiment/statemachine/ISM.sol +25 -0
  202. package/contracts/experiment/statemachine/README.md +112 -0
  203. package/contracts/experiment/statemachine/SM.sol +57 -0
  204. package/contracts/experiment/statemachine/SimpleStateMachine.sol +31 -0
  205. package/contracts/experiment/types/TypeA.sol +47 -0
  206. package/contracts/experiment/types/TypeB.sol +29 -0
  207. package/contracts/instance/IInstance.sol +50 -0
  208. package/contracts/instance/IInstanceLinked.sol +8 -0
  209. package/contracts/instance/IServiceLinked.sol +12 -0
  210. package/contracts/instance/Instance.sol +62 -0
  211. package/contracts/instance/InstanceBase.sol +74 -0
  212. package/contracts/instance/module/access/Access.sol +149 -0
  213. package/contracts/instance/module/access/IAccess.sol +53 -0
  214. package/contracts/instance/module/bundle/BundleModule.sol +228 -0
  215. package/contracts/instance/module/bundle/IBundle.sol +53 -0
  216. package/contracts/instance/module/component/ComponentModule.sol +104 -0
  217. package/contracts/instance/module/component/IComponent.sol +53 -0
  218. package/contracts/instance/module/lifecycle/ILifecycle.sol +47 -0
  219. package/contracts/instance/module/lifecycle/LifecycleModule.sol +89 -0
  220. package/contracts/instance/module/policy/IPolicy.sol +60 -0
  221. package/contracts/instance/module/policy/PolicyModule.sol +84 -0
  222. package/contracts/instance/module/pool/IPoolModule.sol +41 -0
  223. package/contracts/instance/module/pool/PoolModule.sol +87 -0
  224. package/contracts/instance/module/product/IProductModule.sol +6 -0
  225. package/contracts/instance/module/product/ProductModule.sol +8 -0
  226. package/contracts/instance/module/treasury/ITreasury.sol +104 -0
  227. package/contracts/instance/module/treasury/TokenHandler.sol +48 -0
  228. package/contracts/instance/module/treasury/TreasuryModule.sol +148 -0
  229. package/contracts/instance/service/ComponentOwnerService.sol +174 -0
  230. package/contracts/instance/service/ComponentServiceBase.sol +41 -0
  231. package/contracts/instance/service/IComponentOwnerService.sol +22 -0
  232. package/contracts/instance/service/IPoolService.sol +30 -0
  233. package/contracts/instance/service/IProductService.sol +58 -0
  234. package/contracts/instance/service/IService.sol +15 -0
  235. package/contracts/instance/service/PoolService.sol +98 -0
  236. package/contracts/instance/service/ProductService.sol +358 -0
  237. package/contracts/instance/service/ServiceBase.sol +39 -0
  238. package/contracts/registry/ChainNft.sol +159 -0
  239. package/contracts/registry/IChainNft.sol +21 -0
  240. package/contracts/registry/IRegistry.sol +57 -0
  241. package/contracts/registry/IRegistryLinked.sol +8 -0
  242. package/contracts/registry/Registry.sol +381 -0
  243. package/contracts/shared/ERC165.sol +21 -0
  244. package/contracts/shared/IOwnable.sol +6 -0
  245. package/contracts/shared/IRegisterable.sol +24 -0
  246. package/contracts/shared/IVersionable.sol +52 -0
  247. package/contracts/shared/Registerable.sol +86 -0
  248. package/contracts/shared/Versionable.sol +92 -0
  249. package/contracts/test/TestFee.sol +25 -0
  250. package/contracts/test/TestPool.sol +22 -0
  251. package/contracts/test/TestProduct.sol +44 -0
  252. package/contracts/test/TestRegisterable.sol +19 -0
  253. package/contracts/test/TestRoleId.sol +14 -0
  254. package/contracts/test/TestService.sol +35 -0
  255. package/contracts/{Dip.sol → test/TestToken.sol} +5 -5
  256. package/contracts/test/TestVersion.sol +47 -0
  257. package/contracts/test/TestVersionable.sol +20 -0
  258. package/contracts/types/AddressSet.sol +58 -0
  259. package/contracts/types/Blocknumber.sol +118 -0
  260. package/contracts/types/ChainId.sol +38 -0
  261. package/contracts/types/Fee.sol +32 -0
  262. package/contracts/types/NftId.sol +57 -0
  263. package/contracts/types/NftIdSet.sol +60 -0
  264. package/contracts/types/ObjectType.sol +115 -0
  265. package/contracts/types/RoleId.sol +36 -0
  266. package/contracts/types/StateId.sol +95 -0
  267. package/contracts/types/Timestamp.sol +123 -0
  268. package/contracts/types/UFixed.sol +206 -0
  269. package/contracts/types/Version.sol +91 -0
  270. package/package.json +24 -9
  271. package/artifacts/contracts/Dip.sol/DIP.dbg.json +0 -4
  272. package/artifacts/contracts/Dip.sol/DIP.json +0 -338
  273. package/artifacts/contracts/Lock.sol/Lock.dbg.json +0 -4
  274. package/artifacts/contracts/Lock.sol/Lock.json +0 -74
  275. package/contracts/Lock.sol +0 -34
@@ -1,338 +0,0 @@
1
- {
2
- "_format": "hh-sol-artifact-1",
3
- "contractName": "DIP",
4
- "sourceName": "contracts/Dip.sol",
5
- "abi": [
6
- {
7
- "inputs": [],
8
- "stateMutability": "nonpayable",
9
- "type": "constructor"
10
- },
11
- {
12
- "anonymous": false,
13
- "inputs": [
14
- {
15
- "indexed": true,
16
- "internalType": "address",
17
- "name": "owner",
18
- "type": "address"
19
- },
20
- {
21
- "indexed": true,
22
- "internalType": "address",
23
- "name": "spender",
24
- "type": "address"
25
- },
26
- {
27
- "indexed": false,
28
- "internalType": "uint256",
29
- "name": "value",
30
- "type": "uint256"
31
- }
32
- ],
33
- "name": "Approval",
34
- "type": "event"
35
- },
36
- {
37
- "anonymous": false,
38
- "inputs": [
39
- {
40
- "indexed": true,
41
- "internalType": "address",
42
- "name": "from",
43
- "type": "address"
44
- },
45
- {
46
- "indexed": true,
47
- "internalType": "address",
48
- "name": "to",
49
- "type": "address"
50
- },
51
- {
52
- "indexed": false,
53
- "internalType": "uint256",
54
- "name": "value",
55
- "type": "uint256"
56
- }
57
- ],
58
- "name": "Transfer",
59
- "type": "event"
60
- },
61
- {
62
- "inputs": [],
63
- "name": "DECIMALS",
64
- "outputs": [
65
- {
66
- "internalType": "uint8",
67
- "name": "",
68
- "type": "uint8"
69
- }
70
- ],
71
- "stateMutability": "view",
72
- "type": "function"
73
- },
74
- {
75
- "inputs": [],
76
- "name": "INITIAL_SUPPLY",
77
- "outputs": [
78
- {
79
- "internalType": "uint256",
80
- "name": "",
81
- "type": "uint256"
82
- }
83
- ],
84
- "stateMutability": "view",
85
- "type": "function"
86
- },
87
- {
88
- "inputs": [],
89
- "name": "NAME",
90
- "outputs": [
91
- {
92
- "internalType": "string",
93
- "name": "",
94
- "type": "string"
95
- }
96
- ],
97
- "stateMutability": "view",
98
- "type": "function"
99
- },
100
- {
101
- "inputs": [],
102
- "name": "SYMBOL",
103
- "outputs": [
104
- {
105
- "internalType": "string",
106
- "name": "",
107
- "type": "string"
108
- }
109
- ],
110
- "stateMutability": "view",
111
- "type": "function"
112
- },
113
- {
114
- "inputs": [
115
- {
116
- "internalType": "address",
117
- "name": "owner",
118
- "type": "address"
119
- },
120
- {
121
- "internalType": "address",
122
- "name": "spender",
123
- "type": "address"
124
- }
125
- ],
126
- "name": "allowance",
127
- "outputs": [
128
- {
129
- "internalType": "uint256",
130
- "name": "",
131
- "type": "uint256"
132
- }
133
- ],
134
- "stateMutability": "view",
135
- "type": "function"
136
- },
137
- {
138
- "inputs": [
139
- {
140
- "internalType": "address",
141
- "name": "spender",
142
- "type": "address"
143
- },
144
- {
145
- "internalType": "uint256",
146
- "name": "amount",
147
- "type": "uint256"
148
- }
149
- ],
150
- "name": "approve",
151
- "outputs": [
152
- {
153
- "internalType": "bool",
154
- "name": "",
155
- "type": "bool"
156
- }
157
- ],
158
- "stateMutability": "nonpayable",
159
- "type": "function"
160
- },
161
- {
162
- "inputs": [
163
- {
164
- "internalType": "address",
165
- "name": "account",
166
- "type": "address"
167
- }
168
- ],
169
- "name": "balanceOf",
170
- "outputs": [
171
- {
172
- "internalType": "uint256",
173
- "name": "",
174
- "type": "uint256"
175
- }
176
- ],
177
- "stateMutability": "view",
178
- "type": "function"
179
- },
180
- {
181
- "inputs": [],
182
- "name": "decimals",
183
- "outputs": [
184
- {
185
- "internalType": "uint8",
186
- "name": "",
187
- "type": "uint8"
188
- }
189
- ],
190
- "stateMutability": "pure",
191
- "type": "function"
192
- },
193
- {
194
- "inputs": [
195
- {
196
- "internalType": "address",
197
- "name": "spender",
198
- "type": "address"
199
- },
200
- {
201
- "internalType": "uint256",
202
- "name": "subtractedValue",
203
- "type": "uint256"
204
- }
205
- ],
206
- "name": "decreaseAllowance",
207
- "outputs": [
208
- {
209
- "internalType": "bool",
210
- "name": "",
211
- "type": "bool"
212
- }
213
- ],
214
- "stateMutability": "nonpayable",
215
- "type": "function"
216
- },
217
- {
218
- "inputs": [
219
- {
220
- "internalType": "address",
221
- "name": "spender",
222
- "type": "address"
223
- },
224
- {
225
- "internalType": "uint256",
226
- "name": "addedValue",
227
- "type": "uint256"
228
- }
229
- ],
230
- "name": "increaseAllowance",
231
- "outputs": [
232
- {
233
- "internalType": "bool",
234
- "name": "",
235
- "type": "bool"
236
- }
237
- ],
238
- "stateMutability": "nonpayable",
239
- "type": "function"
240
- },
241
- {
242
- "inputs": [],
243
- "name": "name",
244
- "outputs": [
245
- {
246
- "internalType": "string",
247
- "name": "",
248
- "type": "string"
249
- }
250
- ],
251
- "stateMutability": "view",
252
- "type": "function"
253
- },
254
- {
255
- "inputs": [],
256
- "name": "symbol",
257
- "outputs": [
258
- {
259
- "internalType": "string",
260
- "name": "",
261
- "type": "string"
262
- }
263
- ],
264
- "stateMutability": "view",
265
- "type": "function"
266
- },
267
- {
268
- "inputs": [],
269
- "name": "totalSupply",
270
- "outputs": [
271
- {
272
- "internalType": "uint256",
273
- "name": "",
274
- "type": "uint256"
275
- }
276
- ],
277
- "stateMutability": "view",
278
- "type": "function"
279
- },
280
- {
281
- "inputs": [
282
- {
283
- "internalType": "address",
284
- "name": "to",
285
- "type": "address"
286
- },
287
- {
288
- "internalType": "uint256",
289
- "name": "amount",
290
- "type": "uint256"
291
- }
292
- ],
293
- "name": "transfer",
294
- "outputs": [
295
- {
296
- "internalType": "bool",
297
- "name": "",
298
- "type": "bool"
299
- }
300
- ],
301
- "stateMutability": "nonpayable",
302
- "type": "function"
303
- },
304
- {
305
- "inputs": [
306
- {
307
- "internalType": "address",
308
- "name": "from",
309
- "type": "address"
310
- },
311
- {
312
- "internalType": "address",
313
- "name": "to",
314
- "type": "address"
315
- },
316
- {
317
- "internalType": "uint256",
318
- "name": "amount",
319
- "type": "uint256"
320
- }
321
- ],
322
- "name": "transferFrom",
323
- "outputs": [
324
- {
325
- "internalType": "bool",
326
- "name": "",
327
- "type": "bool"
328
- }
329
- ],
330
- "stateMutability": "nonpayable",
331
- "type": "function"
332
- }
333
- ],
334
- "bytecode": "0x608060405234801562000010575f80fd5b5060405180606001604052806028815260200162001d84602891396040518060400160405280600381526020017f44495000000000000000000000000000000000000000000000000000000000008152508160039081620000729190620004a8565b508060049081620000849190620004a8565b505050620000c86200009b620000ce60201b60201c565b6012600a620000ab919062000715565b633b9aca00620000bc919062000765565b620000d560201b60201c565b62000893565b5f33905090565b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff160362000146576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016200013d906200080d565b60405180910390fd5b620001595f83836200023a60201b60201c565b8060025f8282546200016c91906200082d565b92505081905550805f808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f82825401925050819055508173ffffffffffffffffffffffffffffffffffffffff165f73ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040516200021b919062000878565b60405180910390a3620002365f83836200023f60201b60201c565b5050565b505050565b505050565b5f81519050919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52604160045260245ffd5b7f4e487b71000000000000000000000000000000000000000000000000000000005f52602260045260245ffd5b5f6002820490506001821680620002c057607f821691505b602082108103620002d657620002d56200027b565b5b50919050565b5f819050815f5260205f209050919050565b5f6020601f8301049050919050565b5f82821b905092915050565b5f600883026200033a7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82620002fd565b620003468683620002fd565b95508019841693508086168417925050509392505050565b5f819050919050565b5f819050919050565b5f620003906200038a62000384846200035e565b62000367565b6200035e565b9050919050565b5f819050919050565b620003ab8362000370565b620003c3620003ba8262000397565b84845462000309565b825550505050565b5f90565b620003d9620003cb565b620003e6818484620003a0565b505050565b5b818110156200040d57620004015f82620003cf565b600181019050620003ec565b5050565b601f8211156200045c576200042681620002dc565b6200043184620002ee565b8101602085101562000441578190505b620004596200045085620002ee565b830182620003eb565b50505b505050565b5f82821c905092915050565b5f6200047e5f198460080262000461565b1980831691505092915050565b5f6200049883836200046d565b9150826002028217905092915050565b620004b38262000244565b67ffffffffffffffff811115620004cf57620004ce6200024e565b5b620004db8254620002a8565b620004e882828562000411565b5f60209050601f8311600181146200051e575f841562000509578287015190505b6200051585826200048b565b86555062000584565b601f1984166200052e86620002dc565b5f5b82811015620005575784890151825560018201915060208501945060208101905062000530565b8683101562000577578489015162000573601f8916826200046d565b8355505b6001600288020188555050505b505050505050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f8160011c9050919050565b5f808291508390505b60018511156200061657808604811115620005ee57620005ed6200058c565b5b6001851615620005fe5780820291505b80810290506200060e85620005b9565b9450620005ce565b94509492505050565b5f8262000630576001905062000702565b816200063f575f905062000702565b8160018114620006585760028114620006635762000699565b600191505062000702565b60ff8411156200067857620006776200058c565b5b8360020a9150848211156200069257620006916200058c565b5b5062000702565b5060208310610133831016604e8410600b8410161715620006d35782820a905083811115620006cd57620006cc6200058c565b5b62000702565b620006e28484846001620005c5565b92509050818404811115620006fc57620006fb6200058c565b5b81810290505b9392505050565b5f60ff82169050919050565b5f62000721826200035e565b91506200072e8362000709565b92506200075d7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff84846200061f565b905092915050565b5f62000771826200035e565b91506200077e836200035e565b92508282026200078e816200035e565b91508282048414831517620007a857620007a76200058c565b5b5092915050565b5f82825260208201905092915050565b7f45524332303a206d696e7420746f20746865207a65726f2061646472657373005f82015250565b5f620007f5601f83620007af565b91506200080282620007bf565b602082019050919050565b5f6020820190508181035f8301526200082681620007e7565b9050919050565b5f62000839826200035e565b915062000846836200035e565b92508282019050808211156200086157620008606200058c565b5b92915050565b62000872816200035e565b82525050565b5f6020820190506200088d5f83018462000867565b92915050565b6114e380620008a15f395ff3fe608060405234801561000f575f80fd5b50600436106100f3575f3560e01c80633950935111610095578063a457c2d711610064578063a457c2d714610289578063a9059cbb146102b9578063dd62ed3e146102e9578063f76f8d7814610319576100f3565b806339509351146101ed57806370a082311461021d57806395d89b411461024d578063a3f4df7e1461026b576100f3565b806323b872dd116100d157806323b872dd146101635780632e0f2625146101935780632ff2e9dc146101b1578063313ce567146101cf576100f3565b806306fdde03146100f7578063095ea7b31461011557806318160ddd14610145575b5f80fd5b6100ff610337565b60405161010c9190610c1b565b60405180910390f35b61012f600480360381019061012a9190610ccc565b6103c7565b60405161013c9190610d24565b60405180910390f35b61014d6103e9565b60405161015a9190610d4c565b60405180910390f35b61017d60048036038101906101789190610d65565b6103f2565b60405161018a9190610d24565b60405180910390f35b61019b610420565b6040516101a89190610dd0565b60405180910390f35b6101b9610425565b6040516101c69190610d4c565b60405180910390f35b6101d7610445565b6040516101e49190610dd0565b60405180910390f35b61020760048036038101906102029190610ccc565b61044d565b6040516102149190610d24565b60405180910390f35b61023760048036038101906102329190610de9565b610483565b6040516102449190610d4c565b60405180910390f35b6102556104c8565b6040516102629190610c1b565b60405180910390f35b610273610558565b6040516102809190610c1b565b60405180910390f35b6102a3600480360381019061029e9190610ccc565b610574565b6040516102b09190610d24565b60405180910390f35b6102d360048036038101906102ce9190610ccc565b6105e9565b6040516102e09190610d24565b60405180910390f35b61030360048036038101906102fe9190610e14565b61060b565b6040516103109190610d4c565b60405180910390f35b61032161068d565b60405161032e9190610c1b565b60405180910390f35b60606003805461034690610e7f565b80601f016020809104026020016040519081016040528092919081815260200182805461037290610e7f565b80156103bd5780601f10610394576101008083540402835291602001916103bd565b820191905f5260205f20905b8154815290600101906020018083116103a057829003601f168201915b5050505050905090565b5f806103d16106c6565b90506103de8185856106cd565b600191505092915050565b5f600254905090565b5f806103fc6106c6565b9050610409858285610890565b61041485858561091b565b60019150509392505050565b601281565b6012600a610433919061100b565b633b9aca006104429190611055565b81565b5f6012905090565b5f806104576106c6565b9050610478818585610469858961060b565b6104739190611096565b6106cd565b600191505092915050565b5f805f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20549050919050565b6060600480546104d790610e7f565b80601f016020809104026020016040519081016040528092919081815260200182805461050390610e7f565b801561054e5780601f106105255761010080835404028352916020019161054e565b820191905f5260205f20905b81548152906001019060200180831161053157829003601f168201915b5050505050905090565b6040518060600160405280602881526020016114866028913981565b5f8061057e6106c6565b90505f61058b828661060b565b9050838110156105d0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105c790611139565b60405180910390fd5b6105dd82868684036106cd565b60019250505092915050565b5f806105f36106c6565b905061060081858561091b565b600191505092915050565b5f60015f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f2054905092915050565b6040518060400160405280600381526020017f444950000000000000000000000000000000000000000000000000000000000081525081565b5f33905090565b5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff160361073b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610732906111c7565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036107a9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107a090611255565b60405180910390fd5b8060015f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040516108839190610d4c565b60405180910390a3505050565b5f61089b848461060b565b90507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146109155781811015610907576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108fe906112bd565b60405180910390fd5b61091484848484036106cd565b5b50505050565b5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603610989576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109809061134b565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036109f7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109ee906113d9565b60405180910390fd5b610a02838383610b87565b5f805f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f2054905081811015610a85576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a7c90611467565b60405180910390fd5b8181035f808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f2081905550815f808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f82825401925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610b6e9190610d4c565b60405180910390a3610b81848484610b8c565b50505050565b505050565b505050565b5f81519050919050565b5f82825260208201905092915050565b5f5b83811015610bc8578082015181840152602081019050610bad565b5f8484015250505050565b5f601f19601f8301169050919050565b5f610bed82610b91565b610bf78185610b9b565b9350610c07818560208601610bab565b610c1081610bd3565b840191505092915050565b5f6020820190508181035f830152610c338184610be3565b905092915050565b5f80fd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f610c6882610c3f565b9050919050565b610c7881610c5e565b8114610c82575f80fd5b50565b5f81359050610c9381610c6f565b92915050565b5f819050919050565b610cab81610c99565b8114610cb5575f80fd5b50565b5f81359050610cc681610ca2565b92915050565b5f8060408385031215610ce257610ce1610c3b565b5b5f610cef85828601610c85565b9250506020610d0085828601610cb8565b9150509250929050565b5f8115159050919050565b610d1e81610d0a565b82525050565b5f602082019050610d375f830184610d15565b92915050565b610d4681610c99565b82525050565b5f602082019050610d5f5f830184610d3d565b92915050565b5f805f60608486031215610d7c57610d7b610c3b565b5b5f610d8986828701610c85565b9350506020610d9a86828701610c85565b9250506040610dab86828701610cb8565b9150509250925092565b5f60ff82169050919050565b610dca81610db5565b82525050565b5f602082019050610de35f830184610dc1565b92915050565b5f60208284031215610dfe57610dfd610c3b565b5b5f610e0b84828501610c85565b91505092915050565b5f8060408385031215610e2a57610e29610c3b565b5b5f610e3785828601610c85565b9250506020610e4885828601610c85565b9150509250929050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52602260045260245ffd5b5f6002820490506001821680610e9657607f821691505b602082108103610ea957610ea8610e52565b5b50919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f8160011c9050919050565b5f808291508390505b6001851115610f3157808604811115610f0d57610f0c610eaf565b5b6001851615610f1c5780820291505b8081029050610f2a85610edc565b9450610ef1565b94509492505050565b5f82610f495760019050611004565b81610f56575f9050611004565b8160018114610f6c5760028114610f7657610fa5565b6001915050611004565b60ff841115610f8857610f87610eaf565b5b8360020a915084821115610f9f57610f9e610eaf565b5b50611004565b5060208310610133831016604e8410600b8410161715610fda5782820a905083811115610fd557610fd4610eaf565b5b611004565b610fe78484846001610ee8565b92509050818404811115610ffe57610ffd610eaf565b5b81810290505b9392505050565b5f61101582610c99565b915061102083610db5565b925061104d7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f3a565b905092915050565b5f61105f82610c99565b915061106a83610c99565b925082820261107881610c99565b9150828204841483151761108f5761108e610eaf565b5b5092915050565b5f6110a082610c99565b91506110ab83610c99565b92508282019050808211156110c3576110c2610eaf565b5b92915050565b7f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f775f8201527f207a65726f000000000000000000000000000000000000000000000000000000602082015250565b5f611123602583610b9b565b915061112e826110c9565b604082019050919050565b5f6020820190508181035f83015261115081611117565b9050919050565b7f45524332303a20617070726f76652066726f6d20746865207a65726f206164645f8201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b5f6111b1602483610b9b565b91506111bc82611157565b604082019050919050565b5f6020820190508181035f8301526111de816111a5565b9050919050565b7f45524332303a20617070726f766520746f20746865207a65726f2061646472655f8201527f7373000000000000000000000000000000000000000000000000000000000000602082015250565b5f61123f602283610b9b565b915061124a826111e5565b604082019050919050565b5f6020820190508181035f83015261126c81611233565b9050919050565b7f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000005f82015250565b5f6112a7601d83610b9b565b91506112b282611273565b602082019050919050565b5f6020820190508181035f8301526112d48161129b565b9050919050565b7f45524332303a207472616e736665722066726f6d20746865207a65726f2061645f8201527f6472657373000000000000000000000000000000000000000000000000000000602082015250565b5f611335602583610b9b565b9150611340826112db565b604082019050919050565b5f6020820190508181035f83015261136281611329565b9050919050565b7f45524332303a207472616e7366657220746f20746865207a65726f20616464725f8201527f6573730000000000000000000000000000000000000000000000000000000000602082015250565b5f6113c3602383610b9b565b91506113ce82611369565b604082019050919050565b5f6020820190508181035f8301526113f0816113b7565b9050919050565b7f45524332303a207472616e7366657220616d6f756e74206578636565647320625f8201527f616c616e63650000000000000000000000000000000000000000000000000000602082015250565b5f611451602683610b9b565b915061145c826113f7565b604082019050919050565b5f6020820190508181035f83015261147e81611445565b905091905056fe446563656e7472616c697a656420496e737572616e63652050726f746f636f6c202d2044554d4d59a2646970667358221220b5817fafe4925dedfbf7a88cb88310c1b3164f71f2d48445c354b2ba8929211964736f6c63430008140033446563656e7472616c697a656420496e737572616e63652050726f746f636f6c202d2044554d4d59",
335
- "deployedBytecode": "0x608060405234801561000f575f80fd5b50600436106100f3575f3560e01c80633950935111610095578063a457c2d711610064578063a457c2d714610289578063a9059cbb146102b9578063dd62ed3e146102e9578063f76f8d7814610319576100f3565b806339509351146101ed57806370a082311461021d57806395d89b411461024d578063a3f4df7e1461026b576100f3565b806323b872dd116100d157806323b872dd146101635780632e0f2625146101935780632ff2e9dc146101b1578063313ce567146101cf576100f3565b806306fdde03146100f7578063095ea7b31461011557806318160ddd14610145575b5f80fd5b6100ff610337565b60405161010c9190610c1b565b60405180910390f35b61012f600480360381019061012a9190610ccc565b6103c7565b60405161013c9190610d24565b60405180910390f35b61014d6103e9565b60405161015a9190610d4c565b60405180910390f35b61017d60048036038101906101789190610d65565b6103f2565b60405161018a9190610d24565b60405180910390f35b61019b610420565b6040516101a89190610dd0565b60405180910390f35b6101b9610425565b6040516101c69190610d4c565b60405180910390f35b6101d7610445565b6040516101e49190610dd0565b60405180910390f35b61020760048036038101906102029190610ccc565b61044d565b6040516102149190610d24565b60405180910390f35b61023760048036038101906102329190610de9565b610483565b6040516102449190610d4c565b60405180910390f35b6102556104c8565b6040516102629190610c1b565b60405180910390f35b610273610558565b6040516102809190610c1b565b60405180910390f35b6102a3600480360381019061029e9190610ccc565b610574565b6040516102b09190610d24565b60405180910390f35b6102d360048036038101906102ce9190610ccc565b6105e9565b6040516102e09190610d24565b60405180910390f35b61030360048036038101906102fe9190610e14565b61060b565b6040516103109190610d4c565b60405180910390f35b61032161068d565b60405161032e9190610c1b565b60405180910390f35b60606003805461034690610e7f565b80601f016020809104026020016040519081016040528092919081815260200182805461037290610e7f565b80156103bd5780601f10610394576101008083540402835291602001916103bd565b820191905f5260205f20905b8154815290600101906020018083116103a057829003601f168201915b5050505050905090565b5f806103d16106c6565b90506103de8185856106cd565b600191505092915050565b5f600254905090565b5f806103fc6106c6565b9050610409858285610890565b61041485858561091b565b60019150509392505050565b601281565b6012600a610433919061100b565b633b9aca006104429190611055565b81565b5f6012905090565b5f806104576106c6565b9050610478818585610469858961060b565b6104739190611096565b6106cd565b600191505092915050565b5f805f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20549050919050565b6060600480546104d790610e7f565b80601f016020809104026020016040519081016040528092919081815260200182805461050390610e7f565b801561054e5780601f106105255761010080835404028352916020019161054e565b820191905f5260205f20905b81548152906001019060200180831161053157829003601f168201915b5050505050905090565b6040518060600160405280602881526020016114866028913981565b5f8061057e6106c6565b90505f61058b828661060b565b9050838110156105d0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105c790611139565b60405180910390fd5b6105dd82868684036106cd565b60019250505092915050565b5f806105f36106c6565b905061060081858561091b565b600191505092915050565b5f60015f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f2054905092915050565b6040518060400160405280600381526020017f444950000000000000000000000000000000000000000000000000000000000081525081565b5f33905090565b5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff160361073b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610732906111c7565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036107a9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107a090611255565b60405180910390fd5b8060015f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f8473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f20819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040516108839190610d4c565b60405180910390a3505050565b5f61089b848461060b565b90507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146109155781811015610907576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108fe906112bd565b60405180910390fd5b61091484848484036106cd565b5b50505050565b5f73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603610989576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109809061134b565b60405180910390fd5b5f73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036109f7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109ee906113d9565b60405180910390fd5b610a02838383610b87565b5f805f8573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f2054905081811015610a85576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a7c90611467565b60405180910390fd5b8181035f808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f2081905550815f808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020015f205f82825401925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610b6e9190610d4c565b60405180910390a3610b81848484610b8c565b50505050565b505050565b505050565b5f81519050919050565b5f82825260208201905092915050565b5f5b83811015610bc8578082015181840152602081019050610bad565b5f8484015250505050565b5f601f19601f8301169050919050565b5f610bed82610b91565b610bf78185610b9b565b9350610c07818560208601610bab565b610c1081610bd3565b840191505092915050565b5f6020820190508181035f830152610c338184610be3565b905092915050565b5f80fd5b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f610c6882610c3f565b9050919050565b610c7881610c5e565b8114610c82575f80fd5b50565b5f81359050610c9381610c6f565b92915050565b5f819050919050565b610cab81610c99565b8114610cb5575f80fd5b50565b5f81359050610cc681610ca2565b92915050565b5f8060408385031215610ce257610ce1610c3b565b5b5f610cef85828601610c85565b9250506020610d0085828601610cb8565b9150509250929050565b5f8115159050919050565b610d1e81610d0a565b82525050565b5f602082019050610d375f830184610d15565b92915050565b610d4681610c99565b82525050565b5f602082019050610d5f5f830184610d3d565b92915050565b5f805f60608486031215610d7c57610d7b610c3b565b5b5f610d8986828701610c85565b9350506020610d9a86828701610c85565b9250506040610dab86828701610cb8565b9150509250925092565b5f60ff82169050919050565b610dca81610db5565b82525050565b5f602082019050610de35f830184610dc1565b92915050565b5f60208284031215610dfe57610dfd610c3b565b5b5f610e0b84828501610c85565b91505092915050565b5f8060408385031215610e2a57610e29610c3b565b5b5f610e3785828601610c85565b9250506020610e4885828601610c85565b9150509250929050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52602260045260245ffd5b5f6002820490506001821680610e9657607f821691505b602082108103610ea957610ea8610e52565b5b50919050565b7f4e487b71000000000000000000000000000000000000000000000000000000005f52601160045260245ffd5b5f8160011c9050919050565b5f808291508390505b6001851115610f3157808604811115610f0d57610f0c610eaf565b5b6001851615610f1c5780820291505b8081029050610f2a85610edc565b9450610ef1565b94509492505050565b5f82610f495760019050611004565b81610f56575f9050611004565b8160018114610f6c5760028114610f7657610fa5565b6001915050611004565b60ff841115610f8857610f87610eaf565b5b8360020a915084821115610f9f57610f9e610eaf565b5b50611004565b5060208310610133831016604e8410600b8410161715610fda5782820a905083811115610fd557610fd4610eaf565b5b611004565b610fe78484846001610ee8565b92509050818404811115610ffe57610ffd610eaf565b5b81810290505b9392505050565b5f61101582610c99565b915061102083610db5565b925061104d7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f3a565b905092915050565b5f61105f82610c99565b915061106a83610c99565b925082820261107881610c99565b9150828204841483151761108f5761108e610eaf565b5b5092915050565b5f6110a082610c99565b91506110ab83610c99565b92508282019050808211156110c3576110c2610eaf565b5b92915050565b7f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f775f8201527f207a65726f000000000000000000000000000000000000000000000000000000602082015250565b5f611123602583610b9b565b915061112e826110c9565b604082019050919050565b5f6020820190508181035f83015261115081611117565b9050919050565b7f45524332303a20617070726f76652066726f6d20746865207a65726f206164645f8201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b5f6111b1602483610b9b565b91506111bc82611157565b604082019050919050565b5f6020820190508181035f8301526111de816111a5565b9050919050565b7f45524332303a20617070726f766520746f20746865207a65726f2061646472655f8201527f7373000000000000000000000000000000000000000000000000000000000000602082015250565b5f61123f602283610b9b565b915061124a826111e5565b604082019050919050565b5f6020820190508181035f83015261126c81611233565b9050919050565b7f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000005f82015250565b5f6112a7601d83610b9b565b91506112b282611273565b602082019050919050565b5f6020820190508181035f8301526112d48161129b565b9050919050565b7f45524332303a207472616e736665722066726f6d20746865207a65726f2061645f8201527f6472657373000000000000000000000000000000000000000000000000000000602082015250565b5f611335602583610b9b565b9150611340826112db565b604082019050919050565b5f6020820190508181035f83015261136281611329565b9050919050565b7f45524332303a207472616e7366657220746f20746865207a65726f20616464725f8201527f6573730000000000000000000000000000000000000000000000000000000000602082015250565b5f6113c3602383610b9b565b91506113ce82611369565b604082019050919050565b5f6020820190508181035f8301526113f0816113b7565b9050919050565b7f45524332303a207472616e7366657220616d6f756e74206578636565647320625f8201527f616c616e63650000000000000000000000000000000000000000000000000000602082015250565b5f611451602683610b9b565b915061145c826113f7565b604082019050919050565b5f6020820190508181035f83015261147e81611445565b905091905056fe446563656e7472616c697a656420496e737572616e63652050726f746f636f6c202d2044554d4d59a2646970667358221220b5817fafe4925dedfbf7a88cb88310c1b3164f71f2d48445c354b2ba8929211964736f6c63430008140033",
336
- "linkReferences": {},
337
- "deployedLinkReferences": {}
338
- }
@@ -1,4 +0,0 @@
1
- {
2
- "_format": "hh-sol-dbg-1",
3
- "buildInfo": "../../build-info/d6ddc31c8d0f29d05ebcf7dbd3184aca.json"
4
- }
@@ -1,74 +0,0 @@
1
- {
2
- "_format": "hh-sol-artifact-1",
3
- "contractName": "Lock",
4
- "sourceName": "contracts/Lock.sol",
5
- "abi": [
6
- {
7
- "inputs": [
8
- {
9
- "internalType": "uint256",
10
- "name": "_unlockTime",
11
- "type": "uint256"
12
- }
13
- ],
14
- "stateMutability": "payable",
15
- "type": "constructor"
16
- },
17
- {
18
- "anonymous": false,
19
- "inputs": [
20
- {
21
- "indexed": false,
22
- "internalType": "uint256",
23
- "name": "amount",
24
- "type": "uint256"
25
- },
26
- {
27
- "indexed": false,
28
- "internalType": "uint256",
29
- "name": "when",
30
- "type": "uint256"
31
- }
32
- ],
33
- "name": "Withdrawal",
34
- "type": "event"
35
- },
36
- {
37
- "inputs": [],
38
- "name": "owner",
39
- "outputs": [
40
- {
41
- "internalType": "address payable",
42
- "name": "",
43
- "type": "address"
44
- }
45
- ],
46
- "stateMutability": "view",
47
- "type": "function"
48
- },
49
- {
50
- "inputs": [],
51
- "name": "unlockTime",
52
- "outputs": [
53
- {
54
- "internalType": "uint256",
55
- "name": "",
56
- "type": "uint256"
57
- }
58
- ],
59
- "stateMutability": "view",
60
- "type": "function"
61
- },
62
- {
63
- "inputs": [],
64
- "name": "withdraw",
65
- "outputs": [],
66
- "stateMutability": "nonpayable",
67
- "type": "function"
68
- }
69
- ],
70
- "bytecode": "0x60806040526040516105ac3803806105ac833981810160405281019061002591906100ea565b804210610067576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161005e90610195565b60405180910390fd5b805f819055503360015f6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550506101b3565b5f80fd5b5f819050919050565b6100c9816100b7565b81146100d3575f80fd5b50565b5f815190506100e4816100c0565b92915050565b5f602082840312156100ff576100fe6100b3565b5b5f61010c848285016100d6565b91505092915050565b5f82825260208201905092915050565b7f556e6c6f636b2074696d652073686f756c6420626520696e20746865206675745f8201527f7572650000000000000000000000000000000000000000000000000000000000602082015250565b5f61017f602383610115565b915061018a82610125565b604082019050919050565b5f6020820190508181035f8301526101ac81610173565b9050919050565b6103ec806101c05f395ff3fe608060405234801561000f575f80fd5b506004361061003f575f3560e01c8063251c1aa3146100435780633ccfd60b146100615780638da5cb5b1461006b575b5f80fd5b61004b610089565b604051610058919061023e565b60405180910390f35b61006961008e565b005b610073610201565b6040516100809190610296565b60405180910390f35b5f5481565b5f544210156100d2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016100c990610309565b60405180910390fd5b60015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610161576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161015890610371565b60405180910390fd5b7fbf2ed60bd5b5965d685680c01195c9514e4382e28e3a5a2d2d5244bf59411b93474260405161019292919061038f565b60405180910390a160015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166108fc4790811502906040515f60405180830381858888f193505050501580156101fe573d5f803e3d5ffd5b50565b60015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f819050919050565b61023881610226565b82525050565b5f6020820190506102515f83018461022f565b92915050565b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f61028082610257565b9050919050565b61029081610276565b82525050565b5f6020820190506102a95f830184610287565b92915050565b5f82825260208201905092915050565b7f596f752063616e277420776974686472617720796574000000000000000000005f82015250565b5f6102f36016836102af565b91506102fe826102bf565b602082019050919050565b5f6020820190508181035f830152610320816102e7565b9050919050565b7f596f75206172656e277420746865206f776e65720000000000000000000000005f82015250565b5f61035b6014836102af565b915061036682610327565b602082019050919050565b5f6020820190508181035f8301526103888161034f565b9050919050565b5f6040820190506103a25f83018561022f565b6103af602083018461022f565b939250505056fea26469706673582212208f7a384749b7101b94270d81d01abfe82e5419e000f416303d429b9e681b0f9364736f6c63430008140033",
71
- "deployedBytecode": "0x608060405234801561000f575f80fd5b506004361061003f575f3560e01c8063251c1aa3146100435780633ccfd60b146100615780638da5cb5b1461006b575b5f80fd5b61004b610089565b604051610058919061023e565b60405180910390f35b61006961008e565b005b610073610201565b6040516100809190610296565b60405180910390f35b5f5481565b5f544210156100d2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016100c990610309565b60405180910390fd5b60015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610161576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161015890610371565b60405180910390fd5b7fbf2ed60bd5b5965d685680c01195c9514e4382e28e3a5a2d2d5244bf59411b93474260405161019292919061038f565b60405180910390a160015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166108fc4790811502906040515f60405180830381858888f193505050501580156101fe573d5f803e3d5ffd5b50565b60015f9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b5f819050919050565b61023881610226565b82525050565b5f6020820190506102515f83018461022f565b92915050565b5f73ffffffffffffffffffffffffffffffffffffffff82169050919050565b5f61028082610257565b9050919050565b61029081610276565b82525050565b5f6020820190506102a95f830184610287565b92915050565b5f82825260208201905092915050565b7f596f752063616e277420776974686472617720796574000000000000000000005f82015250565b5f6102f36016836102af565b91506102fe826102bf565b602082019050919050565b5f6020820190508181035f830152610320816102e7565b9050919050565b7f596f75206172656e277420746865206f776e65720000000000000000000000005f82015250565b5f61035b6014836102af565b915061036682610327565b602082019050919050565b5f6020820190508181035f8301526103888161034f565b9050919050565b5f6040820190506103a25f83018561022f565b6103af602083018461022f565b939250505056fea26469706673582212208f7a384749b7101b94270d81d01abfe82e5419e000f416303d429b9e681b0f9364736f6c63430008140033",
72
- "linkReferences": {},
73
- "deployedLinkReferences": {}
74
- }
@@ -1,34 +0,0 @@
1
- // SPDX-License-Identifier: UNLICENSED
2
- pragma solidity ^0.8.20;
3
-
4
- // Uncomment this line to use console.log
5
- // import "hardhat/console.sol";
6
-
7
- contract Lock {
8
- uint public unlockTime;
9
- address payable public owner;
10
-
11
- event Withdrawal(uint amount, uint when);
12
-
13
- constructor(uint _unlockTime) payable {
14
- require(
15
- block.timestamp < _unlockTime,
16
- "Unlock time should be in the future"
17
- );
18
-
19
- unlockTime = _unlockTime;
20
- owner = payable(msg.sender);
21
- }
22
-
23
- function withdraw() public {
24
- // Uncomment this line, and the import of "hardhat/console.sol", to print a log in your terminal
25
- // console.log("Unlock time is %o and block timestamp is %o", unlockTime, block.timestamp);
26
-
27
- require(block.timestamp >= unlockTime, "You can't withdraw yet");
28
- require(msg.sender == owner, "You aren't the owner");
29
-
30
- emit Withdrawal(address(this).balance, block.timestamp);
31
-
32
- owner.transfer(address(this).balance);
33
- }
34
- }