@kosdev-code/kos-freestyle-sdk 2.0.2
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/extension-utils-D_CXSnlW.cjs +2 -0
- package/extension-utils-D_CXSnlW.cjs.map +1 -0
- package/extension-utils-uYGl3TGm.js +201 -0
- package/extension-utils-uYGl3TGm.js.map +1 -0
- package/freestyle-registration-manager-pbtzJUqS.js +765 -0
- package/freestyle-registration-manager-pbtzJUqS.js.map +1 -0
- package/freestyle-registration-manager-yxRMbjlE.cjs +2 -0
- package/freestyle-registration-manager-yxRMbjlE.cjs.map +1 -0
- package/index.cjs +2 -0
- package/index.cjs.map +1 -0
- package/index.d.ts +3 -0
- package/index.d.ts.map +1 -0
- package/index.js +33 -0
- package/index.js.map +1 -0
- package/models/constants/index.d.ts +2 -0
- package/models/constants/index.d.ts.map +1 -0
- package/models/index.d.ts +6 -0
- package/models/index.d.ts.map +1 -0
- package/models/models/agitation-required-trouble/agitation-required-trouble-model.d.ts +23 -0
- package/models/models/agitation-required-trouble/agitation-required-trouble-model.d.ts.map +1 -0
- package/models/models/agitation-required-trouble/agitation-required-trouble-registration.d.ts +87 -0
- package/models/models/agitation-required-trouble/agitation-required-trouble-registration.d.ts.map +1 -0
- package/models/models/agitation-required-trouble/index.d.ts +4 -0
- package/models/models/agitation-required-trouble/index.d.ts.map +1 -0
- package/models/models/agitation-required-trouble/types/index.d.ts +8 -0
- package/models/models/carb-agitator/carb-agitator-model.d.ts +14 -0
- package/models/models/carb-agitator/carb-agitator-model.d.ts.map +1 -0
- package/models/models/carb-agitator/carb-agitator-registration.d.ts +84 -0
- package/models/models/carb-agitator/carb-agitator-registration.d.ts.map +1 -0
- package/models/models/carb-agitator/index.d.ts +3 -0
- package/models/models/carb-agitator/index.d.ts.map +1 -0
- package/models/models/carb-agitator/types/index.d.ts +14 -0
- package/models/models/cartridge-agitator/cartridge-agitator-container-model.d.ts +20 -0
- package/models/models/cartridge-agitator/cartridge-agitator-container-model.d.ts.map +1 -0
- package/models/models/cartridge-agitator/cartridge-agitator-container-registration.d.ts +87 -0
- package/models/models/cartridge-agitator/cartridge-agitator-container-registration.d.ts.map +1 -0
- package/models/models/cartridge-agitator/cartridge-agitator-model.d.ts +27 -0
- package/models/models/cartridge-agitator/cartridge-agitator-model.d.ts.map +1 -0
- package/models/models/cartridge-agitator/cartridge-agitator-registration.d.ts +87 -0
- package/models/models/cartridge-agitator/cartridge-agitator-registration.d.ts.map +1 -0
- package/models/models/cartridge-agitator/index.d.ts +6 -0
- package/models/models/cartridge-agitator/index.d.ts.map +1 -0
- package/models/models/cartridge-agitator/services/cartridge-agitator-services.d.ts +8 -0
- package/models/models/cartridge-agitator/services/cartridge-agitator-services.d.ts.map +1 -0
- package/models/models/cartridge-agitator/types/index.d.ts +14 -0
- package/models/models/freestyle-assembly/freestyle-assembly-model.d.ts +38 -0
- package/models/models/freestyle-assembly/freestyle-assembly-model.d.ts.map +1 -0
- package/models/models/freestyle-assembly/freestyle-assembly-registration.d.ts +89 -0
- package/models/models/freestyle-assembly/freestyle-assembly-registration.d.ts.map +1 -0
- package/models/models/freestyle-assembly/index.d.ts +4 -0
- package/models/models/freestyle-assembly/index.d.ts.map +1 -0
- package/models/models/freestyle-assembly/types/index.d.ts +8 -0
- package/models/models/freestyle-holder/freestyle-holder-model.d.ts +19 -0
- package/models/models/freestyle-holder/freestyle-holder-model.d.ts.map +1 -0
- package/models/models/freestyle-holder/freestyle-holder-registration.d.ts +87 -0
- package/models/models/freestyle-holder/freestyle-holder-registration.d.ts.map +1 -0
- package/models/models/freestyle-holder/index.d.ts +4 -0
- package/models/models/freestyle-holder/index.d.ts.map +1 -0
- package/models/models/freestyle-holder/types/index.d.ts +8 -0
- package/models/models/freestyle-nozzle/freestyle-nozzle-model.d.ts +21 -0
- package/models/models/freestyle-nozzle/freestyle-nozzle-model.d.ts.map +1 -0
- package/models/models/freestyle-nozzle/freestyle-nozzle-registration.d.ts +87 -0
- package/models/models/freestyle-nozzle/freestyle-nozzle-registration.d.ts.map +1 -0
- package/models/models/freestyle-nozzle/index.d.ts +5 -0
- package/models/models/freestyle-nozzle/index.d.ts.map +1 -0
- package/models/models/freestyle-nozzle/services/freestyle-nozzle-services.d.ts +32 -0
- package/models/models/freestyle-nozzle/services/freestyle-nozzle-services.d.ts.map +1 -0
- package/models/models/freestyle-nozzle/services/index.d.ts +2 -0
- package/models/models/freestyle-nozzle/services/index.d.ts.map +1 -0
- package/models/models/freestyle-nozzle/types/index.d.ts +8 -0
- package/models/models/freestyle-pump/freestyle-pump-model.d.ts +14 -0
- package/models/models/freestyle-pump/freestyle-pump-model.d.ts.map +1 -0
- package/models/models/freestyle-pump/freestyle-pump-registration.d.ts +87 -0
- package/models/models/freestyle-pump/freestyle-pump-registration.d.ts.map +1 -0
- package/models/models/freestyle-pump/index.d.ts +5 -0
- package/models/models/freestyle-pump/index.d.ts.map +1 -0
- package/models/models/freestyle-pump/services/freestyle-pump-services.d.ts +10 -0
- package/models/models/freestyle-pump/services/freestyle-pump-services.d.ts.map +1 -0
- package/models/models/freestyle-pump/services/index.d.ts +2 -0
- package/models/models/freestyle-pump/services/index.d.ts.map +1 -0
- package/models/models/freestyle-pump/types/index.d.ts +5 -0
- package/models/models/ice-agitator/ice-agitator-model.d.ts +28 -0
- package/models/models/ice-agitator/ice-agitator-model.d.ts.map +1 -0
- package/models/models/ice-agitator/ice-agitator-registration.d.ts +84 -0
- package/models/models/ice-agitator/ice-agitator-registration.d.ts.map +1 -0
- package/models/models/ice-agitator/index.d.ts +3 -0
- package/models/models/ice-agitator/index.d.ts.map +1 -0
- package/models/models/ice-agitator/services/ice-agitator-services.d.ts +8 -0
- package/models/models/ice-agitator/services/ice-agitator-services.d.ts.map +1 -0
- package/models/models/ice-agitator/services/index.d.ts +2 -0
- package/models/models/ice-agitator/services/index.d.ts.map +1 -0
- package/models/models/ice-agitator/types/index.d.ts +28 -0
- package/models/models/index.d.ts +11 -0
- package/models/models/index.d.ts.map +1 -0
- package/models/models/types/assembly.d.ts +16 -0
- package/models/models/types/assembly.d.ts.map +1 -0
- package/models/models/types/ingredients.d.ts +33 -0
- package/models/models/types/ingredients.d.ts.map +1 -0
- package/models/models/types/pumps.d.ts +6 -0
- package/models/models/types/pumps.d.ts.map +1 -0
- package/models/utils/extension-utils.d.ts +37 -0
- package/models/utils/extension-utils.d.ts.map +1 -0
- package/models/utils/extensions/assembly/assembly-data-mapper.d.ts +19 -0
- package/models/utils/extensions/assembly/assembly-data-mapper.d.ts.map +1 -0
- package/models/utils/extensions/assembly/types.d.ts +130 -0
- package/models/utils/extensions/assembly/types.d.ts.map +1 -0
- package/models/utils/extensions/availability/freestyle-loader.d.ts +31 -0
- package/models/utils/extensions/availability/freestyle-loader.d.ts.map +1 -0
- package/models/utils/extensions/availability/freestyle-mapper.d.ts +14 -0
- package/models/utils/extensions/availability/freestyle-mapper.d.ts.map +1 -0
- package/models/utils/extensions/availability/middleware/assets.d.ts +10 -0
- package/models/utils/extensions/availability/middleware/assets.d.ts.map +1 -0
- package/models/utils/extensions/availability/middleware/beverage-screen.d.ts +14 -0
- package/models/utils/extensions/availability/middleware/beverage-screen.d.ts.map +1 -0
- package/models/utils/extensions/availability/middleware/beverages.d.ts +10 -0
- package/models/utils/extensions/availability/middleware/beverages.d.ts.map +1 -0
- package/models/utils/extensions/availability/middleware/brand-screen.d.ts +5 -0
- package/models/utils/extensions/availability/middleware/brand-screen.d.ts.map +1 -0
- package/models/utils/extensions/availability/middleware/brands.d.ts +10 -0
- package/models/utils/extensions/availability/middleware/brands.d.ts.map +1 -0
- package/models/utils/extensions/availability/middleware/copy-input.d.ts +4 -0
- package/models/utils/extensions/availability/middleware/copy-input.d.ts.map +1 -0
- package/models/utils/extensions/availability/middleware/flavors.d.ts +10 -0
- package/models/utils/extensions/availability/middleware/flavors.d.ts.map +1 -0
- package/models/utils/extensions/availability/middleware/nutrition.d.ts +10 -0
- package/models/utils/extensions/availability/middleware/nutrition.d.ts.map +1 -0
- package/models/utils/extensions/availability/middleware/related-brands.d.ts +14 -0
- package/models/utils/extensions/availability/middleware/related-brands.d.ts.map +1 -0
- package/models/utils/extensions/availability/types.d.ts +251 -0
- package/models/utils/extensions/availability/types.d.ts.map +1 -0
- package/models/utils/extensions/availability/util/locate-brand.d.ts +2 -0
- package/models/utils/extensions/availability/util/locate-brand.d.ts.map +1 -0
- package/models/utils/extensions/availability/util/process-related-brand.d.ts +4 -0
- package/models/utils/extensions/availability/util/process-related-brand.d.ts.map +1 -0
- package/models/utils/extensions/ingredient/index.d.ts +2 -0
- package/models/utils/extensions/ingredient/index.d.ts.map +1 -0
- package/models/utils/extensions/ingredient/model-extension.d.ts +7 -0
- package/models/utils/extensions/ingredient/model-extension.d.ts.map +1 -0
- package/models/utils/extensions/pourable/select-pourable-mapper.d.ts +6 -0
- package/models/utils/extensions/pourable/select-pourable-mapper.d.ts.map +1 -0
- package/models/utils/freestyle-registration-manager.d.ts +39 -0
- package/models/utils/freestyle-registration-manager.d.ts.map +1 -0
- package/models/utils/index.d.ts +5 -0
- package/models/utils/index.d.ts.map +1 -0
- package/models.cjs +2 -0
- package/models.cjs.map +1 -0
- package/models.d.ts +1 -0
- package/models.js +25 -0
- package/models.js.map +1 -0
- package/package.json +37 -0
- package/ui/contexts/index.d.ts +2 -0
- package/ui/contexts/index.d.ts.map +1 -0
- package/ui/hooks/freestyle-assembly/index.d.ts +2 -0
- package/ui/hooks/freestyle-assembly/index.d.ts.map +1 -0
- package/ui/hooks/freestyle-assembly/use-freestyle-assembly.d.ts +4 -0
- package/ui/hooks/freestyle-assembly/use-freestyle-assembly.d.ts.map +1 -0
- package/ui/hooks/freestyle-nozzle/index.d.ts +2 -0
- package/ui/hooks/freestyle-nozzle/index.d.ts.map +1 -0
- package/ui/hooks/freestyle-nozzle/use-freestyle-nozzle.d.ts +4 -0
- package/ui/hooks/freestyle-nozzle/use-freestyle-nozzle.d.ts.map +1 -0
- package/ui/hooks/ice-agitator/index.d.ts +3 -0
- package/ui/hooks/ice-agitator/index.d.ts.map +1 -0
- package/ui/hooks/ice-agitator/use-ice-agitator.d.ts +14 -0
- package/ui/hooks/ice-agitator/use-ice-agitator.d.ts.map +1 -0
- package/ui/hooks/ice-agitator/with-ice-agitator.d.ts +7 -0
- package/ui/hooks/ice-agitator/with-ice-agitator.d.ts.map +1 -0
- package/ui/hooks/index.d.ts +5 -0
- package/ui/hooks/index.d.ts.map +1 -0
- package/ui/hooks/nutrition/index.d.ts +2 -0
- package/ui/hooks/nutrition/index.d.ts.map +1 -0
- package/ui/hooks/nutrition/use-nutrition-info.d.ts +4 -0
- package/ui/hooks/nutrition/use-nutrition-info.d.ts.map +1 -0
- package/ui/index.d.ts +3 -0
- package/ui/index.d.ts.map +1 -0
- package/ui.cjs +2 -0
- package/ui.cjs.map +1 -0
- package/ui.d.ts +1 -0
- package/ui.js +14 -0
- package/ui.js.map +1 -0
- package/use-nutrition-info-CGrmEGIR.cjs +2 -0
- package/use-nutrition-info-CGrmEGIR.cjs.map +1 -0
- package/use-nutrition-info-D-wbfIlj.js +52 -0
- package/use-nutrition-info-D-wbfIlj.js.map +1 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { AgitationRequiredTroubleOptions } from './types';
|
|
2
|
+
import { DeferAware, FutureResponse, IKosDataModel, IKosIdentifiable, KosConfigProperty, KosCreationContext, PublicModelInterface, ResolveAware, TroubleModel } from '@kosdev-code/kos-ui-sdk';
|
|
3
|
+
import { HolderModel } from '@kosdev-code/kos-dispense-sdk';
|
|
4
|
+
|
|
5
|
+
export declare const MODEL_TYPE = "agitation-required-trouble-model";
|
|
6
|
+
export type AgitationRequiredTroubleModel = PublicModelInterface<AgitationRequiredTroubleModelImpl>;
|
|
7
|
+
export declare const agitationModelFactory: (troubleModel: TroubleModel) => "agitation-required-trouble-model" | undefined;
|
|
8
|
+
export declare const AGITATION_REQUIRED_TROUBLE = "InsufficientAgitationTrouble";
|
|
9
|
+
export declare class AgitationRequiredTroubleModelImpl implements IKosDataModel, IKosIdentifiable, ResolveAware, DeferAware {
|
|
10
|
+
id: string;
|
|
11
|
+
private logger;
|
|
12
|
+
private trouble;
|
|
13
|
+
private _deferred;
|
|
14
|
+
agitateBeforePour: KosConfigProperty<boolean>;
|
|
15
|
+
constructor(modelId: string, options: AgitationRequiredTroubleOptions, context: KosCreationContext);
|
|
16
|
+
resolve(): Promise<FutureResponse | undefined>;
|
|
17
|
+
get holder(): HolderModel<any>;
|
|
18
|
+
get shouldDefer(): boolean;
|
|
19
|
+
get deferred(): boolean;
|
|
20
|
+
defer(): void;
|
|
21
|
+
clearDefer(): void;
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=agitation-required-trouble-model.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agitation-required-trouble-model.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/agitation-required-trouble/agitation-required-trouble-model.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EAEZ,MAAM,+BAA+B,CAAC;AACvC,OAAO,KAAK,EACV,UAAU,EACV,cAAc,EACd,aAAa,EACb,gBAAgB,EAChB,iBAAiB,EAEjB,kBAAkB,EAClB,oBAAoB,EACpB,YAAY,EACZ,YAAY,EACb,MAAM,yBAAyB,CAAC;AAMjC,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,SAAS,CAAC;AAE/D,eAAO,MAAM,UAAU,qCAAqC,CAAC;AAE7D,MAAM,MAAM,6BAA6B,GACvC,oBAAoB,CAAC,iCAAiC,CAAC,CAAC;AAE1D,eAAO,MAAM,qBAAqB,iBAAkB,YAAY,mDAK/D,CAAC;AAEF,eAAO,MAAM,0BAA0B,iCAAiC,CAAC;AACzE,qBACa,iCACX,YAAW,aAAa,EAAE,gBAAgB,EAAE,YAAY,EAAE,UAAU;IAEpE,EAAE,EAAE,MAAM,CAAC;IACX,OAAO,CAAC,MAAM,CAAmB;IACjC,OAAO,CAAC,OAAO,CAAkC;IACjD,OAAO,CAAC,SAAS,CAAU;IAM3B,iBAAiB,EAAG,iBAAiB,CAAC,OAAO,CAAC,CAAC;gBAG7C,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,+BAA+B,EACxC,OAAO,EAAE,kBAAkB;IAOvB,OAAO,IAAI,OAAO,CAAC,cAAc,GAAG,SAAS,CAAC;IAKpD,IAAI,MAAM,qBAIT;IAED,IAAI,WAAW,YAMd;IAED,IAAI,QAAQ,YAEX;IACD,KAAK;IAIL,UAAU;CAGX"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { AgitationRequiredTroubleOptions } from './types';
|
|
2
|
+
import { AgitationRequiredTroubleModel } from './agitation-required-trouble-model';
|
|
3
|
+
import { KosModelRegistrationFactory } from '@kosdev-code/kos-ui-sdk';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* # AgitationRequiredTrouble
|
|
7
|
+
*
|
|
8
|
+
* The registration bean includes convenience methods for creating and working with AgitationRequiredTroubleModel instances.
|
|
9
|
+
*
|
|
10
|
+
* ## type
|
|
11
|
+
* The type property is a string that identifies the model type.
|
|
12
|
+
* The type is used to identify the model type in the model registry and to narrow down the model type in type predicates. It's most frequently
|
|
13
|
+
* used when declaring dependencies on models.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```typescript
|
|
17
|
+
*
|
|
18
|
+
* @kosDependency({modelType: AgitationRequiredTrouble.type, id: "agitationRequiredTroubleId"})
|
|
19
|
+
* private agitationRequiredTroubleModel: AgitationRequiredTroubleModel;
|
|
20
|
+
* ```
|
|
21
|
+
*
|
|
22
|
+
*
|
|
23
|
+
* ## factory
|
|
24
|
+
*
|
|
25
|
+
* The factory method creates a factory function that can be used to create new AgitationRequiredTroubleModel instances.
|
|
26
|
+
*
|
|
27
|
+
|
|
28
|
+
* The factory function is a curried function that takes the model id as the first argument and the options as the second argument.
|
|
29
|
+
*
|
|
30
|
+
* If a model with the specified id already exists, the factory function will return the existing model. The options will be ignored
|
|
31
|
+
* in this case and the existing model will be returned in its current state.
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```typescript
|
|
35
|
+
* const model = AgitationRequiredTrouble.factory("agitationRequiredTroubleId")({
|
|
36
|
+
* // Add option data
|
|
37
|
+
* });
|
|
38
|
+
* ```
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
*
|
|
42
|
+
* ## predicate
|
|
43
|
+
*
|
|
44
|
+
* [Typescript type predicate](https://www.typescriptlang.org/docs/handbook/2/narrowing.html#using-type-predicates) function that will identify and narrow down a model to a AgitationRequiredTroubleModel.
|
|
45
|
+
*
|
|
46
|
+
* @example
|
|
47
|
+
* ```typescript
|
|
48
|
+
*
|
|
49
|
+
* const model: IKosDataModel = ...; // some model
|
|
50
|
+
*
|
|
51
|
+
* if (AgitationRequiredTrouble.predicate(model)) {
|
|
52
|
+
* // if the function evaluates to true, the model is narrowed down to AgitationRequiredTroubleModel
|
|
53
|
+
* // and the compiler will know that the model has the AgitationRequiredTroubleModel interface
|
|
54
|
+
* model.updateAvailability(false);
|
|
55
|
+
* }
|
|
56
|
+
* ```
|
|
57
|
+
*
|
|
58
|
+
* ## registration
|
|
59
|
+
*
|
|
60
|
+
* The registration property is an object that can be used to simplify registration of the model with the model registry. The registration object
|
|
61
|
+
* can be spread into the model registration and provides all of the required information to register the model implementation class against the model type.
|
|
62
|
+
*
|
|
63
|
+
*
|
|
64
|
+
* @example
|
|
65
|
+
*
|
|
66
|
+
* In an application registration file you can declare the model registration as follows:
|
|
67
|
+
*
|
|
68
|
+
* **registration.ts**
|
|
69
|
+
* ```typescript
|
|
70
|
+
* import { AgitationRequiredTrouble } from "@kos-ui/project-models";
|
|
71
|
+
* import { KosModelRegistry } from "@kosdev-code/kos-dispense-sdk";
|
|
72
|
+
*
|
|
73
|
+
* import { initKosProvider } from "@kosdev-code/kos-ui-sdk";
|
|
74
|
+
*
|
|
75
|
+
* KosModelRegistry.dispense
|
|
76
|
+
* .models()
|
|
77
|
+
* .model(AgitationRequiredTrouble);
|
|
78
|
+
* ```
|
|
79
|
+
*
|
|
80
|
+
* ## registration.singleton
|
|
81
|
+
|
|
82
|
+
* The agitationRequiredTrouble model is NOT a singleton model. This means that each time the factory function is called with a unique ID, a new model instance will be created.
|
|
83
|
+
* If the factory function is called with an ID that already exists, the existing model will be returned.
|
|
84
|
+
|
|
85
|
+
* */
|
|
86
|
+
export declare const AgitationRequiredTrouble: KosModelRegistrationFactory<AgitationRequiredTroubleModel, AgitationRequiredTroubleOptions>;
|
|
87
|
+
//# sourceMappingURL=agitation-required-trouble-registration.d.ts.map
|
package/models/models/agitation-required-trouble/agitation-required-trouble-registration.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agitation-required-trouble-registration.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/agitation-required-trouble/agitation-required-trouble-registration.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,yBAAyB,CAAC;AACtE,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,oCAAoC,CAAC;AAKxF,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,SAAS,CAAC;AAE/D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAgFK;AACL,eAAO,MAAM,wBAAwB,6FAMnC,CAAC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { AGITATION_REQUIRED_TROUBLE, type AgitationRequiredTroubleModel, } from './agitation-required-trouble-model';
|
|
2
|
+
export { AgitationRequiredTrouble } from './agitation-required-trouble-registration';
|
|
3
|
+
export type * from './types';
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/agitation-required-trouble/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,0BAA0B,EAC1B,KAAK,6BAA6B,GACnC,MAAM,oCAAoC,CAAC;AAC5C,OAAO,EAAE,wBAAwB,EAAE,MAAM,2CAA2C,CAAC;AACrF,mBAAmB,SAAS,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { IKosCompanionOptions, TroubleModel, TroubleOptions } from '@kosdev-code/kos-ui-sdk';
|
|
2
|
+
import { HolderTroubleData } from '@kosdev-code/kos-dispense-sdk';
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
export type AgitationRequiredTroubleOptions = IKosCompanionOptions<
|
|
6
|
+
TroubleModel<HolderTroubleData>,
|
|
7
|
+
TroubleOptions
|
|
8
|
+
>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { CarbAgitatorModel, CarbAgitatorOptions } from './types';
|
|
2
|
+
import { IKosDataModel, KosCreationContext } from '@kosdev-code/kos-ui-sdk';
|
|
3
|
+
|
|
4
|
+
export declare const MODEL_TYPE = "carb-agitator-model";
|
|
5
|
+
export declare class CarbAgitatorModelImpl implements CarbAgitatorModel, IKosDataModel {
|
|
6
|
+
id: string;
|
|
7
|
+
name: string;
|
|
8
|
+
path: string;
|
|
9
|
+
private logger;
|
|
10
|
+
constructor(modelId: string, options: CarbAgitatorOptions, context: KosCreationContext);
|
|
11
|
+
init(): Promise<void>;
|
|
12
|
+
load(): Promise<void>;
|
|
13
|
+
}
|
|
14
|
+
//# sourceMappingURL=carb-agitator-model.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"carb-agitator-model.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/carb-agitator/carb-agitator-model.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EAEb,kBAAkB,EACnB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,KAAK,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAEtE,eAAO,MAAM,UAAU,wBAAwB,CAAC;AAEhD,qBACa,qBAAsB,YAAW,iBAAiB,EAAE,aAAa;IAC5E,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IAEb,OAAO,CAAC,MAAM,CAAmB;gBAE/B,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,mBAAmB,EAC5B,OAAO,EAAE,kBAAkB;IAavB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAIrB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAG5B"}
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import { CarbAgitatorModel, CarbAgitatorOptions } from './types';
|
|
2
|
+
import { KosModelRegistrationFactory } from '@kosdev-code/kos-ui-sdk';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* # CarbAgitator
|
|
6
|
+
*
|
|
7
|
+
* The registration bean includes convenience methods for creating and working with CarbAgitatorModel instances.
|
|
8
|
+
*
|
|
9
|
+
* ## type
|
|
10
|
+
* The type property is a string that identifies the model type.
|
|
11
|
+
* The type is used to identify the model type in the model registry and to narrow down the model type in type predicates. It's most frequently
|
|
12
|
+
* used when declaring dependencies on models.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```typescript
|
|
16
|
+
*
|
|
17
|
+
* @kosDependency({modelType: CarbAgitator.type, id: "carbAgitatorId"})
|
|
18
|
+
* private carbAgitatorModel: CarbAgitatorModel;
|
|
19
|
+
* ```
|
|
20
|
+
*
|
|
21
|
+
*
|
|
22
|
+
* ## factory
|
|
23
|
+
*
|
|
24
|
+
* The factory method creates a factory function that can be used to create new CarbAgitatorModel instances.
|
|
25
|
+
*
|
|
26
|
+
|
|
27
|
+
* The factory function is a curried function that takes the model id as the first argument and the options as the second argument.
|
|
28
|
+
*
|
|
29
|
+
* If a model with the specified id already exists, the factory function will return the existing model. The options will be ignored
|
|
30
|
+
* in this case and the existing model will be returned in its current state.
|
|
31
|
+
*
|
|
32
|
+
* @example
|
|
33
|
+
* ```typescript
|
|
34
|
+
* const model = CarbAgitator.factory("carbAgitatorId")({
|
|
35
|
+
* // Add option data
|
|
36
|
+
* });
|
|
37
|
+
* ```
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
*
|
|
41
|
+
* ## predicate
|
|
42
|
+
*
|
|
43
|
+
* [Typescript type predicate](https://www.typescriptlang.org/docs/handbook/2/narrowing.html#using-type-predicates) function that will identify and narrow down a model to a CarbAgitatorModel.
|
|
44
|
+
*
|
|
45
|
+
* @example
|
|
46
|
+
* ```typescript
|
|
47
|
+
*
|
|
48
|
+
* const model: IKosDataModel = ...; // some model
|
|
49
|
+
*
|
|
50
|
+
* if (CarbAgitator.predicate(model)) {
|
|
51
|
+
* // if the function evaluates to true, the model is narrowed down to CarbAgitatorModel
|
|
52
|
+
* // and the compiler will know that the model has the CarbAgitatorModel interface
|
|
53
|
+
* model.updateAvailability(false);
|
|
54
|
+
* }
|
|
55
|
+
* ```
|
|
56
|
+
*
|
|
57
|
+
* ## registration
|
|
58
|
+
*
|
|
59
|
+
* The registration property is an object that can be used to simplify registration of the model with the model registry. The registration object
|
|
60
|
+
* can be spread into the model registration and provides all of the required information to register the model implementation class against the model type.
|
|
61
|
+
*
|
|
62
|
+
*
|
|
63
|
+
* @example
|
|
64
|
+
*
|
|
65
|
+
* In an application registration file you can declare the model registration as follows:
|
|
66
|
+
*
|
|
67
|
+
* **registration.ts**
|
|
68
|
+
* ```typescript
|
|
69
|
+
* import { CarbAgitator } from "@kos-ui/kos-dispenser-model";
|
|
70
|
+
* ...
|
|
71
|
+
* import { ExtensionManager, IKosRegistry } from "@kosdev-code/kos-ui-sdk";
|
|
72
|
+
* export const kosModels: IKosRegistry["models"] = {
|
|
73
|
+
* ...CarbAgitator.registration,
|
|
74
|
+
* };
|
|
75
|
+
* ```
|
|
76
|
+
*
|
|
77
|
+
* ## registration.singleton
|
|
78
|
+
|
|
79
|
+
* The carbAgitator model is NOT a singleton model. This means that each time the factory function is called with a unique ID, a new model instance will be created.
|
|
80
|
+
* If the factory function is called with an ID that already exists, the existing model will be returned.
|
|
81
|
+
|
|
82
|
+
* */
|
|
83
|
+
export declare const CarbAgitator: KosModelRegistrationFactory<CarbAgitatorModel, CarbAgitatorOptions>;
|
|
84
|
+
//# sourceMappingURL=carb-agitator-registration.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"carb-agitator-registration.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/carb-agitator/carb-agitator-registration.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,yBAAyB,CAAC;AAEtE,OAAO,KAAK,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAEtE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KA8EK;AAEL,eAAO,MAAM,YAAY,qEAMvB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/carb-agitator/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAE5D,mBAAmB,SAAS,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { IKosIdentifiable } from '@kosdev-code/kos-ui-sdk';
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
export interface CarbAgitatorOptions {
|
|
5
|
+
name: string;
|
|
6
|
+
path: string;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export interface CarbAgitatorModel extends IKosIdentifiable {
|
|
10
|
+
name: string;
|
|
11
|
+
path: string;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { CartridgeAgitatorContainerOptions } from './types';
|
|
2
|
+
import { CartridgeAgitatorModel } from './cartridge-agitator-model';
|
|
3
|
+
import { IKosDataModel, IKosIdentifiable, IKosModelContainer, IKosModelHolder, KosCreationContext, PublicModelInterface } from '@kosdev-code/kos-ui-sdk';
|
|
4
|
+
|
|
5
|
+
export declare const MODEL_TYPE = "cartridge-agitator-container-model";
|
|
6
|
+
export type CartridgeAgitatorContainerModel = PublicModelInterface<CartridgeAgitatorContainerModelImpl>;
|
|
7
|
+
export declare class CartridgeAgitatorContainerModelImpl implements IKosIdentifiable, IKosModelHolder<CartridgeAgitatorModel>, IKosDataModel {
|
|
8
|
+
id: string;
|
|
9
|
+
private logger;
|
|
10
|
+
private _models;
|
|
11
|
+
constructor(modelId: string, options: CartridgeAgitatorContainerOptions, context: KosCreationContext);
|
|
12
|
+
getModel(id: string): CartridgeAgitatorModel | undefined;
|
|
13
|
+
get models(): IKosModelContainer<CartridgeAgitatorModel>;
|
|
14
|
+
get data(): CartridgeAgitatorModel[];
|
|
15
|
+
addModel(model: CartridgeAgitatorModel): void;
|
|
16
|
+
removeModel(id: string): void;
|
|
17
|
+
init(): Promise<void>;
|
|
18
|
+
load(): Promise<void>;
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=cartridge-agitator-container-model.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cartridge-agitator-container-model.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/cartridge-agitator/cartridge-agitator-container-model.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACb,gBAAgB,EAChB,kBAAkB,EAClB,eAAe,EAEf,kBAAkB,EAClB,oBAAoB,EACrB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,4BAA4B,CAAC;AACzE,OAAO,KAAK,EAAE,iCAAiC,EAAE,MAAM,SAAS,CAAC;AAEjE,eAAO,MAAM,UAAU,uCAAuC,CAAC;AAE/D,MAAM,MAAM,+BAA+B,GACzC,oBAAoB,CAAC,mCAAmC,CAAC,CAAC;AAE5D,qBACa,mCACX,YACE,gBAAgB,EAChB,eAAe,CAAC,sBAAsB,CAAC,EACvC,aAAa;IAEf,EAAE,EAAE,MAAM,CAAC;IACX,OAAO,CAAC,MAAM,CAAmB;IACvB,OAAO,CAAC,OAAO,CAA6C;gBAEpE,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,iCAAiC,EAC1C,OAAO,EAAE,kBAAkB;IAY7B,QAAQ,CAAC,EAAE,EAAE,MAAM;IAGnB,IAAI,MAAM,+CAET;IACD,IAAI,IAAI,6BAEP;IAED,QAAQ,CAAC,KAAK,EAAE,sBAAsB;IAItC,WAAW,CAAC,EAAE,EAAE,MAAM;IAKhB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAMrB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAK5B"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { CartridgeAgitatorContainerOptions } from './types';
|
|
2
|
+
import { CartridgeAgitatorContainerModel } from './cartridge-agitator-container-model';
|
|
3
|
+
import { SingletonKosModelRegistrationFactory } from '@kosdev-code/kos-ui-sdk';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* # CartridgeAgitatorContainer
|
|
7
|
+
*
|
|
8
|
+
* The registration bean includes convenience methods for creating and working with CartridgeAgitatorContainerModel instances.
|
|
9
|
+
*
|
|
10
|
+
* ## type
|
|
11
|
+
* The type property is a string that identifies the model type.
|
|
12
|
+
* The type is used to identify the model type in the model registry and to narrow down the model type in type predicates. It's most frequently
|
|
13
|
+
* used when declaring dependencies on models.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```typescript
|
|
17
|
+
*
|
|
18
|
+
* @kosDependency({modelType: CartridgeAgitatorContainer.type, id: "cartridgeAgitatorContainerId"})
|
|
19
|
+
* private cartridgeAgitatorContainerModel: CartridgeAgitatorContainerModel;
|
|
20
|
+
* ```
|
|
21
|
+
*
|
|
22
|
+
*
|
|
23
|
+
* ## factory
|
|
24
|
+
*
|
|
25
|
+
* The factory method creates a factory function that can be used to create new CartridgeAgitatorContainerModel instances.
|
|
26
|
+
*
|
|
27
|
+
|
|
28
|
+
* As this is a singleton model, the factory function accepts the model options as its argument.
|
|
29
|
+
*
|
|
30
|
+
* If a model with the same model type already exists, the factory function will return the existing model. The options will be ignored
|
|
31
|
+
* in this case and the existing model will be returned in its current state.
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```typescript
|
|
35
|
+
* const model = CartridgeAgitatorContainer.factory({
|
|
36
|
+
* // Add option data
|
|
37
|
+
* });
|
|
38
|
+
* ```
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
*
|
|
42
|
+
* ## predicate
|
|
43
|
+
*
|
|
44
|
+
* [Typescript type predicate](https://www.typescriptlang.org/docs/handbook/2/narrowing.html#using-type-predicates) function that will identify and narrow down a model to a CartridgeAgitatorContainerModel.
|
|
45
|
+
*
|
|
46
|
+
* @example
|
|
47
|
+
* ```typescript
|
|
48
|
+
*
|
|
49
|
+
* const model: IKosDataModel = ...; // some model
|
|
50
|
+
*
|
|
51
|
+
* if (CartridgeAgitatorContainer.predicate(model)) {
|
|
52
|
+
* // if the function evaluates to true, the model is narrowed down to CartridgeAgitatorContainerModel
|
|
53
|
+
* // and the compiler will know that the model has the CartridgeAgitatorContainerModel interface
|
|
54
|
+
* model.updateAvailability(false);
|
|
55
|
+
* }
|
|
56
|
+
* ```
|
|
57
|
+
*
|
|
58
|
+
* ## registration
|
|
59
|
+
*
|
|
60
|
+
* The registration property is an object that can be used to simplify registration of the model with the model registry. The registration object
|
|
61
|
+
* can be spread into the model registration and provides all of the required information to register the model implementation class against the model type.
|
|
62
|
+
*
|
|
63
|
+
*
|
|
64
|
+
* @example
|
|
65
|
+
*
|
|
66
|
+
* In an application registration file you can declare the model registration as follows:
|
|
67
|
+
*
|
|
68
|
+
* **registration.ts**
|
|
69
|
+
* ```typescript
|
|
70
|
+
* import { CartridgeAgitatorContainer } from "@kosdev-code/kos-dispense-sdk";
|
|
71
|
+
* ...
|
|
72
|
+
* import { ExtensionManager, IKosRegistry } from "@kosdev-code/kos-ui-sdk";
|
|
73
|
+
* export const kosModels: IKosRegistry["models"] = {
|
|
74
|
+
* ...CartridgeAgitatorContainer.registration,
|
|
75
|
+
* };
|
|
76
|
+
* ```
|
|
77
|
+
*
|
|
78
|
+
* ## registration.singleton
|
|
79
|
+
|
|
80
|
+
* The cartridgeAgitatorContainer model is a singleton model. This means that each time the factory function is called , the same instance will be returned.
|
|
81
|
+
* If the model does not yet exist, it will be created passing in the provided options to initialize it.
|
|
82
|
+
*
|
|
83
|
+
* Singleton models don't require an ID as they will use the model type as their ID to guarantee uniqueness throughout the system.
|
|
84
|
+
|
|
85
|
+
* */
|
|
86
|
+
export declare const CartridgeAgitatorContainer: SingletonKosModelRegistrationFactory<CartridgeAgitatorContainerModel, CartridgeAgitatorContainerOptions>;
|
|
87
|
+
//# sourceMappingURL=cartridge-agitator-container-registration.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cartridge-agitator-container-registration.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/cartridge-agitator/cartridge-agitator-container-registration.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oCAAoC,EAAE,MAAM,yBAAyB,CAAC;AAC/E,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,sCAAsC,CAAC;AAM5F,OAAO,KAAK,EAAE,iCAAiC,EAAE,MAAM,SAAS,CAAC;AAEjE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAgFK;AACL,eAAO,MAAM,0BAA0B,0GAOnC,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { CartridgeAgitatorOptions } from './types';
|
|
2
|
+
import { FutureAwareContainer, FutureContainer, IKosDataModel, IKosIdentifiable, KosCreationContext, PublicModelInterface } from '@kosdev-code/kos-ui-sdk';
|
|
3
|
+
|
|
4
|
+
export declare const MODEL_TYPE = "cartridge-agitator-model";
|
|
5
|
+
export type CartridgeAgitatorModel = PublicModelInterface<CartridgeAgitatorModelImpl>;
|
|
6
|
+
export declare class CartridgeAgitatorEvents {
|
|
7
|
+
static TOPIC_AGITATION_STARTED: string;
|
|
8
|
+
static TOPIC_AGITATION_ENDED: string;
|
|
9
|
+
}
|
|
10
|
+
export declare class CartridgeAgitatorModelImpl implements IKosDataModel, IKosIdentifiable, FutureContainer {
|
|
11
|
+
id: string;
|
|
12
|
+
futureHandler: FutureAwareContainer<Record<string, unknown>>;
|
|
13
|
+
private logger;
|
|
14
|
+
private disposer?;
|
|
15
|
+
private agitating;
|
|
16
|
+
path: string;
|
|
17
|
+
statePath: string;
|
|
18
|
+
name: string;
|
|
19
|
+
constructor(modelId: string, options: CartridgeAgitatorOptions, context: KosCreationContext);
|
|
20
|
+
get isAgitating(): boolean;
|
|
21
|
+
get future(): import('@kosdev-code/kos-ui-sdk').IFutureModel<Record<string, unknown>> | undefined;
|
|
22
|
+
testAgitate(tracker?: string): Promise<import('@kosdev-code/kos-ui-sdk').FutureResponse>;
|
|
23
|
+
init(): Promise<void>;
|
|
24
|
+
unload(): void;
|
|
25
|
+
load(): Promise<void>;
|
|
26
|
+
}
|
|
27
|
+
//# sourceMappingURL=cartridge-agitator-model.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cartridge-agitator-model.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/cartridge-agitator/cartridge-agitator-model.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,oBAAoB,EACpB,eAAe,EACf,aAAa,EACb,gBAAgB,EAEhB,kBAAkB,EAElB,oBAAoB,EACrB,MAAM,yBAAyB,CAAC;AAWjC,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,SAAS,CAAC;AAExD,eAAO,MAAM,UAAU,6BAA6B,CAAC;AAErD,MAAM,MAAM,sBAAsB,GAChC,oBAAoB,CAAC,0BAA0B,CAAC,CAAC;AAEnD,qBAAa,uBAAuB;IAClC,MAAM,CAAC,uBAAuB,SAAuC;IACrE,MAAM,CAAC,qBAAqB,SAAqC;CAClE;AAED,qBACa,0BACX,YAAW,aAAa,EAAE,gBAAgB,EAAE,eAAe;IAE3D,EAAE,EAAE,MAAM,CAAC;IACX,aAAa,EAAE,oBAAoB,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;IAC7D,OAAO,CAAC,MAAM,CAAmB;IACjC,OAAO,CAAC,QAAQ,CAAC,CAAe;IAEhC,OAAO,CAAC,SAAS,CAAyB;IAC1C,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;gBAEX,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,wBAAwB,EACjC,OAAO,EAAE,kBAAkB;IAU7B,IAAI,WAAW,IAAI,OAAO,CAEzB;IAED,IAAI,MAAM,wFAET;IAGK,WAAW,CAAC,OAAO,CAAC,EAAE,MAAM;IAY5B,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAI3B,MAAM;IAIA,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAoB5B"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { CartridgeAgitatorOptions } from './types';
|
|
2
|
+
import { CartridgeAgitatorModel } from './cartridge-agitator-model';
|
|
3
|
+
import { KosModelRegistrationFactory } from '@kosdev-code/kos-ui-sdk';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* # CartridgeAgitator
|
|
7
|
+
*
|
|
8
|
+
* The registration bean includes convenience methods for creating and working with CartridgeAgitatorModel instances.
|
|
9
|
+
*
|
|
10
|
+
* ## type
|
|
11
|
+
* The type property is a string that identifies the model type.
|
|
12
|
+
* The type is used to identify the model type in the model registry and to narrow down the model type in type predicates. It's most frequently
|
|
13
|
+
* used when declaring dependencies on models.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```typescript
|
|
17
|
+
*
|
|
18
|
+
* @kosDependency({modelType: CartridgeAgitator.type, id: "cartridgeAgitatorId"})
|
|
19
|
+
* private cartridgeAgitatorModel: CartridgeAgitatorModel;
|
|
20
|
+
* ```
|
|
21
|
+
*
|
|
22
|
+
*
|
|
23
|
+
* ## factory
|
|
24
|
+
*
|
|
25
|
+
* The factory method creates a factory function that can be used to create new CartridgeAgitatorModel instances.
|
|
26
|
+
*
|
|
27
|
+
|
|
28
|
+
* The factory function is a curried function that takes the model id as the first argument and the options as the second argument.
|
|
29
|
+
*
|
|
30
|
+
* If a model with the specified id already exists, the factory function will return the existing model. The options will be ignored
|
|
31
|
+
* in this case and the existing model will be returned in its current state.
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```typescript
|
|
35
|
+
* const model = CartridgeAgitator.factory("cartridgeAgitatorId")({
|
|
36
|
+
* // Add option data
|
|
37
|
+
* });
|
|
38
|
+
* ```
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
*
|
|
42
|
+
* ## predicate
|
|
43
|
+
*
|
|
44
|
+
* [Typescript type predicate](https://www.typescriptlang.org/docs/handbook/2/narrowing.html#using-type-predicates) function that will identify and narrow down a model to a CartridgeAgitatorModel.
|
|
45
|
+
*
|
|
46
|
+
* @example
|
|
47
|
+
* ```typescript
|
|
48
|
+
*
|
|
49
|
+
* const model: IKosDataModel = ...; // some model
|
|
50
|
+
*
|
|
51
|
+
* if (CartridgeAgitator.predicate(model)) {
|
|
52
|
+
* // if the function evaluates to true, the model is narrowed down to CartridgeAgitatorModel
|
|
53
|
+
* // and the compiler will know that the model has the CartridgeAgitatorModel interface
|
|
54
|
+
* model.updateAvailability(false);
|
|
55
|
+
* }
|
|
56
|
+
* ```
|
|
57
|
+
*
|
|
58
|
+
* ## registration
|
|
59
|
+
*
|
|
60
|
+
* The registration property is an object that can be used to simplify registration of the model with the model registry. The registration object
|
|
61
|
+
* can be spread into the model registration and provides all of the required information to register the model implementation class against the model type.
|
|
62
|
+
*
|
|
63
|
+
*
|
|
64
|
+
* @example
|
|
65
|
+
*
|
|
66
|
+
* In an application registration file you can declare the model registration as follows:
|
|
67
|
+
*
|
|
68
|
+
* **registration.ts**
|
|
69
|
+
* ```typescript
|
|
70
|
+
* import { CartridgeAgitator } from "@kos-ui/project-models";
|
|
71
|
+
* import { KosModelRegistry } from "@kosdev-code/kos-dispense-sdk";
|
|
72
|
+
*
|
|
73
|
+
* import { initKosProvider } from "@kosdev-code/kos-ui-sdk";
|
|
74
|
+
*
|
|
75
|
+
* KosModelRegistry.dispense
|
|
76
|
+
* .models()
|
|
77
|
+
* .model(CartridgeAgitator);
|
|
78
|
+
* ```
|
|
79
|
+
*
|
|
80
|
+
* ## registration.singleton
|
|
81
|
+
|
|
82
|
+
* The cartridgeAgitator model is NOT a singleton model. This means that each time the factory function is called with a unique ID, a new model instance will be created.
|
|
83
|
+
* If the factory function is called with an ID that already exists, the existing model will be returned.
|
|
84
|
+
|
|
85
|
+
* */
|
|
86
|
+
export declare const CartridgeAgitator: KosModelRegistrationFactory<CartridgeAgitatorModel, CartridgeAgitatorOptions>;
|
|
87
|
+
//# sourceMappingURL=cartridge-agitator-registration.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cartridge-agitator-registration.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/cartridge-agitator/cartridge-agitator-registration.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,yBAAyB,CAAC;AACtE,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,4BAA4B,CAAC;AAKzE,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,SAAS,CAAC;AAExD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAgFK;AACL,eAAO,MAAM,iBAAiB,+EAM5B,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export type { CartridgeAgitatorContainerModel } from './cartridge-agitator-container-model';
|
|
2
|
+
export { CartridgeAgitatorContainer } from './cartridge-agitator-container-registration';
|
|
3
|
+
export { CartridgeAgitatorEvents, type CartridgeAgitatorModel, } from './cartridge-agitator-model';
|
|
4
|
+
export { CartridgeAgitator } from './cartridge-agitator-registration';
|
|
5
|
+
export type * from './types';
|
|
6
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/cartridge-agitator/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,+BAA+B,EAAE,MAAM,sCAAsC,CAAC;AAC5F,OAAO,EAAE,0BAA0B,EAAE,MAAM,6CAA6C,CAAC;AACzF,OAAO,EACL,uBAAuB,EACvB,KAAK,sBAAsB,GAC5B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AACtE,mBAAmB,SAAS,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { FutureResponse } from '@kosdev-code/kos-ui-sdk';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @category Service
|
|
5
|
+
* Retrieves the initial screen data.
|
|
6
|
+
*/
|
|
7
|
+
export declare const agitate: (path: string, tracker: string) => Promise<FutureResponse>;
|
|
8
|
+
//# sourceMappingURL=cartridge-agitator-services.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cartridge-agitator-services.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/cartridge-agitator/services/cartridge-agitator-services.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,cAAc,EAEf,MAAM,yBAAyB,CAAC;AAOjC;;;GAGG;AACH,eAAO,MAAM,OAAO,SAAgB,MAAM,WAAW,MAAM,4BAY1D,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// --------------- CartridgeAgitator ---------------
|
|
2
|
+
|
|
3
|
+
export interface CartridgeAgitatorOptions {
|
|
4
|
+
name: string;
|
|
5
|
+
path: string;
|
|
6
|
+
statePath: string;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export interface AgitationRequiredTroubleIface {
|
|
10
|
+
agitationRequired: boolean;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
// --------------- CartridgeAgitatorContainer ---------------
|
|
14
|
+
export interface CartridgeAgitatorContainerOptions {}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { FreestyleHolderModelExt, FreestyleModelAssemblyExt } from '../types/assembly';
|
|
2
|
+
import { IceAgitatorModel } from '../ice-agitator';
|
|
3
|
+
import { CartridgeAgitatorContainerModel, CartridgeAgitatorModel } from '../cartridge-agitator';
|
|
4
|
+
import { CarbAgitatorModel } from '../carb-agitator';
|
|
5
|
+
import { AssemblyModel, AssemblyOptions, BoardModel, HolderModel, PumpModel } from '@kosdev-code/kos-dispense-sdk';
|
|
6
|
+
import { FreestyleAssemblyOptions } from './types';
|
|
7
|
+
import { IKosDataModel, IKosIdentifiable, KosCreationContext, PublicModelInterface } from '@kosdev-code/kos-ui-sdk';
|
|
8
|
+
|
|
9
|
+
export declare const MODEL_TYPE = "freestyle-assembly-model";
|
|
10
|
+
export declare const FEATURE_SUPPORTS_ICE = "iceAgitator";
|
|
11
|
+
export declare const FEATURE_SUPPORTS_CARB = "carbAgitator";
|
|
12
|
+
export type FreestyleAssemblyModel = PublicModelInterface<FreestyleAssemblyModelImpl> & AssemblyModel<FreestyleModelAssemblyExt, FreestyleHolderModelExt>;
|
|
13
|
+
export declare class FreestyleAssemblyModelImpl implements IKosDataModel, IKosIdentifiable, AssemblyModel<FreestyleModelAssemblyExt, FreestyleHolderModelExt> {
|
|
14
|
+
id: string;
|
|
15
|
+
private logger;
|
|
16
|
+
private assembly;
|
|
17
|
+
constructor(modelId: string, options: FreestyleAssemblyOptions, context: KosCreationContext);
|
|
18
|
+
get holderGroups(): string[];
|
|
19
|
+
get nozzlePaths(): string[];
|
|
20
|
+
get allHolders(): HolderModel<FreestyleHolderModelExt>[];
|
|
21
|
+
getHoldersByGroup(group: string): HolderModel<FreestyleHolderModelExt>[];
|
|
22
|
+
getHoldersByNozzle(nozzlePath: string): HolderModel<FreestyleHolderModelExt>[];
|
|
23
|
+
get pumpsByNozzle(): Record<string, PumpModel<any>[]>;
|
|
24
|
+
get pumpPaths(): string[];
|
|
25
|
+
get boards(): BoardModel<any>[];
|
|
26
|
+
updateModel(options: AssemblyOptions): void;
|
|
27
|
+
get iceAgitator(): IceAgitatorModel;
|
|
28
|
+
get carbAgitator(): CarbAgitatorModel;
|
|
29
|
+
get cartridgeAgitators(): CartridgeAgitatorContainerModel;
|
|
30
|
+
get defaultCartridgeAgitator(): CartridgeAgitatorModel;
|
|
31
|
+
get cartridgeAgitatorModels(): CartridgeAgitatorModel[];
|
|
32
|
+
get hasCartridgeAgitators(): boolean;
|
|
33
|
+
get supportsIce(): boolean;
|
|
34
|
+
get supportsCarb(): boolean;
|
|
35
|
+
init(): Promise<void>;
|
|
36
|
+
load(): Promise<void>;
|
|
37
|
+
}
|
|
38
|
+
//# sourceMappingURL=freestyle-assembly-model.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"freestyle-assembly-model.d.ts","sourceRoot":"","sources":["../../../../../../../packages/sdk/kos-freestyle-sdk/src/models/models/freestyle-assembly/freestyle-assembly-model.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACb,gBAAgB,EAEhB,kBAAkB,EAClB,oBAAoB,EACrB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,SAAS,CAAC;AAExD,OAAO,KAAK,EACV,aAAa,EACb,eAAe,EACf,UAAU,EACV,WAAW,EACX,SAAS,EACV,MAAM,+BAA+B,CAAC;AACvC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAC1D,OAAO,EACL,KAAK,+BAA+B,EACpC,KAAK,sBAAsB,EAC5B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AACxD,OAAO,KAAK,EACV,uBAAuB,EACvB,yBAAyB,EAC1B,MAAM,mBAAmB,CAAC;AAE3B,eAAO,MAAM,UAAU,6BAA6B,CAAC;AAErD,eAAO,MAAM,oBAAoB,gBAAgB,CAAC;AAClD,eAAO,MAAM,qBAAqB,iBAAiB,CAAC;AAEpD,MAAM,MAAM,sBAAsB,GAChC,oBAAoB,CAAC,0BAA0B,CAAC,GAC9C,aAAa,CAAC,yBAAyB,EAAE,uBAAuB,CAAC,CAAC;AAEtE,qBACa,0BACX,YACE,aAAa,EACb,gBAAgB,EAChB,aAAa,CAAC,yBAAyB,EAAE,uBAAuB,CAAC;IAEnE,EAAE,EAAE,MAAM,CAAC;IACX,OAAO,CAAC,MAAM,CAAmB;IACjC,OAAO,CAAC,QAAQ,CAGd;gBAGA,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,wBAAwB,EACjC,OAAO,EAAE,kBAAkB;IAW7B,IAAI,YAAY,IAAI,MAAM,EAAE,CAE3B;IACD,IAAI,WAAW,IAAI,MAAM,EAAE,CAE1B;IACD,IAAI,UAAU,IAAI,WAAW,CAAC,uBAAuB,CAAC,EAAE,CAEvD;IACD,iBAAiB,CAAC,KAAK,EAAE,MAAM,GAAG,WAAW,CAAC,uBAAuB,CAAC,EAAE;IAGxE,kBAAkB,CAChB,UAAU,EAAE,MAAM,GACjB,WAAW,CAAC,uBAAuB,CAAC,EAAE;IAGzC,IAAI,aAAa,IAAI,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,GAAG,CAAC,EAAE,CAAC,CAEpD;IACD,IAAI,SAAS,IAAI,MAAM,EAAE,CAExB;IAED,IAAI,MAAM,IAAI,UAAU,CAAC,GAAG,CAAC,EAAE,CAE9B;IACD,WAAW,CAAC,OAAO,EAAE,eAAe,GAAG,IAAI;IAG3C,IAAI,WAAW,IAAI,gBAAgB,CAElC;IACD,IAAI,YAAY,IAAI,iBAAiB,CAEpC;IAED,IAAI,kBAAkB,IAAI,+BAA+B,CAExD;IAED,IAAI,wBAAwB,IAAI,sBAAsB,CAErD;IACD,IAAI,uBAAuB,IAAI,sBAAsB,EAAE,CAEtD;IAED,IAAI,qBAAqB,IAAI,OAAO,CAEnC;IAID,IAAI,WAAW,YAEd;IAED,IAAI,YAAY,YAEf;IAEK,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAIrB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAG5B"}
|