gs2-cdk 1.0.50 → 1.0.52
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.
- package/enhance/model/CurrentMasterData.d.ts +3 -1
- package/enhance/model/CurrentMasterData.js +5 -1
- package/enhance/model/CurrentMasterData.js.map +1 -1
- package/enhance/model/CurrentMasterData.ts +8 -0
- package/enhance/model/Namespace.d.ts +2 -1
- package/enhance/model/Namespace.js +2 -2
- package/enhance/model/Namespace.js.map +1 -1
- package/enhance/model/Namespace.ts +3 -0
- package/enhance/model/UnleashRateEntryModel.d.ts +9 -0
- package/enhance/model/UnleashRateEntryModel.js +20 -0
- package/enhance/model/UnleashRateEntryModel.js.map +1 -0
- package/enhance/model/UnleashRateEntryModel.ts +44 -0
- package/enhance/model/UnleashRateModel.d.ts +14 -0
- package/enhance/model/UnleashRateModel.js +39 -0
- package/enhance/model/UnleashRateModel.js.map +1 -0
- package/enhance/model/UnleashRateModel.ts +68 -0
- package/enhance/model/index.d.ts +5 -1
- package/enhance/model/index.js +5 -1
- package/enhance/model/index.js.map +1 -1
- package/enhance/model/index.ts +8 -0
- package/enhance/model/options/UnleashRateEntryModelOptions.d.ts +2 -0
- package/enhance/model/options/UnleashRateEntryModelOptions.js +18 -0
- package/enhance/model/options/UnleashRateEntryModelOptions.js.map +1 -0
- package/enhance/model/options/UnleashRateEntryModelOptions.ts +19 -0
- package/enhance/model/options/UnleashRateModelOptions.d.ts +4 -0
- package/enhance/model/options/UnleashRateModelOptions.js +3 -0
- package/enhance/model/options/UnleashRateModelOptions.js.map +1 -0
- package/enhance/model/options/UnleashRateModelOptions.ts +22 -0
- package/enhance/ref/NamespaceRef.d.ts +2 -0
- package/enhance/ref/NamespaceRef.js +4 -0
- package/enhance/ref/NamespaceRef.js.map +1 -1
- package/enhance/ref/NamespaceRef.ts +10 -0
- package/enhance/ref/UnleashRateModelRef.d.ts +6 -0
- package/enhance/ref/UnleashRateModelRef.js +38 -0
- package/enhance/ref/UnleashRateModelRef.js.map +1 -0
- package/enhance/ref/UnleashRateModelRef.ts +52 -0
- package/enhance/ref/index.d.ts +2 -1
- package/enhance/ref/index.js +3 -1
- package/enhance/ref/index.js.map +1 -1
- package/enhance/ref/index.ts +2 -0
- package/enhance/stampSheet/UnleashByUserId.d.ts +15 -0
- package/enhance/stampSheet/UnleashByUserId.js +57 -0
- package/enhance/stampSheet/UnleashByUserId.js.map +1 -0
- package/enhance/stampSheet/UnleashByUserId.ts +77 -0
- package/enhance/stampSheet/index.d.ts +2 -1
- package/enhance/stampSheet/index.js +3 -1
- package/enhance/stampSheet/index.js.map +1 -1
- package/enhance/stampSheet/index.ts +2 -0
- package/grade/index.d.ts +12 -0
- package/grade/index.js +32 -0
- package/grade/index.js.map +1 -0
- package/grade/index.ts +36 -0
- package/grade/model/AcquireActionRate.d.ts +16 -0
- package/grade/model/AcquireActionRate.js +42 -0
- package/grade/model/AcquireActionRate.js.map +1 -0
- package/grade/model/AcquireActionRate.ts +85 -0
- package/grade/model/CurrentMasterData.d.ts +13 -0
- package/grade/model/CurrentMasterData.js +50 -0
- package/grade/model/CurrentMasterData.js.map +1 -0
- package/grade/model/CurrentMasterData.ts +70 -0
- package/grade/model/DefaultGradeModel.d.ts +9 -0
- package/grade/model/DefaultGradeModel.js +20 -0
- package/grade/model/DefaultGradeModel.js.map +1 -0
- package/grade/model/DefaultGradeModel.ts +44 -0
- package/grade/model/GradeEntryModel.d.ts +11 -0
- package/grade/model/GradeEntryModel.js +30 -0
- package/grade/model/GradeEntryModel.js.map +1 -0
- package/grade/model/GradeEntryModel.ts +55 -0
- package/grade/model/GradeModel.d.ts +14 -0
- package/grade/model/GradeModel.js +40 -0
- package/grade/model/GradeModel.js.map +1 -0
- package/grade/model/GradeModel.ts +71 -0
- package/grade/model/Namespace.d.ts +22 -0
- package/grade/model/Namespace.js +77 -0
- package/grade/model/Namespace.js.map +1 -0
- package/grade/model/Namespace.ts +122 -0
- package/grade/model/enum/AcquireActionRateMode.d.ts +5 -0
- package/grade/model/enum/AcquireActionRateMode.js +23 -0
- package/grade/model/enum/AcquireActionRateMode.js.map +1 -0
- package/grade/model/enum/AcquireActionRateMode.ts +23 -0
- package/grade/model/index.d.ts +15 -0
- package/grade/model/index.js +34 -0
- package/grade/model/index.js.map +1 -0
- package/grade/model/index.ts +46 -0
- package/grade/model/options/AcquireActionRateModeIsBigOptions.d.ts +2 -0
- package/grade/model/options/AcquireActionRateModeIsBigOptions.js +3 -0
- package/grade/model/options/AcquireActionRateModeIsBigOptions.js.map +1 -0
- package/grade/model/options/AcquireActionRateModeIsBigOptions.ts +19 -0
- package/grade/model/options/AcquireActionRateModeIsDoubleOptions.d.ts +2 -0
- package/grade/model/options/AcquireActionRateModeIsDoubleOptions.js +3 -0
- package/grade/model/options/AcquireActionRateModeIsDoubleOptions.js.map +1 -0
- package/grade/model/options/AcquireActionRateModeIsDoubleOptions.ts +19 -0
- package/grade/model/options/AcquireActionRateOptions.d.ts +4 -0
- package/grade/model/options/AcquireActionRateOptions.js +3 -0
- package/grade/model/options/AcquireActionRateOptions.js.map +1 -0
- package/grade/model/options/AcquireActionRateOptions.ts +22 -0
- package/grade/model/options/DefaultGradeModelOptions.d.ts +2 -0
- package/grade/model/options/DefaultGradeModelOptions.js +18 -0
- package/grade/model/options/DefaultGradeModelOptions.js.map +1 -0
- package/grade/model/options/DefaultGradeModelOptions.ts +19 -0
- package/grade/model/options/GradeEntryModelOptions.d.ts +3 -0
- package/grade/model/options/GradeEntryModelOptions.js +18 -0
- package/grade/model/options/GradeEntryModelOptions.js.map +1 -0
- package/grade/model/options/GradeEntryModelOptions.ts +20 -0
- package/grade/model/options/GradeModelOptions.d.ts +7 -0
- package/grade/model/options/GradeModelOptions.js +3 -0
- package/grade/model/options/GradeModelOptions.js.map +1 -0
- package/grade/model/options/GradeModelOptions.ts +25 -0
- package/grade/model/options/NamespaceOptions.d.ts +9 -0
- package/grade/model/options/NamespaceOptions.js +3 -0
- package/grade/model/options/NamespaceOptions.js.map +1 -0
- package/grade/model/options/NamespaceOptions.ts +26 -0
- package/grade/ref/GradeModelRef.d.ts +6 -0
- package/grade/ref/GradeModelRef.js +38 -0
- package/grade/ref/GradeModelRef.js.map +1 -0
- package/grade/ref/GradeModelRef.ts +52 -0
- package/grade/ref/NamespaceRef.d.ts +21 -0
- package/grade/ref/NamespaceRef.js +64 -0
- package/grade/ref/NamespaceRef.js.map +1 -0
- package/grade/ref/NamespaceRef.ts +159 -0
- package/grade/ref/index.d.ts +3 -0
- package/grade/ref/index.js +24 -0
- package/grade/ref/index.js.map +1 -0
- package/grade/ref/index.ts +22 -0
- package/grade/stampSheet/AddGradeByUserId.d.ts +13 -0
- package/grade/stampSheet/AddGradeByUserId.js +53 -0
- package/grade/stampSheet/AddGradeByUserId.js.map +1 -0
- package/grade/stampSheet/AddGradeByUserId.ts +69 -0
- package/grade/stampSheet/ApplyRankCapByUserId.d.ts +12 -0
- package/grade/stampSheet/ApplyRankCapByUserId.js +48 -0
- package/grade/stampSheet/ApplyRankCapByUserId.js.map +1 -0
- package/grade/stampSheet/ApplyRankCapByUserId.ts +63 -0
- package/grade/stampSheet/MultiplyAcquireActionsByUserId.d.ts +14 -0
- package/grade/stampSheet/MultiplyAcquireActionsByUserId.js +57 -0
- package/grade/stampSheet/MultiplyAcquireActionsByUserId.js.map +1 -0
- package/grade/stampSheet/MultiplyAcquireActionsByUserId.ts +76 -0
- package/grade/stampSheet/SubGradeByUserId.d.ts +13 -0
- package/grade/stampSheet/SubGradeByUserId.js +53 -0
- package/grade/stampSheet/SubGradeByUserId.js.map +1 -0
- package/grade/stampSheet/SubGradeByUserId.ts +69 -0
- package/grade/stampSheet/VerifyGradeByUserId.d.ts +15 -0
- package/grade/stampSheet/VerifyGradeByUserId.js +57 -0
- package/grade/stampSheet/VerifyGradeByUserId.js.map +1 -0
- package/grade/stampSheet/VerifyGradeByUserId.ts +76 -0
- package/grade/stampSheet/VerifyGradeUpMaterialByUserId.d.ts +15 -0
- package/grade/stampSheet/VerifyGradeUpMaterialByUserId.js +56 -0
- package/grade/stampSheet/VerifyGradeUpMaterialByUserId.js.map +1 -0
- package/grade/stampSheet/VerifyGradeUpMaterialByUserId.ts +76 -0
- package/grade/stampSheet/enum/StatusVerifyType.d.ts +5 -0
- package/grade/stampSheet/enum/StatusVerifyType.js +23 -0
- package/grade/stampSheet/enum/StatusVerifyType.js.map +1 -0
- package/grade/stampSheet/enum/StatusVerifyType.ts +23 -0
- package/grade/stampSheet/index.d.ts +7 -0
- package/grade/stampSheet/index.js +32 -0
- package/grade/stampSheet/index.js.map +1 -0
- package/grade/stampSheet/index.ts +30 -0
- package/package.json +1 -1
- package/stateMachine/ref/NamespaceRef.d.ts +1 -2
- package/stateMachine/ref/NamespaceRef.js +2 -2
- package/stateMachine/ref/NamespaceRef.js.map +1 -1
- package/stateMachine/ref/NamespaceRef.ts +0 -3
- package/stateMachine/stampSheet/StartStateMachineByUserId.d.ts +1 -3
- package/stateMachine/stampSheet/StartStateMachineByUserId.js +1 -6
- package/stateMachine/stampSheet/StartStateMachineByUserId.js.map +1 -1
- package/stateMachine/stampSheet/StartStateMachineByUserId.ts +0 -7
|
@@ -0,0 +1,70 @@
|
|
|
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 {CdkResource, Stack} from "../../core/model";
|
|
17
|
+
import GradeModel from "./GradeModel";
|
|
18
|
+
|
|
19
|
+
export default class CurrentMasterData extends CdkResource {
|
|
20
|
+
private readonly version: string= "2023-12-25";
|
|
21
|
+
private readonly namespaceName: string;
|
|
22
|
+
private readonly gradeModels: GradeModel[];
|
|
23
|
+
|
|
24
|
+
public constructor(
|
|
25
|
+
stack: Stack,
|
|
26
|
+
namespaceName: string,
|
|
27
|
+
gradeModels: GradeModel[],
|
|
28
|
+
) {
|
|
29
|
+
super(
|
|
30
|
+
"Grade_CurrentGradeMaster_" + namespaceName
|
|
31
|
+
);
|
|
32
|
+
|
|
33
|
+
this.namespaceName = namespaceName;
|
|
34
|
+
this.gradeModels = gradeModels;
|
|
35
|
+
stack.addResource(
|
|
36
|
+
this,
|
|
37
|
+
);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
public alternateKeys(
|
|
41
|
+
) {
|
|
42
|
+
return this.namespaceName;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
public resourceType(
|
|
46
|
+
): string {
|
|
47
|
+
return "GS2::Grade::CurrentGradeMaster";
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
public properties(
|
|
51
|
+
): {[name: string]: any} {
|
|
52
|
+
let properties: {[name: string]: any} = {};
|
|
53
|
+
let settings: {[name: string]: any} = {};
|
|
54
|
+
|
|
55
|
+
settings["version"] = this.version
|
|
56
|
+
if (this.gradeModels != null) {
|
|
57
|
+
settings["gradeModels"] = this.gradeModels.map(v => v.properties(
|
|
58
|
+
));
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
if (this.namespaceName != null) {
|
|
62
|
+
properties["NamespaceName"] = this.namespaceName;
|
|
63
|
+
}
|
|
64
|
+
if (settings != null) {
|
|
65
|
+
properties["Settings"] = settings;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
return properties;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { DefaultGradeModelOptions } from "./options/DefaultGradeModelOptions";
|
|
2
|
+
export default class DefaultGradeModel {
|
|
3
|
+
private readonly propertyIdRegex;
|
|
4
|
+
private readonly defaultGradeValue;
|
|
5
|
+
constructor(propertyIdRegex: string, defaultGradeValue: number, options?: DefaultGradeModelOptions | null);
|
|
6
|
+
properties(): {
|
|
7
|
+
[name: string]: any;
|
|
8
|
+
};
|
|
9
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
class DefaultGradeModel {
|
|
4
|
+
constructor(propertyIdRegex, defaultGradeValue, options = null) {
|
|
5
|
+
this.propertyIdRegex = propertyIdRegex;
|
|
6
|
+
this.defaultGradeValue = defaultGradeValue;
|
|
7
|
+
}
|
|
8
|
+
properties() {
|
|
9
|
+
let properties = {};
|
|
10
|
+
if (this.propertyIdRegex != null) {
|
|
11
|
+
properties["propertyIdRegex"] = this.propertyIdRegex;
|
|
12
|
+
}
|
|
13
|
+
if (this.defaultGradeValue != null) {
|
|
14
|
+
properties["defaultGradeValue"] = this.defaultGradeValue;
|
|
15
|
+
}
|
|
16
|
+
return properties;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
exports.default = DefaultGradeModel;
|
|
20
|
+
//# sourceMappingURL=DefaultGradeModel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DefaultGradeModel.js","sourceRoot":"","sources":["DefaultGradeModel.ts"],"names":[],"mappings":";;AAiBA,MAAqB,iBAAiB;IAIlC,YACI,eAAuB,EACvB,iBAAyB,EACzB,UAAyC,IAAI;QAE7C,IAAI,CAAC,eAAe,GAAG,eAAe,CAAC;QACvC,IAAI,CAAC,iBAAiB,GAAG,iBAAiB,CAAC;IAC/C,CAAC;IAEM,UAAU;QAEb,IAAI,UAAU,GAA0B,EAAE,CAAC;QAE3C,IAAI,IAAI,CAAC,eAAe,IAAI,IAAI,EAAE;YAC9B,UAAU,CAAC,iBAAiB,CAAC,GAAG,IAAI,CAAC,eAAe,CAAC;SACxD;QACD,IAAI,IAAI,CAAC,iBAAiB,IAAI,IAAI,EAAE;YAChC,UAAU,CAAC,mBAAmB,CAAC,GAAG,IAAI,CAAC,iBAAiB,CAAC;SAC5D;QAED,OAAO,UAAU,CAAC;IACtB,CAAC;CACJ;AA1BD,oCA0BC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
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 { DefaultGradeModelOptions } from "./options/DefaultGradeModelOptions";
|
|
17
|
+
|
|
18
|
+
export default class DefaultGradeModel {
|
|
19
|
+
private readonly propertyIdRegex: string;
|
|
20
|
+
private readonly defaultGradeValue: number;
|
|
21
|
+
|
|
22
|
+
public constructor(
|
|
23
|
+
propertyIdRegex: string,
|
|
24
|
+
defaultGradeValue: number,
|
|
25
|
+
options: DefaultGradeModelOptions|null = null,
|
|
26
|
+
) {
|
|
27
|
+
this.propertyIdRegex = propertyIdRegex;
|
|
28
|
+
this.defaultGradeValue = defaultGradeValue;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
public properties(
|
|
32
|
+
): {[name: string]: any} {
|
|
33
|
+
let properties: {[name: string]: any} = {};
|
|
34
|
+
|
|
35
|
+
if (this.propertyIdRegex != null) {
|
|
36
|
+
properties["propertyIdRegex"] = this.propertyIdRegex;
|
|
37
|
+
}
|
|
38
|
+
if (this.defaultGradeValue != null) {
|
|
39
|
+
properties["defaultGradeValue"] = this.defaultGradeValue;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
return properties;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { GradeEntryModelOptions } from "./options/GradeEntryModelOptions";
|
|
2
|
+
export default class GradeEntryModel {
|
|
3
|
+
private readonly rankCapValue;
|
|
4
|
+
private readonly propertyIdRegex;
|
|
5
|
+
private readonly gradeUpPropertyIdRegex;
|
|
6
|
+
private readonly metadata;
|
|
7
|
+
constructor(rankCapValue: number, propertyIdRegex: string, gradeUpPropertyIdRegex: string, options?: GradeEntryModelOptions | null);
|
|
8
|
+
properties(): {
|
|
9
|
+
[name: string]: any;
|
|
10
|
+
};
|
|
11
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
class GradeEntryModel {
|
|
4
|
+
constructor(rankCapValue, propertyIdRegex, gradeUpPropertyIdRegex, options = null) {
|
|
5
|
+
var _a;
|
|
6
|
+
this.metadata = null;
|
|
7
|
+
this.rankCapValue = rankCapValue;
|
|
8
|
+
this.propertyIdRegex = propertyIdRegex;
|
|
9
|
+
this.gradeUpPropertyIdRegex = gradeUpPropertyIdRegex;
|
|
10
|
+
this.metadata = (_a = options === null || options === void 0 ? void 0 : options.metadata) !== null && _a !== void 0 ? _a : null;
|
|
11
|
+
}
|
|
12
|
+
properties() {
|
|
13
|
+
let properties = {};
|
|
14
|
+
if (this.metadata != null) {
|
|
15
|
+
properties["metadata"] = this.metadata;
|
|
16
|
+
}
|
|
17
|
+
if (this.rankCapValue != null) {
|
|
18
|
+
properties["rankCapValue"] = this.rankCapValue;
|
|
19
|
+
}
|
|
20
|
+
if (this.propertyIdRegex != null) {
|
|
21
|
+
properties["propertyIdRegex"] = this.propertyIdRegex;
|
|
22
|
+
}
|
|
23
|
+
if (this.gradeUpPropertyIdRegex != null) {
|
|
24
|
+
properties["gradeUpPropertyIdRegex"] = this.gradeUpPropertyIdRegex;
|
|
25
|
+
}
|
|
26
|
+
return properties;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
exports.default = GradeEntryModel;
|
|
30
|
+
//# sourceMappingURL=GradeEntryModel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"GradeEntryModel.js","sourceRoot":"","sources":["GradeEntryModel.ts"],"names":[],"mappings":";;AAiBA,MAAqB,eAAe;IAMhC,YACI,YAAoB,EACpB,eAAuB,EACvB,sBAA8B,EAC9B,UAAuC,IAAI;;QAN9B,aAAQ,GAAgB,IAAI,CAAC;QAQ1C,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;QACjC,IAAI,CAAC,eAAe,GAAG,eAAe,CAAC;QACvC,IAAI,CAAC,sBAAsB,GAAG,sBAAsB,CAAC;QACrD,IAAI,CAAC,QAAQ,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,QAAQ,mCAAI,IAAI,CAAC;IAC9C,CAAC;IAEM,UAAU;QAEb,IAAI,UAAU,GAA0B,EAAE,CAAC;QAE3C,IAAI,IAAI,CAAC,QAAQ,IAAI,IAAI,EAAE;YACvB,UAAU,CAAC,UAAU,CAAC,GAAG,IAAI,CAAC,QAAQ,CAAC;SAC1C;QACD,IAAI,IAAI,CAAC,YAAY,IAAI,IAAI,EAAE;YAC3B,UAAU,CAAC,cAAc,CAAC,GAAG,IAAI,CAAC,YAAY,CAAC;SAClD;QACD,IAAI,IAAI,CAAC,eAAe,IAAI,IAAI,EAAE;YAC9B,UAAU,CAAC,iBAAiB,CAAC,GAAG,IAAI,CAAC,eAAe,CAAC;SACxD;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,kCAqCC"}
|
|
@@ -0,0 +1,55 @@
|
|
|
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 { GradeEntryModelOptions } from "./options/GradeEntryModelOptions";
|
|
17
|
+
|
|
18
|
+
export default class GradeEntryModel {
|
|
19
|
+
private readonly rankCapValue: number;
|
|
20
|
+
private readonly propertyIdRegex: string;
|
|
21
|
+
private readonly gradeUpPropertyIdRegex: string;
|
|
22
|
+
private readonly metadata: string|null = null;
|
|
23
|
+
|
|
24
|
+
public constructor(
|
|
25
|
+
rankCapValue: number,
|
|
26
|
+
propertyIdRegex: string,
|
|
27
|
+
gradeUpPropertyIdRegex: string,
|
|
28
|
+
options: GradeEntryModelOptions|null = null,
|
|
29
|
+
) {
|
|
30
|
+
this.rankCapValue = rankCapValue;
|
|
31
|
+
this.propertyIdRegex = propertyIdRegex;
|
|
32
|
+
this.gradeUpPropertyIdRegex = gradeUpPropertyIdRegex;
|
|
33
|
+
this.metadata = options?.metadata ?? null;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
public properties(
|
|
37
|
+
): {[name: string]: any} {
|
|
38
|
+
let properties: {[name: string]: any} = {};
|
|
39
|
+
|
|
40
|
+
if (this.metadata != null) {
|
|
41
|
+
properties["metadata"] = this.metadata;
|
|
42
|
+
}
|
|
43
|
+
if (this.rankCapValue != null) {
|
|
44
|
+
properties["rankCapValue"] = this.rankCapValue;
|
|
45
|
+
}
|
|
46
|
+
if (this.propertyIdRegex != null) {
|
|
47
|
+
properties["propertyIdRegex"] = this.propertyIdRegex;
|
|
48
|
+
}
|
|
49
|
+
if (this.gradeUpPropertyIdRegex != null) {
|
|
50
|
+
properties["gradeUpPropertyIdRegex"] = this.gradeUpPropertyIdRegex;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
return properties;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import GradeEntryModel from "./GradeEntryModel";
|
|
2
|
+
import { GradeModelOptions } from "./options/GradeModelOptions";
|
|
3
|
+
export default class GradeModel {
|
|
4
|
+
private readonly name;
|
|
5
|
+
private readonly experienceModelId;
|
|
6
|
+
private readonly gradeEntries;
|
|
7
|
+
private readonly metadata;
|
|
8
|
+
private readonly defaultGrades;
|
|
9
|
+
private readonly acquireActionRates;
|
|
10
|
+
constructor(name: string, experienceModelId: string, gradeEntries: GradeEntryModel[], options?: GradeModelOptions | null);
|
|
11
|
+
properties(): {
|
|
12
|
+
[name: string]: any;
|
|
13
|
+
};
|
|
14
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
class GradeModel {
|
|
4
|
+
constructor(name, experienceModelId, gradeEntries, options = null) {
|
|
5
|
+
var _a, _b, _c;
|
|
6
|
+
this.metadata = null;
|
|
7
|
+
this.defaultGrades = null;
|
|
8
|
+
this.acquireActionRates = null;
|
|
9
|
+
this.name = name;
|
|
10
|
+
this.experienceModelId = experienceModelId;
|
|
11
|
+
this.gradeEntries = gradeEntries;
|
|
12
|
+
this.metadata = (_a = options === null || options === void 0 ? void 0 : options.metadata) !== null && _a !== void 0 ? _a : null;
|
|
13
|
+
this.defaultGrades = (_b = options === null || options === void 0 ? void 0 : options.defaultGrades) !== null && _b !== void 0 ? _b : null;
|
|
14
|
+
this.acquireActionRates = (_c = options === null || options === void 0 ? void 0 : options.acquireActionRates) !== null && _c !== void 0 ? _c : null;
|
|
15
|
+
}
|
|
16
|
+
properties() {
|
|
17
|
+
let properties = {};
|
|
18
|
+
if (this.name != null) {
|
|
19
|
+
properties["name"] = this.name;
|
|
20
|
+
}
|
|
21
|
+
if (this.metadata != null) {
|
|
22
|
+
properties["metadata"] = this.metadata;
|
|
23
|
+
}
|
|
24
|
+
if (this.defaultGrades != null) {
|
|
25
|
+
properties["defaultGrades"] = this.defaultGrades.map(v => v.properties());
|
|
26
|
+
}
|
|
27
|
+
if (this.experienceModelId != null) {
|
|
28
|
+
properties["experienceModelId"] = this.experienceModelId;
|
|
29
|
+
}
|
|
30
|
+
if (this.gradeEntries != null) {
|
|
31
|
+
properties["gradeEntries"] = this.gradeEntries.map(v => v.properties());
|
|
32
|
+
}
|
|
33
|
+
if (this.acquireActionRates != null) {
|
|
34
|
+
properties["acquireActionRates"] = this.acquireActionRates.map(v => v.properties());
|
|
35
|
+
}
|
|
36
|
+
return properties;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
exports.default = GradeModel;
|
|
40
|
+
//# sourceMappingURL=GradeModel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"GradeModel.js","sourceRoot":"","sources":["GradeModel.ts"],"names":[],"mappings":";;AAoBA,MAAqB,UAAU;IAQ3B,YACI,IAAY,EACZ,iBAAyB,EACzB,YAA+B,EAC/B,UAAkC,IAAI;;QARzB,aAAQ,GAAgB,IAAI,CAAC;QAC7B,kBAAa,GAA6B,IAAI,CAAC;QAC/C,uBAAkB,GAA6B,IAAI,CAAC;QAQjE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,iBAAiB,GAAG,iBAAiB,CAAC;QAC3C,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;QACjC,IAAI,CAAC,QAAQ,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,QAAQ,mCAAI,IAAI,CAAC;QAC1C,IAAI,CAAC,aAAa,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,aAAa,mCAAI,IAAI,CAAC;QACpD,IAAI,CAAC,kBAAkB,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,kBAAkB,mCAAI,IAAI,CAAC;IAClE,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,aAAa,IAAI,IAAI,EAAE;YAC5B,UAAU,CAAC,eAAe,CAAC,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,UAAU,EACjE,CAAC,CAAC;SACV;QACD,IAAI,IAAI,CAAC,iBAAiB,IAAI,IAAI,EAAE;YAChC,UAAU,CAAC,mBAAmB,CAAC,GAAG,IAAI,CAAC,iBAAiB,CAAC;SAC5D;QACD,IAAI,IAAI,CAAC,YAAY,IAAI,IAAI,EAAE;YAC3B,UAAU,CAAC,cAAc,CAAC,GAAG,IAAI,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,UAAU,EAC/D,CAAC,CAAC;SACV;QACD,IAAI,IAAI,CAAC,kBAAkB,IAAI,IAAI,EAAE;YACjC,UAAU,CAAC,oBAAoB,CAAC,GAAG,IAAI,CAAC,kBAAkB,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,UAAU,EAC3E,CAAC,CAAC;SACV;QAED,OAAO,UAAU,CAAC;IACtB,CAAC;CACJ;AAlDD,6BAkDC"}
|
|
@@ -0,0 +1,71 @@
|
|
|
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 DefaultGradeModel from "./DefaultGradeModel";
|
|
17
|
+
import GradeEntryModel from "./GradeEntryModel";
|
|
18
|
+
import AcquireActionRate from "./AcquireActionRate";
|
|
19
|
+
import { GradeModelOptions } from "./options/GradeModelOptions";
|
|
20
|
+
|
|
21
|
+
export default class GradeModel {
|
|
22
|
+
private readonly name: string;
|
|
23
|
+
private readonly experienceModelId: string;
|
|
24
|
+
private readonly gradeEntries: GradeEntryModel[];
|
|
25
|
+
private readonly metadata: string|null = null;
|
|
26
|
+
private readonly defaultGrades: DefaultGradeModel[]|null = null;
|
|
27
|
+
private readonly acquireActionRates: AcquireActionRate[]|null = null;
|
|
28
|
+
|
|
29
|
+
public constructor(
|
|
30
|
+
name: string,
|
|
31
|
+
experienceModelId: string,
|
|
32
|
+
gradeEntries: GradeEntryModel[],
|
|
33
|
+
options: GradeModelOptions|null = null,
|
|
34
|
+
) {
|
|
35
|
+
this.name = name;
|
|
36
|
+
this.experienceModelId = experienceModelId;
|
|
37
|
+
this.gradeEntries = gradeEntries;
|
|
38
|
+
this.metadata = options?.metadata ?? null;
|
|
39
|
+
this.defaultGrades = options?.defaultGrades ?? null;
|
|
40
|
+
this.acquireActionRates = options?.acquireActionRates ?? null;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
public properties(
|
|
44
|
+
): {[name: string]: any} {
|
|
45
|
+
let properties: {[name: string]: any} = {};
|
|
46
|
+
|
|
47
|
+
if (this.name != null) {
|
|
48
|
+
properties["name"] = this.name;
|
|
49
|
+
}
|
|
50
|
+
if (this.metadata != null) {
|
|
51
|
+
properties["metadata"] = this.metadata;
|
|
52
|
+
}
|
|
53
|
+
if (this.defaultGrades != null) {
|
|
54
|
+
properties["defaultGrades"] = this.defaultGrades.map(v => v.properties(
|
|
55
|
+
));
|
|
56
|
+
}
|
|
57
|
+
if (this.experienceModelId != null) {
|
|
58
|
+
properties["experienceModelId"] = this.experienceModelId;
|
|
59
|
+
}
|
|
60
|
+
if (this.gradeEntries != null) {
|
|
61
|
+
properties["gradeEntries"] = this.gradeEntries.map(v => v.properties(
|
|
62
|
+
));
|
|
63
|
+
}
|
|
64
|
+
if (this.acquireActionRates != null) {
|
|
65
|
+
properties["acquireActionRates"] = this.acquireActionRates.map(v => v.properties(
|
|
66
|
+
));
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
return properties;
|
|
70
|
+
}
|
|
71
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { CdkResource, Stack } from "../../core/model";
|
|
2
|
+
import { GetAttr } from "../../core/func";
|
|
3
|
+
import NamespaceRef from "../ref/NamespaceRef";
|
|
4
|
+
import GradeModel from "./GradeModel";
|
|
5
|
+
import { NamespaceOptions } from "./options/NamespaceOptions";
|
|
6
|
+
export default class Namespace extends CdkResource {
|
|
7
|
+
private readonly stack;
|
|
8
|
+
private readonly name;
|
|
9
|
+
private readonly description;
|
|
10
|
+
private readonly transactionSetting;
|
|
11
|
+
private readonly changeGradeScript;
|
|
12
|
+
private readonly logSetting;
|
|
13
|
+
constructor(stack: Stack, name: string, options?: NamespaceOptions | null);
|
|
14
|
+
alternateKeys(): string;
|
|
15
|
+
resourceType(): string;
|
|
16
|
+
properties(): {
|
|
17
|
+
[name: string]: any;
|
|
18
|
+
};
|
|
19
|
+
ref(): NamespaceRef;
|
|
20
|
+
getAttrNamespaceId(): GetAttr;
|
|
21
|
+
masterData(gradeModels: GradeModel[]): Namespace;
|
|
22
|
+
}
|
|
@@ -0,0 +1,77 @@
|
|
|
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
|
+
const tslib_1 = require("tslib");
|
|
19
|
+
const model_1 = require("../../core/model");
|
|
20
|
+
const func_1 = require("../../core/func");
|
|
21
|
+
const NamespaceRef_1 = tslib_1.__importDefault(require("../ref/NamespaceRef"));
|
|
22
|
+
const CurrentMasterData_1 = tslib_1.__importDefault(require("./CurrentMasterData"));
|
|
23
|
+
class Namespace extends model_1.CdkResource {
|
|
24
|
+
constructor(stack, name, options = null) {
|
|
25
|
+
var _a, _b, _c, _d;
|
|
26
|
+
super("Grade_Namespace_" + name);
|
|
27
|
+
this.description = null;
|
|
28
|
+
this.transactionSetting = null;
|
|
29
|
+
this.changeGradeScript = null;
|
|
30
|
+
this.logSetting = null;
|
|
31
|
+
this.stack = stack;
|
|
32
|
+
this.name = name;
|
|
33
|
+
this.description = (_a = options === null || options === void 0 ? void 0 : options.description) !== null && _a !== void 0 ? _a : null;
|
|
34
|
+
this.transactionSetting = (_b = options === null || options === void 0 ? void 0 : options.transactionSetting) !== null && _b !== void 0 ? _b : null;
|
|
35
|
+
this.changeGradeScript = (_c = options === null || options === void 0 ? void 0 : options.changeGradeScript) !== null && _c !== void 0 ? _c : null;
|
|
36
|
+
this.logSetting = (_d = options === null || options === void 0 ? void 0 : options.logSetting) !== null && _d !== void 0 ? _d : null;
|
|
37
|
+
stack.addResource(this);
|
|
38
|
+
}
|
|
39
|
+
alternateKeys() {
|
|
40
|
+
return "name";
|
|
41
|
+
}
|
|
42
|
+
resourceType() {
|
|
43
|
+
return "GS2::Grade::Namespace";
|
|
44
|
+
}
|
|
45
|
+
properties() {
|
|
46
|
+
var _a, _b, _c;
|
|
47
|
+
let properties = {};
|
|
48
|
+
if (this.name != null) {
|
|
49
|
+
properties["Name"] = this.name;
|
|
50
|
+
}
|
|
51
|
+
if (this.description != null) {
|
|
52
|
+
properties["Description"] = this.description;
|
|
53
|
+
}
|
|
54
|
+
if (this.transactionSetting != null) {
|
|
55
|
+
properties["TransactionSetting"] = (_a = this.transactionSetting) === null || _a === void 0 ? void 0 : _a.properties();
|
|
56
|
+
}
|
|
57
|
+
if (this.changeGradeScript != null) {
|
|
58
|
+
properties["ChangeGradeScript"] = (_b = this.changeGradeScript) === null || _b === void 0 ? void 0 : _b.properties();
|
|
59
|
+
}
|
|
60
|
+
if (this.logSetting != null) {
|
|
61
|
+
properties["LogSetting"] = (_c = this.logSetting) === null || _c === void 0 ? void 0 : _c.properties();
|
|
62
|
+
}
|
|
63
|
+
return properties;
|
|
64
|
+
}
|
|
65
|
+
ref() {
|
|
66
|
+
return new NamespaceRef_1.default(this.name);
|
|
67
|
+
}
|
|
68
|
+
getAttrNamespaceId() {
|
|
69
|
+
return new func_1.GetAttr(this, "Item.NamespaceId", null);
|
|
70
|
+
}
|
|
71
|
+
masterData(gradeModels) {
|
|
72
|
+
new CurrentMasterData_1.default(this.stack, this.name, gradeModels).addDependsOn(this);
|
|
73
|
+
return this;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
exports.default = Namespace;
|
|
77
|
+
//# sourceMappingURL=Namespace.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Namespace.js","sourceRoot":"","sources":["Namespace.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;AAEH,4CAAoD;AACpD,0CAAwC;AAKxC,+EAA+C;AAC/C,oFAAoD;AAKpD,MAAqB,SAAU,SAAQ,mBAAW;IAQ9C,YACI,KAAY,EACZ,IAAY,EACZ,UAAiC,IAAI;;QAErC,KAAK,CACD,kBAAkB,GAAG,IAAI,CAC5B,CAAC;QAZW,gBAAW,GAAgB,IAAI,CAAC;QAChC,uBAAkB,GAA4B,IAAI,CAAC;QACnD,sBAAiB,GAAuB,IAAI,CAAC;QAC7C,eAAU,GAAoB,IAAI,CAAC;QAWhD,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACnB,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,WAAW,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,WAAW,mCAAI,IAAI,CAAC;QAChD,IAAI,CAAC,kBAAkB,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,kBAAkB,mCAAI,IAAI,CAAC;QAC9D,IAAI,CAAC,iBAAiB,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,iBAAiB,mCAAI,IAAI,CAAC;QAC5D,IAAI,CAAC,UAAU,GAAG,MAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,UAAU,mCAAI,IAAI,CAAC;QAC9C,KAAK,CAAC,WAAW,CACb,IAAI,CACP,CAAC;IACN,CAAC;IAGM,aAAa;QAEhB,OAAO,MAAM,CAAC;IAClB,CAAC;IAEM,YAAY;QAEf,OAAO,uBAAuB,CAAC;IACnC,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,WAAW,IAAI,IAAI,EAAE;YAC1B,UAAU,CAAC,aAAa,CAAC,GAAG,IAAI,CAAC,WAAW,CAAC;SAChD;QACD,IAAI,IAAI,CAAC,kBAAkB,IAAI,IAAI,EAAE;YACjC,UAAU,CAAC,oBAAoB,CAAC,GAAG,MAAA,IAAI,CAAC,kBAAkB,0CAAE,UAAU,EACrE,CAAC;SACL;QACD,IAAI,IAAI,CAAC,iBAAiB,IAAI,IAAI,EAAE;YAChC,UAAU,CAAC,mBAAmB,CAAC,GAAG,MAAA,IAAI,CAAC,iBAAiB,0CAAE,UAAU,EACnE,CAAC;SACL;QACD,IAAI,IAAI,CAAC,UAAU,IAAI,IAAI,EAAE;YACzB,UAAU,CAAC,YAAY,CAAC,GAAG,MAAA,IAAI,CAAC,UAAU,0CAAE,UAAU,EACrD,CAAC;SACL;QAED,OAAO,UAAU,CAAC;IACtB,CAAC;IAEM,GAAG;QAEN,OAAO,IAAI,sBAAY,CACnB,IAAI,CAAC,IAAK,CACb,CAAC;IACN,CAAC;IAEM,kBAAkB;QAErB,OAAO,IAAI,cAAO,CACd,IAAI,EACJ,kBAAkB,EAClB,IAAI,CACP,CAAC;IACN,CAAC;IAEM,UAAU,CACb,WAAyB;QAEzB,IAAI,2BAAiB,CACjB,IAAI,CAAC,KAAK,EACV,IAAI,CAAC,IAAI,EACT,WAAW,CACd,CAAC,YAAY,CACV,IAAI,CACP,CAAC;QACF,OAAO,IAAI,CAAC;IAChB,CAAC;CACJ;AA7FD,4BA6FC"}
|
|
@@ -0,0 +1,122 @@
|
|
|
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
|
+
import {CdkResource, Stack} from "../../core/model";
|
|
18
|
+
import {GetAttr} from "../../core/func";
|
|
19
|
+
import TransactionSetting from "../../core/model/TransactionSetting";
|
|
20
|
+
import ScriptSetting from "../../core/model/ScriptSetting";
|
|
21
|
+
import LogSetting from "../../core/model/LogSetting";
|
|
22
|
+
|
|
23
|
+
import NamespaceRef from "../ref/NamespaceRef";
|
|
24
|
+
import CurrentMasterData from "./CurrentMasterData";
|
|
25
|
+
import GradeModel from "./GradeModel";
|
|
26
|
+
|
|
27
|
+
import { NamespaceOptions } from "./options/NamespaceOptions";
|
|
28
|
+
|
|
29
|
+
export default class Namespace extends CdkResource {
|
|
30
|
+
private readonly stack: Stack;
|
|
31
|
+
private readonly name: string;
|
|
32
|
+
private readonly description: string|null = null;
|
|
33
|
+
private readonly transactionSetting: TransactionSetting|null = null;
|
|
34
|
+
private readonly changeGradeScript: ScriptSetting|null = null;
|
|
35
|
+
private readonly logSetting: LogSetting|null = null;
|
|
36
|
+
|
|
37
|
+
public constructor(
|
|
38
|
+
stack: Stack,
|
|
39
|
+
name: string,
|
|
40
|
+
options: NamespaceOptions|null = null,
|
|
41
|
+
) {
|
|
42
|
+
super(
|
|
43
|
+
"Grade_Namespace_" + name
|
|
44
|
+
);
|
|
45
|
+
|
|
46
|
+
this.stack = stack;
|
|
47
|
+
this.name = name;
|
|
48
|
+
this.description = options?.description ?? null;
|
|
49
|
+
this.transactionSetting = options?.transactionSetting ?? null;
|
|
50
|
+
this.changeGradeScript = options?.changeGradeScript ?? null;
|
|
51
|
+
this.logSetting = options?.logSetting ?? null;
|
|
52
|
+
stack.addResource(
|
|
53
|
+
this,
|
|
54
|
+
);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
public alternateKeys(
|
|
59
|
+
) {
|
|
60
|
+
return "name";
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
public resourceType(
|
|
64
|
+
): string {
|
|
65
|
+
return "GS2::Grade::Namespace";
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
public properties(
|
|
69
|
+
): {[name: string]: any} {
|
|
70
|
+
let properties: {[name: string]: any} = {};
|
|
71
|
+
|
|
72
|
+
if (this.name != null) {
|
|
73
|
+
properties["Name"] = this.name;
|
|
74
|
+
}
|
|
75
|
+
if (this.description != null) {
|
|
76
|
+
properties["Description"] = this.description;
|
|
77
|
+
}
|
|
78
|
+
if (this.transactionSetting != null) {
|
|
79
|
+
properties["TransactionSetting"] = this.transactionSetting?.properties(
|
|
80
|
+
);
|
|
81
|
+
}
|
|
82
|
+
if (this.changeGradeScript != null) {
|
|
83
|
+
properties["ChangeGradeScript"] = this.changeGradeScript?.properties(
|
|
84
|
+
);
|
|
85
|
+
}
|
|
86
|
+
if (this.logSetting != null) {
|
|
87
|
+
properties["LogSetting"] = this.logSetting?.properties(
|
|
88
|
+
);
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
return properties;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
public ref(
|
|
95
|
+
): NamespaceRef {
|
|
96
|
+
return new NamespaceRef(
|
|
97
|
+
this.name!,
|
|
98
|
+
);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
public getAttrNamespaceId(
|
|
102
|
+
): GetAttr {
|
|
103
|
+
return new GetAttr(
|
|
104
|
+
this,
|
|
105
|
+
"Item.NamespaceId",
|
|
106
|
+
null,
|
|
107
|
+
);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
public masterData(
|
|
111
|
+
gradeModels: GradeModel[],
|
|
112
|
+
): Namespace {
|
|
113
|
+
new CurrentMasterData(
|
|
114
|
+
this.stack,
|
|
115
|
+
this.name,
|
|
116
|
+
gradeModels,
|
|
117
|
+
).addDependsOn(
|
|
118
|
+
this,
|
|
119
|
+
);
|
|
120
|
+
return this;
|
|
121
|
+
}
|
|
122
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
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
|
+
exports.AcquireActionRateMode = void 0;
|
|
19
|
+
exports.AcquireActionRateMode = {
|
|
20
|
+
DOUBLE: "double",
|
|
21
|
+
BIG: "big",
|
|
22
|
+
};
|
|
23
|
+
//# sourceMappingURL=AcquireActionRateMode.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AcquireActionRateMode.js","sourceRoot":"","sources":["AcquireActionRateMode.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;AAIU,QAAA,qBAAqB,GAAG;IACjC,MAAM,EAAE,QAAQ;IAChB,GAAG,EAAE,KAAK;CACJ,CAAC"}
|