@ludeo/cloud-common 1.2.211 → 1.2.212
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/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/v4/events/forecast/forecast-ended.d.ts +5 -10
- package/dist/v4/events/forecast/forecast-ended.js +20 -13
- package/dist/v4/events/forecast/forecast-ended.js.map +1 -1
- package/package.json +1 -1
- package/src/v4/events/forecast/forecast-ended.ts +14 -14
|
@@ -1,20 +1,15 @@
|
|
|
1
1
|
import { LudeoEvent } from "../../../infra";
|
|
2
2
|
import { ForecastContext } from "../../contexts";
|
|
3
3
|
import { LudeoFeatures } from "../../types/predictor";
|
|
4
|
-
export declare class
|
|
4
|
+
export declare class ForecastDemandEntry {
|
|
5
|
+
location: string;
|
|
6
|
+
gameId: string;
|
|
7
|
+
majorVersion: string;
|
|
5
8
|
totalDemand: number;
|
|
6
9
|
ludeoFeatures?: LudeoFeatures;
|
|
7
10
|
}
|
|
8
|
-
export declare class ForecastEnvironment {
|
|
9
|
-
[majorVersion: string]: ForecastMajorVersion;
|
|
10
|
-
}
|
|
11
|
-
export declare class ForecastLocation {
|
|
12
|
-
[envId: string]: ForecastEnvironment;
|
|
13
|
-
}
|
|
14
11
|
export declare class ForecastEndedPayload {
|
|
15
|
-
forecasts:
|
|
16
|
-
[location: string]: ForecastLocation;
|
|
17
|
-
};
|
|
12
|
+
forecasts: ForecastDemandEntry[];
|
|
18
13
|
}
|
|
19
14
|
export declare class ForecastEnded extends LudeoEvent {
|
|
20
15
|
static readonly EVENT_NAME = "forecast.forecast-ended";
|
|
@@ -9,37 +9,44 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.ForecastEnded = exports.ForecastEndedPayload = exports.
|
|
12
|
+
exports.ForecastEnded = exports.ForecastEndedPayload = exports.ForecastDemandEntry = void 0;
|
|
13
13
|
const infra_1 = require("../../../infra");
|
|
14
14
|
const decorators_1 = require("../../../decorators");
|
|
15
15
|
const class_validator_1 = require("class-validator");
|
|
16
16
|
const contexts_1 = require("../../contexts");
|
|
17
17
|
const predictor_1 = require("../../types/predictor");
|
|
18
|
-
class
|
|
18
|
+
class ForecastDemandEntry {
|
|
19
19
|
}
|
|
20
|
-
exports.
|
|
20
|
+
exports.ForecastDemandEntry = ForecastDemandEntry;
|
|
21
|
+
__decorate([
|
|
22
|
+
(0, class_validator_1.IsString)(),
|
|
23
|
+
__metadata("design:type", String)
|
|
24
|
+
], ForecastDemandEntry.prototype, "location", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
(0, class_validator_1.IsString)(),
|
|
27
|
+
__metadata("design:type", String)
|
|
28
|
+
], ForecastDemandEntry.prototype, "gameId", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
(0, class_validator_1.IsString)(),
|
|
31
|
+
__metadata("design:type", String)
|
|
32
|
+
], ForecastDemandEntry.prototype, "majorVersion", void 0);
|
|
21
33
|
__decorate([
|
|
22
34
|
(0, class_validator_1.IsNumber)(),
|
|
23
35
|
__metadata("design:type", Number)
|
|
24
|
-
],
|
|
36
|
+
], ForecastDemandEntry.prototype, "totalDemand", void 0);
|
|
25
37
|
__decorate([
|
|
26
38
|
(0, class_validator_1.IsOptional)(),
|
|
27
39
|
(0, decorators_1.ValidateNestedType)(() => predictor_1.LudeoFeatures),
|
|
28
40
|
__metadata("design:type", predictor_1.LudeoFeatures)
|
|
29
|
-
],
|
|
30
|
-
class ForecastEnvironment {
|
|
31
|
-
}
|
|
32
|
-
exports.ForecastEnvironment = ForecastEnvironment;
|
|
33
|
-
class ForecastLocation {
|
|
34
|
-
}
|
|
35
|
-
exports.ForecastLocation = ForecastLocation;
|
|
41
|
+
], ForecastDemandEntry.prototype, "ludeoFeatures", void 0);
|
|
36
42
|
class ForecastEndedPayload {
|
|
37
43
|
}
|
|
38
44
|
exports.ForecastEndedPayload = ForecastEndedPayload;
|
|
39
45
|
__decorate([
|
|
40
46
|
(0, class_validator_1.IsDefined)(),
|
|
41
|
-
(0,
|
|
42
|
-
|
|
47
|
+
(0, class_validator_1.IsArray)(),
|
|
48
|
+
(0, decorators_1.ValidateNestedType)(() => ForecastDemandEntry),
|
|
49
|
+
__metadata("design:type", Array)
|
|
43
50
|
], ForecastEndedPayload.prototype, "forecasts", void 0);
|
|
44
51
|
class ForecastEnded extends infra_1.LudeoEvent {
|
|
45
52
|
constructor(payload, context) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"forecast-ended.js","sourceRoot":"","sources":["../../../../src/v4/events/forecast/forecast-ended.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,0CAA4C;AAC5C,oDAAyD;AACzD,
|
|
1
|
+
{"version":3,"file":"forecast-ended.js","sourceRoot":"","sources":["../../../../src/v4/events/forecast/forecast-ended.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,0CAA4C;AAC5C,oDAAyD;AACzD,qDAAqF;AACrF,6CAAiD;AACjD,qDAAsD;AAEtD,MAAa,mBAAmB;CAgB/B;AAhBD,kDAgBC;AAdG;IADC,IAAA,0BAAQ,GAAE;;qDACM;AAGjB;IADC,IAAA,0BAAQ,GAAE;;mDACI;AAGf;IADC,IAAA,0BAAQ,GAAE;;yDACU;AAGrB;IADC,IAAA,0BAAQ,GAAE;;wDACS;AAIpB;IAFC,IAAA,4BAAU,GAAE;IACZ,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,yBAAa,CAAC;8BACxB,yBAAa;0DAAC;AAGlC,MAAa,oBAAoB;CAKhC;AALD,oDAKC;AADG;IAHC,IAAA,2BAAS,GAAE;IACX,IAAA,yBAAO,GAAE;IACT,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,mBAAmB,CAAC;;uDACb;AAGrC,MAAa,aAAc,SAAQ,kBAAU;IAGzC,YAAY,OAA6B,EAAE,OAAwB;QAC/D,KAAK,CAAC,aAAa,CAAC,UAAU,CAAC,CAAC;QAChC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IAC3B,CAAC;;AAPL,sCAcC;AAbmB,wBAAU,GAAG,yBAAyB,CAAC;AASvD;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,oBAAoB,CAAC;8BACtC,oBAAoB;8CAAC;AAG9B;IADC,IAAA,+BAAkB,EAAC,GAAG,EAAE,CAAC,0BAAe,CAAC;8BACjC,0BAAe;8CAAC"}
|
package/package.json
CHANGED
|
@@ -1,10 +1,19 @@
|
|
|
1
1
|
import { LudeoEvent } from "../../../infra";
|
|
2
2
|
import { ValidateNestedType } from "../../../decorators";
|
|
3
|
-
import { IsDefined, IsNumber, IsOptional } from "class-validator";
|
|
3
|
+
import { IsArray, IsDefined, IsNumber, IsOptional, IsString } from "class-validator";
|
|
4
4
|
import { ForecastContext } from "../../contexts";
|
|
5
5
|
import { LudeoFeatures } from "../../types/predictor";
|
|
6
6
|
|
|
7
|
-
export class
|
|
7
|
+
export class ForecastDemandEntry {
|
|
8
|
+
@IsString()
|
|
9
|
+
location: string;
|
|
10
|
+
|
|
11
|
+
@IsString()
|
|
12
|
+
gameId: string;
|
|
13
|
+
|
|
14
|
+
@IsString()
|
|
15
|
+
majorVersion: string;
|
|
16
|
+
|
|
8
17
|
@IsNumber()
|
|
9
18
|
totalDemand: number;
|
|
10
19
|
|
|
@@ -13,20 +22,11 @@ export class ForecastMajorVersion {
|
|
|
13
22
|
ludeoFeatures?: LudeoFeatures;
|
|
14
23
|
}
|
|
15
24
|
|
|
16
|
-
export class ForecastEnvironment {
|
|
17
|
-
[majorVersion: string]: ForecastMajorVersion;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export class ForecastLocation {
|
|
21
|
-
[envId: string]: ForecastEnvironment;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
25
|
export class ForecastEndedPayload {
|
|
25
26
|
@IsDefined()
|
|
26
|
-
@
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
};
|
|
27
|
+
@IsArray()
|
|
28
|
+
@ValidateNestedType(() => ForecastDemandEntry)
|
|
29
|
+
forecasts: ForecastDemandEntry[];
|
|
30
30
|
}
|
|
31
31
|
|
|
32
32
|
export class ForecastEnded extends LudeoEvent {
|