@etherisc/gif-next 0.0.2-ac5f18b → 0.0.2-aeb86f4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (156) hide show
  1. package/README.md +70 -0
  2. package/artifacts/contracts/components/Component.sol/Component.dbg.json +4 -0
  3. package/artifacts/contracts/components/Component.sol/Component.json +179 -0
  4. package/artifacts/contracts/components/Component.sol/InstanceLinked.dbg.json +4 -0
  5. package/artifacts/contracts/components/Component.sol/InstanceLinked.json +35 -0
  6. package/artifacts/contracts/components/IPool.sol/IPoolComponent.dbg.json +4 -0
  7. package/artifacts/contracts/components/IPool.sol/IPoolComponent.json +179 -0
  8. package/artifacts/contracts/components/IProduct.sol/IProductComponent.dbg.json +4 -0
  9. package/artifacts/contracts/components/IProduct.sol/IProductComponent.json +192 -0
  10. package/artifacts/contracts/components/Pool.sol/Pool.dbg.json +4 -0
  11. package/artifacts/contracts/components/Pool.sol/Pool.json +213 -0
  12. package/artifacts/contracts/components/Product.sol/Product.dbg.json +4 -0
  13. package/artifacts/contracts/components/Product.sol/Product.json +231 -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/types/TypeA.sol/TypeALib.dbg.json +4 -0
  35. package/artifacts/contracts/experiment/types/TypeA.sol/TypeALib.json +10 -0
  36. package/artifacts/contracts/experiment/types/TypeB.sol/TypeBLib.dbg.json +4 -0
  37. package/artifacts/contracts/experiment/types/TypeB.sol/TypeBLib.json +10 -0
  38. package/artifacts/contracts/instance/IInstance.sol/IInstance.dbg.json +4 -0
  39. package/artifacts/contracts/instance/IInstance.sol/IInstance.json +892 -0
  40. package/artifacts/contracts/instance/Instance.sol/Instance.dbg.json +4 -0
  41. package/artifacts/contracts/instance/Instance.sol/Instance.json +1067 -0
  42. package/artifacts/contracts/instance/access/Access.sol/AccessModule.dbg.json +4 -0
  43. package/artifacts/contracts/instance/access/Access.sol/AccessModule.json +400 -0
  44. package/artifacts/contracts/instance/access/IAccess.sol/IAccess.dbg.json +4 -0
  45. package/artifacts/contracts/instance/access/IAccess.sol/IAccess.json +10 -0
  46. package/artifacts/contracts/instance/access/IAccess.sol/IAccessCheckRole.dbg.json +4 -0
  47. package/artifacts/contracts/instance/access/IAccess.sol/IAccessCheckRole.json +35 -0
  48. package/artifacts/contracts/instance/access/IAccess.sol/IAccessComponentTypeRoles.dbg.json +4 -0
  49. package/artifacts/contracts/instance/access/IAccess.sol/IAccessComponentTypeRoles.json +50 -0
  50. package/artifacts/contracts/instance/access/IAccess.sol/IAccessModule.dbg.json +4 -0
  51. package/artifacts/contracts/instance/access/IAccess.sol/IAccessModule.json +336 -0
  52. package/artifacts/contracts/instance/component/ComponentModule.sol/ComponentModule.dbg.json +4 -0
  53. package/artifacts/contracts/instance/component/ComponentModule.sol/ComponentModule.json +327 -0
  54. package/artifacts/contracts/instance/component/ComponentModule.sol/ComponentOwnerService.dbg.json +4 -0
  55. package/artifacts/contracts/instance/component/ComponentModule.sol/ComponentOwnerService.json +147 -0
  56. package/artifacts/contracts/instance/component/IComponent.sol/IComponent.dbg.json +4 -0
  57. package/artifacts/contracts/instance/component/IComponent.sol/IComponent.json +10 -0
  58. package/artifacts/contracts/instance/component/IComponent.sol/IComponentContract.dbg.json +4 -0
  59. package/artifacts/contracts/instance/component/IComponent.sol/IComponentContract.json +179 -0
  60. package/artifacts/contracts/instance/component/IComponent.sol/IComponentModule.dbg.json +4 -0
  61. package/artifacts/contracts/instance/component/IComponent.sol/IComponentModule.json +245 -0
  62. package/artifacts/contracts/instance/component/IComponent.sol/IComponentOwnerService.dbg.json +4 -0
  63. package/artifacts/contracts/instance/component/IComponent.sol/IComponentOwnerService.json +94 -0
  64. package/artifacts/contracts/instance/component/IComponent.sol/IInstanceLinked.dbg.json +4 -0
  65. package/artifacts/contracts/instance/component/IComponent.sol/IInstanceLinked.json +24 -0
  66. package/artifacts/contracts/instance/policy/IPolicy.sol/IPolicy.dbg.json +4 -0
  67. package/artifacts/contracts/instance/policy/IPolicy.sol/IPolicy.json +10 -0
  68. package/artifacts/contracts/instance/policy/IPolicy.sol/IPolicyModule.dbg.json +4 -0
  69. package/artifacts/contracts/instance/policy/IPolicy.sol/IPolicyModule.json +231 -0
  70. package/artifacts/contracts/instance/policy/PolicyModule.sol/PolicyModule.dbg.json +4 -0
  71. package/artifacts/contracts/instance/policy/PolicyModule.sol/PolicyModule.json +231 -0
  72. package/artifacts/contracts/instance/pool/IPoolModule.sol/IPool.dbg.json +4 -0
  73. package/artifacts/contracts/instance/pool/IPoolModule.sol/IPool.json +10 -0
  74. package/artifacts/contracts/instance/pool/IPoolModule.sol/IPoolModule.dbg.json +4 -0
  75. package/artifacts/contracts/instance/pool/IPoolModule.sol/IPoolModule.json +149 -0
  76. package/artifacts/contracts/instance/pool/PoolModule.sol/PoolModule.dbg.json +4 -0
  77. package/artifacts/contracts/instance/pool/PoolModule.sol/PoolModule.json +162 -0
  78. package/artifacts/contracts/instance/product/IProductService.sol/IProductModule.dbg.json +4 -0
  79. package/artifacts/contracts/instance/product/IProductService.sol/IProductModule.json +75 -0
  80. package/artifacts/contracts/instance/product/IProductService.sol/IProductService.dbg.json +4 -0
  81. package/artifacts/contracts/instance/product/IProductService.sol/IProductService.json +114 -0
  82. package/artifacts/contracts/instance/product/ProductService.sol/ProductModule.dbg.json +4 -0
  83. package/artifacts/contracts/instance/product/ProductService.sol/ProductModule.json +75 -0
  84. package/artifacts/contracts/instance/product/ProductService.sol/ProductService.dbg.json +4 -0
  85. package/artifacts/contracts/instance/product/ProductService.sol/ProductService.json +167 -0
  86. package/artifacts/contracts/registry/ChainNft.sol/ChainNft.dbg.json +4 -0
  87. package/artifacts/contracts/registry/ChainNft.sol/ChainNft.json +534 -0
  88. package/artifacts/contracts/registry/IChainNft.sol/IChainNft.dbg.json +4 -0
  89. package/artifacts/contracts/registry/IChainNft.sol/IChainNft.json +452 -0
  90. package/artifacts/contracts/registry/IRegistry.sol/IOwnable.dbg.json +4 -0
  91. package/artifacts/contracts/registry/IRegistry.sol/IOwnable.json +24 -0
  92. package/artifacts/contracts/registry/IRegistry.sol/IRegisterable.dbg.json +4 -0
  93. package/artifacts/contracts/registry/IRegistry.sol/IRegisterable.json +166 -0
  94. package/artifacts/contracts/registry/IRegistry.sol/IRegistry.dbg.json +4 -0
  95. package/artifacts/contracts/registry/IRegistry.sol/IRegistry.json +279 -0
  96. package/artifacts/contracts/registry/IRegistry.sol/IRegistryLinked.dbg.json +4 -0
  97. package/artifacts/contracts/registry/IRegistry.sol/IRegistryLinked.json +49 -0
  98. package/artifacts/contracts/registry/Registry.sol/Registerable.dbg.json +4 -0
  99. package/artifacts/contracts/registry/Registry.sol/Registerable.json +166 -0
  100. package/artifacts/contracts/registry/Registry.sol/Registry.dbg.json +4 -0
  101. package/artifacts/contracts/registry/Registry.sol/Registry.json +347 -0
  102. package/artifacts/contracts/registry/Registry.sol/RegistryLinked.dbg.json +4 -0
  103. package/artifacts/contracts/registry/Registry.sol/RegistryLinked.json +60 -0
  104. package/artifacts/contracts/types/Blocknumber.sol/BlocknumberLib.dbg.json +4 -0
  105. package/artifacts/contracts/types/Blocknumber.sol/BlocknumberLib.json +174 -0
  106. package/artifacts/contracts/types/ChainId.sol/ChainIdLib.dbg.json +4 -0
  107. package/artifacts/contracts/types/ChainId.sol/ChainIdLib.json +10 -0
  108. package/artifacts/contracts/types/NftId.sol/NftIdLib.dbg.json +4 -0
  109. package/artifacts/contracts/types/NftId.sol/NftIdLib.json +92 -0
  110. package/artifacts/contracts/types/Timestamp.sol/TimestampLib.dbg.json +4 -0
  111. package/artifacts/contracts/types/Timestamp.sol/TimestampLib.json +174 -0
  112. package/artifacts/contracts/types/UFixed.sol/UFixedMathLib.dbg.json +4 -0
  113. package/artifacts/contracts/types/UFixed.sol/UFixedMathLib.json +453 -0
  114. package/contracts/components/Component.sol +62 -0
  115. package/contracts/components/IPool.sol +9 -0
  116. package/contracts/components/IProduct.sol +12 -0
  117. package/contracts/components/Pool.sol +29 -0
  118. package/contracts/components/Product.sol +66 -0
  119. package/contracts/experiment/errors/Require.sol +33 -0
  120. package/contracts/experiment/errors/Revert.sol +39 -0
  121. package/contracts/experiment/inheritance/A.sol +56 -0
  122. package/contracts/experiment/inheritance/B.sol +23 -0
  123. package/contracts/experiment/inheritance/C.sol +28 -0
  124. package/contracts/experiment/inheritance/IA.sol +18 -0
  125. package/contracts/experiment/inheritance/IB.sol +9 -0
  126. package/contracts/experiment/inheritance/IC.sol +11 -0
  127. package/contracts/experiment/types/TypeA.sol +42 -0
  128. package/contracts/experiment/types/TypeB.sol +24 -0
  129. package/contracts/instance/IInstance.sol +20 -0
  130. package/contracts/instance/Instance.sol +64 -0
  131. package/contracts/instance/access/Access.sol +218 -0
  132. package/contracts/instance/access/IAccess.sol +83 -0
  133. package/contracts/instance/component/ComponentModule.sol +248 -0
  134. package/contracts/instance/component/IComponent.sol +95 -0
  135. package/contracts/instance/policy/IPolicy.sol +66 -0
  136. package/contracts/instance/policy/PolicyModule.sol +107 -0
  137. package/contracts/instance/pool/IPoolModule.sol +41 -0
  138. package/contracts/instance/pool/PoolModule.sol +86 -0
  139. package/contracts/instance/product/IProductService.sol +46 -0
  140. package/contracts/instance/product/ProductService.sol +108 -0
  141. package/contracts/registry/ChainNft.sol +173 -0
  142. package/contracts/registry/IChainNft.sol +18 -0
  143. package/contracts/registry/IRegistry.sol +70 -0
  144. package/contracts/registry/Registry.sol +182 -0
  145. package/contracts/types/Blocknumber.sol +60 -0
  146. package/contracts/types/ChainId.sol +30 -0
  147. package/contracts/types/NftId.sol +35 -0
  148. package/contracts/types/Timestamp.sol +55 -0
  149. package/contracts/types/UFixed.sol +211 -0
  150. package/package.json +6 -6
  151. package/artifacts/contracts/Dip.sol/DIP.dbg.json +0 -4
  152. package/artifacts/contracts/Dip.sol/DIP.json +0 -338
  153. package/artifacts/contracts/Lock.sol/Lock.dbg.json +0 -4
  154. package/artifacts/contracts/Lock.sol/Lock.json +0 -74
  155. package/contracts/Dip.sol +0 -26
  156. package/contracts/Lock.sol +0 -34
@@ -0,0 +1,55 @@
1
+ // SPDX-License-Identifier: Apache-2.0
2
+ pragma solidity ^0.8.19;
3
+
4
+ type Timestamp is uint40;
5
+
6
+ using {
7
+ gtTimestamp as >,
8
+ gteTimestamp as >=,
9
+ ltTimestamp as <,
10
+ lteTimestamp as <=,
11
+ eqTimestamp as ==,
12
+ neTimestamp as !=
13
+ } for Timestamp global;
14
+
15
+ /// @dev return true if Timestamp a is after Timestamp b
16
+ function gtTimestamp(Timestamp a, Timestamp b) pure returns(bool) { return Timestamp.unwrap(a) > Timestamp.unwrap(b); }
17
+ /// @dev return true if Timestamp a is after or equal to Timestamp b
18
+ function gteTimestamp(Timestamp a, Timestamp b) pure returns(bool) { return Timestamp.unwrap(a) >= Timestamp.unwrap(b); }
19
+
20
+ /// @dev return true if Timestamp a is before Timestamp b
21
+ function ltTimestamp(Timestamp a, Timestamp b) pure returns(bool) { return Timestamp.unwrap(a) < Timestamp.unwrap(b); }
22
+ /// @dev return true if Timestamp a is before or equal to Timestamp b
23
+ function lteTimestamp(Timestamp a, Timestamp b) pure returns(bool) { return Timestamp.unwrap(a) <= Timestamp.unwrap(b); }
24
+
25
+ /// @dev return true if Timestamp a is equal to Timestamp b
26
+ function eqTimestamp(Timestamp a, Timestamp b) pure returns(bool) { return Timestamp.unwrap(a) == Timestamp.unwrap(b); }
27
+ /// @dev return true if Timestamp a is not equal to Timestamp b
28
+ function neTimestamp(Timestamp a, Timestamp b) pure returns(bool) { return Timestamp.unwrap(a) != Timestamp.unwrap(b); }
29
+
30
+ /// @dev Converts the uint256 to a Timestamp.
31
+ function toTimestamp(uint256 timestamp) pure returns(Timestamp) { return Timestamp.wrap(uint40(timestamp));}
32
+
33
+ function blockTimestamp() view returns(Timestamp) { return toTimestamp(block.timestamp); }
34
+
35
+ /// @dev Return the Timestamp zero (0)
36
+ function zeroTimestamp() pure returns(Timestamp) { return toTimestamp(0); }
37
+
38
+ library TimestampLib {
39
+ /// @dev return true if Timestamp a is after Timestamp b
40
+ function gt(Timestamp a, Timestamp b) public pure returns(bool isAfter) { return gtTimestamp(a, b); }
41
+ /// @dev return true if Timestamp a is after or the same than Timestamp b
42
+ function gte(Timestamp a, Timestamp b) public pure returns(bool isAfterOrSame) { return gteTimestamp(a, b); }
43
+
44
+ /// @dev return true if Timestamp a is before Timestamp b
45
+ function lt(Timestamp a, Timestamp b) public pure returns(bool isBefore) { return ltTimestamp(a, b); }
46
+ /// @dev return true if Timestamp a is before or the same than Timestamp b
47
+ function lte(Timestamp a, Timestamp b) public pure returns(bool isBeforeOrSame) { return lteTimestamp(a, b); }
48
+
49
+ /// @dev return true if Timestamp a is equal to Timestamp b
50
+ function eq(Timestamp a, Timestamp b) public pure returns(bool isSame) { return eqTimestamp(a, b); }
51
+ /// @dev return true if Timestamp a is not equal to Timestamp b
52
+ function ne(Timestamp a, Timestamp b) public pure returns(bool isDifferent) { return neTimestamp(a, b); }
53
+
54
+ function toInt(Timestamp timestamp) public pure returns(uint256) { return uint256(uint40(Timestamp.unwrap(timestamp))); }
55
+ }
@@ -0,0 +1,211 @@
1
+ // SPDX-License-Identifier: Apache-2.0
2
+ pragma solidity ^0.8.19;
3
+
4
+ import { Math } from "@openzeppelin/contracts/utils/math/Math.sol";
5
+
6
+ /// @dev UFixed is a fixed point number with 18 decimals precision.
7
+ type UFixed is uint256;
8
+
9
+ using {
10
+ addUFixed as +,
11
+ subUFixed as -,
12
+ mulUFixed as *,
13
+ divUFixed as /,
14
+ gtUFixed as >,
15
+ gteUFixed as >=,
16
+ ltUFixed as <,
17
+ lteUFixed as <=,
18
+ eqUFixed as ==
19
+ } for UFixed global;
20
+
21
+ function addUFixed(UFixed a, UFixed b) pure returns(UFixed) {
22
+ return UFixed.wrap(UFixed.unwrap(a) + UFixed.unwrap(b));
23
+ }
24
+
25
+ function subUFixed(UFixed a, UFixed b) pure returns(UFixed) {
26
+ require(a >= b, "ERROR:UFM-010:NEGATIVE_RESULT");
27
+ return UFixed.wrap(UFixed.unwrap(a) - UFixed.unwrap(b));
28
+ }
29
+
30
+ function mulUFixed(UFixed a, UFixed b) pure returns(UFixed) {
31
+ return UFixed.wrap(Math.mulDiv(UFixed.unwrap(a), UFixed.unwrap(b), 10 ** 18));
32
+ }
33
+
34
+ function divUFixed(UFixed a, UFixed b) pure returns(UFixed) {
35
+ require(UFixed.unwrap(b) > 0, "ERROR:UFM-020:DIVISOR_ZERO");
36
+
37
+ return UFixed.wrap(
38
+ Math.mulDiv(
39
+ UFixed.unwrap(a),
40
+ 10 ** 18,
41
+ UFixed.unwrap(b)));
42
+ }
43
+
44
+ function gtUFixed(UFixed a, UFixed b) pure returns(bool isGreaterThan) {
45
+ return UFixed.unwrap(a) > UFixed.unwrap(b);
46
+ }
47
+
48
+ function gteUFixed(UFixed a, UFixed b) pure returns(bool isGreaterThan) {
49
+ return UFixed.unwrap(a) >= UFixed.unwrap(b);
50
+ }
51
+
52
+ function ltUFixed(UFixed a, UFixed b) pure returns(bool isGreaterThan) {
53
+ return UFixed.unwrap(a) < UFixed.unwrap(b);
54
+ }
55
+
56
+ function lteUFixed(UFixed a, UFixed b) pure returns(bool isGreaterThan) {
57
+ return UFixed.unwrap(a) <= UFixed.unwrap(b);
58
+ }
59
+
60
+ function eqUFixed(UFixed a, UFixed b) pure returns(bool isEqual) {
61
+ return UFixed.unwrap(a) == UFixed.unwrap(b);
62
+ }
63
+
64
+ function gtzUFixed(UFixed a) pure returns(bool isZero) {
65
+ return UFixed.unwrap(a) > 0;
66
+ }
67
+
68
+ function eqzUFixed(UFixed a) pure returns(bool isZero) {
69
+ return UFixed.unwrap(a) == 0;
70
+ }
71
+
72
+ function deltaUFixed(UFixed a, UFixed b) pure returns(UFixed) {
73
+ if(a > b) {
74
+ return a - b;
75
+ }
76
+
77
+ return b - a;
78
+ }
79
+
80
+ library UFixedMathLib {
81
+
82
+ enum Rounding {
83
+ /// @dev Round down - floor(value)
84
+ Down,
85
+ /// @dev Round up - ceil(value)
86
+ Up,
87
+ /// @dev Round half up - round(value)
88
+ HalfUp
89
+ }
90
+
91
+ int8 public constant EXP = 18;
92
+ uint256 public constant MULTIPLIER = 10 ** uint256(int256(EXP));
93
+ uint256 public constant MULTIPLIER_HALF = MULTIPLIER / 2;
94
+
95
+ /// @dev Default rounding mode used by ftoi is HalfUp
96
+ Rounding public constant ROUNDING_DEFAULT = Rounding.HalfUp;
97
+
98
+ /// @dev returns the decimals precision of the UFixed type
99
+ function decimals() public pure returns(uint256) {
100
+ return uint8(EXP);
101
+ }
102
+
103
+ /// @dev Converts the uint256 to a UFixed.
104
+ function itof(uint256 a)
105
+ public
106
+ pure
107
+ returns(UFixed)
108
+ {
109
+ return UFixed.wrap(a * MULTIPLIER);
110
+ }
111
+
112
+ /// @dev Converts the uint256 to a UFixed with given exponent.
113
+ function itof(uint256 a, int8 exp)
114
+ public
115
+ pure
116
+ returns(UFixed)
117
+ {
118
+ require(EXP + exp >= 0, "ERROR:FM-010:EXPONENT_TOO_SMALL");
119
+ require(EXP + exp <= 64, "ERROR:FM-011:EXPONENT_TOO_LARGE");
120
+
121
+ return UFixed.wrap(a * 10 ** uint8(EXP + exp));
122
+ }
123
+
124
+ /// @dev Converts a UFixed to a uint256.
125
+ function ftoi(UFixed a)
126
+ public
127
+ pure
128
+ returns(uint256)
129
+ {
130
+ return ftoi(a, ROUNDING_DEFAULT);
131
+ }
132
+
133
+ /// @dev Converts a UFixed to a uint256 with given rounding mode.
134
+ function ftoi(UFixed a, Rounding rounding)
135
+ public
136
+ pure
137
+ returns(uint256)
138
+ {
139
+ if(rounding == Rounding.HalfUp) {
140
+ return Math.mulDiv(UFixed.unwrap(a) + MULTIPLIER_HALF, 1, MULTIPLIER, Math.Rounding.Down);
141
+ } else if(rounding == Rounding.Down) {
142
+ return Math.mulDiv(UFixed.unwrap(a), 1, MULTIPLIER, Math.Rounding.Down);
143
+ } else {
144
+ return Math.mulDiv(UFixed.unwrap(a), 1, MULTIPLIER, Math.Rounding.Up);
145
+ }
146
+ }
147
+
148
+ /// @dev adds two UFixed numbers
149
+ function add(UFixed a, UFixed b) public pure returns(UFixed) {
150
+ return addUFixed(a, b);
151
+ }
152
+
153
+ /// @dev subtracts two UFixed numbers
154
+ function sub(UFixed a, UFixed b) public pure returns(UFixed) {
155
+ return subUFixed(a, b);
156
+ }
157
+
158
+ /// @dev multiplies two UFixed numbers
159
+ function mul(UFixed a, UFixed b) public pure returns(UFixed) {
160
+ return mulUFixed(a, b);
161
+ }
162
+
163
+ /// @dev divides two UFixed numbers
164
+ function div(UFixed a, UFixed b) public pure returns(UFixed) {
165
+ return divUFixed(a, b);
166
+ }
167
+
168
+ /// @dev return true if UFixed a is greater than UFixed b
169
+ function gt(UFixed a, UFixed b) public pure returns(bool isGreaterThan) {
170
+ return gtUFixed(a, b);
171
+ }
172
+
173
+ /// @dev return true if UFixed a is greater than or equal to UFixed b
174
+ function gte(UFixed a, UFixed b) public pure returns(bool isGreaterThan) {
175
+ return gteUFixed(a, b);
176
+ }
177
+
178
+ /// @dev return true if UFixed a is less than UFixed b
179
+ function lt(UFixed a, UFixed b) public pure returns(bool isGreaterThan) {
180
+ return ltUFixed(a, b);
181
+ }
182
+
183
+ /// @dev return true if UFixed a is less than or equal to UFixed b
184
+ function lte(UFixed a, UFixed b) public pure returns(bool isGreaterThan) {
185
+ return lteUFixed(a, b);
186
+ }
187
+
188
+ /// @dev return true if UFixed a is equal to UFixed b
189
+ function eq(UFixed a, UFixed b) public pure returns(bool isEqual) {
190
+ return eqUFixed(a, b);
191
+ }
192
+
193
+ /// @dev return true if UFixed a is not zero
194
+ function gtz(UFixed a) public pure returns(bool isZero) {
195
+ return gtzUFixed(a);
196
+ }
197
+
198
+ /// @dev return true if UFixed a is zero
199
+ function eqz(UFixed a) public pure returns(bool isZero) {
200
+ return eqzUFixed(a);
201
+ }
202
+
203
+ function zero() public pure returns(UFixed) {
204
+ return UFixed.wrap(0);
205
+ }
206
+
207
+ /// @dev return the absolute delta between two UFixed numbers
208
+ function delta(UFixed a, UFixed b) public pure returns(UFixed) {
209
+ return deltaUFixed(a, b);
210
+ }
211
+ }
package/package.json CHANGED
@@ -1,14 +1,14 @@
1
1
  {
2
2
  "name": "@etherisc/gif-next",
3
- "version": "0.0.2-ac5f18b",
3
+ "version": "0.0.2-aeb86f4",
4
4
  "description": "This is the repository for the next version of the Generic Insurance Framework (GIF) smart contracts. ",
5
5
  "main": "index.js",
6
6
  "scripts": {
7
- "build": "hardhat compile",
8
- "test": "hardhat test",
9
- "ptest": "hardhat test --parallel",
10
- "test-with-gas": "REPORT_GAS=true hardhat test",
11
- "coverage": "hardhat coverage"
7
+ "build": "hh compile",
8
+ "test": "hh test",
9
+ "ptest": "hh test --parallel",
10
+ "test-with-gas": "REPORT_GAS=true hh test",
11
+ "coverage": "hh coverage"
12
12
  },
13
13
  "repository": {
14
14
  "type": "git",
@@ -1,4 +0,0 @@
1
- {
2
- "_format": "hh-sol-dbg-1",
3
- "buildInfo": "../../build-info/84491cfcc8110d612289088b9a868965.json"
4
- }
@@ -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": "0x60806040523480156200001157600080fd5b5060405180606001604052806028815260200162001e2c602891396040518060400160405280600381526020017f44495000000000000000000000000000000000000000000000000000000000008152508160039081620000739190620004c8565b508060049081620000859190620004c8565b505050620000c96200009c620000cf60201b60201c565b6012600a620000ac91906200073f565b633b9aca00620000bd919062000790565b620000d760201b60201c565b620008c7565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff160362000149576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040162000140906200083c565b60405180910390fd5b6200015d600083836200024460201b60201c565b80600260008282546200017191906200085e565b92505081905550806000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef83604051620002249190620008aa565b60405180910390a362000240600083836200024960201b60201c565b5050565b505050565b505050565b600081519050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60006002820490506001821680620002d057607f821691505b602082108103620002e657620002e562000288565b5b50919050565b60008190508160005260206000209050919050565b60006020601f8301049050919050565b600082821b905092915050565b600060088302620003507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8262000311565b6200035c868362000311565b95508019841693508086168417925050509392505050565b6000819050919050565b6000819050919050565b6000620003a9620003a36200039d8462000374565b6200037e565b62000374565b9050919050565b6000819050919050565b620003c58362000388565b620003dd620003d482620003b0565b8484546200031e565b825550505050565b600090565b620003f4620003e5565b62000401818484620003ba565b505050565b5b8181101562000429576200041d600082620003ea565b60018101905062000407565b5050565b601f82111562000478576200044281620002ec565b6200044d8462000301565b810160208510156200045d578190505b620004756200046c8562000301565b83018262000406565b50505b505050565b600082821c905092915050565b60006200049d600019846008026200047d565b1980831691505092915050565b6000620004b883836200048a565b9150826002028217905092915050565b620004d3826200024e565b67ffffffffffffffff811115620004ef57620004ee62000259565b5b620004fb8254620002b7565b620005088282856200042d565b600060209050601f8311600181146200054057600084156200052b578287015190505b620005378582620004aa565b865550620005a7565b601f1984166200055086620002ec565b60005b828110156200057a5784890151825560018201915060208501945060208101905062000553565b868310156200059a578489015162000596601f8916826200048a565b8355505b6001600288020188555050505b505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008160011c9050919050565b6000808291508390505b60018511156200063d57808604811115620006155762000614620005af565b5b6001851615620006255780820291505b80810290506200063585620005de565b9450620005f5565b94509492505050565b6000826200065857600190506200072b565b816200066857600090506200072b565b81600181146200068157600281146200068c57620006c2565b60019150506200072b565b60ff841115620006a157620006a0620005af565b5b8360020a915084821115620006bb57620006ba620005af565b5b506200072b565b5060208310610133831016604e8410600b8410161715620006fc5782820a905083811115620006f657620006f5620005af565b5b6200072b565b6200070b8484846001620005eb565b92509050818404811115620007255762000724620005af565b5b81810290505b9392505050565b600060ff82169050919050565b60006200074c8262000374565b9150620007598362000732565b9250620007887fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff848462000646565b905092915050565b60006200079d8262000374565b9150620007aa8362000374565b9250828202620007ba8162000374565b91508282048414831517620007d457620007d3620005af565b5b5092915050565b600082825260208201905092915050565b7f45524332303a206d696e7420746f20746865207a65726f206164647265737300600082015250565b600062000824601f83620007db565b91506200083182620007ec565b602082019050919050565b60006020820190508181036000830152620008578162000815565b9050919050565b60006200086b8262000374565b9150620008788362000374565b9250828201905080821115620008935762000892620005af565b5b92915050565b620008a48162000374565b82525050565b6000602082019050620008c1600083018462000899565b92915050565b61155580620008d76000396000f3fe608060405234801561001057600080fd5b50600436106100f55760003560e01c80633950935111610097578063a457c2d711610066578063a457c2d71461028c578063a9059cbb146102bc578063dd62ed3e146102ec578063f76f8d781461031c576100f5565b806339509351146101f057806370a082311461022057806395d89b4114610250578063a3f4df7e1461026e576100f5565b806323b872dd116100d357806323b872dd146101665780632e0f2625146101965780632ff2e9dc146101b4578063313ce567146101d2576100f5565b806306fdde03146100fa578063095ea7b31461011857806318160ddd14610148575b600080fd5b61010261033a565b60405161010f9190610c4a565b60405180910390f35b610132600480360381019061012d9190610d05565b6103cc565b60405161013f9190610d60565b60405180910390f35b6101506103ef565b60405161015d9190610d8a565b60405180910390f35b610180600480360381019061017b9190610da5565b6103f9565b60405161018d9190610d60565b60405180910390f35b61019e610428565b6040516101ab9190610e14565b60405180910390f35b6101bc61042d565b6040516101c99190610d8a565b60405180910390f35b6101da61044d565b6040516101e79190610e14565b60405180910390f35b61020a60048036038101906102059190610d05565b610456565b6040516102179190610d60565b60405180910390f35b61023a60048036038101906102359190610e2f565b61048d565b6040516102479190610d8a565b60405180910390f35b6102586104d5565b6040516102659190610c4a565b60405180910390f35b610276610567565b6040516102839190610c4a565b60405180910390f35b6102a660048036038101906102a19190610d05565b610583565b6040516102b39190610d60565b60405180910390f35b6102d660048036038101906102d19190610d05565b6105fa565b6040516102e39190610d60565b60405180910390f35b61030660048036038101906103019190610e5c565b61061d565b6040516103139190610d8a565b60405180910390f35b6103246106a4565b6040516103319190610c4a565b60405180910390f35b60606003805461034990610ecb565b80601f016020809104026020016040519081016040528092919081815260200182805461037590610ecb565b80156103c25780601f10610397576101008083540402835291602001916103c2565b820191906000526020600020905b8154815290600101906020018083116103a557829003601f168201915b5050505050905090565b6000806103d76106dd565b90506103e48185856106e5565b600191505092915050565b6000600254905090565b6000806104046106dd565b90506104118582856108ae565b61041c85858561093a565b60019150509392505050565b601281565b6012600a61043b919061105e565b633b9aca0061044a91906110a9565b81565b60006012905090565b6000806104616106dd565b9050610482818585610473858961061d565b61047d91906110eb565b6106e5565b600191505092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b6060600480546104e490610ecb565b80601f016020809104026020016040519081016040528092919081815260200182805461051090610ecb565b801561055d5780601f106105325761010080835404028352916020019161055d565b820191906000526020600020905b81548152906001019060200180831161054057829003601f168201915b5050505050905090565b6040518060600160405280602881526020016114f86028913981565b60008061058e6106dd565b9050600061059c828661061d565b9050838110156105e1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105d890611191565b60405180910390fd5b6105ee82868684036106e5565b60019250505092915050565b6000806106056106dd565b905061061281858561093a565b600191505092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b6040518060400160405280600381526020017f444950000000000000000000000000000000000000000000000000000000000081525081565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603610754576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161074b90611223565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036107c3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107ba906112b5565b60405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040516108a19190610d8a565b60405180910390a3505050565b60006108ba848461061d565b90507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146109345781811015610926576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161091d90611321565b60405180910390fd5b61093384848484036106e5565b5b50505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036109a9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109a0906113b3565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603610a18576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a0f90611445565b60405180910390fd5b610a23838383610bb0565b60008060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905081811015610aa9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610aa0906114d7565b60405180910390fd5b8181036000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610b979190610d8a565b60405180910390a3610baa848484610bb5565b50505050565b505050565b505050565b600081519050919050565b600082825260208201905092915050565b60005b83811015610bf4578082015181840152602081019050610bd9565b60008484015250505050565b6000601f19601f8301169050919050565b6000610c1c82610bba565b610c268185610bc5565b9350610c36818560208601610bd6565b610c3f81610c00565b840191505092915050565b60006020820190508181036000830152610c648184610c11565b905092915050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000610c9c82610c71565b9050919050565b610cac81610c91565b8114610cb757600080fd5b50565b600081359050610cc981610ca3565b92915050565b6000819050919050565b610ce281610ccf565b8114610ced57600080fd5b50565b600081359050610cff81610cd9565b92915050565b60008060408385031215610d1c57610d1b610c6c565b5b6000610d2a85828601610cba565b9250506020610d3b85828601610cf0565b9150509250929050565b60008115159050919050565b610d5a81610d45565b82525050565b6000602082019050610d756000830184610d51565b92915050565b610d8481610ccf565b82525050565b6000602082019050610d9f6000830184610d7b565b92915050565b600080600060608486031215610dbe57610dbd610c6c565b5b6000610dcc86828701610cba565b9350506020610ddd86828701610cba565b9250506040610dee86828701610cf0565b9150509250925092565b600060ff82169050919050565b610e0e81610df8565b82525050565b6000602082019050610e296000830184610e05565b92915050565b600060208284031215610e4557610e44610c6c565b5b6000610e5384828501610cba565b91505092915050565b60008060408385031215610e7357610e72610c6c565b5b6000610e8185828601610cba565b9250506020610e9285828601610cba565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60006002820490506001821680610ee357607f821691505b602082108103610ef657610ef5610e9c565b5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008160011c9050919050565b6000808291508390505b6001851115610f8257808604811115610f5e57610f5d610efc565b5b6001851615610f6d5780820291505b8081029050610f7b85610f2b565b9450610f42565b94509492505050565b600082610f9b5760019050611057565b81610fa95760009050611057565b8160018114610fbf5760028114610fc957610ff8565b6001915050611057565b60ff841115610fdb57610fda610efc565b5b8360020a915084821115610ff257610ff1610efc565b5b50611057565b5060208310610133831016604e8410600b841016171561102d5782820a90508381111561102857611027610efc565b5b611057565b61103a8484846001610f38565b9250905081840481111561105157611050610efc565b5b81810290505b9392505050565b600061106982610ccf565b915061107483610df8565b92506110a17fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f8b565b905092915050565b60006110b482610ccf565b91506110bf83610ccf565b92508282026110cd81610ccf565b915082820484148315176110e4576110e3610efc565b5b5092915050565b60006110f682610ccf565b915061110183610ccf565b925082820190508082111561111957611118610efc565b5b92915050565b7f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760008201527f207a65726f000000000000000000000000000000000000000000000000000000602082015250565b600061117b602583610bc5565b91506111868261111f565b604082019050919050565b600060208201905081810360008301526111aa8161116e565b9050919050565b7f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460008201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b600061120d602483610bc5565b9150611218826111b1565b604082019050919050565b6000602082019050818103600083015261123c81611200565b9050919050565b7f45524332303a20617070726f766520746f20746865207a65726f20616464726560008201527f7373000000000000000000000000000000000000000000000000000000000000602082015250565b600061129f602283610bc5565b91506112aa82611243565b604082019050919050565b600060208201905081810360008301526112ce81611292565b9050919050565b7f45524332303a20696e73756666696369656e7420616c6c6f77616e6365000000600082015250565b600061130b601d83610bc5565b9150611316826112d5565b602082019050919050565b6000602082019050818103600083015261133a816112fe565b9050919050565b7f45524332303a207472616e736665722066726f6d20746865207a65726f20616460008201527f6472657373000000000000000000000000000000000000000000000000000000602082015250565b600061139d602583610bc5565b91506113a882611341565b604082019050919050565b600060208201905081810360008301526113cc81611390565b9050919050565b7f45524332303a207472616e7366657220746f20746865207a65726f206164647260008201527f6573730000000000000000000000000000000000000000000000000000000000602082015250565b600061142f602383610bc5565b915061143a826113d3565b604082019050919050565b6000602082019050818103600083015261145e81611422565b9050919050565b7f45524332303a207472616e7366657220616d6f756e742065786365656473206260008201527f616c616e63650000000000000000000000000000000000000000000000000000602082015250565b60006114c1602683610bc5565b91506114cc82611465565b604082019050919050565b600060208201905081810360008301526114f0816114b4565b905091905056fe446563656e7472616c697a656420496e737572616e63652050726f746f636f6c202d2044554d4d59a26469706673582212207c0b5fc9c425154d4c614fe0925d4fc2f9079abd8b114f30cb85a2942310245b64736f6c63430008140033446563656e7472616c697a656420496e737572616e63652050726f746f636f6c202d2044554d4d59",
335
- "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100f55760003560e01c80633950935111610097578063a457c2d711610066578063a457c2d71461028c578063a9059cbb146102bc578063dd62ed3e146102ec578063f76f8d781461031c576100f5565b806339509351146101f057806370a082311461022057806395d89b4114610250578063a3f4df7e1461026e576100f5565b806323b872dd116100d357806323b872dd146101665780632e0f2625146101965780632ff2e9dc146101b4578063313ce567146101d2576100f5565b806306fdde03146100fa578063095ea7b31461011857806318160ddd14610148575b600080fd5b61010261033a565b60405161010f9190610c4a565b60405180910390f35b610132600480360381019061012d9190610d05565b6103cc565b60405161013f9190610d60565b60405180910390f35b6101506103ef565b60405161015d9190610d8a565b60405180910390f35b610180600480360381019061017b9190610da5565b6103f9565b60405161018d9190610d60565b60405180910390f35b61019e610428565b6040516101ab9190610e14565b60405180910390f35b6101bc61042d565b6040516101c99190610d8a565b60405180910390f35b6101da61044d565b6040516101e79190610e14565b60405180910390f35b61020a60048036038101906102059190610d05565b610456565b6040516102179190610d60565b60405180910390f35b61023a60048036038101906102359190610e2f565b61048d565b6040516102479190610d8a565b60405180910390f35b6102586104d5565b6040516102659190610c4a565b60405180910390f35b610276610567565b6040516102839190610c4a565b60405180910390f35b6102a660048036038101906102a19190610d05565b610583565b6040516102b39190610d60565b60405180910390f35b6102d660048036038101906102d19190610d05565b6105fa565b6040516102e39190610d60565b60405180910390f35b61030660048036038101906103019190610e5c565b61061d565b6040516103139190610d8a565b60405180910390f35b6103246106a4565b6040516103319190610c4a565b60405180910390f35b60606003805461034990610ecb565b80601f016020809104026020016040519081016040528092919081815260200182805461037590610ecb565b80156103c25780601f10610397576101008083540402835291602001916103c2565b820191906000526020600020905b8154815290600101906020018083116103a557829003601f168201915b5050505050905090565b6000806103d76106dd565b90506103e48185856106e5565b600191505092915050565b6000600254905090565b6000806104046106dd565b90506104118582856108ae565b61041c85858561093a565b60019150509392505050565b601281565b6012600a61043b919061105e565b633b9aca0061044a91906110a9565b81565b60006012905090565b6000806104616106dd565b9050610482818585610473858961061d565b61047d91906110eb565b6106e5565b600191505092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b6060600480546104e490610ecb565b80601f016020809104026020016040519081016040528092919081815260200182805461051090610ecb565b801561055d5780601f106105325761010080835404028352916020019161055d565b820191906000526020600020905b81548152906001019060200180831161054057829003601f168201915b5050505050905090565b6040518060600160405280602881526020016114f86028913981565b60008061058e6106dd565b9050600061059c828661061d565b9050838110156105e1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105d890611191565b60405180910390fd5b6105ee82868684036106e5565b60019250505092915050565b6000806106056106dd565b905061061281858561093a565b600191505092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b6040518060400160405280600381526020017f444950000000000000000000000000000000000000000000000000000000000081525081565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603610754576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161074b90611223565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036107c3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107ba906112b5565b60405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040516108a19190610d8a565b60405180910390a3505050565b60006108ba848461061d565b90507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146109345781811015610926576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161091d90611321565b60405180910390fd5b61093384848484036106e5565b5b50505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16036109a9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109a0906113b3565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603610a18576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a0f90611445565b60405180910390fd5b610a23838383610bb0565b60008060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905081811015610aa9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610aa0906114d7565b60405180910390fd5b8181036000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600082825401925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610b979190610d8a565b60405180910390a3610baa848484610bb5565b50505050565b505050565b505050565b600081519050919050565b600082825260208201905092915050565b60005b83811015610bf4578082015181840152602081019050610bd9565b60008484015250505050565b6000601f19601f8301169050919050565b6000610c1c82610bba565b610c268185610bc5565b9350610c36818560208601610bd6565b610c3f81610c00565b840191505092915050565b60006020820190508181036000830152610c648184610c11565b905092915050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000610c9c82610c71565b9050919050565b610cac81610c91565b8114610cb757600080fd5b50565b600081359050610cc981610ca3565b92915050565b6000819050919050565b610ce281610ccf565b8114610ced57600080fd5b50565b600081359050610cff81610cd9565b92915050565b60008060408385031215610d1c57610d1b610c6c565b5b6000610d2a85828601610cba565b9250506020610d3b85828601610cf0565b9150509250929050565b60008115159050919050565b610d5a81610d45565b82525050565b6000602082019050610d756000830184610d51565b92915050565b610d8481610ccf565b82525050565b6000602082019050610d9f6000830184610d7b565b92915050565b600080600060608486031215610dbe57610dbd610c6c565b5b6000610dcc86828701610cba565b9350506020610ddd86828701610cba565b9250506040610dee86828701610cf0565b9150509250925092565b600060ff82169050919050565b610e0e81610df8565b82525050565b6000602082019050610e296000830184610e05565b92915050565b600060208284031215610e4557610e44610c6c565b5b6000610e5384828501610cba565b91505092915050565b60008060408385031215610e7357610e72610c6c565b5b6000610e8185828601610cba565b9250506020610e9285828601610cba565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60006002820490506001821680610ee357607f821691505b602082108103610ef657610ef5610e9c565b5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008160011c9050919050565b6000808291508390505b6001851115610f8257808604811115610f5e57610f5d610efc565b5b6001851615610f6d5780820291505b8081029050610f7b85610f2b565b9450610f42565b94509492505050565b600082610f9b5760019050611057565b81610fa95760009050611057565b8160018114610fbf5760028114610fc957610ff8565b6001915050611057565b60ff841115610fdb57610fda610efc565b5b8360020a915084821115610ff257610ff1610efc565b5b50611057565b5060208310610133831016604e8410600b841016171561102d5782820a90508381111561102857611027610efc565b5b611057565b61103a8484846001610f38565b9250905081840481111561105157611050610efc565b5b81810290505b9392505050565b600061106982610ccf565b915061107483610df8565b92506110a17fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8484610f8b565b905092915050565b60006110b482610ccf565b91506110bf83610ccf565b92508282026110cd81610ccf565b915082820484148315176110e4576110e3610efc565b5b5092915050565b60006110f682610ccf565b915061110183610ccf565b925082820190508082111561111957611118610efc565b5b92915050565b7f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760008201527f207a65726f000000000000000000000000000000000000000000000000000000602082015250565b600061117b602583610bc5565b91506111868261111f565b604082019050919050565b600060208201905081810360008301526111aa8161116e565b9050919050565b7f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460008201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b600061120d602483610bc5565b9150611218826111b1565b604082019050919050565b6000602082019050818103600083015261123c81611200565b9050919050565b7f45524332303a20617070726f766520746f20746865207a65726f20616464726560008201527f7373000000000000000000000000000000000000000000000000000000000000602082015250565b600061129f602283610bc5565b91506112aa82611243565b604082019050919050565b600060208201905081810360008301526112ce81611292565b9050919050565b7f45524332303a20696e73756666696369656e7420616c6c6f77616e6365000000600082015250565b600061130b601d83610bc5565b9150611316826112d5565b602082019050919050565b6000602082019050818103600083015261133a816112fe565b9050919050565b7f45524332303a207472616e736665722066726f6d20746865207a65726f20616460008201527f6472657373000000000000000000000000000000000000000000000000000000602082015250565b600061139d602583610bc5565b91506113a882611341565b604082019050919050565b600060208201905081810360008301526113cc81611390565b9050919050565b7f45524332303a207472616e7366657220746f20746865207a65726f206164647260008201527f6573730000000000000000000000000000000000000000000000000000000000602082015250565b600061142f602383610bc5565b915061143a826113d3565b604082019050919050565b6000602082019050818103600083015261145e81611422565b9050919050565b7f45524332303a207472616e7366657220616d6f756e742065786365656473206260008201527f616c616e63650000000000000000000000000000000000000000000000000000602082015250565b60006114c1602683610bc5565b91506114cc82611465565b604082019050919050565b600060208201905081810360008301526114f0816114b4565b905091905056fe446563656e7472616c697a656420496e737572616e63652050726f746f636f6c202d2044554d4d59a26469706673582212207c0b5fc9c425154d4c614fe0925d4fc2f9079abd8b114f30cb85a2942310245b64736f6c63430008140033",
336
- "linkReferences": {},
337
- "deployedLinkReferences": {}
338
- }
@@ -1,4 +0,0 @@
1
- {
2
- "_format": "hh-sol-dbg-1",
3
- "buildInfo": "../../build-info/84491cfcc8110d612289088b9a868965.json"
4
- }