gs2-cdk 1.0.81 → 1.0.83

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 (110) hide show
  1. package/exchange/model/LogCost.d.ts +10 -0
  2. package/exchange/model/LogCost.js +26 -0
  3. package/exchange/model/LogCost.js.map +1 -0
  4. package/exchange/model/LogCost.ts +49 -0
  5. package/exchange/model/index.d.ts +3 -1
  6. package/exchange/model/index.js +3 -1
  7. package/exchange/model/index.js.map +1 -1
  8. package/exchange/model/index.ts +4 -0
  9. package/exchange/model/options/LogCostOptions.d.ts +3 -0
  10. package/exchange/model/options/LogCostOptions.js +18 -0
  11. package/exchange/model/options/LogCostOptions.js.map +1 -0
  12. package/exchange/model/options/LogCostOptions.ts +20 -0
  13. package/mission/model/CounterModel.js.map +1 -1
  14. package/mission/model/CounterModel.ts +1 -0
  15. package/mission/model/CounterScopeModel.d.ts +14 -5
  16. package/mission/model/CounterScopeModel.js +42 -15
  17. package/mission/model/CounterScopeModel.js.map +1 -1
  18. package/mission/model/CounterScopeModel.ts +57 -7
  19. package/mission/model/ScopedValue.d.ts +9 -2
  20. package/mission/model/ScopedValue.js +26 -4
  21. package/mission/model/ScopedValue.js.map +1 -1
  22. package/mission/model/ScopedValue.ts +47 -3
  23. package/mission/model/TargetCounterModel.d.ts +8 -1
  24. package/mission/model/TargetCounterModel.js +23 -2
  25. package/mission/model/TargetCounterModel.js.map +1 -1
  26. package/mission/model/TargetCounterModel.ts +46 -0
  27. package/mission/model/enum/CounterScopeModelScopeType.d.ts +5 -0
  28. package/mission/model/enum/CounterScopeModelScopeType.js +23 -0
  29. package/mission/model/enum/CounterScopeModelScopeType.js.map +1 -0
  30. package/mission/model/enum/CounterScopeModelScopeType.ts +23 -0
  31. package/mission/model/enum/ScopedValueScopeType.d.ts +5 -0
  32. package/mission/model/enum/ScopedValueScopeType.js +23 -0
  33. package/mission/model/enum/ScopedValueScopeType.js.map +1 -0
  34. package/mission/model/enum/ScopedValueScopeType.ts +23 -0
  35. package/mission/model/enum/TargetCounterModelScopeType.d.ts +5 -0
  36. package/mission/model/enum/TargetCounterModelScopeType.js +23 -0
  37. package/mission/model/enum/TargetCounterModelScopeType.js.map +1 -0
  38. package/mission/model/enum/TargetCounterModelScopeType.ts +23 -0
  39. package/mission/model/index.d.ts +10 -1
  40. package/mission/model/index.js +7 -1
  41. package/mission/model/index.js.map +1 -1
  42. package/mission/model/index.ts +18 -0
  43. package/mission/model/options/CounterModelOptions.ts +1 -0
  44. package/mission/model/options/CounterScopeModelOptions.d.ts +5 -0
  45. package/mission/model/options/CounterScopeModelOptions.ts +5 -0
  46. package/mission/model/options/CounterScopeModelResetTypeIsDailyOptions.ts +2 -0
  47. package/mission/model/options/CounterScopeModelResetTypeIsMonthlyOptions.ts +2 -0
  48. package/mission/model/options/CounterScopeModelResetTypeIsNotResetOptions.ts +2 -0
  49. package/mission/model/options/CounterScopeModelResetTypeIsWeeklyOptions.ts +2 -0
  50. package/mission/model/options/CounterScopeModelScopeTypeIsResetTimingOptions.d.ts +2 -0
  51. package/mission/model/options/CounterScopeModelScopeTypeIsResetTimingOptions.js +3 -0
  52. package/mission/model/options/CounterScopeModelScopeTypeIsResetTimingOptions.js.map +1 -0
  53. package/mission/model/options/CounterScopeModelScopeTypeIsResetTimingOptions.ts +22 -0
  54. package/mission/model/options/CounterScopeModelScopeTypeIsVerifyActionOptions.d.ts +2 -0
  55. package/mission/model/options/CounterScopeModelScopeTypeIsVerifyActionOptions.js +3 -0
  56. package/mission/model/options/CounterScopeModelScopeTypeIsVerifyActionOptions.js.map +1 -0
  57. package/mission/model/options/CounterScopeModelScopeTypeIsVerifyActionOptions.ts +22 -0
  58. package/mission/model/options/ScopedValueOptions.d.ts +3 -0
  59. package/mission/model/options/ScopedValueOptions.ts +3 -0
  60. package/mission/model/options/ScopedValueScopeTypeIsResetTimingOptions.d.ts +3 -0
  61. package/mission/model/options/ScopedValueScopeTypeIsResetTimingOptions.js +3 -0
  62. package/mission/model/options/ScopedValueScopeTypeIsResetTimingOptions.js.map +1 -0
  63. package/mission/model/options/ScopedValueScopeTypeIsResetTimingOptions.ts +21 -0
  64. package/mission/model/options/ScopedValueScopeTypeIsVerifyActionOptions.d.ts +3 -0
  65. package/mission/model/options/ScopedValueScopeTypeIsVerifyActionOptions.js +3 -0
  66. package/mission/model/options/ScopedValueScopeTypeIsVerifyActionOptions.js.map +1 -0
  67. package/mission/model/options/ScopedValueScopeTypeIsVerifyActionOptions.ts +21 -0
  68. package/mission/model/options/TargetCounterModelOptions.d.ts +1 -0
  69. package/mission/model/options/TargetCounterModelOptions.ts +2 -0
  70. package/mission/model/options/TargetCounterModelScopeTypeIsResetTimingOptions.d.ts +4 -0
  71. package/mission/model/options/TargetCounterModelScopeTypeIsResetTimingOptions.js +3 -0
  72. package/mission/model/options/TargetCounterModelScopeTypeIsResetTimingOptions.js.map +1 -0
  73. package/mission/model/options/TargetCounterModelScopeTypeIsResetTimingOptions.ts +21 -0
  74. package/mission/model/options/TargetCounterModelScopeTypeIsVerifyActionOptions.d.ts +4 -0
  75. package/mission/model/options/TargetCounterModelScopeTypeIsVerifyActionOptions.js +3 -0
  76. package/mission/model/options/TargetCounterModelScopeTypeIsVerifyActionOptions.js.map +1 -0
  77. package/mission/model/options/TargetCounterModelScopeTypeIsVerifyActionOptions.ts +21 -0
  78. package/mission/ref/CounterModelRef.d.ts +2 -1
  79. package/mission/ref/CounterModelRef.js +2 -2
  80. package/mission/ref/CounterModelRef.js.map +1 -1
  81. package/mission/ref/CounterModelRef.ts +6 -1
  82. package/mission/ref/NamespaceRef.d.ts +2 -1
  83. package/mission/ref/NamespaceRef.js +2 -2
  84. package/mission/ref/NamespaceRef.js.map +1 -1
  85. package/mission/ref/NamespaceRef.ts +6 -1
  86. package/mission/stampSheet/VerifyCounterValueByUserId.d.ts +4 -1
  87. package/mission/stampSheet/VerifyCounterValueByUserId.js +13 -2
  88. package/mission/stampSheet/VerifyCounterValueByUserId.js.map +1 -1
  89. package/mission/stampSheet/VerifyCounterValueByUserId.ts +16 -3
  90. package/mission/stampSheet/enum/CounterScopeType.d.ts +5 -0
  91. package/mission/stampSheet/enum/CounterScopeType.js +23 -0
  92. package/mission/stampSheet/enum/CounterScopeType.js.map +1 -0
  93. package/mission/stampSheet/enum/CounterScopeType.ts +23 -0
  94. package/package.json +1 -1
  95. package/schedule/ref/NamespaceRef.d.ts +3 -0
  96. package/schedule/ref/NamespaceRef.js +4 -0
  97. package/schedule/ref/NamespaceRef.js.map +1 -1
  98. package/schedule/ref/NamespaceRef.ts +17 -0
  99. package/schedule/stampSheet/VerifyTriggerByUserId.d.ts +15 -0
  100. package/schedule/stampSheet/VerifyTriggerByUserId.js +58 -0
  101. package/schedule/stampSheet/VerifyTriggerByUserId.js.map +1 -0
  102. package/schedule/stampSheet/VerifyTriggerByUserId.ts +76 -0
  103. package/schedule/stampSheet/enum/TriggerVerifyType.d.ts +6 -0
  104. package/schedule/stampSheet/enum/TriggerVerifyType.js +24 -0
  105. package/schedule/stampSheet/enum/TriggerVerifyType.js.map +1 -0
  106. package/schedule/stampSheet/enum/TriggerVerifyType.ts +24 -0
  107. package/schedule/stampSheet/index.d.ts +2 -1
  108. package/schedule/stampSheet/index.js +3 -1
  109. package/schedule/stampSheet/index.js.map +1 -1
  110. package/schedule/stampSheet/index.ts +2 -0
@@ -0,0 +1,10 @@
1
+ import { LogCostOptions } from "./options/LogCostOptions";
2
+ export default class LogCost {
3
+ private readonly base;
4
+ private readonly adds;
5
+ private readonly subs;
6
+ constructor(base: number, adds: number[], options?: LogCostOptions | null);
7
+ properties(): {
8
+ [name: string]: any;
9
+ };
10
+ }
@@ -0,0 +1,26 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ class LogCost {
4
+ constructor(base, adds, options = null) {
5
+ var _a;
6
+ this.subs = null;
7
+ this.base = base;
8
+ this.adds = adds;
9
+ this.subs = (_a = options === null || options === void 0 ? void 0 : options.subs) !== null && _a !== void 0 ? _a : null;
10
+ }
11
+ properties() {
12
+ let properties = {};
13
+ if (this.base != null) {
14
+ properties["base"] = this.base;
15
+ }
16
+ if (this.adds != null) {
17
+ properties["adds"] = this.adds;
18
+ }
19
+ if (this.subs != null) {
20
+ properties["subs"] = this.subs;
21
+ }
22
+ return properties;
23
+ }
24
+ }
25
+ exports.default = LogCost;
26
+ //# sourceMappingURL=LogCost.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LogCost.js","sourceRoot":"","sources":["LogCost.ts"],"names":[],"mappings":";;AAiBA,MAAqB,OAAO;IAKxB,YACI,IAAY,EACZ,IAAc,EACd,UAA+B,IAAI;;QALtB,SAAI,GAAkB,IAAI,CAAC;QAOxC,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,IAAI,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,IAAI,mCAAI,IAAI,CAAC;IACtC,CAAC;IAEM,UAAU;QAEb,IAAI,UAAU,GAA0B,EAAE,CAAC;QAE3C,IAAI,IAAI,CAAC,IAAI,IAAI,IAAI,EAAE;YACnB,UAAU,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC;SAClC;QACD,IAAI,IAAI,CAAC,IAAI,IAAI,IAAI,EAAE;YACnB,UAAU,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC;SAClC;QACD,IAAI,IAAI,CAAC,IAAI,IAAI,IAAI,EAAE;YACnB,UAAU,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC;SAClC;QAED,OAAO,UAAU,CAAC;IACtB,CAAC;CACJ;AA/BD,0BA+BC"}
@@ -0,0 +1,49 @@
1
+ /*
2
+ * Copyright 2016- Game Server Services, Inc. or its affiliates. All Rights
3
+ * Reserved.
4
+ *
5
+ * Licensed under the Apache License, Version 2.0 (the "License").
6
+ * You may not use this file except in compliance with the License.
7
+ * A copy of the License is located at
8
+ *
9
+ * http://www.apache.org/licenses/LICENSE-2.0
10
+ *
11
+ * or in the "license" file accompanying this file. This file is distributed
12
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13
+ * express or implied. See the License for the specific language governing
14
+ * permissions and limitations under the License.
15
+ */
16
+ import { LogCostOptions } from "./options/LogCostOptions";
17
+
18
+ export default class LogCost {
19
+ private readonly base: number;
20
+ private readonly adds: number[];
21
+ private readonly subs: number[]|null = null;
22
+
23
+ public constructor(
24
+ base: number,
25
+ adds: number[],
26
+ options: LogCostOptions|null = null,
27
+ ) {
28
+ this.base = base;
29
+ this.adds = adds;
30
+ this.subs = options?.subs ?? null;
31
+ }
32
+
33
+ public properties(
34
+ ): {[name: string]: any} {
35
+ let properties: {[name: string]: any} = {};
36
+
37
+ if (this.base != null) {
38
+ properties["base"] = this.base;
39
+ }
40
+ if (this.adds != null) {
41
+ properties["adds"] = this.adds;
42
+ }
43
+ if (this.subs != null) {
44
+ properties["subs"] = this.subs;
45
+ }
46
+
47
+ return properties;
48
+ }
49
+ }
@@ -11,5 +11,7 @@ import { IncrementalRateModelCalculateType } from "./enum/IncrementalRateModelCa
11
11
  import { IncrementalRateModelCalculateTypeIsLinearOptions } from "./options/IncrementalRateModelCalculateTypeIsLinearOptions";
12
12
  import { IncrementalRateModelCalculateTypeIsPowerOptions } from "./options/IncrementalRateModelCalculateTypeIsPowerOptions";
13
13
  import { IncrementalRateModelCalculateTypeIsGs2ScriptOptions } from "./options/IncrementalRateModelCalculateTypeIsGs2ScriptOptions";
14
+ import LogCost from "./LogCost";
15
+ import { LogCostOptions } from "./options/LogCostOptions";
14
16
  import CurrentMasterData from "./CurrentMasterData";
15
- export { Namespace, NamespaceOptions, RateModel, RateModelOptions, RateModelTimingType, RateModelTimingTypeIsImmediateOptions, RateModelTimingTypeIsAwaitOptions, IncrementalRateModel, IncrementalRateModelOptions, IncrementalRateModelCalculateType, IncrementalRateModelCalculateTypeIsLinearOptions, IncrementalRateModelCalculateTypeIsPowerOptions, IncrementalRateModelCalculateTypeIsGs2ScriptOptions, CurrentMasterData, };
17
+ export { Namespace, NamespaceOptions, RateModel, RateModelOptions, RateModelTimingType, RateModelTimingTypeIsImmediateOptions, RateModelTimingTypeIsAwaitOptions, IncrementalRateModel, IncrementalRateModelOptions, IncrementalRateModelCalculateType, IncrementalRateModelCalculateTypeIsLinearOptions, IncrementalRateModelCalculateTypeIsPowerOptions, IncrementalRateModelCalculateTypeIsGs2ScriptOptions, LogCost, LogCostOptions, CurrentMasterData, };
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.CurrentMasterData = exports.IncrementalRateModelCalculateType = exports.IncrementalRateModel = exports.RateModelTimingType = exports.RateModel = exports.Namespace = void 0;
3
+ exports.CurrentMasterData = exports.LogCost = exports.IncrementalRateModelCalculateType = exports.IncrementalRateModel = exports.RateModelTimingType = exports.RateModel = exports.Namespace = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  /*
6
6
  * Copyright 2016- Game Server Services, Inc. or its affiliates. All Rights
@@ -27,6 +27,8 @@ const IncrementalRateModel_1 = tslib_1.__importDefault(require("./IncrementalRat
27
27
  exports.IncrementalRateModel = IncrementalRateModel_1.default;
28
28
  const IncrementalRateModelCalculateType_1 = require("./enum/IncrementalRateModelCalculateType");
29
29
  Object.defineProperty(exports, "IncrementalRateModelCalculateType", { enumerable: true, get: function () { return IncrementalRateModelCalculateType_1.IncrementalRateModelCalculateType; } });
30
+ const LogCost_1 = tslib_1.__importDefault(require("./LogCost"));
31
+ exports.LogCost = LogCost_1.default;
30
32
  const CurrentMasterData_1 = tslib_1.__importDefault(require("./CurrentMasterData"));
31
33
  exports.CurrentMasterData = CurrentMasterData_1.default;
32
34
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;AAAA;;;;;;;;;;;;;;GAcG;AACH,oEAAoC;AAgBhC,oBAhBG,mBAAS,CAgBH;AAdb,oEAAoC;AAgBhC,oBAhBG,mBAAS,CAgBH;AAdb,oEAAiE;AAgB7D,oGAhBK,yCAAmB,OAgBL;AAbvB,0FAA0D;AAgBtD,+BAhBG,8BAAoB,CAgBH;AAdxB,gGAA6F;AAgBzF,kHAhBK,qEAAiC,OAgBL;AAZrC,oFAAoD;AAgBhD,4BAhBG,2BAAiB,CAgBH"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;AAAA;;;;;;;;;;;;;;GAcG;AACH,oEAAoC;AAkBhC,oBAlBG,mBAAS,CAkBH;AAhBb,oEAAoC;AAkBhC,oBAlBG,mBAAS,CAkBH;AAhBb,oEAAiE;AAkB7D,oGAlBK,yCAAmB,OAkBL;AAfvB,0FAA0D;AAkBtD,+BAlBG,8BAAoB,CAkBH;AAhBxB,gGAA6F;AAkBzF,kHAlBK,qEAAiC,OAkBL;AAdrC,gEAAgC;AAkB5B,kBAlBG,iBAAO,CAkBH;AAhBX,oFAAoD;AAkBhD,4BAlBG,2BAAiB,CAkBH"}
@@ -26,6 +26,8 @@ import { IncrementalRateModelCalculateType } from "./enum/IncrementalRateModelCa
26
26
  import { IncrementalRateModelCalculateTypeIsLinearOptions } from "./options/IncrementalRateModelCalculateTypeIsLinearOptions"
27
27
  import { IncrementalRateModelCalculateTypeIsPowerOptions } from "./options/IncrementalRateModelCalculateTypeIsPowerOptions"
28
28
  import { IncrementalRateModelCalculateTypeIsGs2ScriptOptions } from "./options/IncrementalRateModelCalculateTypeIsGs2ScriptOptions"
29
+ import LogCost from "./LogCost";
30
+ import { LogCostOptions } from "./options/LogCostOptions";
29
31
  import CurrentMasterData from "./CurrentMasterData";
30
32
 
31
33
  export {
@@ -42,5 +44,7 @@ export {
42
44
  IncrementalRateModelCalculateTypeIsLinearOptions,
43
45
  IncrementalRateModelCalculateTypeIsPowerOptions,
44
46
  IncrementalRateModelCalculateTypeIsGs2ScriptOptions,
47
+ LogCost,
48
+ LogCostOptions,
45
49
  CurrentMasterData,
46
50
  }
@@ -0,0 +1,3 @@
1
+ export interface LogCostOptions {
2
+ subs?: number[] | null;
3
+ }
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ /*
3
+ * Copyright 2016- Game Server Services, Inc. or its affiliates. All Rights
4
+ * Reserved.
5
+ *
6
+ * Licensed under the Apache License, Version 2.0 (the "License").
7
+ * You may not use this file except in compliance with the License.
8
+ * A copy of the License is located at
9
+ *
10
+ * http://www.apache.org/licenses/LICENSE-2.0
11
+ *
12
+ * or in the "license" file accompanying this file. This file is distributed
13
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
14
+ * express or implied. See the License for the specific language governing
15
+ * permissions and limitations under the License.
16
+ */
17
+ Object.defineProperty(exports, "__esModule", { value: true });
18
+ //# sourceMappingURL=LogCostOptions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LogCostOptions.js","sourceRoot":"","sources":["LogCostOptions.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG"}
@@ -0,0 +1,20 @@
1
+ /*
2
+ * Copyright 2016- Game Server Services, Inc. or its affiliates. All Rights
3
+ * Reserved.
4
+ *
5
+ * Licensed under the Apache License, Version 2.0 (the "License").
6
+ * You may not use this file except in compliance with the License.
7
+ * A copy of the License is located at
8
+ *
9
+ * http://www.apache.org/licenses/LICENSE-2.0
10
+ *
11
+ * or in the "license" file accompanying this file. This file is distributed
12
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
13
+ * express or implied. See the License for the specific language governing
14
+ * permissions and limitations under the License.
15
+ */
16
+
17
+ export interface LogCostOptions {
18
+ subs?: number[]|null;
19
+ }
20
+
@@ -1 +1 @@
1
- {"version":3,"file":"CounterModel.js","sourceRoot":"","sources":["CounterModel.ts"],"names":[],"mappings":";;AA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AN3B,aAAQ,GAAgB,IAAI,CAAC;QAC7B,2BAAsB,GAAgB,IAAI,CAAC;QAOxD,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,QAAQ,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,QAAQ,mCAAI,IAAI,CAAC;QAC1C,IAAI,CAAC,sBAAsB,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,sBAAsB,mCAAI,IAAI,CAAC;IAC1E,CAAC;IAEM,UAAU;QAEb,IAAI,UAAU,GAA0B,EAAE,CAAC;QAE3C,IAAI,IAAI,CAAC,IAAI,IAAI,IAAI,EAAE;YACnB,UAAU,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC;SAClC;QACD,IAAI,IAAI,CAAC,QAAQ,IAAI,IAAI,EAAE;YACvB,UAAU,CAAC,UAAU,CAAC,GAAG,IAAI,CAAC,QAAQ,CAAC;SAC1C;QACD,IAAI,IAAI,CAAC,MAAM,IAAI,IAAI,EAAE;YACrB,UAAU,CAAC,QAAQ,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,UAAU,EACnD,CAAC,CAAC;SACV;QACD,IAAI,IAAI,CAAC,sBAAsB,IAAI,IAAI,EAAE;YACrC,UAAU,CAAC,wBAAwB,CAAC,GAAG,IAAI,CAAC,sBAAsB,CAAC;SACtE;QAED,OAAO,UAAU,CAAC;IACtB,CAAC;CACJ;AArCD,+BAqCC"}
@@ -13,6 +13,7 @@
13
13
  * express or implied. See the License for the specific language governing
14
14
  * permissions and limitations under the License.
15
15
  */
16
+ import { VerifyAction } from "../../core/model";
16
17
  import CounterScopeModel from "./CounterScopeModel";
17
18
  import { CounterModelOptions } from "./options/CounterModelOptions";
18
19
 
@@ -1,20 +1,29 @@
1
+ import { VerifyAction } from "../../core/model";
1
2
  import { CounterScopeModelOptions } from "./options/CounterScopeModelOptions";
3
+ import { CounterScopeModelScopeTypeIsResetTimingOptions } from "./options/CounterScopeModelScopeTypeIsResetTimingOptions";
4
+ import { CounterScopeModelScopeTypeIsVerifyActionOptions } from "./options/CounterScopeModelScopeTypeIsVerifyActionOptions";
2
5
  import { CounterScopeModelResetTypeIsNotResetOptions } from "./options/CounterScopeModelResetTypeIsNotResetOptions";
3
6
  import { CounterScopeModelResetTypeIsDailyOptions } from "./options/CounterScopeModelResetTypeIsDailyOptions";
4
7
  import { CounterScopeModelResetTypeIsWeeklyOptions } from "./options/CounterScopeModelResetTypeIsWeeklyOptions";
5
8
  import { CounterScopeModelResetTypeIsMonthlyOptions } from "./options/CounterScopeModelResetTypeIsMonthlyOptions";
9
+ import { CounterScopeModelScopeType } from "./enum/CounterScopeModelScopeType";
6
10
  import { CounterScopeModelResetType } from "./enum/CounterScopeModelResetType";
7
11
  import { CounterScopeModelResetDayOfWeek } from "./enum/CounterScopeModelResetDayOfWeek";
8
12
  export default class CounterScopeModel {
13
+ private readonly scopeType;
9
14
  private readonly resetType;
10
15
  private readonly resetDayOfMonth;
11
16
  private readonly resetDayOfWeek;
12
17
  private readonly resetHour;
13
- constructor(resetType: CounterScopeModelResetType, options?: CounterScopeModelOptions | null);
14
- static resetTypeIsNotReset(options?: CounterScopeModelResetTypeIsNotResetOptions | null): CounterScopeModel;
15
- static resetTypeIsDaily(resetHour: number, options?: CounterScopeModelResetTypeIsDailyOptions | null): CounterScopeModel;
16
- static resetTypeIsWeekly(resetDayOfWeek: CounterScopeModelResetDayOfWeek, resetHour: number, options?: CounterScopeModelResetTypeIsWeeklyOptions | null): CounterScopeModel;
17
- static resetTypeIsMonthly(resetDayOfMonth: number, resetHour: number, options?: CounterScopeModelResetTypeIsMonthlyOptions | null): CounterScopeModel;
18
+ private readonly conditionName;
19
+ private readonly condition;
20
+ constructor(scopeType: CounterScopeModelScopeType, options?: CounterScopeModelOptions | null);
21
+ static scopeTypeIsResetTiming(resetType: CounterScopeModelResetType, options?: CounterScopeModelScopeTypeIsResetTimingOptions | null): CounterScopeModel;
22
+ static scopeTypeIsVerifyAction(conditionName: string, condition: VerifyAction, options?: CounterScopeModelScopeTypeIsVerifyActionOptions | null): CounterScopeModel;
23
+ static resetTypeIsNotReset(scopeType: CounterScopeModelScopeType, options?: CounterScopeModelResetTypeIsNotResetOptions | null): CounterScopeModel;
24
+ static resetTypeIsDaily(scopeType: CounterScopeModelScopeType, resetHour: number, options?: CounterScopeModelResetTypeIsDailyOptions | null): CounterScopeModel;
25
+ static resetTypeIsWeekly(scopeType: CounterScopeModelScopeType, resetDayOfWeek: CounterScopeModelResetDayOfWeek, resetHour: number, options?: CounterScopeModelResetTypeIsWeeklyOptions | null): CounterScopeModel;
26
+ static resetTypeIsMonthly(scopeType: CounterScopeModelScopeType, resetDayOfMonth: number, resetHour: number, options?: CounterScopeModelResetTypeIsMonthlyOptions | null): CounterScopeModel;
18
27
  properties(): {
19
28
  [name: string]: any;
20
29
  };
@@ -1,39 +1,60 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- const CounterScopeModelResetType_1 = require("./enum/CounterScopeModelResetType");
3
+ const CounterScopeModelScopeType_1 = require("./enum/CounterScopeModelScopeType");
4
4
  class CounterScopeModel {
5
- constructor(resetType, options = null) {
6
- var _a, _b, _c;
5
+ constructor(scopeType, options = null) {
6
+ var _a, _b, _c, _d, _e, _f;
7
+ this.resetType = null;
7
8
  this.resetDayOfMonth = null;
8
9
  this.resetDayOfWeek = null;
9
10
  this.resetHour = null;
10
- this.resetType = resetType;
11
- this.resetDayOfMonth = (_a = options === null || options === void 0 ? void 0 : options.resetDayOfMonth) !== null && _a !== void 0 ? _a : null;
12
- this.resetDayOfWeek = (_b = options === null || options === void 0 ? void 0 : options.resetDayOfWeek) !== null && _b !== void 0 ? _b : null;
13
- this.resetHour = (_c = options === null || options === void 0 ? void 0 : options.resetHour) !== null && _c !== void 0 ? _c : null;
11
+ this.conditionName = null;
12
+ this.condition = null;
13
+ this.scopeType = scopeType;
14
+ this.resetType = (_a = options === null || options === void 0 ? void 0 : options.resetType) !== null && _a !== void 0 ? _a : null;
15
+ this.resetDayOfMonth = (_b = options === null || options === void 0 ? void 0 : options.resetDayOfMonth) !== null && _b !== void 0 ? _b : null;
16
+ this.resetDayOfWeek = (_c = options === null || options === void 0 ? void 0 : options.resetDayOfWeek) !== null && _c !== void 0 ? _c : null;
17
+ this.resetHour = (_d = options === null || options === void 0 ? void 0 : options.resetHour) !== null && _d !== void 0 ? _d : null;
18
+ this.conditionName = (_e = options === null || options === void 0 ? void 0 : options.conditionName) !== null && _e !== void 0 ? _e : null;
19
+ this.condition = (_f = options === null || options === void 0 ? void 0 : options.condition) !== null && _f !== void 0 ? _f : null;
14
20
  }
15
- static resetTypeIsNotReset(options = null) {
16
- return new CounterScopeModel(CounterScopeModelResetType_1.CounterScopeModelResetType.NOT_RESET, {});
21
+ static scopeTypeIsResetTiming(resetType, options = null) {
22
+ return new CounterScopeModel(CounterScopeModelScopeType_1.CounterScopeModelScopeType.RESET_TIMING, {
23
+ resetType: resetType,
24
+ });
25
+ }
26
+ static scopeTypeIsVerifyAction(conditionName, condition, options = null) {
27
+ return new CounterScopeModel(CounterScopeModelScopeType_1.CounterScopeModelScopeType.VERIFY_ACTION, {
28
+ conditionName: conditionName,
29
+ condition: condition,
30
+ });
31
+ }
32
+ static resetTypeIsNotReset(scopeType, options = null) {
33
+ return new CounterScopeModel(scopeType, {});
17
34
  }
18
- static resetTypeIsDaily(resetHour, options = null) {
19
- return new CounterScopeModel(CounterScopeModelResetType_1.CounterScopeModelResetType.DAILY, {
35
+ static resetTypeIsDaily(scopeType, resetHour, options = null) {
36
+ return new CounterScopeModel(scopeType, {
20
37
  resetHour: resetHour,
21
38
  });
22
39
  }
23
- static resetTypeIsWeekly(resetDayOfWeek, resetHour, options = null) {
24
- return new CounterScopeModel(CounterScopeModelResetType_1.CounterScopeModelResetType.WEEKLY, {
40
+ static resetTypeIsWeekly(scopeType, resetDayOfWeek, resetHour, options = null) {
41
+ return new CounterScopeModel(scopeType, {
25
42
  resetDayOfWeek: resetDayOfWeek,
26
43
  resetHour: resetHour,
27
44
  });
28
45
  }
29
- static resetTypeIsMonthly(resetDayOfMonth, resetHour, options = null) {
30
- return new CounterScopeModel(CounterScopeModelResetType_1.CounterScopeModelResetType.MONTHLY, {
46
+ static resetTypeIsMonthly(scopeType, resetDayOfMonth, resetHour, options = null) {
47
+ return new CounterScopeModel(scopeType, {
31
48
  resetDayOfMonth: resetDayOfMonth,
32
49
  resetHour: resetHour,
33
50
  });
34
51
  }
35
52
  properties() {
53
+ var _a;
36
54
  let properties = {};
55
+ if (this.scopeType != null) {
56
+ properties["scopeType"] = this.scopeType;
57
+ }
37
58
  if (this.resetType != null) {
38
59
  properties["resetType"] = this.resetType;
39
60
  }
@@ -46,6 +67,12 @@ class CounterScopeModel {
46
67
  if (this.resetHour != null) {
47
68
  properties["resetHour"] = this.resetHour;
48
69
  }
70
+ if (this.conditionName != null) {
71
+ properties["conditionName"] = this.conditionName;
72
+ }
73
+ if (this.condition != null) {
74
+ properties["condition"] = (_a = this.condition) === null || _a === void 0 ? void 0 : _a.properties();
75
+ }
49
76
  return properties;
50
77
  }
51
78
  }
@@ -1 +1 @@
1
- {"version":3,"file":"CounterScopeModel.js","sourceRoot":"","sources":["CounterScopeModel.ts"],"names":[],"mappings":";;AAoBA,kFAA+E;AAG/E,MAAqB,iBAAiB;IAMlC,YACI,SAAqC,EACrC,UAAyC,IAAI;;QANhC,oBAAe,GAAgB,IAAI,CAAC;QACpC,mBAAc,GAAyC,IAAI,CAAC;QAC5D,cAAS,GAAgB,IAAI,CAAC;QAM3C,IAAI,CAAC,SAAS,GAAG,SAAS,CAAC;QAC3B,IAAI,CAAC,eAAe,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,eAAe,mCAAI,IAAI,CAAC;QACxD,I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;YACxB,UAAU,CAAC,WAAW,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC;SAC5C;QACD,IAAI,IAAI,CAAC,SAAS,IAAI,IAAI,EAAE;YACxB,UAAU,CAAC,WAAW,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC;SAC5C;QACD,IAAI,IAAI,CAAC,eAAe,IAAI,IAAI,EAAE;YAC9B,UAAU,CAAC,iBAAiB,CAAC,GAAG,IAAI,CAAC,eAAe,CAAC;SACxD;QACD,IAAI,IAAI,CAAC,cAAc,IAAI,IAAI,EAAE;YAC7B,UAAU,CAAC,gBAAgB,CAAC,GAAG,IAAI,CAAC,cAAc,CAAC;SACtD;QACD,IAAI,IAAI,CAAC,SAAS,IAAI,IAAI,EAAE;YACxB,UAAU,CAAC,WAAW,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC;SAC5C;QACD,IAAI,IAAI,CAAC,aAAa,IAAI,IAAI,EAAE;YAC5B,UAAU,CAAC,eAAe,CAAC,GAAG,IAAI,CAAC,aAAa,CAAC;SACpD;QACD,IAAI,IAAI,CAAC,SAAS,IAAI,IAAI,EAAE;YACxB,UAAU,CAAC,WAAW,CAAC,GAAG,MAAA,IAAI,CAAC,SAAS,0CAAE,UAAU,EACnD,CAAC;SACL;QAED,OAAO,UAAU,CAAC;IACtB,CAAC;CACJ;AAnID,oCAmIC"}
@@ -13,46 +13,84 @@
13
13
  * express or implied. See the License for the specific language governing
14
14
  * permissions and limitations under the License.
15
15
  */
16
+ import { VerifyAction } from "../../core/model";
16
17
  import { CounterScopeModelOptions } from "./options/CounterScopeModelOptions";
18
+ import { CounterScopeModelScopeTypeIsResetTimingOptions } from "./options/CounterScopeModelScopeTypeIsResetTimingOptions";
19
+ import { CounterScopeModelScopeTypeIsVerifyActionOptions } from "./options/CounterScopeModelScopeTypeIsVerifyActionOptions";
17
20
  import { CounterScopeModelResetTypeIsNotResetOptions } from "./options/CounterScopeModelResetTypeIsNotResetOptions";
18
21
  import { CounterScopeModelResetTypeIsDailyOptions } from "./options/CounterScopeModelResetTypeIsDailyOptions";
19
22
  import { CounterScopeModelResetTypeIsWeeklyOptions } from "./options/CounterScopeModelResetTypeIsWeeklyOptions";
20
23
  import { CounterScopeModelResetTypeIsMonthlyOptions } from "./options/CounterScopeModelResetTypeIsMonthlyOptions";
24
+ import { CounterScopeModelScopeType } from "./enum/CounterScopeModelScopeType";
21
25
  import { CounterScopeModelResetType } from "./enum/CounterScopeModelResetType";
22
26
  import { CounterScopeModelResetDayOfWeek } from "./enum/CounterScopeModelResetDayOfWeek";
23
27
 
24
28
  export default class CounterScopeModel {
25
- private readonly resetType: CounterScopeModelResetType;
29
+ private readonly scopeType: CounterScopeModelScopeType;
30
+ private readonly resetType: CounterScopeModelResetType|null = null;
26
31
  private readonly resetDayOfMonth: number|null = null;
27
32
  private readonly resetDayOfWeek: CounterScopeModelResetDayOfWeek|null = null;
28
33
  private readonly resetHour: number|null = null;
34
+ private readonly conditionName: string|null = null;
35
+ private readonly condition: VerifyAction|null = null;
29
36
 
30
37
  public constructor(
31
- resetType: CounterScopeModelResetType,
38
+ scopeType: CounterScopeModelScopeType,
32
39
  options: CounterScopeModelOptions|null = null,
33
40
  ) {
34
- this.resetType = resetType;
41
+ this.scopeType = scopeType;
42
+ this.resetType = options?.resetType ?? null;
35
43
  this.resetDayOfMonth = options?.resetDayOfMonth ?? null;
36
44
  this.resetDayOfWeek = options?.resetDayOfWeek ?? null;
37
45
  this.resetHour = options?.resetHour ?? null;
46
+ this.conditionName = options?.conditionName ?? null;
47
+ this.condition = options?.condition ?? null;
48
+ }
49
+
50
+ public static scopeTypeIsResetTiming(
51
+ resetType: CounterScopeModelResetType,
52
+ options: CounterScopeModelScopeTypeIsResetTimingOptions|null = null,
53
+ ): CounterScopeModel {
54
+ return new CounterScopeModel(
55
+ CounterScopeModelScopeType.RESET_TIMING,
56
+ {
57
+ resetType: resetType,
58
+ },
59
+ );
60
+ }
61
+
62
+ public static scopeTypeIsVerifyAction(
63
+ conditionName: string,
64
+ condition: VerifyAction,
65
+ options: CounterScopeModelScopeTypeIsVerifyActionOptions|null = null,
66
+ ): CounterScopeModel {
67
+ return new CounterScopeModel(
68
+ CounterScopeModelScopeType.VERIFY_ACTION,
69
+ {
70
+ conditionName: conditionName,
71
+ condition: condition,
72
+ },
73
+ );
38
74
  }
39
75
 
40
76
  public static resetTypeIsNotReset(
77
+ scopeType: CounterScopeModelScopeType,
41
78
  options: CounterScopeModelResetTypeIsNotResetOptions|null = null,
42
79
  ): CounterScopeModel {
43
80
  return new CounterScopeModel(
44
- CounterScopeModelResetType.NOT_RESET,
81
+ scopeType,
45
82
  {
46
83
  },
47
84
  );
48
85
  }
49
86
 
50
87
  public static resetTypeIsDaily(
88
+ scopeType: CounterScopeModelScopeType,
51
89
  resetHour: number,
52
90
  options: CounterScopeModelResetTypeIsDailyOptions|null = null,
53
91
  ): CounterScopeModel {
54
92
  return new CounterScopeModel(
55
- CounterScopeModelResetType.DAILY,
93
+ scopeType,
56
94
  {
57
95
  resetHour: resetHour,
58
96
  },
@@ -60,12 +98,13 @@ export default class CounterScopeModel {
60
98
  }
61
99
 
62
100
  public static resetTypeIsWeekly(
101
+ scopeType: CounterScopeModelScopeType,
63
102
  resetDayOfWeek: CounterScopeModelResetDayOfWeek,
64
103
  resetHour: number,
65
104
  options: CounterScopeModelResetTypeIsWeeklyOptions|null = null,
66
105
  ): CounterScopeModel {
67
106
  return new CounterScopeModel(
68
- CounterScopeModelResetType.WEEKLY,
107
+ scopeType,
69
108
  {
70
109
  resetDayOfWeek: resetDayOfWeek,
71
110
  resetHour: resetHour,
@@ -74,12 +113,13 @@ export default class CounterScopeModel {
74
113
  }
75
114
 
76
115
  public static resetTypeIsMonthly(
116
+ scopeType: CounterScopeModelScopeType,
77
117
  resetDayOfMonth: number,
78
118
  resetHour: number,
79
119
  options: CounterScopeModelResetTypeIsMonthlyOptions|null = null,
80
120
  ): CounterScopeModel {
81
121
  return new CounterScopeModel(
82
- CounterScopeModelResetType.MONTHLY,
122
+ scopeType,
83
123
  {
84
124
  resetDayOfMonth: resetDayOfMonth,
85
125
  resetHour: resetHour,
@@ -91,6 +131,9 @@ export default class CounterScopeModel {
91
131
  ): {[name: string]: any} {
92
132
  let properties: {[name: string]: any} = {};
93
133
 
134
+ if (this.scopeType != null) {
135
+ properties["scopeType"] = this.scopeType;
136
+ }
94
137
  if (this.resetType != null) {
95
138
  properties["resetType"] = this.resetType;
96
139
  }
@@ -103,6 +146,13 @@ export default class CounterScopeModel {
103
146
  if (this.resetHour != null) {
104
147
  properties["resetHour"] = this.resetHour;
105
148
  }
149
+ if (this.conditionName != null) {
150
+ properties["conditionName"] = this.conditionName;
151
+ }
152
+ if (this.condition != null) {
153
+ properties["condition"] = this.condition?.properties(
154
+ );
155
+ }
106
156
 
107
157
  return properties;
108
158
  }
@@ -1,10 +1,17 @@
1
1
  import { ScopedValueOptions } from "./options/ScopedValueOptions";
2
+ import { ScopedValueScopeTypeIsResetTimingOptions } from "./options/ScopedValueScopeTypeIsResetTimingOptions";
3
+ import { ScopedValueScopeTypeIsVerifyActionOptions } from "./options/ScopedValueScopeTypeIsVerifyActionOptions";
4
+ import { ScopedValueScopeType } from "./enum/ScopedValueScopeType";
2
5
  import { ScopedValueResetType } from "./enum/ScopedValueResetType";
3
6
  export default class ScopedValue {
4
- private readonly resetType;
7
+ private readonly scopeType;
5
8
  private readonly value;
9
+ private readonly resetType;
10
+ private readonly conditionName;
6
11
  private readonly nextResetAt;
7
- constructor(resetType: ScopedValueResetType, value: number, options?: ScopedValueOptions | null);
12
+ constructor(scopeType: ScopedValueScopeType, value: number, options?: ScopedValueOptions | null);
13
+ static scopeTypeIsResetTiming(value: number, resetType: ScopedValueResetType, options?: ScopedValueScopeTypeIsResetTimingOptions | null): ScopedValue;
14
+ static scopeTypeIsVerifyAction(value: number, conditionName: string, options?: ScopedValueScopeTypeIsVerifyActionOptions | null): ScopedValue;
8
15
  properties(): {
9
16
  [name: string]: any;
10
17
  };
@@ -1,18 +1,40 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ const ScopedValueScopeType_1 = require("./enum/ScopedValueScopeType");
3
4
  class ScopedValue {
4
- constructor(resetType, value, options = null) {
5
- var _a;
5
+ constructor(scopeType, value, options = null) {
6
+ var _a, _b, _c;
7
+ this.resetType = null;
8
+ this.conditionName = null;
6
9
  this.nextResetAt = null;
7
- this.resetType = resetType;
10
+ this.scopeType = scopeType;
8
11
  this.value = value;
9
- this.nextResetAt = (_a = options === null || options === void 0 ? void 0 : options.nextResetAt) !== null && _a !== void 0 ? _a : null;
12
+ this.resetType = (_a = options === null || options === void 0 ? void 0 : options.resetType) !== null && _a !== void 0 ? _a : null;
13
+ this.conditionName = (_b = options === null || options === void 0 ? void 0 : options.conditionName) !== null && _b !== void 0 ? _b : null;
14
+ this.nextResetAt = (_c = options === null || options === void 0 ? void 0 : options.nextResetAt) !== null && _c !== void 0 ? _c : null;
15
+ }
16
+ static scopeTypeIsResetTiming(value, resetType, options = null) {
17
+ return new ScopedValue(ScopedValueScopeType_1.ScopedValueScopeType.RESET_TIMING, value, {
18
+ resetType: resetType,
19
+ nextResetAt: options === null || options === void 0 ? void 0 : options.nextResetAt,
20
+ });
21
+ }
22
+ static scopeTypeIsVerifyAction(value, conditionName, options = null) {
23
+ return new ScopedValue(ScopedValueScopeType_1.ScopedValueScopeType.VERIFY_ACTION, value, {
24
+ conditionName: conditionName,
25
+ });
10
26
  }
11
27
  properties() {
12
28
  let properties = {};
29
+ if (this.scopeType != null) {
30
+ properties["scopeType"] = this.scopeType;
31
+ }
13
32
  if (this.resetType != null) {
14
33
  properties["resetType"] = this.resetType;
15
34
  }
35
+ if (this.conditionName != null) {
36
+ properties["conditionName"] = this.conditionName;
37
+ }
16
38
  if (this.value != null) {
17
39
  properties["value"] = this.value;
18
40
  }
@@ -1 +1 @@
1
- {"version":3,"file":"ScopedValue.js","sourceRoot":"","sources":["ScopedValue.ts"],"names":[],"mappings":";;AA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