@voxgig/sdkgen-langpack 0.0.1
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/.sdk/model/target/dart.aon +63 -0
- package/.sdk/model/target/haskell.aon +72 -0
- package/.sdk/model/target/lean.aon +91 -0
- package/.sdk/src/cmp/dart/Config_dart.ts +248 -0
- package/.sdk/src/cmp/dart/EntityBase_dart.ts +34 -0
- package/.sdk/src/cmp/dart/EntityOperation_dart.ts +43 -0
- package/.sdk/src/cmp/dart/EntityTypes_dart.ts +207 -0
- package/.sdk/src/cmp/dart/Entity_dart.ts +87 -0
- package/.sdk/src/cmp/dart/Gitignore_dart.ts +34 -0
- package/.sdk/src/cmp/dart/MainEntity_dart.ts +33 -0
- package/.sdk/src/cmp/dart/Main_dart.ts +178 -0
- package/.sdk/src/cmp/dart/Package_dart.ts +82 -0
- package/.sdk/src/cmp/dart/ReadmeEntity_dart.ts +177 -0
- package/.sdk/src/cmp/dart/ReadmeExamplesTest_dart.ts +238 -0
- package/.sdk/src/cmp/dart/ReadmeExplanation_dart.ts +53 -0
- package/.sdk/src/cmp/dart/ReadmeHowto_dart.ts +152 -0
- package/.sdk/src/cmp/dart/ReadmeInstall_dart.ts +59 -0
- package/.sdk/src/cmp/dart/ReadmeIntro_dart.ts +65 -0
- package/.sdk/src/cmp/dart/ReadmeModel_dart.ts +151 -0
- package/.sdk/src/cmp/dart/ReadmeOptions_dart.ts +63 -0
- package/.sdk/src/cmp/dart/ReadmeQuick_dart.ts +225 -0
- package/.sdk/src/cmp/dart/ReadmeRef_dart.ts +397 -0
- package/.sdk/src/cmp/dart/ReadmeTopHowto_dart.ts +24 -0
- package/.sdk/src/cmp/dart/ReadmeTopQuick_dart.ts +106 -0
- package/.sdk/src/cmp/dart/ReadmeTopTest_dart.ts +78 -0
- package/.sdk/src/cmp/dart/SdkError_dart.ts +42 -0
- package/.sdk/src/cmp/dart/TestDirect_dart.ts +516 -0
- package/.sdk/src/cmp/dart/TestEntity_dart.ts +628 -0
- package/.sdk/src/cmp/dart/Test_dart.ts +138 -0
- package/.sdk/src/cmp/dart/fragment/Config.data.fragment.dart +98 -0
- package/.sdk/src/cmp/dart/fragment/Config.fragment.dart +70 -0
- package/.sdk/src/cmp/dart/fragment/Direct.test.fragment.dart +25 -0
- package/.sdk/src/cmp/dart/fragment/Entity.fragment.dart +29 -0
- package/.sdk/src/cmp/dart/fragment/Entity.test.fragment.dart +28 -0
- package/.sdk/src/cmp/dart/fragment/EntityBase.fragment.dart +302 -0
- package/.sdk/src/cmp/dart/fragment/EntityCreateOp.fragment.dart +98 -0
- package/.sdk/src/cmp/dart/fragment/EntityListOp.fragment.dart +90 -0
- package/.sdk/src/cmp/dart/fragment/EntityLoadOp.fragment.dart +102 -0
- package/.sdk/src/cmp/dart/fragment/EntityRemoveOp.fragment.dart +108 -0
- package/.sdk/src/cmp/dart/fragment/EntityUpdateOp.fragment.dart +102 -0
- package/.sdk/src/cmp/dart/fragment/Main.fragment.dart +339 -0
- package/.sdk/src/cmp/dart/fragment/SdkError.fragment.dart +26 -0
- package/.sdk/src/cmp/dart/tsconfig.json +15 -0
- package/.sdk/src/cmp/dart/utility_dart.ts +155 -0
- package/.sdk/src/cmp/haskell/Config_haskell.ts +98 -0
- package/.sdk/src/cmp/haskell/Entity_haskell.ts +13 -0
- package/.sdk/src/cmp/haskell/Gitignore_haskell.ts +27 -0
- package/.sdk/src/cmp/haskell/Main_haskell.ts +123 -0
- package/.sdk/src/cmp/haskell/Package_haskell.ts +60 -0
- package/.sdk/src/cmp/haskell/ReadmeEntity_haskell.ts +186 -0
- package/.sdk/src/cmp/haskell/ReadmeExamplesTest_haskell.ts +135 -0
- package/.sdk/src/cmp/haskell/ReadmeExplanation_haskell.ts +48 -0
- package/.sdk/src/cmp/haskell/ReadmeHowto_haskell.ts +168 -0
- package/.sdk/src/cmp/haskell/ReadmeInstall_haskell.ts +51 -0
- package/.sdk/src/cmp/haskell/ReadmeIntro_haskell.ts +67 -0
- package/.sdk/src/cmp/haskell/ReadmeModel_haskell.ts +162 -0
- package/.sdk/src/cmp/haskell/ReadmeOptions_haskell.ts +74 -0
- package/.sdk/src/cmp/haskell/ReadmeQuick_haskell.ts +241 -0
- package/.sdk/src/cmp/haskell/ReadmeRef_haskell.ts +408 -0
- package/.sdk/src/cmp/haskell/ReadmeTopHowto_haskell.ts +31 -0
- package/.sdk/src/cmp/haskell/ReadmeTopQuick_haskell.ts +104 -0
- package/.sdk/src/cmp/haskell/ReadmeTopTest_haskell.ts +80 -0
- package/.sdk/src/cmp/haskell/Test_haskell.ts +297 -0
- package/.sdk/src/cmp/haskell/tsconfig.json +15 -0
- package/.sdk/src/cmp/haskell/utility_haskell.ts +166 -0
- package/.sdk/src/cmp/lean/Config_lean.ts +93 -0
- package/.sdk/src/cmp/lean/Entity_lean.ts +9 -0
- package/.sdk/src/cmp/lean/Gitignore_lean.ts +18 -0
- package/.sdk/src/cmp/lean/Main_lean.ts +120 -0
- package/.sdk/src/cmp/lean/Package_lean.ts +93 -0
- package/.sdk/src/cmp/lean/ReadmeEntity_lean.ts +29 -0
- package/.sdk/src/cmp/lean/ReadmeExplanation_lean.ts +19 -0
- package/.sdk/src/cmp/lean/ReadmeHowto_lean.ts +25 -0
- package/.sdk/src/cmp/lean/ReadmeInstall_lean.ts +39 -0
- package/.sdk/src/cmp/lean/ReadmeIntro_lean.ts +25 -0
- package/.sdk/src/cmp/lean/ReadmeModel_lean.ts +24 -0
- package/.sdk/src/cmp/lean/ReadmeOptions_lean.ts +22 -0
- package/.sdk/src/cmp/lean/ReadmeQuick_lean.ts +50 -0
- package/.sdk/src/cmp/lean/ReadmeRef_lean.ts +40 -0
- package/.sdk/src/cmp/lean/ReadmeTopHowto_lean.ts +16 -0
- package/.sdk/src/cmp/lean/ReadmeTopQuick_lean.ts +23 -0
- package/.sdk/src/cmp/lean/ReadmeTopTest_lean.ts +19 -0
- package/.sdk/src/cmp/lean/Test_lean.ts +261 -0
- package/.sdk/src/cmp/lean/utility_lean.ts +129 -0
- package/.sdk/tm/dart/LICENSE +22 -0
- package/.sdk/tm/dart/Makefile +50 -0
- package/.sdk/tm/dart/lib/Context.dart +150 -0
- package/.sdk/tm/dart/lib/Control.dart +15 -0
- package/.sdk/tm/dart/lib/Operation.dart +31 -0
- package/.sdk/tm/dart/lib/Point.dart +51 -0
- package/.sdk/tm/dart/lib/Response.dart +32 -0
- package/.sdk/tm/dart/lib/Result.dart +39 -0
- package/.sdk/tm/dart/lib/Spec.dart +49 -0
- package/.sdk/tm/dart/lib/feature/audit/AuditFeature.dart +103 -0
- package/.sdk/tm/dart/lib/feature/base/BaseFeature.dart +76 -0
- package/.sdk/tm/dart/lib/feature/cache/CacheFeature.dart +152 -0
- package/.sdk/tm/dart/lib/feature/clienttrack/ClienttrackFeature.dart +104 -0
- package/.sdk/tm/dart/lib/feature/cost/CostFeature.dart +446 -0
- package/.sdk/tm/dart/lib/feature/debug/DebugFeature.dart +153 -0
- package/.sdk/tm/dart/lib/feature/idempotency/IdempotencyFeature.dart +92 -0
- package/.sdk/tm/dart/lib/feature/log/LogFeature.dart +85 -0
- package/.sdk/tm/dart/lib/feature/metrics/MetricsFeature.dart +103 -0
- package/.sdk/tm/dart/lib/feature/netsim/NetsimFeature.dart +186 -0
- package/.sdk/tm/dart/lib/feature/paging/PagingFeature.dart +240 -0
- package/.sdk/tm/dart/lib/feature/proxy/ProxyFeature.dart +118 -0
- package/.sdk/tm/dart/lib/feature/ratelimit/RatelimitFeature.dart +103 -0
- package/.sdk/tm/dart/lib/feature/rbac/RbacFeature.dart +121 -0
- package/.sdk/tm/dart/lib/feature/retry/RetryFeature.dart +155 -0
- package/.sdk/tm/dart/lib/feature/secrets/SecretsFeature.dart +649 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/capability.dart +105 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/catalog.dart +46 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/config.dart +297 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/depend.dart +198 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/env.dart +144 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/export.dart +58 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/graph.dart +160 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/host.dart +1067 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/order.dart +172 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/plugin.dart +23 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/point.dart +117 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/ref.dart +105 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/resolve.dart +58 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/types.dart +201 -0
- package/.sdk/tm/dart/lib/feature/secrets/plugin/version.dart +116 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/aws.dart +285 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/azuresecrets.dart +178 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/boru.dart +145 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/crypto.dart +194 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/doppler.dart +101 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/gcpsecrets.dart +143 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/hashicorp.dart +190 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/httpjson.dart +363 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/infisical.dart +149 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/onepassword.dart +146 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/secretspec.dart +116 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/plugins/sigv4.dart +237 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/src/addr.dart +138 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/src/json.dart +276 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/src/provider.dart +31 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/src/providers.dart +243 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/src/sekreto.dart +730 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/src/spec.dart +200 -0
- package/.sdk/tm/dart/lib/feature/secrets/sekreto/src/support.dart +217 -0
- package/.sdk/tm/dart/lib/feature/streaming/StreamingFeature.dart +97 -0
- package/.sdk/tm/dart/lib/feature/telemetry/TelemetryFeature.dart +136 -0
- package/.sdk/tm/dart/lib/feature/test/TestFeature.dart +328 -0
- package/.sdk/tm/dart/lib/feature/timeout/TimeoutFeature.dart +104 -0
- package/.sdk/tm/dart/lib/utility/CleanUtility.dart +12 -0
- package/.sdk/tm/dart/lib/utility/DoneUtility.dart +18 -0
- package/.sdk/tm/dart/lib/utility/ErrUtility.dart +46 -0
- package/.sdk/tm/dart/lib/utility/FeatureAddUtility.dart +35 -0
- package/.sdk/tm/dart/lib/utility/FeatureHookUtility.dart +20 -0
- package/.sdk/tm/dart/lib/utility/FeatureInitUtility.dart +9 -0
- package/.sdk/tm/dart/lib/utility/FetcherUtility.dart +104 -0
- package/.sdk/tm/dart/lib/utility/GraphqlUtility.dart +162 -0
- package/.sdk/tm/dart/lib/utility/MakeContextUtility.dart +6 -0
- package/.sdk/tm/dart/lib/utility/MakeErrorUtility.dart +71 -0
- package/.sdk/tm/dart/lib/utility/MakeFetchDefUtility.dart +42 -0
- package/.sdk/tm/dart/lib/utility/MakeOptionsUtility.dart +233 -0
- package/.sdk/tm/dart/lib/utility/MakePointUtility.dart +130 -0
- package/.sdk/tm/dart/lib/utility/MakeRequestUtility.dart +66 -0
- package/.sdk/tm/dart/lib/utility/MakeResponseUtility.dart +59 -0
- package/.sdk/tm/dart/lib/utility/MakeResultUtility.dart +49 -0
- package/.sdk/tm/dart/lib/utility/MakeSpecUtility.dart +77 -0
- package/.sdk/tm/dart/lib/utility/MakeUrlUtility.dart +51 -0
- package/.sdk/tm/dart/lib/utility/ParamUtility.dart +56 -0
- package/.sdk/tm/dart/lib/utility/PrepareAuthUtility.dart +46 -0
- package/.sdk/tm/dart/lib/utility/PrepareBodyUtility.dart +19 -0
- package/.sdk/tm/dart/lib/utility/PrepareHeadersUtility.dart +11 -0
- package/.sdk/tm/dart/lib/utility/PrepareMethodUtility.dart +30 -0
- package/.sdk/tm/dart/lib/utility/PrepareParamsUtility.dart +23 -0
- package/.sdk/tm/dart/lib/utility/PreparePathUtility.dart +9 -0
- package/.sdk/tm/dart/lib/utility/PrepareQueryUtility.dart +18 -0
- package/.sdk/tm/dart/lib/utility/ResultBasicUtility.dart +29 -0
- package/.sdk/tm/dart/lib/utility/ResultBodyUtility.dart +15 -0
- package/.sdk/tm/dart/lib/utility/ResultHeadersUtility.dart +18 -0
- package/.sdk/tm/dart/lib/utility/StructUtility.dart +127 -0
- package/.sdk/tm/dart/lib/utility/TransformRequestUtility.dart +28 -0
- package/.sdk/tm/dart/lib/utility/TransformResponseUtility.dart +44 -0
- package/.sdk/tm/dart/lib/utility/Utility.dart +239 -0
- package/.sdk/tm/dart/lib/utility/voxgig_struct.dart +2462 -0
- package/.sdk/tm/dart/src/feature/README.md +3 -0
- package/.sdk/tm/dart/src/feature/audit/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/base/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/cache/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/clienttrack/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/cost/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/debug/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/idempotency/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/log/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/metrics/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/netsim/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/paging/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/proxy/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/ratelimit/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/rbac/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/retry/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/secrets/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/streaming/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/telemetry/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/test/.gitkeep +0 -0
- package/.sdk/tm/dart/src/feature/timeout/.gitkeep +0 -0
- package/.sdk/tm/dart/test/custom_test.dart +65 -0
- package/.sdk/tm/dart/test/exists_test.dart +12 -0
- package/.sdk/tm/dart/test/feature/harness.dart +347 -0
- package/.sdk/tm/dart/test/feature/secrets/secrets_test.dart +1107 -0
- package/.sdk/tm/dart/test/feature_test.dart +1193 -0
- package/.sdk/tm/dart/test/harness.dart +153 -0
- package/.sdk/tm/dart/test/netsim_test.dart +48 -0
- package/.sdk/tm/dart/test/omni.dart +520 -0
- package/.sdk/tm/dart/test/omni_smoke_test.dart +143 -0
- package/.sdk/tm/dart/test/pipeline_test.dart +608 -0
- package/.sdk/tm/dart/test/primary_test.dart +476 -0
- package/.sdk/tm/dart/test/sdk-test-control.json +19 -0
- package/.sdk/tm/dart/test/struct_test.dart +468 -0
- package/.sdk/tm/dart/test/utility.dart +198 -0
- package/.sdk/tm/dart/test/vendor/omni/omni.dart +7 -0
- package/.sdk/tm/dart/test/vendor/omni/runner.dart +653 -0
- package/.sdk/tm/dart/test/vendor/omni/util.dart +232 -0
- package/.sdk/tm/haskell/LICENSE +21 -0
- package/.sdk/tm/haskell/Makefile +22 -0
- package/.sdk/tm/haskell/VERSION +1 -0
- package/.sdk/tm/haskell/src/SdkFeatures.hs +1440 -0
- package/.sdk/tm/haskell/src/SdkHelpers.hs +337 -0
- package/.sdk/tm/haskell/src/SdkJson.hs +111 -0
- package/.sdk/tm/haskell/src/SdkRuntime.hs +1279 -0
- package/.sdk/tm/haskell/src/SdkTypes.hs +195 -0
- package/.sdk/tm/haskell/src/VoxgigStruct.hs +2299 -0
- package/.sdk/tm/haskell/src/Vregex.hs +237 -0
- package/.sdk/tm/haskell/src/feature/README.md +5 -0
- package/.sdk/tm/haskell/src/feature/audit/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/base/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/cache/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/clienttrack/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/debug/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/idempotency/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/log/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/metrics/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/netsim/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/paging/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/proxy/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/ratelimit/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/rbac/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/retry/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/streaming/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/telemetry/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/test/.gitkeep +0 -0
- package/.sdk/tm/haskell/src/feature/timeout/.gitkeep +0 -0
- package/.sdk/tm/haskell/test/Harness.hs +281 -0
- package/.sdk/tm/haskell/test/OmniResolver.hs +252 -0
- package/.sdk/tm/haskell/test/Runner.hs +49 -0
- package/.sdk/tm/haskell/test/StructCorpus.hs +449 -0
- package/.sdk/tm/haskell/test/TCustomUtility.hs +38 -0
- package/.sdk/tm/haskell/test/TFeature.hs +794 -0
- package/.sdk/tm/haskell/test/TNetsim.hs +50 -0
- package/.sdk/tm/haskell/test/TPipeline.hs +334 -0
- package/.sdk/tm/haskell/test/TPrimaryCorpus.hs +263 -0
- package/.sdk/tm/haskell/test/TPrimaryUtility.hs +386 -0
- package/.sdk/tm/haskell/test/Testutil.hs +59 -0
- package/.sdk/tm/haskell/test/vendor/omni/Omni.hs +1147 -0
- package/.sdk/tm/lean/LICENSE +21 -0
- package/.sdk/tm/lean/Makefile +32 -0
- package/.sdk/tm/lean/VERSION +1 -0
- package/.sdk/tm/lean/src/SdkFeature.lean +171 -0
- package/.sdk/tm/lean/src/SdkFeatures.lean +787 -0
- package/.sdk/tm/lean/src/SdkJson.lean +134 -0
- package/.sdk/tm/lean/src/SdkRuntime.lean +374 -0
- package/.sdk/tm/lean/src/SdkUtility.lean +809 -0
- package/.sdk/tm/lean/src/VoxgigStruct.lean +2880 -0
- package/.sdk/tm/lean/src/Vregex.lean +412 -0
- package/.sdk/tm/lean/src/feature/README.md +5 -0
- package/.sdk/tm/lean/src/feature/audit/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/base/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/cache/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/clienttrack/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/cost/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/debug/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/idempotency/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/log/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/metrics/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/netsim/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/paging/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/proxy/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/ratelimit/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/rbac/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/retry/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/streaming/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/telemetry/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/test/.gitkeep +0 -0
- package/.sdk/tm/lean/src/feature/timeout/.gitkeep +0 -0
- package/.sdk/tm/lean/test/OmniResolver.lean +358 -0
- package/.sdk/tm/lean/test/OmniSmoke.lean +174 -0
- package/.sdk/tm/lean/test/StructCorpus.lean +368 -0
- package/.sdk/tm/lean/test/TFeature.lean +281 -0
- package/.sdk/tm/lean/test/TPrimaryUtility.lean +227 -0
- package/.sdk/tm/lean/test/vendor/omni/Omni.lean +997 -0
- package/LICENSE +21 -0
- package/README.md +104 -0
- package/package.json +78 -0
- package/sdkgen-package.json +22 -0
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
// Custom utility injection. Port of ts test/utility/Custom.test.ts: user
|
|
2
|
+
// options.utility entries become reachable through the client's utility
|
|
3
|
+
// (via byName, Dart's analogue of dynamic property access).
|
|
4
|
+
|
|
5
|
+
import 'harness.dart';
|
|
6
|
+
|
|
7
|
+
import '../lib/ProjectNameSDK.dart';
|
|
8
|
+
|
|
9
|
+
void tests() {
|
|
10
|
+
describe('Custom', () {
|
|
11
|
+
test('basic', (t) async {
|
|
12
|
+
final client = ProjectNameSDK.test({}, {
|
|
13
|
+
'apikey': 'APIKEY01',
|
|
14
|
+
|
|
15
|
+
// NOTE: original utility members must remain in place.
|
|
16
|
+
'utility': {
|
|
17
|
+
'auth': () => {'util': 'AUTH'},
|
|
18
|
+
'body': () => {'util': 'BODY'},
|
|
19
|
+
'contextify': () => {'util': 'CONTEXTIFY'},
|
|
20
|
+
'findparam': () => {'util': 'FINDPARAM'},
|
|
21
|
+
'fullurl': () => {'util': 'FULLURL'},
|
|
22
|
+
'headers': () => {'util': 'HEADERS'},
|
|
23
|
+
'method': () => {'util': 'METHOD'},
|
|
24
|
+
'operator': () => {'util': 'OPERATOR'},
|
|
25
|
+
'params': () => {'util': 'PARAMS'},
|
|
26
|
+
'query': () => {'util': 'QUERY'},
|
|
27
|
+
'reqform': () => {'util': 'REQFORM'},
|
|
28
|
+
'request': () => {'util': 'REQUEST'},
|
|
29
|
+
'resbasic': () => {'util': 'RESBASIC'},
|
|
30
|
+
'resbody': () => {'util': 'RESBODY'},
|
|
31
|
+
'resform': () => {'util': 'RESFORM'},
|
|
32
|
+
'resheaders': () => {'util': 'RESHEADERS'},
|
|
33
|
+
'response': () => {'util': 'RESPONSE'},
|
|
34
|
+
'result': () => {'util': 'RESULT'},
|
|
35
|
+
'spec': () => {'util': 'SPEC'},
|
|
36
|
+
}
|
|
37
|
+
});
|
|
38
|
+
|
|
39
|
+
final u = client.utility();
|
|
40
|
+
|
|
41
|
+
equal('AUTH', u.byName('auth')()['util']);
|
|
42
|
+
equal('BODY', u.byName('body')()['util']);
|
|
43
|
+
equal('CONTEXTIFY', u.byName('contextify')()['util']);
|
|
44
|
+
equal('FINDPARAM', u.byName('findparam')()['util']);
|
|
45
|
+
equal('FULLURL', u.byName('fullurl')()['util']);
|
|
46
|
+
equal('HEADERS', u.byName('headers')()['util']);
|
|
47
|
+
equal('METHOD', u.byName('method')()['util']);
|
|
48
|
+
equal('OPERATOR', u.byName('operator')()['util']);
|
|
49
|
+
equal('PARAMS', u.byName('params')()['util']);
|
|
50
|
+
equal('QUERY', u.byName('query')()['util']);
|
|
51
|
+
equal('REQFORM', u.byName('reqform')()['util']);
|
|
52
|
+
equal('RESBASIC', u.byName('resbasic')()['util']);
|
|
53
|
+
equal('RESBODY', u.byName('resbody')()['util']);
|
|
54
|
+
equal('RESFORM', u.byName('resform')()['util']);
|
|
55
|
+
equal('RESHEADERS', u.byName('resheaders')()['util']);
|
|
56
|
+
equal('RESPONSE', u.byName('response')()['util']);
|
|
57
|
+
equal('RESULT', u.byName('result')()['util']);
|
|
58
|
+
equal('SPEC', u.byName('spec')()['util']);
|
|
59
|
+
|
|
60
|
+
// Standard members are untouched.
|
|
61
|
+
ok(null != u.byName('makeSpec'));
|
|
62
|
+
ok(null != u.byName('fetcher'));
|
|
63
|
+
});
|
|
64
|
+
});
|
|
65
|
+
}
|
|
@@ -0,0 +1,347 @@
|
|
|
1
|
+
// Offline feature-test harness for the generated SDK.
|
|
2
|
+
//
|
|
3
|
+
// Feature behaviour (retry, cache, rbac, telemetry, ...) is unit-tested by
|
|
4
|
+
// driving each feature class through a faithful miniature of the real
|
|
5
|
+
// operation pipeline against a configurable mock transport — the same hook
|
|
6
|
+
// order and short-circuit rules as the generated entity op code, but with
|
|
7
|
+
// no live server and no API-specific fixtures. Feature instances are built
|
|
8
|
+
// via `config.makeFeature`, so only features actually present in this SDK
|
|
9
|
+
// are exercised (see `hasFeature`). Port of ts test/feature/harness.ts.
|
|
10
|
+
|
|
11
|
+
import 'dart:async';
|
|
12
|
+
|
|
13
|
+
import '../../lib/ProjectNameSDK.dart';
|
|
14
|
+
import '../../lib/ProjectNameError.dart';
|
|
15
|
+
import '../../lib/Config.dart';
|
|
16
|
+
import '../../lib/Operation.dart';
|
|
17
|
+
import '../../lib/Response.dart';
|
|
18
|
+
import '../../lib/Result.dart';
|
|
19
|
+
import '../../lib/Spec.dart';
|
|
20
|
+
import '../../lib/utility/ErrUtility.dart';
|
|
21
|
+
import '../../lib/utility/Utility.dart';
|
|
22
|
+
|
|
23
|
+
// True when this SDK was generated with the named feature.
|
|
24
|
+
bool hasFeature(String name) => null != config.feature[name];
|
|
25
|
+
|
|
26
|
+
// A deterministic virtual clock: `now()` advances only when `sleep(ms)` is
|
|
27
|
+
// called, so timing-based features can be asserted without real delays.
|
|
28
|
+
class Clock {
|
|
29
|
+
num t;
|
|
30
|
+
Clock([this.t = 0]);
|
|
31
|
+
num now() => t;
|
|
32
|
+
void sleep(dynamic ms) {
|
|
33
|
+
t += (ms is num ? ms : 0);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
void advance(num ms) {
|
|
37
|
+
t += ms;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
num get time => t;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
Clock makeClock([num start = 0]) => Clock(start);
|
|
44
|
+
|
|
45
|
+
// Build a transport-shaped response the pipeline understands.
|
|
46
|
+
Map<String, dynamic> makeResponse(int status,
|
|
47
|
+
[dynamic data, Map<String, dynamic>? headers]) {
|
|
48
|
+
final h = <String, dynamic>{};
|
|
49
|
+
(headers ?? {}).forEach((k, v) => h[k.toLowerCase()] = v);
|
|
50
|
+
return {
|
|
51
|
+
'status': status,
|
|
52
|
+
'statusText': status < 400 ? 'OK' : 'ERR',
|
|
53
|
+
'body': 'not-used',
|
|
54
|
+
'json': () => data,
|
|
55
|
+
'headers': h,
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
typedef ServerFn = dynamic Function(dynamic ctx, dynamic url, dynamic fetchdef);
|
|
60
|
+
|
|
61
|
+
ServerFn defaultServer() {
|
|
62
|
+
return (dynamic _ctx, dynamic _url, dynamic fetchdef) {
|
|
63
|
+
final method = (fetchdef['method'] ?? 'GET').toString().toUpperCase();
|
|
64
|
+
if ('GET' == method) {
|
|
65
|
+
return makeResponse(200, {'ok': true, 'method': method});
|
|
66
|
+
}
|
|
67
|
+
return makeResponse(200, {'ok': true, 'method': method, 'echo': fetchdef['body']});
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
String defaultMethod(String op) {
|
|
72
|
+
if ('create' == op) return 'POST';
|
|
73
|
+
if ('update' == op) return 'PATCH';
|
|
74
|
+
if ('remove' == op) return 'DELETE';
|
|
75
|
+
return 'GET';
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
// A minimal client shape: exactly the surface features touch.
|
|
79
|
+
class HarnessClient {
|
|
80
|
+
String mode = 'test';
|
|
81
|
+
List features = [];
|
|
82
|
+
final Map<String, dynamic> track = {};
|
|
83
|
+
Map<String, dynamic> opts = {};
|
|
84
|
+
Utility util = Utility();
|
|
85
|
+
|
|
86
|
+
dynamic options() => opts;
|
|
87
|
+
dynamic utility() => util;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
class Harness {
|
|
91
|
+
late HarnessClient client;
|
|
92
|
+
late Utility utility;
|
|
93
|
+
dynamic rootctx;
|
|
94
|
+
late Future<dynamic> Function(Map<String, dynamic> o) op;
|
|
95
|
+
late Future<void> Function() ready;
|
|
96
|
+
late dynamic Function(String name) feature;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
// Construct a fake client wired with the given features (in init order) and
|
|
100
|
+
// a mini operation pipeline. `features` is a list of {name, options} maps.
|
|
101
|
+
Harness makeClient({
|
|
102
|
+
required List<Map<String, dynamic>> features,
|
|
103
|
+
ServerFn? server,
|
|
104
|
+
String? mode,
|
|
105
|
+
String? base,
|
|
106
|
+
Map<String, dynamic>? headers,
|
|
107
|
+
// Extra client options, written OVER the defaults below - a null value
|
|
108
|
+
// overwrites too, which is how `auth: null` (the documented credential
|
|
109
|
+
// suppression) is expressed here.
|
|
110
|
+
Map<String, dynamic>? options,
|
|
111
|
+
}) {
|
|
112
|
+
final b = base ?? 'http://api.test';
|
|
113
|
+
final srv = server ?? defaultServer();
|
|
114
|
+
|
|
115
|
+
final utility = Utility();
|
|
116
|
+
utility.fetcher = srv;
|
|
117
|
+
|
|
118
|
+
final client = HarnessClient();
|
|
119
|
+
client.mode = mode ?? 'test';
|
|
120
|
+
client.util = utility;
|
|
121
|
+
client.opts = {
|
|
122
|
+
'base': b,
|
|
123
|
+
'headers': headers ?? {},
|
|
124
|
+
'feature': {},
|
|
125
|
+
// The real makeOptions always produces an `auth` map unless the caller
|
|
126
|
+
// suppressed it with `auth: null`, and a feature that writes the
|
|
127
|
+
// Authorization header reads its prefix from here. Without it the
|
|
128
|
+
// harness said "auth suppressed" for every client it built.
|
|
129
|
+
'auth': <String, dynamic>{'prefix': ''},
|
|
130
|
+
};
|
|
131
|
+
|
|
132
|
+
if (null != options) {
|
|
133
|
+
options.forEach((k, v) => client.opts[k] = v);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
var idseq = 0;
|
|
137
|
+
final rootShared = {};
|
|
138
|
+
|
|
139
|
+
dynamic makeCtx(Map<String, dynamic> over) {
|
|
140
|
+
idseq++;
|
|
141
|
+
final ctx = utility.makeContext({
|
|
142
|
+
'client': client,
|
|
143
|
+
'utility': utility,
|
|
144
|
+
// The LIVE options map, as the generated constructor puts on its own
|
|
145
|
+
// root context (`rootctx.options = _options`). A feature that reads
|
|
146
|
+
// ctx.options - the seam the secrets feature uses for `auth`,
|
|
147
|
+
// `apikey`, `base` and `system.fetch` - saw null without it.
|
|
148
|
+
'options': client.opts,
|
|
149
|
+
'ctrl': over['ctrl'] ?? {},
|
|
150
|
+
'entity': over['entity'],
|
|
151
|
+
'shared': rootShared,
|
|
152
|
+
});
|
|
153
|
+
ctx.id = 'C' + idseq.toString();
|
|
154
|
+
final opdef = over['op'];
|
|
155
|
+
ctx.op = null == opdef ? null : Operation(opdef);
|
|
156
|
+
return ctx;
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
Future<void> featureHook(dynamic ctx, String name) async {
|
|
160
|
+
final resp = <Future>[];
|
|
161
|
+
for (final f in client.features) {
|
|
162
|
+
final r = (f as dynamic).invokeHook(name, ctx);
|
|
163
|
+
if (r is Future) {
|
|
164
|
+
resp.add(r);
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
if (resp.isNotEmpty) {
|
|
168
|
+
await Future.wait(resp);
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
final rootctx = makeCtx({
|
|
173
|
+
'op': {'name': 'root', 'entity': '_'},
|
|
174
|
+
});
|
|
175
|
+
|
|
176
|
+
// Instantiate + init the requested features (skipping any not present in
|
|
177
|
+
// this SDK), then fire PostConstruct.
|
|
178
|
+
for (final fspec in features) {
|
|
179
|
+
final fname = fspec['name'].toString();
|
|
180
|
+
if (!hasFeature(fname)) {
|
|
181
|
+
continue;
|
|
182
|
+
}
|
|
183
|
+
final f = config.makeFeature(fname);
|
|
184
|
+
final fopts = <String, dynamic>{'active': true};
|
|
185
|
+
final fo = fspec['options'];
|
|
186
|
+
if (fo is Map) {
|
|
187
|
+
fo.forEach((k, v) => fopts[k.toString()] = v);
|
|
188
|
+
}
|
|
189
|
+
(client.opts['feature'] as Map)[f.name] = fopts;
|
|
190
|
+
f.init(rootctx, fopts);
|
|
191
|
+
client.features.add(f);
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
String buildUrl(dynamic sp) {
|
|
195
|
+
final q = sp.query ?? {};
|
|
196
|
+
final keys = (q as Map)
|
|
197
|
+
.keys
|
|
198
|
+
.where((k) => null != q[k])
|
|
199
|
+
.map((k) => k.toString())
|
|
200
|
+
.toList()
|
|
201
|
+
..sort();
|
|
202
|
+
final qs = keys
|
|
203
|
+
.map((k) =>
|
|
204
|
+
Uri.encodeComponent(k) + '=' + Uri.encodeComponent(q[k].toString()))
|
|
205
|
+
.join('&');
|
|
206
|
+
return sp.base.toString() +
|
|
207
|
+
(sp.path ?? '').toString() +
|
|
208
|
+
('' == qs ? '' : '?' + qs);
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
Future<void> populateResult(dynamic ctx, dynamic response) async {
|
|
212
|
+
final result = Result({});
|
|
213
|
+
ctx.result = result;
|
|
214
|
+
|
|
215
|
+
if (iserr(response)) {
|
|
216
|
+
result.err = response;
|
|
217
|
+
return;
|
|
218
|
+
}
|
|
219
|
+
result.status = response['status'];
|
|
220
|
+
result.statusText = response['statusText'];
|
|
221
|
+
final h = response['headers'];
|
|
222
|
+
if (h is Map) {
|
|
223
|
+
final out = <String, dynamic>{};
|
|
224
|
+
h.forEach((k, v) => out[k.toString()] = v);
|
|
225
|
+
result.headers = out;
|
|
226
|
+
}
|
|
227
|
+
final jsonFn = response['json'];
|
|
228
|
+
if (jsonFn is Function) {
|
|
229
|
+
result.body = await Future.value(jsonFn());
|
|
230
|
+
}
|
|
231
|
+
result.resdata = result.body;
|
|
232
|
+
if (result.status is num && result.status >= 400) {
|
|
233
|
+
result.err = ProjectNameError('request_status',
|
|
234
|
+
'request: ' + result.status.toString() + ': ' + result.statusText.toString(), ctx);
|
|
235
|
+
} else if (null != response['err']) {
|
|
236
|
+
result.err = response['err'];
|
|
237
|
+
}
|
|
238
|
+
if (null == result.err) {
|
|
239
|
+
result.ok = true;
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
// Run one operation through the mini pipeline (mirrors the generated
|
|
244
|
+
// entity op fragment: hook, short-circuit, make*, hook, ...).
|
|
245
|
+
Future<dynamic> op(Map<String, dynamic> o) async {
|
|
246
|
+
final entity = (o['entity'] ?? 'widget').toString();
|
|
247
|
+
final opname = (o['op'] ?? 'load').toString();
|
|
248
|
+
final method = (o['method'] ?? defaultMethod(opname)).toString();
|
|
249
|
+
|
|
250
|
+
final ctx = makeCtx({
|
|
251
|
+
'op': {'name': opname, 'entity': entity},
|
|
252
|
+
'entity': {'name': entity},
|
|
253
|
+
'ctrl': o['ctrl'] ?? {},
|
|
254
|
+
});
|
|
255
|
+
|
|
256
|
+
await featureHook(ctx, 'PostConstructEntity');
|
|
257
|
+
|
|
258
|
+
try {
|
|
259
|
+
await featureHook(ctx, 'PrePoint');
|
|
260
|
+
if (iserr(ctx.out['point'])) {
|
|
261
|
+
throw ctx.out['point'];
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
await featureHook(ctx, 'PreSpec');
|
|
265
|
+
final headersMap = <String, dynamic>{};
|
|
266
|
+
(headers ?? {}).forEach((k, v) => headersMap[k.toString()] = v);
|
|
267
|
+
final oh = o['headers'];
|
|
268
|
+
if (oh is Map) {
|
|
269
|
+
oh.forEach((k, v) => headersMap[k.toString()] = v);
|
|
270
|
+
}
|
|
271
|
+
ctx.spec = ctx.out['spec'] ??
|
|
272
|
+
Spec({
|
|
273
|
+
'method': method,
|
|
274
|
+
'base': b,
|
|
275
|
+
'path': o['path'] ?? ('/' + entity),
|
|
276
|
+
'params': {},
|
|
277
|
+
'headers': headersMap,
|
|
278
|
+
'query': o['query'] ?? {},
|
|
279
|
+
'body': o['body'],
|
|
280
|
+
'step': 'start',
|
|
281
|
+
});
|
|
282
|
+
|
|
283
|
+
await featureHook(ctx, 'PreRequest');
|
|
284
|
+
ctx.spec.url = buildUrl(ctx.spec);
|
|
285
|
+
|
|
286
|
+
dynamic response;
|
|
287
|
+
if (null != ctx.out['request']) {
|
|
288
|
+
response = ctx.out['request'];
|
|
289
|
+
} else {
|
|
290
|
+
final fetchdef = <String, dynamic>{
|
|
291
|
+
'url': ctx.spec.url,
|
|
292
|
+
'method': ctx.spec.method,
|
|
293
|
+
'headers': ctx.spec.headers,
|
|
294
|
+
'body': ctx.spec.body,
|
|
295
|
+
};
|
|
296
|
+
response =
|
|
297
|
+
await Future.value(utility.fetcher(ctx, fetchdef['url'], fetchdef));
|
|
298
|
+
}
|
|
299
|
+
ctx.response = iserr(response)
|
|
300
|
+
? Response({'err': response})
|
|
301
|
+
: (response is Map ? Response(response) : response);
|
|
302
|
+
|
|
303
|
+
await featureHook(ctx, 'PreResponse');
|
|
304
|
+
await populateResult(ctx, response);
|
|
305
|
+
await featureHook(ctx, 'PreResult');
|
|
306
|
+
await featureHook(ctx, 'PreDone');
|
|
307
|
+
|
|
308
|
+
if (null != ctx.result && true == ctx.result.ok) {
|
|
309
|
+
return {
|
|
310
|
+
'ok': true,
|
|
311
|
+
'data': ctx.result.resdata,
|
|
312
|
+
'result': ctx.result,
|
|
313
|
+
'ctx': ctx,
|
|
314
|
+
};
|
|
315
|
+
}
|
|
316
|
+
throw (null != ctx.result ? ctx.result.err : null) ??
|
|
317
|
+
ctx.error('op_failed', 'operation failed');
|
|
318
|
+
} catch (err) {
|
|
319
|
+
if (ctx.ctrl is Map) {
|
|
320
|
+
ctx.ctrl['err'] = err;
|
|
321
|
+
}
|
|
322
|
+
await featureHook(ctx, 'PreUnexpected');
|
|
323
|
+
return {'ok': false, 'error': err, 'result': ctx.result, 'ctx': ctx};
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
final boot = featureHook(rootctx, 'PostConstruct');
|
|
328
|
+
|
|
329
|
+
final h = Harness();
|
|
330
|
+
h.client = client;
|
|
331
|
+
h.utility = utility;
|
|
332
|
+
h.rootctx = rootctx;
|
|
333
|
+
h.op = op;
|
|
334
|
+
h.ready = () async {
|
|
335
|
+
await boot;
|
|
336
|
+
};
|
|
337
|
+
h.feature = (String name) {
|
|
338
|
+
for (final f in client.features) {
|
|
339
|
+
if ((f as dynamic).name == name) {
|
|
340
|
+
return f;
|
|
341
|
+
}
|
|
342
|
+
}
|
|
343
|
+
return null;
|
|
344
|
+
};
|
|
345
|
+
|
|
346
|
+
return h;
|
|
347
|
+
}
|