@openxiot/xiot-core-spec-ts 0.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/LICENSE +21 -0
- package/README.md +2 -0
- package/dist/index.d.ts +315 -0
- package/dist/index.js +331 -0
- package/dist/xiot/core/spec/codec/app/ApplicationCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/app/ApplicationCodec.js +50 -0
- package/dist/xiot/core/spec/codec/app/authorization/AuthorizationCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/app/authorization/AuthorizationCodec.js +41 -0
- package/dist/xiot/core/spec/codec/app/authorization/impl/AuthorizationEventbusImplCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/app/authorization/impl/AuthorizationEventbusImplCodec.js +15 -0
- package/dist/xiot/core/spec/codec/app/authorization/impl/AuthorizationHttpImplCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/app/authorization/impl/AuthorizationHttpImplCodec.js +15 -0
- package/dist/xiot/core/spec/codec/app/authorization/impl/AuthorizationJwtImplCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/app/authorization/impl/AuthorizationJwtImplCodec.js +14 -0
- package/dist/xiot/core/spec/codec/app/event/EventReceiverCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/app/event/EventReceiverCodec.js +41 -0
- package/dist/xiot/core/spec/codec/app/event/impl/EventReceiverEventbusImplCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/app/event/impl/EventReceiverEventbusImplCodec.js +15 -0
- package/dist/xiot/core/spec/codec/app/event/impl/EventReceiverHttpImplCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/app/event/impl/EventReceiverHttpImplCodec.js +15 -0
- package/dist/xiot/core/spec/codec/app/event/impl/EventReceiverKafkaImplCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/app/event/impl/EventReceiverKafkaImplCodec.js +18 -0
- package/dist/xiot/core/spec/codec/definition/ActionDefinitionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/definition/ActionDefinitionCodec.js +43 -0
- package/dist/xiot/core/spec/codec/definition/ArgumentDefinitionCodec.d.ts +8 -0
- package/dist/xiot/core/spec/codec/definition/ArgumentDefinitionCodec.js +48 -0
- package/dist/xiot/core/spec/codec/definition/CategoryDefinitionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/definition/CategoryDefinitionCodec.js +32 -0
- package/dist/xiot/core/spec/codec/definition/DescriptionCodec.d.ts +4 -0
- package/dist/xiot/core/spec/codec/definition/DescriptionCodec.js +32 -0
- package/dist/xiot/core/spec/codec/definition/DeviceDefinitionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/definition/DeviceDefinitionCodec.js +38 -0
- package/dist/xiot/core/spec/codec/definition/EventDefinitionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/definition/EventDefinitionCodec.js +39 -0
- package/dist/xiot/core/spec/codec/definition/FormatDefinitionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/definition/FormatDefinitionCodec.js +34 -0
- package/dist/xiot/core/spec/codec/definition/NamespaceDefinitionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/definition/NamespaceDefinitionCodec.js +32 -0
- package/dist/xiot/core/spec/codec/definition/PropertyDefinitionCodec.d.ts +9 -0
- package/dist/xiot/core/spec/codec/definition/PropertyDefinitionCodec.js +95 -0
- package/dist/xiot/core/spec/codec/definition/ServiceDefinitionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/definition/ServiceDefinitionCodec.js +71 -0
- package/dist/xiot/core/spec/codec/definition/UnitDefinitionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/definition/UnitDefinitionCodec.js +34 -0
- package/dist/xiot/core/spec/codec/definition/ValueListCodec.d.ts +6 -0
- package/dist/xiot/core/spec/codec/definition/ValueListCodec.js +31 -0
- package/dist/xiot/core/spec/codec/definition/ValueRangeCodec.d.ts +6 -0
- package/dist/xiot/core/spec/codec/definition/ValueRangeCodec.js +13 -0
- package/dist/xiot/core/spec/codec/definition/type/ActionTypeCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/definition/type/ActionTypeCodec.js +28 -0
- package/dist/xiot/core/spec/codec/definition/type/EventTypeCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/definition/type/EventTypeCodec.js +28 -0
- package/dist/xiot/core/spec/codec/definition/type/GroupTypeCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/definition/type/GroupTypeCodec.js +28 -0
- package/dist/xiot/core/spec/codec/definition/type/PropertyTypeCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/definition/type/PropertyTypeCodec.js +28 -0
- package/dist/xiot/core/spec/codec/definition/type/ServiceTypeCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/definition/type/ServiceTypeCodec.js +28 -0
- package/dist/xiot/core/spec/codec/device/DeviceCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/device/DeviceCodec.js +51 -0
- package/dist/xiot/core/spec/codec/image/ActionImageCodec.d.ts +4 -0
- package/dist/xiot/core/spec/codec/image/ActionImageCodec.js +25 -0
- package/dist/xiot/core/spec/codec/image/ArgumentImageCodec.d.ts +8 -0
- package/dist/xiot/core/spec/codec/image/ArgumentImageCodec.js +44 -0
- package/dist/xiot/core/spec/codec/image/DeviceImageCodec.d.ts +4 -0
- package/dist/xiot/core/spec/codec/image/DeviceImageCodec.js +17 -0
- package/dist/xiot/core/spec/codec/image/EventImageCodec.d.ts +4 -0
- package/dist/xiot/core/spec/codec/image/EventImageCodec.js +27 -0
- package/dist/xiot/core/spec/codec/image/PropertyImageCodec.d.ts +4 -0
- package/dist/xiot/core/spec/codec/image/PropertyImageCodec.js +18 -0
- package/dist/xiot/core/spec/codec/image/ServiceImageCodec.d.ts +4 -0
- package/dist/xiot/core/spec/codec/image/ServiceImageCodec.js +42 -0
- package/dist/xiot/core/spec/codec/instance/ActionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/instance/ActionCodec.js +49 -0
- package/dist/xiot/core/spec/codec/instance/ArgumentCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/instance/ArgumentCodec.js +44 -0
- package/dist/xiot/core/spec/codec/instance/DeviceInstanceCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/instance/DeviceInstanceCodec.js +25 -0
- package/dist/xiot/core/spec/codec/instance/EventCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/instance/EventCodec.js +45 -0
- package/dist/xiot/core/spec/codec/instance/PropertyCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/instance/PropertyCodec.js +98 -0
- package/dist/xiot/core/spec/codec/instance/ServiceCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/instance/ServiceCodec.js +55 -0
- package/dist/xiot/core/spec/codec/jwt/JwtCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/jwt/JwtCodec.js +41 -0
- package/dist/xiot/core/spec/codec/jwt/impl/JwtEsImplCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/jwt/impl/JwtEsImplCodec.js +26 -0
- package/dist/xiot/core/spec/codec/jwt/impl/JwtRsaImplCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/jwt/impl/JwtRsaImplCodec.js +26 -0
- package/dist/xiot/core/spec/codec/jwt/impl/JwtSecretsImplCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/jwt/impl/JwtSecretsImplCodec.js +24 -0
- package/dist/xiot/core/spec/codec/key/AccessKeyCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/key/AccessKeyCodec.js +18 -0
- package/dist/xiot/core/spec/codec/key/DeviceCertCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/key/DeviceCertCodec.js +36 -0
- package/dist/xiot/core/spec/codec/key/DeviceKeyCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/key/DeviceKeyCodec.js +24 -0
- package/dist/xiot/core/spec/codec/lifecycle/app/ApplicationWithLifecycleCodec.d.ts +11 -0
- package/dist/xiot/core/spec/codec/lifecycle/app/ApplicationWithLifecycleCodec.js +38 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/ActionDefinitionWithLifecycleCodec.d.ts +11 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/ActionDefinitionWithLifecycleCodec.js +38 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/DeviceDefinitionWithLifecycleCodec.d.ts +11 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/DeviceDefinitionWithLifecycleCodec.js +38 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/EventDefinitionWithLifecycleCodec.d.ts +11 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/EventDefinitionWithLifecycleCodec.js +38 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/FormatDefinitionWithLifecycleCodec.d.ts +11 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/FormatDefinitionWithLifecycleCodec.js +38 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/PropertyDefinitionWithLifecycleCodec.d.ts +8 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/PropertyDefinitionWithLifecycleCodec.js +38 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/ServiceDefinitionWithLifecycleCodec.d.ts +11 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/ServiceDefinitionWithLifecycleCodec.js +38 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/UnitDefinitionWithLifecycleCodec.d.ts +11 -0
- package/dist/xiot/core/spec/codec/lifecycle/definition/UnitDefinitionWithLifecycleCodec.js +38 -0
- package/dist/xiot/core/spec/codec/lifecycle/instance/DeviceInstanceWithLifecycleCodec.d.ts +11 -0
- package/dist/xiot/core/spec/codec/lifecycle/instance/DeviceInstanceWithLifecycleCodec.js +38 -0
- package/dist/xiot/core/spec/codec/lifecycle/product/VersionWithLifecycleCodec.d.ts +10 -0
- package/dist/xiot/core/spec/codec/lifecycle/product/VersionWithLifecycleCodec.js +42 -0
- package/dist/xiot/core/spec/codec/lifecycle/template/DeviceTemplateWithLifecycleCodec.d.ts +11 -0
- package/dist/xiot/core/spec/codec/lifecycle/template/DeviceTemplateWithLifecycleCodec.js +38 -0
- package/dist/xiot/core/spec/codec/lifecycle/type/DeviceTypeWithLifecycleCodec.d.ts +12 -0
- package/dist/xiot/core/spec/codec/lifecycle/type/DeviceTypeWithLifecycleCodec.js +36 -0
- package/dist/xiot/core/spec/codec/notice/DeviceNoticeCodec.d.ts +8 -0
- package/dist/xiot/core/spec/codec/notice/DeviceNoticeCodec.js +122 -0
- package/dist/xiot/core/spec/codec/notice/OwnerNoticeCodec.d.ts +8 -0
- package/dist/xiot/core/spec/codec/notice/OwnerNoticeCodec.js +220 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceAccessKeyChangedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceAccessKeyChangedCodec.js +19 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceChildrenAddedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceChildrenAddedCodec.js +20 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceChildrenRemovedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceChildrenRemovedCodec.js +19 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceEventOccurredCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceEventOccurredCodec.js +18 -0
- package/dist/xiot/core/spec/codec/notice/device/DevicePropertiesChangedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/device/DevicePropertiesChangedCodec.js +18 -0
- package/dist/xiot/core/spec/codec/notice/device/DevicePropertyChangedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/device/DevicePropertyChangedCodec.js +18 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceRootActiveCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceRootActiveCodec.js +20 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceRootInactiveCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceRootInactiveCodec.js +16 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceSummaryChangedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/device/DeviceSummaryChangedCodec.js +20 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerDeviceAddedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerDeviceAddedCodec.js +23 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerDeviceRemovedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerDeviceRemovedCodec.js +19 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerDeviceSomewhereChangedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerDeviceSomewhereChangedCodec.js +26 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerDeviceSummaryChangedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerDeviceSummaryChangedCodec.js +26 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerEventOccurredCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerEventOccurredCodec.js +20 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerPropertiesChangedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerPropertiesChangedCodec.js +21 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerRuleAddedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerRuleAddedCodec.js +24 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerRuleChangedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerRuleChangedCodec.js +24 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerRuleExecutedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerRuleExecutedCodec.js +47 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerRuleRemovedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerRuleRemovedCodec.js +23 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerRuleTriggeredCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnerRuleTriggeredCodec.js +23 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnershipDisclaimedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnershipDisclaimedCodec.js +19 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnershipTakenCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/OwnershipTakenCodec.js +19 -0
- package/dist/xiot/core/spec/codec/notice/owner/home/OwnerHomeAddedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/home/OwnerHomeAddedCodec.js +24 -0
- package/dist/xiot/core/spec/codec/notice/owner/home/OwnerHomeChangedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/home/OwnerHomeChangedCodec.js +24 -0
- package/dist/xiot/core/spec/codec/notice/owner/home/OwnerHomeRemovedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/home/OwnerHomeRemovedCodec.js +23 -0
- package/dist/xiot/core/spec/codec/notice/owner/space/OwnerSpaceAddedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/space/OwnerSpaceAddedCodec.js +24 -0
- package/dist/xiot/core/spec/codec/notice/owner/space/OwnerSpaceChangedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/space/OwnerSpaceChangedCodec.js +24 -0
- package/dist/xiot/core/spec/codec/notice/owner/space/OwnerSpaceRemovedCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/notice/owner/space/OwnerSpaceRemovedCodec.js +23 -0
- package/dist/xiot/core/spec/codec/oauth2/Oauth2ConfigurationCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/oauth2/Oauth2ConfigurationCodec.js +49 -0
- package/dist/xiot/core/spec/codec/operation/AbstractOperationCodec.d.ts +10 -0
- package/dist/xiot/core/spec/codec/operation/AbstractOperationCodec.js +27 -0
- package/dist/xiot/core/spec/codec/operation/ActionOperationCodec.d.ts +14 -0
- package/dist/xiot/core/spec/codec/operation/ActionOperationCodec.js +84 -0
- package/dist/xiot/core/spec/codec/operation/ArgumentOperationCodec.d.ts +10 -0
- package/dist/xiot/core/spec/codec/operation/ArgumentOperationCodec.js +65 -0
- package/dist/xiot/core/spec/codec/operation/CombinationValueCodec.d.ts +6 -0
- package/dist/xiot/core/spec/codec/operation/CombinationValueCodec.js +70 -0
- package/dist/xiot/core/spec/codec/operation/EventOperationCodec.d.ts +14 -0
- package/dist/xiot/core/spec/codec/operation/EventOperationCodec.js +63 -0
- package/dist/xiot/core/spec/codec/operation/PropertyOperationCodec.d.ts +31 -0
- package/dist/xiot/core/spec/codec/operation/PropertyOperationCodec.js +151 -0
- package/dist/xiot/core/spec/codec/operation/RuleOperationCodec.d.ts +14 -0
- package/dist/xiot/core/spec/codec/operation/RuleOperationCodec.js +43 -0
- package/dist/xiot/core/spec/codec/ownership/DeviceOwnerCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/ownership/DeviceOwnerCodec.js +37 -0
- package/dist/xiot/core/spec/codec/ownership/OwnershipCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/ownership/OwnershipCodec.js +62 -0
- package/dist/xiot/core/spec/codec/product/ProductCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/product/ProductCodec.js +76 -0
- package/dist/xiot/core/spec/codec/product/ProductVersionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/product/ProductVersionCodec.js +69 -0
- package/dist/xiot/core/spec/codec/product/resource/ProductResourceCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/product/resource/ProductResourceCodec.js +45 -0
- package/dist/xiot/core/spec/codec/product/resource/ProductResourceVersionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/product/resource/ProductResourceVersionCodec.js +69 -0
- package/dist/xiot/core/spec/codec/product/resource/ResourceVersionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/product/resource/ResourceVersionCodec.js +65 -0
- package/dist/xiot/core/spec/codec/rbac/PermissionCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/rbac/PermissionCodec.js +35 -0
- package/dist/xiot/core/spec/codec/rbac/RoleCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/rbac/RoleCodec.js +34 -0
- package/dist/xiot/core/spec/codec/rbac/account/AccountCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/rbac/account/AccountCodec.js +38 -0
- package/dist/xiot/core/spec/codec/rbac/organization/MemberCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/rbac/organization/MemberCodec.js +34 -0
- package/dist/xiot/core/spec/codec/rbac/organization/OrganizationCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/rbac/organization/OrganizationCodec.js +33 -0
- package/dist/xiot/core/spec/codec/rule/RuleCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/rule/RuleCodec.js +74 -0
- package/dist/xiot/core/spec/codec/shadow/DeviceShadowCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/shadow/DeviceShadowCodec.js +38 -0
- package/dist/xiot/core/spec/codec/shadow/ShadowCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/shadow/ShadowCodec.js +51 -0
- package/dist/xiot/core/spec/codec/somewhere/SomewhereCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/somewhere/SomewhereCodec.js +50 -0
- package/dist/xiot/core/spec/codec/space/SpaceCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/space/SpaceCodec.js +45 -0
- package/dist/xiot/core/spec/codec/summary/SummaryCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/summary/SummaryCodec.js +82 -0
- package/dist/xiot/core/spec/codec/template/ActionTemplateCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/template/ActionTemplateCodec.js +55 -0
- package/dist/xiot/core/spec/codec/template/DeviceTemplateCodec.d.ts +5 -0
- package/dist/xiot/core/spec/codec/template/DeviceTemplateCodec.js +24 -0
- package/dist/xiot/core/spec/codec/template/EventTemplateCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/template/EventTemplateCodec.js +51 -0
- package/dist/xiot/core/spec/codec/template/PropertyTemplateCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/template/PropertyTemplateCodec.js +78 -0
- package/dist/xiot/core/spec/codec/template/ServiceTemplateCodec.d.ts +7 -0
- package/dist/xiot/core/spec/codec/template/ServiceTemplateCodec.js +67 -0
- package/dist/xiot/core/spec/typedef/app/Application.d.ts +11 -0
- package/dist/xiot/core/spec/typedef/app/Application.js +13 -0
- package/dist/xiot/core/spec/typedef/app/authorization/Authorization.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/app/authorization/Authorization.js +9 -0
- package/dist/xiot/core/spec/typedef/app/authorization/AuthorizationType.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/app/authorization/AuthorizationType.js +25 -0
- package/dist/xiot/core/spec/typedef/app/authorization/impl/AuthorizationEventbusImpl.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/app/authorization/impl/AuthorizationEventbusImpl.js +12 -0
- package/dist/xiot/core/spec/typedef/app/authorization/impl/AuthorizationHttpImpl.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/app/authorization/impl/AuthorizationHttpImpl.js +12 -0
- package/dist/xiot/core/spec/typedef/app/authorization/impl/AuthorizationJwtImpl.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/app/authorization/impl/AuthorizationJwtImpl.js +12 -0
- package/dist/xiot/core/spec/typedef/app/event/EventReceiver.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/app/event/EventReceiver.js +9 -0
- package/dist/xiot/core/spec/typedef/app/event/EventReceiverType.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/app/event/EventReceiverType.js +25 -0
- package/dist/xiot/core/spec/typedef/app/event/impl/EventReceiverEventbusImpl.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/app/event/impl/EventReceiverEventbusImpl.js +12 -0
- package/dist/xiot/core/spec/typedef/app/event/impl/EventReceiverHttpImpl.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/app/event/impl/EventReceiverHttpImpl.js +12 -0
- package/dist/xiot/core/spec/typedef/app/event/impl/EventReceiverKafkaImpl.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/app/event/impl/EventReceiverKafkaImpl.js +13 -0
- package/dist/xiot/core/spec/typedef/constant/Spec.d.ts +48 -0
- package/dist/xiot/core/spec/typedef/constant/Spec.js +52 -0
- package/dist/xiot/core/spec/typedef/definition/ActionDefinition.d.ts +9 -0
- package/dist/xiot/core/spec/typedef/definition/ActionDefinition.js +21 -0
- package/dist/xiot/core/spec/typedef/definition/ArgumentDefinition.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/definition/ArgumentDefinition.js +11 -0
- package/dist/xiot/core/spec/typedef/definition/CategoryDefinition.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/definition/CategoryDefinition.js +12 -0
- package/dist/xiot/core/spec/typedef/definition/DeviceDefinition.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/definition/DeviceDefinition.js +14 -0
- package/dist/xiot/core/spec/typedef/definition/EventDefinition.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/definition/EventDefinition.js +17 -0
- package/dist/xiot/core/spec/typedef/definition/FormatDefinition.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/definition/FormatDefinition.js +11 -0
- package/dist/xiot/core/spec/typedef/definition/NamespaceDefinition.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/definition/NamespaceDefinition.js +12 -0
- package/dist/xiot/core/spec/typedef/definition/PropertyDefinition.d.ts +24 -0
- package/dist/xiot/core/spec/typedef/definition/PropertyDefinition.js +71 -0
- package/dist/xiot/core/spec/typedef/definition/ServiceDefinition.d.ts +15 -0
- package/dist/xiot/core/spec/typedef/definition/ServiceDefinition.js +37 -0
- package/dist/xiot/core/spec/typedef/definition/UnitDefinition.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/definition/UnitDefinition.js +11 -0
- package/dist/xiot/core/spec/typedef/definition/property/Access.d.ts +11 -0
- package/dist/xiot/core/spec/typedef/definition/property/Access.js +87 -0
- package/dist/xiot/core/spec/typedef/definition/property/ConstraintValue.d.ts +4 -0
- package/dist/xiot/core/spec/typedef/definition/property/ConstraintValue.js +2 -0
- package/dist/xiot/core/spec/typedef/definition/property/ValueDefinition.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/definition/property/ValueDefinition.js +12 -0
- package/dist/xiot/core/spec/typedef/definition/property/ValueList.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/definition/property/ValueList.js +21 -0
- package/dist/xiot/core/spec/typedef/definition/property/ValueRange.d.ts +18 -0
- package/dist/xiot/core/spec/typedef/definition/property/ValueRange.js +103 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/DataFormat.d.ts +23 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/DataFormat.js +96 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/DataValue.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/DataValue.js +2 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/DataValueFactory.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/DataValueFactory.js +115 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vbool.d.ts +12 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vbool.js +53 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vcombination.d.ts +11 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vcombination.js +33 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vfloat.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vfloat.js +67 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vhex.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vhex.js +80 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vint16.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vint16.js +65 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vint32.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vint32.js +65 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vint64.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vint64.js +65 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vint8.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vint8.js +65 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vstring.d.ts +11 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vstring.js +36 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vtlv8.d.ts +12 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vtlv8.js +39 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vuint16.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vuint16.js +71 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vuint32.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vuint32.js +65 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vuint8.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/definition/property/data/value/Vuint8.js +65 -0
- package/dist/xiot/core/spec/typedef/definition/urn/ActionType.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/definition/urn/ActionType.js +14 -0
- package/dist/xiot/core/spec/typedef/definition/urn/DeviceType.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/definition/urn/DeviceType.js +14 -0
- package/dist/xiot/core/spec/typedef/definition/urn/EventType.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/definition/urn/EventType.js +14 -0
- package/dist/xiot/core/spec/typedef/definition/urn/Extendable.d.ts +11 -0
- package/dist/xiot/core/spec/typedef/definition/urn/Extendable.js +18 -0
- package/dist/xiot/core/spec/typedef/definition/urn/FormatType.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/definition/urn/FormatType.js +14 -0
- package/dist/xiot/core/spec/typedef/definition/urn/GroupType.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/definition/urn/GroupType.js +14 -0
- package/dist/xiot/core/spec/typedef/definition/urn/PropertyType.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/definition/urn/PropertyType.js +14 -0
- package/dist/xiot/core/spec/typedef/definition/urn/ServiceType.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/definition/urn/ServiceType.js +14 -0
- package/dist/xiot/core/spec/typedef/definition/urn/UnitType.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/definition/urn/UnitType.js +14 -0
- package/dist/xiot/core/spec/typedef/definition/urn/Urn.d.ts +24 -0
- package/dist/xiot/core/spec/typedef/definition/urn/Urn.js +146 -0
- package/dist/xiot/core/spec/typedef/definition/urn/UrnStyle.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/definition/urn/UrnStyle.js +11 -0
- package/dist/xiot/core/spec/typedef/definition/urn/UrnType.d.ts +13 -0
- package/dist/xiot/core/spec/typedef/definition/urn/UrnType.js +30 -0
- package/dist/xiot/core/spec/typedef/device/Device.d.ts +9 -0
- package/dist/xiot/core/spec/typedef/device/Device.js +9 -0
- package/dist/xiot/core/spec/typedef/error/IotError.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/error/IotError.js +13 -0
- package/dist/xiot/core/spec/typedef/image/ActionImage.d.ts +13 -0
- package/dist/xiot/core/spec/typedef/image/ActionImage.js +76 -0
- package/dist/xiot/core/spec/typedef/image/ArgumentImage.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/image/ArgumentImage.js +30 -0
- package/dist/xiot/core/spec/typedef/image/DeviceImage.d.ts +31 -0
- package/dist/xiot/core/spec/typedef/image/DeviceImage.js +283 -0
- package/dist/xiot/core/spec/typedef/image/EventImage.d.ts +11 -0
- package/dist/xiot/core/spec/typedef/image/EventImage.js +48 -0
- package/dist/xiot/core/spec/typedef/image/PropertyImage.d.ts +22 -0
- package/dist/xiot/core/spec/typedef/image/PropertyImage.js +73 -0
- package/dist/xiot/core/spec/typedef/image/ServiceImage.d.ts +21 -0
- package/dist/xiot/core/spec/typedef/image/ServiceImage.js +172 -0
- package/dist/xiot/core/spec/typedef/instance/Action.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/instance/Action.js +33 -0
- package/dist/xiot/core/spec/typedef/instance/Argument.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/instance/Argument.js +18 -0
- package/dist/xiot/core/spec/typedef/instance/DeviceInstance.d.ts +9 -0
- package/dist/xiot/core/spec/typedef/instance/DeviceInstance.js +17 -0
- package/dist/xiot/core/spec/typedef/instance/Event.d.ts +11 -0
- package/dist/xiot/core/spec/typedef/instance/Event.js +23 -0
- package/dist/xiot/core/spec/typedef/instance/Property.d.ts +56 -0
- package/dist/xiot/core/spec/typedef/instance/Property.js +244 -0
- package/dist/xiot/core/spec/typedef/instance/PropertyValue.d.ts +16 -0
- package/dist/xiot/core/spec/typedef/instance/PropertyValue.js +81 -0
- package/dist/xiot/core/spec/typedef/instance/Service.d.ts +19 -0
- package/dist/xiot/core/spec/typedef/instance/Service.js +48 -0
- package/dist/xiot/core/spec/typedef/jwt/Jwt.d.ts +10 -0
- package/dist/xiot/core/spec/typedef/jwt/Jwt.js +16 -0
- package/dist/xiot/core/spec/typedef/jwt/JwtType.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/jwt/JwtType.js +25 -0
- package/dist/xiot/core/spec/typedef/jwt/impl/JwtEsImpl.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/jwt/impl/JwtEsImpl.js +15 -0
- package/dist/xiot/core/spec/typedef/jwt/impl/JwtRsaImpl.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/jwt/impl/JwtRsaImpl.js +15 -0
- package/dist/xiot/core/spec/typedef/jwt/impl/JwtSecretsImpl.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/jwt/impl/JwtSecretsImpl.js +13 -0
- package/dist/xiot/core/spec/typedef/key/AccessKey.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/key/AccessKey.js +10 -0
- package/dist/xiot/core/spec/typedef/key/DeviceCert.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/key/DeviceCert.js +12 -0
- package/dist/xiot/core/spec/typedef/key/DeviceKey.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/key/DeviceKey.js +13 -0
- package/dist/xiot/core/spec/typedef/lifecycle/Lifecycle.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/lifecycle/Lifecycle.js +25 -0
- package/dist/xiot/core/spec/typedef/lifecycle/ObjectWithLifecycle.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/lifecycle/ObjectWithLifecycle.js +10 -0
- package/dist/xiot/core/spec/typedef/notice/Notice.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/notice/Notice.js +9 -0
- package/dist/xiot/core/spec/typedef/notice/NoticeCodec.d.ts +27 -0
- package/dist/xiot/core/spec/typedef/notice/NoticeCodec.js +6 -0
- package/dist/xiot/core/spec/typedef/notice/device/DeviceNotice.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/notice/device/DeviceNotice.js +13 -0
- package/dist/xiot/core/spec/typedef/notice/device/DeviceNoticeType.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/notice/device/DeviceNoticeType.js +31 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceAccessKeyChanged.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceAccessKeyChanged.js +16 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceChildrenAdded.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceChildrenAdded.js +16 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceChildrenRemoved.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceChildrenRemoved.js +16 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceEventOccurred.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceEventOccurred.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DevicePropertiesChanged.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DevicePropertiesChanged.js +16 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DevicePropertyChanged.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DevicePropertyChanged.js +17 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceRootActive.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceRootActive.js +16 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceRootInactive.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceRootInactive.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceSummaryChanged.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/notice/device/impl/DeviceSummaryChanged.js +17 -0
- package/dist/xiot/core/spec/typedef/notice/owner/OwnerNotice.d.ts +9 -0
- package/dist/xiot/core/spec/typedef/notice/owner/OwnerNotice.js +16 -0
- package/dist/xiot/core/spec/typedef/notice/owner/OwnerNoticeType.d.ts +42 -0
- package/dist/xiot/core/spec/typedef/notice/owner/OwnerNoticeType.js +59 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerDeviceAdded.d.ts +10 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerDeviceAdded.js +17 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerDeviceRemoved.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerDeviceRemoved.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerDeviceSomewhereChanged.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerDeviceSomewhereChanged.js +16 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerDeviceSummaryChanged.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerDeviceSummaryChanged.js +16 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerEventOccurred.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerEventOccurred.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerPropertiesChanged.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerPropertiesChanged.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerRuleAdded.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerRuleAdded.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerRuleChanged.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerRuleChanged.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerRuleExecuted.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerRuleExecuted.js +16 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerRuleRemoved.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerRuleRemoved.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerRuleTriggered.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnerRuleTriggered.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnershipDisclaimed.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnershipDisclaimed.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnershipTaken.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/OwnershipTaken.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/home/OwnerHomeAdded.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/home/OwnerHomeAdded.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/home/OwnerHomeChanged.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/home/OwnerHomeChanged.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/home/OwnerHomeRemoved.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/home/OwnerHomeRemoved.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/space/OwnerSpaceAdded.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/space/OwnerSpaceAdded.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/space/OwnerSpaceChanged.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/space/OwnerSpaceChanged.js +15 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/space/OwnerSpaceRemoved.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/notice/owner/impl/space/OwnerSpaceRemoved.js +15 -0
- package/dist/xiot/core/spec/typedef/oauth2/Oauth2Configuration.d.ts +13 -0
- package/dist/xiot/core/spec/typedef/oauth2/Oauth2Configuration.js +19 -0
- package/dist/xiot/core/spec/typedef/operation/AbstractOperation.d.ts +9 -0
- package/dist/xiot/core/spec/typedef/operation/AbstractOperation.js +21 -0
- package/dist/xiot/core/spec/typedef/operation/ActionOperation.d.ts +17 -0
- package/dist/xiot/core/spec/typedef/operation/ActionOperation.js +50 -0
- package/dist/xiot/core/spec/typedef/operation/ArgumentOperation.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/operation/ArgumentOperation.js +52 -0
- package/dist/xiot/core/spec/typedef/operation/EventOperation.d.ts +16 -0
- package/dist/xiot/core/spec/typedef/operation/EventOperation.js +58 -0
- package/dist/xiot/core/spec/typedef/operation/PropertyOperation.d.ts +13 -0
- package/dist/xiot/core/spec/typedef/operation/PropertyOperation.js +53 -0
- package/dist/xiot/core/spec/typedef/operation/RemindOperation.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/operation/RemindOperation.js +25 -0
- package/dist/xiot/core/spec/typedef/operation/RuleOperation.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/operation/RuleOperation.js +25 -0
- package/dist/xiot/core/spec/typedef/operation/SleepOperation.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/operation/SleepOperation.js +25 -0
- package/dist/xiot/core/spec/typedef/operation/value/AnyValue.d.ts +3 -0
- package/dist/xiot/core/spec/typedef/operation/value/AnyValue.js +9 -0
- package/dist/xiot/core/spec/typedef/operation/value/AutoscalingValue.d.ts +3 -0
- package/dist/xiot/core/spec/typedef/operation/value/AutoscalingValue.js +9 -0
- package/dist/xiot/core/spec/typedef/operation/value/ReverseValue.d.ts +3 -0
- package/dist/xiot/core/spec/typedef/operation/value/ReverseValue.js +9 -0
- package/dist/xiot/core/spec/typedef/ownership/DeviceOwner.d.ts +4 -0
- package/dist/xiot/core/spec/typedef/ownership/DeviceOwner.js +10 -0
- package/dist/xiot/core/spec/typedef/ownership/Ownership.d.ts +12 -0
- package/dist/xiot/core/spec/typedef/ownership/Ownership.js +26 -0
- package/dist/xiot/core/spec/typedef/product/Product.d.ts +22 -0
- package/dist/xiot/core/spec/typedef/product/Product.js +25 -0
- package/dist/xiot/core/spec/typedef/product/ProductVersion.d.ts +17 -0
- package/dist/xiot/core/spec/typedef/product/ProductVersion.js +24 -0
- package/dist/xiot/core/spec/typedef/product/resource/ProductResource.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/product/resource/ProductResource.js +13 -0
- package/dist/xiot/core/spec/typedef/product/resource/ProductResourceVersion.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/product/resource/ProductResourceVersion.js +12 -0
- package/dist/xiot/core/spec/typedef/product/resource/ResourceVersion.d.ts +16 -0
- package/dist/xiot/core/spec/typedef/product/resource/ResourceVersion.js +30 -0
- package/dist/xiot/core/spec/typedef/rbac/Permission.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/rbac/Permission.js +13 -0
- package/dist/xiot/core/spec/typedef/rbac/Role.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/rbac/Role.js +12 -0
- package/dist/xiot/core/spec/typedef/rbac/account/Account.d.ts +11 -0
- package/dist/xiot/core/spec/typedef/rbac/account/Account.js +16 -0
- package/dist/xiot/core/spec/typedef/rbac/organization/Member.d.ts +12 -0
- package/dist/xiot/core/spec/typedef/rbac/organization/Member.js +22 -0
- package/dist/xiot/core/spec/typedef/rbac/organization/Organization.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/rbac/organization/Organization.js +12 -0
- package/dist/xiot/core/spec/typedef/registry/DeviceRegistry.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/registry/DeviceRegistry.js +7 -0
- package/dist/xiot/core/spec/typedef/registry/accesspoint/AccessPoint.d.ts +4 -0
- package/dist/xiot/core/spec/typedef/registry/accesspoint/AccessPoint.js +10 -0
- package/dist/xiot/core/spec/typedef/registry/accesspoint/AccessPointType.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/registry/accesspoint/AccessPointType.js +24 -0
- package/dist/xiot/core/spec/typedef/registry/accesspoint/impl/AccessPointEventbus.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/registry/accesspoint/impl/AccessPointEventbus.js +12 -0
- package/dist/xiot/core/spec/typedef/registry/accesspoint/impl/AccessPointHttp.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/registry/accesspoint/impl/AccessPointHttp.js +13 -0
- package/dist/xiot/core/spec/typedef/rule/Rule.d.ts +44 -0
- package/dist/xiot/core/spec/typedef/rule/Rule.js +174 -0
- package/dist/xiot/core/spec/typedef/rule/RuleContent.d.ts +16 -0
- package/dist/xiot/core/spec/typedef/rule/RuleContent.js +56 -0
- package/dist/xiot/core/spec/typedef/rule/RuleType.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/rule/RuleType.js +11 -0
- package/dist/xiot/core/spec/typedef/rule/condition/AbstractCondition.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/rule/condition/AbstractCondition.js +12 -0
- package/dist/xiot/core/spec/typedef/rule/condition/ComplexCondition.d.ts +17 -0
- package/dist/xiot/core/spec/typedef/rule/condition/ComplexCondition.js +57 -0
- package/dist/xiot/core/spec/typedef/rule/condition/EventCondition.d.ts +16 -0
- package/dist/xiot/core/spec/typedef/rule/condition/EventCondition.js +59 -0
- package/dist/xiot/core/spec/typedef/rule/condition/ExternalCondition.d.ts +19 -0
- package/dist/xiot/core/spec/typedef/rule/condition/ExternalCondition.js +43 -0
- package/dist/xiot/core/spec/typedef/rule/condition/ExternalType.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/rule/condition/ExternalType.js +9 -0
- package/dist/xiot/core/spec/typedef/rule/condition/NowCondition.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/rule/condition/NowCondition.js +15 -0
- package/dist/xiot/core/spec/typedef/rule/condition/PropertyCondition.d.ts +19 -0
- package/dist/xiot/core/spec/typedef/rule/condition/PropertyCondition.js +48 -0
- package/dist/xiot/core/spec/typedef/rule/condition/TimeCondition.d.ts +14 -0
- package/dist/xiot/core/spec/typedef/rule/condition/TimeCondition.js +85 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/ComparisonOperator.d.ts +10 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/ComparisonOperator.js +32 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/LogicalOperator.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/LogicalOperator.js +22 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/compare/Comparator.d.ts +2 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/compare/Comparator.js +20 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/compare/Compare.d.ts +21 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/compare/Compare.js +67 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/logical/Logic.d.ts +2 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/logical/Logic.js +16 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/logical/Logical.d.ts +9 -0
- package/dist/xiot/core/spec/typedef/rule/condition/operator/logical/Logical.js +15 -0
- package/dist/xiot/core/spec/typedef/rule/cron/CronExp.d.ts +31 -0
- package/dist/xiot/core/spec/typedef/rule/cron/CronExp.js +102 -0
- package/dist/xiot/core/spec/typedef/rule/listener/RuleExecutionListener.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/rule/listener/RuleExecutionListener.js +2 -0
- package/dist/xiot/core/spec/typedef/rule/parser/RuleContentParser.d.ts +13 -0
- package/dist/xiot/core/spec/typedef/rule/parser/RuleContentParser.js +70 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/ConditionParser.d.ts +17 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/ConditionParser.js +72 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/parser0/Parser0.d.ts +28 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/parser0/Parser0.js +148 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/parser1/Parser1.d.ts +16 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/parser1/Parser1.js +90 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/parser2/Parser2.d.ts +31 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/parser2/Parser2.js +289 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/parser2/ParserState2.d.ts +13 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/parser2/ParserState2.js +17 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/parser2/Token2.d.ts +22 -0
- package/dist/xiot/core/spec/typedef/rule/parser/condition/parser2/Token2.js +68 -0
- package/dist/xiot/core/spec/typedef/rule/parser/operation/OperationParser.d.ts +31 -0
- package/dist/xiot/core/spec/typedef/rule/parser/operation/OperationParser.js +331 -0
- package/dist/xiot/core/spec/typedef/rule/parser/operation/OperationState.d.ts +19 -0
- package/dist/xiot/core/spec/typedef/rule/parser/operation/OperationState.js +23 -0
- package/dist/xiot/core/spec/typedef/rule/parser/token/Token.d.ts +91 -0
- package/dist/xiot/core/spec/typedef/rule/parser/token/Token.js +269 -0
- package/dist/xiot/core/spec/typedef/rule/parser/token/Tokenizer.d.ts +29 -0
- package/dist/xiot/core/spec/typedef/rule/parser/token/Tokenizer.js +483 -0
- package/dist/xiot/core/spec/typedef/shadow/DeviceShadow.d.ts +5 -0
- package/dist/xiot/core/spec/typedef/shadow/DeviceShadow.js +10 -0
- package/dist/xiot/core/spec/typedef/shadow/Shadow.d.ts +7 -0
- package/dist/xiot/core/spec/typedef/shadow/Shadow.js +13 -0
- package/dist/xiot/core/spec/typedef/somewhere/Somewhere.d.ts +11 -0
- package/dist/xiot/core/spec/typedef/somewhere/Somewhere.js +45 -0
- package/dist/xiot/core/spec/typedef/somewhere/Where.d.ts +9 -0
- package/dist/xiot/core/spec/typedef/somewhere/Where.js +26 -0
- package/dist/xiot/core/spec/typedef/space/Space.d.ts +9 -0
- package/dist/xiot/core/spec/typedef/space/Space.js +20 -0
- package/dist/xiot/core/spec/typedef/status/AbstractStatus.d.ts +8 -0
- package/dist/xiot/core/spec/typedef/status/AbstractStatus.js +23 -0
- package/dist/xiot/core/spec/typedef/status/Status.d.ts +50 -0
- package/dist/xiot/core/spec/typedef/status/Status.js +54 -0
- package/dist/xiot/core/spec/typedef/summary/Summary.d.ts +24 -0
- package/dist/xiot/core/spec/typedef/summary/Summary.js +120 -0
- package/dist/xiot/core/spec/typedef/template/ActionTemplate.d.ts +17 -0
- package/dist/xiot/core/spec/typedef/template/ActionTemplate.js +33 -0
- package/dist/xiot/core/spec/typedef/template/DeviceTemplate.d.ts +12 -0
- package/dist/xiot/core/spec/typedef/template/DeviceTemplate.js +23 -0
- package/dist/xiot/core/spec/typedef/template/EventTemplate.d.ts +15 -0
- package/dist/xiot/core/spec/typedef/template/EventTemplate.js +26 -0
- package/dist/xiot/core/spec/typedef/template/PropertyTemplate.d.ts +10 -0
- package/dist/xiot/core/spec/typedef/template/PropertyTemplate.js +16 -0
- package/dist/xiot/core/spec/typedef/template/ServiceTemplate.d.ts +24 -0
- package/dist/xiot/core/spec/typedef/template/ServiceTemplate.js +46 -0
- package/dist/xiot/core/spec/typedef/utils/Stack.d.ts +10 -0
- package/dist/xiot/core/spec/typedef/utils/Stack.js +35 -0
- package/dist/xiot/core/spec/typedef/utils/StringUtils.d.ts +3 -0
- package/dist/xiot/core/spec/typedef/utils/StringUtils.js +14 -0
- package/dist/xiot/core/spec/typedef/utils/TemplateHelper.d.ts +30 -0
- package/dist/xiot/core/spec/typedef/utils/TemplateHelper.js +285 -0
- package/dist/xiot/core/spec/typedef/version/Version.d.ts +9 -0
- package/dist/xiot/core/spec/typedef/version/Version.js +40 -0
- package/dist/xiot/core/spec/typedef/xid/ActionID.d.ts +13 -0
- package/dist/xiot/core/spec/typedef/xid/ActionID.js +27 -0
- package/dist/xiot/core/spec/typedef/xid/EventID.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/xid/EventID.js +20 -0
- package/dist/xiot/core/spec/typedef/xid/PropertyID.d.ts +6 -0
- package/dist/xiot/core/spec/typedef/xid/PropertyID.js +20 -0
- package/dist/xiot/core/spec/typedef/xid/XID3.d.ts +10 -0
- package/dist/xiot/core/spec/typedef/xid/XID3.js +41 -0
- package/dist/xiot/core/support/codegen/codec/controlled/ActionControlledCodec.d.ts +3 -0
- package/dist/xiot/core/support/codegen/codec/controlled/ActionControlledCodec.js +8 -0
- package/dist/xiot/core/support/codegen/codec/controlled/DeviceControlledCodec.d.ts +3 -0
- package/dist/xiot/core/support/codegen/codec/controlled/DeviceControlledCodec.js +8 -0
- package/dist/xiot/core/support/codegen/codec/controlled/EventControlledCodec.d.ts +3 -0
- package/dist/xiot/core/support/codegen/codec/controlled/EventControlledCodec.js +8 -0
- package/dist/xiot/core/support/codegen/codec/controlled/PropertyControlledCodec.d.ts +3 -0
- package/dist/xiot/core/support/codegen/codec/controlled/PropertyControlledCodec.js +8 -0
- package/dist/xiot/core/support/codegen/codec/controlled/ServiceControlledCodec.d.ts +2 -0
- package/dist/xiot/core/support/codegen/codec/controlled/ServiceControlledCodec.js +6 -0
- package/dist/xiot/core/support/codegen/codec/controller/ActionControllerCodec.d.ts +6 -0
- package/dist/xiot/core/support/codegen/codec/controller/ActionControllerCodec.js +30 -0
- package/dist/xiot/core/support/codegen/codec/controller/DeviceControllerCodec.d.ts +5 -0
- package/dist/xiot/core/support/codegen/codec/controller/DeviceControllerCodec.js +20 -0
- package/dist/xiot/core/support/codegen/codec/controller/EventControllerCodec.d.ts +6 -0
- package/dist/xiot/core/support/codegen/codec/controller/EventControllerCodec.js +29 -0
- package/dist/xiot/core/support/codegen/codec/controller/PropertyControllerCodec.d.ts +7 -0
- package/dist/xiot/core/support/codegen/codec/controller/PropertyControllerCodec.js +25 -0
- package/dist/xiot/core/support/codegen/codec/controller/ServiceControllerCodec.d.ts +5 -0
- package/dist/xiot/core/support/codegen/codec/controller/ServiceControllerCodec.js +31 -0
- package/dist/xiot/core/support/codegen/typedef/controlled/ActionControlled.d.ts +9 -0
- package/dist/xiot/core/support/codegen/typedef/controlled/ActionControlled.js +25 -0
- package/dist/xiot/core/support/codegen/typedef/controlled/DeviceControlled.d.ts +3 -0
- package/dist/xiot/core/support/codegen/typedef/controlled/DeviceControlled.js +7 -0
- package/dist/xiot/core/support/codegen/typedef/controlled/EventControlled.d.ts +12 -0
- package/dist/xiot/core/support/codegen/typedef/controlled/EventControlled.js +20 -0
- package/dist/xiot/core/support/codegen/typedef/controlled/PropertyControlled.d.ts +18 -0
- package/dist/xiot/core/support/codegen/typedef/controlled/PropertyControlled.js +122 -0
- package/dist/xiot/core/support/codegen/typedef/controlled/ServiceControlled.d.ts +8 -0
- package/dist/xiot/core/support/codegen/typedef/controlled/ServiceControlled.js +10 -0
- package/dist/xiot/core/support/codegen/typedef/controller/ActionController.d.ts +10 -0
- package/dist/xiot/core/support/codegen/typedef/controller/ActionController.js +15 -0
- package/dist/xiot/core/support/codegen/typedef/controller/DeviceController.d.ts +23 -0
- package/dist/xiot/core/support/codegen/typedef/controller/DeviceController.js +86 -0
- package/dist/xiot/core/support/codegen/typedef/controller/EventController.d.ts +8 -0
- package/dist/xiot/core/support/codegen/typedef/controller/EventController.js +12 -0
- package/dist/xiot/core/support/codegen/typedef/controller/PropertyController.d.ts +27 -0
- package/dist/xiot/core/support/codegen/typedef/controller/PropertyController.js +144 -0
- package/dist/xiot/core/support/codegen/typedef/controller/ServiceController.d.ts +15 -0
- package/dist/xiot/core/support/codegen/typedef/controller/ServiceController.js +70 -0
- package/dist/xiot/core/support/codegen/typedef/controller/SomewhereController.d.ts +7 -0
- package/dist/xiot/core/support/codegen/typedef/controller/SomewhereController.js +32 -0
- package/dist/xiot/core/support/codegen/typedef/controller/SummaryController.d.ts +7 -0
- package/dist/xiot/core/support/codegen/typedef/controller/SummaryController.js +55 -0
- package/dist/xiot/core/support/codegen/typedef/controller/operator/ActionInvokerWrapper.d.ts +9 -0
- package/dist/xiot/core/support/codegen/typedef/controller/operator/ActionInvokerWrapper.js +27 -0
- package/dist/xiot/core/support/codegen/typedef/controller/operator/PropertySetterWrapper.d.ts +8 -0
- package/dist/xiot/core/support/codegen/typedef/controller/operator/PropertySetterWrapper.js +27 -0
- package/dist/xiot/core/support/codegen/typedef/result/Result.d.ts +9 -0
- package/dist/xiot/core/support/codegen/typedef/result/Result.js +15 -0
- package/dist/xiot/core/support/codegen/typedef/rule/RuleController.d.ts +7 -0
- package/dist/xiot/core/support/codegen/typedef/rule/RuleController.js +14 -0
- package/dist/xiot/core/support/codegen/typedef/rule/status/RuleStatus.d.ts +2 -0
- package/dist/xiot/core/support/codegen/typedef/rule/status/RuleStatus.js +2 -0
- package/dist/xiot/core/support/codegen/typedef/rule/status/impl/RuleExecuted.d.ts +8 -0
- package/dist/xiot/core/support/codegen/typedef/rule/status/impl/RuleExecuted.js +11 -0
- package/dist/xiot/core/support/codegen/typedef/rule/status/impl/RuleReady.d.ts +3 -0
- package/dist/xiot/core/support/codegen/typedef/rule/status/impl/RuleReady.js +6 -0
- package/dist/xiot/core/support/codegen/typedef/rule/status/impl/RuleTriggered.d.ts +6 -0
- package/dist/xiot/core/support/codegen/typedef/rule/status/impl/RuleTriggered.js +10 -0
- package/package.json +62 -0
|
@@ -0,0 +1,483 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Tokenizer = void 0;
|
|
4
|
+
const Token_1 = require("./Token");
|
|
5
|
+
class Tokenizer {
|
|
6
|
+
constructor() {
|
|
7
|
+
this.tokens = [];
|
|
8
|
+
this.bytes = [];
|
|
9
|
+
this.current = 0;
|
|
10
|
+
}
|
|
11
|
+
parse(expression) {
|
|
12
|
+
this.tokens = [];
|
|
13
|
+
this.bytes = expression.split('');
|
|
14
|
+
while (this.current < this.bytes.length) {
|
|
15
|
+
this.parseToken();
|
|
16
|
+
}
|
|
17
|
+
return this.tokens;
|
|
18
|
+
}
|
|
19
|
+
parseToken() {
|
|
20
|
+
switch (this.bytes[this.current]) {
|
|
21
|
+
case ' ':
|
|
22
|
+
case '\n':
|
|
23
|
+
case '\r':
|
|
24
|
+
case '\t':
|
|
25
|
+
this.current++;
|
|
26
|
+
break;
|
|
27
|
+
case '(':
|
|
28
|
+
this.parseTokenMonocase(Token_1.TokenType.LEFT_PARENTHESES);
|
|
29
|
+
break;
|
|
30
|
+
case ')':
|
|
31
|
+
this.parseTokenMonocase(Token_1.TokenType.RIGHT_PARENTHESES);
|
|
32
|
+
break;
|
|
33
|
+
case '{':
|
|
34
|
+
this.parseTokenMonocase(Token_1.TokenType.LEFT_BRACE);
|
|
35
|
+
break;
|
|
36
|
+
case '}':
|
|
37
|
+
this.parseTokenMonocase(Token_1.TokenType.RIGHT_BRACE);
|
|
38
|
+
break;
|
|
39
|
+
case '#':
|
|
40
|
+
this.parseTokenMonocase(Token_1.TokenType.HASH);
|
|
41
|
+
break;
|
|
42
|
+
case ',':
|
|
43
|
+
this.parseTokenMonocase(Token_1.TokenType.COMMA);
|
|
44
|
+
break;
|
|
45
|
+
case ';':
|
|
46
|
+
this.parseTokenMonocase(Token_1.TokenType.SEMICOLON);
|
|
47
|
+
break;
|
|
48
|
+
case '@':
|
|
49
|
+
this.parseTokenExternalID();
|
|
50
|
+
break;
|
|
51
|
+
case 't':
|
|
52
|
+
this.parseTokenTrue();
|
|
53
|
+
break;
|
|
54
|
+
case 'f':
|
|
55
|
+
this.parseTokenFalse();
|
|
56
|
+
break;
|
|
57
|
+
case 'I':
|
|
58
|
+
this.parseTokenIF();
|
|
59
|
+
break;
|
|
60
|
+
case 'T':
|
|
61
|
+
this.parseTokenTHEN();
|
|
62
|
+
break;
|
|
63
|
+
case 'E':
|
|
64
|
+
this.parseTokenENDIF();
|
|
65
|
+
break;
|
|
66
|
+
case 'S':
|
|
67
|
+
this.parseTokenSLEEP();
|
|
68
|
+
break;
|
|
69
|
+
case 'R':
|
|
70
|
+
this.parseTokenREMIND_or_REVERSE();
|
|
71
|
+
break;
|
|
72
|
+
case 'A':
|
|
73
|
+
this.parseTokenAND_or_ANY_AUTOSCALING();
|
|
74
|
+
break;
|
|
75
|
+
case '"':
|
|
76
|
+
this.parseTokenString();
|
|
77
|
+
break;
|
|
78
|
+
case '-':
|
|
79
|
+
case '0':
|
|
80
|
+
case '1':
|
|
81
|
+
case '2':
|
|
82
|
+
case '3':
|
|
83
|
+
case '4':
|
|
84
|
+
case '5':
|
|
85
|
+
case '6':
|
|
86
|
+
case '7':
|
|
87
|
+
case '8':
|
|
88
|
+
case '9':
|
|
89
|
+
this.parseTokenNumber();
|
|
90
|
+
break;
|
|
91
|
+
case '&':
|
|
92
|
+
this.parseTokeAnd(); // &&
|
|
93
|
+
break;
|
|
94
|
+
case '|':
|
|
95
|
+
this.parseTokenOR(); // ||
|
|
96
|
+
break;
|
|
97
|
+
case '!':
|
|
98
|
+
this.parseTokenNOT_or_NOT_EQUAL(); // ! or !=
|
|
99
|
+
break;
|
|
100
|
+
case '=':
|
|
101
|
+
this.parseTokenEQUAL_or_ASSIGNMENT_or_OPERATE(); // ==, =>, =
|
|
102
|
+
break;
|
|
103
|
+
case '>':
|
|
104
|
+
this.parseTokenGreater_or_GE(); // > or >=
|
|
105
|
+
break;
|
|
106
|
+
case '<':
|
|
107
|
+
this.parseTokenLess_or_LE(); // < or <=
|
|
108
|
+
break;
|
|
109
|
+
default:
|
|
110
|
+
this.parseTokenID3();
|
|
111
|
+
break;
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
parseTokenMonocase(type) {
|
|
115
|
+
this.tokens.push(new Token_1.Token(type, this.current, 1, this.bytes));
|
|
116
|
+
this.current++;
|
|
117
|
+
}
|
|
118
|
+
parseTokenTrue() {
|
|
119
|
+
if (this.bytes[this.current] !== 't' || this.bytes[this.current + 1] !== 'r'
|
|
120
|
+
|| this.bytes[this.current + 2] !== 'u' || this.bytes[this.current + 3] !== 'e') {
|
|
121
|
+
this.parseTokenID3();
|
|
122
|
+
return;
|
|
123
|
+
}
|
|
124
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.TRUE, this.current, 4, this.bytes));
|
|
125
|
+
this.current += 4;
|
|
126
|
+
}
|
|
127
|
+
parseTokenFalse() {
|
|
128
|
+
if (this.bytes[this.current] !== 'f'
|
|
129
|
+
|| this.bytes[this.current + 1] !== 'a'
|
|
130
|
+
|| this.bytes[this.current + 2] !== 'l'
|
|
131
|
+
|| this.bytes[this.current + 3] !== 's'
|
|
132
|
+
|| this.bytes[this.current + 4] !== 'e') {
|
|
133
|
+
this.parseTokenID3();
|
|
134
|
+
return;
|
|
135
|
+
}
|
|
136
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.FALSE, this.current, 5, this.bytes));
|
|
137
|
+
this.current += 5;
|
|
138
|
+
}
|
|
139
|
+
parseTokenIF() {
|
|
140
|
+
if (this.bytes[this.current] !== 'I' || this.bytes[this.current + 1] !== 'F') {
|
|
141
|
+
this.parseTokenID3();
|
|
142
|
+
return;
|
|
143
|
+
}
|
|
144
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.KEY_IF, this.current, 2, this.bytes));
|
|
145
|
+
this.current += 2;
|
|
146
|
+
}
|
|
147
|
+
parseTokenTHEN() {
|
|
148
|
+
if (this.bytes[this.current] !== 'T'
|
|
149
|
+
|| this.bytes[this.current + 1] !== 'H'
|
|
150
|
+
|| this.bytes[this.current + 2] !== 'E'
|
|
151
|
+
|| this.bytes[this.current + 3] !== 'N') {
|
|
152
|
+
this.parseTokenID3();
|
|
153
|
+
return;
|
|
154
|
+
}
|
|
155
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.KEY_THEN, this.current, 4, this.bytes));
|
|
156
|
+
this.current += 4;
|
|
157
|
+
}
|
|
158
|
+
parseTokenENDIF() {
|
|
159
|
+
if (this.bytes[this.current] !== 'E'
|
|
160
|
+
|| this.bytes[this.current + 1] !== 'N'
|
|
161
|
+
|| this.bytes[this.current + 2] !== 'D'
|
|
162
|
+
|| this.bytes[this.current + 3] !== 'I'
|
|
163
|
+
|| this.bytes[this.current + 4] !== 'F') {
|
|
164
|
+
this.parseTokenID3();
|
|
165
|
+
return;
|
|
166
|
+
}
|
|
167
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.KEY_ENDIF, this.current, 5, this.bytes));
|
|
168
|
+
this.current += 5;
|
|
169
|
+
}
|
|
170
|
+
parseTokenSLEEP() {
|
|
171
|
+
if (this.bytes[this.current] !== 'S'
|
|
172
|
+
|| this.bytes[this.current + 1] !== 'L'
|
|
173
|
+
|| this.bytes[this.current + 2] !== 'E'
|
|
174
|
+
|| this.bytes[this.current + 3] !== 'E'
|
|
175
|
+
|| this.bytes[this.current + 4] !== 'P') {
|
|
176
|
+
this.parseTokenID3();
|
|
177
|
+
return;
|
|
178
|
+
}
|
|
179
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.KEY_SLEEP, this.current, 5, this.bytes));
|
|
180
|
+
this.current += 5;
|
|
181
|
+
}
|
|
182
|
+
parseTokenREMIND_or_REVERSE() {
|
|
183
|
+
if (this.bytes[this.current] !== 'R' || this.bytes[this.current + 1] !== 'E') {
|
|
184
|
+
this.parseTokenID3();
|
|
185
|
+
return;
|
|
186
|
+
}
|
|
187
|
+
// RE + MIND
|
|
188
|
+
if (this.bytes[this.current + 2] === 'M'
|
|
189
|
+
&& this.bytes[this.current + 3] === 'I'
|
|
190
|
+
&& this.bytes[this.current + 4] === 'N'
|
|
191
|
+
&& this.bytes[this.current + 5] === 'D') {
|
|
192
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.KEY_REMIND, this.current, 6, this.bytes));
|
|
193
|
+
this.current += 6;
|
|
194
|
+
return;
|
|
195
|
+
}
|
|
196
|
+
// RE + VERSE
|
|
197
|
+
if (this.bytes[this.current + 2] === 'V'
|
|
198
|
+
&& this.bytes[this.current + 3] === 'E'
|
|
199
|
+
&& this.bytes[this.current + 4] === 'R'
|
|
200
|
+
&& this.bytes[this.current + 5] === 'S'
|
|
201
|
+
&& this.bytes[this.current + 6] === 'E') {
|
|
202
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.KEY_REVERSE, this.current, 7, this.bytes));
|
|
203
|
+
this.current += 7;
|
|
204
|
+
return;
|
|
205
|
+
}
|
|
206
|
+
this.parseTokenID3();
|
|
207
|
+
}
|
|
208
|
+
parseTokenAND_or_ANY_AUTOSCALING() {
|
|
209
|
+
if (this.bytes[this.current] !== 'A') {
|
|
210
|
+
this.parseTokenID3();
|
|
211
|
+
return;
|
|
212
|
+
}
|
|
213
|
+
// A + ND
|
|
214
|
+
if (this.bytes[this.current + 1] === 'N' && this.bytes[this.current + 2] === 'D') {
|
|
215
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.KEY_AND, this.current, 3, this.bytes));
|
|
216
|
+
this.current += 3;
|
|
217
|
+
return;
|
|
218
|
+
}
|
|
219
|
+
// A + NY
|
|
220
|
+
if (this.bytes[this.current + 1] === 'N' && this.bytes[this.current + 2] === 'Y') {
|
|
221
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.KEY_ANY, this.current, 3, this.bytes));
|
|
222
|
+
this.current += 3;
|
|
223
|
+
return;
|
|
224
|
+
}
|
|
225
|
+
// A + UTOSCALING
|
|
226
|
+
if (this.bytes[this.current + 1] === 'U'
|
|
227
|
+
&& this.bytes[this.current + 2] === 'T'
|
|
228
|
+
&& this.bytes[this.current + 3] === 'O'
|
|
229
|
+
&& this.bytes[this.current + 4] === 'S'
|
|
230
|
+
&& this.bytes[this.current + 5] === 'C'
|
|
231
|
+
&& this.bytes[this.current + 6] === 'A'
|
|
232
|
+
&& this.bytes[this.current + 7] === 'L'
|
|
233
|
+
&& this.bytes[this.current + 8] === 'I'
|
|
234
|
+
&& this.bytes[this.current + 9] === 'N'
|
|
235
|
+
&& this.bytes[this.current + 10] === 'G') {
|
|
236
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.KEY_AUTOSCALING, this.current, 11, this.bytes));
|
|
237
|
+
this.current += 11;
|
|
238
|
+
return;
|
|
239
|
+
}
|
|
240
|
+
this.parseTokenID3();
|
|
241
|
+
}
|
|
242
|
+
parseTokenString() {
|
|
243
|
+
do {
|
|
244
|
+
// 去掉左引号"
|
|
245
|
+
const offset = this.current + 1;
|
|
246
|
+
this.current++;
|
|
247
|
+
while (true) {
|
|
248
|
+
let c = this.bytes[this.current];
|
|
249
|
+
if (c === '\\') {
|
|
250
|
+
c = this.bytes[this.current];
|
|
251
|
+
this.current++;
|
|
252
|
+
switch (c) {
|
|
253
|
+
case '"':
|
|
254
|
+
case '\\':
|
|
255
|
+
case '/':
|
|
256
|
+
case 'b':
|
|
257
|
+
case 'f':
|
|
258
|
+
case 'n':
|
|
259
|
+
case 'r':
|
|
260
|
+
case 't':
|
|
261
|
+
this.current++;
|
|
262
|
+
break;
|
|
263
|
+
case 'u':
|
|
264
|
+
this.current++;
|
|
265
|
+
if (this.is_hex(this.bytes[this.current]) &&
|
|
266
|
+
this.is_hex(this.bytes[this.current + 1]) &&
|
|
267
|
+
this.is_hex(this.bytes[this.current + 2]) &&
|
|
268
|
+
this.is_hex(this.bytes[this.current + 3])) {
|
|
269
|
+
this.current += 4;
|
|
270
|
+
}
|
|
271
|
+
else {
|
|
272
|
+
throw new Error(`String invalid, this.current:
|
|
273
|
+
${this.current} => ${this.bytes[this.current]}${this.bytes[this.current + 2]}${this.bytes[this.current + 3]}`);
|
|
274
|
+
}
|
|
275
|
+
break;
|
|
276
|
+
default:
|
|
277
|
+
throw new Error(`String invalid, this.current: ${this.current} => ${c}`);
|
|
278
|
+
}
|
|
279
|
+
}
|
|
280
|
+
else if (c === '"') {
|
|
281
|
+
this.current++;
|
|
282
|
+
break;
|
|
283
|
+
}
|
|
284
|
+
else if (this.is_print(c)) {
|
|
285
|
+
this.current++;
|
|
286
|
+
}
|
|
287
|
+
else {
|
|
288
|
+
throw new Error(`String invalid, this.current: ${this.current} => ${c}`);
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
// 去掉右引号, length - 1
|
|
292
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.STRING, offset, this.current - offset - 1, this.bytes));
|
|
293
|
+
} while (false);
|
|
294
|
+
}
|
|
295
|
+
parseTokenNumber() {
|
|
296
|
+
do {
|
|
297
|
+
const offset = this.current;
|
|
298
|
+
let c = this.bytes[this.current];
|
|
299
|
+
do {
|
|
300
|
+
if (c === '-') {
|
|
301
|
+
this.current++;
|
|
302
|
+
}
|
|
303
|
+
if (this.current >= this.bytes.length) {
|
|
304
|
+
throw new Error(`Number invalid, this.current: ${this.current} => ${c}`);
|
|
305
|
+
}
|
|
306
|
+
c = this.bytes[this.current];
|
|
307
|
+
if (c === '0') {
|
|
308
|
+
this.current++;
|
|
309
|
+
}
|
|
310
|
+
else if (c >= '1' && c <= '9') {
|
|
311
|
+
this.current++;
|
|
312
|
+
while (this.current < this.bytes.length) {
|
|
313
|
+
c = this.bytes[this.current];
|
|
314
|
+
if (!/^\d$/.test(c)) {
|
|
315
|
+
break;
|
|
316
|
+
}
|
|
317
|
+
this.current++;
|
|
318
|
+
}
|
|
319
|
+
}
|
|
320
|
+
else {
|
|
321
|
+
throw new Error(`Number invalid, this.current: ${this.current} => ${c}`);
|
|
322
|
+
}
|
|
323
|
+
if (this.current >= this.bytes.length) {
|
|
324
|
+
break;
|
|
325
|
+
}
|
|
326
|
+
c = this.bytes[this.current];
|
|
327
|
+
if (c === '.') {
|
|
328
|
+
this.current++;
|
|
329
|
+
while (this.current < this.bytes.length) {
|
|
330
|
+
c = this.bytes[this.current];
|
|
331
|
+
if (!/^\d$/.test(c)) {
|
|
332
|
+
break;
|
|
333
|
+
}
|
|
334
|
+
this.current++;
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
if (this.current >= this.bytes.length) {
|
|
338
|
+
break;
|
|
339
|
+
}
|
|
340
|
+
if (c === ' '
|
|
341
|
+
|| c === '\r'
|
|
342
|
+
|| c === '\n'
|
|
343
|
+
|| c === '\t'
|
|
344
|
+
|| c === '}'
|
|
345
|
+
|| c === ']'
|
|
346
|
+
|| c === ','
|
|
347
|
+
|| c === ')'
|
|
348
|
+
|| c === '='
|
|
349
|
+
|| c === ';') {
|
|
350
|
+
break;
|
|
351
|
+
}
|
|
352
|
+
else {
|
|
353
|
+
// 123456.1.1 结构,不应该识别为浮点数,应该尝试用ID的方式去识别
|
|
354
|
+
this.current = offset;
|
|
355
|
+
this.parseTokenID3();
|
|
356
|
+
return;
|
|
357
|
+
}
|
|
358
|
+
} while (false);
|
|
359
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.NUMBER, offset, this.current - offset, this.bytes));
|
|
360
|
+
} while (false);
|
|
361
|
+
}
|
|
362
|
+
parseTokeAnd() {
|
|
363
|
+
// &&
|
|
364
|
+
if (this.bytes[this.current + 1] !== '&') {
|
|
365
|
+
throw new Error(`AND operator invalid: ${this.bytes[this.current]}${this.bytes[this.current + 1]}`);
|
|
366
|
+
}
|
|
367
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.OP_AND, this.current, 2, this.bytes));
|
|
368
|
+
this.current += 2;
|
|
369
|
+
}
|
|
370
|
+
parseTokenOR() {
|
|
371
|
+
// ||
|
|
372
|
+
if (this.bytes[this.current + 1] !== '|') {
|
|
373
|
+
throw new Error(`OR operator invalid: ${this.bytes[this.current]}${this.bytes[this.current + 1]}`);
|
|
374
|
+
}
|
|
375
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.OP_OR, this.current, 2, this.bytes));
|
|
376
|
+
this.current += 2;
|
|
377
|
+
}
|
|
378
|
+
parseTokenNOT_or_NOT_EQUAL() {
|
|
379
|
+
// !=
|
|
380
|
+
if (this.bytes[this.current + 1] !== '=') {
|
|
381
|
+
throw new Error(`!= operator invalid: ${this.bytes[this.current]}${this.bytes[this.current + 1]}`);
|
|
382
|
+
}
|
|
383
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.OP_NOT_EQUAL, this.current, 2, this.bytes));
|
|
384
|
+
this.current += 2;
|
|
385
|
+
}
|
|
386
|
+
//
|
|
387
|
+
parseTokenEQUAL_or_ASSIGNMENT_or_OPERATE() {
|
|
388
|
+
// ==
|
|
389
|
+
if (this.bytes[this.current + 1] === '=') {
|
|
390
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.OP_EQUAL, this.current, 2, this.bytes));
|
|
391
|
+
this.current += 2;
|
|
392
|
+
return;
|
|
393
|
+
}
|
|
394
|
+
if (this.bytes[this.current + 1] === '>') {
|
|
395
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.OPERATE, this.current, 2, this.bytes));
|
|
396
|
+
this.current += 2;
|
|
397
|
+
return;
|
|
398
|
+
}
|
|
399
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.ASSIGNMENT, this.current, 1, this.bytes));
|
|
400
|
+
this.current += 1;
|
|
401
|
+
}
|
|
402
|
+
parseTokenGreater_or_GE() {
|
|
403
|
+
// >=
|
|
404
|
+
if (this.bytes[this.current + 1] === '=') {
|
|
405
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.OP_GREATER_OR_EQUAL, this.current, 2, this.bytes));
|
|
406
|
+
this.current += 2;
|
|
407
|
+
}
|
|
408
|
+
else {
|
|
409
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.OP_GREATER, this.current, 1, this.bytes));
|
|
410
|
+
this.current++;
|
|
411
|
+
}
|
|
412
|
+
}
|
|
413
|
+
parseTokenLess_or_LE() {
|
|
414
|
+
// <=
|
|
415
|
+
if (this.bytes[this.current + 1] === '=') {
|
|
416
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.OP_LESS_OR_EQUAL, this.current, 2, this.bytes));
|
|
417
|
+
this.current += 2;
|
|
418
|
+
}
|
|
419
|
+
else {
|
|
420
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.OP_LESS, this.current, 1, this.bytes));
|
|
421
|
+
this.current++;
|
|
422
|
+
}
|
|
423
|
+
}
|
|
424
|
+
parseTokenExternalID() {
|
|
425
|
+
do {
|
|
426
|
+
let offset = this.current;
|
|
427
|
+
while (true) {
|
|
428
|
+
const c = this.bytes[this.current];
|
|
429
|
+
if (c === ' ' || c === '=' || c === '<' || c === '>' || c === '!' || c === ')' || c === ';' || c === '\n' || c === '\r') {
|
|
430
|
+
break;
|
|
431
|
+
}
|
|
432
|
+
if ((c >= 'a' && c <= 'z')
|
|
433
|
+
|| (c >= 'A' && c <= 'Z')
|
|
434
|
+
|| (c >= '0' && c <= '9')
|
|
435
|
+
|| c === '@'
|
|
436
|
+
|| c === '-'
|
|
437
|
+
|| c === '.') {
|
|
438
|
+
this.current++;
|
|
439
|
+
}
|
|
440
|
+
else {
|
|
441
|
+
throw new Error(`external ID invalid, ID: ${this.current} => ${c}`);
|
|
442
|
+
}
|
|
443
|
+
}
|
|
444
|
+
// skip '@'
|
|
445
|
+
if ((this.current - offset) > 0) {
|
|
446
|
+
offset++;
|
|
447
|
+
}
|
|
448
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.EXID, offset, this.current - offset, this.bytes));
|
|
449
|
+
} while (false);
|
|
450
|
+
}
|
|
451
|
+
parseTokenID3() {
|
|
452
|
+
do {
|
|
453
|
+
const offset = this.current;
|
|
454
|
+
while (true) {
|
|
455
|
+
const c = this.bytes[this.current];
|
|
456
|
+
if (c === ' ' || c === '=' || c === '<' || c === '>' || c === '!' || c === ')') {
|
|
457
|
+
break;
|
|
458
|
+
}
|
|
459
|
+
if ((c >= 'a' && c <= 'z')
|
|
460
|
+
|| (c >= 'A' && c <= 'Z')
|
|
461
|
+
|| (c >= '0' && c <= '9')
|
|
462
|
+
|| c === '@'
|
|
463
|
+
|| c === '-'
|
|
464
|
+
|| c === '.') {
|
|
465
|
+
this.current++;
|
|
466
|
+
}
|
|
467
|
+
else {
|
|
468
|
+
throw new Error(`ID invalid, ID: ${this.current} => ${c}`);
|
|
469
|
+
}
|
|
470
|
+
}
|
|
471
|
+
this.tokens.push(new Token_1.Token(Token_1.TokenType.XID3, offset, this.current - offset, this.bytes));
|
|
472
|
+
} while (false);
|
|
473
|
+
}
|
|
474
|
+
is_hex(c) {
|
|
475
|
+
return (c >= '0' && c <= '9') || (c >= 'a' && c <= 'f') || (c >= 'A' && c <= 'F');
|
|
476
|
+
}
|
|
477
|
+
is_print(b) {
|
|
478
|
+
return /^[0-9a-zA-Z]*$/.test(b)
|
|
479
|
+
|| /\s*/.test(b) || /\n*/.test(b)
|
|
480
|
+
|| b === '*' || b === ',' || b === '?' || b === '-' || b === ':';
|
|
481
|
+
}
|
|
482
|
+
}
|
|
483
|
+
exports.Tokenizer = Tokenizer;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Shadow = void 0;
|
|
4
|
+
class Shadow {
|
|
5
|
+
constructor() {
|
|
6
|
+
this.siid = 0;
|
|
7
|
+
this.piid = 0;
|
|
8
|
+
this.value = {};
|
|
9
|
+
this.status = 0;
|
|
10
|
+
this.description = '';
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
exports.Shadow = Shadow;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Where } from "./Where";
|
|
2
|
+
export declare class Somewhere {
|
|
3
|
+
where: Where;
|
|
4
|
+
spaceId: string;
|
|
5
|
+
index: number;
|
|
6
|
+
local(): boolean;
|
|
7
|
+
cloud(): boolean;
|
|
8
|
+
protected changeWhere(where: Where): boolean;
|
|
9
|
+
protected changeSpaceId(spaceId: string): boolean;
|
|
10
|
+
protected changeIndex(index: number): boolean;
|
|
11
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Somewhere = void 0;
|
|
4
|
+
const Where_1 = require("./Where");
|
|
5
|
+
class Somewhere {
|
|
6
|
+
constructor() {
|
|
7
|
+
this.where = Where_1.Where.UNKNOWN;
|
|
8
|
+
this.spaceId = '';
|
|
9
|
+
this.index = 0;
|
|
10
|
+
}
|
|
11
|
+
local() {
|
|
12
|
+
if (this.where != null) {
|
|
13
|
+
return this.where == Where_1.Where.LOCAL || this.where == Where_1.Where.LOCAL_AND_CLOUD;
|
|
14
|
+
}
|
|
15
|
+
return false;
|
|
16
|
+
}
|
|
17
|
+
cloud() {
|
|
18
|
+
if (this.where != null) {
|
|
19
|
+
return this.where == Where_1.Where.CLOUD || this.where == Where_1.Where.LOCAL_AND_CLOUD;
|
|
20
|
+
}
|
|
21
|
+
return false;
|
|
22
|
+
}
|
|
23
|
+
changeWhere(where) {
|
|
24
|
+
if (this.where === where) {
|
|
25
|
+
return false;
|
|
26
|
+
}
|
|
27
|
+
this.where = where;
|
|
28
|
+
return true;
|
|
29
|
+
}
|
|
30
|
+
changeSpaceId(spaceId) {
|
|
31
|
+
if (this.spaceId === spaceId) {
|
|
32
|
+
return false;
|
|
33
|
+
}
|
|
34
|
+
this.spaceId = spaceId;
|
|
35
|
+
return true;
|
|
36
|
+
}
|
|
37
|
+
changeIndex(index) {
|
|
38
|
+
if (this.index === index) {
|
|
39
|
+
return false;
|
|
40
|
+
}
|
|
41
|
+
this.index = index;
|
|
42
|
+
return true;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
exports.Somewhere = Somewhere;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare enum Where {
|
|
2
|
+
UNKNOWN = "unknown",
|
|
3
|
+
LOCAL = "local",
|
|
4
|
+
CLUSTER = "cluster",
|
|
5
|
+
CLOUD = "cloud",
|
|
6
|
+
LOCAL_AND_CLOUD = "local-and-cloud"
|
|
7
|
+
}
|
|
8
|
+
export declare function WhereToString(x: Where): string;
|
|
9
|
+
export declare function WhereFromString(type: string): Where;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Where = void 0;
|
|
4
|
+
exports.WhereToString = WhereToString;
|
|
5
|
+
exports.WhereFromString = WhereFromString;
|
|
6
|
+
var Where;
|
|
7
|
+
(function (Where) {
|
|
8
|
+
Where["UNKNOWN"] = "unknown";
|
|
9
|
+
Where["LOCAL"] = "local";
|
|
10
|
+
Where["CLUSTER"] = "cluster";
|
|
11
|
+
Where["CLOUD"] = "cloud";
|
|
12
|
+
Where["LOCAL_AND_CLOUD"] = "local-and-cloud";
|
|
13
|
+
})(Where || (exports.Where = Where = {}));
|
|
14
|
+
function WhereToString(x) {
|
|
15
|
+
return x.toString();
|
|
16
|
+
}
|
|
17
|
+
function WhereFromString(type) {
|
|
18
|
+
const keys = Object.keys(Where);
|
|
19
|
+
for (const key of keys) {
|
|
20
|
+
const s = WhereToString(Where[key]);
|
|
21
|
+
if (s === type) {
|
|
22
|
+
return Where[key];
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
return Where.UNKNOWN;
|
|
26
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Space = void 0;
|
|
4
|
+
class Space {
|
|
5
|
+
constructor(id) {
|
|
6
|
+
this.id = '';
|
|
7
|
+
this.name = '';
|
|
8
|
+
this.rootId = null;
|
|
9
|
+
this.parentId = null;
|
|
10
|
+
this.index = 0;
|
|
11
|
+
this.id = id;
|
|
12
|
+
}
|
|
13
|
+
isRoot() {
|
|
14
|
+
if (this.rootId !== null) {
|
|
15
|
+
return this.rootId === this.id;
|
|
16
|
+
}
|
|
17
|
+
return this.parentId === null;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
exports.Space = Space;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AbstractStatus = void 0;
|
|
4
|
+
const Status_1 = require("./Status");
|
|
5
|
+
class AbstractStatus {
|
|
6
|
+
constructor() {
|
|
7
|
+
this.status = Status_1.Status.COMPLETED;
|
|
8
|
+
this.description = '';
|
|
9
|
+
}
|
|
10
|
+
isError() {
|
|
11
|
+
return (this.status < 0);
|
|
12
|
+
}
|
|
13
|
+
isNotError() {
|
|
14
|
+
return (this.status >= 0);
|
|
15
|
+
}
|
|
16
|
+
isCompleted() {
|
|
17
|
+
return (this.status == 0);
|
|
18
|
+
}
|
|
19
|
+
isNotCompleted() {
|
|
20
|
+
return (this.status == Status_1.Status.TO_BE_EXECUTE);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
exports.AbstractStatus = AbstractStatus;
|