@thisisagile/easy 15.26.1 → 15.27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunk-35PSIDGU.mjs +17 -0
- package/dist/chunk-35PSIDGU.mjs.map +1 -0
- package/dist/chunk-3HTSHJPL.mjs +26 -0
- package/dist/chunk-3HTSHJPL.mjs.map +1 -0
- package/dist/chunk-3WOYFN2Q.mjs +18 -0
- package/dist/chunk-3WOYFN2Q.mjs.map +1 -0
- package/dist/chunk-4AP5H3OQ.mjs +46 -0
- package/dist/chunk-4AP5H3OQ.mjs.map +1 -0
- package/dist/chunk-4EVQZKMK.mjs +15 -0
- package/dist/chunk-4EVQZKMK.mjs.map +1 -0
- package/dist/chunk-4QX4EMLL.mjs +13 -0
- package/dist/chunk-4QX4EMLL.mjs.map +1 -0
- package/dist/chunk-5AF55QCJ.mjs +51 -0
- package/dist/chunk-5AF55QCJ.mjs.map +1 -0
- package/dist/chunk-6NOTDYUE.mjs +272 -0
- package/dist/chunk-6NOTDYUE.mjs.map +1 -0
- package/dist/chunk-6OW7KEN5.mjs +94 -0
- package/dist/chunk-6OW7KEN5.mjs.map +1 -0
- package/dist/chunk-74AOBBOZ.mjs +113 -0
- package/dist/chunk-74AOBBOZ.mjs.map +1 -0
- package/dist/chunk-7EP6VCI3.mjs +60 -0
- package/dist/chunk-7EP6VCI3.mjs.map +1 -0
- package/dist/{types/PageList.js → chunk-7NYZAGM3.mjs} +31 -48
- package/dist/chunk-7NYZAGM3.mjs.map +1 -0
- package/dist/chunk-7RIXMU5L.mjs +50 -0
- package/dist/chunk-7RIXMU5L.mjs.map +1 -0
- package/dist/chunk-A7OYYR2S.mjs +48 -0
- package/dist/chunk-A7OYYR2S.mjs.map +1 -0
- package/dist/chunk-ADJAEGCT.mjs +21 -0
- package/dist/chunk-ADJAEGCT.mjs.map +1 -0
- package/dist/chunk-AKYA7FHU.mjs +15 -0
- package/dist/chunk-AKYA7FHU.mjs.map +1 -0
- package/dist/chunk-CLKUH5JA.mjs +42 -0
- package/dist/chunk-CLKUH5JA.mjs.map +1 -0
- package/dist/chunk-CMRS457E.mjs +11 -0
- package/dist/chunk-CMRS457E.mjs.map +1 -0
- package/dist/chunk-D54TPU6G.mjs +43 -0
- package/dist/chunk-D54TPU6G.mjs.map +1 -0
- package/dist/chunk-DICMUQFL.mjs +11 -0
- package/dist/chunk-DICMUQFL.mjs.map +1 -0
- package/dist/chunk-EZC3HAYN.mjs +70 -0
- package/dist/chunk-EZC3HAYN.mjs.map +1 -0
- package/dist/chunk-FAAERRP2.mjs +37 -0
- package/dist/chunk-FAAERRP2.mjs.map +1 -0
- package/dist/chunk-FSK4W6I2.mjs +33 -0
- package/dist/chunk-FSK4W6I2.mjs.map +1 -0
- package/dist/chunk-G7QSW2EB.mjs +23 -0
- package/dist/chunk-G7QSW2EB.mjs.map +1 -0
- package/dist/chunk-GDD652NR.mjs +94 -0
- package/dist/chunk-GDD652NR.mjs.map +1 -0
- package/dist/chunk-GGC4TWMF.mjs +40 -0
- package/dist/chunk-GGC4TWMF.mjs.map +1 -0
- package/dist/chunk-GI5TZOAG.mjs +30 -0
- package/dist/chunk-GI5TZOAG.mjs.map +1 -0
- package/dist/chunk-GVX6S54O.mjs +54 -0
- package/dist/chunk-GVX6S54O.mjs.map +1 -0
- package/dist/chunk-H22IHXDC.mjs +23 -0
- package/dist/chunk-H22IHXDC.mjs.map +1 -0
- package/dist/chunk-H6GKGVYF.mjs +18 -0
- package/dist/chunk-H6GKGVYF.mjs.map +1 -0
- package/dist/chunk-HNB4RM5S.mjs +89 -0
- package/dist/chunk-HNB4RM5S.mjs.map +1 -0
- package/dist/chunk-I3VZW3XF.mjs +46 -0
- package/dist/chunk-I3VZW3XF.mjs.map +1 -0
- package/dist/chunk-IJFQ7PRU.mjs +19 -0
- package/dist/chunk-IJFQ7PRU.mjs.map +1 -0
- package/dist/chunk-JER7KLEK.mjs +82 -0
- package/dist/chunk-JER7KLEK.mjs.map +1 -0
- package/dist/chunk-JXJ5LRH3.mjs +30 -0
- package/dist/chunk-JXJ5LRH3.mjs.map +1 -0
- package/dist/chunk-L2BMMXCX.mjs +79 -0
- package/dist/chunk-L2BMMXCX.mjs.map +1 -0
- package/dist/chunk-LB7OMB5S.mjs +57 -0
- package/dist/chunk-LB7OMB5S.mjs.map +1 -0
- package/dist/chunk-LCDQWW2Y.mjs +18 -0
- package/dist/chunk-LCDQWW2Y.mjs.map +1 -0
- package/dist/chunk-LD64IICE.mjs +28 -0
- package/dist/chunk-LD64IICE.mjs.map +1 -0
- package/dist/chunk-LV7HNQ3N.mjs +183 -0
- package/dist/chunk-LV7HNQ3N.mjs.map +1 -0
- package/dist/chunk-M4UUIOW6.mjs +86 -0
- package/dist/chunk-M4UUIOW6.mjs.map +1 -0
- package/dist/chunk-MDLVDMKY.mjs +11 -0
- package/dist/chunk-MDLVDMKY.mjs.map +1 -0
- package/dist/chunk-NF7FTEE7.mjs +26 -0
- package/dist/chunk-NF7FTEE7.mjs.map +1 -0
- package/dist/chunk-NYTGMBLK.mjs +49 -0
- package/dist/chunk-NYTGMBLK.mjs.map +1 -0
- package/dist/chunk-O62PGEQ7.mjs +20 -0
- package/dist/chunk-O62PGEQ7.mjs.map +1 -0
- package/dist/chunk-OQNZEKWO.mjs +24 -0
- package/dist/chunk-OQNZEKWO.mjs.map +1 -0
- package/dist/chunk-OXBQSJDF.mjs +45 -0
- package/dist/chunk-OXBQSJDF.mjs.map +1 -0
- package/dist/chunk-PIRWVOO2.mjs +7 -0
- package/dist/chunk-PIRWVOO2.mjs.map +1 -0
- package/dist/chunk-PLIJ2CRV.mjs +25 -0
- package/dist/chunk-PLIJ2CRV.mjs.map +1 -0
- package/dist/chunk-PSIJUWZT.mjs +13 -0
- package/dist/chunk-PSIJUWZT.mjs.map +1 -0
- package/dist/chunk-QOGUHAMC.mjs +40 -0
- package/dist/chunk-QOGUHAMC.mjs.map +1 -0
- package/dist/chunk-SGSU4KYT.mjs +49 -0
- package/dist/chunk-SGSU4KYT.mjs.map +1 -0
- package/dist/chunk-SJGDB24D.mjs +41 -0
- package/dist/chunk-SJGDB24D.mjs.map +1 -0
- package/dist/chunk-SJGQU3OG.mjs +15 -0
- package/dist/chunk-SJGQU3OG.mjs.map +1 -0
- package/dist/chunk-SP4KAT3N.mjs +25 -0
- package/dist/chunk-SP4KAT3N.mjs.map +1 -0
- package/dist/chunk-SS3C77DP.mjs +134 -0
- package/dist/chunk-SS3C77DP.mjs.map +1 -0
- package/dist/chunk-SW2OCUH3.mjs +10 -0
- package/dist/chunk-SW2OCUH3.mjs.map +1 -0
- package/dist/chunk-UDLMLGTS.mjs +43 -0
- package/dist/chunk-UDLMLGTS.mjs.map +1 -0
- package/dist/chunk-V62IOKST.mjs +21 -0
- package/dist/chunk-V62IOKST.mjs.map +1 -0
- package/dist/chunk-WEXSGVXZ.mjs +53 -0
- package/dist/chunk-WEXSGVXZ.mjs.map +1 -0
- package/dist/chunk-WUFQM7VZ.mjs +20 -0
- package/dist/chunk-WUFQM7VZ.mjs.map +1 -0
- package/dist/chunk-YTWFWQNB.mjs +866 -0
- package/dist/chunk-YTWFWQNB.mjs.map +1 -0
- package/dist/chunk-ZHAJLP7P.mjs +49 -0
- package/dist/chunk-ZHAJLP7P.mjs.map +1 -0
- package/dist/chunk-ZNWOAXMK.mjs +46 -0
- package/dist/chunk-ZNWOAXMK.mjs.map +1 -0
- package/dist/data/Condition.mjs +19 -35
- package/dist/data/Condition.mjs.map +1 -1
- package/dist/data/Database.mjs +15 -12
- package/dist/data/Database.mjs.map +1 -1
- package/dist/data/Field.mjs +28 -6
- package/dist/data/Field.mjs.map +1 -1
- package/dist/data/InMemoryGateway.mjs +26 -4
- package/dist/data/InMemoryGateway.mjs.map +1 -1
- package/dist/domain/Audit.mjs +18 -24
- package/dist/domain/Audit.mjs.map +1 -1
- package/dist/domain/Child.mjs +28 -5
- package/dist/domain/Child.mjs.map +1 -1
- package/dist/domain/Entity.mjs +32 -6
- package/dist/domain/Entity.mjs.map +1 -1
- package/dist/domain/Repo.mjs +28 -5
- package/dist/domain/Repo.mjs.map +1 -1
- package/dist/domain/Struct.mjs +15 -25
- package/dist/domain/Struct.mjs.map +1 -1
- package/dist/domain/Typo.mjs +21 -4
- package/dist/domain/Typo.mjs.map +1 -1
- package/dist/domain/enums/Country.mjs +14 -262
- package/dist/domain/enums/Country.mjs.map +1 -1
- package/dist/domain/enums/Currency.mjs +17 -131
- package/dist/domain/enums/Currency.mjs.map +1 -1
- package/dist/domain/enums/Environment.mjs +21 -7
- package/dist/domain/enums/Environment.mjs.map +1 -1
- package/dist/domain/enums/Locale.mjs +581 -566
- package/dist/domain/enums/Locale.mjs.map +1 -1
- package/dist/domain/enums/UnitOfMeasurement.mjs +14 -12
- package/dist/domain/enums/UnitOfMeasurement.mjs.map +1 -1
- package/dist/domain/enums/UnitOfWeight.mjs +14 -10
- package/dist/domain/enums/UnitOfWeight.mjs.map +1 -1
- package/dist/domain/structs/Address.mjs +34 -8
- package/dist/domain/structs/Address.mjs.map +1 -1
- package/dist/domain/structs/Box.mjs +26 -5
- package/dist/domain/structs/Box.mjs.map +1 -1
- package/dist/domain/structs/Dimension.mjs +18 -26
- package/dist/domain/structs/Dimension.mjs.map +1 -1
- package/dist/domain/structs/Money.mjs +19 -32
- package/dist/domain/structs/Money.mjs.map +1 -1
- package/dist/domain/structs/Name.mjs +25 -6
- package/dist/domain/structs/Name.mjs.map +1 -1
- package/dist/domain/structs/Weight.mjs +26 -6
- package/dist/domain/structs/Weight.mjs.map +1 -1
- package/dist/domain/values/DateTime.mjs +17 -88
- package/dist/domain/values/DateTime.mjs.map +1 -1
- package/dist/domain/values/EAN.mjs +21 -4
- package/dist/domain/values/EAN.mjs.map +1 -1
- package/dist/domain/values/Email.mjs +23 -5
- package/dist/domain/values/Email.mjs.map +1 -1
- package/dist/domain/values/IBAN.mjs +21 -4
- package/dist/domain/values/IBAN.mjs.map +1 -1
- package/dist/domain/values/PostalCode.mjs +16 -13
- package/dist/domain/values/PostalCode.mjs.map +1 -1
- package/dist/domain/values/Slug.mjs +21 -4
- package/dist/domain/values/Slug.mjs.map +1 -1
- package/dist/domain/values/Url.mjs +22 -5
- package/dist/domain/values/Url.mjs.map +1 -1
- package/dist/health/HealthResource.mjs +32 -4
- package/dist/health/HealthResource.mjs.map +1 -1
- package/dist/health/HealthUri.mjs +15 -5
- package/dist/health/HealthUri.mjs.map +1 -1
- package/dist/http/CacheControl.mjs +16 -28
- package/dist/http/CacheControl.mjs.map +1 -1
- package/dist/http/ContentType.mjs +14 -15
- package/dist/http/ContentType.mjs.map +1 -1
- package/dist/http/HttpHeader.mjs +3 -4
- package/dist/http/HttpHeader.mjs.map +1 -1
- package/dist/http/HttpStatus.mjs +16 -80
- package/dist/http/HttpStatus.mjs.map +1 -1
- package/dist/http/HttpVerb.mjs +14 -11
- package/dist/http/HttpVerb.mjs.map +1 -1
- package/dist/http/LocalRequestStore.mjs +17 -3
- package/dist/http/LocalRequestStore.mjs.map +1 -1
- package/dist/http/OriginatedError.mjs +9 -5
- package/dist/http/OriginatedError.mjs.map +1 -1
- package/dist/http/RequestOptions.mjs +19 -59
- package/dist/http/RequestOptions.mjs.map +1 -1
- package/dist/http/Response.mjs +16 -9
- package/dist/http/Response.mjs.map +1 -1
- package/dist/http/RestResult.mjs +16 -26
- package/dist/http/RestResult.mjs.map +1 -1
- package/dist/http/Verb.mjs +27 -19
- package/dist/http/Verb.mjs.map +1 -1
- package/dist/index.js +4790 -27
- package/dist/index.js.map +1 -1
- package/dist/process/App.mjs +19 -4
- package/dist/process/App.mjs.map +1 -1
- package/dist/process/Manage.mjs +19 -3
- package/dist/process/Manage.mjs.map +1 -1
- package/dist/process/Scope.mjs +14 -18
- package/dist/process/Scope.mjs.map +1 -1
- package/dist/process/Search.mjs +15 -34
- package/dist/process/Search.mjs.map +1 -1
- package/dist/process/UseCase.mjs +24 -4
- package/dist/process/UseCase.mjs.map +1 -1
- package/dist/resources/Req.mjs +20 -4
- package/dist/resources/Req.mjs.map +1 -1
- package/dist/resources/Requires.mjs +18 -4
- package/dist/resources/Requires.mjs.map +1 -1
- package/dist/resources/Route.mjs +15 -32
- package/dist/resources/Route.mjs.map +1 -1
- package/dist/resources/Service.mjs +19 -3
- package/dist/resources/Service.mjs.map +1 -1
- package/dist/security/Jwt.mjs +21 -5
- package/dist/security/Jwt.mjs.map +1 -1
- package/dist/services/Api.mjs +25 -63
- package/dist/services/Api.mjs.map +1 -1
- package/dist/services/ApiGateway.mjs +27 -29
- package/dist/services/ApiGateway.mjs.map +1 -1
- package/dist/services/AxiosProvider.mjs +22 -23
- package/dist/services/AxiosProvider.mjs.map +1 -1
- package/dist/services/MappedRouteGateway.mjs +40 -5
- package/dist/services/MappedRouteGateway.mjs.map +1 -1
- package/dist/services/RouteGateway.mjs +28 -42
- package/dist/services/RouteGateway.mjs.map +1 -1
- package/dist/services/ViewRouteGateway.mjs +39 -5
- package/dist/services/ViewRouteGateway.mjs.map +1 -1
- package/dist/sql/Clause.mjs +19 -22
- package/dist/sql/Clause.mjs.map +1 -1
- package/dist/sql/Column.mjs +19 -64
- package/dist/sql/Column.mjs.map +1 -1
- package/dist/sql/Count.mjs +16 -7
- package/dist/sql/Count.mjs.map +1 -1
- package/dist/sql/Delete.mjs +15 -7
- package/dist/sql/Delete.mjs.map +1 -1
- package/dist/sql/Insert.mjs +17 -12
- package/dist/sql/Insert.mjs.map +1 -1
- package/dist/sql/Join.mjs +3 -18
- package/dist/sql/Join.mjs.map +1 -1
- package/dist/sql/Select.mjs +15 -40
- package/dist/sql/Select.mjs.map +1 -1
- package/dist/sql/SqlQuery.mjs +14 -11
- package/dist/sql/SqlQuery.mjs.map +1 -1
- package/dist/sql/Table.mjs +53 -12
- package/dist/sql/Table.mjs.map +1 -1
- package/dist/sql/TableGateway.mjs +27 -5
- package/dist/sql/TableGateway.mjs.map +1 -1
- package/dist/sql/Update.mjs +17 -13
- package/dist/sql/Update.mjs.map +1 -1
- package/dist/types/Array.mjs +9 -22
- package/dist/types/Array.mjs.map +1 -1
- package/dist/types/Builder.mjs +21 -7
- package/dist/types/Builder.mjs.map +1 -1
- package/dist/types/Cache.mjs +17 -3
- package/dist/types/Cache.mjs.map +1 -1
- package/dist/types/CacheAge.mjs +15 -36
- package/dist/types/CacheAge.mjs.map +1 -1
- package/dist/types/Case.mjs +13 -87
- package/dist/types/Case.mjs.map +1 -1
- package/dist/types/Constructor.mjs +11 -12
- package/dist/types/Constructor.mjs.map +1 -1
- package/dist/types/Context.mjs +17 -81
- package/dist/types/Context.mjs.map +1 -1
- package/dist/types/Enum.mjs +14 -46
- package/dist/types/Enum.mjs.map +1 -1
- package/dist/types/Exception.mjs +15 -22
- package/dist/types/Exception.mjs.map +1 -1
- package/dist/types/Falsy.mjs +4 -2
- package/dist/types/Falsy.mjs.map +1 -1
- package/dist/types/Func.mjs +3 -1
- package/dist/types/Func.mjs.map +1 -1
- package/dist/types/Gateway.mjs +14 -34
- package/dist/types/Gateway.mjs.map +1 -1
- package/dist/types/Get.mjs +6 -4
- package/dist/types/Get.mjs.map +1 -1
- package/dist/types/Id.mjs +5 -2
- package/dist/types/Id.mjs.map +1 -1
- package/dist/types/Is.mjs +21 -21
- package/dist/types/Is.mjs.map +1 -1
- package/dist/types/IsA.mjs +6 -3
- package/dist/types/IsA.mjs.map +1 -1
- package/dist/types/IsDate.mjs +6 -12
- package/dist/types/IsDate.mjs.map +1 -1
- package/dist/types/IsEqual.mjs +14 -11
- package/dist/types/IsEqual.mjs.map +1 -1
- package/dist/types/Json.mjs +14 -31
- package/dist/types/Json.mjs.map +1 -1
- package/dist/types/List.mjs +18 -170
- package/dist/types/List.mjs.map +1 -1
- package/dist/types/Message.mjs +6 -2
- package/dist/types/Message.mjs.map +1 -1
- package/dist/types/Meta.mjs +14 -41
- package/dist/types/Meta.mjs.map +1 -1
- package/dist/types/Nullish.mjs +3 -1
- package/dist/types/Nullish.mjs.map +1 -1
- package/dist/types/Number.mjs +14 -5
- package/dist/types/Number.mjs.map +1 -1
- package/dist/types/PageList.mjs +19 -118
- package/dist/types/PageList.mjs.map +1 -1
- package/dist/types/Parser.mjs +30 -7
- package/dist/types/Parser.mjs.map +1 -1
- package/dist/types/Primitive.mjs +4 -4
- package/dist/types/Primitive.mjs.map +1 -1
- package/dist/types/Repository.mjs +14 -40
- package/dist/types/Repository.mjs.map +1 -1
- package/dist/types/Result.mjs +14 -8
- package/dist/types/Result.mjs.map +1 -1
- package/dist/types/Results.mjs +15 -19
- package/dist/types/Results.mjs.map +1 -1
- package/dist/types/Sort.mjs +4 -2
- package/dist/types/Sort.mjs.map +1 -1
- package/dist/types/Tag.mjs +17 -3
- package/dist/types/Tag.mjs.map +1 -1
- package/dist/types/Template.mjs +14 -35
- package/dist/types/Template.mjs.map +1 -1
- package/dist/types/Text.mjs +19 -97
- package/dist/types/Text.mjs.map +1 -1
- package/dist/types/Try.mjs +14 -107
- package/dist/types/Try.mjs.map +1 -1
- package/dist/types/Uri.mjs +16 -74
- package/dist/types/Uri.mjs.map +1 -1
- package/dist/types/Uuid.mjs +5 -5
- package/dist/types/Uuid.mjs.map +1 -1
- package/dist/types/Validatable.mjs +6 -2
- package/dist/types/Validatable.mjs.map +1 -1
- package/dist/types/Value.mjs +14 -17
- package/dist/types/Value.mjs.map +1 -1
- package/dist/utils/Base64.mjs +3 -1
- package/dist/utils/Base64.mjs.map +1 -1
- package/dist/utils/Convert.mjs +15 -39
- package/dist/utils/Convert.mjs.map +1 -1
- package/dist/utils/If.mjs +10 -13
- package/dist/utils/If.mjs.map +1 -1
- package/dist/utils/Loading.mjs +6 -2
- package/dist/utils/Loading.mjs.map +1 -1
- package/dist/utils/Log.mjs +2 -0
- package/dist/utils/Log.mjs.map +1 -1
- package/dist/utils/Mapper.mjs +19 -101
- package/dist/utils/Mapper.mjs.map +1 -1
- package/dist/utils/Promise.mjs +19 -16
- package/dist/utils/Promise.mjs.map +1 -1
- package/dist/utils/Property.mjs +15 -14
- package/dist/utils/Property.mjs.map +1 -1
- package/dist/utils/Sentence.mjs +28 -14
- package/dist/utils/Sentence.mjs.map +1 -1
- package/dist/utils/State.mjs +7 -8
- package/dist/utils/State.mjs.map +1 -1
- package/dist/utils/Traverse.mjs +3 -5
- package/dist/utils/Traverse.mjs.map +1 -1
- package/dist/utils/View.mjs +21 -64
- package/dist/utils/View.mjs.map +1 -1
- package/dist/utils/Wait.mjs +5 -3
- package/dist/utils/Wait.mjs.map +1 -1
- package/dist/validation/Contraints.mjs +32 -29
- package/dist/validation/Contraints.mjs.map +1 -1
- package/dist/validation/Validate.mjs +16 -28
- package/dist/validation/Validate.mjs.map +1 -1
- package/dist/validation/When.mjs +14 -38
- package/dist/validation/When.mjs.map +1 -1
- package/package.json +4 -3
- package/dist/data/Condition.js +0 -71
- package/dist/data/Condition.js.map +0 -1
- package/dist/data/DataProvider.js +0 -17
- package/dist/data/DataProvider.js.map +0 -1
- package/dist/data/Database.js +0 -42
- package/dist/data/Database.js.map +0 -1
- package/dist/data/Field.js +0 -48
- package/dist/data/Field.js.map +0 -1
- package/dist/data/InMemoryGateway.js +0 -59
- package/dist/data/InMemoryGateway.js.map +0 -1
- package/dist/data/Query.js +0 -17
- package/dist/data/Query.js.map +0 -1
- package/dist/data/QueryProvider.js +0 -17
- package/dist/data/QueryProvider.js.map +0 -1
- package/dist/data/index.js +0 -35
- package/dist/data/index.js.map +0 -1
- package/dist/domain/Audit.js +0 -59
- package/dist/domain/Audit.js.map +0 -1
- package/dist/domain/Child.js +0 -49
- package/dist/domain/Child.js.map +0 -1
- package/dist/domain/Entity.js +0 -62
- package/dist/domain/Entity.js.map +0 -1
- package/dist/domain/Repo.js +0 -81
- package/dist/domain/Repo.js.map +0 -1
- package/dist/domain/Struct.js +0 -55
- package/dist/domain/Struct.js.map +0 -1
- package/dist/domain/Typo.js +0 -62
- package/dist/domain/Typo.js.map +0 -1
- package/dist/domain/enums/Country.js +0 -290
- package/dist/domain/enums/Country.js.map +0 -1
- package/dist/domain/enums/Currency.js +0 -159
- package/dist/domain/enums/Currency.js.map +0 -1
- package/dist/domain/enums/Environment.js +0 -35
- package/dist/domain/enums/Environment.js.map +0 -1
- package/dist/domain/enums/Locale.js +0 -605
- package/dist/domain/enums/Locale.js.map +0 -1
- package/dist/domain/enums/UnitOfMeasurement.js +0 -40
- package/dist/domain/enums/UnitOfMeasurement.js.map +0 -1
- package/dist/domain/enums/UnitOfWeight.js +0 -38
- package/dist/domain/enums/UnitOfWeight.js.map +0 -1
- package/dist/domain/enums/index.js +0 -33
- package/dist/domain/enums/index.js.map +0 -1
- package/dist/domain/index.js +0 -39
- package/dist/domain/index.js.map +0 -1
- package/dist/domain/structs/Address.js +0 -73
- package/dist/domain/structs/Address.js.map +0 -1
- package/dist/domain/structs/Box.js +0 -70
- package/dist/domain/structs/Box.js.map +0 -1
- package/dist/domain/structs/Dimension.js +0 -61
- package/dist/domain/structs/Dimension.js.map +0 -1
- package/dist/domain/structs/Money.js +0 -71
- package/dist/domain/structs/Money.js.map +0 -1
- package/dist/domain/structs/Name.js +0 -57
- package/dist/domain/structs/Name.js.map +0 -1
- package/dist/domain/structs/Weight.js +0 -71
- package/dist/domain/structs/Weight.js.map +0 -1
- package/dist/domain/structs/index.js +0 -33
- package/dist/domain/structs/index.js.map +0 -1
- package/dist/domain/values/DateTime.js +0 -120
- package/dist/domain/values/DateTime.js.map +0 -1
- package/dist/domain/values/EAN.js +0 -50
- package/dist/domain/values/EAN.js.map +0 -1
- package/dist/domain/values/Email.js +0 -57
- package/dist/domain/values/Email.js.map +0 -1
- package/dist/domain/values/IBAN.js +0 -50
- package/dist/domain/values/IBAN.js.map +0 -1
- package/dist/domain/values/PostalCode.js +0 -53
- package/dist/domain/values/PostalCode.js.map +0 -1
- package/dist/domain/values/Slug.js +0 -41
- package/dist/domain/values/Slug.js.map +0 -1
- package/dist/domain/values/Url.js +0 -57
- package/dist/domain/values/Url.js.map +0 -1
- package/dist/domain/values/index.js +0 -35
- package/dist/domain/values/index.js.map +0 -1
- package/dist/health/HealthResource.js +0 -49
- package/dist/health/HealthResource.js.map +0 -1
- package/dist/health/HealthUri.js +0 -33
- package/dist/health/HealthUri.js.map +0 -1
- package/dist/health/index.js +0 -25
- package/dist/health/index.js.map +0 -1
- package/dist/http/CacheControl.js +0 -56
- package/dist/http/CacheControl.js.map +0 -1
- package/dist/http/ContentType.js +0 -53
- package/dist/http/ContentType.js.map +0 -1
- package/dist/http/HttpHeader.js +0 -32
- package/dist/http/HttpHeader.js.map +0 -1
- package/dist/http/HttpStatus.js +0 -112
- package/dist/http/HttpStatus.js.map +0 -1
- package/dist/http/HttpVerb.js +0 -39
- package/dist/http/HttpVerb.js.map +0 -1
- package/dist/http/LocalRequestStore.js +0 -36
- package/dist/http/LocalRequestStore.js.map +0 -1
- package/dist/http/OriginatedError.js +0 -44
- package/dist/http/OriginatedError.js.map +0 -1
- package/dist/http/Request.js +0 -17
- package/dist/http/Request.js.map +0 -1
- package/dist/http/RequestOptions.js +0 -91
- package/dist/http/RequestOptions.js.map +0 -1
- package/dist/http/RequestProvider.js +0 -17
- package/dist/http/RequestProvider.js.map +0 -1
- package/dist/http/Response.js +0 -39
- package/dist/http/Response.js.map +0 -1
- package/dist/http/RestResult.js +0 -56
- package/dist/http/RestResult.js.map +0 -1
- package/dist/http/Verb.js +0 -61
- package/dist/http/Verb.js.map +0 -1
- package/dist/http/index.js +0 -45
- package/dist/http/index.js.map +0 -1
- package/dist/process/App.js +0 -35
- package/dist/process/App.js.map +0 -1
- package/dist/process/Manage.js +0 -43
- package/dist/process/Manage.js.map +0 -1
- package/dist/process/Scope.js +0 -46
- package/dist/process/Scope.js.map +0 -1
- package/dist/process/Search.js +0 -62
- package/dist/process/Search.js.map +0 -1
- package/dist/process/UseCase.js +0 -50
- package/dist/process/UseCase.js.map +0 -1
- package/dist/process/index.js +0 -31
- package/dist/process/index.js.map +0 -1
- package/dist/resources/AppProvider.js +0 -17
- package/dist/resources/AppProvider.js.map +0 -1
- package/dist/resources/Req.js +0 -54
- package/dist/resources/Req.js.map +0 -1
- package/dist/resources/Requires.js +0 -48
- package/dist/resources/Requires.js.map +0 -1
- package/dist/resources/Resource.js +0 -17
- package/dist/resources/Resource.js.map +0 -1
- package/dist/resources/Route.js +0 -62
- package/dist/resources/Route.js.map +0 -1
- package/dist/resources/Service.js +0 -49
- package/dist/resources/Service.js.map +0 -1
- package/dist/resources/index.js +0 -35
- package/dist/resources/index.js.map +0 -1
- package/dist/security/Jwt.js +0 -48
- package/dist/security/Jwt.js.map +0 -1
- package/dist/security/index.js +0 -23
- package/dist/security/index.js.map +0 -1
- package/dist/services/Api.js +0 -93
- package/dist/services/Api.js.map +0 -1
- package/dist/services/ApiGateway.js +0 -57
- package/dist/services/ApiGateway.js.map +0 -1
- package/dist/services/AxiosProvider.js +0 -61
- package/dist/services/AxiosProvider.js.map +0 -1
- package/dist/services/MappedRouteGateway.js +0 -52
- package/dist/services/MappedRouteGateway.js.map +0 -1
- package/dist/services/RouteGateway.js +0 -70
- package/dist/services/RouteGateway.js.map +0 -1
- package/dist/services/ViewRouteGateway.js +0 -55
- package/dist/services/ViewRouteGateway.js.map +0 -1
- package/dist/services/index.js +0 -33
- package/dist/services/index.js.map +0 -1
- package/dist/sql/Clause.js +0 -58
- package/dist/sql/Clause.js.map +0 -1
- package/dist/sql/Column.js +0 -96
- package/dist/sql/Column.js.map +0 -1
- package/dist/sql/Count.js +0 -35
- package/dist/sql/Count.js.map +0 -1
- package/dist/sql/Delete.js +0 -35
- package/dist/sql/Delete.js.map +0 -1
- package/dist/sql/Insert.js +0 -40
- package/dist/sql/Insert.js.map +0 -1
- package/dist/sql/Join.js +0 -46
- package/dist/sql/Join.js.map +0 -1
- package/dist/sql/Select.js +0 -68
- package/dist/sql/Select.js.map +0 -1
- package/dist/sql/SqlQuery.js +0 -39
- package/dist/sql/SqlQuery.js.map +0 -1
- package/dist/sql/Table.js +0 -63
- package/dist/sql/Table.js.map +0 -1
- package/dist/sql/TableGateway.js +0 -62
- package/dist/sql/TableGateway.js.map +0 -1
- package/dist/sql/Update.js +0 -41
- package/dist/sql/Update.js.map +0 -1
- package/dist/sql/index.js +0 -41
- package/dist/sql/index.js.map +0 -1
- package/dist/types/Array.js +0 -54
- package/dist/types/Array.js.map +0 -1
- package/dist/types/Builder.js +0 -43
- package/dist/types/Builder.js.map +0 -1
- package/dist/types/Cache.js +0 -38
- package/dist/types/Cache.js.map +0 -1
- package/dist/types/CacheAge.js +0 -64
- package/dist/types/CacheAge.js.map +0 -1
- package/dist/types/Case.js +0 -115
- package/dist/types/Case.js.map +0 -1
- package/dist/types/Constructor.js +0 -50
- package/dist/types/Constructor.js.map +0 -1
- package/dist/types/Context.js +0 -117
- package/dist/types/Context.js.map +0 -1
- package/dist/types/Enum.js +0 -76
- package/dist/types/Enum.js.map +0 -1
- package/dist/types/ErrorOrigin.js +0 -17
- package/dist/types/ErrorOrigin.js.map +0 -1
- package/dist/types/Exception.js +0 -54
- package/dist/types/Exception.js.map +0 -1
- package/dist/types/Falsy.js +0 -32
- package/dist/types/Falsy.js.map +0 -1
- package/dist/types/Func.js +0 -29
- package/dist/types/Func.js.map +0 -1
- package/dist/types/Gateway.js +0 -62
- package/dist/types/Gateway.js.map +0 -1
- package/dist/types/Get.js +0 -36
- package/dist/types/Get.js.map +0 -1
- package/dist/types/Id.js +0 -30
- package/dist/types/Id.js.map +0 -1
- package/dist/types/Identity.js +0 -17
- package/dist/types/Identity.js.map +0 -1
- package/dist/types/Is.js +0 -85
- package/dist/types/Is.js.map +0 -1
- package/dist/types/IsA.js +0 -33
- package/dist/types/IsA.js.map +0 -1
- package/dist/types/IsDate.js +0 -46
- package/dist/types/IsDate.js.map +0 -1
- package/dist/types/IsEqual.js +0 -39
- package/dist/types/IsEqual.js.map +0 -1
- package/dist/types/Json.js +0 -67
- package/dist/types/Json.js.map +0 -1
- package/dist/types/List.js +0 -208
- package/dist/types/List.js.map +0 -1
- package/dist/types/Message.js +0 -30
- package/dist/types/Message.js.map +0 -1
- package/dist/types/Meta.js +0 -71
- package/dist/types/Meta.js.map +0 -1
- package/dist/types/Nullish.js +0 -29
- package/dist/types/Nullish.js.map +0 -1
- package/dist/types/Number.js +0 -33
- package/dist/types/Number.js.map +0 -1
- package/dist/types/PageList.js.map +0 -1
- package/dist/types/Parser.js +0 -69
- package/dist/types/Parser.js.map +0 -1
- package/dist/types/Primitive.js +0 -32
- package/dist/types/Primitive.js.map +0 -1
- package/dist/types/Repository.js +0 -68
- package/dist/types/Repository.js.map +0 -1
- package/dist/types/Result.js +0 -38
- package/dist/types/Result.js.map +0 -1
- package/dist/types/Results.js +0 -51
- package/dist/types/Results.js.map +0 -1
- package/dist/types/Sort.js +0 -32
- package/dist/types/Sort.js.map +0 -1
- package/dist/types/Tag.js +0 -35
- package/dist/types/Tag.js.map +0 -1
- package/dist/types/Template.js +0 -65
- package/dist/types/Template.js.map +0 -1
- package/dist/types/Text.js +0 -137
- package/dist/types/Text.js.map +0 -1
- package/dist/types/Try.js +0 -137
- package/dist/types/Try.js.map +0 -1
- package/dist/types/TypeGuard.js +0 -17
- package/dist/types/TypeGuard.js.map +0 -1
- package/dist/types/Types.js +0 -17
- package/dist/types/Types.js.map +0 -1
- package/dist/types/Uri.js +0 -106
- package/dist/types/Uri.js.map +0 -1
- package/dist/types/Uuid.js +0 -35
- package/dist/types/Uuid.js.map +0 -1
- package/dist/types/Validatable.js +0 -30
- package/dist/types/Validatable.js.map +0 -1
- package/dist/types/Value.js +0 -47
- package/dist/types/Value.js.map +0 -1
- package/dist/types/index.js +0 -107
- package/dist/types/index.js.map +0 -1
- package/dist/utils/Base64.js +0 -33
- package/dist/utils/Base64.js.map +0 -1
- package/dist/utils/Convert.js +0 -69
- package/dist/utils/Convert.js.map +0 -1
- package/dist/utils/If.js +0 -47
- package/dist/utils/If.js.map +0 -1
- package/dist/utils/Loading.js +0 -30
- package/dist/utils/Loading.js.map +0 -1
- package/dist/utils/Log.js +0 -43
- package/dist/utils/Log.js.map +0 -1
- package/dist/utils/Mapper.js +0 -133
- package/dist/utils/Mapper.js.map +0 -1
- package/dist/utils/Promise.js +0 -56
- package/dist/utils/Promise.js.map +0 -1
- package/dist/utils/Property.js +0 -42
- package/dist/utils/Property.js.map +0 -1
- package/dist/utils/Sentence.js +0 -80
- package/dist/utils/Sentence.js.map +0 -1
- package/dist/utils/State.js +0 -36
- package/dist/utils/State.js.map +0 -1
- package/dist/utils/Traverse.js +0 -33
- package/dist/utils/Traverse.js.map +0 -1
- package/dist/utils/View.js +0 -86
- package/dist/utils/View.js.map +0 -1
- package/dist/utils/Wait.js +0 -39
- package/dist/utils/Wait.js.map +0 -1
- package/dist/utils/index.js +0 -47
- package/dist/utils/index.js.map +0 -1
- package/dist/validation/Contraints.js +0 -91
- package/dist/validation/Contraints.js.map +0 -1
- package/dist/validation/Validate.js +0 -46
- package/dist/validation/Validate.js.map +0 -1
- package/dist/validation/When.js +0 -68
- package/dist/validation/When.js.map +0 -1
- package/dist/validation/index.js +0 -27
- package/dist/validation/index.js.map +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/data/InMemoryGateway.ts"],"sourcesContent":["import { Exception, FetchOptions, Gateway, Id, isDefined, Json, JsonValue, Optional, PageList, toPageList } from '../types';\nimport { when } from '../validation';\n\nexport class InMemoryGateway extends Gateway {\n constructor(private readonly data: Promise<PageList<Json>>) {\n super();\n }\n\n all(options?: FetchOptions): Promise<PageList<Json>> {\n return this.data.then(d => toPageList(d, d));\n }\n\n byId(id: Id): Promise<Optional<Json>> {\n return this.data.then(d => d.byId(id)).then(d => (d ? { ...d } : undefined));\n }\n\n by = (key: string, value: JsonValue): Promise<PageList<Json>> => {\n return this.data.then(d => d.filter(i => i[key] === value));\n };\n\n exists(id: Id): Promise<boolean> {\n return this.byId(id).then(d => isDefined(d));\n }\n\n add(item: Json): Promise<Json> {\n return when(item)\n .not.contains(i => i.id)\n .reject(Exception.IsMissingId)\n .then(i => this.exists(i.id as Id))\n .then(ex => when(ex).isTrue.reject(Exception.AlreadyExists))\n .then(() => this.data.then(d => d.add(item)))\n .then(() => ({ ...item }));\n }\n\n remove(id: Id): Promise<true> {\n return this.data\n .then(d =>\n when(d.findIndex(i => i.id === id))\n .with(i => i < 0)\n .reject(Exception.DoesNotExist)\n .then(i => d.splice(i, 1))\n )\n .then(() => true);\n }\n\n update(item: Json): Promise<Json> {\n return when(item)\n .not.contains(i => i.id)\n .reject(Exception.IsMissingId)\n .then(i => this.remove(i.id as Id).then(() => this.add(i)));\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAAiH;AACjH,wBAAqB;AAEd,MAAM,wBAAwB,qBAAQ;AAAA,EAC3C,YAA6B,MAA+B;AAC1D,UAAM;AADqB;AAAA,EAE7B;AAAA,EAEA,IAAI,SAAiD;AACnD,WAAO,KAAK,KAAK,KAAK,WAAK,yBAAW,GAAG,CAAC,CAAC;AAAA,EAC7C;AAAA,EAEA,KAAK,IAAiC;AACpC,WAAO,KAAK,KAAK,KAAK,OAAK,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,OAAM,IAAI,EAAE,GAAG,EAAE,IAAI,MAAU;AAAA,EAC7E;AAAA,EAEA,KAAK,CAAC,KAAa,UAA8C;AAC/D,WAAO,KAAK,KAAK,KAAK,OAAK,EAAE,OAAO,OAAK,EAAE,GAAG,MAAM,KAAK,CAAC;AAAA,EAC5D;AAAA,EAEA,OAAO,IAA0B;AAC/B,WAAO,KAAK,KAAK,EAAE,EAAE,KAAK,WAAK,wBAAU,CAAC,CAAC;AAAA,EAC7C;AAAA,EAEA,IAAI,MAA2B;AAC7B,eAAO,wBAAK,IAAI,EACb,IAAI,SAAS,OAAK,EAAE,EAAE,EACtB,OAAO,uBAAU,WAAW,EAC5B,KAAK,OAAK,KAAK,OAAO,EAAE,EAAQ,CAAC,EACjC,KAAK,YAAM,wBAAK,EAAE,EAAE,OAAO,OAAO,uBAAU,aAAa,CAAC,EAC1D,KAAK,MAAM,KAAK,KAAK,KAAK,OAAK,EAAE,IAAI,IAAI,CAAC,CAAC,EAC3C,KAAK,OAAO,EAAE,GAAG,KAAK,EAAE;AAAA,EAC7B;AAAA,EAEA,OAAO,IAAuB;AAC5B,WAAO,KAAK,KACT;AAAA,MAAK,WACJ,wBAAK,EAAE,UAAU,OAAK,EAAE,OAAO,EAAE,CAAC,EAC/B,KAAK,OAAK,IAAI,CAAC,EACf,OAAO,uBAAU,YAAY,EAC7B,KAAK,OAAK,EAAE,OAAO,GAAG,CAAC,CAAC;AAAA,IAC7B,EACC,KAAK,MAAM,IAAI;AAAA,EACpB;AAAA,EAEA,OAAO,MAA2B;AAChC,eAAO,wBAAK,IAAI,EACb,IAAI,SAAS,OAAK,EAAE,EAAE,EACtB,OAAO,uBAAU,WAAW,EAC5B,KAAK,OAAK,KAAK,OAAO,EAAE,EAAQ,EAAE,KAAK,MAAM,KAAK,IAAI,CAAC,CAAC,CAAC;AAAA,EAC9D;AACF;","names":[]}
|
package/dist/data/Query.js
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __copyProps = (to, from, except, desc) => {
|
|
7
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
8
|
-
for (let key of __getOwnPropNames(from))
|
|
9
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
10
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
11
|
-
}
|
|
12
|
-
return to;
|
|
13
|
-
};
|
|
14
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
15
|
-
var Query_exports = {};
|
|
16
|
-
module.exports = __toCommonJS(Query_exports);
|
|
17
|
-
//# sourceMappingURL=Query.js.map
|
package/dist/data/Query.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/data/Query.ts"],"sourcesContent":["import { Text } from '../types';\n\nexport type Query = Text;\n"],"mappings":";;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __copyProps = (to, from, except, desc) => {
|
|
7
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
8
|
-
for (let key of __getOwnPropNames(from))
|
|
9
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
10
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
11
|
-
}
|
|
12
|
-
return to;
|
|
13
|
-
};
|
|
14
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
15
|
-
var QueryProvider_exports = {};
|
|
16
|
-
module.exports = __toCommonJS(QueryProvider_exports);
|
|
17
|
-
//# sourceMappingURL=QueryProvider.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/data/QueryProvider.ts"],"sourcesContent":["import { Query } from './Query';\nimport { Json, List } from '../types';\nimport { DataProvider } from './DataProvider';\n\nexport interface QueryProvider extends DataProvider {\n query: (q: Query) => Promise<List<Json>>;\n command: (q: Query) => Promise<number>;\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA;AAAA;","names":[]}
|
package/dist/data/index.js
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __copyProps = (to, from, except, desc) => {
|
|
7
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
8
|
-
for (let key of __getOwnPropNames(from))
|
|
9
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
10
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
11
|
-
}
|
|
12
|
-
return to;
|
|
13
|
-
};
|
|
14
|
-
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
15
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
16
|
-
var data_exports = {};
|
|
17
|
-
module.exports = __toCommonJS(data_exports);
|
|
18
|
-
__reExport(data_exports, require("./Condition"), module.exports);
|
|
19
|
-
__reExport(data_exports, require("./InMemoryGateway"), module.exports);
|
|
20
|
-
__reExport(data_exports, require("./Database"), module.exports);
|
|
21
|
-
__reExport(data_exports, require("./DataProvider"), module.exports);
|
|
22
|
-
__reExport(data_exports, require("./Field"), module.exports);
|
|
23
|
-
__reExport(data_exports, require("./Query"), module.exports);
|
|
24
|
-
__reExport(data_exports, require("./QueryProvider"), module.exports);
|
|
25
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
26
|
-
0 && (module.exports = {
|
|
27
|
-
...require("./Condition"),
|
|
28
|
-
...require("./InMemoryGateway"),
|
|
29
|
-
...require("./Database"),
|
|
30
|
-
...require("./DataProvider"),
|
|
31
|
-
...require("./Field"),
|
|
32
|
-
...require("./Query"),
|
|
33
|
-
...require("./QueryProvider")
|
|
34
|
-
});
|
|
35
|
-
//# sourceMappingURL=index.js.map
|
package/dist/data/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/data/index.ts"],"sourcesContent":["export * from './Condition';\nexport * from './InMemoryGateway';\nexport * from './Database';\nexport * from './DataProvider';\nexport * from './Field';\nexport * from './Query';\nexport * from './QueryProvider';\n"],"mappings":";;;;;;;;;;;;;;;AAAA;AAAA;AAAA,yBAAc,wBAAd;AACA,yBAAc,8BADd;AAEA,yBAAc,uBAFd;AAGA,yBAAc,2BAHd;AAIA,yBAAc,oBAJd;AAKA,yBAAc,oBALd;AAMA,yBAAc,4BANd;","names":[]}
|
package/dist/domain/Audit.js
DELETED
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __export = (target, all) => {
|
|
7
|
-
for (var name in all)
|
|
8
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
var __decorateClass = (decorators, target, key, kind) => {
|
|
20
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc(target, key) : target;
|
|
21
|
-
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
22
|
-
if (decorator = decorators[i])
|
|
23
|
-
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
24
|
-
if (kind && result)
|
|
25
|
-
__defProp(target, key, result);
|
|
26
|
-
return result;
|
|
27
|
-
};
|
|
28
|
-
var Audit_exports = {};
|
|
29
|
-
__export(Audit_exports, {
|
|
30
|
-
Audit: () => Audit
|
|
31
|
-
});
|
|
32
|
-
module.exports = __toCommonJS(Audit_exports);
|
|
33
|
-
var import_Struct = require("./Struct");
|
|
34
|
-
var import_types = require("../types");
|
|
35
|
-
var import_validation = require("../validation");
|
|
36
|
-
var import_values = require("./values");
|
|
37
|
-
class Audit extends import_Struct.Struct {
|
|
38
|
-
by = { id: this.state.by.id, user: this.state.by.user };
|
|
39
|
-
when = new import_values.DateTime(this.state.when);
|
|
40
|
-
constructor(json) {
|
|
41
|
-
super(
|
|
42
|
-
(0, import_types.choose)(json).is.defined(
|
|
43
|
-
(j) => j,
|
|
44
|
-
(j) => j
|
|
45
|
-
).else({ by: import_types.ctx.request?.identity ?? { id: 0, user: "easy" }, when: import_values.DateTime.now.toJSON() })
|
|
46
|
-
);
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
__decorateClass([
|
|
50
|
-
(0, import_validation.required)()
|
|
51
|
-
], Audit.prototype, "by", 2);
|
|
52
|
-
__decorateClass([
|
|
53
|
-
(0, import_validation.valid)()
|
|
54
|
-
], Audit.prototype, "when", 2);
|
|
55
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
56
|
-
0 && (module.exports = {
|
|
57
|
-
Audit
|
|
58
|
-
});
|
|
59
|
-
//# sourceMappingURL=Audit.js.map
|
package/dist/domain/Audit.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/domain/Audit.ts"],"sourcesContent":["import { Struct } from './Struct';\nimport { choose, ctx, Id, Json } from '../types';\nimport { required, valid } from '../validation';\nimport { DateTime } from './values';\n\nexport class Audit extends Struct {\n @required() readonly by: { id: Id; user: string } = { id: this.state.by.id, user: this.state.by.user };\n @valid() readonly when: DateTime = new DateTime(this.state.when);\n\n constructor(json?: Json) {\n super(\n choose(json)\n .is.defined(\n j => j,\n j => j\n )\n .else({ by: ctx.request?.identity ?? { id: 0, user: 'easy' }, when: DateTime.now.toJSON() })\n );\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,oBAAuB;AACvB,mBAAsC;AACtC,wBAAgC;AAChC,oBAAyB;AAElB,MAAM,cAAc,qBAAO;AAAA,EACX,KAA+B,EAAE,IAAI,KAAK,MAAM,GAAG,IAAI,MAAM,KAAK,MAAM,GAAG,KAAK;AAAA,EACnF,OAAiB,IAAI,uBAAS,KAAK,MAAM,IAAI;AAAA,EAE/D,YAAY,MAAa;AACvB;AAAA,UACE,qBAAO,IAAI,EACR,GAAG;AAAA,QACF,OAAK;AAAA,QACL,OAAK;AAAA,MACP,EACC,KAAK,EAAE,IAAI,iBAAI,SAAS,YAAY,EAAE,IAAI,GAAG,MAAM,OAAO,GAAG,MAAM,uBAAS,IAAI,OAAO,EAAE,CAAC;AAAA,IAC/F;AAAA,EACF;AACF;AAbuB;AAAA,MAApB,4BAAS;AAAA,GADC,MACU;AACH;AAAA,MAAjB,yBAAM;AAAA,GAFI,MAEO;","names":[]}
|
package/dist/domain/Child.js
DELETED
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __export = (target, all) => {
|
|
7
|
-
for (var name in all)
|
|
8
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
var __decorateClass = (decorators, target, key, kind) => {
|
|
20
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc(target, key) : target;
|
|
21
|
-
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
22
|
-
if (decorator = decorators[i])
|
|
23
|
-
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
24
|
-
if (kind && result)
|
|
25
|
-
__defProp(target, key, result);
|
|
26
|
-
return result;
|
|
27
|
-
};
|
|
28
|
-
var Child_exports = {};
|
|
29
|
-
__export(Child_exports, {
|
|
30
|
-
Child: () => Child
|
|
31
|
-
});
|
|
32
|
-
module.exports = __toCommonJS(Child_exports);
|
|
33
|
-
var import_Struct = require("./Struct");
|
|
34
|
-
var import_types = require("../types");
|
|
35
|
-
var import_validation = require("../validation");
|
|
36
|
-
class Child extends import_Struct.Struct {
|
|
37
|
-
id = this.state.id ?? (0, import_types.toId)();
|
|
38
|
-
merge(a) {
|
|
39
|
-
return import_types.json.merge(this, a, { id: this.id });
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
__decorateClass([
|
|
43
|
-
(0, import_validation.required)()
|
|
44
|
-
], Child.prototype, "id", 2);
|
|
45
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
46
|
-
0 && (module.exports = {
|
|
47
|
-
Child
|
|
48
|
-
});
|
|
49
|
-
//# sourceMappingURL=Child.js.map
|
package/dist/domain/Child.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/domain/Child.ts"],"sourcesContent":["import { Struct } from './Struct';\nimport { Id, json, Json, toId } from '../types';\nimport { required } from '../validation';\n\nexport abstract class Child extends Struct {\n @required() readonly id: Id = this.state.id ?? toId();\n\n protected merge(a: unknown): Json {\n return json.merge(this, a, { id: this.id });\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,oBAAuB;AACvB,mBAAqC;AACrC,wBAAyB;AAElB,MAAe,cAAc,qBAAO;AAAA,EACpB,KAAS,KAAK,MAAM,UAAM,mBAAK;AAAA,EAE1C,MAAM,GAAkB;AAChC,WAAO,kBAAK,MAAM,MAAM,GAAG,EAAE,IAAI,KAAK,GAAG,CAAC;AAAA,EAC5C;AACF;AALuB;AAAA,MAApB,4BAAS;AAAA,GADU,MACC;","names":[]}
|
package/dist/domain/Entity.js
DELETED
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __export = (target, all) => {
|
|
7
|
-
for (var name in all)
|
|
8
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
var __decorateClass = (decorators, target, key, kind) => {
|
|
20
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc(target, key) : target;
|
|
21
|
-
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
22
|
-
if (decorator = decorators[i])
|
|
23
|
-
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
24
|
-
if (kind && result)
|
|
25
|
-
__defProp(target, key, result);
|
|
26
|
-
return result;
|
|
27
|
-
};
|
|
28
|
-
var Entity_exports = {};
|
|
29
|
-
__export(Entity_exports, {
|
|
30
|
-
Entity: () => Entity
|
|
31
|
-
});
|
|
32
|
-
module.exports = __toCommonJS(Entity_exports);
|
|
33
|
-
var import_Struct = require("./Struct");
|
|
34
|
-
var import_types = require("../types");
|
|
35
|
-
var import_validation = require("../validation");
|
|
36
|
-
var import_Audit = require("./Audit");
|
|
37
|
-
class Entity extends import_Struct.Struct {
|
|
38
|
-
id = this.state.id ?? (0, import_types.toId)();
|
|
39
|
-
created = new import_Audit.Audit(this.state.created);
|
|
40
|
-
lastModified = new import_Audit.Audit(this.state.lastModified);
|
|
41
|
-
merge(a) {
|
|
42
|
-
return import_types.json.merge(this, a, {
|
|
43
|
-
id: this.id,
|
|
44
|
-
created: this.created,
|
|
45
|
-
lastModified: new import_Audit.Audit()
|
|
46
|
-
});
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
__decorateClass([
|
|
50
|
-
(0, import_validation.required)()
|
|
51
|
-
], Entity.prototype, "id", 2);
|
|
52
|
-
__decorateClass([
|
|
53
|
-
(0, import_validation.required)()
|
|
54
|
-
], Entity.prototype, "created", 2);
|
|
55
|
-
__decorateClass([
|
|
56
|
-
(0, import_validation.required)()
|
|
57
|
-
], Entity.prototype, "lastModified", 2);
|
|
58
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
59
|
-
0 && (module.exports = {
|
|
60
|
-
Entity
|
|
61
|
-
});
|
|
62
|
-
//# sourceMappingURL=Entity.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/domain/Entity.ts"],"sourcesContent":["import { Struct } from './Struct';\nimport { Id, json, Json, toId } from '../types';\nimport { required } from '../validation';\nimport { Audit } from './Audit';\n\nexport abstract class Entity extends Struct {\n @required() readonly id: Id = this.state.id ?? toId();\n @required() readonly created: Audit = new Audit(this.state.created);\n @required() readonly lastModified: Audit = new Audit(this.state.lastModified);\n\n protected merge(a: unknown): Json {\n return json.merge(this, a, {\n id: this.id,\n created: this.created,\n lastModified: new Audit(),\n });\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,oBAAuB;AACvB,mBAAqC;AACrC,wBAAyB;AACzB,mBAAsB;AAEf,MAAe,eAAe,qBAAO;AAAA,EACrB,KAAS,KAAK,MAAM,UAAM,mBAAK;AAAA,EAC/B,UAAiB,IAAI,mBAAM,KAAK,MAAM,OAAO;AAAA,EAC7C,eAAsB,IAAI,mBAAM,KAAK,MAAM,YAAY;AAAA,EAElE,MAAM,GAAkB;AAChC,WAAO,kBAAK,MAAM,MAAM,GAAG;AAAA,MACzB,IAAI,KAAK;AAAA,MACT,SAAS,KAAK;AAAA,MACd,cAAc,IAAI,mBAAM;AAAA,IAC1B,CAAC;AAAA,EACH;AACF;AAXuB;AAAA,MAApB,4BAAS;AAAA,GADU,OACC;AACA;AAAA,MAApB,4BAAS;AAAA,GAFU,OAEC;AACA;AAAA,MAApB,4BAAS;AAAA,GAHU,OAGC;","names":[]}
|
package/dist/domain/Repo.js
DELETED
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __export = (target, all) => {
|
|
7
|
-
for (var name in all)
|
|
8
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
var Repo_exports = {};
|
|
20
|
-
__export(Repo_exports, {
|
|
21
|
-
Repo: () => Repo
|
|
22
|
-
});
|
|
23
|
-
module.exports = __toCommonJS(Repo_exports);
|
|
24
|
-
var import_types = require("../types");
|
|
25
|
-
var import_validation = require("../validation");
|
|
26
|
-
var import_utils = require("../utils");
|
|
27
|
-
class Repo extends import_types.Repository {
|
|
28
|
-
constructor(ctor, gateway) {
|
|
29
|
-
super();
|
|
30
|
-
this.ctor = ctor;
|
|
31
|
-
this.gateway = gateway;
|
|
32
|
-
}
|
|
33
|
-
create = (item) => (0, import_types.isValidatable)(item) ? item : new this.ctor(item);
|
|
34
|
-
all(options) {
|
|
35
|
-
return this.gateway.all(options).then((js) => js.map((i) => new this.ctor(i)));
|
|
36
|
-
}
|
|
37
|
-
byId(id) {
|
|
38
|
-
return this.gateway.byId(id).then((j) => (0, import_validation.when)(j).not.isDefined.reject(import_types.Exception.DoesNotExist)).then((j) => new this.ctor(j));
|
|
39
|
-
}
|
|
40
|
-
byIds(...ids) {
|
|
41
|
-
return this.gateway.byIds(...ids).then((j) => (0, import_types.asList)(this.ctor, j));
|
|
42
|
-
}
|
|
43
|
-
byKey(key, options) {
|
|
44
|
-
return this.gateway.by("key", key, options).then((js) => js.map((i) => new this.ctor(i)));
|
|
45
|
-
}
|
|
46
|
-
by(key, value, options) {
|
|
47
|
-
return this.gateway.by(key.toString(), value, options).then((js) => js.map((i) => new this.ctor(i)));
|
|
48
|
-
}
|
|
49
|
-
search(q, options) {
|
|
50
|
-
return this.gateway.search(q, options).then((js) => js.map((i) => new this.ctor(i)));
|
|
51
|
-
}
|
|
52
|
-
filter(options) {
|
|
53
|
-
return this.gateway.filter(options).then((js) => js.map((i) => new this.ctor(i)));
|
|
54
|
-
}
|
|
55
|
-
exists(id) {
|
|
56
|
-
return this.gateway.exists(id);
|
|
57
|
-
}
|
|
58
|
-
add(t) {
|
|
59
|
-
return this.extend(this.create(t), "add").then((i) => (0, import_validation.when)(i).not.isValid.reject()).then((i) => this.validate(i, "add")).then((i) => this.gateway.add((0, import_types.toJson)(i))).then((j) => new this.ctor(j));
|
|
60
|
-
}
|
|
61
|
-
update(id, json) {
|
|
62
|
-
return this.gateway.byId(id).then((j) => (0, import_validation.when)(j).not.isDefined.reject(import_types.Exception.DoesNotExist)).then((j) => new this.ctor(j).update(json)).then((i) => this.extend(i, "update")).then((i) => (0, import_validation.when)(i).not.isValid.reject()).then((i) => this.validate(i, "update")).then((i) => this.gateway.update((0, import_types.toJson)(i))).then((j) => new this.ctor(j));
|
|
63
|
-
}
|
|
64
|
-
remove(id) {
|
|
65
|
-
return this.gateway.remove(id);
|
|
66
|
-
}
|
|
67
|
-
extend(item, _action) {
|
|
68
|
-
return (0, import_utils.resolve)(item);
|
|
69
|
-
}
|
|
70
|
-
validate(item, _action) {
|
|
71
|
-
return (0, import_utils.resolve)(item);
|
|
72
|
-
}
|
|
73
|
-
upsert(id, item) {
|
|
74
|
-
return this.update(id, item).catch((e) => import_types.Exception.DoesNotExist.equals(e) ? this.add(item) : (0, import_utils.reject)(e));
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
78
|
-
0 && (module.exports = {
|
|
79
|
-
Repo
|
|
80
|
-
});
|
|
81
|
-
//# sourceMappingURL=Repo.js.map
|
package/dist/domain/Repo.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/domain/Repo.ts"],"sourcesContent":["import { asList, Constructor, Exception, FetchOptions, Gateway, Id, isValidatable, Json, JsonValue, Key, List, PageList, Repository, toJson } from '../types';\nimport { when } from '../validation';\nimport { reject, resolve } from '../utils';\nimport { Struct } from './Struct';\n\nexport type RepoAction = 'add' | 'update' | 'remove';\n\nexport class Repo<T extends Struct, Options = FetchOptions> extends Repository<T, Options> {\n constructor(protected ctor: Constructor<T>, private readonly gateway: Gateway<Options>) {\n super();\n }\n\n create = (item: T | Json): T => (isValidatable(item) ? item : new this.ctor(item));\n\n all(options?: Options): Promise<PageList<T>> {\n return this.gateway.all(options).then(js => js.map(i => new this.ctor(i)));\n }\n\n byId(id: Id): Promise<T> {\n return this.gateway\n .byId(id)\n .then(j => when(j).not.isDefined.reject(Exception.DoesNotExist))\n .then(j => new this.ctor(j));\n }\n\n byIds(...ids: Id[]): Promise<List<T>> {\n return this.gateway.byIds(...ids).then(j => asList(this.ctor, j));\n }\n\n byKey(key: Key, options?: Options): Promise<PageList<T>> {\n return this.gateway.by('key', key, options).then(js => js.map(i => new this.ctor(i)));\n }\n\n by(key: keyof T, value: JsonValue, options?: Options): Promise<PageList<T>> {\n return this.gateway.by(key.toString(), value, options).then(js => js.map(i => new this.ctor(i)));\n }\n\n search(q: JsonValue, options?: Options): Promise<PageList<T>> {\n return this.gateway.search(q, options).then(js => js.map(i => new this.ctor(i)));\n }\n\n filter(options?: Options): Promise<PageList<T>> {\n return this.gateway.filter(options).then(js => js.map(i => new this.ctor(i)));\n }\n\n exists(id: Id): Promise<boolean> {\n return this.gateway.exists(id);\n }\n\n add(t: T | Json): Promise<T> {\n return this.extend(this.create(t), 'add')\n .then(i => when(i).not.isValid.reject())\n .then(i => this.validate(i, 'add'))\n .then(i => this.gateway.add(toJson(i)))\n .then(j => new this.ctor(j));\n }\n\n update(id: Id, json: Json): Promise<T> {\n return this.gateway\n .byId(id)\n .then(j => when(j).not.isDefined.reject(Exception.DoesNotExist))\n .then(j => new this.ctor(j).update(json) as T)\n .then(i => this.extend(i, 'update'))\n .then(i => when(i).not.isValid.reject())\n .then(i => this.validate(i, 'update'))\n .then(i => this.gateway.update(toJson(i)))\n .then(j => new this.ctor(j));\n }\n\n remove(id: Id): Promise<boolean> {\n return this.gateway.remove(id);\n }\n\n extend(item: T, _action?: RepoAction): Promise<T> {\n return resolve(item);\n }\n\n validate(item: T, _action?: RepoAction): Promise<T> {\n return resolve(item);\n }\n\n upsert(id: Id, item: Json): Promise<T> {\n return this.update(id, item).catch(e => (Exception.DoesNotExist.equals(e) ? this.add(item) : reject(e)));\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAAmJ;AACnJ,wBAAqB;AACrB,mBAAgC;AAKzB,MAAM,aAAuD,wBAAuB;AAAA,EACzF,YAAsB,MAAuC,SAA2B;AACtF,UAAM;AADc;AAAuC;AAAA,EAE7D;AAAA,EAEA,SAAS,CAAC,aAAuB,4BAAc,IAAI,IAAI,OAAO,IAAI,KAAK,KAAK,IAAI;AAAA,EAEhF,IAAI,SAAyC;AAC3C,WAAO,KAAK,QAAQ,IAAI,OAAO,EAAE,KAAK,QAAM,GAAG,IAAI,OAAK,IAAI,KAAK,KAAK,CAAC,CAAC,CAAC;AAAA,EAC3E;AAAA,EAEA,KAAK,IAAoB;AACvB,WAAO,KAAK,QACT,KAAK,EAAE,EACP,KAAK,WAAK,wBAAK,CAAC,EAAE,IAAI,UAAU,OAAO,uBAAU,YAAY,CAAC,EAC9D,KAAK,OAAK,IAAI,KAAK,KAAK,CAAC,CAAC;AAAA,EAC/B;AAAA,EAEA,SAAS,KAA6B;AACpC,WAAO,KAAK,QAAQ,MAAM,GAAG,GAAG,EAAE,KAAK,WAAK,qBAAO,KAAK,MAAM,CAAC,CAAC;AAAA,EAClE;AAAA,EAEA,MAAM,KAAU,SAAyC;AACvD,WAAO,KAAK,QAAQ,GAAG,OAAO,KAAK,OAAO,EAAE,KAAK,QAAM,GAAG,IAAI,OAAK,IAAI,KAAK,KAAK,CAAC,CAAC,CAAC;AAAA,EACtF;AAAA,EAEA,GAAG,KAAc,OAAkB,SAAyC;AAC1E,WAAO,KAAK,QAAQ,GAAG,IAAI,SAAS,GAAG,OAAO,OAAO,EAAE,KAAK,QAAM,GAAG,IAAI,OAAK,IAAI,KAAK,KAAK,CAAC,CAAC,CAAC;AAAA,EACjG;AAAA,EAEA,OAAO,GAAc,SAAyC;AAC5D,WAAO,KAAK,QAAQ,OAAO,GAAG,OAAO,EAAE,KAAK,QAAM,GAAG,IAAI,OAAK,IAAI,KAAK,KAAK,CAAC,CAAC,CAAC;AAAA,EACjF;AAAA,EAEA,OAAO,SAAyC;AAC9C,WAAO,KAAK,QAAQ,OAAO,OAAO,EAAE,KAAK,QAAM,GAAG,IAAI,OAAK,IAAI,KAAK,KAAK,CAAC,CAAC,CAAC;AAAA,EAC9E;AAAA,EAEA,OAAO,IAA0B;AAC/B,WAAO,KAAK,QAAQ,OAAO,EAAE;AAAA,EAC/B;AAAA,EAEA,IAAI,GAAyB;AAC3B,WAAO,KAAK,OAAO,KAAK,OAAO,CAAC,GAAG,KAAK,EACrC,KAAK,WAAK,wBAAK,CAAC,EAAE,IAAI,QAAQ,OAAO,CAAC,EACtC,KAAK,OAAK,KAAK,SAAS,GAAG,KAAK,CAAC,EACjC,KAAK,OAAK,KAAK,QAAQ,QAAI,qBAAO,CAAC,CAAC,CAAC,EACrC,KAAK,OAAK,IAAI,KAAK,KAAK,CAAC,CAAC;AAAA,EAC/B;AAAA,EAEA,OAAO,IAAQ,MAAwB;AACrC,WAAO,KAAK,QACT,KAAK,EAAE,EACP,KAAK,WAAK,wBAAK,CAAC,EAAE,IAAI,UAAU,OAAO,uBAAU,YAAY,CAAC,EAC9D,KAAK,OAAK,IAAI,KAAK,KAAK,CAAC,EAAE,OAAO,IAAI,CAAM,EAC5C,KAAK,OAAK,KAAK,OAAO,GAAG,QAAQ,CAAC,EAClC,KAAK,WAAK,wBAAK,CAAC,EAAE,IAAI,QAAQ,OAAO,CAAC,EACtC,KAAK,OAAK,KAAK,SAAS,GAAG,QAAQ,CAAC,EACpC,KAAK,OAAK,KAAK,QAAQ,WAAO,qBAAO,CAAC,CAAC,CAAC,EACxC,KAAK,OAAK,IAAI,KAAK,KAAK,CAAC,CAAC;AAAA,EAC/B;AAAA,EAEA,OAAO,IAA0B;AAC/B,WAAO,KAAK,QAAQ,OAAO,EAAE;AAAA,EAC/B;AAAA,EAEA,OAAO,MAAS,SAAkC;AAChD,eAAO,sBAAQ,IAAI;AAAA,EACrB;AAAA,EAEA,SAAS,MAAS,SAAkC;AAClD,eAAO,sBAAQ,IAAI;AAAA,EACrB;AAAA,EAEA,OAAO,IAAQ,MAAwB;AACrC,WAAO,KAAK,OAAO,IAAI,IAAI,EAAE,MAAM,OAAM,uBAAU,aAAa,OAAO,CAAC,IAAI,KAAK,IAAI,IAAI,QAAI,qBAAO,CAAC,CAAE;AAAA,EACzG;AACF;","names":[]}
|
package/dist/domain/Struct.js
DELETED
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __export = (target, all) => {
|
|
7
|
-
for (var name in all)
|
|
8
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
var Struct_exports = {};
|
|
20
|
-
__export(Struct_exports, {
|
|
21
|
-
Struct: () => Struct,
|
|
22
|
-
isStruct: () => isStruct
|
|
23
|
-
});
|
|
24
|
-
module.exports = __toCommonJS(Struct_exports);
|
|
25
|
-
var import_types = require("../types");
|
|
26
|
-
var import_validation = require("../validation");
|
|
27
|
-
class Struct {
|
|
28
|
-
constructor(state = {}) {
|
|
29
|
-
this.state = state;
|
|
30
|
-
}
|
|
31
|
-
get isValid() {
|
|
32
|
-
return (0, import_validation.validate)(this).isValid;
|
|
33
|
-
}
|
|
34
|
-
toJSON() {
|
|
35
|
-
return import_types.json.delete(import_types.json.parse({ ...this }), "state");
|
|
36
|
-
}
|
|
37
|
-
toString() {
|
|
38
|
-
return this.constructor.name;
|
|
39
|
-
}
|
|
40
|
-
update(_add) {
|
|
41
|
-
return this;
|
|
42
|
-
}
|
|
43
|
-
merge(a) {
|
|
44
|
-
return import_types.json.merge(this, a);
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
function isStruct(s) {
|
|
48
|
-
return (0, import_types.isDefined)(s) && s instanceof Struct;
|
|
49
|
-
}
|
|
50
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
51
|
-
0 && (module.exports = {
|
|
52
|
-
Struct,
|
|
53
|
-
isStruct
|
|
54
|
-
});
|
|
55
|
-
//# sourceMappingURL=Struct.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/domain/Struct.ts"],"sourcesContent":["import { isDefined, json, Json, Validatable } from '../types';\nimport { validate } from '../validation';\n\nexport abstract class Struct implements Validatable {\n constructor(protected readonly state: any = {}) {}\n\n get isValid(): boolean {\n return validate(this).isValid;\n }\n\n toJSON(): Json {\n return json.delete(json.parse({ ...this }), 'state');\n }\n\n toString(): string {\n return this.constructor.name;\n }\n\n update(_add: Json): Struct {\n return this;\n }\n\n protected merge(a: unknown): Json {\n return json.merge(this, a);\n }\n}\n\nexport function isStruct(s?: unknown): s is Struct {\n return isDefined(s) && s instanceof Struct;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAAmD;AACnD,wBAAyB;AAElB,MAAe,OAA8B;AAAA,EAClD,YAA+B,QAAa,CAAC,GAAG;AAAjB;AAAA,EAAkB;AAAA,EAEjD,IAAI,UAAmB;AACrB,eAAO,4BAAS,IAAI,EAAE;AAAA,EACxB;AAAA,EAEA,SAAe;AACb,WAAO,kBAAK,OAAO,kBAAK,MAAM,EAAE,GAAG,KAAK,CAAC,GAAG,OAAO;AAAA,EACrD;AAAA,EAEA,WAAmB;AACjB,WAAO,KAAK,YAAY;AAAA,EAC1B;AAAA,EAEA,OAAO,MAAoB;AACzB,WAAO;AAAA,EACT;AAAA,EAEU,MAAM,GAAkB;AAChC,WAAO,kBAAK,MAAM,MAAM,CAAC;AAAA,EAC3B;AACF;AAEO,SAAS,SAAS,GAA0B;AACjD,aAAO,wBAAU,CAAC,KAAK,aAAa;AACtC;","names":[]}
|
package/dist/domain/Typo.js
DELETED
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __export = (target, all) => {
|
|
7
|
-
for (var name in all)
|
|
8
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
-
};
|
|
10
|
-
var __copyProps = (to, from, except, desc) => {
|
|
11
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
-
for (let key of __getOwnPropNames(from))
|
|
13
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
-
}
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
var Typo_exports = {};
|
|
20
|
-
__export(Typo_exports, {
|
|
21
|
-
Typo: () => Typo
|
|
22
|
-
});
|
|
23
|
-
module.exports = __toCommonJS(Typo_exports);
|
|
24
|
-
var import_types = require("../types");
|
|
25
|
-
var import_validation = require("../validation");
|
|
26
|
-
class Typo extends import_types.Repository {
|
|
27
|
-
constructor(view, gateway) {
|
|
28
|
-
super();
|
|
29
|
-
this.view = view;
|
|
30
|
-
this.gateway = gateway;
|
|
31
|
-
}
|
|
32
|
-
create = (j) => this.view.from(j);
|
|
33
|
-
all(options) {
|
|
34
|
-
return this.gateway.all(options).then((js) => js.map(this.create));
|
|
35
|
-
}
|
|
36
|
-
byId(id) {
|
|
37
|
-
return this.gateway.byId(id).then((j) => (0, import_validation.when)(j).not.isDefined.reject(import_types.Exception.DoesNotExist)).then((j) => this.create(j));
|
|
38
|
-
}
|
|
39
|
-
byIds(...ids) {
|
|
40
|
-
return this.gateway.byIds(...ids).then((js) => js.map(this.create));
|
|
41
|
-
}
|
|
42
|
-
byKey(key, options) {
|
|
43
|
-
return this.gateway.by("key", key, options).then((js) => js.map(this.create));
|
|
44
|
-
}
|
|
45
|
-
by(key, value, options) {
|
|
46
|
-
return this.gateway.by(key.toString(), value, options).then((js) => js.map(this.create));
|
|
47
|
-
}
|
|
48
|
-
search(q, options) {
|
|
49
|
-
return this.gateway.search(q, options).then((js) => js.map(this.create));
|
|
50
|
-
}
|
|
51
|
-
filter(options) {
|
|
52
|
-
return this.gateway.filter(options).then((js) => js.map((j) => this.create(j)));
|
|
53
|
-
}
|
|
54
|
-
exists(id) {
|
|
55
|
-
return this.gateway.exists(id);
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
59
|
-
0 && (module.exports = {
|
|
60
|
-
Typo
|
|
61
|
-
});
|
|
62
|
-
//# sourceMappingURL=Typo.js.map
|
package/dist/domain/Typo.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/domain/Typo.ts"],"sourcesContent":["import { Exception, FetchOptions, Gateway, Id, Json, JsonValue, Key, List, PageList, Repository } from '../types';\nimport { when } from '../validation';\nimport { View } from '../utils';\n\nexport class Typo<T, Options = FetchOptions> extends Repository<T, Options> {\n constructor(protected view: View<T>, private readonly gateway: Gateway<Options>) {\n super();\n }\n\n create = (j: Json): T => this.view.from(j);\n\n all(options?: Options): Promise<PageList<T>> {\n return this.gateway.all(options).then(js => js.map(this.create));\n }\n\n byId(id: Id): Promise<T> {\n return this.gateway\n .byId(id)\n .then(j => when(j).not.isDefined.reject(Exception.DoesNotExist))\n .then(j => this.create(j));\n }\n\n byIds(...ids: Id[]): Promise<List<T>> {\n return this.gateway.byIds(...ids).then(js => js.map(this.create));\n }\n\n byKey(key: Key, options?: Options): Promise<PageList<T>> {\n return this.gateway.by('key', key, options).then(js => js.map(this.create));\n }\n\n by(key: keyof T, value: JsonValue, options?: Options): Promise<PageList<T>> {\n return this.gateway.by(key.toString(), value, options).then(js => js.map(this.create));\n }\n\n search(q: JsonValue, options?: Options): Promise<PageList<T>> {\n return this.gateway.search(q, options).then(js => js.map(this.create));\n }\n\n filter(options?: Options): Promise<PageList<T>> {\n return this.gateway.filter(options).then(js => js.map(j => this.create(j)));\n }\n\n exists(id: Id): Promise<boolean> {\n return this.gateway.exists(id);\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAAuG;AACvG,wBAAqB;AAGd,MAAM,aAAwC,wBAAuB;AAAA,EAC1E,YAAsB,MAAgC,SAA2B;AAC/E,UAAM;AADc;AAAgC;AAAA,EAEtD;AAAA,EAEA,SAAS,CAAC,MAAe,KAAK,KAAK,KAAK,CAAC;AAAA,EAEzC,IAAI,SAAyC;AAC3C,WAAO,KAAK,QAAQ,IAAI,OAAO,EAAE,KAAK,QAAM,GAAG,IAAI,KAAK,MAAM,CAAC;AAAA,EACjE;AAAA,EAEA,KAAK,IAAoB;AACvB,WAAO,KAAK,QACT,KAAK,EAAE,EACP,KAAK,WAAK,wBAAK,CAAC,EAAE,IAAI,UAAU,OAAO,uBAAU,YAAY,CAAC,EAC9D,KAAK,OAAK,KAAK,OAAO,CAAC,CAAC;AAAA,EAC7B;AAAA,EAEA,SAAS,KAA6B;AACpC,WAAO,KAAK,QAAQ,MAAM,GAAG,GAAG,EAAE,KAAK,QAAM,GAAG,IAAI,KAAK,MAAM,CAAC;AAAA,EAClE;AAAA,EAEA,MAAM,KAAU,SAAyC;AACvD,WAAO,KAAK,QAAQ,GAAG,OAAO,KAAK,OAAO,EAAE,KAAK,QAAM,GAAG,IAAI,KAAK,MAAM,CAAC;AAAA,EAC5E;AAAA,EAEA,GAAG,KAAc,OAAkB,SAAyC;AAC1E,WAAO,KAAK,QAAQ,GAAG,IAAI,SAAS,GAAG,OAAO,OAAO,EAAE,KAAK,QAAM,GAAG,IAAI,KAAK,MAAM,CAAC;AAAA,EACvF;AAAA,EAEA,OAAO,GAAc,SAAyC;AAC5D,WAAO,KAAK,QAAQ,OAAO,GAAG,OAAO,EAAE,KAAK,QAAM,GAAG,IAAI,KAAK,MAAM,CAAC;AAAA,EACvE;AAAA,EAEA,OAAO,SAAyC;AAC9C,WAAO,KAAK,QAAQ,OAAO,OAAO,EAAE,KAAK,QAAM,GAAG,IAAI,OAAK,KAAK,OAAO,CAAC,CAAC,CAAC;AAAA,EAC5E;AAAA,EAEA,OAAO,IAA0B;AAC/B,WAAO,KAAK,QAAQ,OAAO,EAAE;AAAA,EAC/B;AACF;","names":[]}
|