From c8f6ad00254e802b18a10a3efb2aa22f80ca99e9 Mon Sep 17 00:00:00 2001 From: Weidong Xu Date: Tue, 25 Feb 2025 10:38:09 +0800 Subject: [PATCH 01/11] http-client-java, bump tcgc 0.51.3 (#6102) --- .../emitter/src/code-model-builder.ts | 57 +- .../package.json | 2 +- .../http-client-generator-test/package.json | 2 +- .../java/tsptest/naming/models/RunObject.java | 10 +- ...astError.java => RunObjectLastError1.java} | 18 +- .../tsptest-naming_apiview_properties.json | 2 +- packages/http-client-java/package-lock.json | 591 +++++++++++------- packages/http-client-java/package.json | 16 +- 8 files changed, 401 insertions(+), 297 deletions(-) rename packages/http-client-java/generator/http-client-generator-test/src/main/java/tsptest/naming/models/{RunObjectLastError.java => RunObjectLastError1.java} (77%) diff --git a/packages/http-client-java/emitter/src/code-model-builder.ts b/packages/http-client-java/emitter/src/code-model-builder.ts index 429580f9e42..6b540e89d53 100644 --- a/packages/http-client-java/emitter/src/code-model-builder.ts +++ b/packages/http-client-java/emitter/src/code-model-builder.ts @@ -997,37 +997,30 @@ export class CodeModelBuilder { for (const response of responses) { const bodyType = response.type; if (bodyType && bodyType.kind === "model") { - const itemClientName = sdkMethod.response.resultPath; - const nextLinkClientName = sdkMethod.nextLinkPath; - let itemSerializedName: string | undefined = undefined; let nextLinkSerializedName: string | undefined = undefined; + const itemSegments = sdkMethod.response.resultSegments; + const nextLinkSegments = sdkMethod.pagingMetadata.nextLinkSegments; + + // TODO: in future the property could be nested, so that the "itemSegments" or "nextLinkSegments" would contain more than 1 element + if (itemSegments) { + // "itemsSegments" should exist for "paging"/"lropaging" + const lastSegment = itemSegments[itemSegments.length - 1]; + if (lastSegment.kind === "property") { + itemSerializedName = getPropertySerializedName(lastSegment); + } + } + if (nextLinkSegments) { + const lastSegment = nextLinkSegments[nextLinkSegments.length - 1]; + if (lastSegment.kind === "property") { + nextLinkSerializedName = getPropertySerializedName(lastSegment); + } + } + op.responses?.forEach((r) => { if (r instanceof SchemaResponse) { this.trackSchemaUsage(r.schema, { usage: [SchemaContext.Paged] }); - - // find serializedName for items and nextLink - if (r.schema instanceof ObjectSchema) { - r.schema.properties?.forEach((p) => { - if ( - itemClientName && - !itemSerializedName && - p.serializedName && - p.language.default.name === itemClientName - ) { - itemSerializedName = p.serializedName; - } - if ( - nextLinkClientName && - !nextLinkSerializedName && - p.serializedName && - p.language.default.name === nextLinkClientName - ) { - nextLinkSerializedName = p.serializedName; - } - }); - } } }); @@ -1099,12 +1092,16 @@ export class CodeModelBuilder { useNewPollStrategy && lroMetadata.finalStep && lroMetadata.finalStep.kind === "pollingSuccessProperty" && - lroMetadata.finalResponse.resultSegments && - lroMetadata.finalResponse.resultSegments[0].kind === "property" + lroMetadata.finalResponse.resultSegments ) { - finalResultPropertySerializedName = getPropertySerializedName( - lroMetadata.finalResponse.resultSegments[0], - ); + // TODO: in future the property could be nested, so that the "resultSegments" would contain more than 1 element + const lastSegment = + lroMetadata.finalResponse.resultSegments[ + lroMetadata.finalResponse.resultSegments.length - 1 + ]; + if (lastSegment.kind === "property") { + finalResultPropertySerializedName = getPropertySerializedName(lastSegment); + } } } diff --git a/packages/http-client-java/generator/http-client-generator-clientcore-test/package.json b/packages/http-client-java/generator/http-client-generator-clientcore-test/package.json index c268c3f1af6..a1e212c0fbb 100644 --- a/packages/http-client-java/generator/http-client-generator-clientcore-test/package.json +++ b/packages/http-client-java/generator/http-client-generator-clientcore-test/package.json @@ -24,7 +24,7 @@ "@typespec/openapi": "~0.65.0", "@typespec/xml": "~0.65.0", "@azure-tools/typespec-azure-core": "~0.51.0", - "@azure-tools/typespec-client-generator-core": "~0.51.0", + "@azure-tools/typespec-client-generator-core": "~0.51.3", "@azure-tools/typespec-azure-resource-manager": "~0.51.0", "@azure-tools/typespec-autorest": "~0.51.0" }, diff --git a/packages/http-client-java/generator/http-client-generator-test/package.json b/packages/http-client-java/generator/http-client-generator-test/package.json index 0e93597c435..b8ddfbe3281 100644 --- a/packages/http-client-java/generator/http-client-generator-test/package.json +++ b/packages/http-client-java/generator/http-client-generator-test/package.json @@ -25,7 +25,7 @@ "@typespec/openapi": "~0.65.0", "@typespec/xml": "~0.65.0", "@azure-tools/typespec-azure-core": "~0.51.0", - "@azure-tools/typespec-client-generator-core": "~0.51.0", + "@azure-tools/typespec-client-generator-core": "~0.51.3", "@azure-tools/typespec-azure-resource-manager": "~0.51.0", "@azure-tools/typespec-autorest": "~0.51.0" }, diff --git a/packages/http-client-java/generator/http-client-generator-test/src/main/java/tsptest/naming/models/RunObject.java b/packages/http-client-java/generator/http-client-generator-test/src/main/java/tsptest/naming/models/RunObject.java index 8c7d0dea1f3..a70e28e4029 100644 --- a/packages/http-client-java/generator/http-client-generator-test/src/main/java/tsptest/naming/models/RunObject.java +++ b/packages/http-client-java/generator/http-client-generator-test/src/main/java/tsptest/naming/models/RunObject.java @@ -21,7 +21,7 @@ public final class RunObject implements JsonSerializable { * The last_error property. */ @Generated - private final RunObjectLastError lastError; + private final RunObjectLastError1 lastError; /** * Creates an instance of RunObject class. @@ -29,7 +29,7 @@ public final class RunObject implements JsonSerializable { * @param lastError the lastError value to set. */ @Generated - private RunObject(RunObjectLastError lastError) { + private RunObject(RunObjectLastError1 lastError) { this.lastError = lastError; } @@ -39,7 +39,7 @@ private RunObject(RunObjectLastError lastError) { * @return the lastError value. */ @Generated - public RunObjectLastError getLastError() { + public RunObjectLastError1 getLastError() { return this.lastError; } @@ -66,13 +66,13 @@ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException { @Generated public static RunObject fromJson(JsonReader jsonReader) throws IOException { return jsonReader.readObject(reader -> { - RunObjectLastError lastError = null; + RunObjectLastError1 lastError = null; while (reader.nextToken() != JsonToken.END_OBJECT) { String fieldName = reader.getFieldName(); reader.nextToken(); if ("last_error".equals(fieldName)) { - lastError = RunObjectLastError.fromJson(reader); + lastError = RunObjectLastError1.fromJson(reader); } else { reader.skipChildren(); } diff --git a/packages/http-client-java/generator/http-client-generator-test/src/main/java/tsptest/naming/models/RunObjectLastError.java b/packages/http-client-java/generator/http-client-generator-test/src/main/java/tsptest/naming/models/RunObjectLastError1.java similarity index 77% rename from packages/http-client-java/generator/http-client-generator-test/src/main/java/tsptest/naming/models/RunObjectLastError.java rename to packages/http-client-java/generator/http-client-generator-test/src/main/java/tsptest/naming/models/RunObjectLastError1.java index 05f968913da..82dcbf0868b 100644 --- a/packages/http-client-java/generator/http-client-generator-test/src/main/java/tsptest/naming/models/RunObjectLastError.java +++ b/packages/http-client-java/generator/http-client-generator-test/src/main/java/tsptest/naming/models/RunObjectLastError1.java @@ -13,10 +13,10 @@ import java.io.IOException; /** - * The RunObjectLastError model. + * The RunObjectLastError1 model. */ @Immutable -public final class RunObjectLastError implements JsonSerializable { +public final class RunObjectLastError1 implements JsonSerializable { /* * The code property. */ @@ -24,12 +24,12 @@ public final class RunObjectLastError implements JsonSerializable { RunObjectLastErrorCode code = null; while (reader.nextToken() != JsonToken.END_OBJECT) { @@ -77,7 +77,7 @@ public static RunObjectLastError fromJson(JsonReader jsonReader) throws IOExcept reader.skipChildren(); } } - return new RunObjectLastError(code); + return new RunObjectLastError1(code); }); } } diff --git a/packages/http-client-java/generator/http-client-generator-test/src/main/resources/META-INF/tsptest-naming_apiview_properties.json b/packages/http-client-java/generator/http-client-generator-test/src/main/resources/META-INF/tsptest-naming_apiview_properties.json index af92943d717..6156b25f37b 100644 --- a/packages/http-client-java/generator/http-client-generator-test/src/main/resources/META-INF/tsptest-naming_apiview_properties.json +++ b/packages/http-client-java/generator/http-client-generator-test/src/main/resources/META-INF/tsptest-naming_apiview_properties.json @@ -22,7 +22,7 @@ "tsptest.naming.models.RequestParameters": "TspTest.Naming.Request.parameters.anonymous", "tsptest.naming.models.RequestParametersType": "TspTest.Naming.Request.parameters.type.anonymous", "tsptest.naming.models.RunObject": "TspTest.Naming.RunObject", - "tsptest.naming.models.RunObjectLastError": "TspTest.Naming.RunObject.last_error.anonymous", + "tsptest.naming.models.RunObjectLastError1": "TspTest.Naming.RunObject.last_error.anonymous", "tsptest.naming.models.RunObjectLastErrorCode": "TspTest.Naming.RunObject.last_error.code.anonymous", "tsptest.naming.models.TypesModel": "TspTest.Naming.TypesModel" } diff --git a/packages/http-client-java/package-lock.json b/packages/http-client-java/package-lock.json index a48c53fb094..369b8e60e34 100644 --- a/packages/http-client-java/package-lock.json +++ b/packages/http-client-java/package-lock.json @@ -19,24 +19,24 @@ "@azure-tools/typespec-azure-core": "0.51.0", "@azure-tools/typespec-azure-resource-manager": "0.51.0", "@azure-tools/typespec-azure-rulesets": "0.51.0", - "@azure-tools/typespec-client-generator-core": "0.51.0", - "@microsoft/api-extractor": "^7.50.0", + "@azure-tools/typespec-client-generator-core": "0.51.3", + "@microsoft/api-extractor": "^7.50.1", "@microsoft/api-extractor-model": "^7.30.3", "@types/js-yaml": "~4.0.9", "@types/lodash": "~4.17.15", - "@types/node": "~22.13.1", - "@typespec/compiler": "0.65.0", + "@types/node": "~22.13.5", + "@typespec/compiler": "0.65.3", "@typespec/http": "0.65.0", "@typespec/openapi": "0.65.0", "@typespec/rest": "0.65.0", "@typespec/spector": "0.1.0-alpha.7", "@typespec/versioning": "0.65.0", - "@vitest/coverage-v8": "^3.0.5", - "@vitest/ui": "^3.0.5", + "@vitest/coverage-v8": "^3.0.6", + "@vitest/ui": "^3.0.6", "c8": "~10.1.3", "rimraf": "~6.0.1", "typescript": "~5.7.3", - "vitest": "^3.0.5" + "vitest": "^3.0.6" }, "engines": { "node": ">=18.0.0" @@ -44,7 +44,7 @@ "peerDependencies": { "@azure-tools/typespec-autorest": ">=0.50.0 <1.0.0", "@azure-tools/typespec-azure-core": ">=0.50.0 <1.0.0", - "@azure-tools/typespec-client-generator-core": ">=0.50.3 <1.0.0", + "@azure-tools/typespec-client-generator-core": ">=0.51.3 <1.0.0", "@typespec/compiler": ">=0.64.0 <1.0.0", "@typespec/http": ">=0.64.0 <1.0.0", "@typespec/openapi": ">=0.64.0 <1.0.0", @@ -185,9 +185,9 @@ } }, "node_modules/@azure-tools/typespec-client-generator-core": { - "version": "0.51.0", - "resolved": "https://registry.npmjs.org/@azure-tools/typespec-client-generator-core/-/typespec-client-generator-core-0.51.0.tgz", - "integrity": "sha512-nhnG5EmZmWlvofKipVz4PJEhq95MlO8SqYINvU33SQOI+/8QBp3Y0JV7NJPxKObWdOPZli98VZ/glLEV8YX8YQ==", + "version": "0.51.3", + "resolved": "https://registry.npmjs.org/@azure-tools/typespec-client-generator-core/-/typespec-client-generator-core-0.51.3.tgz", + "integrity": "sha512-gwHpnZsUdfJAiJ3vlLzZeBQB/2Z/CKvL8144v9mOBuqrTnF4NVr+KWahFY6GrH+5/2gWxcVVKBYsGOS6eTdKuA==", "dev": true, "license": "MIT", "dependencies": { @@ -1156,9 +1156,9 @@ } }, "node_modules/@microsoft/api-extractor": { - "version": "7.50.0", - "resolved": "https://registry.npmjs.org/@microsoft/api-extractor/-/api-extractor-7.50.0.tgz", - "integrity": "sha512-Ds/PHTiVzuENQsmXrJKkSdfgNkr/SDG/2rDef0AWl3BchAnXdO7gXaYsAkNx4gWiC4OngNA3fQfd3+BcQxP1DQ==", + "version": "7.50.1", + "resolved": "https://registry.npmjs.org/@microsoft/api-extractor/-/api-extractor-7.50.1.tgz", + "integrity": "sha512-L18vz0ARLNaBLKwWe0DdEf7eijDsb7ERZspgZK7PxclLoQrc+9hJZo8y4OVfCHxNVyxlwVywY2WdE/3pOFViLQ==", "dev": true, "license": "MIT", "dependencies": { @@ -1174,7 +1174,7 @@ "resolve": "~1.22.1", "semver": "~7.5.4", "source-map": "~0.6.1", - "typescript": "5.7.2" + "typescript": "5.7.3" }, "bin": { "api-extractor": "bin/api-extractor" @@ -1241,20 +1241,6 @@ "node": ">=10" } }, - "node_modules/@microsoft/api-extractor/node_modules/typescript": { - "version": "5.7.2", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.7.2.tgz", - "integrity": "sha512-i5t66RHxDvVN40HfDd1PsEThGNnlMCMT3jMUuoh9/0TaqWevNontacunWyN02LA9/fIbEWlcHZcgTKb9QoaLfg==", - "dev": true, - "license": "Apache-2.0", - "bin": { - "tsc": "bin/tsc", - "tsserver": "bin/tsserver" - }, - "engines": { - "node": ">=14.17" - } - }, "node_modules/@microsoft/tsdoc": { "version": "0.15.1", "resolved": "https://registry.npmjs.org/@microsoft/tsdoc/-/tsdoc-0.15.1.tgz", @@ -1330,16 +1316,16 @@ "license": "ISC" }, "node_modules/@npmcli/arborist": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/arborist/-/arborist-9.0.0.tgz", - "integrity": "sha512-ZFsI/VJ7wJ2rTksLNJ9xqr75Ste/wiKvW+7w12ZGbcT67xWii97yS+aDlh3edNhqlqoXvdzYG4hTNui81VxJCA==", + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/@npmcli/arborist/-/arborist-8.0.0.tgz", + "integrity": "sha512-APDXxtXGSftyXibl0dZ3CuZYmmVnkiN3+gkqwXshY4GKC2rof2+Lg0sGuj6H1p2YfBAKd7PRwuMVhu6Pf/nQ/A==", "license": "ISC", "dependencies": { "@isaacs/string-locale-compare": "^1.1.0", "@npmcli/fs": "^4.0.0", "@npmcli/installed-package-contents": "^3.0.0", "@npmcli/map-workspaces": "^4.0.1", - "@npmcli/metavuln-calculator": "^9.0.0", + "@npmcli/metavuln-calculator": "^8.0.0", "@npmcli/name-from-folder": "^3.0.0", "@npmcli/node-gyp": "^4.0.0", "@npmcli/package-json": "^6.0.1", @@ -1350,6 +1336,7 @@ "cacache": "^19.0.1", "common-ancestor-path": "^1.0.1", "hosted-git-info": "^8.0.0", + "json-parse-even-better-errors": "^4.0.0", "json-stringify-nice": "^1.1.4", "lru-cache": "^10.2.2", "minimatch": "^9.0.4", @@ -1358,7 +1345,7 @@ "npm-package-arg": "^12.0.0", "npm-pick-manifest": "^10.0.0", "npm-registry-fetch": "^18.0.1", - "pacote": "^21.0.0", + "pacote": "^19.0.0", "parse-conflict-json": "^4.0.0", "proc-log": "^5.0.0", "proggy": "^3.0.0", @@ -1368,13 +1355,13 @@ "semver": "^7.3.7", "ssri": "^12.0.0", "treeverse": "^3.0.0", - "walk-up-path": "^4.0.0" + "walk-up-path": "^3.0.1" }, "bin": { "arborist": "bin/index.js" }, "engines": { - "node": "^20.17.0 || >=22.9.0" + "node": "^18.17.0 || >=20.5.0" } }, "node_modules/@npmcli/arborist/node_modules/lru-cache": { @@ -1411,9 +1398,9 @@ } }, "node_modules/@npmcli/git": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/@npmcli/git/-/git-6.0.1.tgz", - "integrity": "sha512-BBWMMxeQzalmKadyimwb2/VVQyJB01PH0HhVSNLHNBDZN/M/h/02P6f8fxedIiFhpMj11SO9Ep5tKTBE7zL2nw==", + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/@npmcli/git/-/git-6.0.3.tgz", + "integrity": "sha512-GUYESQlxZRAdhs3UhbB6pVRNUELQOHXwK9ruDkwmCv2aZ5y0SApQzUJCg02p3A7Ue2J5hxvlk1YI53c00NmRyQ==", "license": "ISC", "dependencies": { "@npmcli/promise-spawn": "^8.0.0", @@ -1421,7 +1408,6 @@ "lru-cache": "^10.0.1", "npm-pick-manifest": "^10.0.0", "proc-log": "^5.0.0", - "promise-inflight": "^1.0.1", "promise-retry": "^2.0.1", "semver": "^7.3.5", "which": "^5.0.0" @@ -1564,19 +1550,146 @@ } }, "node_modules/@npmcli/metavuln-calculator": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/@npmcli/metavuln-calculator/-/metavuln-calculator-9.0.0.tgz", - "integrity": "sha512-znLKqdy1ZEGNK3VB9j/RzGyb/P0BJb3fGpvEbHIAyBAXsps2l1ce8SVHfsGAFLl9s8072PxafqTn7RC8wSnQPg==", + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/@npmcli/metavuln-calculator/-/metavuln-calculator-8.0.1.tgz", + "integrity": "sha512-WXlJx9cz3CfHSt9W9Opi1PTFc4WZLFomm5O8wekxQZmkyljrBRwATwDxfC9iOXJwYVmfiW1C1dUe0W2aN0UrSg==", "license": "ISC", "dependencies": { "cacache": "^19.0.0", "json-parse-even-better-errors": "^4.0.0", - "pacote": "^21.0.0", + "pacote": "^20.0.0", "proc-log": "^5.0.0", "semver": "^7.3.5" }, "engines": { - "node": "^20.17.0 || >=22.9.0" + "node": "^18.17.0 || >=20.5.0" + } + }, + "node_modules/@npmcli/metavuln-calculator/node_modules/chownr": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz", + "integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==", + "license": "ISC", + "engines": { + "node": ">=10" + } + }, + "node_modules/@npmcli/metavuln-calculator/node_modules/minizlib": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-2.1.2.tgz", + "integrity": "sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==", + "license": "MIT", + "dependencies": { + "minipass": "^3.0.0", + "yallist": "^4.0.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@npmcli/metavuln-calculator/node_modules/minizlib/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@npmcli/metavuln-calculator/node_modules/mkdirp": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", + "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", + "license": "MIT", + "bin": { + "mkdirp": "bin/cmd.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@npmcli/metavuln-calculator/node_modules/pacote": { + "version": "20.0.0", + "resolved": "https://registry.npmjs.org/pacote/-/pacote-20.0.0.tgz", + "integrity": "sha512-pRjC5UFwZCgx9kUFDVM9YEahv4guZ1nSLqwmWiLUnDbGsjs+U5w7z6Uc8HNR1a6x8qnu5y9xtGE6D1uAuYz+0A==", + "license": "ISC", + "dependencies": { + "@npmcli/git": "^6.0.0", + "@npmcli/installed-package-contents": "^3.0.0", + "@npmcli/package-json": "^6.0.0", + "@npmcli/promise-spawn": "^8.0.0", + "@npmcli/run-script": "^9.0.0", + "cacache": "^19.0.0", + "fs-minipass": "^3.0.0", + "minipass": "^7.0.2", + "npm-package-arg": "^12.0.0", + "npm-packlist": "^9.0.0", + "npm-pick-manifest": "^10.0.0", + "npm-registry-fetch": "^18.0.0", + "proc-log": "^5.0.0", + "promise-retry": "^2.0.1", + "sigstore": "^3.0.0", + "ssri": "^12.0.0", + "tar": "^6.1.11" + }, + "bin": { + "pacote": "bin/index.js" + }, + "engines": { + "node": "^18.17.0 || >=20.5.0" + } + }, + "node_modules/@npmcli/metavuln-calculator/node_modules/tar": { + "version": "6.2.1", + "resolved": "https://registry.npmjs.org/tar/-/tar-6.2.1.tgz", + "integrity": "sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A==", + "license": "ISC", + "dependencies": { + "chownr": "^2.0.0", + "fs-minipass": "^2.0.0", + "minipass": "^5.0.0", + "minizlib": "^2.1.1", + "mkdirp": "^1.0.3", + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/@npmcli/metavuln-calculator/node_modules/tar/node_modules/fs-minipass": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", + "integrity": "sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==", + "license": "ISC", + "dependencies": { + "minipass": "^3.0.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@npmcli/metavuln-calculator/node_modules/tar/node_modules/fs-minipass/node_modules/minipass": { + "version": "3.3.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.6.tgz", + "integrity": "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw==", + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@npmcli/metavuln-calculator/node_modules/tar/node_modules/minipass": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-5.0.0.tgz", + "integrity": "sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ==", + "license": "ISC", + "engines": { + "node": ">=8" } }, "node_modules/@npmcli/name-from-folder": { @@ -1802,9 +1915,9 @@ "license": "MIT" }, "node_modules/@rollup/rollup-android-arm-eabi": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.34.4.tgz", - "integrity": "sha512-gGi5adZWvjtJU7Axs//CWaQbQd/vGy8KGcnEaCWiyCqxWYDxwIlAHFuSe6Guoxtd0SRvSfVTDMPd5H+4KE2kKA==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.34.8.tgz", + "integrity": "sha512-q217OSE8DTp8AFHuNHXo0Y86e1wtlfVrXiAlwkIvGRQv9zbc6mE3sjIVfwI8sYUyNxwOg0j/Vm1RKM04JcWLJw==", "cpu": [ "arm" ], @@ -1816,9 +1929,9 @@ ] }, "node_modules/@rollup/rollup-android-arm64": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.34.4.tgz", - "integrity": "sha512-1aRlh1gqtF7vNPMnlf1vJKk72Yshw5zknR/ZAVh7zycRAGF2XBMVDAHmFQz/Zws5k++nux3LOq/Ejj1WrDR6xg==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.34.8.tgz", + "integrity": "sha512-Gigjz7mNWaOL9wCggvoK3jEIUUbGul656opstjaUSGC3eT0BM7PofdAJaBfPFWWkXNVAXbaQtC99OCg4sJv70Q==", "cpu": [ "arm64" ], @@ -1830,9 +1943,9 @@ ] }, "node_modules/@rollup/rollup-darwin-arm64": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.34.4.tgz", - "integrity": "sha512-drHl+4qhFj+PV/jrQ78p9ch6A0MfNVZScl/nBps5a7u01aGf/GuBRrHnRegA9bP222CBDfjYbFdjkIJ/FurvSQ==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.34.8.tgz", + "integrity": "sha512-02rVdZ5tgdUNRxIUrFdcMBZQoaPMrxtwSb+/hOfBdqkatYHR3lZ2A2EGyHq2sGOd0Owk80oV3snlDASC24He3Q==", "cpu": [ "arm64" ], @@ -1844,9 +1957,9 @@ ] }, "node_modules/@rollup/rollup-darwin-x64": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.34.4.tgz", - "integrity": "sha512-hQqq/8QALU6t1+fbNmm6dwYsa0PDD4L5r3TpHx9dNl+aSEMnIksHZkSO3AVH+hBMvZhpumIGrTFj8XCOGuIXjw==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.34.8.tgz", + "integrity": "sha512-qIP/elwR/tq/dYRx3lgwK31jkZvMiD6qUtOycLhTzCvrjbZ3LjQnEM9rNhSGpbLXVJYQ3rq39A6Re0h9tU2ynw==", "cpu": [ "x64" ], @@ -1858,9 +1971,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-arm64": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.34.4.tgz", - "integrity": "sha512-/L0LixBmbefkec1JTeAQJP0ETzGjFtNml2gpQXA8rpLo7Md+iXQzo9kwEgzyat5Q+OG/C//2B9Fx52UxsOXbzw==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.34.8.tgz", + "integrity": "sha512-IQNVXL9iY6NniYbTaOKdrlVP3XIqazBgJOVkddzJlqnCpRi/yAeSOa8PLcECFSQochzqApIOE1GHNu3pCz+BDA==", "cpu": [ "arm64" ], @@ -1872,9 +1985,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-x64": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.34.4.tgz", - "integrity": "sha512-6Rk3PLRK+b8L/M6m/x6Mfj60LhAUcLJ34oPaxufA+CfqkUrDoUPQYFdRrhqyOvtOKXLJZJwxlOLbQjNYQcRQfw==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.34.8.tgz", + "integrity": "sha512-TYXcHghgnCqYFiE3FT5QwXtOZqDj5GmaFNTNt3jNC+vh22dc/ukG2cG+pi75QO4kACohZzidsq7yKTKwq/Jq7Q==", "cpu": [ "x64" ], @@ -1886,9 +1999,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-gnueabihf": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.34.4.tgz", - "integrity": "sha512-kmT3x0IPRuXY/tNoABp2nDvI9EvdiS2JZsd4I9yOcLCCViKsP0gB38mVHOhluzx+SSVnM1KNn9k6osyXZhLoCA==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.34.8.tgz", + "integrity": "sha512-A4iphFGNkWRd+5m3VIGuqHnG3MVnqKe7Al57u9mwgbyZ2/xF9Jio72MaY7xxh+Y87VAHmGQr73qoKL9HPbXj1g==", "cpu": [ "arm" ], @@ -1900,9 +2013,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-musleabihf": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.34.4.tgz", - "integrity": "sha512-3iSA9tx+4PZcJH/Wnwsvx/BY4qHpit/u2YoZoXugWVfc36/4mRkgGEoRbRV7nzNBSCOgbWMeuQ27IQWgJ7tRzw==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.34.8.tgz", + "integrity": "sha512-S0lqKLfTm5u+QTxlFiAnb2J/2dgQqRy/XvziPtDd1rKZFXHTyYLoVL58M/XFwDI01AQCDIevGLbQrMAtdyanpA==", "cpu": [ "arm" ], @@ -1914,9 +2027,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-gnu": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.34.4.tgz", - "integrity": "sha512-7CwSJW+sEhM9sESEk+pEREF2JL0BmyCro8UyTq0Kyh0nu1v0QPNY3yfLPFKChzVoUmaKj8zbdgBxUhBRR+xGxg==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.34.8.tgz", + "integrity": "sha512-jpz9YOuPiSkL4G4pqKrus0pn9aYwpImGkosRKwNi+sJSkz+WU3anZe6hi73StLOQdfXYXC7hUfsQlTnjMd3s1A==", "cpu": [ "arm64" ], @@ -1928,9 +2041,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-musl": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.34.4.tgz", - "integrity": "sha512-GZdafB41/4s12j8Ss2izofjeFXRAAM7sHCb+S4JsI9vaONX/zQ8cXd87B9MRU/igGAJkKvmFmJJBeeT9jJ5Cbw==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.34.8.tgz", + "integrity": "sha512-KdSfaROOUJXgTVxJNAZ3KwkRc5nggDk+06P6lgi1HLv1hskgvxHUKZ4xtwHkVYJ1Rep4GNo+uEfycCRRxht7+Q==", "cpu": [ "arm64" ], @@ -1942,9 +2055,9 @@ ] }, "node_modules/@rollup/rollup-linux-loongarch64-gnu": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.34.4.tgz", - "integrity": "sha512-uuphLuw1X6ur11675c2twC6YxbzyLSpWggvdawTUamlsoUv81aAXRMPBC1uvQllnBGls0Qt5Siw8reSIBnbdqQ==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.34.8.tgz", + "integrity": "sha512-NyF4gcxwkMFRjgXBM6g2lkT58OWztZvw5KkV2K0qqSnUEqCVcqdh2jN4gQrTn/YUpAcNKyFHfoOZEer9nwo6uQ==", "cpu": [ "loong64" ], @@ -1956,9 +2069,9 @@ ] }, "node_modules/@rollup/rollup-linux-powerpc64le-gnu": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.34.4.tgz", - "integrity": "sha512-KvLEw1os2gSmD6k6QPCQMm2T9P2GYvsMZMRpMz78QpSoEevHbV/KOUbI/46/JRalhtSAYZBYLAnT9YE4i/l4vg==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-powerpc64le-gnu/-/rollup-linux-powerpc64le-gnu-4.34.8.tgz", + "integrity": "sha512-LMJc999GkhGvktHU85zNTDImZVUCJ1z/MbAJTnviiWmmjyckP5aQsHtcujMjpNdMZPT2rQEDBlJfubhs3jsMfw==", "cpu": [ "ppc64" ], @@ -1970,9 +2083,9 @@ ] }, "node_modules/@rollup/rollup-linux-riscv64-gnu": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.34.4.tgz", - "integrity": "sha512-wcpCLHGM9yv+3Dql/CI4zrY2mpQ4WFergD3c9cpRowltEh5I84pRT/EuHZsG0In4eBPPYthXnuR++HrFkeqwkA==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.34.8.tgz", + "integrity": "sha512-xAQCAHPj8nJq1PI3z8CIZzXuXCstquz7cIOL73HHdXiRcKk8Ywwqtx2wrIy23EcTn4aZ2fLJNBB8d0tQENPCmw==", "cpu": [ "riscv64" ], @@ -1984,9 +2097,9 @@ ] }, "node_modules/@rollup/rollup-linux-s390x-gnu": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.34.4.tgz", - "integrity": "sha512-nLbfQp2lbJYU8obhRQusXKbuiqm4jSJteLwfjnunDT5ugBKdxqw1X9KWwk8xp1OMC6P5d0WbzxzhWoznuVK6XA==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.34.8.tgz", + "integrity": "sha512-DdePVk1NDEuc3fOe3dPPTb+rjMtuFw89gw6gVWxQFAuEqqSdDKnrwzZHrUYdac7A7dXl9Q2Vflxpme15gUWQFA==", "cpu": [ "s390x" ], @@ -1998,9 +2111,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-gnu": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.34.4.tgz", - "integrity": "sha512-JGejzEfVzqc/XNiCKZj14eb6s5w8DdWlnQ5tWUbs99kkdvfq9btxxVX97AaxiUX7xJTKFA0LwoS0KU8C2faZRg==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.34.8.tgz", + "integrity": "sha512-8y7ED8gjxITUltTUEJLQdgpbPh1sUQ0kMTmufRF/Ns5tI9TNMNlhWtmPKKHCU0SilX+3MJkZ0zERYYGIVBYHIA==", "cpu": [ "x64" ], @@ -2012,9 +2125,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-musl": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.34.4.tgz", - "integrity": "sha512-/iFIbhzeyZZy49ozAWJ1ZR2KW6ZdYUbQXLT4O5n1cRZRoTpwExnHLjlurDXXPKEGxiAg0ujaR9JDYKljpr2fDg==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.34.8.tgz", + "integrity": "sha512-SCXcP0ZpGFIe7Ge+McxY5zKxiEI5ra+GT3QRxL0pMMtxPfpyLAKleZODi1zdRHkz5/BhueUrYtYVgubqe9JBNQ==", "cpu": [ "x64" ], @@ -2026,9 +2139,9 @@ ] }, "node_modules/@rollup/rollup-win32-arm64-msvc": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.34.4.tgz", - "integrity": "sha512-qORc3UzoD5UUTneiP2Afg5n5Ti1GAW9Gp5vHPxzvAFFA3FBaum9WqGvYXGf+c7beFdOKNos31/41PRMUwh1tpA==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.34.8.tgz", + "integrity": "sha512-YHYsgzZgFJzTRbth4h7Or0m5O74Yda+hLin0irAIobkLQFRQd1qWmnoVfwmKm9TXIZVAD0nZ+GEb2ICicLyCnQ==", "cpu": [ "arm64" ], @@ -2040,9 +2153,9 @@ ] }, "node_modules/@rollup/rollup-win32-ia32-msvc": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.34.4.tgz", - "integrity": "sha512-5g7E2PHNK2uvoD5bASBD9aelm44nf1w4I5FEI7MPHLWcCSrR8JragXZWgKPXk5i2FU3JFfa6CGZLw2RrGBHs2Q==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.34.8.tgz", + "integrity": "sha512-r3NRQrXkHr4uWy5TOjTpTYojR9XmF0j/RYgKCef+Ag46FWUTltm5ziticv8LdNsDMehjJ543x/+TJAek/xBA2w==", "cpu": [ "ia32" ], @@ -2054,9 +2167,9 @@ ] }, "node_modules/@rollup/rollup-win32-x64-msvc": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.34.4.tgz", - "integrity": "sha512-p0scwGkR4kZ242xLPBuhSckrJ734frz6v9xZzD+kHVYRAkSUmdSLCIJRfql6H5//aF8Q10K+i7q8DiPfZp0b7A==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.34.8.tgz", + "integrity": "sha512-U0FaE5O1BCpZSeE6gBl3c5ObhePQSfk9vDRToMmTkbhCOgW4jqvtS5LGyQ76L1fH8sM0keRp4uDTsbjiUyjk0g==", "cpu": [ "x64" ], @@ -2353,9 +2466,9 @@ "license": "MIT" }, "node_modules/@types/node": { - "version": "22.13.1", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.13.1.tgz", - "integrity": "sha512-jK8uzQlrvXqEU91UxiK5J7pKHyzgnI1Qnl0QDHIgVGuolJhRb9EEl28Cj9b3rGR8B2lhFCtvIm5os8lFnO/1Ew==", + "version": "22.13.5", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.13.5.tgz", + "integrity": "sha512-+lTU0PxZXn0Dr1NBtC7Y8cR21AJr87dLLU953CWA6pMxxv/UDc7jYAY90upcrie1nRcD6XNG5HOYEDtgW5TxAg==", "dev": true, "license": "MIT", "dependencies": { @@ -2370,13 +2483,13 @@ "license": "MIT" }, "node_modules/@typespec/compiler": { - "version": "0.65.0", - "resolved": "https://registry.npmjs.org/@typespec/compiler/-/compiler-0.65.0.tgz", - "integrity": "sha512-L86mb0aVxhh7z+8Ea1W28TKuGbZk+/ELXjnQOJK4RWXXCoVtxictSXTTX4mZPFoEwOUde5+jQ2Pf8YuUD2frUw==", + "version": "0.65.3", + "resolved": "https://registry.npmjs.org/@typespec/compiler/-/compiler-0.65.3.tgz", + "integrity": "sha512-hPiTMyXYe1ips8o/1OcrzKkdrwFt3NinrD70AldhR6cPNz9O9y9r+TdE62c3VpPNknuamNVJn1jTkOWVhUczxA==", "license": "MIT", "dependencies": { "@babel/code-frame": "~7.26.2", - "@npmcli/arborist": "^9.0.0", + "@npmcli/arborist": "^8.0.0", "ajv": "~8.17.1", "change-case": "~5.4.4", "globby": "~14.0.2", @@ -2597,9 +2710,9 @@ } }, "node_modules/@vitest/coverage-v8": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@vitest/coverage-v8/-/coverage-v8-3.0.5.tgz", - "integrity": "sha512-zOOWIsj5fHh3jjGwQg+P+J1FW3s4jBu1Zqga0qW60yutsBtqEqNEJKWYh7cYn1yGD+1bdPsPdC/eL4eVK56xMg==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/@vitest/coverage-v8/-/coverage-v8-3.0.6.tgz", + "integrity": "sha512-JRTlR8Bw+4BcmVTICa7tJsxqphAktakiLsAmibVLAWbu1lauFddY/tXeM6sAyl1cgkPuXtpnUgaCPhTdz1Qapg==", "dev": true, "license": "MIT", "dependencies": { @@ -2620,8 +2733,8 @@ "url": "https://opencollective.com/vitest" }, "peerDependencies": { - "@vitest/browser": "3.0.5", - "vitest": "3.0.5" + "@vitest/browser": "3.0.6", + "vitest": "3.0.6" }, "peerDependenciesMeta": { "@vitest/browser": { @@ -2630,15 +2743,15 @@ } }, "node_modules/@vitest/expect": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@vitest/expect/-/expect-3.0.5.tgz", - "integrity": "sha512-nNIOqupgZ4v5jWuQx2DSlHLEs7Q4Oh/7AYwNyE+k0UQzG7tSmjPXShUikn1mpNGzYEN2jJbTvLejwShMitovBA==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/@vitest/expect/-/expect-3.0.6.tgz", + "integrity": "sha512-zBduHf/ja7/QRX4HdP1DSq5XrPgdN+jzLOwaTq/0qZjYfgETNFCKf9nOAp2j3hmom3oTbczuUzrzg9Hafh7hNg==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/spy": "3.0.5", - "@vitest/utils": "3.0.5", - "chai": "^5.1.2", + "@vitest/spy": "3.0.6", + "@vitest/utils": "3.0.6", + "chai": "^5.2.0", "tinyrainbow": "^2.0.0" }, "funding": { @@ -2646,13 +2759,13 @@ } }, "node_modules/@vitest/mocker": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-3.0.5.tgz", - "integrity": "sha512-CLPNBFBIE7x6aEGbIjaQAX03ZZlBMaWwAjBdMkIf/cAn6xzLTiM3zYqO/WAbieEjsAZir6tO71mzeHZoodThvw==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-3.0.6.tgz", + "integrity": "sha512-KPztr4/tn7qDGZfqlSPQoF2VgJcKxnDNhmfR3VgZ6Fy1bO8T9Fc1stUiTXtqz0yG24VpD00pZP5f8EOFknjNuQ==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/spy": "3.0.5", + "@vitest/spy": "3.0.6", "estree-walker": "^3.0.3", "magic-string": "^0.30.17" }, @@ -2673,9 +2786,9 @@ } }, "node_modules/@vitest/pretty-format": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@vitest/pretty-format/-/pretty-format-3.0.5.tgz", - "integrity": "sha512-CjUtdmpOcm4RVtB+up8r2vVDLR16Mgm/bYdkGFe3Yj/scRfCpbSi2W/BDSDcFK7ohw8UXvjMbOp9H4fByd/cOA==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/@vitest/pretty-format/-/pretty-format-3.0.6.tgz", + "integrity": "sha512-Zyctv3dbNL+67qtHfRnUE/k8qxduOamRfAL1BurEIQSyOEFffoMvx2pnDSSbKAAVxY0Ej2J/GH2dQKI0W2JyVg==", "dev": true, "license": "MIT", "dependencies": { @@ -2686,38 +2799,38 @@ } }, "node_modules/@vitest/runner": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@vitest/runner/-/runner-3.0.5.tgz", - "integrity": "sha512-BAiZFityFexZQi2yN4OX3OkJC6scwRo8EhRB0Z5HIGGgd2q+Nq29LgHU/+ovCtd0fOfXj5ZI6pwdlUmC5bpi8A==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/@vitest/runner/-/runner-3.0.6.tgz", + "integrity": "sha512-JopP4m/jGoaG1+CBqubV/5VMbi7L+NQCJTu1J1Pf6YaUbk7bZtaq5CX7p+8sY64Sjn1UQ1XJparHfcvTTdu9cA==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/utils": "3.0.5", - "pathe": "^2.0.2" + "@vitest/utils": "3.0.6", + "pathe": "^2.0.3" }, "funding": { "url": "https://opencollective.com/vitest" } }, "node_modules/@vitest/snapshot": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@vitest/snapshot/-/snapshot-3.0.5.tgz", - "integrity": "sha512-GJPZYcd7v8QNUJ7vRvLDmRwl+a1fGg4T/54lZXe+UOGy47F9yUfE18hRCtXL5aHN/AONu29NGzIXSVFh9K0feA==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/@vitest/snapshot/-/snapshot-3.0.6.tgz", + "integrity": "sha512-qKSmxNQwT60kNwwJHMVwavvZsMGXWmngD023OHSgn873pV0lylK7dwBTfYP7e4URy5NiBCHHiQGA9DHkYkqRqg==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/pretty-format": "3.0.5", + "@vitest/pretty-format": "3.0.6", "magic-string": "^0.30.17", - "pathe": "^2.0.2" + "pathe": "^2.0.3" }, "funding": { "url": "https://opencollective.com/vitest" } }, "node_modules/@vitest/spy": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-3.0.5.tgz", - "integrity": "sha512-5fOzHj0WbUNqPK6blI/8VzZdkBlQLnT25knX0r4dbZI9qoZDf3qAdjoMmDcLG5A83W6oUUFJgUd0EYBc2P5xqg==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-3.0.6.tgz", + "integrity": "sha512-HfOGx/bXtjy24fDlTOpgiAEJbRfFxoX3zIGagCqACkFKKZ/TTOE6gYMKXlqecvxEndKFuNHcHqP081ggZ2yM0Q==", "dev": true, "license": "MIT", "dependencies": { @@ -2728,36 +2841,36 @@ } }, "node_modules/@vitest/ui": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@vitest/ui/-/ui-3.0.5.tgz", - "integrity": "sha512-gw2noso6WI+2PeMVCZFntdATS6xl9qhQcbhkPQ9sOmx/Xn0f4Bx4KDSbD90jpJPF0l5wOzSoGCmKyVR3W612mg==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/@vitest/ui/-/ui-3.0.6.tgz", + "integrity": "sha512-N4M2IUG2Q5LCeX4OWs48pQF4P3qsFejmDTc6QWGRFTLPrEe5EvM5HN0WSUnGAmuzQpSWv7ItfSsIJIWaEM2wpQ==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/utils": "3.0.5", + "@vitest/utils": "3.0.6", "fflate": "^0.8.2", "flatted": "^3.3.2", - "pathe": "^2.0.2", - "sirv": "^3.0.0", - "tinyglobby": "^0.2.10", + "pathe": "^2.0.3", + "sirv": "^3.0.1", + "tinyglobby": "^0.2.11", "tinyrainbow": "^2.0.0" }, "funding": { "url": "https://opencollective.com/vitest" }, "peerDependencies": { - "vitest": "3.0.5" + "vitest": "3.0.6" } }, "node_modules/@vitest/utils": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@vitest/utils/-/utils-3.0.5.tgz", - "integrity": "sha512-N9AX0NUoUtVwKwy21JtwzaqR5L5R5A99GAbrHfCCXK1lp593i/3AZAXhSP43wRQuxYsflrdzEfXZFo1reR1Nkg==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/@vitest/utils/-/utils-3.0.6.tgz", + "integrity": "sha512-18ktZpf4GQFTbf9jK543uspU03Q2qya7ZGya5yiZ0Gx0nnnalBvd5ZBislbl2EhLjM8A8rt4OilqKG7QwcGkvQ==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/pretty-format": "3.0.5", - "loupe": "^3.1.2", + "@vitest/pretty-format": "3.0.6", + "loupe": "^3.1.3", "tinyrainbow": "^2.0.0" }, "funding": { @@ -3267,9 +3380,9 @@ } }, "node_modules/chai": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/chai/-/chai-5.1.2.tgz", - "integrity": "sha512-aGtmf24DW6MLHHG5gCx4zaI3uBq3KRtxeVs0DjFH6Z0rDNbsvTxFASFvdj79pxjxZ8/5u3PIiN3IwEIQkiiuPw==", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/chai/-/chai-5.2.0.tgz", + "integrity": "sha512-mCuXncKXk5iCLhfhwTc0izo0gtEmpz5CtG2y8GiOINBlMVS6v8TMRc5TaLWKS6692m9+dVVfzgeVxR5UxWHTYw==", "dev": true, "license": "MIT", "dependencies": { @@ -4157,9 +4270,9 @@ } }, "node_modules/flatted": { - "version": "3.3.2", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.3.2.tgz", - "integrity": "sha512-AiwGJM8YcNOaobumgtng+6NHuOqC3A7MixFeDafM3X9cIUM+xUXoS5Vfgf+OihAYe20fxqNM9yPBXJzRtZ/4eA==", + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.3.3.tgz", + "integrity": "sha512-GX+ysw4PBCz0PzosHDepZGANEuFCMLrnRTiEy9McGjmkCQYwRq4A/X786G/fjM/+OjsWSU1ZrY5qyARZmO/uwg==", "dev": true, "license": "ISC" }, @@ -5881,9 +5994,9 @@ } }, "node_modules/mrmime": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/mrmime/-/mrmime-2.0.0.tgz", - "integrity": "sha512-eu38+hdgojoyq63s+yTpN4XMBdt5l8HhMhc4VKLO9KM5caLIBvUm4thi7fFaxyTmCKeNnXZ5pAlBwCUnhA09uw==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/mrmime/-/mrmime-2.0.1.tgz", + "integrity": "sha512-Y3wQdFg2Va6etvQ5I82yUhGdsKrcYox6p7FfL1LbK2J4V01F9TGlepTIhnK24t7koZibmg82KGglhA1XK5IsLQ==", "dev": true, "license": "MIT", "engines": { @@ -6172,15 +6285,15 @@ } }, "node_modules/npm-packlist": { - "version": "10.0.0", - "resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-10.0.0.tgz", - "integrity": "sha512-rht9U6nS8WOBDc53eipZNPo5qkAV4X2rhKE2Oj1DYUQ3DieXfj0mKkVmjnf3iuNdtMd8WfLdi2L6ASkD/8a+Kg==", + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/npm-packlist/-/npm-packlist-9.0.0.tgz", + "integrity": "sha512-8qSayfmHJQTx3nJWYbbUmflpyarbLMBc6LCAjYsiGtXxDB68HaZpb8re6zeaLGxZzDuMdhsg70jryJe+RrItVQ==", "license": "ISC", "dependencies": { "ignore-walk": "^7.0.0" }, "engines": { - "node": "^20.17.0 || >=22.9.0" + "node": "^18.17.0 || >=20.5.0" } }, "node_modules/npm-pick-manifest": { @@ -6387,9 +6500,9 @@ "integrity": "sha512-dATvCeZN/8wQsGywez1mzHtTlP22H8OEfPrVMLNr4/eGa+ijtLn/6M5f0dY8UKNrC2O9UCU6SSoG3qRKnt7STw==" }, "node_modules/pacote": { - "version": "21.0.0", - "resolved": "https://registry.npmjs.org/pacote/-/pacote-21.0.0.tgz", - "integrity": "sha512-lcqexq73AMv6QNLo7SOpz0JJoaGdS3rBFgF122NZVl1bApo2mfu+XzUBU/X/XsiJu+iUmKpekRayqQYAs+PhkA==", + "version": "19.0.1", + "resolved": "https://registry.npmjs.org/pacote/-/pacote-19.0.1.tgz", + "integrity": "sha512-zIpxWAsr/BvhrkSruspG8aqCQUUrWtpwx0GjiRZQhEM/pZXrigA32ElN3vTcCPUDOFmHr6SFxwYrvVUs5NTEUg==", "license": "ISC", "dependencies": { "@npmcli/git": "^6.0.0", @@ -6401,7 +6514,7 @@ "fs-minipass": "^3.0.0", "minipass": "^7.0.2", "npm-package-arg": "^12.0.0", - "npm-packlist": "^10.0.0", + "npm-packlist": "^9.0.0", "npm-pick-manifest": "^10.0.0", "npm-registry-fetch": "^18.0.0", "proc-log": "^5.0.0", @@ -6414,7 +6527,7 @@ "pacote": "bin/index.js" }, "engines": { - "node": "^20.17.0 || >=22.9.0" + "node": "^18.17.0 || >=20.5.0" } }, "node_modules/pacote/node_modules/chownr": { @@ -6596,9 +6709,9 @@ } }, "node_modules/pathe": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/pathe/-/pathe-2.0.2.tgz", - "integrity": "sha512-15Ztpk+nov8DR524R4BF7uEuzESgzUEAV4Ah7CUMNGXdE5ELuvxElxGXndBl32vMSsWa1jpNf22Z+Er3sKwq+w==", + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/pathe/-/pathe-2.0.3.tgz", + "integrity": "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==", "dev": true, "license": "MIT" }, @@ -6649,9 +6762,9 @@ } }, "node_modules/postcss": { - "version": "8.5.1", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.1.tgz", - "integrity": "sha512-6oz2beyjc5VMn/KV1pPw8fliQkhBXrVn1Z3TVyqZxU8kZpzEKhBdmCFqI6ZbmGtamQvQGuU1sgPTk8ZrXDD7jQ==", + "version": "8.5.3", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.5.3.tgz", + "integrity": "sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==", "dev": true, "funding": [ { @@ -6748,12 +6861,6 @@ "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/promise-inflight": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-inflight/-/promise-inflight-1.0.1.tgz", - "integrity": "sha512-6zWPyEOFaQBJYcGMHBKTKJ3u6TBsnMFOIZSa6ce1e/ZrrsOlnHRHbabMjLiBYKp+n44X9eUI6VUPaukCXHuG4g==", - "license": "ISC" - }, "node_modules/promise-retry": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/promise-retry/-/promise-retry-2.0.1.tgz", @@ -7034,9 +7141,9 @@ } }, "node_modules/rollup": { - "version": "4.34.4", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.34.4.tgz", - "integrity": "sha512-spF66xoyD7rz3o08sHP7wogp1gZ6itSq22SGa/IZTcUDXDlOyrShwMwkVSB+BUxFRZZCUYqdb3KWDEOMVQZxuw==", + "version": "4.34.8", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.34.8.tgz", + "integrity": "sha512-489gTVMzAYdiZHFVA/ig/iYFllCcWFHMvUHI1rpFmkoUtRlQxqh6/yiNqnYibjMZ2b/+FUQwldG+aLsEt6bglQ==", "dev": true, "license": "MIT", "dependencies": { @@ -7050,25 +7157,25 @@ "npm": ">=8.0.0" }, "optionalDependencies": { - "@rollup/rollup-android-arm-eabi": "4.34.4", - "@rollup/rollup-android-arm64": "4.34.4", - "@rollup/rollup-darwin-arm64": "4.34.4", - "@rollup/rollup-darwin-x64": "4.34.4", - "@rollup/rollup-freebsd-arm64": "4.34.4", - "@rollup/rollup-freebsd-x64": "4.34.4", - "@rollup/rollup-linux-arm-gnueabihf": "4.34.4", - "@rollup/rollup-linux-arm-musleabihf": "4.34.4", - "@rollup/rollup-linux-arm64-gnu": "4.34.4", - "@rollup/rollup-linux-arm64-musl": "4.34.4", - "@rollup/rollup-linux-loongarch64-gnu": "4.34.4", - "@rollup/rollup-linux-powerpc64le-gnu": "4.34.4", - "@rollup/rollup-linux-riscv64-gnu": "4.34.4", - "@rollup/rollup-linux-s390x-gnu": "4.34.4", - "@rollup/rollup-linux-x64-gnu": "4.34.4", - "@rollup/rollup-linux-x64-musl": "4.34.4", - "@rollup/rollup-win32-arm64-msvc": "4.34.4", - "@rollup/rollup-win32-ia32-msvc": "4.34.4", - "@rollup/rollup-win32-x64-msvc": "4.34.4", + "@rollup/rollup-android-arm-eabi": "4.34.8", + "@rollup/rollup-android-arm64": "4.34.8", + "@rollup/rollup-darwin-arm64": "4.34.8", + "@rollup/rollup-darwin-x64": "4.34.8", + "@rollup/rollup-freebsd-arm64": "4.34.8", + "@rollup/rollup-freebsd-x64": "4.34.8", + "@rollup/rollup-linux-arm-gnueabihf": "4.34.8", + "@rollup/rollup-linux-arm-musleabihf": "4.34.8", + "@rollup/rollup-linux-arm64-gnu": "4.34.8", + "@rollup/rollup-linux-arm64-musl": "4.34.8", + "@rollup/rollup-linux-loongarch64-gnu": "4.34.8", + "@rollup/rollup-linux-powerpc64le-gnu": "4.34.8", + "@rollup/rollup-linux-riscv64-gnu": "4.34.8", + "@rollup/rollup-linux-s390x-gnu": "4.34.8", + "@rollup/rollup-linux-x64-gnu": "4.34.8", + "@rollup/rollup-linux-x64-musl": "4.34.8", + "@rollup/rollup-win32-arm64-msvc": "4.34.8", + "@rollup/rollup-win32-ia32-msvc": "4.34.8", + "@rollup/rollup-win32-x64-msvc": "4.34.8", "fsevents": "~2.3.2" } }, @@ -7418,9 +7525,9 @@ } }, "node_modules/sirv": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/sirv/-/sirv-3.0.0.tgz", - "integrity": "sha512-BPwJGUeDaDCHihkORDchNyyTvWFhcusy1XMmhEVTQTwGeybFbp8YEmB+njbPnth1FibULBSBVwCQni25XlCUDg==", + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/sirv/-/sirv-3.0.1.tgz", + "integrity": "sha512-FoqMu0NCGBLCcAkS1qA+XJIQTR6/JHfQXl+uGteNCQ76T91DMUjPa9xfmeqMY3z80nLSg9yQmNjK0Px6RWsH/A==", "dev": true, "license": "MIT", "dependencies": { @@ -7920,17 +8027,20 @@ "license": "MIT" }, "node_modules/tinyglobby": { - "version": "0.2.10", - "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.10.tgz", - "integrity": "sha512-Zc+8eJlFMvgatPZTl6A9L/yht8QqdmUNtURHaKZLmKBE12hNPSrqNkUp2cs3M/UKmNVVAMFQYSjYIVHDjW5zew==", + "version": "0.2.12", + "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.12.tgz", + "integrity": "sha512-qkf4trmKSIiMTs/E63cxH+ojC2unam7rJ0WrauAzpT3ECNTxGRMlaXxVbfxMUC/w0LaYk6jQ4y/nGR9uBO3tww==", "dev": true, "license": "MIT", "dependencies": { - "fdir": "^6.4.2", + "fdir": "^6.4.3", "picomatch": "^4.0.2" }, "engines": { "node": ">=12.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/SuperchupuDev" } }, "node_modules/tinyglobby/node_modules/fdir": { @@ -8239,14 +8349,14 @@ } }, "node_modules/vite": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/vite/-/vite-6.1.0.tgz", - "integrity": "sha512-RjjMipCKVoR4hVfPY6GQTgveinjNuyLw+qruksLDvA5ktI1150VmcMBKmQaEWJhg/j6Uaf6dNCNA0AfdzUb/hQ==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/vite/-/vite-6.1.1.tgz", + "integrity": "sha512-4GgM54XrwRfrOp297aIYspIti66k56v16ZnqHvrIM7mG+HjDlAwS7p+Srr7J6fGvEdOJ5JcQ/D9T7HhtdXDTzA==", "dev": true, "license": "MIT", "dependencies": { "esbuild": "^0.24.2", - "postcss": "^8.5.1", + "postcss": "^8.5.2", "rollup": "^4.30.1" }, "bin": { @@ -8311,16 +8421,16 @@ } }, "node_modules/vite-node": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/vite-node/-/vite-node-3.0.5.tgz", - "integrity": "sha512-02JEJl7SbtwSDJdYS537nU6l+ktdvcREfLksk/NDAqtdKWGqHl+joXzEubHROmS3E6pip+Xgu2tFezMu75jH7A==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/vite-node/-/vite-node-3.0.6.tgz", + "integrity": "sha512-s51RzrTkXKJrhNbUzQRsarjmAae7VmMPAsRT7lppVpIg6mK3zGthP9Hgz0YQQKuNcF+Ii7DfYk3Fxz40jRmePw==", "dev": true, "license": "MIT", "dependencies": { "cac": "^6.7.14", "debug": "^4.4.0", "es-module-lexer": "^1.6.0", - "pathe": "^2.0.2", + "pathe": "^2.0.3", "vite": "^5.0.0 || ^6.0.0" }, "bin": { @@ -8334,31 +8444,31 @@ } }, "node_modules/vitest": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/vitest/-/vitest-3.0.5.tgz", - "integrity": "sha512-4dof+HvqONw9bvsYxtkfUp2uHsTN9bV2CZIi1pWgoFpL1Lld8LA1ka9q/ONSsoScAKG7NVGf2stJTI7XRkXb2Q==", + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/vitest/-/vitest-3.0.6.tgz", + "integrity": "sha512-/iL1Sc5VeDZKPDe58oGK4HUFLhw6b5XdY1MYawjuSaDA4sEfYlY9HnS6aCEG26fX+MgUi7MwlduTBHHAI/OvMA==", "dev": true, "license": "MIT", "dependencies": { - "@vitest/expect": "3.0.5", - "@vitest/mocker": "3.0.5", - "@vitest/pretty-format": "^3.0.5", - "@vitest/runner": "3.0.5", - "@vitest/snapshot": "3.0.5", - "@vitest/spy": "3.0.5", - "@vitest/utils": "3.0.5", - "chai": "^5.1.2", + "@vitest/expect": "3.0.6", + "@vitest/mocker": "3.0.6", + "@vitest/pretty-format": "^3.0.6", + "@vitest/runner": "3.0.6", + "@vitest/snapshot": "3.0.6", + "@vitest/spy": "3.0.6", + "@vitest/utils": "3.0.6", + "chai": "^5.2.0", "debug": "^4.4.0", "expect-type": "^1.1.0", "magic-string": "^0.30.17", - "pathe": "^2.0.2", + "pathe": "^2.0.3", "std-env": "^3.8.0", "tinybench": "^2.9.0", "tinyexec": "^0.3.2", "tinypool": "^1.0.2", "tinyrainbow": "^2.0.0", "vite": "^5.0.0 || ^6.0.0", - "vite-node": "3.0.5", + "vite-node": "3.0.6", "why-is-node-running": "^2.3.0" }, "bin": { @@ -8374,8 +8484,8 @@ "@edge-runtime/vm": "*", "@types/debug": "^4.1.12", "@types/node": "^18.0.0 || ^20.0.0 || >=22.0.0", - "@vitest/browser": "3.0.5", - "@vitest/ui": "3.0.5", + "@vitest/browser": "3.0.6", + "@vitest/ui": "3.0.6", "happy-dom": "*", "jsdom": "*" }, @@ -8442,13 +8552,10 @@ "integrity": "sha512-Ld1VelNuX9pdF39h2Hgaeb5hEZM2Z3jUrrMgWQAu82jMtZp7p3vJT3BzToKtZI7NgQssZje5o0zryOrhQvzQAg==" }, "node_modules/walk-up-path": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/walk-up-path/-/walk-up-path-4.0.0.tgz", - "integrity": "sha512-3hu+tD8YzSLGuFYtPRb48vdhKMi0KQV5sn+uWr8+7dMEq/2G/dtLrdDinkLjqq5TIbIBjYJ4Ax/n3YiaW7QM8A==", - "license": "ISC", - "engines": { - "node": "20 || >=22" - } + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/walk-up-path/-/walk-up-path-3.0.1.tgz", + "integrity": "sha512-9YlCL/ynK3CTlrSRrDxZvUauLzAswPCrsaCgilqFevUYpeEW0/3ScEjaa3kbW/T0ghhkEr7mv+fpjqn1Y1YuTA==", + "license": "ISC" }, "node_modules/web-streams-polyfill": { "version": "3.3.3", diff --git a/packages/http-client-java/package.json b/packages/http-client-java/package.json index cc84d1fc769..3f0f4d3eb3b 100644 --- a/packages/http-client-java/package.json +++ b/packages/http-client-java/package.json @@ -49,7 +49,7 @@ "peerDependencies": { "@azure-tools/typespec-autorest": ">=0.50.0 <1.0.0", "@azure-tools/typespec-azure-core": ">=0.50.0 <1.0.0", - "@azure-tools/typespec-client-generator-core": ">=0.50.3 <1.0.0", + "@azure-tools/typespec-client-generator-core": ">=0.51.3 <1.0.0", "@typespec/compiler": ">=0.64.0 <1.0.0", "@typespec/http": ">=0.64.0 <1.0.0", "@typespec/openapi": ">=0.64.0 <1.0.0", @@ -68,23 +68,23 @@ "@azure-tools/typespec-azure-core": "0.51.0", "@azure-tools/typespec-azure-resource-manager": "0.51.0", "@azure-tools/typespec-azure-rulesets": "0.51.0", - "@azure-tools/typespec-client-generator-core": "0.51.0", + "@azure-tools/typespec-client-generator-core": "0.51.3", "@typespec/spector": "0.1.0-alpha.7", - "@microsoft/api-extractor": "^7.50.0", + "@microsoft/api-extractor": "^7.50.1", "@microsoft/api-extractor-model": "^7.30.3", "@types/js-yaml": "~4.0.9", "@types/lodash": "~4.17.15", - "@types/node": "~22.13.1", - "@typespec/compiler": "0.65.0", + "@types/node": "~22.13.5", + "@typespec/compiler": "0.65.3", "@typespec/http": "0.65.0", "@typespec/openapi": "0.65.0", "@typespec/rest": "0.65.0", "@typespec/versioning": "0.65.0", - "@vitest/coverage-v8": "^3.0.5", - "@vitest/ui": "^3.0.5", + "@vitest/coverage-v8": "^3.0.6", + "@vitest/ui": "^3.0.6", "c8": "~10.1.3", "rimraf": "~6.0.1", "typescript": "~5.7.3", - "vitest": "^3.0.5" + "vitest": "^3.0.6" } } From 917c8e9f9043d4af9cf8101383d8581d8e5e3022 Mon Sep 17 00:00:00 2001 From: Weidong Xu Date: Tue, 25 Feb 2025 11:57:23 +0800 Subject: [PATCH 02/11] http-client-java, support returnValueWireType in clientcore (#6105) partly solve https://github.com/microsoft/typespec/issues/6075 currently seems only `Base64Uri` is handled in clientcore --- .../encode/bytes/implementation/ResponseBodiesImpl.java | 4 +++- .../type/array/implementation/DatetimeValuesImpl.java | 6 +++++- .../dictionary/implementation/DatetimeValuesImpl.java | 3 ++- .../implementation/NullableFloatValuesImpl.java | 3 ++- .../src/test/java/encode/bytes/EncodeBytesTests.java | 5 ++--- .../client/generator/core/template/ProxyTemplate.java | 8 +++++++- 6 files changed, 21 insertions(+), 8 deletions(-) diff --git a/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/encode/bytes/implementation/ResponseBodiesImpl.java b/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/encode/bytes/implementation/ResponseBodiesImpl.java index c686f8c3788..878b208cd9d 100644 --- a/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/encode/bytes/implementation/ResponseBodiesImpl.java +++ b/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/encode/bytes/implementation/ResponseBodiesImpl.java @@ -13,6 +13,7 @@ import io.clientcore.core.http.models.RequestOptions; import io.clientcore.core.http.models.Response; import io.clientcore.core.models.binarydata.BinaryData; +import io.clientcore.core.utils.Base64Uri; /** * An instance of this class provides access to all the operations defined in ResponseBodies. @@ -79,7 +80,8 @@ Response base64Sync(@HostParam("endpoint") String endpoint, @HeaderParam @HttpRequestInformation( method = HttpMethod.GET, path = "/encode/bytes/body/response/base64url", - expectedStatusCodes = { 200 }) + expectedStatusCodes = { 200 }, + returnValueWireType = Base64Uri.class) @UnexpectedResponseExceptionDetail Response base64urlSync(@HostParam("endpoint") String endpoint, @HeaderParam("Accept") String accept, RequestOptions requestOptions); diff --git a/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/array/implementation/DatetimeValuesImpl.java b/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/array/implementation/DatetimeValuesImpl.java index b4bedcfd376..5137bb82791 100644 --- a/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/array/implementation/DatetimeValuesImpl.java +++ b/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/array/implementation/DatetimeValuesImpl.java @@ -47,7 +47,11 @@ public final class DatetimeValuesImpl { */ @ServiceInterface(name = "ArrayClientDatetimeV", host = "{endpoint}") public interface DatetimeValuesService { - @HttpRequestInformation(method = HttpMethod.GET, path = "/type/array/datetime", expectedStatusCodes = { 200 }) + @HttpRequestInformation( + method = HttpMethod.GET, + path = "/type/array/datetime", + expectedStatusCodes = { 200 }, + returnValueWireType = OffsetDateTime.class) @UnexpectedResponseExceptionDetail Response> getSync(@HostParam("endpoint") String endpoint, @HeaderParam("Accept") String accept, RequestOptions requestOptions); diff --git a/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/dictionary/implementation/DatetimeValuesImpl.java b/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/dictionary/implementation/DatetimeValuesImpl.java index 7639ca7e688..b032dd5790a 100644 --- a/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/dictionary/implementation/DatetimeValuesImpl.java +++ b/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/dictionary/implementation/DatetimeValuesImpl.java @@ -50,7 +50,8 @@ public interface DatetimeValuesService { @HttpRequestInformation( method = HttpMethod.GET, path = "/type/dictionary/datetime", - expectedStatusCodes = { 200 }) + expectedStatusCodes = { 200 }, + returnValueWireType = OffsetDateTime.class) @UnexpectedResponseExceptionDetail Response> getSync(@HostParam("endpoint") String endpoint, @HeaderParam("Accept") String accept, RequestOptions requestOptions); diff --git a/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/dictionary/implementation/NullableFloatValuesImpl.java b/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/dictionary/implementation/NullableFloatValuesImpl.java index 368f50eef47..0e4148c94b0 100644 --- a/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/dictionary/implementation/NullableFloatValuesImpl.java +++ b/packages/http-client-java/generator/http-client-generator-clientcore-test/src/main/java/type/dictionary/implementation/NullableFloatValuesImpl.java @@ -49,7 +49,8 @@ public interface NullableFloatValuesService { @HttpRequestInformation( method = HttpMethod.GET, path = "/type/dictionary/nullable-float", - expectedStatusCodes = { 200 }) + expectedStatusCodes = { 200 }, + returnValueWireType = Double.class) @UnexpectedResponseExceptionDetail Response> getSync(@HostParam("endpoint") String endpoint, @HeaderParam("Accept") String accept, RequestOptions requestOptions); diff --git a/packages/http-client-java/generator/http-client-generator-clientcore-test/src/test/java/encode/bytes/EncodeBytesTests.java b/packages/http-client-java/generator/http-client-generator-clientcore-test/src/test/java/encode/bytes/EncodeBytesTests.java index d7962bf337d..b5fb711d8f9 100644 --- a/packages/http-client-java/generator/http-client-generator-clientcore-test/src/test/java/encode/bytes/EncodeBytesTests.java +++ b/packages/http-client-java/generator/http-client-generator-clientcore-test/src/test/java/encode/bytes/EncodeBytesTests.java @@ -82,8 +82,7 @@ public void testResponseBody() { // bytes = responseClient.base64(); // Assertions.assertArrayEquals(DATA, bytes); - // array lengths differ -// bytes = responseClient.base64url(); -// Assertions.assertArrayEquals(DATA, bytes); + bytes = responseClient.base64url(); + Assertions.assertArrayEquals(DATA, bytes); } } diff --git a/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/template/ProxyTemplate.java b/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/template/ProxyTemplate.java index 112d3563ef9..90334b4159a 100644 --- a/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/template/ProxyTemplate.java +++ b/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/template/ProxyTemplate.java @@ -79,6 +79,12 @@ public final void write(Proxy restAPI, JavaClass classBlock) { .collect(Collectors.joining(", ")))); } } else { + String returnValueWireTypeCode = ""; + if (restAPIMethod.getReturnValueWireType() != null) { + returnValueWireTypeCode + = ", returnValueWireType = " + restAPIMethod.getReturnValueWireType() + ".class"; + } + interfaceBlock.annotation( "HttpRequestInformation(method = HttpMethod." + restAPIMethod.getHttpMethod().toString() + ", path = \"" + restAPIMethod.getUrlPath() + "\", expectedStatusCodes = { " @@ -86,7 +92,7 @@ public final void write(Proxy restAPI, JavaClass classBlock) { .stream() .map(String::valueOf) .collect(Collectors.joining(", ")) - + " })"); + + " } " + returnValueWireTypeCode + ")"); } if (!settings.isDataPlaneClient()) { From 4757a4f99ef1d90d14d18eb55133b4404c38b9f5 Mon Sep 17 00:00:00 2001 From: Zhonglei Ma Date: Tue, 25 Feb 2025 13:25:18 +0800 Subject: [PATCH 03/11] [typespec-vscode] Add autocomplete of model properties for union type (#5483) Fix : https://github.com/microsoft/typespec/issues/4024 add code and tests --- ...perties-for-union-type-2025-1-24-7-8-39.md | 8 + packages/compiler/src/core/checker.ts | 159 +++++++++++------- packages/compiler/src/server/serverlib.ts | 45 ++--- .../compiler/test/server/completion.test.ts | 112 ++++++++++++ 4 files changed, 246 insertions(+), 78 deletions(-) create mode 100644 .chronus/changes/add-autocomplete-of-model-properties-for-union-type-2025-1-24-7-8-39.md diff --git a/.chronus/changes/add-autocomplete-of-model-properties-for-union-type-2025-1-24-7-8-39.md b/.chronus/changes/add-autocomplete-of-model-properties-for-union-type-2025-1-24-7-8-39.md new file mode 100644 index 00000000000..a6a91ec7069 --- /dev/null +++ b/.chronus/changes/add-autocomplete-of-model-properties-for-union-type-2025-1-24-7-8-39.md @@ -0,0 +1,8 @@ +--- +# Change versionKind to one of: internal, fix, dependencies, feature, deprecation, breaking +changeKind: feature +packages: + - "@typespec/compiler" +--- + +Add autocomplete of model properties for union type diff --git a/packages/compiler/src/core/checker.ts b/packages/compiler/src/core/checker.ts index 52034752b9d..1c82a9c3759 100644 --- a/packages/compiler/src/core/checker.ts +++ b/packages/compiler/src/core/checker.ts @@ -225,7 +225,7 @@ export interface Checker { projection: ProjectionNode, args?: (Type | string | number | boolean)[], ): Type; - resolveIdentifier(node: IdentifierNode): Sym | undefined; + resolveRelatedSymbols(node: IdentifierNode): Sym[] | undefined; resolveCompletions(node: IdentifierNode): Map; createType( typeDef: T, @@ -412,7 +412,7 @@ export function createChecker(program: Program, resolver: NameResolver): Checker getGlobalNamespaceNode, getMergedSymbol, cloneType, - resolveIdentifier, + resolveRelatedSymbols, resolveCompletions, evalProjection, project, @@ -2545,7 +2545,7 @@ export function createChecker(program: Program, resolver: NameResolver): Checker return resolver.getSymbolLinks(s); } - function resolveIdentifier(id: IdentifierNode, mapper?: TypeMapper): Sym | undefined { + function resolveRelatedSymbols(id: IdentifierNode, mapper?: TypeMapper): Sym[] | undefined { let sym: Sym | undefined; const { node, kind } = getIdentifierContext(id); @@ -2553,16 +2553,13 @@ export function createChecker(program: Program, resolver: NameResolver): Checker case IdentifierKind.ModelExpressionProperty: case IdentifierKind.ObjectLiteralProperty: const model = getReferencedModel(node as ModelPropertyNode | ObjectLiteralPropertyNode); - if (model) { - sym = getMemberSymbol(model.node!.symbol, id.sv); - } else { - return undefined; - } - break; + return model + .map((m) => getMemberSymbol(m.node!.symbol, id.sv)) + .filter((m): m is Sym => m !== undefined); case IdentifierKind.ModelStatementProperty: case IdentifierKind.Declaration: const links = resolver.getNodeLinks(id); - return links.resolvedSymbol; + return links.resolvedSymbol === undefined ? undefined : [links.resolvedSymbol]; case IdentifierKind.Other: return undefined; @@ -2601,7 +2598,14 @@ export function createChecker(program: Program, resolver: NameResolver): Checker compilerAssert(false, "Unreachable"); } - return sym?.symbolSource ?? sym; + if (sym) { + if (sym.symbolSource) { + return [sym.symbolSource]; + } else { + return [sym]; + } + } + return undefined; //sym?.symbolSource ?? sym; } function getTemplateDeclarationsForArgument( @@ -2621,7 +2625,7 @@ export function createChecker(program: Program, resolver: NameResolver): Checker function getReferencedModel( propertyNode: ObjectLiteralPropertyNode | ModelPropertyNode, - ): Model | undefined { + ): Model[] { type ModelOrArrayValueNode = ArrayLiteralNode | ObjectLiteralNode; type ModelOrArrayTypeNode = ModelExpressionNode | TupleExpressionNode; type ModelOrArrayNode = ModelOrArrayValueNode | ModelOrArrayTypeNode; @@ -2664,9 +2668,8 @@ export function createChecker(program: Program, resolver: NameResolver): Checker refType = getReferencedTypeFromConstAssignment(foundNode as ModelOrArrayValueNode); break; } - return refType?.kind === "Model" || refType?.kind === "Tuple" - ? getNestedModel(refType, path) - : undefined; + + return getNestedModel(refType, path); function pushToModelPath(node: Node, preNode: Node | undefined, path: PathSeg[]) { if (node.kind === SyntaxKind.ArrayLiteral || node.kind === SyntaxKind.TupleExpression) { @@ -2685,38 +2688,75 @@ export function createChecker(program: Program, resolver: NameResolver): Checker } } - function getNestedModel( - modelOrTuple: Model | Tuple | undefined, - path: PathSeg[], - ): Model | undefined { - let cur: Type | undefined = modelOrTuple; - for (const seg of path) { + function getNestedModel(modelOrTupleOrUnion: Type | undefined, path: PathSeg[]): Model[] { + let cur = modelOrTupleOrUnion; + + if (cur && cur.kind !== "Model" && cur.kind !== "Tuple" && cur.kind !== "Union") { + return []; + } + + if (path.length === 0) { + // Handle union and model type nesting when path is empty switch (cur?.kind) { - case "Tuple": - if ( - seg.tupleIndex !== undefined && - seg.tupleIndex >= 0 && - seg.tupleIndex < cur.values.length - ) { - cur = cur.values[seg.tupleIndex]; - } else { - return undefined; - } - break; case "Model": - if (cur.name === "Array" && seg.tupleIndex !== undefined) { - cur = cur.templateMapper?.args[0] as Model; - } else if (cur.name !== "Array" && seg.propertyName) { - cur = cur.properties.get(seg.propertyName)?.type; - } else { - return undefined; + return [cur]; + case "Union": + const models: Model[] = []; + for (const variant of cur.variants.values()) { + if ( + variant.type.kind === "Model" || + variant.type.kind === "Tuple" || + variant.type.kind === "Union" + ) { + models.push(...(getNestedModel(variant.type, path) ?? [])); + } } - break; + return models; default: - return undefined; + return []; } } - return cur?.kind === "Model" ? cur : undefined; + + const seg = path[0]; + switch (cur?.kind) { + case "Tuple": + if ( + seg.tupleIndex !== undefined && + seg.tupleIndex >= 0 && + seg.tupleIndex < cur.values.length + ) { + return getNestedModel(cur.values[seg.tupleIndex], path.slice(1)); + } else { + return []; + } + + case "Model": + if (cur.name === "Array" && seg.tupleIndex !== undefined) { + cur = cur.templateMapper?.args[0] as Model; + } else if (cur.name !== "Array" && seg.propertyName) { + cur = cur.properties.get(seg.propertyName)?.type; + } else { + return []; + } + return getNestedModel(cur, path.slice(1)); + + case "Union": + // When seg.property name exists, it means that it is in the union model or tuple, + // and the corresponding model or tuple needs to be found recursively. + const models: Model[] = []; + for (const variant of cur.variants.values()) { + if ( + variant.type.kind === "Model" || + variant.type.kind === "Tuple" || + variant.type.kind === "Union" + ) { + models.push(...(getNestedModel(variant.type, path) ?? [])); + } + } + return models; + default: + return []; + } } function getReferencedTypeFromTemplateDeclaration(node: ModelOrArrayNode): Type | undefined { @@ -2813,14 +2853,14 @@ export function createChecker(program: Program, resolver: NameResolver): Checker return undefined; } - const decSym = program.checker.resolveIdentifier( + const decSym = program.checker.resolveRelatedSymbols( decNode.target.kind === SyntaxKind.MemberExpression ? decNode.target.id : decNode.target, ); - if (!decSym) { + if (!decSym || decSym.length <= 0) { return undefined; } - const decDecl: DecoratorDeclarationStatementNode | undefined = decSym.declarations.find( + const decDecl: DecoratorDeclarationStatementNode | undefined = decSym[0].declarations.find( (x): x is DecoratorDeclarationStatementNode => x.kind === SyntaxKind.DecoratorDeclarationStatement, ); @@ -2909,24 +2949,25 @@ export function createChecker(program: Program, resolver: NameResolver): Checker kind === IdentifierKind.ObjectLiteralProperty ) { const model = getReferencedModel(ancestor as ModelPropertyNode | ObjectLiteralPropertyNode); - if (!model) { + if (model.length <= 0) { return completions; } const curModelNode = ancestor.parent as ModelExpressionNode | ObjectLiteralNode; - - for (const prop of walkPropertiesInherited(model)) { - if ( - identifier.sv === prop.name || - !curModelNode.properties.find( - (p) => - (p.kind === SyntaxKind.ModelProperty || - p.kind === SyntaxKind.ObjectLiteralProperty) && - p.id.sv === prop.name, - ) - ) { - const sym = getMemberSymbol(model.node!.symbol, prop.name); - if (sym) { - addCompletion(prop.name, sym); + for (const curModel of model) { + for (const prop of walkPropertiesInherited(curModel)) { + if ( + identifier.sv === prop.name || + !curModelNode.properties.find( + (p) => + (p.kind === SyntaxKind.ModelProperty || + p.kind === SyntaxKind.ObjectLiteralProperty) && + p.id.sv === prop.name, + ) + ) { + const sym = getMemberSymbol(curModel.node!.symbol, prop.name); + if (sym) { + addCompletion(prop.name, sym); + } } } } diff --git a/packages/compiler/src/server/serverlib.ts b/packages/compiler/src/server/serverlib.ts index 6be56904da0..7f5ac92eebc 100644 --- a/packages/compiler/src/server/serverlib.ts +++ b/packages/compiler/src/server/serverlib.ts @@ -540,11 +540,11 @@ export function createServer(host: ServerHost): Server { const id = getNodeAtPosition(script, document.offsetAt(params.position)); const sym = - id?.kind === SyntaxKind.Identifier ? program.checker.resolveIdentifier(id) : undefined; + id?.kind === SyntaxKind.Identifier ? program.checker.resolveRelatedSymbols(id) : undefined; const markdown: MarkupContent = { kind: MarkupKind.Markdown, - value: sym ? getSymbolDetails(program, sym) : "", + value: sym && sym.length > 0 ? getSymbolDetails(program, sym[0]) : "", }; return { contents: markdown, @@ -581,10 +581,13 @@ export function createServer(host: ServerHost): Server { node: TypeReferenceNode, argumentIndex: number, ): SignatureHelp | undefined { - const sym = program.checker.resolveIdentifier( + const sym = program.checker.resolveRelatedSymbols( node.target.kind === SyntaxKind.MemberExpression ? node.target.id : node.target, ); - const templateDeclNode = sym?.declarations[0]; + if (!sym || sym.length <= 0) { + return undefined; + } + const templateDeclNode = sym[0].declarations[0]; if ( !templateDeclNode || !("templateParameters" in templateDeclNode) || @@ -606,7 +609,7 @@ export function createServer(host: ServerHost): Server { const help: SignatureHelp = { signatures: [ { - label: `${sym.name}<${parameters.map((x) => x.label).join(", ")}>`, + label: `${sym[0].name}<${parameters.map((x) => x.label).join(", ")}>`, parameters, activeParameter: Math.min(parameters.length - 1, argumentIndex), }, @@ -615,7 +618,7 @@ export function createServer(host: ServerHost): Server { activeParameter: 0, }; - const doc = getSymbolDetails(program, sym, { + const doc = getSymbolDetails(program, sym[0], { includeSignature: false, includeParameterTags: false, }); @@ -631,17 +634,18 @@ export function createServer(host: ServerHost): Server { node: DecoratorExpressionNode | AugmentDecoratorStatementNode, argumentIndex: number, ): SignatureHelp | undefined { - const sym = program.checker.resolveIdentifier( + const sym = program.checker.resolveRelatedSymbols( node.target.kind === SyntaxKind.MemberExpression ? node.target.id : node.target, ); - if (!sym) { + if (!sym || sym.length <= 0) { return undefined; } - const decoratorDeclNode: DecoratorDeclarationStatementNode | undefined = sym.declarations.find( - (x): x is DecoratorDeclarationStatementNode => - x.kind === SyntaxKind.DecoratorDeclarationStatement, - ); + const decoratorDeclNode: DecoratorDeclarationStatementNode | undefined = + sym[0].declarations.find( + (x): x is DecoratorDeclarationStatementNode => + x.kind === SyntaxKind.DecoratorDeclarationStatement, + ); if (decoratorDeclNode === undefined) { return undefined; } @@ -692,7 +696,7 @@ export function createServer(host: ServerHost): Server { activeParameter: 0, }; - const doc = getSymbolDetails(program, sym, { + const doc = getSymbolDetails(program, sym[0], { includeSignature: false, includeParameterTags: false, }); @@ -767,8 +771,8 @@ export function createServer(host: ServerHost): Server { const node = getNodeAtPosition(result.script, result.document.offsetAt(params.position)); switch (node?.kind) { case SyntaxKind.Identifier: - const sym = result.program.checker.resolveIdentifier(node); - return getLocations(sym?.declarations); + const sym = result.program.checker.resolveRelatedSymbols(node); + return getLocations(sym && sym.length > 0 ? sym[0].declarations : undefined); case SyntaxKind.StringLiteral: if (node.parent?.kind === SyntaxKind.ImportStatement) { return [await getImportLocation(node.value, result.script)]; @@ -908,8 +912,8 @@ export function createServer(host: ServerHost): Server { return []; } - const sym = program.checker.resolveIdentifier(id); - if (!sym) { + const sym = program.checker.resolveRelatedSymbols(id); + if (!sym || sym.length <= 0) { return [id]; } @@ -917,8 +921,11 @@ export function createServer(host: ServerHost): Server { for (const searchFile of searchFiles) { visitChildren(searchFile, function visit(node) { if (node.kind === SyntaxKind.Identifier) { - const s = program.checker.resolveIdentifier(node); - if (s === sym || (sym.type && s?.type === sym.type)) { + const s = program.checker.resolveRelatedSymbols(node); + if (!s || s.length <= 0) { + return; + } + if (s[0] === sym[0] || (sym[0].type && s[0].type === sym[0].type)) { references.push(node); } } diff --git a/packages/compiler/test/server/completion.test.ts b/packages/compiler/test/server/completion.test.ts index 0efecc6bb5d..008de033b39 100644 --- a/packages/compiler/test/server/completion.test.ts +++ b/packages/compiler/test/server/completion.test.ts @@ -755,6 +755,118 @@ describe("identifiers", () => { ); }); + it("completes union variants(models) of template parameters", async () => { + const completions = await complete( + ` + model Options { + a: string; + b: Nested; + } + model Nested { + c:Foo2; + } + model Foo1 { + foo1: string; + } + model Foo2 { + foo2: string; + } + + model Test {} + + alias A = Test<#{┆}>; + `, + ); + + check( + completions, + [ + { + label: "foo1", + insertText: "foo1", + kind: CompletionItemKind.Field, + documentation: { + kind: MarkupKind.Markdown, + value: "(model property)\n```typespec\nFoo1.foo1: string\n```", + }, + }, + { + label: "a", + insertText: "a", + kind: CompletionItemKind.Field, + documentation: { + kind: MarkupKind.Markdown, + value: "(model property)\n```typespec\nOptions.a: string\n```", + }, + }, + { + label: "b", + insertText: "b", + kind: CompletionItemKind.Field, + documentation: { + kind: MarkupKind.Markdown, + value: "(model property)\n```typespec\nOptions.b: Nested\n```", + }, + }, + ], + { + allowAdditionalCompletions: false, + }, + ); + }); + + it("completes specific type in union variants(models) of template parameters", async () => { + const completions = await complete( + ` + model Options { + a: string; + b: Nested; + } + model Nested { + c:Foo2; + d:string; + } + model Foo1 { + foo1: string; + } + model Foo2 { + foo2: string; + } + + model Test {} + + alias A = Test<#{a:"",b:#{┆}}>; + `, + ); + + check( + completions, + [ + { + label: "c", + insertText: "c", + kind: CompletionItemKind.Field, + documentation: { + kind: MarkupKind.Markdown, + value: "(model property)\n```typespec\nNested.c: Foo2\n```", + }, + }, + { + label: "d", + insertText: "d", + kind: CompletionItemKind.Field, + documentation: { + kind: MarkupKind.Markdown, + value: "(model property)\n```typespec\nNested.d: string\n```", + }, + }, + ], + { + allowAdditionalCompletions: false, + }, + ); + }); + it("completes namespace operations", async () => { const completions = await complete( ` From e3e2699713c8d69c5df5cdaed5af52f2f98468bd Mon Sep 17 00:00:00 2001 From: Weidong Xu Date: Tue, 25 Feb 2025 16:58:56 +0800 Subject: [PATCH 04/11] http-client-java, pass oauth2 flows to code-model (#6139) Currently we just use the same schema as from TypeSpec (TCGC also uses same schema). No codegen code consumes the data (and no diff on generated code), at present. ![Screenshot 2025-02-25 112842](https://github.com/user-attachments/assets/705013ea-3cb7-4dc8-abae-ecfe9a791e71) --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- .../emitter/src/code-model-builder.ts | 1 + .../extension/model/codemodel/OAuth2Flow.java | 130 ++++++++++++++++++ .../extension/model/codemodel/Scheme.java | 18 +++ .../core/mapper/ServiceClientMapper.java | 11 +- .../core/model/clientmodel/SecurityInfo.java | 37 +++++ 5 files changed, 196 insertions(+), 1 deletion(-) create mode 100644 packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/extension/model/codemodel/OAuth2Flow.java diff --git a/packages/http-client-java/emitter/src/code-model-builder.ts b/packages/http-client-java/emitter/src/code-model-builder.ts index 6b540e89d53..4cf56e9381c 100644 --- a/packages/http-client-java/emitter/src/code-model-builder.ts +++ b/packages/http-client-java/emitter/src/code-model-builder.ts @@ -324,6 +324,7 @@ export class CodeModelBuilder { scheme.flows.forEach((it) => oauth2Scheme.scopes.push(...it.scopes.map((it) => it.value)), ); + (oauth2Scheme as any).flows = scheme.flows; securitySchemes.push(oauth2Scheme); } else { // there is no TokenCredential in clientcore, hence use Bearer Authentication directly diff --git a/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/extension/model/codemodel/OAuth2Flow.java b/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/extension/model/codemodel/OAuth2Flow.java new file mode 100644 index 00000000000..91c94d55256 --- /dev/null +++ b/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/extension/model/codemodel/OAuth2Flow.java @@ -0,0 +1,130 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +package com.microsoft.typespec.http.client.generator.core.extension.model.codemodel; + +import com.azure.json.JsonReader; +import com.azure.json.JsonSerializable; +import com.azure.json.JsonWriter; +import com.microsoft.typespec.http.client.generator.core.extension.base.util.JsonUtils; +import java.io.IOException; +import java.util.List; + +public final class OAuth2Flow implements JsonSerializable { + + public static final class OAuth2Scope implements JsonSerializable { + private String value; + private String description; + + public String getValue() { + return value; + } + + public void setValue(String value) { + this.value = value; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + @Override + public JsonWriter toJson(JsonWriter jsonWriter) throws IOException { + return jsonWriter.writeStartObject() + .writeStringField("value", value) + .writeStringField("description", description) + .writeEndObject(); + } + + public static OAuth2Scope fromJson(JsonReader jsonReader) throws IOException { + return JsonUtils.readObject(jsonReader, OAuth2Scope::new, (scheme, fieldName, reader) -> { + if ("value".equals(fieldName)) { + scheme.value = reader.getString(); + } else if ("description".equals(fieldName)) { + scheme.description = reader.getString(); + } else { + reader.skipChildren(); + } + }); + } + } + + private String type; + private String authorizationUrl; + private String tokenUrl; + private String refreshUrl; + private List scopes; + + public String getType() { + return type; + } + + public void setType(String type) { + this.type = type; + } + + public String getAuthorizationUrl() { + return authorizationUrl; + } + + public void setAuthorizationUrl(String authorizationUrl) { + this.authorizationUrl = authorizationUrl; + } + + public String getTokenUrl() { + return tokenUrl; + } + + public void setTokenUrl(String tokenUrl) { + this.tokenUrl = tokenUrl; + } + + public String getRefreshUrl() { + return refreshUrl; + } + + public void setRefreshUrl(String refreshUrl) { + this.refreshUrl = refreshUrl; + } + + public List getScopes() { + return scopes; + } + + public void setScopes(List scopes) { + this.scopes = scopes; + } + + @Override + public JsonWriter toJson(JsonWriter jsonWriter) throws IOException { + return jsonWriter.writeStartObject() + .writeStringField("type", type) + .writeStringField("authorizationUrl", authorizationUrl) + .writeStringField("tokenUrl", tokenUrl) + .writeStringField("refreshUrl", refreshUrl) + .writeArrayField("scopes", scopes, JsonWriter::writeJson) + .writeEndObject(); + } + + public static OAuth2Flow fromJson(JsonReader jsonReader) throws IOException { + return JsonUtils.readObject(jsonReader, OAuth2Flow::new, (scheme, fieldName, reader) -> { + if ("type".equals(fieldName)) { + scheme.type = reader.getString(); + } else if ("authorizationUrl".equals(fieldName)) { + scheme.authorizationUrl = reader.getString(); + } else if ("tokenUrl".equals(fieldName)) { + scheme.tokenUrl = reader.getString(); + } else if ("refreshUrl".equals(fieldName)) { + scheme.refreshUrl = reader.getString(); + } else if ("scopes".equals(fieldName)) { + scheme.scopes = reader.readArray(OAuth2Scope::fromJson); + } else { + reader.skipChildren(); + } + }); + } +} diff --git a/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/extension/model/codemodel/Scheme.java b/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/extension/model/codemodel/Scheme.java index d2b68573a86..af833febb51 100644 --- a/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/extension/model/codemodel/Scheme.java +++ b/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/extension/model/codemodel/Scheme.java @@ -8,6 +8,7 @@ import com.azure.json.JsonWriter; import com.microsoft.typespec.http.client.generator.core.extension.base.util.JsonUtils; import java.io.IOException; +import java.util.ArrayList; import java.util.HashSet; import java.util.List; import java.util.Set; @@ -19,6 +20,7 @@ public class Scheme implements JsonSerializable { private Scheme.SecuritySchemeType type; // OAuth2 private Set scopes = new HashSet<>(); + private List flows = new ArrayList<>(); // Key private String name; private String in; @@ -66,6 +68,19 @@ public void setScopes(Set scopes) { this.scopes = scopes; } + /** + * Gets the flows of the OAuth2 security scheme. + * + * @return The flows of the security scheme. + */ + public List getFlows() { + return flows; + } + + public void setFlows(List flows) { + this.flows = flows; + } + /** * Gets the name of the security scheme. * @@ -128,6 +143,7 @@ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException { .writeStringField("name", name) .writeStringField("in", in) .writeStringField("prefix", prefix) + .writeArrayField("flows", flows, JsonWriter::writeJson) .writeEndObject(); } @@ -151,6 +167,8 @@ public static Scheme fromJson(JsonReader jsonReader) throws IOException { scheme.in = reader.getString(); } else if ("prefix".equals(fieldName)) { scheme.prefix = reader.getString(); + } else if ("flows".equals(fieldName)) { + scheme.flows = reader.readArray(OAuth2Flow::fromJson); } else { reader.skipChildren(); } diff --git a/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/mapper/ServiceClientMapper.java b/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/mapper/ServiceClientMapper.java index 88886f6fb97..57aee6c11ff 100644 --- a/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/mapper/ServiceClientMapper.java +++ b/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/mapper/ServiceClientMapper.java @@ -354,7 +354,16 @@ protected void processParametersAndConstructors(ServiceClient.Builder builder, C SecurityInfo securityInfoInCodeModel = new SecurityInfo(); codeModel.getSecurity().getSchemes().forEach(securityScheme -> { - // hack, ignore "user_impersonation", as these non-AADToken appears in modelerfour 4.23.0+ + // flows for OAUTH2 + if (securityScheme.getType().equals(Scheme.SecuritySchemeType.OAUTH2) + && !CoreUtils.isNullOrEmpty(securityScheme.getFlows())) { + if (securityInfoInCodeModel.getFlows() == null) { + securityInfoInCodeModel.setFlows(new ArrayList<>()); + } + securityInfoInCodeModel.getFlows().addAll(securityScheme.getFlows()); + } + + // hack, ignore "user_impersonation" in OAUTH2, as these non-AADToken appears in modelerfour 4.23.0+ if (securityScheme.getType() == Scheme.SecuritySchemeType.OAUTH2 && securityScheme.getScopes().size() == 1 && userImpersonationScope.equals(securityScheme.getScopes().iterator().next())) { diff --git a/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/model/clientmodel/SecurityInfo.java b/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/model/clientmodel/SecurityInfo.java index 0717a6d5060..fdf000f8a39 100644 --- a/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/model/clientmodel/SecurityInfo.java +++ b/packages/http-client-java/generator/http-client-generator-core/src/main/java/com/microsoft/typespec/http/client/generator/core/model/clientmodel/SecurityInfo.java @@ -3,8 +3,11 @@ package com.microsoft.typespec.http.client.generator.core.model.clientmodel; +import com.microsoft.typespec.http.client.generator.core.extension.model.codemodel.OAuth2Flow; import com.microsoft.typespec.http.client.generator.core.extension.model.codemodel.Scheme; +import java.util.ArrayList; import java.util.HashSet; +import java.util.List; import java.util.Set; public class SecurityInfo { @@ -12,11 +15,17 @@ public class SecurityInfo { private Set securityTypes = new HashSet<>(); private Set scopes = new HashSet<>(); + private List flows = new ArrayList<>(); private String headerName; private String headerValuePrefix; + /** + * Gets the type of the security. + * + * @return the type of the security + */ public Set getSecurityTypes() { return securityTypes; } @@ -25,6 +34,11 @@ public void setSecurityTypes(Set securityTypes) { this.securityTypes = securityTypes; } + /** + * Gets the OAuth2 scopes for OAUTH2. + * + * @return the OAuth2 scopes for OAUTH2 + */ public Set getScopes() { return scopes; } @@ -33,6 +47,24 @@ public void setScopes(Set scopes) { this.scopes = scopes; } + /** + * Gets the OAuth2 flows for OAUTH2. + * + * @return the OAuth2 flows for OAUTH2 + */ + public List getFlows() { + return flows; + } + + public void setFlows(List flows) { + this.flows = flows; + } + + /** + * Gets the name of the header for KEY auth. + * + * @return the name of the header for KEY auth + */ public String getHeaderName() { return headerName; } @@ -41,6 +73,11 @@ public void setHeaderName(String headerName) { this.headerName = headerName; } + /** + * Gets the prefix of the header value for KEY auth. + * + * @return the prefix of the header value for KEY auth + */ public String getHeaderValuePrefix() { return headerValuePrefix; } From e0cf97c48ae10d396b6c485f6030c985c422372a Mon Sep 17 00:00:00 2001 From: JoshLove-msft <54595583+JoshLove-msft@users.noreply.github.com> Date: Tue, 25 Feb 2025 09:33:23 -0800 Subject: [PATCH 05/11] Write comment statement (#6141) Fixes https://github.com/microsoft/typespec/issues/6136 Also make MethodBodyStatement.Write `abstract`. --- .../MrwSerializationTypeDefinition.cs | 2 +- .../perf/MethodProviderBenchmark.cs | 2 +- .../src/Statements/MethodBodyStatement.cs | 14 +++++++-- .../Statements/SingleLineCommentStatement.cs | 5 ++++ .../test/Statements/StatementTests.cs | 30 ++++++++++++------- ...tSwitchStatementWithUsingStatementWrite.cs | 1 + 6 files changed, 38 insertions(+), 16 deletions(-) diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.ClientModel/src/Providers/MrwSerializationTypeDefinition.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.ClientModel/src/Providers/MrwSerializationTypeDefinition.cs index 10a530cd16d..fd66125f61f 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.ClientModel/src/Providers/MrwSerializationTypeDefinition.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.ClientModel/src/Providers/MrwSerializationTypeDefinition.cs @@ -1313,7 +1313,7 @@ private ConstructorProvider BuildEmptyConstructor() var accessibility = _isStruct ? MethodSignatureModifiers.Public : MethodSignatureModifiers.Internal; return new ConstructorProvider( signature: new ConstructorSignature(Type, $"Initializes a new instance of {Type:C} for deserialization.", accessibility, Array.Empty()), - bodyStatements: new MethodBodyStatement(), + bodyStatements: MethodBodyStatement.Empty, this); } diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/perf/MethodProviderBenchmark.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/perf/MethodProviderBenchmark.cs index 1b15e0e6cd5..106ef0c4bbb 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/perf/MethodProviderBenchmark.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/perf/MethodProviderBenchmark.cs @@ -13,7 +13,7 @@ namespace Microsoft.TypeSpec.Generator.Perf public class MethodProviderBenchmark { private MethodSignature Signature { get; } - private MethodBodyStatement BodyStatement = new(); + private MethodBodyStatement BodyStatement = MethodBodyStatement.Empty; private Dictionary>? ParamHash; public MethodProviderBenchmark() diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/Statements/MethodBodyStatement.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/Statements/MethodBodyStatement.cs index 2039bd74a03..6bec0604050 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/Statements/MethodBodyStatement.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/Statements/MethodBodyStatement.cs @@ -7,9 +7,9 @@ namespace Microsoft.TypeSpec.Generator.Statements { [DebuggerDisplay("{GetDebuggerDisplay(),nq}")] - public class MethodBodyStatement + public abstract class MethodBodyStatement { - internal virtual void Write(CodeWriter writer) { } + internal abstract void Write(CodeWriter writer); public static implicit operator MethodBodyStatement(MethodBodyStatement[] statements) => new MethodBodyStatements(statements); public static implicit operator MethodBodyStatement(List statements) => new MethodBodyStatements(statements); @@ -21,7 +21,15 @@ internal override void Write(CodeWriter writer) } } - public static readonly MethodBodyStatement Empty = new(); + private class PrivateEmptyStatement : MethodBodyStatement + { + internal override void Write(CodeWriter writer) + { + // Do nothing + } + } + + public static readonly MethodBodyStatement Empty = new PrivateEmptyStatement(); public static readonly MethodBodyStatement EmptyLine = new PrivateEmptyLineStatement(); public string ToDisplayString() => GetDebuggerDisplay(); diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/Statements/SingleLineCommentStatement.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/Statements/SingleLineCommentStatement.cs index 60a08161cbb..6900ab15c81 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/Statements/SingleLineCommentStatement.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/Statements/SingleLineCommentStatement.cs @@ -16,5 +16,10 @@ public SingleLineCommentStatement(FormattableString message) public SingleLineCommentStatement(string message) : this(FormattableStringHelpers.FromString(message)) { } + + internal override void Write(CodeWriter writer) + { + writer.WriteLine($"// {Message}"); + } } } diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/test/Statements/StatementTests.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/test/Statements/StatementTests.cs index dd62b9b3bda..97aaa25da43 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/test/Statements/StatementTests.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/test/Statements/StatementTests.cs @@ -41,7 +41,7 @@ public void ForStatementWithAddMethod() var condition = True; var increment = ValueExpression.Empty; var forStatement = new ForStatement(assignment, condition, increment); - var statementToAdd = new MethodBodyStatement(); + var statementToAdd = MethodBodyStatement.Empty; forStatement.Add(statementToAdd); @@ -73,7 +73,7 @@ public void CreateForeachStatement() public void ForeachStatementWithAddMethod() { var foreachStatement = new ForeachStatement(new CSharpType(typeof(int)), "item", ValueExpression.Empty, isAsync: false, out var itemReference); - var statementToAdd = new MethodBodyStatement(); + var statementToAdd = MethodBodyStatement.Empty; foreachStatement.Add(statementToAdd); @@ -98,7 +98,7 @@ public void IfStatementWithBoolExpression() public void IfStatementWithAddMethod() { var ifStatement = new IfStatement(True); - var statementToAdd = new MethodBodyStatement(); + var statementToAdd = MethodBodyStatement.Empty; ifStatement.Add(statementToAdd); @@ -139,7 +139,7 @@ public void IfStatementAddBracesOptionFalse() public void IfElseStatementWithIfAndElse() { var condition = True; - var elseStatement = new MethodBodyStatement(); + var elseStatement = MethodBodyStatement.Empty; var ifElseStatement = new IfElseStatement(new IfStatement(condition), elseStatement); @@ -153,8 +153,8 @@ public void IfElseStatementWithIfAndElse() public void IfElseStatementWithConditionAndStatements() { var condition = True; - var ifStatement = new MethodBodyStatement(); - var elseStatement = new MethodBodyStatement(); + var ifStatement = MethodBodyStatement.Empty; + var elseStatement = MethodBodyStatement.Empty; var ifElseStatement = new IfElseStatement(condition, ifStatement, elseStatement); @@ -170,7 +170,7 @@ public void SwitchStatementWithSingleCase() var matchExpression = ValueExpression.Empty; var switchStatement = new SwitchStatement(matchExpression); - var caseStatement = new MethodBodyStatement(); + var caseStatement = MethodBodyStatement.Empty; var switchCase = new SwitchCaseStatement(ValueExpression.Empty, caseStatement); switchStatement.Add(switchCase); @@ -187,8 +187,8 @@ public void SwitchStatementWithMultipleCases() var caseStatements = new List { - new SwitchCaseStatement(ValueExpression.Empty, new MethodBodyStatement()), - new SwitchCaseStatement(ValueExpression.Empty, new MethodBodyStatement()) + new SwitchCaseStatement(ValueExpression.Empty, MethodBodyStatement.Empty), + new SwitchCaseStatement(ValueExpression.Empty, MethodBodyStatement.Empty) }; foreach (var switchCase in caseStatements) @@ -207,8 +207,8 @@ public void SwitchStatementEnumeratingCases() var caseStatements = new List { - new SwitchCaseStatement(ValueExpression.Empty, new MethodBodyStatement()), - new SwitchCaseStatement(ValueExpression.Empty, new MethodBodyStatement()) + new SwitchCaseStatement(ValueExpression.Empty, MethodBodyStatement.Empty), + new SwitchCaseStatement(ValueExpression.Empty, MethodBodyStatement.Empty) }; foreach (var switchCase in caseStatements) @@ -271,6 +271,7 @@ public void TestSwitchStatementWithUsingStatementWrite() var switchStatement = new SwitchStatement(variableFoo); var usingStatement = new UsingScopeStatement(null, new CodeWriterDeclaration("x"), New.Instance(typeof(MemoryStream))) { + new SingleLineCommentStatement("some comment explaining the return"), Return(variableFoo) }; @@ -546,5 +547,12 @@ public void TestFlatten_CorrectNestedOrder() }; Assert.AreEqual(expectedOrder, result); } + + [Test] + public void SingleLineCommentStatement() + { + var comment = new SingleLineCommentStatement("This is a comment"); + Assert.AreEqual("// This is a comment\n", comment.ToDisplayString()); + } } } diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/test/Statements/TestData/StatementTests/TestSwitchStatementWithUsingStatementWrite.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/test/Statements/TestData/StatementTests/TestSwitchStatementWithUsingStatementWrite.cs index 710dc1f42dd..fd39f093ceb 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/test/Statements/TestData/StatementTests/TestSwitchStatementWithUsingStatementWrite.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/test/Statements/TestData/StatementTests/TestSwitchStatementWithUsingStatementWrite.cs @@ -6,6 +6,7 @@ public bool Foo() case true: using (var x = new global::System.IO.MemoryStream()) { + // some comment explaining the return return foo; } default: From 4dcc26b0316f16e25f1f69097c5da58a2dd31a79 Mon Sep 17 00:00:00 2001 From: Timothee Guerin Date: Tue, 25 Feb 2025 12:07:42 -0800 Subject: [PATCH 06/11] Exclude tsp.exe from binskim (#6145) PR adding some baseline thing to give time to fix issues, https://github.com/microsoft/typespec/pull/6134 we can't actually fix those as we don't build this binary we just inject our code into node's so just ignoring the validation of the `tsp.exe` --- eng/common/pipelines/ci.yml | 2 ++ eng/tsp-core/pipelines/publish.yml | 2 ++ 2 files changed, 4 insertions(+) diff --git a/eng/common/pipelines/ci.yml b/eng/common/pipelines/ci.yml index 3f1af419221..e1fefbd74f8 100644 --- a/eng/common/pipelines/ci.yml +++ b/eng/common/pipelines/ci.yml @@ -12,6 +12,8 @@ pr: extends: template: /eng/common/pipelines/templates/1es-redirect.yml parameters: + BinSkimSettings: + targetPathExclusionPattern: "tsp.exe" # Flag issue with node binary which we can't fix https://github.com/nodejs/node/issues/42100 stages: - stage: InitStage displayName: Initialize diff --git a/eng/tsp-core/pipelines/publish.yml b/eng/tsp-core/pipelines/publish.yml index 4a8d65ecc36..509500bd552 100644 --- a/eng/tsp-core/pipelines/publish.yml +++ b/eng/tsp-core/pipelines/publish.yml @@ -15,6 +15,8 @@ pr: none extends: template: /eng/common/pipelines/templates/1es-redirect.yml parameters: + BinSkimSettings: + targetPathExclusionPattern: "tsp.exe" # Flag issue with node binary which we can't fix https://github.com/nodejs/node/issues/42100 variables: - template: /eng/tsp-core/pipelines/templates/variables/globals.yml@self From e878d39fe0a9cbb73170b2d5bfdf8ee438fb0deb Mon Sep 17 00:00:00 2001 From: Timothee Guerin Date: Tue, 25 Feb 2025 15:45:32 -0800 Subject: [PATCH 07/11] Fix don't shrink icons when text is too long (#6150) Before image after image --- packages/react-components/src/tree/tree.module.css | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/react-components/src/tree/tree.module.css b/packages/react-components/src/tree/tree.module.css index 5970f1a2080..e7c02187fb4 100644 --- a/packages/react-components/src/tree/tree.module.css +++ b/packages/react-components/src/tree/tree.module.css @@ -25,12 +25,14 @@ .tree-row .caret { width: 16px; + flex: 0 0 16px; display: flex; align-items: center; } .tree-row .icon { width: 16px; + flex: 0 0 16px; display: flex; align-items: center; } From 817fdb33a870c0fb1f114f5473110c4502ccd8f5 Mon Sep 17 00:00:00 2001 From: Timothee Guerin Date: Tue, 25 Feb 2025 15:47:37 -0800 Subject: [PATCH 08/11] Fix upload manifest for http specs (#6147) --- eng/tsp-core/pipelines/jobs/publish-npm.yml | 5 +++++ package.json | 3 +-- packages/spector/docs/using-spector.md | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/eng/tsp-core/pipelines/jobs/publish-npm.yml b/eng/tsp-core/pipelines/jobs/publish-npm.yml index 2c596a3b585..6bb05c434e8 100644 --- a/eng/tsp-core/pipelines/jobs/publish-npm.yml +++ b/eng/tsp-core/pipelines/jobs/publish-npm.yml @@ -45,10 +45,15 @@ jobs: } displayName: "Check if @typespec/http-specs was published" + - script: pnpm -r --filter '@typespec/http-specs...' build + condition: eq(variables['PublishHttpSpecs'], 'true') + displayName: Build spector + - task: AzureCLI@2 displayName: Upload scenario manifest condition: eq(variables['PublishHttpSpecs'], 'true') inputs: + workingDirectory: packages/http-specs azureSubscription: "TypeSpec Storage" scriptType: "bash" scriptLocation: "inlineScript" diff --git a/package.json b/package.json index b09c4195f30..411a2d34cc4 100644 --- a/package.json +++ b/package.json @@ -36,8 +36,7 @@ "sync-labels": "tsx ./eng/common/scripts/labels/sync-labels.ts --config ./eng/common/config/labels.ts", "validate-scenarios": "pnpm -r --filter=@typespec/http-specs run validate-scenarios", "validate-mock-apis": "pnpm -r --filter=@typespec/http-specs run validate-mock-apis", - "generate-scenarios-summary": "pnpm -r --filter=@typespec/http-specs run generate-scenarios-summary", - "upload-manifest": "pnpm -r --filter=@typespec/http-specs run upload-manifest" + "generate-scenarios-summary": "pnpm -r --filter=@typespec/http-specs run generate-scenarios-summary" }, "devDependencies": { "@alloy-js/prettier-plugin-alloy": "^0.1.0", diff --git a/packages/spector/docs/using-spector.md b/packages/spector/docs/using-spector.md index 68680a2c259..a35e8fec8ba 100644 --- a/packages/spector/docs/using-spector.md +++ b/packages/spector/docs/using-spector.md @@ -90,7 +90,7 @@ Add the following step ```yaml - task: AzureCLI@2 - displayName: Upload scenario manifest + displayName: Upload scenario coverage inputs: azureSubscription: "Typespec Storage" scriptType: "bash" From 1e114fec88e210c84e113bd5d35525a50c21769a Mon Sep 17 00:00:00 2001 From: Timothee Guerin Date: Tue, 25 Feb 2025 17:16:56 -0800 Subject: [PATCH 09/11] Exclude binskim take2 (#6148) --- eng/common/pipelines/ci.yml | 2 +- eng/tsp-core/pipelines/publish.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/eng/common/pipelines/ci.yml b/eng/common/pipelines/ci.yml index e1fefbd74f8..f679a844652 100644 --- a/eng/common/pipelines/ci.yml +++ b/eng/common/pipelines/ci.yml @@ -13,7 +13,7 @@ extends: template: /eng/common/pipelines/templates/1es-redirect.yml parameters: BinSkimSettings: - targetPathExclusionPattern: "tsp.exe" # Flag issue with node binary which we can't fix https://github.com/nodejs/node/issues/42100 + analyzeTargetGlob: +:file|**/*.dll;+:file|**/*.exe;-:f|**/tsp.exe # Flag issue with node binary which we can't fix https://github.com/nodejs/node/issues/42100 stages: - stage: InitStage displayName: Initialize diff --git a/eng/tsp-core/pipelines/publish.yml b/eng/tsp-core/pipelines/publish.yml index 509500bd552..5fc8501f5a5 100644 --- a/eng/tsp-core/pipelines/publish.yml +++ b/eng/tsp-core/pipelines/publish.yml @@ -16,7 +16,7 @@ extends: template: /eng/common/pipelines/templates/1es-redirect.yml parameters: BinSkimSettings: - targetPathExclusionPattern: "tsp.exe" # Flag issue with node binary which we can't fix https://github.com/nodejs/node/issues/42100 + analyzeTargetGlob: +:file|**/*.dll;+:file|**/*.exe;-:f|**/tsp.exe # Flag issue with node binary which we can't fix https://github.com/nodejs/node/issues/42100 variables: - template: /eng/tsp-core/pipelines/templates/variables/globals.yml@self From c6ae78e1c8f7e979e5f5a4e94fd93a134853f48c Mon Sep 17 00:00:00 2001 From: Dapeng Zhang Date: Wed, 26 Feb 2025 09:29:54 +0800 Subject: [PATCH 10/11] introduce IPC between ts part and C# part to report diagnostics and write logs (#5917) Fixes https://github.com/microsoft/typespec/issues/5920 --- .../http-client-csharp/emitter/src/emitter.ts | 59 +++------- .../emitter/src/lib/logger.ts | 14 +++ .../emitter/src/lib/type-converter.ts | 6 + .../emitter/src/lib/utils.ts | 98 ++++++++++++++++ .../emitter/src/sdk-context.ts | 1 + .../emitter/test/Unit/utils/test-util.ts | 1 + .../TypeSpecInputEnumTypeConverter.cs | 4 - .../src/CSharpGen.cs | 3 +- .../src/EmitterRpc/Emitter.cs | 105 ++++++++++++++++++ .../src/StartUp/Program.cs | 6 +- .../SamplePluginLibraryLibraryVisitor.cs | 39 ------- .../OutputTypes/SamplePluginLibraryVisitor.cs | 45 ++++++++ .../SamplePluginPropertyProvider.cs | 14 ++- .../SamplePluginMethodProviderCollection.cs | 17 ++- .../SamplePlugin/src/SampleCodeModelPlugin.cs | 2 +- .../SamplePlugin/src/SamplePlugin.csproj | 2 +- 16 files changed, 312 insertions(+), 104 deletions(-) create mode 100644 packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/EmitterRpc/Emitter.cs delete mode 100644 packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginLibraryLibraryVisitor.cs create mode 100644 packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginLibraryVisitor.cs diff --git a/packages/http-client-csharp/emitter/src/emitter.ts b/packages/http-client-csharp/emitter/src/emitter.ts index 91d5cc90c7d..7d9a916a4e6 100644 --- a/packages/http-client-csharp/emitter/src/emitter.ts +++ b/packages/http-client-csharp/emitter/src/emitter.ts @@ -22,7 +22,7 @@ import { import { createModel } from "./lib/client-model-builder.js"; import { LoggerLevel } from "./lib/logger-level.js"; import { Logger } from "./lib/logger.js"; -import { execAsync } from "./lib/utils.js"; +import { execAsync, execCSharpGenerator } from "./lib/utils.js"; import { _resolveOutputFolder, CSharpEmitterOptions, resolveOptions } from "./options.js"; import { defaultSDKContextOptions } from "./sdk-context-options.js"; import { CSharpEmitterContext } from "./sdk-context.js"; @@ -59,7 +59,7 @@ export async function $onEmit(context: EmitContext) { const options = resolveOptions(context); const outputFolder = _resolveOutputFolder(context); - /* set the loglevel. */ + /* set the log level. */ const logger = new Logger(program, options.logLevel ?? LoggerLevel.INFO); if (!program.compilerOptions.noEmit && !program.hasError()) { @@ -72,6 +72,7 @@ export async function $onEmit(context: EmitContext) { )), logger: logger, __typeCache: { + crossLanguageDefinitionIds: new Map(), types: new Map(), models: new Map(), enums: new Map(), @@ -112,9 +113,6 @@ export async function $onEmit(context: EmitContext) { `${configurations["package-name"]}.csproj`, ); logger.info(`Checking if ${csProjFile} exists`); - const newProjectOption = - options["new-project"] || !checkFile(csProjFile) ? "--new-project" : ""; - const debugFlag = (options.debug ?? false) ? "--debug" : ""; const emitterPath = options["emitter-extension-path"] ?? import.meta.url; const projectRoot = findProjectRoot(dirname(fileURLToPath(emitterPath))); @@ -122,31 +120,21 @@ export async function $onEmit(context: EmitContext) { projectRoot + "/dist/generator/Microsoft.TypeSpec.Generator.dll", ); - const command = `dotnet --roll-forward Major ${generatorPath} ${outputFolder} -p ${options["plugin-name"]}${constructCommandArg(newProjectOption)}${constructCommandArg(debugFlag)}`; - logger.info(command); - try { - const result = await execAsync( - "dotnet", - [ - "--roll-forward", - "Major", - generatorPath, - outputFolder, - "-p", - options["plugin-name"], - newProjectOption, - debugFlag, - ], - { stdio: "inherit" }, - ); + const result = await execCSharpGenerator(sdkContext, { + generatorPath: generatorPath, + outputFolder: outputFolder, + pluginName: options["plugin-name"], + newProject: options["new-project"] ?? !checkFile(csProjFile), + debug: options.debug ?? false, + }); if (result.exitCode !== 0) { const isValid = await _validateDotNetSdk(sdkContext, _minSupportedDotNetSdkVersion); // if the dotnet sdk is valid, the error is not dependency issue, log it as normal if (isValid) { - if (result.stderr) logger.error(result.stderr); - if (result.stdout) logger.verbose(result.stdout); - throw new Error(`Failed to generate the library. Exit code: ${result.exitCode}`); + throw new Error( + `Failed to generate the library. Exit code: ${result.exitCode}.\nStackTrace: \n${result.stderr}`, + ); } } } catch (error: any) { @@ -156,8 +144,8 @@ export async function $onEmit(context: EmitContext) { } if (!options["save-inputs"]) { // delete - deleteFile(resolvePath(outputFolder, tspOutputFileName), logger); - deleteFile(resolvePath(outputFolder, configurationFileName), logger); + context.program.host.rm(resolvePath(outputFolder, tspOutputFileName)); + context.program.host.rm(resolvePath(outputFolder, configurationFileName)); } } } @@ -196,7 +184,7 @@ export async function _validateDotNetSdk( const result = await execAsync("dotnet", ["--version"], { stdio: "pipe" }); return validateDotNetSdkVersionCore(sdkContext, result.stdout, minMajorVersion); } catch (error: any) { - if (error && "code" in (error as {}) && error["code"] === "ENOENT") { + if (error && "code" in error && error["code"] === "ENOENT") { sdkContext.logger.reportDiagnostic({ code: "invalid-dotnet-sdk-dependency", messageId: "missing", @@ -222,7 +210,6 @@ function validateDotNetSdkVersionCore( const major = Number(firstPart); if (isNaN(major)) { - sdkContext.logger.error("Invalid .NET SDK version."); return false; } if (major < minMajorVersion) { @@ -245,10 +232,6 @@ function validateDotNetSdkVersionCore( } } -function constructCommandArg(arg: string): string { - return arg !== "" ? ` ${arg}` : ""; -} - function transformJSONProperties(this: any, key: string, value: any): any { // convertUsageNumbersToStrings if (this["kind"] === "model" || this["kind"] === "enum") { @@ -276,16 +259,6 @@ function transformJSONProperties(this: any, key: string, value: any): any { return value; } -function deleteFile(filePath: string, logger: Logger) { - fs.unlink(filePath, (err) => { - if (err) { - logger.error(`Failed to delete files: ${err}`); - } else { - logger.info(`File ${filePath} is deleted.`); - } - }); -} - function prettierOutput(output: string) { return output + "\n"; } diff --git a/packages/http-client-csharp/emitter/src/lib/logger.ts b/packages/http-client-csharp/emitter/src/lib/logger.ts index b0732ab0285..8b087a400f3 100644 --- a/packages/http-client-csharp/emitter/src/lib/logger.ts +++ b/packages/http-client-csharp/emitter/src/lib/logger.ts @@ -24,6 +24,20 @@ export class Logger { this.program = program; } + trace(level: LoggerLevel, message: string): void { + switch (level) { + case LoggerLevel.INFO: + this.info(message); + break; + case LoggerLevel.DEBUG: + this.debug(message); + break; + case LoggerLevel.VERBOSE: + this.verbose(message); + break; + } + } + info(message: string): void { if ( this.level === LoggerLevel.INFO || diff --git a/packages/http-client-csharp/emitter/src/lib/type-converter.ts b/packages/http-client-csharp/emitter/src/lib/type-converter.ts index 1222917982d..0b4b4b4efdd 100644 --- a/packages/http-client-csharp/emitter/src/lib/type-converter.ts +++ b/packages/http-client-csharp/emitter/src/lib/type-converter.ts @@ -122,6 +122,12 @@ function updateSdkTypeReferences( inputType: InputType, ) { sdkContext.__typeCache.types.set(sdkType, inputType); + if ("crossLanguageDefinitionId" in sdkType) { + sdkContext.__typeCache.crossLanguageDefinitionIds.set( + sdkType.crossLanguageDefinitionId, + sdkType, + ); + } } export function fromSdkModelType( diff --git a/packages/http-client-csharp/emitter/src/lib/utils.ts b/packages/http-client-csharp/emitter/src/lib/utils.ts index a5de42eeaa2..ed9fbaf0e32 100644 --- a/packages/http-client-csharp/emitter/src/lib/utils.ts +++ b/packages/http-client-csharp/emitter/src/lib/utils.ts @@ -1,4 +1,102 @@ +import { NoTarget, Type } from "@typespec/compiler"; import { spawn, SpawnOptions } from "child_process"; +import { CSharpEmitterContext } from "../sdk-context.js"; + +export async function execCSharpGenerator( + context: CSharpEmitterContext, + options: { + generatorPath: string; + outputFolder: string; + pluginName: string; + newProject: boolean; + debug: boolean; + }, +): Promise<{ exitCode: number; stderr: string; proc: any }> { + const command = "dotnet"; + const args = [ + "--roll-forward", + "Major", + options.generatorPath, + options.outputFolder, + "-p", + options.pluginName, + ]; + if (options.newProject) { + args.push("--new-project"); + } + if (options.debug) { + args.push("--debug"); + } + context.logger.info(`${command} ${args.join(" ")}`); + + const child = spawn(command, args, { stdio: "pipe" }); + + const stderr: Buffer[] = []; + return new Promise((resolve, reject) => { + let buffer = ""; + + child.stdout?.on("data", (data) => { + buffer += data.toString(); + let index; + while ((index = buffer.indexOf("\n")) !== -1) { + const message = buffer.slice(0, index); + buffer = buffer.slice(index + 1); + processJsonRpc(context, message); + } + }); + + child.stderr?.on("data", (data) => { + stderr.push(data); + }); + + child.on("error", (error) => { + reject(error); + }); + + child.on("exit", (exitCode) => { + resolve({ + exitCode: exitCode ?? -1, + stderr: Buffer.concat(stderr).toString(), + proc: child, + }); + }); + }); +} + +function processJsonRpc(context: CSharpEmitterContext, message: string) { + const response = JSON.parse(message); + const method = response.method; + const params = response.params; + switch (method) { + case "trace": + context.logger.trace(params.level, params.message); + break; + case "diagnostic": + let crossLanguageDefinitionId: string | undefined; + if ("crossLanguageDefinitionId" in params) { + crossLanguageDefinitionId = params.crossLanguageDefinitionId; + } + context.logger.reportDiagnostic({ + code: params.code, + format: { + message: params.message, + }, + target: findTarget(crossLanguageDefinitionId) ?? NoTarget, + }); + break; + } + + function findTarget(crossLanguageDefinitionId: string | undefined): Type | undefined { + if (crossLanguageDefinitionId === undefined) { + return undefined; + } + const target = context.__typeCache.crossLanguageDefinitionIds.get(crossLanguageDefinitionId); + if (target) { + return target.__raw; + } + return undefined; + } +} export async function execAsync( command: string, diff --git a/packages/http-client-csharp/emitter/src/sdk-context.ts b/packages/http-client-csharp/emitter/src/sdk-context.ts index f7eb05f84ec..425ddfd8432 100644 --- a/packages/http-client-csharp/emitter/src/sdk-context.ts +++ b/packages/http-client-csharp/emitter/src/sdk-context.ts @@ -16,6 +16,7 @@ export interface CSharpEmitterContext extends SdkContext { } export interface SdkTypeMap { + crossLanguageDefinitionIds: Map; types: Map; models: Map; enums: Map; diff --git a/packages/http-client-csharp/emitter/test/Unit/utils/test-util.ts b/packages/http-client-csharp/emitter/test/Unit/utils/test-util.ts index 58ddc0be946..953ab1f5202 100644 --- a/packages/http-client-csharp/emitter/test/Unit/utils/test-util.ts +++ b/packages/http-client-csharp/emitter/test/Unit/utils/test-util.ts @@ -118,6 +118,7 @@ export async function createCSharpSdkContext( ...context, logger: new Logger(program.program, LoggerLevel.INFO), __typeCache: { + crossLanguageDefinitionIds: new Map(), types: new Map(), models: new Map(), enums: new Map(), diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputEnumTypeConverter.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputEnumTypeConverter.cs index 19e37ab9ae6..36987205059 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputEnumTypeConverter.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputEnumTypeConverter.cs @@ -61,10 +61,6 @@ public static InputEnumType CreateEnumType(ref Utf8JsonReader reader, string? id } name = name ?? throw new JsonException("Enum must have name"); - if (summary is null && doc is null) - { - Console.Error.WriteLine($"[Warn]: Enum '{name}' must have either a summary or doc"); - } if (usageString != null) { diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/CSharpGen.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/CSharpGen.cs index b6a70edb7ca..e751c63608b 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/CSharpGen.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/CSharpGen.cs @@ -6,6 +6,7 @@ using System.IO; using System.Linq; using System.Threading.Tasks; +using Microsoft.TypeSpec.Generator.EmitterRpc; using Microsoft.TypeSpec.Generator.Providers; using Microsoft.TypeSpec.Generator.SourceInput; @@ -85,7 +86,7 @@ public async Task ExecuteAsync() continue; } var filename = Path.Combine(outputPath, file.Name); - Console.WriteLine($"Writing {Path.GetFullPath(filename)}"); + Emitter.Instance.Info($"Writing {Path.GetFullPath(filename)}"); Directory.CreateDirectory(Path.GetDirectoryName(filename)!); await File.WriteAllTextAsync(filename, file.Text); } diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/EmitterRpc/Emitter.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/EmitterRpc/Emitter.cs new file mode 100644 index 00000000000..ce824535c44 --- /dev/null +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/EmitterRpc/Emitter.cs @@ -0,0 +1,105 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using System; +using System.IO; +using System.Text.Json; + +namespace Microsoft.TypeSpec.Generator.EmitterRpc +{ + public sealed class Emitter : IDisposable + { + private const string BasicNotificationFormat = @"{{""method"":{0},""params"":{1}}}"; + private const string Trace = "trace"; + private const string Diagnostic = "diagnostic"; + + private static Emitter? _emitter; + private bool _disposed; + + private readonly StreamWriter _writer; + + private Emitter() + { + _writer = new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = true }; + } + + public static Emitter Instance => _emitter ??= new Emitter(); + + private void SendNotification(string method, object content) + { + var paramsContent = JsonSerializer.Serialize(content); + var message = string.Format(BasicNotificationFormat, AsStringLiteral(method), paramsContent); + _writer.WriteLine(message); + } + + private static string AsStringLiteral(string input) => $"\"{input}\""; + + public void Info(string message) + { + SendNotification(Trace, new + { + level = "info", + message = message, + }); + } + + public void Debug(string message) + { + SendNotification(Trace, new + { + level = "debug", + message = message, + }); + } + + public void Verbose(string message) + { + SendNotification(Trace, new + { + level = "verbose", + message = message, + }); + } + + public void ReportDiagnostic(string code, string message, string? targetCrossLanguageDefinitionId = null) + { + if (targetCrossLanguageDefinitionId != null) + { + SendNotification(Diagnostic, new + { + code = code, + message = message, + crossLanguageDefinitionId = targetCrossLanguageDefinitionId + }); + } + else + { + SendNotification(Diagnostic, new + { + code = code, + message = message, + }); + } + } + + private void Dispose(bool disposing) + { + if (!_disposed) + { + if (disposing) + { + _writer.Dispose(); + } + + _disposed = true; + } + } + + void IDisposable.Dispose() + { + // Do not change this code. Put cleanup code in 'Dispose(bool disposing)' method + Dispose(disposing: true); + GC.SuppressFinalize(this); + } + } +} diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/StartUp/Program.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/StartUp/Program.cs index a4e429f3b2f..a85d40cf09f 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/StartUp/Program.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator/src/StartUp/Program.cs @@ -5,6 +5,7 @@ using System.Diagnostics; using System.Threading.Tasks; using CommandLine; +using Microsoft.TypeSpec.Generator.EmitterRpc; namespace Microsoft.TypeSpec.Generator { @@ -30,9 +31,11 @@ public static async Task Main(string[] args) private static async Task Run(CommandLineOptions options, GeneratorRunner runner) { + using var emitter = Emitter.Instance; + if (options.ShouldDebug) { - await Console.Error.WriteLineAsync("Attempting to attach debugger.."); + emitter.Debug("Attempting to attach debugger.."); Debugger.Launch(); } @@ -46,6 +49,7 @@ private static async Task Run(CommandLineOptions options, GeneratorRunner r Console.Error.WriteLine(e.StackTrace); return 1; } + return 0; } } diff --git a/packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginLibraryLibraryVisitor.cs b/packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginLibraryLibraryVisitor.cs deleted file mode 100644 index 6d49f70e2e9..00000000000 --- a/packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginLibraryLibraryVisitor.cs +++ /dev/null @@ -1,39 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -using Microsoft.Generator.CSharp; -using Microsoft.Generator.CSharp.ClientModel; -using Microsoft.Generator.CSharp.ClientModel.Providers; -using Microsoft.Generator.CSharp.Input; -using Microsoft.Generator.CSharp.Primitives; -using Microsoft.Generator.CSharp.Providers; -using SamplePlugin.Providers; - -namespace SamplePlugin -{ - public class SamplePluginLibraryLibraryVisitor : ScmLibraryVisitor - { - protected override MethodProvider Visit(TypeProvider typeProvider, MethodProvider methodProvider) - { - if (methodProvider is not ScmMethodProvider) - { - return methodProvider; - } - - methodProvider.Signature.Update(name: $"Foo{methodProvider.Signature.Name}"); - return methodProvider; - } - - protected override PropertyProvider Visit(InputModelProperty property, PropertyProvider? propertyProvider) - { - return new SamplePluginPropertyProvider(property); - } - - protected override MethodProviderCollection Visit(InputOperation operation, - TypeProvider enclosingType, - MethodProviderCollection? methodProvider) - { - return new SamplePluginMethodProviderCollection(operation, enclosingType); - } - } -} diff --git a/packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginLibraryVisitor.cs b/packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginLibraryVisitor.cs new file mode 100644 index 00000000000..4ee99143cd2 --- /dev/null +++ b/packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginLibraryVisitor.cs @@ -0,0 +1,45 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +using Microsoft.TypeSpec.Generator.ClientModel; +using Microsoft.TypeSpec.Generator.ClientModel.Providers; +using Microsoft.TypeSpec.Generator.EmitterRpc; +using Microsoft.TypeSpec.Generator.Input; +using Microsoft.TypeSpec.Generator.Providers; +using SamplePlugin.Providers; + +namespace SamplePlugin +{ + public class SamplePluginLibraryVisitor : ScmLibraryVisitor + { + protected override MethodProvider? VisitMethod(MethodProvider method) + { + if (method is not ScmMethodProvider) + { + return method; + } + + Emitter.Instance.Info($"Visiting method {method.Signature.Name} in type {method.EnclosingType.Type}"); + method.Signature.Update(name: $"Foo{method.Signature.Name}"); + return method; + } + + protected override PropertyProvider? PreVisitProperty(InputModelProperty property, PropertyProvider? propertyProvider) + { + Emitter.Instance.Info($"PreVisiting property {property.Name} in model {property.EnclosingType?.Name}"); + if (propertyProvider is not null) + { + return new SamplePluginPropertyProvider(property, propertyProvider.EnclosingType); + } + return null; + } + + protected override MethodProviderCollection Visit(InputOperation operation, + TypeProvider enclosingType, + MethodProviderCollection? methodProvider) + { + Emitter.Instance.Info($"Visiting methodProviderCollection for operation {operation.Path} in type {enclosingType.Type.Name}"); + return new SamplePluginMethodProviderCollection(operation, enclosingType); + } + } +} diff --git a/packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginPropertyProvider.cs b/packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginPropertyProvider.cs index 5925801b9b3..e629b03fda5 100644 --- a/packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginPropertyProvider.cs +++ b/packages/http-client-csharp/generator/SamplePlugin/src/OutputTypes/SamplePluginPropertyProvider.cs @@ -1,14 +1,18 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. +// Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. -using Microsoft.Generator.CSharp.Input; -using Microsoft.Generator.CSharp.Primitives; -using Microsoft.Generator.CSharp.Providers; +using Microsoft.TypeSpec.Generator.Input; +using Microsoft.TypeSpec.Generator.Primitives; +using Microsoft.TypeSpec.Generator.Providers; namespace SamplePlugin { - public class SamplePluginPropertyProvider(InputModelProperty inputModel) : PropertyProvider(inputModel) + public class SamplePluginPropertyProvider : PropertyProvider { + public SamplePluginPropertyProvider(InputModelProperty inputProperty, TypeProvider enclosingType) : base(inputProperty, enclosingType) + { + } + protected override bool PropertyHasSetter(CSharpType type, InputModelProperty inputProperty) { return type.IsCollection || base.PropertyHasSetter(type, inputProperty); diff --git a/packages/http-client-csharp/generator/SamplePlugin/src/Providers/SamplePluginMethodProviderCollection.cs b/packages/http-client-csharp/generator/SamplePlugin/src/Providers/SamplePluginMethodProviderCollection.cs index c5e10e75275..04344a39d48 100644 --- a/packages/http-client-csharp/generator/SamplePlugin/src/Providers/SamplePluginMethodProviderCollection.cs +++ b/packages/http-client-csharp/generator/SamplePlugin/src/Providers/SamplePluginMethodProviderCollection.cs @@ -3,15 +3,14 @@ using System; using System.Collections.Generic; -using Microsoft.Generator.CSharp.ClientModel; -using Microsoft.Generator.CSharp.ClientModel.Providers; -using Microsoft.Generator.CSharp.Expressions; -using Microsoft.Generator.CSharp.Input; -using Microsoft.Generator.CSharp.Primitives; -using Microsoft.Generator.CSharp.Providers; -using Microsoft.Generator.CSharp.Snippets; -using Microsoft.Generator.CSharp.Statements; -using static Microsoft.Generator.CSharp.Snippets.Snippet; +using Microsoft.TypeSpec.Generator.ClientModel; +using Microsoft.TypeSpec.Generator.ClientModel.Providers; +using Microsoft.TypeSpec.Generator.Expressions; +using Microsoft.TypeSpec.Generator.Input; +using Microsoft.TypeSpec.Generator.Providers; +using Microsoft.TypeSpec.Generator.Snippets; +using Microsoft.TypeSpec.Generator.Statements; +using static Microsoft.TypeSpec.Generator.Snippets.Snippet; namespace SamplePlugin.Providers { diff --git a/packages/http-client-csharp/generator/SamplePlugin/src/SampleCodeModelPlugin.cs b/packages/http-client-csharp/generator/SamplePlugin/src/SampleCodeModelPlugin.cs index 316935632e3..a1aa5a486e0 100644 --- a/packages/http-client-csharp/generator/SamplePlugin/src/SampleCodeModelPlugin.cs +++ b/packages/http-client-csharp/generator/SamplePlugin/src/SampleCodeModelPlugin.cs @@ -14,7 +14,7 @@ public class SampleCodeModelPlugin(GeneratorContext context) : ScmCodeModelPlugi { public override void Configure() { - AddVisitor(new SamplePluginLibraryLibraryVisitor()); + AddVisitor(new SamplePluginLibraryVisitor()); } } } diff --git a/packages/http-client-csharp/generator/SamplePlugin/src/SamplePlugin.csproj b/packages/http-client-csharp/generator/SamplePlugin/src/SamplePlugin.csproj index 826a573f524..c9ef945b56f 100644 --- a/packages/http-client-csharp/generator/SamplePlugin/src/SamplePlugin.csproj +++ b/packages/http-client-csharp/generator/SamplePlugin/src/SamplePlugin.csproj @@ -12,6 +12,6 @@ - + From c79e263ca2e67d3b622ebe642d556ff93292c71b Mon Sep 17 00:00:00 2001 From: Dapeng Zhang Date: Wed, 26 Feb 2025 12:42:22 +0800 Subject: [PATCH 11/11] bump the TCGC version to 0.51.3 (#6103) Here is the changelog: https://github.com/Azure/typespec-azure/blob/release/february-2025/packages/typespec-client-generator-core/CHANGELOG.md#0512 --- .../emitter/src/lib/client-model-builder.ts | 6 +- .../emitter/src/lib/type-converter.ts | 22 +-- .../emitter/src/type/input-client.ts | 2 +- .../emitter/src/type/input-type.ts | 8 +- .../emitter/src/type/literal-type-context.ts | 8 +- .../TypeSpecInputClientConverter.cs | 8 +- .../TypeSpecInputEnumTypeConverter.cs | 2 +- .../TypeSpecInputModelTypeConverter.cs | 2 +- .../Unbranded-TypeSpec/tspCodeModel.json | 60 +++---- .../authentication/api-key/tspCodeModel.json | 4 +- .../http/custom/tspCodeModel.json | 4 +- .../authentication/oauth2/tspCodeModel.json | 4 +- .../authentication/union/tspCodeModel.json | 2 +- .../client-operation-group/tspCodeModel.json | 12 +- .../structure/default/tspCodeModel.json | 16 +- .../structure/multi-client/tspCodeModel.json | 6 +- .../renamed-operation/tspCodeModel.json | 6 +- .../two-operation-group/tspCodeModel.json | 8 +- .../http/encode/bytes/tspCodeModel.json | 20 +-- .../http/encode/datetime/tspCodeModel.json | 20 +-- .../http/encode/duration/tspCodeModel.json | 20 +-- .../http/encode/numeric/tspCodeModel.json | 10 +- .../http/parameters/basic/tspCodeModel.json | 10 +- .../body-optionality/tspCodeModel.json | 6 +- .../collection-format/tspCodeModel.json | 6 +- .../http/parameters/spread/tspCodeModel.json | 20 +-- .../content-negotiation/tspCodeModel.json | 8 +- .../json-merge-patch/tspCodeModel.json | 8 +- .../http/payload/media-type/tspCodeModel.json | 4 +- .../http/payload/multipart/tspCodeModel.json | 46 ++--- .../srv-driven/v1/tspCodeModel.json | 4 +- .../srv-driven/v2/tspCodeModel.json | 4 +- .../status-code-range/tspCodeModel.json | 10 +- .../Spector/http/routes/tspCodeModel.json | 46 ++--- .../encoded-name/json/tspCodeModel.json | 6 +- .../endpoint/not-defined/tspCodeModel.json | 2 +- .../server/path/multiple/tspCodeModel.json | 4 +- .../http/server/path/single/tspCodeModel.json | 2 +- .../versions/not-versioned/tspCodeModel.json | 2 +- .../versions/versioned/tspCodeModel.json | 4 +- .../conditional-request/tspCodeModel.json | 2 +- .../repeatability/tspCodeModel.json | 4 +- .../http/special-words/tspCodeModel.json | 78 ++++----- .../Spector/http/type/array/tspCodeModel.json | 42 ++--- .../http/type/dictionary/tspCodeModel.json | 28 +-- .../type/enum/extensible/tspCodeModel.json | 6 +- .../http/type/enum/fixed/tspCodeModel.json | 6 +- .../http/type/model/empty/tspCodeModel.json | 8 +- .../enum-discriminator/tspCodeModel.json | 14 +- .../nested-discriminator/tspCodeModel.json | 12 +- .../not-discriminated/tspCodeModel.json | 8 +- .../inheritance/recursive/tspCodeModel.json | 6 +- .../single-discriminator/tspCodeModel.json | 16 +- .../http/type/model/usage/tspCodeModel.json | 8 +- .../type/model/visibility/tspCodeModel.json | 8 +- .../additional-properties/tspCodeModel.json | 160 +++++++++--------- .../type/property/nullable/tspCodeModel.json | 46 ++--- .../property/optionality/tspCodeModel.json | 78 ++++----- .../property/value-types/tspCodeModel.json | 138 +++++++-------- .../http/type/scalar/tspCodeModel.json | 16 +- .../Spector/http/type/union/tspCodeModel.json | 98 +++++------ .../versioning/added/v1/tspCodeModel.json | 8 +- .../versioning/added/v2/tspCodeModel.json | 18 +- .../madeOptional/v1/tspCodeModel.json | 6 +- .../madeOptional/v2/tspCodeModel.json | 6 +- .../versioning/removed/v1/tspCodeModel.json | 22 +-- .../versioning/removed/v2/tspCodeModel.json | 14 +- .../removed/v2Preview/tspCodeModel.json | 20 +-- .../renamedFrom/v1/tspCodeModel.json | 12 +- .../renamedFrom/v2/tspCodeModel.json | 12 +- .../v1/tspCodeModel.json | 4 +- .../v2/tspCodeModel.json | 4 +- .../typeChangedFrom/v1/tspCodeModel.json | 6 +- .../typeChangedFrom/v2/tspCodeModel.json | 6 +- packages/http-client-csharp/package-lock.json | 8 +- packages/http-client-csharp/package.json | 2 +- 76 files changed, 686 insertions(+), 686 deletions(-) diff --git a/packages/http-client-csharp/emitter/src/lib/client-model-builder.ts b/packages/http-client-csharp/emitter/src/lib/client-model-builder.ts index a7cd82c9d3f..4b204c11576 100644 --- a/packages/http-client-csharp/emitter/src/lib/client-model-builder.ts +++ b/packages/http-client-csharp/emitter/src/lib/client-model-builder.ts @@ -93,7 +93,7 @@ export function createModel(sdkContext: CSharpEmitterContext): CodeModel { const clientParameters = fromSdkEndpointParameter(endpointParameter); const clientName = getClientName(client, parentNames); // see if this namespace is a sub-namespace of an existing bad namespace - const segments = client.clientNamespace.split("."); + const segments = client.namespace.split("."); const lastSegment = segments[segments.length - 1]; if (lastSegment === clientName) { // we report diagnostics when the last segment of the namespace is the same as the client name @@ -101,14 +101,14 @@ export function createModel(sdkContext: CSharpEmitterContext): CodeModel { // in csharp, this will cause a conflict between the namespace and the class name sdkContext.logger.reportDiagnostic({ code: "client-namespace-conflict", - format: { clientNamespace: client.clientNamespace, clientName }, + format: { namespace: client.namespace, clientName }, target: client.__raw.type ?? NoTarget, }); } return { Name: clientName, - ClientNamespace: client.clientNamespace, + Namespace: client.namespace, Summary: client.summary, Doc: client.doc, Operations: client.methods diff --git a/packages/http-client-csharp/emitter/src/lib/type-converter.ts b/packages/http-client-csharp/emitter/src/lib/type-converter.ts index 0b4b4b4efdd..6f95f598771 100644 --- a/packages/http-client-csharp/emitter/src/lib/type-converter.ts +++ b/packages/http-client-csharp/emitter/src/lib/type-converter.ts @@ -53,7 +53,7 @@ export function fromSdkType( retVar = { kind: "nullable", type: inputType, - clientNamespace: sdkType.clientNamespace, + namespace: sdkType.namespace, }; break; case "model": @@ -140,7 +140,7 @@ export function fromSdkModelType( inputModelType = { kind: "model", name: modelTypeName, - clientNamespace: modelType.clientNamespace, + namespace: modelType.namespace, crossLanguageDefinitionId: modelType.crossLanguageDefinitionId, access: getAccessOverride(sdkContext, modelType.__raw as Model), usage: modelType.usage, @@ -163,9 +163,9 @@ export function fromSdkModelType( continue; } const ourProperty = fromSdkModelProperty(sdkContext, property, { - ModelName: modelTypeName, - Usage: modelType.usage, - ClientNamespace: modelType.clientNamespace, + modelName: modelTypeName, + usage: modelType.usage, + namespace: modelType.namespace, } as LiteralTypeContext); propertiesDict.set(property, ourProperty); } @@ -204,7 +204,7 @@ export function fromSdkModelType( } const serializedName = property.serializedName; - literalTypeContext.PropertyName = serializedName; + literalTypeContext.propertyName = serializedName; const modelProperty: InputModelProperty = { kind: property.kind, @@ -246,7 +246,7 @@ export function fromSdkEnumType( valueType: fromSdkBuiltInType(sdkContext, enumType.valueType), values: values, access: getAccessOverride(sdkContext, enumType.__raw as any), - clientNamespace: enumType.clientNamespace, + namespace: enumType.namespace, deprecation: enumType.deprecation, summary: enumType.summary, doc: enumType.doc, @@ -336,7 +336,7 @@ function fromUnionType(sdkContext: CSharpEmitterContext, union: SdkUnionType): I kind: "union", name: union.name, variantTypes: variantTypes, - clientNamespace: union.clientNamespace, + namespace: union.namespace, decorators: union.decorators, }; } @@ -361,7 +361,7 @@ function fromSdkConstantType( constantType: SdkConstantType, literalTypeContext: LiteralTypeContext, ) { - const enumName = `${literalTypeContext.ModelName}_${literalTypeContext.PropertyName}`; + const enumName = `${literalTypeContext.modelName}_${literalTypeContext.propertyName}`; const enumValueName = constantType.value === null ? "Null" : constantType.value.toString(); const values: InputEnumTypeValue[] = []; const enumType: InputEnumType = { @@ -371,11 +371,11 @@ function fromSdkConstantType( values: values, crossLanguageDefinitionId: "", access: undefined, - clientNamespace: literalTypeContext.ClientNamespace, + namespace: literalTypeContext.namespace, doc: `The ${enumName}`, isFixed: false, isFlags: false, - usage: literalTypeContext.Usage, + usage: literalTypeContext.usage, decorators: constantType.decorators, }; diff --git a/packages/http-client-csharp/emitter/src/type/input-client.ts b/packages/http-client-csharp/emitter/src/type/input-client.ts index 4eeee6dd08d..7867bc42ba6 100644 --- a/packages/http-client-csharp/emitter/src/type/input-client.ts +++ b/packages/http-client-csharp/emitter/src/type/input-client.ts @@ -8,7 +8,7 @@ import { Protocols } from "./protocols.js"; export interface InputClient { Name: string; - ClientNamespace: string; + Namespace: string; Summary?: string; Doc?: string; Operations: InputOperation[]; diff --git a/packages/http-client-csharp/emitter/src/type/input-type.ts b/packages/http-client-csharp/emitter/src/type/input-type.ts index 1f066a104de..d5f83708b43 100644 --- a/packages/http-client-csharp/emitter/src/type/input-type.ts +++ b/packages/http-client-csharp/emitter/src/type/input-type.ts @@ -79,7 +79,7 @@ export interface InputUnionType extends InputTypeBase { kind: "union"; name: string; variantTypes: InputType[]; - clientNamespace: string; + namespace: string; } export function isInputUnionType(type: InputType): type is InputUnionType { @@ -93,7 +93,7 @@ export interface InputModelType extends InputTypeBase { crossLanguageDefinitionId: string; access?: AccessFlags; usage: UsageFlags; - clientNamespace: string; + namespace: string; additionalProperties?: InputType; discriminatorValue?: string; discriminatedSubtypes?: Record; @@ -129,7 +129,7 @@ export interface InputEnumType extends InputTypeBase { isFlags: boolean; usage: UsageFlags; access?: AccessFlags; - clientNamespace: string; + namespace: string; } export interface InputEnumTypeValue extends InputTypeBase { @@ -143,7 +143,7 @@ export interface InputEnumTypeValue extends InputTypeBase { export interface InputNullableType extends InputTypeBase { kind: "nullable"; type: InputType; - clientNamespace: string; + namespace: string; } export function isInputEnumType(type: InputType): type is InputEnumType { diff --git a/packages/http-client-csharp/emitter/src/type/literal-type-context.ts b/packages/http-client-csharp/emitter/src/type/literal-type-context.ts index 7c8b8642ee8..24e0a23826e 100644 --- a/packages/http-client-csharp/emitter/src/type/literal-type-context.ts +++ b/packages/http-client-csharp/emitter/src/type/literal-type-context.ts @@ -4,8 +4,8 @@ import { UsageFlags } from "@azure-tools/typespec-client-generator-core"; export interface LiteralTypeContext { - ModelName: string; - PropertyName: string; - Usage: UsageFlags; - ClientNamespace: string; + modelName: string; + propertyName: string; + usage: UsageFlags; + namespace: string; } diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputClientConverter.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputClientConverter.cs index b42b2576126..0edffd2b802 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputClientConverter.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputClientConverter.cs @@ -46,7 +46,7 @@ public override void Write(Utf8JsonWriter writer, InputClient value, JsonSeriali while (reader.TokenType != JsonTokenType.EndObject) { var isKnownProperty = reader.TryReadString(nameof(InputClient.Name), ref name) - || reader.TryReadString("ClientNamespace", ref @namespace) + || reader.TryReadString("Namespace", ref @namespace) || reader.TryReadString("Summary", ref summary) || reader.TryReadString("Doc", ref doc) || reader.TryReadWithConverter(nameof(InputClient.Operations), options, ref operations) @@ -81,13 +81,13 @@ public override void Write(Utf8JsonWriter writer, InputClient value, JsonSeriali return client; } - private static string GetLastSegment(string clientNamespace) + private static string GetLastSegment(string @namespace) { - var span = clientNamespace.AsSpan(); + var span = @namespace.AsSpan(); var index = span.LastIndexOf('.'); if (index == -1) { - return clientNamespace; + return @namespace; } return span.Slice(index + 1).ToString(); diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputEnumTypeConverter.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputEnumTypeConverter.cs index 36987205059..e87c7c1eece 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputEnumTypeConverter.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputEnumTypeConverter.cs @@ -42,7 +42,7 @@ public static InputEnumType CreateEnumType(ref Utf8JsonReader reader, string? id { var isKnownProperty = reader.TryReadReferenceId(ref isFirstProperty, ref id) || reader.TryReadString("name", ref name) - || reader.TryReadString("clientNamespace", ref @namespace) + || reader.TryReadString("namespace", ref @namespace) || reader.TryReadString("crossLanguageDefinitionId", ref crossLanguageDefinitionId) || reader.TryReadString("access", ref accessibility) || reader.TryReadString("deprecation", ref deprecated) diff --git a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputModelTypeConverter.cs b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputModelTypeConverter.cs index 42525aa0066..14104d127d9 100644 --- a/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputModelTypeConverter.cs +++ b/packages/http-client-csharp/generator/Microsoft.TypeSpec.Generator.Input/src/InputTypes/Serialization/TypeSpecInputModelTypeConverter.cs @@ -74,7 +74,7 @@ internal static InputModelType CreateModelType(ref Utf8JsonReader reader, string while (reader.TokenType != JsonTokenType.EndObject) { var isKnownProperty = reader.TryReadString("name", ref name) - || reader.TryReadString("clientNamespace", ref @namespace) + || reader.TryReadString("namespace", ref @namespace) || reader.TryReadString("crossLanguageDefinitionId", ref crossLanguageDefinitionId) || reader.TryReadString("access", ref accessibility) || reader.TryReadString("deprecation", ref deprecation) diff --git a/packages/http-client-csharp/generator/TestProjects/Local/Unbranded-TypeSpec/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Local/Unbranded-TypeSpec/tspCodeModel.json index 0476180bc8d..a54c91ba990 100644 --- a/packages/http-client-csharp/generator/TestProjects/Local/Unbranded-TypeSpec/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Local/Unbranded-TypeSpec/tspCodeModel.json @@ -33,7 +33,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "The Thing_requiredLiteralString", "isFixed": false, "isFlags": false, @@ -67,7 +67,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "The Thing_requiredLiteralInt", "isFixed": false, "isFlags": false, @@ -101,7 +101,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "The Thing_requiredLiteralFloat", "isFixed": false, "isFlags": false, @@ -135,7 +135,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "The Thing_optionalLiteralString", "isFixed": false, "isFlags": false, @@ -169,7 +169,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "The Thing_optionalLiteralInt", "isFixed": false, "isFlags": false, @@ -203,7 +203,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "The Thing_optionalLiteralFloat", "isFixed": false, "isFlags": false, @@ -275,7 +275,7 @@ "decorators": [] } ], - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "Simple enum", "isFixed": true, "isFlags": false, @@ -347,7 +347,7 @@ "decorators": [] } ], - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "Extensible enum", "isFixed": false, "isFlags": false, @@ -419,7 +419,7 @@ "decorators": [] } ], - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "Int based extensible enum", "isFixed": false, "isFlags": false, @@ -491,7 +491,7 @@ "decorators": [] } ], - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "Float based extensible enum", "isFixed": false, "isFlags": false, @@ -563,7 +563,7 @@ "decorators": [] } ], - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "float fixed enum", "isFixed": false, "isFlags": false, @@ -635,7 +635,7 @@ "decorators": [] } ], - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "float fixed enum", "isFixed": true, "isFlags": false, @@ -707,7 +707,7 @@ "decorators": [] } ], - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "float fixed enum", "isFixed": true, "isFlags": false, @@ -779,7 +779,7 @@ "decorators": [] } ], - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "doc": "int fixed enum", "isFixed": true, "isFlags": false, @@ -834,7 +834,7 @@ "decorators": [] } ], - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "isFixed": true, "isFlags": false, "usage": "ApiVersionEnum", @@ -846,7 +846,7 @@ "$id": "90", "kind": "model", "name": "Thing", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "crossLanguageDefinitionId": "UnbrandedTypeSpec.Thing", "usage": "Input,Output,Spread,Json", "doc": "A model with a few properties of literal types", @@ -919,7 +919,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "decorators": [] }, "optional": false, @@ -981,7 +981,7 @@ "crossLanguageDefinitionId": "TypeSpec.string", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -1013,7 +1013,7 @@ "crossLanguageDefinitionId": "TypeSpec.string", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": true, "readOnly": false, @@ -1290,7 +1290,7 @@ "crossLanguageDefinitionId": "TypeSpec.Array", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": true, "readOnly": false, @@ -1329,7 +1329,7 @@ "crossLanguageDefinitionId": "TypeSpec.Array", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -1351,7 +1351,7 @@ "$id": "163", "kind": "model", "name": "RoundTripModel", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "crossLanguageDefinitionId": "UnbrandedTypeSpec.RoundTripModel", "usage": "Input,Output,Json", "doc": "this is a roundtrip model", @@ -2001,7 +2001,7 @@ "$id": "254", "kind": "model", "name": "ModelWithRequiredNullableProperties", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "crossLanguageDefinitionId": "UnbrandedTypeSpec.ModelWithRequiredNullableProperties", "usage": "Input,Output,Json", "doc": "A model with a few required nullable properties", @@ -2023,7 +2023,7 @@ "crossLanguageDefinitionId": "TypeSpec.int32", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -2051,7 +2051,7 @@ "type": { "$ref": "28" }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -2079,7 +2079,7 @@ "type": { "$ref": "20" }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -2148,7 +2148,7 @@ "$id": "274", "kind": "model", "name": "Friend", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "crossLanguageDefinitionId": "UnbrandedTypeSpec.NotFriend", "usage": "Output,Spread,Json", "doc": "this is not a friendly model but with a friendly name", @@ -2187,7 +2187,7 @@ "$id": "279", "kind": "model", "name": "ProjectedModel", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "crossLanguageDefinitionId": "UnbrandedTypeSpec.ModelWithProjectedName", "usage": "Output,Spread,Json", "doc": "this is a model with a projected name", @@ -2226,7 +2226,7 @@ "$id": "284", "kind": "model", "name": "ReturnsAnonymousModelResponse", - "clientNamespace": "UnbrandedTypeSpec", + "namespace": "UnbrandedTypeSpec", "crossLanguageDefinitionId": "UnbrandedTypeSpec.returnsAnonymousModel.Response.anonymous", "usage": "Output,Json", "decorators": [], @@ -2237,7 +2237,7 @@ { "$id": "285", "Name": "UnbrandedTypeSpecClient", - "ClientNamespace": "UnbrandedTypeSpec", + "Namespace": "UnbrandedTypeSpec", "Doc": "This is a sample typespec project.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/api-key/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/api-key/tspCodeModel.json index 4c9ab31f491..f337ec13512 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/api-key/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/api-key/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "InvalidAuth", - "clientNamespace": "Authentication.ApiKey", + "namespace": "Authentication.ApiKey", "crossLanguageDefinitionId": "Authentication.ApiKey.InvalidAuth", "usage": "Error,Json,Exception", "decorators": [], @@ -46,7 +46,7 @@ { "$id": "7", "Name": "ApiKeyClient", - "ClientNamespace": "Authentication.ApiKey", + "Namespace": "Authentication.ApiKey", "Doc": "Illustrates clients generated with ApiKey authentication.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/http/custom/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/http/custom/tspCodeModel.json index 1484f57a9c6..ac5f94972bb 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/http/custom/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/http/custom/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "InvalidAuth", - "clientNamespace": "Authentication.Http.Custom", + "namespace": "Authentication.Http.Custom", "crossLanguageDefinitionId": "Authentication.Http.Custom.InvalidAuth", "usage": "Error,Json,Exception", "decorators": [], @@ -46,7 +46,7 @@ { "$id": "7", "Name": "CustomClient", - "ClientNamespace": "Authentication.Http.Custom", + "Namespace": "Authentication.Http.Custom", "Doc": "Illustrates clients generated with generic HTTP auth.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/oauth2/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/oauth2/tspCodeModel.json index 881d4962698..7d64b723168 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/oauth2/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/oauth2/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "InvalidAuth", - "clientNamespace": "Authentication.OAuth2", + "namespace": "Authentication.OAuth2", "crossLanguageDefinitionId": "Authentication.OAuth2.InvalidAuth", "usage": "Error,Json,Exception", "decorators": [], @@ -46,7 +46,7 @@ { "$id": "7", "Name": "OAuth2Client", - "ClientNamespace": "Authentication.OAuth2", + "Namespace": "Authentication.OAuth2", "Doc": "Illustrates clients generated with OAuth2 authentication.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/union/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/union/tspCodeModel.json index 2224a7c8e44..fc7400e00cb 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/union/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/authentication/union/tspCodeModel.json @@ -8,7 +8,7 @@ { "$id": "2", "Name": "UnionClient", - "ClientNamespace": "Authentication.Union", + "Namespace": "Authentication.Union", "Doc": "Illustrates clients generated with ApiKey and OAuth2 authentication.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/client-operation-group/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/client-operation-group/tspCodeModel.json index 190328726a5..4ecaa80d018 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/client-operation-group/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/client-operation-group/tspCodeModel.json @@ -102,7 +102,7 @@ "decorators": [] } ], - "clientNamespace": "Client.Structure.Service", + "namespace": "Client.Structure.Service", "isFixed": true, "isFlags": false, "usage": "Input", @@ -114,7 +114,7 @@ { "$id": "14", "Name": "FirstClient", - "ClientNamespace": "Client.Structure.ClientOperationGroup", + "Namespace": "Client.Structure.ClientOperationGroup", "Operations": [ { "$id": "15", @@ -193,7 +193,7 @@ { "$id": "21", "Name": "Group3", - "ClientNamespace": "Client.Structure.ClientOperationGroup", + "Namespace": "Client.Structure.ClientOperationGroup", "Operations": [ { "$id": "22", @@ -300,7 +300,7 @@ { "$id": "30", "Name": "Group4", - "ClientNamespace": "Client.Structure.ClientOperationGroup", + "Namespace": "Client.Structure.ClientOperationGroup", "Operations": [ { "$id": "31", @@ -380,7 +380,7 @@ { "$id": "37", "Name": "SubNamespace.SecondClient", - "ClientNamespace": "Client.Structure.AnotherClientOperationGroup", + "Namespace": "Client.Structure.AnotherClientOperationGroup", "Operations": [ { "$id": "38", @@ -459,7 +459,7 @@ { "$id": "44", "Name": "Group5", - "ClientNamespace": "Client.Structure.AnotherClientOperationGroup", + "Namespace": "Client.Structure.AnotherClientOperationGroup", "Operations": [ { "$id": "45", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/default/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/default/tspCodeModel.json index e6eebf97c60..c9e25e7d34f 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/default/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/default/tspCodeModel.json @@ -102,7 +102,7 @@ "decorators": [] } ], - "clientNamespace": "Client.Structure.Service", + "namespace": "Client.Structure.Service", "isFixed": true, "isFlags": false, "usage": "Input", @@ -114,7 +114,7 @@ { "$id": "14", "Name": "ServiceClient", - "ClientNamespace": "Client.Structure.Service", + "Namespace": "Client.Structure.Service", "Doc": "Test that we can use @client and @operationGroup decorators to customize client side code structure, such as:\n1. have everything as default.\n2. to rename client or operation group\n3. one client can have more than one operations groups\n4. split one interface into two clients\n5. have two clients with operations come from different interfaces\n6. have two clients with a hierarchy relation.", "Operations": [ { @@ -221,7 +221,7 @@ { "$id": "23", "Name": "Baz", - "ClientNamespace": "Client.Structure.Service.Baz", + "Namespace": "Client.Structure.Service.Baz", "Operations": [], "Protocol": { "$id": "24" @@ -273,7 +273,7 @@ { "$id": "28", "Name": "BazFoo", - "ClientNamespace": "Client.Structure.Service.Baz", + "Namespace": "Client.Structure.Service.Baz", "Operations": [ { "$id": "29", @@ -353,7 +353,7 @@ { "$id": "35", "Name": "Qux", - "ClientNamespace": "Client.Structure.Service.Qux", + "Namespace": "Client.Structure.Service.Qux", "Operations": [ { "$id": "36", @@ -433,7 +433,7 @@ { "$id": "42", "Name": "QuxBar", - "ClientNamespace": "Client.Structure.Service.Qux", + "Namespace": "Client.Structure.Service.Qux", "Operations": [ { "$id": "43", @@ -513,7 +513,7 @@ { "$id": "49", "Name": "Foo", - "ClientNamespace": "Client.Structure.Service", + "Namespace": "Client.Structure.Service", "Operations": [ { "$id": "50", @@ -620,7 +620,7 @@ { "$id": "58", "Name": "Bar", - "ClientNamespace": "Client.Structure.Service", + "Namespace": "Client.Structure.Service", "Operations": [ { "$id": "59", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/multi-client/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/multi-client/tspCodeModel.json index 541a93ae149..5d581072f68 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/multi-client/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/multi-client/tspCodeModel.json @@ -102,7 +102,7 @@ "decorators": [] } ], - "clientNamespace": "Client.Structure.Service", + "namespace": "Client.Structure.Service", "isFixed": true, "isFlags": false, "usage": "Input", @@ -114,7 +114,7 @@ { "$id": "14", "Name": "ClientAClient", - "ClientNamespace": "Client.Structure.MultiClient", + "Namespace": "Client.Structure.MultiClient", "Operations": [ { "$id": "15", @@ -247,7 +247,7 @@ { "$id": "25", "Name": "ClientBClient", - "ClientNamespace": "Client.Structure.MultiClient", + "Namespace": "Client.Structure.MultiClient", "Operations": [ { "$id": "26", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/renamed-operation/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/renamed-operation/tspCodeModel.json index 334ff1a156c..da6493ddae0 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/renamed-operation/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/renamed-operation/tspCodeModel.json @@ -102,7 +102,7 @@ "decorators": [] } ], - "clientNamespace": "Client.Structure.Service", + "namespace": "Client.Structure.Service", "isFixed": true, "isFlags": false, "usage": "Input", @@ -114,7 +114,7 @@ { "$id": "14", "Name": "RenamedOperationClient", - "ClientNamespace": "Client.Structure.RenamedOperation", + "Namespace": "Client.Structure.RenamedOperation", "Operations": [ { "$id": "15", @@ -247,7 +247,7 @@ { "$id": "25", "Name": "Group", - "ClientNamespace": "Client.Structure.RenamedOperation", + "Namespace": "Client.Structure.RenamedOperation", "Operations": [ { "$id": "26", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/two-operation-group/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/two-operation-group/tspCodeModel.json index d86d7888cd1..4e155dae121 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/two-operation-group/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/client/structure/two-operation-group/tspCodeModel.json @@ -102,7 +102,7 @@ "decorators": [] } ], - "clientNamespace": "Client.Structure.Service", + "namespace": "Client.Structure.Service", "isFixed": true, "isFlags": false, "usage": "Input", @@ -114,7 +114,7 @@ { "$id": "14", "Name": "TwoOperationGroupClient", - "ClientNamespace": "Client.Structure.TwoOperationGroup", + "Namespace": "Client.Structure.TwoOperationGroup", "Operations": [], "Protocol": { "$id": "15" @@ -165,7 +165,7 @@ { "$id": "19", "Name": "Group1", - "ClientNamespace": "Client.Structure.TwoOperationGroup", + "Namespace": "Client.Structure.TwoOperationGroup", "Operations": [ { "$id": "20", @@ -299,7 +299,7 @@ { "$id": "30", "Name": "Group2", - "ClientNamespace": "Client.Structure.TwoOperationGroup", + "Namespace": "Client.Structure.TwoOperationGroup", "Operations": [ { "$id": "31", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/bytes/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/bytes/tspCodeModel.json index 7a39503ab8c..45c6408d0a8 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/bytes/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/bytes/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "DefaultBytesProperty", - "clientNamespace": "Encode.Bytes", + "namespace": "Encode.Bytes", "crossLanguageDefinitionId": "Encode.Bytes.DefaultBytesProperty", "usage": "Input,Output,Json", "decorators": [], @@ -46,7 +46,7 @@ "$id": "7", "kind": "model", "name": "Base64BytesProperty", - "clientNamespace": "Encode.Bytes", + "namespace": "Encode.Bytes", "crossLanguageDefinitionId": "Encode.Bytes.Base64BytesProperty", "usage": "Input,Output,Json", "decorators": [], @@ -84,7 +84,7 @@ "$id": "12", "kind": "model", "name": "Base64urlBytesProperty", - "clientNamespace": "Encode.Bytes", + "namespace": "Encode.Bytes", "crossLanguageDefinitionId": "Encode.Bytes.Base64urlBytesProperty", "usage": "Input,Output,Json", "decorators": [], @@ -122,7 +122,7 @@ "$id": "17", "kind": "model", "name": "Base64urlArrayBytesProperty", - "clientNamespace": "Encode.Bytes", + "namespace": "Encode.Bytes", "crossLanguageDefinitionId": "Encode.Bytes.Base64urlArrayBytesProperty", "usage": "Input,Output,Json", "decorators": [], @@ -176,7 +176,7 @@ { "$id": "24", "Name": "BytesClient", - "ClientNamespace": "Encode.Bytes", + "Namespace": "Encode.Bytes", "Doc": "Test for encode decorator on bytes.", "Operations": [], "Protocol": { @@ -220,7 +220,7 @@ { "$id": "30", "Name": "Query", - "ClientNamespace": "Encode.Bytes.Query", + "Namespace": "Encode.Bytes.Query", "Operations": [ { "$id": "31", @@ -481,7 +481,7 @@ { "$id": "54", "Name": "Property", - "ClientNamespace": "Encode.Bytes.Property", + "Namespace": "Encode.Bytes.Property", "Operations": [ { "$id": "55", @@ -962,7 +962,7 @@ { "$id": "96", "Name": "Header", - "ClientNamespace": "Encode.Bytes.Header", + "Namespace": "Encode.Bytes.Header", "Operations": [ { "$id": "97", @@ -1223,7 +1223,7 @@ { "$id": "120", "Name": "RequestBody", - "ClientNamespace": "Encode.Bytes.RequestBody", + "Namespace": "Encode.Bytes.RequestBody", "Operations": [ { "$id": "121", @@ -1669,7 +1669,7 @@ { "$id": "161", "Name": "ResponseBody", - "ClientNamespace": "Encode.Bytes.ResponseBody", + "Namespace": "Encode.Bytes.ResponseBody", "Operations": [ { "$id": "162", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/datetime/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/datetime/tspCodeModel.json index 1f427ed8f08..5b58dc3f324 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/datetime/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/datetime/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "DefaultDatetimeProperty", - "clientNamespace": "Encode.Datetime", + "namespace": "Encode.Datetime", "crossLanguageDefinitionId": "Encode.Datetime.DefaultDatetimeProperty", "usage": "Input,Output,Json", "decorators": [], @@ -53,7 +53,7 @@ "$id": "8", "kind": "model", "name": "Rfc3339DatetimeProperty", - "clientNamespace": "Encode.Datetime", + "namespace": "Encode.Datetime", "crossLanguageDefinitionId": "Encode.Datetime.Rfc3339DatetimeProperty", "usage": "Input,Output,Json", "decorators": [], @@ -98,7 +98,7 @@ "$id": "14", "kind": "model", "name": "Rfc7231DatetimeProperty", - "clientNamespace": "Encode.Datetime", + "namespace": "Encode.Datetime", "crossLanguageDefinitionId": "Encode.Datetime.Rfc7231DatetimeProperty", "usage": "Input,Output,Json", "decorators": [], @@ -143,7 +143,7 @@ "$id": "20", "kind": "model", "name": "UnixTimestampDatetimeProperty", - "clientNamespace": "Encode.Datetime", + "namespace": "Encode.Datetime", "crossLanguageDefinitionId": "Encode.Datetime.UnixTimestampDatetimeProperty", "usage": "Input,Output,Json", "decorators": [], @@ -188,7 +188,7 @@ "$id": "26", "kind": "model", "name": "UnixTimestampArrayDatetimeProperty", - "clientNamespace": "Encode.Datetime", + "namespace": "Encode.Datetime", "crossLanguageDefinitionId": "Encode.Datetime.UnixTimestampArrayDatetimeProperty", "usage": "Input,Output,Json", "decorators": [], @@ -256,7 +256,7 @@ { "$id": "35", "Name": "DatetimeClient", - "ClientNamespace": "Encode.Datetime", + "Namespace": "Encode.Datetime", "Doc": "Test for encode decorator on datetime.", "Operations": [], "Protocol": { @@ -300,7 +300,7 @@ { "$id": "41", "Name": "Query", - "ClientNamespace": "Encode.Datetime.Query", + "Namespace": "Encode.Datetime.Query", "Operations": [ { "$id": "42", @@ -653,7 +653,7 @@ { "$id": "75", "Name": "Property", - "ClientNamespace": "Encode.Datetime.Property", + "Namespace": "Encode.Datetime.Property", "Operations": [ { "$id": "76", @@ -1243,7 +1243,7 @@ { "$id": "126", "Name": "Header", - "ClientNamespace": "Encode.Datetime.Header", + "Namespace": "Encode.Datetime.Header", "Operations": [ { "$id": "127", @@ -1596,7 +1596,7 @@ { "$id": "160", "Name": "ResponseHeader", - "ClientNamespace": "Encode.Datetime.ResponseHeader", + "Namespace": "Encode.Datetime.ResponseHeader", "Operations": [ { "$id": "161", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/duration/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/duration/tspCodeModel.json index a8f107b762d..e7b8a352acc 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/duration/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/duration/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "DefaultDurationProperty", - "clientNamespace": "Encode.Duration.Property", + "namespace": "Encode.Duration.Property", "crossLanguageDefinitionId": "Encode.Duration.Property.DefaultDurationProperty", "usage": "Input,Output,Json", "decorators": [], @@ -53,7 +53,7 @@ "$id": "8", "kind": "model", "name": "ISO8601DurationProperty", - "clientNamespace": "Encode.Duration.Property", + "namespace": "Encode.Duration.Property", "crossLanguageDefinitionId": "Encode.Duration.Property.ISO8601DurationProperty", "usage": "Input,Output,Json", "decorators": [], @@ -98,7 +98,7 @@ "$id": "14", "kind": "model", "name": "Int32SecondsDurationProperty", - "clientNamespace": "Encode.Duration.Property", + "namespace": "Encode.Duration.Property", "crossLanguageDefinitionId": "Encode.Duration.Property.Int32SecondsDurationProperty", "usage": "Input,Output,Json", "decorators": [], @@ -143,7 +143,7 @@ "$id": "20", "kind": "model", "name": "FloatSecondsDurationProperty", - "clientNamespace": "Encode.Duration.Property", + "namespace": "Encode.Duration.Property", "crossLanguageDefinitionId": "Encode.Duration.Property.FloatSecondsDurationProperty", "usage": "Input,Output,Json", "decorators": [], @@ -188,7 +188,7 @@ "$id": "26", "kind": "model", "name": "Float64SecondsDurationProperty", - "clientNamespace": "Encode.Duration.Property", + "namespace": "Encode.Duration.Property", "crossLanguageDefinitionId": "Encode.Duration.Property.Float64SecondsDurationProperty", "usage": "Input,Output,Json", "decorators": [], @@ -233,7 +233,7 @@ "$id": "32", "kind": "model", "name": "FloatSecondsDurationArrayProperty", - "clientNamespace": "Encode.Duration.Property", + "namespace": "Encode.Duration.Property", "crossLanguageDefinitionId": "Encode.Duration.Property.FloatSecondsDurationArrayProperty", "usage": "Input,Output,Json", "decorators": [], @@ -301,7 +301,7 @@ { "$id": "41", "Name": "DurationClient", - "ClientNamespace": "Encode.Duration", + "Namespace": "Encode.Duration", "Doc": "Test for encode decorator on duration.", "Operations": [], "Protocol": { @@ -345,7 +345,7 @@ { "$id": "47", "Name": "Query", - "ClientNamespace": "Encode.Duration.Query", + "Namespace": "Encode.Duration.Query", "Operations": [ { "$id": "48", @@ -755,7 +755,7 @@ { "$id": "86", "Name": "Property", - "ClientNamespace": "Encode.Duration.Property", + "Namespace": "Encode.Duration.Property", "Operations": [ { "$id": "87", @@ -1454,7 +1454,7 @@ { "$id": "146", "Name": "Header", - "ClientNamespace": "Encode.Duration.Header", + "Namespace": "Encode.Duration.Header", "Operations": [ { "$id": "147", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/numeric/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/numeric/tspCodeModel.json index 9fdf021d68b..af1d4079a0c 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/numeric/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/encode/numeric/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "SafeintAsStringProperty", - "clientNamespace": "Encode.Numeric.Property", + "namespace": "Encode.Numeric.Property", "crossLanguageDefinitionId": "Encode.Numeric.Property.SafeintAsStringProperty", "usage": "Input,Output,Json", "decorators": [], @@ -46,7 +46,7 @@ "$id": "7", "kind": "model", "name": "Uint32AsStringProperty", - "clientNamespace": "Encode.Numeric.Property", + "namespace": "Encode.Numeric.Property", "crossLanguageDefinitionId": "Encode.Numeric.Property.Uint32AsStringProperty", "usage": "Input,Output,Json", "decorators": [], @@ -84,7 +84,7 @@ "$id": "12", "kind": "model", "name": "Uint8AsStringProperty", - "clientNamespace": "Encode.Numeric.Property", + "namespace": "Encode.Numeric.Property", "crossLanguageDefinitionId": "Encode.Numeric.Property.Uint8AsStringProperty", "usage": "Input,Output,Json", "decorators": [], @@ -123,7 +123,7 @@ { "$id": "17", "Name": "NumericClient", - "ClientNamespace": "Encode.Numeric", + "Namespace": "Encode.Numeric", "Doc": "Test for encode decorator on integer.", "Operations": [], "Protocol": { @@ -167,7 +167,7 @@ { "$id": "23", "Name": "Property", - "ClientNamespace": "Encode.Numeric.Property", + "Namespace": "Encode.Numeric.Property", "Operations": [ { "$id": "24", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/basic/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/basic/tspCodeModel.json index 8f458de3c3a..0ed5a944229 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/basic/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/basic/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "SimpleRequest", - "clientNamespace": "Parameters.Basic.ImplicitBody", + "namespace": "Parameters.Basic.ImplicitBody", "crossLanguageDefinitionId": "Parameters.Basic.ImplicitBody.simple.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -45,7 +45,7 @@ "$id": "7", "kind": "model", "name": "User", - "clientNamespace": "Parameters.Basic.ExplicitBody", + "namespace": "Parameters.Basic.ExplicitBody", "crossLanguageDefinitionId": "Parameters.Basic.ExplicitBody.User", "usage": "Input,Json", "doc": "This is a simple model.", @@ -84,7 +84,7 @@ { "$id": "12", "Name": "BasicClient", - "ClientNamespace": "Parameters.Basic", + "Namespace": "Parameters.Basic", "Doc": "Test for basic parameters cases.", "Operations": [], "Protocol": { @@ -128,7 +128,7 @@ { "$id": "18", "Name": "ExplicitBody", - "ClientNamespace": "Parameters.Basic.ExplicitBody", + "Namespace": "Parameters.Basic.ExplicitBody", "Operations": [ { "$id": "19", @@ -249,7 +249,7 @@ { "$id": "30", "Name": "ImplicitBody", - "ClientNamespace": "Parameters.Basic.ImplicitBody", + "Namespace": "Parameters.Basic.ImplicitBody", "Operations": [ { "$id": "31", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/body-optionality/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/body-optionality/tspCodeModel.json index 443445ef44a..7a8db04da40 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/body-optionality/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/body-optionality/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "BodyModel", - "clientNamespace": "Parameters.BodyOptionality", + "namespace": "Parameters.BodyOptionality", "crossLanguageDefinitionId": "Parameters.BodyOptionality.BodyModel", "usage": "Input,Spread,Json", "decorators": [], @@ -46,7 +46,7 @@ { "$id": "7", "Name": "BodyOptionalityClient", - "ClientNamespace": "Parameters.BodyOptionality", + "Namespace": "Parameters.BodyOptionality", "Doc": "Test describing optionality of the request body.", "Operations": [ { @@ -243,7 +243,7 @@ { "$id": "25", "Name": "OptionalExplicit", - "ClientNamespace": "Parameters.BodyOptionality.OptionalExplicit", + "Namespace": "Parameters.BodyOptionality.OptionalExplicit", "Operations": [ { "$id": "26", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/collection-format/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/collection-format/tspCodeModel.json index de26ade64ce..79a30c05c55 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/collection-format/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/collection-format/tspCodeModel.json @@ -8,7 +8,7 @@ { "$id": "2", "Name": "CollectionFormatClient", - "ClientNamespace": "Parameters.CollectionFormat", + "Namespace": "Parameters.CollectionFormat", "Doc": "Test for collectionFormat.", "Operations": [], "Protocol": { @@ -52,7 +52,7 @@ { "$id": "8", "Name": "Query", - "ClientNamespace": "Parameters.CollectionFormat.Query", + "Namespace": "Parameters.CollectionFormat.Query", "Operations": [ { "$id": "9", @@ -386,7 +386,7 @@ { "$id": "39", "Name": "Header", - "ClientNamespace": "Parameters.CollectionFormat.Header", + "Namespace": "Parameters.CollectionFormat.Header", "Operations": [ { "$id": "40", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/spread/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/spread/tspCodeModel.json index e998cc3d6ba..9936aa85649 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/spread/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/parameters/spread/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "SpreadAsRequestBodyRequest", - "clientNamespace": "Parameters.Spread.Alias", + "namespace": "Parameters.Spread.Alias", "crossLanguageDefinitionId": "Parameters.Spread.Alias.spreadAsRequestBody.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -45,7 +45,7 @@ "$id": "7", "kind": "model", "name": "SpreadParameterWithInnerModelRequest", - "clientNamespace": "", + "namespace": "", "crossLanguageDefinitionId": "Parameters.Spread.Alias.spreadParameterWithInnerModel.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -82,7 +82,7 @@ "$id": "12", "kind": "model", "name": "SpreadAsRequestParameterRequest", - "clientNamespace": "", + "namespace": "", "crossLanguageDefinitionId": "Parameters.Spread.Alias.spreadAsRequestParameter.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -119,7 +119,7 @@ "$id": "17", "kind": "model", "name": "SpreadWithMultipleParametersRequest", - "clientNamespace": "", + "namespace": "", "crossLanguageDefinitionId": "Parameters.Spread.Alias.spreadWithMultipleParameters.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -252,7 +252,7 @@ "$id": "36", "kind": "model", "name": "SpreadParameterWithInnerAliasRequest", - "clientNamespace": "", + "namespace": "", "crossLanguageDefinitionId": "Parameters.Spread.Alias.spreadParameterWithInnerAlias.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -317,7 +317,7 @@ "$id": "45", "kind": "model", "name": "BodyParameter", - "clientNamespace": "Parameters.Spread.Model", + "namespace": "Parameters.Spread.Model", "crossLanguageDefinitionId": "Parameters.Spread.Model.BodyParameter", "usage": "Input,Spread,Json", "doc": "This is a simple model.", @@ -355,7 +355,7 @@ "$id": "50", "kind": "model", "name": "SpreadCompositeRequestMixRequest", - "clientNamespace": "", + "namespace": "", "crossLanguageDefinitionId": "Parameters.Spread.Model.spreadCompositeRequestMix.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -393,7 +393,7 @@ { "$id": "55", "Name": "SpreadClient", - "ClientNamespace": "Parameters.Spread", + "Namespace": "Parameters.Spread", "Doc": "Test for the spread operator.", "Operations": [], "Protocol": { @@ -437,7 +437,7 @@ { "$id": "61", "Name": "Model", - "ClientNamespace": "Parameters.Spread.Model", + "Namespace": "Parameters.Spread.Model", "Operations": [ { "$id": "62", @@ -940,7 +940,7 @@ { "$id": "105", "Name": "Alias", - "ClientNamespace": "Parameters.Spread.Alias", + "Namespace": "Parameters.Spread.Alias", "Operations": [ { "$id": "106", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/content-negotiation/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/content-negotiation/tspCodeModel.json index eac17f5a96c..b10f56934f3 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/content-negotiation/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/content-negotiation/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "PngImageAsJson", - "clientNamespace": "Payload.ContentNegotiation.DifferentBody", + "namespace": "Payload.ContentNegotiation.DifferentBody", "crossLanguageDefinitionId": "Payload.ContentNegotiation.DifferentBody.PngImageAsJson", "usage": "Output,Json", "decorators": [], @@ -47,7 +47,7 @@ { "$id": "7", "Name": "ContentNegotiationClient", - "ClientNamespace": "Payload.ContentNegotiation", + "Namespace": "Payload.ContentNegotiation", "Doc": "Test describing optionality of the request body.", "Operations": [], "Protocol": { @@ -91,7 +91,7 @@ { "$id": "13", "Name": "SameBody", - "ClientNamespace": "Payload.ContentNegotiation.SameBody", + "Namespace": "Payload.ContentNegotiation.SameBody", "Operations": [ { "$id": "14", @@ -304,7 +304,7 @@ { "$id": "37", "Name": "DifferentBody", - "ClientNamespace": "Payload.ContentNegotiation.DifferentBody", + "Namespace": "Payload.ContentNegotiation.DifferentBody", "Operations": [ { "$id": "38", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/json-merge-patch/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/json-merge-patch/tspCodeModel.json index 37711265d5d..27b47ea1443 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/json-merge-patch/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/json-merge-patch/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "Resource", - "clientNamespace": "Payload.JsonMergePatch", + "namespace": "Payload.JsonMergePatch", "crossLanguageDefinitionId": "Payload.JsonMergePatch.Resource", "usage": "Input,Output,Json", "doc": "Details about a resource.", @@ -85,7 +85,7 @@ "$id": "14", "kind": "model", "name": "InnerModel", - "clientNamespace": "Payload.JsonMergePatch", + "namespace": "Payload.JsonMergePatch", "crossLanguageDefinitionId": "Payload.JsonMergePatch.InnerModel", "usage": "Input,Output,JsonMergePatch,Json", "doc": "It is the model used by Resource model", @@ -306,7 +306,7 @@ "$id": "45", "kind": "model", "name": "ResourcePatch", - "clientNamespace": "Payload.JsonMergePatch", + "namespace": "Payload.JsonMergePatch", "crossLanguageDefinitionId": "Payload.JsonMergePatch.ResourcePatch", "usage": "Input,JsonMergePatch,Json", "doc": "Details about a resource for patch operation.", @@ -515,7 +515,7 @@ { "$id": "75", "Name": "JsonMergePatchClient", - "ClientNamespace": "Payload.JsonMergePatch", + "Namespace": "Payload.JsonMergePatch", "Doc": "Test for merge-patch+json content-type", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/media-type/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/media-type/tspCodeModel.json index eebf0b00c70..a315a5ad8d2 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/media-type/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/media-type/tspCodeModel.json @@ -8,7 +8,7 @@ { "$id": "2", "Name": "MediaTypeClient", - "ClientNamespace": "Payload.MediaType", + "Namespace": "Payload.MediaType", "Doc": "Test the payload with different media types and different types of the payload itself.", "Operations": [], "Protocol": { @@ -52,7 +52,7 @@ { "$id": "8", "Name": "StringBody", - "ClientNamespace": "Payload.MediaType.StringBody", + "Namespace": "Payload.MediaType.StringBody", "Operations": [ { "$id": "9", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/multipart/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/multipart/tspCodeModel.json index 2143bc052e8..d809b86fe73 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/multipart/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/payload/multipart/tspCodeModel.json @@ -30,7 +30,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "doc": "The FileSpecificContentType_contentType", "isFixed": false, "isFlags": false, @@ -43,7 +43,7 @@ "$id": "5", "kind": "model", "name": "MultiPartRequest", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.MultiPartRequest", "usage": "Input,MultipartFormData", "decorators": [], @@ -113,7 +113,7 @@ "$id": "14", "kind": "model", "name": "ComplexPartsRequest", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.ComplexPartsRequest", "usage": "Input,MultipartFormData", "decorators": [], @@ -156,7 +156,7 @@ "$id": "20", "kind": "model", "name": "Address", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.Address", "usage": "Input", "decorators": [], @@ -282,7 +282,7 @@ "$id": "36", "kind": "model", "name": "JsonPartRequest", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.JsonPartRequest", "usage": "Input,MultipartFormData", "decorators": [], @@ -348,7 +348,7 @@ "$id": "44", "kind": "model", "name": "BinaryArrayPartsRequest", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.BinaryArrayPartsRequest", "usage": "Input,MultipartFormData", "decorators": [], @@ -425,7 +425,7 @@ "$id": "54", "kind": "model", "name": "MultiBinaryPartsRequest", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.MultiBinaryPartsRequest", "usage": "Input,MultipartFormData", "decorators": [], @@ -496,7 +496,7 @@ "$id": "63", "kind": "model", "name": "AnonymousModelRequest", - "clientNamespace": "", + "namespace": "", "crossLanguageDefinitionId": "Payload.MultiPart.FormData.anonymousModel.Request.anonymous", "usage": "MultipartFormData,Spread", "decorators": [], @@ -537,7 +537,7 @@ "$id": "68", "kind": "model", "name": "ComplexHttpPartsModelRequest", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.ComplexHttpPartsModelRequest", "usage": "Input,MultipartFormData", "decorators": [], @@ -609,7 +609,7 @@ "$id": "77", "kind": "model", "name": "FileRequiredMetaData", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.FileRequiredMetaData", "usage": "Input", "decorators": [], @@ -617,7 +617,7 @@ "$id": "78", "kind": "model", "name": "File", - "clientNamespace": "TypeSpec.Http", + "namespace": "TypeSpec.Http", "crossLanguageDefinitionId": "TypeSpec.Http.File", "usage": "Input", "decorators": [], @@ -911,7 +911,7 @@ "$id": "4774", "kind": "model", "name": "FloatRequest", - "clientNamespace": "Payload.MultiPart.FormData.HttpParts.NonString", + "namespace": "Payload.MultiPart.FormData.HttpParts.NonString", "crossLanguageDefinitionId": "Payload.MultiPart.FormData.HttpParts.NonString.float.Request.anonymous", "usage": "Input,MultipartFormData", "decorators": [], @@ -990,7 +990,7 @@ "$id": "5613", "kind": "model", "name": "FloatRequestTemperature", - "clientNamespace": "Payload.MultiPart.FormData.HttpParts.NonString", + "namespace": "Payload.MultiPart.FormData.HttpParts.NonString", "crossLanguageDefinitionId": "Payload.MultiPart.FormData.HttpParts.NonString.float.Request.temperature.anonymous", "usage": "Input", "decorators": [], @@ -1000,7 +1000,7 @@ "$id": "5614", "kind": "model", "name": "FileWithHttpPartSpecificContentTypeRequest", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.FileWithHttpPartSpecificContentTypeRequest", "usage": "Input,MultipartFormData", "decorators": [], @@ -1014,7 +1014,7 @@ "$id": "5616", "kind": "model", "name": "FileSpecificContentType", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.FileSpecificContentType", "usage": "Input", "decorators": [], @@ -1174,7 +1174,7 @@ "$id": "5633", "kind": "model", "name": "FileWithHttpPartRequiredContentTypeRequest", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.FileWithHttpPartRequiredContentTypeRequest", "usage": "Input,MultipartFormData", "decorators": [], @@ -1218,7 +1218,7 @@ "$id": "5637", "kind": "model", "name": "FileWithHttpPartOptionalContentTypeRequest", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.FileWithHttpPartOptionalContentTypeRequest", "usage": "Input,MultipartFormData", "decorators": [], @@ -1232,7 +1232,7 @@ "$id": "5639", "kind": "model", "name": "FileOptionalContentType", - "clientNamespace": "Payload.MultiPart", + "namespace": "Payload.MultiPart", "crossLanguageDefinitionId": "Payload.MultiPart.FileOptionalContentType", "usage": "Input", "decorators": [], @@ -1361,7 +1361,7 @@ { "$id": "5651", "Name": "MultiPartClient", - "ClientNamespace": "Payload.MultiPart", + "Namespace": "Payload.MultiPart", "Doc": "Test for multipart", "Operations": [], "Protocol": { @@ -1405,7 +1405,7 @@ { "$id": "5657", "Name": "FormData", - "ClientNamespace": "Payload.MultiPart.FormData", + "Namespace": "Payload.MultiPart.FormData", "Operations": [ { "$id": "5658", @@ -1982,7 +1982,7 @@ { "$id": "5705", "Name": "FormDataHttpParts", - "ClientNamespace": "Payload.MultiPart.FormData.HttpParts", + "Namespace": "Payload.MultiPart.FormData.HttpParts", "Operations": [ { "$id": "5706", @@ -2103,7 +2103,7 @@ { "$id": "5717", "Name": "FormDataHttpPartsContentType", - "ClientNamespace": "Payload.MultiPart.FormData.HttpParts.ContentType", + "Namespace": "Payload.MultiPart.FormData.HttpParts.ContentType", "Operations": [ { "$id": "5718", @@ -2376,7 +2376,7 @@ { "$id": "5741", "Name": "FormDataHttpPartsNonString", - "ClientNamespace": "Payload.MultiPart.FormData.HttpParts.NonString", + "Namespace": "Payload.MultiPart.FormData.HttpParts.NonString", "Operations": [ { "$id": "5742", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/resiliency/srv-driven/v1/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/resiliency/srv-driven/v1/tspCodeModel.json index f00b793aa42..25292fa83bd 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/resiliency/srv-driven/v1/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/resiliency/srv-driven/v1/tspCodeModel.json @@ -37,7 +37,7 @@ "decorators": [] } ], - "clientNamespace": "Resiliency.ServiceDriven", + "namespace": "Resiliency.ServiceDriven", "doc": "Service versions.", "isFixed": true, "isFlags": false, @@ -50,7 +50,7 @@ { "$id": "6", "Name": "ResiliencyServiceDrivenClient", - "ClientNamespace": "Resiliency.ServiceDriven", + "Namespace": "Resiliency.ServiceDriven", "Doc": "Test that we can grow up a service spec and service deployment into a multi-versioned service with full client support.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/resiliency/srv-driven/v2/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/resiliency/srv-driven/v2/tspCodeModel.json index f1952125402..25ca91bfc6c 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/resiliency/srv-driven/v2/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/resiliency/srv-driven/v2/tspCodeModel.json @@ -56,7 +56,7 @@ "decorators": [] } ], - "clientNamespace": "Resiliency.ServiceDriven", + "namespace": "Resiliency.ServiceDriven", "doc": "Service versions", "isFixed": true, "isFlags": false, @@ -69,7 +69,7 @@ { "$id": "8", "Name": "ResiliencyServiceDrivenClient", - "ClientNamespace": "Resiliency.ServiceDriven", + "Namespace": "Resiliency.ServiceDriven", "Doc": "Test that we can grow up a service spec and service deployment into a multi-versioned service with full client support.\n\nThere are three concepts that should be clarified:\n1. Client spec version: refers to the spec that the client is generated from. 'v1' is a client generated from old.tsp and 'v2' is a client generated from main.tsp.\n2. Service deployment version: refers to a deployment version of the service. 'v1' represents the initial deployment of the service with a single api version. 'v2' represents the new deployment of a service with multiple api versions\n3. Api version: The initial deployment of the service only supports api version 'v1'. The new deployment of the service supports api versions 'v1' and 'v2'.\n\nWe test the following configurations from this service spec:\n- A client generated from the second service spec can call the second deployment of a service with api version v1\n- A client generated from the second service spec can call the second deployment of a service with api version v2", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/response/status-code-range/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/response/status-code-range/tspCodeModel.json index bf7f83289d3..fb283a7dda4 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/response/status-code-range/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/response/status-code-range/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "ErrorInRange", - "clientNamespace": "Response.StatusCodeRange", + "namespace": "Response.StatusCodeRange", "crossLanguageDefinitionId": "Response.StatusCodeRange.ErrorInRange", "usage": "Error,Json,Exception", "decorators": [], @@ -71,7 +71,7 @@ "$id": "11", "kind": "model", "name": "DefaultError", - "clientNamespace": "Response.StatusCodeRange", + "namespace": "Response.StatusCodeRange", "crossLanguageDefinitionId": "Response.StatusCodeRange.DefaultError", "usage": "Error,Json,Exception", "decorators": [], @@ -108,7 +108,7 @@ "$id": "16", "kind": "model", "name": "NotFoundError", - "clientNamespace": "Response.StatusCodeRange", + "namespace": "Response.StatusCodeRange", "crossLanguageDefinitionId": "Response.StatusCodeRange.NotFoundError", "usage": "Error,Json,Exception", "decorators": [], @@ -171,7 +171,7 @@ "$id": "25", "kind": "model", "name": "Standard4XXError", - "clientNamespace": "Response.StatusCodeRange", + "namespace": "Response.StatusCodeRange", "crossLanguageDefinitionId": "Response.StatusCodeRange.Standard4XXError", "usage": "Error,Json,Exception", "decorators": [], @@ -209,7 +209,7 @@ { "$id": "30", "Name": "StatusCodeRangeClient", - "ClientNamespace": "Response.StatusCodeRange", + "Namespace": "Response.StatusCodeRange", "Doc": "Test for range of status code.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/routes/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/routes/tspCodeModel.json index 8917c780591..7d826b53116 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/routes/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/routes/tspCodeModel.json @@ -8,7 +8,7 @@ { "$id": "2", "Name": "RoutesClient", - "ClientNamespace": "Routes", + "Namespace": "Routes", "Doc": "Define scenario in building the http route/uri", "Operations": [ { @@ -80,7 +80,7 @@ { "$id": "10", "Name": "PathParameters", - "ClientNamespace": "Routes.PathParameters", + "Namespace": "Routes.PathParameters", "Operations": [ { "$id": "11", @@ -272,7 +272,7 @@ { "$id": "28", "Name": "PathParametersReservedExpansion", - "ClientNamespace": "Routes.PathParameters.ReservedExpansion", + "Namespace": "Routes.PathParameters.ReservedExpansion", "Operations": [ { "$id": "29", @@ -415,7 +415,7 @@ { "$id": "42", "Name": "PathParametersSimpleExpansion", - "ClientNamespace": "Routes.PathParameters.SimpleExpansion", + "Namespace": "Routes.PathParameters.SimpleExpansion", "Operations": [], "Protocol": { "$id": "43" @@ -459,7 +459,7 @@ { "$id": "48", "Name": "PathParametersSimpleExpansionStandard", - "ClientNamespace": "Routes.PathParameters.SimpleExpansion.Standard", + "Namespace": "Routes.PathParameters.SimpleExpansion.Standard", "Operations": [ { "$id": "49", @@ -670,7 +670,7 @@ { "$id": "69", "Name": "PathParametersSimpleExpansionExplode", - "ClientNamespace": "Routes.PathParameters.SimpleExpansion.Explode", + "Namespace": "Routes.PathParameters.SimpleExpansion.Explode", "Operations": [ { "$id": "70", @@ -881,7 +881,7 @@ { "$id": "90", "Name": "PathParametersPathExpansion", - "ClientNamespace": "Routes.PathParameters.PathExpansion", + "Namespace": "Routes.PathParameters.PathExpansion", "Operations": [], "Protocol": { "$id": "91" @@ -925,7 +925,7 @@ { "$id": "96", "Name": "PathParametersPathExpansionStandard", - "ClientNamespace": "Routes.PathParameters.PathExpansion.Standard", + "Namespace": "Routes.PathParameters.PathExpansion.Standard", "Operations": [ { "$id": "97", @@ -1136,7 +1136,7 @@ { "$id": "117", "Name": "PathParametersPathExpansionExplode", - "ClientNamespace": "Routes.PathParameters.PathExpansion.Explode", + "Namespace": "Routes.PathParameters.PathExpansion.Explode", "Operations": [ { "$id": "118", @@ -1347,7 +1347,7 @@ { "$id": "138", "Name": "PathParametersLabelExpansion", - "ClientNamespace": "Routes.PathParameters.LabelExpansion", + "Namespace": "Routes.PathParameters.LabelExpansion", "Operations": [], "Protocol": { "$id": "139" @@ -1391,7 +1391,7 @@ { "$id": "144", "Name": "PathParametersLabelExpansionStandard", - "ClientNamespace": "Routes.PathParameters.LabelExpansion.Standard", + "Namespace": "Routes.PathParameters.LabelExpansion.Standard", "Operations": [ { "$id": "145", @@ -1602,7 +1602,7 @@ { "$id": "165", "Name": "PathParametersLabelExpansionExplode", - "ClientNamespace": "Routes.PathParameters.LabelExpansion.Explode", + "Namespace": "Routes.PathParameters.LabelExpansion.Explode", "Operations": [ { "$id": "166", @@ -1813,7 +1813,7 @@ { "$id": "186", "Name": "PathParametersMatrixExpansion", - "ClientNamespace": "Routes.PathParameters.MatrixExpansion", + "Namespace": "Routes.PathParameters.MatrixExpansion", "Operations": [], "Protocol": { "$id": "187" @@ -1857,7 +1857,7 @@ { "$id": "192", "Name": "PathParametersMatrixExpansionStandard", - "ClientNamespace": "Routes.PathParameters.MatrixExpansion.Standard", + "Namespace": "Routes.PathParameters.MatrixExpansion.Standard", "Operations": [ { "$id": "193", @@ -2068,7 +2068,7 @@ { "$id": "213", "Name": "PathParametersMatrixExpansionExplode", - "ClientNamespace": "Routes.PathParameters.MatrixExpansion.Explode", + "Namespace": "Routes.PathParameters.MatrixExpansion.Explode", "Operations": [ { "$id": "214", @@ -2279,7 +2279,7 @@ { "$id": "234", "Name": "QueryParameters", - "ClientNamespace": "Routes.QueryParameters", + "Namespace": "Routes.QueryParameters", "Operations": [ { "$id": "235", @@ -2471,7 +2471,7 @@ { "$id": "252", "Name": "QueryParametersQueryExpansion", - "ClientNamespace": "Routes.QueryParameters.QueryExpansion", + "Namespace": "Routes.QueryParameters.QueryExpansion", "Operations": [], "Protocol": { "$id": "253" @@ -2515,7 +2515,7 @@ { "$id": "258", "Name": "QueryParametersQueryExpansionStandard", - "ClientNamespace": "Routes.QueryParameters.QueryExpansion.Standard", + "Namespace": "Routes.QueryParameters.QueryExpansion.Standard", "Operations": [ { "$id": "259", @@ -2726,7 +2726,7 @@ { "$id": "279", "Name": "QueryParametersQueryExpansionExplode", - "ClientNamespace": "Routes.QueryParameters.QueryExpansion.Explode", + "Namespace": "Routes.QueryParameters.QueryExpansion.Explode", "Operations": [ { "$id": "280", @@ -2937,7 +2937,7 @@ { "$id": "300", "Name": "QueryParametersQueryContinuation", - "ClientNamespace": "Routes.QueryParameters.QueryContinuation", + "Namespace": "Routes.QueryParameters.QueryContinuation", "Operations": [], "Protocol": { "$id": "301" @@ -2981,7 +2981,7 @@ { "$id": "306", "Name": "QueryParametersQueryContinuationStandard", - "ClientNamespace": "Routes.QueryParameters.QueryContinuation.Standard", + "Namespace": "Routes.QueryParameters.QueryContinuation.Standard", "Operations": [ { "$id": "307", @@ -3192,7 +3192,7 @@ { "$id": "327", "Name": "QueryParametersQueryContinuationExplode", - "ClientNamespace": "Routes.QueryParameters.QueryContinuation.Explode", + "Namespace": "Routes.QueryParameters.QueryContinuation.Explode", "Operations": [ { "$id": "328", @@ -3403,7 +3403,7 @@ { "$id": "348", "Name": "InInterface", - "ClientNamespace": "Routes", + "Namespace": "Routes", "Operations": [ { "$id": "349", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/serialization/encoded-name/json/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/serialization/encoded-name/json/tspCodeModel.json index 65edf182022..75127108e3a 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/serialization/encoded-name/json/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/serialization/encoded-name/json/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "JsonEncodedNameModel", - "clientNamespace": "Serialization.EncodedName.Json.Property", + "namespace": "Serialization.EncodedName.Json.Property", "crossLanguageDefinitionId": "Serialization.EncodedName.Json.Property.JsonEncodedNameModel", "usage": "Input,Output,Json", "decorators": [], @@ -47,7 +47,7 @@ { "$id": "7", "Name": "JsonClient", - "ClientNamespace": "Serialization.EncodedName.Json", + "Namespace": "Serialization.EncodedName.Json", "Doc": "Projection", "Operations": [], "Protocol": { @@ -91,7 +91,7 @@ { "$id": "13", "Name": "Property", - "ClientNamespace": "Serialization.EncodedName.Json.Property", + "Namespace": "Serialization.EncodedName.Json.Property", "Operations": [ { "$id": "14", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/server/endpoint/not-defined/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/server/endpoint/not-defined/tspCodeModel.json index b709fe40a0a..3ac3affdd3a 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/server/endpoint/not-defined/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/server/endpoint/not-defined/tspCodeModel.json @@ -8,7 +8,7 @@ { "$id": "2", "Name": "NotDefinedClient", - "ClientNamespace": "Server.Endpoint.NotDefined", + "Namespace": "Server.Endpoint.NotDefined", "Doc": "Illustrates server doesn't define endpoint. Client should automatically add an endpoint to let user pass in.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/server/path/multiple/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/server/path/multiple/tspCodeModel.json index eddef96690e..4cbe2f23da0 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/server/path/multiple/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/server/path/multiple/tspCodeModel.json @@ -37,7 +37,7 @@ "decorators": [] } ], - "clientNamespace": "Server.Path.Multiple", + "namespace": "Server.Path.Multiple", "doc": "Service versions", "isFixed": true, "isFlags": false, @@ -50,7 +50,7 @@ { "$id": "6", "Name": "MultipleClient", - "ClientNamespace": "Server.Path.Multiple", + "Namespace": "Server.Path.Multiple", "Operations": [ { "$id": "7", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/server/path/single/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/server/path/single/tspCodeModel.json index 502196f3ff6..46dfe0c2055 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/server/path/single/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/server/path/single/tspCodeModel.json @@ -8,7 +8,7 @@ { "$id": "2", "Name": "SingleClient", - "ClientNamespace": "Server.Path.Single", + "Namespace": "Server.Path.Single", "Doc": "Illustrates server with a single path parameter @server", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/server/versions/not-versioned/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/server/versions/not-versioned/tspCodeModel.json index 0d095ffaf47..bc27e473432 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/server/versions/not-versioned/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/server/versions/not-versioned/tspCodeModel.json @@ -8,7 +8,7 @@ { "$id": "2", "Name": "NotVersionedClient", - "ClientNamespace": "Server.Versions.NotVersioned", + "Namespace": "Server.Versions.NotVersioned", "Doc": "Illustrates not-versioned server.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/server/versions/versioned/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/server/versions/versioned/tspCodeModel.json index b0052fc0971..26151faf46a 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/server/versions/versioned/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/server/versions/versioned/tspCodeModel.json @@ -56,7 +56,7 @@ "decorators": [] } ], - "clientNamespace": "Server.Versions.Versioned", + "namespace": "Server.Versions.Versioned", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -69,7 +69,7 @@ { "$id": "8", "Name": "VersionedClient", - "ClientNamespace": "Server.Versions.Versioned", + "Namespace": "Server.Versions.Versioned", "Doc": "Illustrates versioned server.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/special-headers/conditional-request/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/special-headers/conditional-request/tspCodeModel.json index 37200b3689f..33cba75dee3 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/special-headers/conditional-request/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/special-headers/conditional-request/tspCodeModel.json @@ -8,7 +8,7 @@ { "$id": "2", "Name": "ConditionalRequestClient", - "ClientNamespace": "SpecialHeaders.ConditionalRequest", + "Namespace": "SpecialHeaders.ConditionalRequest", "Doc": "Illustrates conditional request headers", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/special-headers/repeatability/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/special-headers/repeatability/tspCodeModel.json index 56201c6018e..e440cc4a6e3 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/special-headers/repeatability/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/special-headers/repeatability/tspCodeModel.json @@ -51,7 +51,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Output", @@ -63,7 +63,7 @@ { "$id": "8", "Name": "RepeatabilityClient", - "ClientNamespace": "SpecialHeaders.Repeatability", + "Namespace": "SpecialHeaders.Repeatability", "Doc": "Illustrates OASIS repeatability headers", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/special-words/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/special-words/tspCodeModel.json index d2165fc702f..e3df892fac8 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/special-words/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/special-words/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "SameAsModel", - "clientNamespace": "SpecialWords.ModelProperties", + "namespace": "SpecialWords.ModelProperties", "crossLanguageDefinitionId": "SpecialWords.ModelProperties.SameAsModel", "usage": "Input,Json", "decorators": [], @@ -45,7 +45,7 @@ "$id": "7", "kind": "model", "name": "and", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.and", "usage": "Input,Json", "decorators": [], @@ -82,7 +82,7 @@ "$id": "12", "kind": "model", "name": "as", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.as", "usage": "Input,Json", "decorators": [], @@ -119,7 +119,7 @@ "$id": "17", "kind": "model", "name": "assert", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.assert", "usage": "Input,Json", "decorators": [], @@ -156,7 +156,7 @@ "$id": "22", "kind": "model", "name": "async", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.async", "usage": "Input,Json", "decorators": [], @@ -193,7 +193,7 @@ "$id": "27", "kind": "model", "name": "await", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.await", "usage": "Input,Json", "decorators": [], @@ -230,7 +230,7 @@ "$id": "32", "kind": "model", "name": "break", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.break", "usage": "Input,Json", "decorators": [], @@ -267,7 +267,7 @@ "$id": "37", "kind": "model", "name": "class", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.class", "usage": "Input,Json", "decorators": [], @@ -304,7 +304,7 @@ "$id": "42", "kind": "model", "name": "constructor", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.constructor", "usage": "Input,Json", "decorators": [], @@ -341,7 +341,7 @@ "$id": "47", "kind": "model", "name": "continue", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.continue", "usage": "Input,Json", "decorators": [], @@ -378,7 +378,7 @@ "$id": "52", "kind": "model", "name": "def", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.def", "usage": "Input,Json", "decorators": [], @@ -415,7 +415,7 @@ "$id": "57", "kind": "model", "name": "del", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.del", "usage": "Input,Json", "decorators": [], @@ -452,7 +452,7 @@ "$id": "62", "kind": "model", "name": "elif", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.elif", "usage": "Input,Json", "decorators": [], @@ -489,7 +489,7 @@ "$id": "67", "kind": "model", "name": "else", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.else", "usage": "Input,Json", "decorators": [], @@ -526,7 +526,7 @@ "$id": "72", "kind": "model", "name": "except", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.except", "usage": "Input,Json", "decorators": [], @@ -563,7 +563,7 @@ "$id": "77", "kind": "model", "name": "exec", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.exec", "usage": "Input,Json", "decorators": [], @@ -600,7 +600,7 @@ "$id": "82", "kind": "model", "name": "finally", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.finally", "usage": "Input,Json", "decorators": [], @@ -637,7 +637,7 @@ "$id": "87", "kind": "model", "name": "for", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.for", "usage": "Input,Json", "decorators": [], @@ -674,7 +674,7 @@ "$id": "92", "kind": "model", "name": "from", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.from", "usage": "Input,Json", "decorators": [], @@ -711,7 +711,7 @@ "$id": "97", "kind": "model", "name": "global", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.global", "usage": "Input,Json", "decorators": [], @@ -748,7 +748,7 @@ "$id": "102", "kind": "model", "name": "if", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.if", "usage": "Input,Json", "decorators": [], @@ -785,7 +785,7 @@ "$id": "107", "kind": "model", "name": "import", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.import", "usage": "Input,Json", "decorators": [], @@ -822,7 +822,7 @@ "$id": "112", "kind": "model", "name": "in", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.in", "usage": "Input,Json", "decorators": [], @@ -859,7 +859,7 @@ "$id": "117", "kind": "model", "name": "is", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.is", "usage": "Input,Json", "decorators": [], @@ -896,7 +896,7 @@ "$id": "122", "kind": "model", "name": "lambda", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.lambda", "usage": "Input,Json", "decorators": [], @@ -933,7 +933,7 @@ "$id": "127", "kind": "model", "name": "not", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.not", "usage": "Input,Json", "decorators": [], @@ -970,7 +970,7 @@ "$id": "132", "kind": "model", "name": "or", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.or", "usage": "Input,Json", "decorators": [], @@ -1007,7 +1007,7 @@ "$id": "137", "kind": "model", "name": "pass", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.pass", "usage": "Input,Json", "decorators": [], @@ -1044,7 +1044,7 @@ "$id": "142", "kind": "model", "name": "raise", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.raise", "usage": "Input,Json", "decorators": [], @@ -1081,7 +1081,7 @@ "$id": "147", "kind": "model", "name": "return", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.return", "usage": "Input,Json", "decorators": [], @@ -1118,7 +1118,7 @@ "$id": "152", "kind": "model", "name": "try", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.try", "usage": "Input,Json", "decorators": [], @@ -1155,7 +1155,7 @@ "$id": "157", "kind": "model", "name": "while", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.while", "usage": "Input,Json", "decorators": [], @@ -1192,7 +1192,7 @@ "$id": "162", "kind": "model", "name": "with", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.with", "usage": "Input,Json", "decorators": [], @@ -1229,7 +1229,7 @@ "$id": "167", "kind": "model", "name": "yield", - "clientNamespace": "SpecialWords.Models", + "namespace": "SpecialWords.Models", "crossLanguageDefinitionId": "SpecialWords.Models.yield", "usage": "Input,Json", "decorators": [], @@ -1267,7 +1267,7 @@ { "$id": "172", "Name": "SpecialWordsClient", - "ClientNamespace": "SpecialWords", + "Namespace": "SpecialWords", "Doc": "Scenarios to verify that reserved words can be used in service and generators will handle it appropriately.\n\nCurrent list of special words\n```txt\nand\nas\nassert\nasync\nawait\nbreak\nclass\nconstructor\ncontinue\ndef\ndel\nelif\nelse\nexcept\nexec\nfinally\nfor\nfrom\nglobal\nif\nimport\nin\nis\nlambda\nnot\nor\npass\nraise\nreturn\ntry\nwhile\nwith\nyield\n```", "Operations": [], "Protocol": { @@ -1311,7 +1311,7 @@ { "$id": "178", "Name": "Models", - "ClientNamespace": "SpecialWords.Models", + "Namespace": "SpecialWords.Models", "Doc": "Verify model names", "Operations": [ { @@ -3865,7 +3865,7 @@ { "$id": "382", "Name": "ModelProperties", - "ClientNamespace": "SpecialWords.ModelProperties", + "Namespace": "SpecialWords.ModelProperties", "Doc": "Verify model names", "Operations": [ { @@ -3987,7 +3987,7 @@ { "$id": "394", "Name": "Operations", - "ClientNamespace": "SpecialWords", + "Namespace": "SpecialWords", "Doc": "Test reserved words as operation name.", "Operations": [ { @@ -4924,7 +4924,7 @@ { "$id": "466", "Name": "Parameters", - "ClientNamespace": "SpecialWords", + "Namespace": "SpecialWords", "Doc": "Verify reserved words as parameter name.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/array/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/array/tspCodeModel.json index e44271f4a62..ef342527108 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/array/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/array/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "InnerModel", - "clientNamespace": "Type.Array", + "namespace": "Type.Array", "crossLanguageDefinitionId": "Type.Array.InnerModel", "usage": "Input,Output,Json", "doc": "Array inner model", @@ -77,7 +77,7 @@ { "$id": "11", "Name": "ArrayClient", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Illustrates various types of arrays.", "Operations": [], "Protocol": { @@ -121,7 +121,7 @@ { "$id": "17", "Name": "Int32Value", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of int32 values", "Operations": [ { @@ -326,7 +326,7 @@ { "$id": "38", "Name": "Int64Value", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of int64 values", "Operations": [ { @@ -531,7 +531,7 @@ { "$id": "59", "Name": "BooleanValue", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of boolean values", "Operations": [ { @@ -736,7 +736,7 @@ { "$id": "80", "Name": "StringValue", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of string values", "Operations": [ { @@ -941,7 +941,7 @@ { "$id": "101", "Name": "Float32Value", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of float values", "Operations": [ { @@ -1146,7 +1146,7 @@ { "$id": "122", "Name": "DatetimeValue", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of datetime values", "Operations": [ { @@ -1367,7 +1367,7 @@ { "$id": "145", "Name": "DurationValue", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of duration values", "Operations": [ { @@ -1588,7 +1588,7 @@ { "$id": "168", "Name": "UnknownValue", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of unknown values", "Operations": [ { @@ -1793,7 +1793,7 @@ { "$id": "189", "Name": "ModelValue", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of model values", "Operations": [ { @@ -1990,7 +1990,7 @@ { "$id": "208", "Name": "NullableFloatValue", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of nullable float values", "Operations": [ { @@ -2047,7 +2047,7 @@ "crossLanguageDefinitionId": "TypeSpec.float32", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "crossLanguageDefinitionId": "TypeSpec.Array", "decorators": [] @@ -2196,7 +2196,7 @@ { "$id": "229", "Name": "NullableInt32Value", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of nullable int32 values", "Operations": [ { @@ -2253,7 +2253,7 @@ "crossLanguageDefinitionId": "TypeSpec.int32", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "crossLanguageDefinitionId": "TypeSpec.Array", "decorators": [] @@ -2402,7 +2402,7 @@ { "$id": "250", "Name": "NullableBooleanValue", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of nullable boolean values", "Operations": [ { @@ -2459,7 +2459,7 @@ "crossLanguageDefinitionId": "TypeSpec.boolean", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "crossLanguageDefinitionId": "TypeSpec.Array", "decorators": [] @@ -2608,7 +2608,7 @@ { "$id": "271", "Name": "NullableStringValue", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of nullable string values", "Operations": [ { @@ -2665,7 +2665,7 @@ "crossLanguageDefinitionId": "TypeSpec.string", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "crossLanguageDefinitionId": "TypeSpec.Array", "decorators": [] @@ -2814,7 +2814,7 @@ { "$id": "292", "Name": "NullableModelValue", - "ClientNamespace": "Type.Array", + "Namespace": "Type.Array", "Doc": "Array of nullable model values", "Operations": [ { @@ -2867,7 +2867,7 @@ "type": { "$ref": "2" }, - "clientNamespace": "" + "namespace": "" }, "crossLanguageDefinitionId": "TypeSpec.Array", "decorators": [] diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/dictionary/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/dictionary/tspCodeModel.json index acb4f9864ef..d672bc60809 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/dictionary/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/dictionary/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "InnerModel", - "clientNamespace": "Type.Dictionary", + "namespace": "Type.Dictionary", "crossLanguageDefinitionId": "Type.Dictionary.InnerModel", "usage": "Input,Output,Json", "doc": "Dictionary inner model", @@ -82,7 +82,7 @@ { "$id": "12", "Name": "DictionaryClient", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Illustrates various of dictionaries.", "Operations": [], "Protocol": { @@ -126,7 +126,7 @@ { "$id": "18", "Name": "Int32Value", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Dictionary of int32 values", "Operations": [ { @@ -341,7 +341,7 @@ { "$id": "41", "Name": "Int64Value", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Dictionary of int64 values", "Operations": [ { @@ -556,7 +556,7 @@ { "$id": "64", "Name": "BooleanValue", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Dictionary of boolean values", "Operations": [ { @@ -771,7 +771,7 @@ { "$id": "87", "Name": "StringValue", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Dictionary of string values", "Operations": [ { @@ -986,7 +986,7 @@ { "$id": "110", "Name": "Float32Value", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Dictionary of float values", "Operations": [ { @@ -1201,7 +1201,7 @@ { "$id": "133", "Name": "DatetimeValue", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Dictionary of datetime values", "Operations": [ { @@ -1432,7 +1432,7 @@ { "$id": "158", "Name": "DurationValue", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Dictionary of duration values", "Operations": [ { @@ -1663,7 +1663,7 @@ { "$id": "183", "Name": "UnknownValue", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Dictionary of unknown values", "Operations": [ { @@ -1878,7 +1878,7 @@ { "$id": "206", "Name": "ModelValue", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Dictionary of model values", "Operations": [ { @@ -2085,7 +2085,7 @@ { "$id": "227", "Name": "RecursiveModelValue", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Dictionary of model values", "Operations": [ { @@ -2292,7 +2292,7 @@ { "$id": "248", "Name": "NullableFloatValue", - "ClientNamespace": "Type.Dictionary", + "Namespace": "Type.Dictionary", "Doc": "Dictionary of nullable float values", "Operations": [ { @@ -2355,7 +2355,7 @@ "crossLanguageDefinitionId": "TypeSpec.float32", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "decorators": [] }, diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/enum/extensible/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/enum/extensible/tspCodeModel.json index e4e982876de..078cbfb28d2 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/enum/extensible/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/enum/extensible/tspCodeModel.json @@ -143,7 +143,7 @@ "decorators": [] } ], - "clientNamespace": "Type.Enum.Extensible", + "namespace": "Type.Enum.Extensible", "doc": "Days of the week", "isFixed": false, "isFlags": false, @@ -156,7 +156,7 @@ { "$id": "18", "Name": "ExtensibleClient", - "ClientNamespace": "Type.Enum.Extensible", + "Namespace": "Type.Enum.Extensible", "Operations": [], "Protocol": { "$id": "19" @@ -199,7 +199,7 @@ { "$id": "24", "Name": "String", - "ClientNamespace": "Type.Enum.Extensible", + "Namespace": "Type.Enum.Extensible", "Operations": [ { "$id": "25", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/enum/fixed/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/enum/fixed/tspCodeModel.json index a3a4e749c36..759632b6e85 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/enum/fixed/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/enum/fixed/tspCodeModel.json @@ -143,7 +143,7 @@ "decorators": [] } ], - "clientNamespace": "Type.Enum.Fixed", + "namespace": "Type.Enum.Fixed", "doc": "Days of the week", "isFixed": true, "isFlags": false, @@ -156,7 +156,7 @@ { "$id": "18", "Name": "FixedClient", - "ClientNamespace": "Type.Enum.Fixed", + "Namespace": "Type.Enum.Fixed", "Operations": [], "Protocol": { "$id": "19" @@ -199,7 +199,7 @@ { "$id": "24", "Name": "String", - "ClientNamespace": "Type.Enum.Fixed", + "Namespace": "Type.Enum.Fixed", "Operations": [ { "$id": "25", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/empty/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/empty/tspCodeModel.json index 614df41678b..6b23f6ebc4a 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/empty/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/empty/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "EmptyInput", - "clientNamespace": "Type.Model.Empty", + "namespace": "Type.Model.Empty", "crossLanguageDefinitionId": "Type.Model.Empty.EmptyInput", "usage": "Input,Json", "doc": "Empty model used in operation parameters", @@ -19,7 +19,7 @@ "$id": "3", "kind": "model", "name": "EmptyOutput", - "clientNamespace": "Type.Model.Empty", + "namespace": "Type.Model.Empty", "crossLanguageDefinitionId": "Type.Model.Empty.EmptyOutput", "usage": "Output,Json", "doc": "Empty model used in operation return type", @@ -30,7 +30,7 @@ "$id": "4", "kind": "model", "name": "EmptyInputOutput", - "clientNamespace": "Type.Model.Empty", + "namespace": "Type.Model.Empty", "crossLanguageDefinitionId": "Type.Model.Empty.EmptyInputOutput", "usage": "Input,Output,Json", "doc": "Empty model used in both parameter and return type", @@ -42,7 +42,7 @@ { "$id": "5", "Name": "EmptyClient", - "ClientNamespace": "Type.Model.Empty", + "Namespace": "Type.Model.Empty", "Doc": "Illustrates usage of empty model used in operation's parameters and responses.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/enum-discriminator/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/enum-discriminator/tspCodeModel.json index 1b8d78fef5b..26f722e43eb 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/enum-discriminator/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/enum-discriminator/tspCodeModel.json @@ -35,7 +35,7 @@ "decorators": [] } ], - "clientNamespace": "Type.Model.Inheritance.EnumDiscriminator", + "namespace": "Type.Model.Inheritance.EnumDiscriminator", "doc": "extensible enum type for discriminator", "isFixed": false, "isFlags": false, @@ -74,7 +74,7 @@ "decorators": [] } ], - "clientNamespace": "Type.Model.Inheritance.EnumDiscriminator", + "namespace": "Type.Model.Inheritance.EnumDiscriminator", "doc": "fixed enum type for discriminator", "isFixed": true, "isFlags": false, @@ -87,7 +87,7 @@ "$id": "10", "kind": "model", "name": "Dog", - "clientNamespace": "Type.Model.Inheritance.EnumDiscriminator", + "namespace": "Type.Model.Inheritance.EnumDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.EnumDiscriminator.Dog", "usage": "Input,Output,Json", "doc": "Test extensible enum type for discriminator", @@ -153,7 +153,7 @@ "$id": "19", "kind": "model", "name": "Golden", - "clientNamespace": "Type.Model.Inheritance.EnumDiscriminator", + "namespace": "Type.Model.Inheritance.EnumDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.EnumDiscriminator.Golden", "usage": "Input,Output,Json", "doc": "Golden dog model", @@ -207,7 +207,7 @@ "$id": "25", "kind": "model", "name": "Snake", - "clientNamespace": "Type.Model.Inheritance.EnumDiscriminator", + "namespace": "Type.Model.Inheritance.EnumDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.EnumDiscriminator.Snake", "usage": "Input,Output,Json", "doc": "Test fixed enum type for discriminator", @@ -273,7 +273,7 @@ "$id": "34", "kind": "model", "name": "Cobra", - "clientNamespace": "Type.Model.Inheritance.EnumDiscriminator", + "namespace": "Type.Model.Inheritance.EnumDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.EnumDiscriminator.Cobra", "usage": "Input,Output,Json", "doc": "Cobra model", @@ -328,7 +328,7 @@ { "$id": "40", "Name": "EnumDiscriminatorClient", - "ClientNamespace": "Type.Model.Inheritance.EnumDiscriminator", + "Namespace": "Type.Model.Inheritance.EnumDiscriminator", "Doc": "Illustrates inheritance with enum discriminator.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/nested-discriminator/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/nested-discriminator/tspCodeModel.json index 86f8208f55b..42e92b11153 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/nested-discriminator/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/nested-discriminator/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "Fish", - "clientNamespace": "Type.Model.Inheritance.NestedDiscriminator", + "namespace": "Type.Model.Inheritance.NestedDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.NestedDiscriminator.Fish", "usage": "Input,Output,Json", "doc": "This is base model for polymorphic multiple levels inheritance with a discriminator.", @@ -77,7 +77,7 @@ "$id": "12", "kind": "model", "name": "Shark", - "clientNamespace": "Type.Model.Inheritance.NestedDiscriminator", + "namespace": "Type.Model.Inheritance.NestedDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.NestedDiscriminator.Shark", "usage": "Input,Output,Json", "doc": "The second level model in polymorphic multiple levels inheritance and it defines a new discriminator.", @@ -155,7 +155,7 @@ "$id": "23", "kind": "model", "name": "SawShark", - "clientNamespace": "Type.Model.Inheritance.NestedDiscriminator", + "namespace": "Type.Model.Inheritance.NestedDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.NestedDiscriminator.SawShark", "usage": "Input,Output,Json", "doc": "The third level model SawShark in polymorphic multiple levels inheritance.", @@ -203,7 +203,7 @@ "$id": "29", "kind": "model", "name": "GoblinShark", - "clientNamespace": "Type.Model.Inheritance.NestedDiscriminator", + "namespace": "Type.Model.Inheritance.NestedDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.NestedDiscriminator.GoblinShark", "usage": "Input,Output,Json", "doc": "The third level model GoblinShark in polymorphic multiple levels inheritance.", @@ -253,7 +253,7 @@ "$id": "35", "kind": "model", "name": "Salmon", - "clientNamespace": "Type.Model.Inheritance.NestedDiscriminator", + "namespace": "Type.Model.Inheritance.NestedDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.NestedDiscriminator.Salmon", "usage": "Input,Output,Json", "doc": "The second level model in polymorphic multiple levels inheritance which contains references to other polymorphic instances.", @@ -401,7 +401,7 @@ { "$id": "53", "Name": "NestedDiscriminatorClient", - "ClientNamespace": "Type.Model.Inheritance.NestedDiscriminator", + "Namespace": "Type.Model.Inheritance.NestedDiscriminator", "Doc": "Illustrates multiple level inheritance with multiple discriminators.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/not-discriminated/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/not-discriminated/tspCodeModel.json index cc4fcfa00a1..6eaab8c52b6 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/not-discriminated/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/not-discriminated/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "Siamese", - "clientNamespace": "Type.Model.Inheritance.NotDiscriminated", + "namespace": "Type.Model.Inheritance.NotDiscriminated", "crossLanguageDefinitionId": "Type.Model.Inheritance.NotDiscriminated.Siamese", "usage": "Input,Output,Json", "doc": "The third level model in the normal multiple levels inheritance.", @@ -17,7 +17,7 @@ "$id": "3", "kind": "model", "name": "Cat", - "clientNamespace": "Type.Model.Inheritance.NotDiscriminated", + "namespace": "Type.Model.Inheritance.NotDiscriminated", "crossLanguageDefinitionId": "Type.Model.Inheritance.NotDiscriminated.Cat", "usage": "Input,Output,Json", "doc": "The second level model in the normal multiple levels inheritance.", @@ -26,7 +26,7 @@ "$id": "4", "kind": "model", "name": "Pet", - "clientNamespace": "Type.Model.Inheritance.NotDiscriminated", + "namespace": "Type.Model.Inheritance.NotDiscriminated", "crossLanguageDefinitionId": "Type.Model.Inheritance.NotDiscriminated.Pet", "usage": "Input,Output,Json", "doc": "This is base model for not-discriminated normal multiple levels inheritance.", @@ -129,7 +129,7 @@ { "$id": "17", "Name": "NotDiscriminatedClient", - "ClientNamespace": "Type.Model.Inheritance.NotDiscriminated", + "Namespace": "Type.Model.Inheritance.NotDiscriminated", "Doc": "Illustrates not-discriminated inheritance model.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/recursive/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/recursive/tspCodeModel.json index 5b99c3955fa..4c1783744a0 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/recursive/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/recursive/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "Extension", - "clientNamespace": "Type.Model.Inheritance.Recursive", + "namespace": "Type.Model.Inheritance.Recursive", "crossLanguageDefinitionId": "Type.Model.Inheritance.Recursive.Extension", "usage": "Input,Output,Json", "doc": "extension", @@ -17,7 +17,7 @@ "$id": "3", "kind": "model", "name": "Element", - "clientNamespace": "Type.Model.Inheritance.Recursive", + "namespace": "Type.Model.Inheritance.Recursive", "crossLanguageDefinitionId": "Type.Model.Inheritance.Recursive.Element", "usage": "Input,Output,Json", "doc": "element", @@ -91,7 +91,7 @@ { "$id": "12", "Name": "RecursiveClient", - "ClientNamespace": "Type.Model.Inheritance.Recursive", + "Namespace": "Type.Model.Inheritance.Recursive", "Doc": "Illustrates inheritance recursion", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/single-discriminator/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/single-discriminator/tspCodeModel.json index 61d81657833..5f2d3a502d3 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/single-discriminator/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/inheritance/single-discriminator/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "Bird", - "clientNamespace": "Type.Model.Inheritance.SingleDiscriminator", + "namespace": "Type.Model.Inheritance.SingleDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.SingleDiscriminator.Bird", "usage": "Input,Output,Json", "doc": "This is base model for polymorphic single level inheritance with a discriminator.", @@ -76,7 +76,7 @@ "$id": "12", "kind": "model", "name": "SeaGull", - "clientNamespace": "Type.Model.Inheritance.SingleDiscriminator", + "namespace": "Type.Model.Inheritance.SingleDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.SingleDiscriminator.SeaGull", "usage": "Input,Output,Json", "doc": "The second level model in polymorphic single level inheritance.", @@ -124,7 +124,7 @@ "$id": "18", "kind": "model", "name": "Sparrow", - "clientNamespace": "Type.Model.Inheritance.SingleDiscriminator", + "namespace": "Type.Model.Inheritance.SingleDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.SingleDiscriminator.Sparrow", "usage": "Input,Output,Json", "doc": "The second level model in polymorphic single level inheritance.", @@ -172,7 +172,7 @@ "$id": "24", "kind": "model", "name": "Goose", - "clientNamespace": "Type.Model.Inheritance.SingleDiscriminator", + "namespace": "Type.Model.Inheritance.SingleDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.SingleDiscriminator.Goose", "usage": "Input,Output,Json", "doc": "The second level model in polymorphic single level inheritance.", @@ -220,7 +220,7 @@ "$id": "30", "kind": "model", "name": "Eagle", - "clientNamespace": "Type.Model.Inheritance.SingleDiscriminator", + "namespace": "Type.Model.Inheritance.SingleDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.SingleDiscriminator.Eagle", "usage": "Input,Output,Json", "doc": "The second level model in polymorphic single levels inheritance which contains references to other polymorphic instances.", @@ -367,7 +367,7 @@ "$id": "48", "kind": "model", "name": "Dinosaur", - "clientNamespace": "Type.Model.Inheritance.SingleDiscriminator", + "namespace": "Type.Model.Inheritance.SingleDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.SingleDiscriminator.Dinosaur", "usage": "Output,Json", "doc": "Define a base class in the legacy way. Discriminator property is not explicitly defined in the model.", @@ -436,7 +436,7 @@ "$id": "58", "kind": "model", "name": "TRex", - "clientNamespace": "Type.Model.Inheritance.SingleDiscriminator", + "namespace": "Type.Model.Inheritance.SingleDiscriminator", "crossLanguageDefinitionId": "Type.Model.Inheritance.SingleDiscriminator.TRex", "usage": "Output,Json", "doc": "The second level legacy model in polymorphic single level inheritance.", @@ -490,7 +490,7 @@ { "$id": "64", "Name": "SingleDiscriminatorClient", - "ClientNamespace": "Type.Model.Inheritance.SingleDiscriminator", + "Namespace": "Type.Model.Inheritance.SingleDiscriminator", "Doc": "Illustrates inheritance with single discriminator.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/usage/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/usage/tspCodeModel.json index 81a5a9b3302..966f66a162d 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/usage/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/usage/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "InputRecord", - "clientNamespace": "Type.Model.Usage", + "namespace": "Type.Model.Usage", "crossLanguageDefinitionId": "Type.Model.Usage.InputRecord", "usage": "Input,Json", "doc": "Record used in operation parameters", @@ -46,7 +46,7 @@ "$id": "7", "kind": "model", "name": "OutputRecord", - "clientNamespace": "Type.Model.Usage", + "namespace": "Type.Model.Usage", "crossLanguageDefinitionId": "Type.Model.Usage.OutputRecord", "usage": "Output,Json", "doc": "Record used in operation return type", @@ -84,7 +84,7 @@ "$id": "12", "kind": "model", "name": "InputOutputRecord", - "clientNamespace": "Type.Model.Usage", + "namespace": "Type.Model.Usage", "crossLanguageDefinitionId": "Type.Model.Usage.InputOutputRecord", "usage": "Input,Output,Json", "doc": "Record used both as operation parameter and return type", @@ -123,7 +123,7 @@ { "$id": "17", "Name": "UsageClient", - "ClientNamespace": "Type.Model.Usage", + "Namespace": "Type.Model.Usage", "Doc": "Illustrates usage of Record in different places(Operation parameters, return type or both).", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/visibility/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/visibility/tspCodeModel.json index 8168adc9406..4fe9143ec83 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/visibility/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/model/visibility/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "VisibilityModel", - "clientNamespace": "Type.Model.Visibility", + "namespace": "Type.Model.Visibility", "crossLanguageDefinitionId": "Type.Model.Visibility.VisibilityModel", "usage": "Input,Output,Json", "doc": "Output model with visibility properties.", @@ -169,7 +169,7 @@ "$id": "25", "kind": "model", "name": "ReadOnlyModel", - "clientNamespace": "Type.Model.Visibility", + "namespace": "Type.Model.Visibility", "crossLanguageDefinitionId": "Type.Model.Visibility.ReadOnlyModel", "usage": "Input,Output,Json", "doc": "RoundTrip model with readonly optional properties.", @@ -198,7 +198,7 @@ "crossLanguageDefinitionId": "TypeSpec.Array", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": true, "readOnly": true, @@ -260,7 +260,7 @@ { "$id": "38", "Name": "VisibilityClient", - "ClientNamespace": "Type.Model.Visibility", + "Namespace": "Type.Model.Visibility", "Doc": "Illustrates models with visibility properties.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/additional-properties/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/additional-properties/tspCodeModel.json index 4d2cdb35320..f85517410d6 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/additional-properties/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/additional-properties/tspCodeModel.json @@ -30,7 +30,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "doc": "The WidgetData2_kind", "isFixed": false, "isFlags": false, @@ -64,7 +64,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "doc": "The WidgetData1_kind", "isFixed": false, "isFlags": false, @@ -98,7 +98,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "doc": "The WidgetData0_kind", "isFixed": false, "isFlags": false, @@ -111,7 +111,7 @@ "$id": "11", "kind": "model", "name": "SpreadRecordForNonDiscriminatedUnion3", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.SpreadRecordForNonDiscriminatedUnion3", "usage": "Input,Output,Json", "doc": "The model spread Record", @@ -129,7 +129,7 @@ "$id": "14", "kind": "model", "name": "WidgetData2", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.WidgetData2", "usage": "Input,Output,Json", "decorators": [], @@ -197,7 +197,7 @@ "$id": "23", "kind": "model", "name": "WidgetData1", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.WidgetData1", "usage": "Input,Output,Json", "decorators": [], @@ -301,7 +301,7 @@ ] } ], - "clientNamespace": "", + "namespace": "", "decorators": [] }, "properties": [ @@ -344,7 +344,7 @@ "$id": "42", "kind": "model", "name": "SpreadRecordForNonDiscriminatedUnion2", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.SpreadRecordForNonDiscriminatedUnion2", "usage": "Input,Output,Json", "doc": "The model spread Record", @@ -361,7 +361,7 @@ "$ref": "23" } ], - "clientNamespace": "", + "namespace": "", "decorators": [] }, "properties": [ @@ -398,7 +398,7 @@ "$id": "48", "kind": "model", "name": "SpreadRecordForNonDiscriminatedUnion", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.SpreadRecordForNonDiscriminatedUnion", "usage": "Input,Output,Json", "doc": "The model spread Record", @@ -412,7 +412,7 @@ "$id": "50", "kind": "model", "name": "WidgetData0", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.WidgetData0", "usage": "Input,Output,Json", "decorators": [], @@ -477,7 +477,7 @@ "$ref": "23" } ], - "clientNamespace": "", + "namespace": "", "decorators": [] }, "properties": [ @@ -517,7 +517,7 @@ "$id": "63", "kind": "model", "name": "SpreadRecordForDiscriminatedUnion", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.SpreadRecordForDiscriminatedUnion", "usage": "Input,Output,Json", "doc": "The model spread Record", @@ -534,7 +534,7 @@ "$ref": "23" } ], - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "decorators": [] }, "properties": [ @@ -571,7 +571,7 @@ "$id": "69", "kind": "model", "name": "SpreadRecordForUnion", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.SpreadRecordForUnion", "usage": "Input,Output,Json", "doc": "The model spread Record", @@ -596,7 +596,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "decorators": [] }, "properties": [ @@ -633,7 +633,7 @@ "$id": "77", "kind": "model", "name": "MultipleSpreadRecord", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.MultipleSpreadRecord", "usage": "Input,Output,Json", "doc": "The model spread Record and Record", @@ -658,7 +658,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "decorators": [] }, "properties": [ @@ -695,7 +695,7 @@ "$id": "85", "kind": "model", "name": "DifferentSpreadModelArrayDerived", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.DifferentSpreadModelArrayDerived", "usage": "Input,Output,Json", "doc": "The model extends from a model that spread Record with the different known property type", @@ -704,7 +704,7 @@ "$id": "86", "kind": "model", "name": "DifferentSpreadModelArrayRecord", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.DifferentSpreadModelArrayRecord", "usage": "Input,Output,Json", "doc": "The model spread Record with the different known property type", @@ -717,7 +717,7 @@ "$id": "88", "kind": "model", "name": "ModelForRecord", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.ModelForRecord", "usage": "Input,Output,Json", "doc": "model for record", @@ -827,7 +827,7 @@ "$id": "101", "kind": "model", "name": "DifferentSpreadModelDerived", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.DifferentSpreadModelDerived", "usage": "Input,Output,Json", "doc": "The model extends from a model that spread Record with the different known property type", @@ -836,7 +836,7 @@ "$id": "102", "kind": "model", "name": "DifferentSpreadModelRecord", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.DifferentSpreadModelRecord", "usage": "Input,Output,Json", "doc": "The model spread Record with the different known property type", @@ -906,7 +906,7 @@ "$id": "110", "kind": "model", "name": "DifferentSpreadFloatDerived", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.DifferentSpreadFloatDerived", "usage": "Input,Output,Json", "doc": "The model extends from a model that spread Record with the different known property type", @@ -915,7 +915,7 @@ "$id": "111", "kind": "model", "name": "DifferentSpreadFloatRecord", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.DifferentSpreadFloatRecord", "usage": "Input,Output,Json", "doc": "The model spread Record with the different known property type", @@ -994,7 +994,7 @@ "$id": "121", "kind": "model", "name": "DifferentSpreadStringDerived", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.DifferentSpreadStringDerived", "usage": "Input,Output,Json", "doc": "The model extends from a model that spread Record with the different known property type", @@ -1003,7 +1003,7 @@ "$id": "122", "kind": "model", "name": "DifferentSpreadStringRecord", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.DifferentSpreadStringRecord", "usage": "Input,Output,Json", "doc": "The model spread Record with the different known property type", @@ -1082,7 +1082,7 @@ "$id": "132", "kind": "model", "name": "SpreadModelArrayRecord", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.SpreadModelArrayRecord", "usage": "Input,Output,Json", "decorators": [], @@ -1132,7 +1132,7 @@ "$id": "138", "kind": "model", "name": "IsModelArrayAdditionalProperties", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.IsModelArrayAdditionalProperties", "usage": "Input,Output,Json", "doc": "The model is from Record type.", @@ -1183,7 +1183,7 @@ "$id": "144", "kind": "model", "name": "ExtendsModelArrayAdditionalProperties", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.ExtendsModelArrayAdditionalProperties", "usage": "Input,Output,Json", "doc": "The model extends from Record type.", @@ -1234,7 +1234,7 @@ "$id": "150", "kind": "model", "name": "SpreadModelRecord", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.SpreadModelRecord", "usage": "Input,Output,Json", "doc": "The model spread Record with the same known property type", @@ -1271,7 +1271,7 @@ "$id": "154", "kind": "model", "name": "IsModelAdditionalProperties", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.IsModelAdditionalProperties", "usage": "Input,Output,Json", "doc": "The model is from Record type.", @@ -1308,7 +1308,7 @@ "$id": "158", "kind": "model", "name": "ExtendsModelAdditionalProperties", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.ExtendsModelAdditionalProperties", "usage": "Input,Output,Json", "doc": "The model extends from Record type.", @@ -1345,7 +1345,7 @@ "$id": "162", "kind": "model", "name": "SpreadFloatRecord", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.SpreadFloatRecord", "usage": "Input,Output,Json", "doc": "The model spread Record with the same known property type", @@ -1391,7 +1391,7 @@ "$id": "168", "kind": "model", "name": "IsFloatAdditionalProperties", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.IsFloatAdditionalProperties", "usage": "Input,Output,Json", "doc": "The model is from Record type.", @@ -1437,7 +1437,7 @@ "$id": "174", "kind": "model", "name": "ExtendsFloatAdditionalProperties", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.ExtendsFloatAdditionalProperties", "usage": "Input,Output,Json", "doc": "The model extends from Record type.", @@ -1483,7 +1483,7 @@ "$id": "180", "kind": "model", "name": "SpreadStringRecord", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.SpreadStringRecord", "usage": "Input,Output,Json", "doc": "The model spread Record with the same known property type", @@ -1529,7 +1529,7 @@ "$id": "186", "kind": "model", "name": "IsStringAdditionalProperties", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.IsStringAdditionalProperties", "usage": "Input,Output,Json", "doc": "The model is from Record type.", @@ -1575,7 +1575,7 @@ "$id": "192", "kind": "model", "name": "ExtendsStringAdditionalProperties", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.ExtendsStringAdditionalProperties", "usage": "Input,Output,Json", "doc": "The model extends from Record type.", @@ -1621,7 +1621,7 @@ "$id": "198", "kind": "model", "name": "IsUnknownAdditionalPropertiesDiscriminated", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.IsUnknownAdditionalPropertiesDiscriminated", "usage": "Input,Output,Json", "doc": "The model is Record with a discriminator.", @@ -1698,7 +1698,7 @@ "$id": "209", "kind": "model", "name": "IsUnknownAdditionalPropertiesDiscriminatedDerived", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.IsUnknownAdditionalPropertiesDiscriminatedDerived", "usage": "Input,Output,Json", "doc": "The derived discriminated type", @@ -1805,7 +1805,7 @@ "$id": "223", "kind": "model", "name": "IsUnknownAdditionalPropertiesDerived", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.IsUnknownAdditionalPropertiesDerived", "usage": "Input,Output,Json", "doc": "The model extends from a type that is Record type", @@ -1814,7 +1814,7 @@ "$id": "224", "kind": "model", "name": "IsUnknownAdditionalProperties", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.IsUnknownAdditionalProperties", "usage": "Input,Output,Json", "doc": "The model is from Record type.", @@ -1920,7 +1920,7 @@ "$id": "238", "kind": "model", "name": "ExtendsUnknownAdditionalPropertiesDiscriminated", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.ExtendsUnknownAdditionalPropertiesDiscriminated", "usage": "Input,Output,Json", "doc": "The model extends from Record with a discriminator.", @@ -1997,7 +1997,7 @@ "$id": "249", "kind": "model", "name": "ExtendsUnknownAdditionalPropertiesDiscriminatedDerived", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.ExtendsUnknownAdditionalPropertiesDiscriminatedDerived", "usage": "Input,Output,Json", "doc": "The derived discriminated type", @@ -2104,7 +2104,7 @@ "$id": "263", "kind": "model", "name": "ExtendsUnknownAdditionalPropertiesDerived", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.ExtendsUnknownAdditionalPropertiesDerived", "usage": "Input,Output,Json", "doc": "The model extends from a type that extends from Record.", @@ -2113,7 +2113,7 @@ "$id": "264", "kind": "model", "name": "ExtendsUnknownAdditionalProperties", - "clientNamespace": "Type.Property.AdditionalProperties", + "namespace": "Type.Property.AdditionalProperties", "crossLanguageDefinitionId": "Type.Property.AdditionalProperties.ExtendsUnknownAdditionalProperties", "usage": "Input,Output,Json", "doc": "The model extends from Record type.", @@ -2220,7 +2220,7 @@ { "$id": "278", "Name": "AdditionalPropertiesClient", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Doc": "Tests for additional properties of models", "Operations": [], "Protocol": { @@ -2264,7 +2264,7 @@ { "$id": "284", "Name": "ExtendsUnknown", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "285", @@ -2449,7 +2449,7 @@ { "$id": "301", "Name": "ExtendsUnknownDerived", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "302", @@ -2634,7 +2634,7 @@ { "$id": "318", "Name": "ExtendsUnknownDiscriminated", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "319", @@ -2819,7 +2819,7 @@ { "$id": "335", "Name": "IsUnknown", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "336", @@ -3004,7 +3004,7 @@ { "$id": "352", "Name": "IsUnknownDerived", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "353", @@ -3189,7 +3189,7 @@ { "$id": "369", "Name": "IsUnknownDiscriminated", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "370", @@ -3374,7 +3374,7 @@ { "$id": "386", "Name": "ExtendsString", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "387", @@ -3559,7 +3559,7 @@ { "$id": "403", "Name": "IsString", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "404", @@ -3744,7 +3744,7 @@ { "$id": "420", "Name": "SpreadString", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "421", @@ -3929,7 +3929,7 @@ { "$id": "437", "Name": "ExtendsFloat", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "438", @@ -4114,7 +4114,7 @@ { "$id": "454", "Name": "IsFloat", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "455", @@ -4299,7 +4299,7 @@ { "$id": "471", "Name": "SpreadFloat", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "472", @@ -4484,7 +4484,7 @@ { "$id": "488", "Name": "ExtendsModel", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "489", @@ -4669,7 +4669,7 @@ { "$id": "505", "Name": "IsModel", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "506", @@ -4854,7 +4854,7 @@ { "$id": "522", "Name": "SpreadModel", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "523", @@ -5039,7 +5039,7 @@ { "$id": "539", "Name": "ExtendsModelArray", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "540", @@ -5224,7 +5224,7 @@ { "$id": "556", "Name": "IsModelArray", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "557", @@ -5409,7 +5409,7 @@ { "$id": "573", "Name": "SpreadModelArray", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "574", @@ -5594,7 +5594,7 @@ { "$id": "590", "Name": "SpreadDifferentString", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "591", @@ -5779,7 +5779,7 @@ { "$id": "607", "Name": "SpreadDifferentFloat", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "608", @@ -5964,7 +5964,7 @@ { "$id": "624", "Name": "SpreadDifferentModel", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "625", @@ -6149,7 +6149,7 @@ { "$id": "641", "Name": "SpreadDifferentModelArray", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "642", @@ -6334,7 +6334,7 @@ { "$id": "658", "Name": "ExtendsDifferentSpreadString", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "659", @@ -6519,7 +6519,7 @@ { "$id": "675", "Name": "ExtendsDifferentSpreadFloat", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "676", @@ -6704,7 +6704,7 @@ { "$id": "692", "Name": "ExtendsDifferentSpreadModel", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "693", @@ -6889,7 +6889,7 @@ { "$id": "709", "Name": "ExtendsDifferentSpreadModelArray", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "710", @@ -7074,7 +7074,7 @@ { "$id": "726", "Name": "MultipleSpread", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "727", @@ -7259,7 +7259,7 @@ { "$id": "743", "Name": "SpreadRecordUnion", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "744", @@ -7444,7 +7444,7 @@ { "$id": "760", "Name": "SpreadRecordDiscriminatedUnion", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "761", @@ -7629,7 +7629,7 @@ { "$id": "777", "Name": "SpreadRecordNonDiscriminatedUnion", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "778", @@ -7814,7 +7814,7 @@ { "$id": "794", "Name": "SpreadRecordNonDiscriminatedUnion2", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "795", @@ -7999,7 +7999,7 @@ { "$id": "811", "Name": "SpreadRecordNonDiscriminatedUnion3", - "ClientNamespace": "Type.Property.AdditionalProperties", + "Namespace": "Type.Property.AdditionalProperties", "Operations": [ { "$id": "812", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/nullable/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/nullable/tspCodeModel.json index d42026ed90d..55d3adfc2b6 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/nullable/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/nullable/tspCodeModel.json @@ -8,7 +8,7 @@ "$id": "2", "kind": "model", "name": "CollectionsStringProperty", - "clientNamespace": "Type.Property.Nullable", + "namespace": "Type.Property.Nullable", "crossLanguageDefinitionId": "Type.Property.Nullable.CollectionsStringProperty", "usage": "Input,Output,JsonMergePatch,Json", "doc": "Model with collection string properties", @@ -64,7 +64,7 @@ "crossLanguageDefinitionId": "TypeSpec.Array", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -86,7 +86,7 @@ "$id": "13", "kind": "model", "name": "CollectionsModelProperty", - "clientNamespace": "Type.Property.Nullable", + "namespace": "Type.Property.Nullable", "crossLanguageDefinitionId": "Type.Property.Nullable.CollectionsModelProperty", "usage": "Input,Output,JsonMergePatch,Json", "doc": "Model with collection models properties", @@ -136,7 +136,7 @@ "$id": "21", "kind": "model", "name": "InnerModel", - "clientNamespace": "Type.Property.Nullable", + "namespace": "Type.Property.Nullable", "crossLanguageDefinitionId": "Type.Property.Nullable.InnerModel", "usage": "Input,Output,JsonMergePatch,Json", "doc": "Inner model used in collections model property", @@ -174,7 +174,7 @@ "crossLanguageDefinitionId": "TypeSpec.Array", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -199,7 +199,7 @@ "$id": "28", "kind": "model", "name": "CollectionsByteProperty", - "clientNamespace": "Type.Property.Nullable", + "namespace": "Type.Property.Nullable", "crossLanguageDefinitionId": "Type.Property.Nullable.CollectionsByteProperty", "usage": "Input,Output,JsonMergePatch,Json", "doc": "Model with collection bytes properties", @@ -256,7 +256,7 @@ "crossLanguageDefinitionId": "TypeSpec.Array", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -278,7 +278,7 @@ "$id": "39", "kind": "model", "name": "DurationProperty", - "clientNamespace": "Type.Property.Nullable", + "namespace": "Type.Property.Nullable", "crossLanguageDefinitionId": "Type.Property.Nullable.DurationProperty", "usage": "Input,Output,JsonMergePatch,Json", "doc": "Model with a duration property", @@ -335,7 +335,7 @@ "crossLanguageDefinitionId": "TypeSpec.duration", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -357,7 +357,7 @@ "$id": "50", "kind": "model", "name": "DatetimeProperty", - "clientNamespace": "Type.Property.Nullable", + "namespace": "Type.Property.Nullable", "crossLanguageDefinitionId": "Type.Property.Nullable.DatetimeProperty", "usage": "Input,Output,JsonMergePatch,Json", "doc": "Model with a datetime property", @@ -414,7 +414,7 @@ "crossLanguageDefinitionId": "TypeSpec.utcDateTime", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -436,7 +436,7 @@ "$id": "61", "kind": "model", "name": "BytesProperty", - "clientNamespace": "Type.Property.Nullable", + "namespace": "Type.Property.Nullable", "crossLanguageDefinitionId": "Type.Property.Nullable.BytesProperty", "usage": "Input,Output,JsonMergePatch,Json", "doc": "Template type for testing models with nullable property. Pass in the type of the property you are looking for", @@ -486,7 +486,7 @@ "crossLanguageDefinitionId": "TypeSpec.bytes", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -508,7 +508,7 @@ "$id": "71", "kind": "model", "name": "StringProperty", - "clientNamespace": "Type.Property.Nullable", + "namespace": "Type.Property.Nullable", "crossLanguageDefinitionId": "Type.Property.Nullable.StringProperty", "usage": "Input,Output,JsonMergePatch,Json", "doc": "Template type for testing models with nullable property. Pass in the type of the property you are looking for", @@ -557,7 +557,7 @@ "crossLanguageDefinitionId": "TypeSpec.string", "decorators": [] }, - "clientNamespace": "" + "namespace": "" }, "optional": false, "readOnly": false, @@ -580,7 +580,7 @@ { "$id": "81", "Name": "NullableClient", - "ClientNamespace": "Type.Property.Nullable", + "Namespace": "Type.Property.Nullable", "Doc": "Illustrates models with nullable properties.", "Operations": [], "Protocol": { @@ -624,7 +624,7 @@ { "$id": "87", "Name": "String", - "ClientNamespace": "Type.Property.Nullable", + "Namespace": "Type.Property.Nullable", "Operations": [ { "$id": "88", @@ -947,7 +947,7 @@ { "$id": "115", "Name": "Bytes", - "ClientNamespace": "Type.Property.Nullable", + "Namespace": "Type.Property.Nullable", "Operations": [ { "$id": "116", @@ -1270,7 +1270,7 @@ { "$id": "143", "Name": "Datetime", - "ClientNamespace": "Type.Property.Nullable", + "Namespace": "Type.Property.Nullable", "Operations": [ { "$id": "144", @@ -1593,7 +1593,7 @@ { "$id": "171", "Name": "Duration", - "ClientNamespace": "Type.Property.Nullable", + "Namespace": "Type.Property.Nullable", "Operations": [ { "$id": "172", @@ -1916,7 +1916,7 @@ { "$id": "199", "Name": "CollectionsByte", - "ClientNamespace": "Type.Property.Nullable", + "Namespace": "Type.Property.Nullable", "Operations": [ { "$id": "200", @@ -2239,7 +2239,7 @@ { "$id": "227", "Name": "CollectionsModel", - "ClientNamespace": "Type.Property.Nullable", + "Namespace": "Type.Property.Nullable", "Operations": [ { "$id": "228", @@ -2562,7 +2562,7 @@ { "$id": "255", "Name": "CollectionsString", - "ClientNamespace": "Type.Property.Nullable", + "Namespace": "Type.Property.Nullable", "Operations": [ { "$id": "256", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/optionality/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/optionality/tspCodeModel.json index fb20fc9f8ee..c252d0261ce 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/optionality/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/optionality/tspCodeModel.json @@ -51,7 +51,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -105,7 +105,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -159,7 +159,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -192,7 +192,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "doc": "The FloatLiteralProperty_property", "isFixed": false, "isFlags": false, @@ -226,7 +226,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "doc": "The IntLiteralProperty_property", "isFixed": false, "isFlags": false, @@ -260,7 +260,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "doc": "The StringLiteralProperty_property", "isFixed": false, "isFlags": false, @@ -273,7 +273,7 @@ "$id": "29", "kind": "model", "name": "RequiredAndOptionalProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.RequiredAndOptionalProperty", "usage": "Input,Output,Json", "doc": "Model with required and optional properties", @@ -339,7 +339,7 @@ "$id": "38", "kind": "model", "name": "UnionFloatLiteralProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.UnionFloatLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with union of float literal property", @@ -374,7 +374,7 @@ "$id": "42", "kind": "model", "name": "UnionIntLiteralProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.UnionIntLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with union of int literal property", @@ -409,7 +409,7 @@ "$id": "46", "kind": "model", "name": "UnionStringLiteralProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.UnionStringLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with union of string literal property", @@ -444,7 +444,7 @@ "$id": "50", "kind": "model", "name": "BooleanLiteralProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.BooleanLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with boolean literal property", @@ -489,7 +489,7 @@ "$id": "56", "kind": "model", "name": "FloatLiteralProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.FloatLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with float literal property", @@ -530,7 +530,7 @@ "$id": "61", "kind": "model", "name": "IntLiteralProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.IntLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with int literal property", @@ -571,7 +571,7 @@ "$id": "66", "kind": "model", "name": "StringLiteralProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.StringLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with string literal property", @@ -612,7 +612,7 @@ "$id": "71", "kind": "model", "name": "CollectionsModelProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.CollectionsModelProperty", "usage": "Input,Output,Json", "doc": "Model with collection models properties", @@ -632,7 +632,7 @@ "$id": "74", "kind": "model", "name": "StringProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.StringProperty", "usage": "Input,Output,Json", "doc": "Template type for testing models with optional property. Pass in the type of the property you are looking for", @@ -693,7 +693,7 @@ "$id": "81", "kind": "model", "name": "CollectionsByteProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.CollectionsByteProperty", "usage": "Input,Output,Json", "doc": "Model with collection bytes properties", @@ -740,7 +740,7 @@ "$id": "87", "kind": "model", "name": "PlainTimeProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.PlainTimeProperty", "usage": "Input,Output,Json", "doc": "Model with a plainTime property", @@ -779,7 +779,7 @@ "$id": "92", "kind": "model", "name": "PlainDateProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.PlainDateProperty", "usage": "Input,Output,Json", "doc": "Model with a plainDate property", @@ -818,7 +818,7 @@ "$id": "97", "kind": "model", "name": "DurationProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.DurationProperty", "usage": "Input,Output,Json", "doc": "Model with a duration property", @@ -865,7 +865,7 @@ "$id": "103", "kind": "model", "name": "DatetimeProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.DatetimeProperty", "usage": "Input,Output,Json", "doc": "Model with a datetime property", @@ -912,7 +912,7 @@ "$id": "109", "kind": "model", "name": "BytesProperty", - "clientNamespace": "Type.Property.Optional", + "namespace": "Type.Property.Optional", "crossLanguageDefinitionId": "Type.Property.Optional.BytesProperty", "usage": "Input,Output,Json", "doc": "Template type for testing models with optional property. Pass in the type of the property you are looking for", @@ -953,7 +953,7 @@ { "$id": "114", "Name": "OptionalClient", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Doc": "Illustrates models with optional properties.", "Operations": [], "Protocol": { @@ -997,7 +997,7 @@ { "$id": "120", "Name": "String", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "121", @@ -1320,7 +1320,7 @@ { "$id": "148", "Name": "Bytes", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "149", @@ -1643,7 +1643,7 @@ { "$id": "176", "Name": "Datetime", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "177", @@ -1966,7 +1966,7 @@ { "$id": "204", "Name": "Duration", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "205", @@ -2289,7 +2289,7 @@ { "$id": "232", "Name": "PlainDate", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "233", @@ -2612,7 +2612,7 @@ { "$id": "260", "Name": "PlainTime", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "261", @@ -2935,7 +2935,7 @@ { "$id": "288", "Name": "CollectionsByte", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "289", @@ -3258,7 +3258,7 @@ { "$id": "316", "Name": "CollectionsModel", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "317", @@ -3581,7 +3581,7 @@ { "$id": "344", "Name": "StringLiteral", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "345", @@ -3904,7 +3904,7 @@ { "$id": "372", "Name": "IntLiteral", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "373", @@ -4227,7 +4227,7 @@ { "$id": "400", "Name": "FloatLiteral", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "401", @@ -4550,7 +4550,7 @@ { "$id": "428", "Name": "BooleanLiteral", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "429", @@ -4873,7 +4873,7 @@ { "$id": "456", "Name": "UnionStringLiteral", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "457", @@ -5196,7 +5196,7 @@ { "$id": "484", "Name": "UnionIntLiteral", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "485", @@ -5519,7 +5519,7 @@ { "$id": "512", "Name": "UnionFloatLiteral", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Operations": [ { "$id": "513", @@ -5842,7 +5842,7 @@ { "$id": "540", "Name": "RequiredAndOptional", - "ClientNamespace": "Type.Property.Optional", + "Namespace": "Type.Property.Optional", "Doc": "Test optional and required properties", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/value-types/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/value-types/tspCodeModel.json index acd033d193d..969e78850ff 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/value-types/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/property/value-types/tspCodeModel.json @@ -34,7 +34,7 @@ "decorators": [] } ], - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "isFixed": false, "isFlags": false, "usage": "Input,Output,Json", @@ -88,7 +88,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -142,7 +142,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -196,7 +196,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -229,7 +229,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "doc": "The FloatLiteralProperty_property", "isFixed": false, "isFlags": false, @@ -263,7 +263,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "doc": "The IntLiteralProperty_property", "isFixed": false, "isFlags": false, @@ -297,7 +297,7 @@ } ], "crossLanguageDefinitionId": "", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "doc": "The StringLiteralProperty_property", "isFixed": false, "isFlags": false, @@ -354,7 +354,7 @@ "decorators": [] } ], - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "doc": "Enum that will be used as a property for model EnumProperty. Extensible.", "isFixed": false, "isFlags": false, @@ -411,7 +411,7 @@ "decorators": [] } ], - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "doc": "Enum that will be used as a property for model EnumProperty. Non-extensible.", "isFixed": true, "isFlags": false, @@ -424,7 +424,7 @@ "$id": "45", "kind": "model", "name": "UnionEnumValueProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.UnionEnumValueProperty", "usage": "Input,Output,Json", "doc": "Template type for testing models with specific properties. Pass in the type of the property you are looking for", @@ -465,7 +465,7 @@ "$id": "50", "kind": "model", "name": "UnionFloatLiteralProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.UnionFloatLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with a union of float literal as property.", @@ -500,7 +500,7 @@ "$id": "54", "kind": "model", "name": "UnionIntLiteralProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.UnionIntLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with a union of int literal as property.", @@ -535,7 +535,7 @@ "$id": "58", "kind": "model", "name": "UnionStringLiteralProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.UnionStringLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with a union of string literal as property.", @@ -570,7 +570,7 @@ "$id": "62", "kind": "model", "name": "BooleanLiteralProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.BooleanLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with a boolean literal property.", @@ -615,7 +615,7 @@ "$id": "68", "kind": "model", "name": "FloatLiteralProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.FloatLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with a float literal property.", @@ -656,7 +656,7 @@ "$id": "73", "kind": "model", "name": "IntLiteralProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.IntLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with a int literal property.", @@ -697,7 +697,7 @@ "$id": "78", "kind": "model", "name": "StringLiteralProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.StringLiteralProperty", "usage": "Input,Output,Json", "doc": "Model with a string literal property.", @@ -738,7 +738,7 @@ "$id": "83", "kind": "model", "name": "UnknownArrayProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.UnknownArrayProperty", "usage": "Input,Output,Json", "doc": "Model with a property unknown, and the data is an array.", @@ -777,7 +777,7 @@ "$id": "88", "kind": "model", "name": "UnknownDictProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.UnknownDictProperty", "usage": "Input,Output,Json", "doc": "Model with a property unknown, and the data is a dictionnary.", @@ -816,7 +816,7 @@ "$id": "93", "kind": "model", "name": "UnknownIntProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.UnknownIntProperty", "usage": "Input,Output,Json", "doc": "Model with a property unknown, and the data is a int32.", @@ -855,7 +855,7 @@ "$id": "98", "kind": "model", "name": "UnknownStringProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.UnknownStringProperty", "usage": "Input,Output,Json", "doc": "Model with a property unknown, and the data is a string.", @@ -894,7 +894,7 @@ "$id": "103", "kind": "model", "name": "NeverProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.NeverProperty", "usage": "Input,Output,Json", "doc": "Model with a property never. (This property should not be included).", @@ -905,7 +905,7 @@ "$id": "104", "kind": "model", "name": "DictionaryStringProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.DictionaryStringProperty", "usage": "Input,Output,Json", "doc": "Model with dictionary string properties", @@ -956,7 +956,7 @@ "$id": "111", "kind": "model", "name": "CollectionsModelProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.CollectionsModelProperty", "usage": "Input,Output,Json", "doc": "Model with collection model properties", @@ -976,7 +976,7 @@ "$id": "114", "kind": "model", "name": "InnerModel", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.InnerModel", "usage": "Input,Output,Json", "doc": "Inner model. Will be a property type for ModelWithModelProperties", @@ -1037,7 +1037,7 @@ "$id": "121", "kind": "model", "name": "CollectionsIntProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.CollectionsIntProperty", "usage": "Input,Output,Json", "doc": "Model with collection int properties", @@ -1083,7 +1083,7 @@ "$id": "127", "kind": "model", "name": "CollectionsStringProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.CollectionsStringProperty", "usage": "Input,Output,Json", "doc": "Model with collection string properties", @@ -1129,7 +1129,7 @@ "$id": "133", "kind": "model", "name": "ModelProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.ModelProperty", "usage": "Input,Output,Json", "doc": "Model with model properties", @@ -1164,7 +1164,7 @@ "$id": "137", "kind": "model", "name": "ExtensibleEnumProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.ExtensibleEnumProperty", "usage": "Input,Output,Json", "doc": "Model with extensible enum properties", @@ -1199,7 +1199,7 @@ "$id": "141", "kind": "model", "name": "EnumProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.EnumProperty", "usage": "Input,Output,Json", "doc": "Model with enum properties", @@ -1234,7 +1234,7 @@ "$id": "145", "kind": "model", "name": "DurationProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.DurationProperty", "usage": "Input,Output,Json", "doc": "Model with a duration property", @@ -1281,7 +1281,7 @@ "$id": "151", "kind": "model", "name": "DatetimeProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.DatetimeProperty", "usage": "Input,Output,Json", "doc": "Model with a datetime property", @@ -1328,7 +1328,7 @@ "$id": "157", "kind": "model", "name": "Decimal128Property", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.Decimal128Property", "usage": "Input,Output,Json", "doc": "Model with a decimal128 property", @@ -1367,7 +1367,7 @@ "$id": "162", "kind": "model", "name": "DecimalProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.DecimalProperty", "usage": "Input,Output,Json", "doc": "Model with a decimal property", @@ -1406,7 +1406,7 @@ "$id": "167", "kind": "model", "name": "FloatProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.FloatProperty", "usage": "Input,Output,Json", "doc": "Model with a float property", @@ -1445,7 +1445,7 @@ "$id": "172", "kind": "model", "name": "IntProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.IntProperty", "usage": "Input,Output,Json", "doc": "Model with a int property", @@ -1484,7 +1484,7 @@ "$id": "177", "kind": "model", "name": "BytesProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.BytesProperty", "usage": "Input,Output,Json", "doc": "Model with a bytes property", @@ -1524,7 +1524,7 @@ "$id": "182", "kind": "model", "name": "StringProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.StringProperty", "usage": "Input,Output,Json", "doc": "Model with a string property", @@ -1563,7 +1563,7 @@ "$id": "187", "kind": "model", "name": "BooleanProperty", - "clientNamespace": "Type.Property.ValueTypes", + "namespace": "Type.Property.ValueTypes", "crossLanguageDefinitionId": "Type.Property.ValueTypes.BooleanProperty", "usage": "Input,Output,Json", "doc": "Model with a boolean property", @@ -1603,7 +1603,7 @@ { "$id": "192", "Name": "ValueTypesClient", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Doc": "Illustrates various property types for models", "Operations": [], "Protocol": { @@ -1647,7 +1647,7 @@ { "$id": "198", "Name": "Boolean", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "199", @@ -1832,7 +1832,7 @@ { "$id": "215", "Name": "String", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "216", @@ -2017,7 +2017,7 @@ { "$id": "232", "Name": "Bytes", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "233", @@ -2202,7 +2202,7 @@ { "$id": "249", "Name": "Int", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "250", @@ -2387,7 +2387,7 @@ { "$id": "266", "Name": "Float", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "267", @@ -2572,7 +2572,7 @@ { "$id": "283", "Name": "Decimal", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "284", @@ -2757,7 +2757,7 @@ { "$id": "300", "Name": "Decimal128", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "301", @@ -2942,7 +2942,7 @@ { "$id": "317", "Name": "Datetime", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "318", @@ -3127,7 +3127,7 @@ { "$id": "334", "Name": "Duration", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "335", @@ -3312,7 +3312,7 @@ { "$id": "351", "Name": "Enum", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "352", @@ -3497,7 +3497,7 @@ { "$id": "368", "Name": "ExtensibleEnum", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "369", @@ -3682,7 +3682,7 @@ { "$id": "385", "Name": "Model", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "386", @@ -3867,7 +3867,7 @@ { "$id": "402", "Name": "CollectionsString", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "403", @@ -4052,7 +4052,7 @@ { "$id": "419", "Name": "CollectionsInt", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "420", @@ -4237,7 +4237,7 @@ { "$id": "436", "Name": "CollectionsModel", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "437", @@ -4422,7 +4422,7 @@ { "$id": "453", "Name": "DictionaryString", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "454", @@ -4607,7 +4607,7 @@ { "$id": "470", "Name": "Never", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "471", @@ -4792,7 +4792,7 @@ { "$id": "487", "Name": "UnknownString", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "488", @@ -4977,7 +4977,7 @@ { "$id": "504", "Name": "UnknownInt", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "505", @@ -5162,7 +5162,7 @@ { "$id": "521", "Name": "UnknownDict", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "522", @@ -5347,7 +5347,7 @@ { "$id": "538", "Name": "UnknownArray", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "539", @@ -5532,7 +5532,7 @@ { "$id": "555", "Name": "StringLiteral", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "556", @@ -5717,7 +5717,7 @@ { "$id": "572", "Name": "IntLiteral", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "573", @@ -5902,7 +5902,7 @@ { "$id": "589", "Name": "FloatLiteral", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "590", @@ -6087,7 +6087,7 @@ { "$id": "606", "Name": "BooleanLiteral", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "607", @@ -6272,7 +6272,7 @@ { "$id": "623", "Name": "UnionStringLiteral", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "624", @@ -6457,7 +6457,7 @@ { "$id": "640", "Name": "UnionIntLiteral", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "641", @@ -6642,7 +6642,7 @@ { "$id": "657", "Name": "UnionFloatLiteral", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "658", @@ -6827,7 +6827,7 @@ { "$id": "674", "Name": "UnionEnumValue", - "ClientNamespace": "Type.Property.ValueTypes", + "Namespace": "Type.Property.ValueTypes", "Operations": [ { "$id": "675", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/scalar/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/scalar/tspCodeModel.json index 632b6263864..00a8b21c2d0 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/scalar/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/scalar/tspCodeModel.json @@ -8,7 +8,7 @@ { "$id": "2", "Name": "ScalarClient", - "ClientNamespace": "Type.Scalar", + "Namespace": "Type.Scalar", "Operations": [], "Protocol": { "$id": "3" @@ -51,7 +51,7 @@ { "$id": "8", "Name": "String", - "ClientNamespace": "Type.Scalar", + "Namespace": "Type.Scalar", "Operations": [ { "$id": "9", @@ -244,7 +244,7 @@ { "$id": "27", "Name": "Boolean", - "ClientNamespace": "Type.Scalar", + "Namespace": "Type.Scalar", "Operations": [ { "$id": "28", @@ -437,7 +437,7 @@ { "$id": "46", "Name": "Unknown", - "ClientNamespace": "Type.Scalar", + "Namespace": "Type.Scalar", "Operations": [ { "$id": "47", @@ -630,7 +630,7 @@ { "$id": "65", "Name": "DecimalType", - "ClientNamespace": "Type.Scalar", + "Namespace": "Type.Scalar", "Doc": "Decimal type", "Operations": [ { @@ -870,7 +870,7 @@ { "$id": "88", "Name": "Decimal128Type", - "ClientNamespace": "Type.Scalar", + "Namespace": "Type.Scalar", "Doc": "Decimal128 type", "Operations": [ { @@ -1110,7 +1110,7 @@ { "$id": "111", "Name": "DecimalVerify", - "ClientNamespace": "Type.Scalar", + "Namespace": "Type.Scalar", "Doc": "Decimal type verification", "Operations": [ { @@ -1308,7 +1308,7 @@ { "$id": "131", "Name": "Decimal128Verify", - "ClientNamespace": "Type.Scalar", + "Namespace": "Type.Scalar", "Doc": "Decimal128 type verification", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/union/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/union/tspCodeModel.json index 36d612abb52..9ad6983ad46 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/type/union/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/type/union/tspCodeModel.json @@ -85,7 +85,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -139,7 +139,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -210,7 +210,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -281,7 +281,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -335,7 +335,7 @@ "decorators": [] } ], - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "isFixed": false, "isFlags": false, "usage": "Input,Output,Json", @@ -389,7 +389,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": false, "isFlags": false, "usage": "Input,Output,Json", @@ -460,7 +460,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -472,7 +472,7 @@ "$id": "54", "kind": "model", "name": "GetResponse", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.get.Response.anonymous", "usage": "Output,Json", "decorators": [], @@ -486,7 +486,7 @@ "$id": "56", "kind": "model", "name": "MixedTypesCases", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.MixedTypesCases", "usage": "Input,Output,Json", "decorators": [], @@ -506,7 +506,7 @@ "$id": "59", "kind": "model", "name": "Cat", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.Cat", "usage": "Input,Output,Json", "decorators": [], @@ -567,7 +567,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "decorators": [] }, "optional": false, @@ -711,7 +711,7 @@ "$id": "85", "kind": "model", "name": "SendRequest", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.send.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -744,7 +744,7 @@ "$id": "89", "kind": "model", "name": "GetResponse1", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.get.Response.anonymous", "usage": "Output,Json", "decorators": [], @@ -758,7 +758,7 @@ "$id": "91", "kind": "model", "name": "MixedLiteralsCases", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.MixedLiteralsCases", "usage": "Input,Output,Json", "decorators": [], @@ -827,7 +827,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "decorators": [] }, "optional": false, @@ -938,7 +938,7 @@ "$id": "115", "kind": "model", "name": "SendRequest1", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.send.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -971,7 +971,7 @@ "$id": "119", "kind": "model", "name": "GetResponse2", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.get.Response.anonymous", "usage": "Output,Json", "decorators": [], @@ -985,7 +985,7 @@ "$id": "121", "kind": "model", "name": "StringAndArrayCases", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.StringAndArrayCases", "usage": "Input,Output,Json", "decorators": [], @@ -1023,7 +1023,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "decorators": [] }, "optional": false, @@ -1073,7 +1073,7 @@ "decorators": [] } ], - "clientNamespace": "", + "namespace": "", "decorators": [] }, "optional": false, @@ -1115,7 +1115,7 @@ "$id": "138", "kind": "model", "name": "SendRequest2", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.send.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -1148,7 +1148,7 @@ "$id": "142", "kind": "model", "name": "GetResponse3", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.get.Response.anonymous", "usage": "Output,Json", "decorators": [], @@ -1162,7 +1162,7 @@ "$id": "144", "kind": "model", "name": "EnumsOnlyCases", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.EnumsOnlyCases", "usage": "Input,Output,Json", "decorators": [], @@ -1238,7 +1238,7 @@ "$id": "153", "kind": "model", "name": "SendRequest3", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.send.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -1271,7 +1271,7 @@ "$id": "157", "kind": "model", "name": "GetResponse4", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.get.Response.anonymous", "usage": "Output,Json", "decorators": [], @@ -1293,7 +1293,7 @@ "$id": "160", "kind": "model", "name": "Dog", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.Dog", "usage": "Input,Output,Json", "decorators": [], @@ -1327,7 +1327,7 @@ ] } ], - "clientNamespace": "", + "namespace": "", "decorators": [] }, "optional": false, @@ -1353,7 +1353,7 @@ "$id": "167", "kind": "model", "name": "SendRequest4", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.send.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -1386,7 +1386,7 @@ "$id": "171", "kind": "model", "name": "GetResponse5", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.get.Response.anonymous", "usage": "Output,Json", "decorators": [], @@ -1419,7 +1419,7 @@ "$id": "175", "kind": "model", "name": "SendRequest5", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.send.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -1452,7 +1452,7 @@ "$id": "179", "kind": "model", "name": "GetResponse6", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.get.Response.anonymous", "usage": "Output,Json", "decorators": [], @@ -1485,7 +1485,7 @@ "$id": "183", "kind": "model", "name": "SendRequest6", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.send.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -1518,7 +1518,7 @@ "$id": "187", "kind": "model", "name": "GetResponse7", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.get.Response.anonymous", "usage": "Output,Json", "decorators": [], @@ -1551,7 +1551,7 @@ "$id": "191", "kind": "model", "name": "SendRequest7", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.send.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -1584,7 +1584,7 @@ "$id": "195", "kind": "model", "name": "GetResponse8", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.get.Response.anonymous", "usage": "Output,Json", "decorators": [], @@ -1617,7 +1617,7 @@ "$id": "199", "kind": "model", "name": "SendRequest8", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.send.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -1650,7 +1650,7 @@ "$id": "203", "kind": "model", "name": "GetResponse9", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.get.Response.anonymous", "usage": "Output,Json", "decorators": [], @@ -1683,7 +1683,7 @@ "$id": "207", "kind": "model", "name": "SendRequest9", - "clientNamespace": "Type.Union", + "namespace": "Type.Union", "crossLanguageDefinitionId": "Type.Union.send.Request.anonymous", "usage": "Spread,Json", "decorators": [], @@ -1717,7 +1717,7 @@ { "$id": "211", "Name": "UnionClient", - "ClientNamespace": "Type.Union", + "Namespace": "Type.Union", "Doc": "Describe scenarios for various combinations of unions.", "Operations": [], "Protocol": { @@ -1761,7 +1761,7 @@ { "$id": "217", "Name": "StringsOnly", - "ClientNamespace": "Type.Union", + "Namespace": "Type.Union", "Doc": "Describe union of string \"a\" | \"b\" | \"c\"", "Operations": [ { @@ -1944,7 +1944,7 @@ { "$id": "234", "Name": "StringExtensible", - "ClientNamespace": "Type.Union", + "Namespace": "Type.Union", "Doc": "Describe union of string string | \"b\" | \"c\"", "Operations": [ { @@ -2127,7 +2127,7 @@ { "$id": "251", "Name": "StringExtensibleNamed", - "ClientNamespace": "Type.Union", + "Namespace": "Type.Union", "Doc": "Describe union of string string | \"b\" | \"c\" but where the union is named and some of the variants are named", "Operations": [ { @@ -2310,7 +2310,7 @@ { "$id": "268", "Name": "IntsOnly", - "ClientNamespace": "Type.Union", + "Namespace": "Type.Union", "Doc": "Describe union of integer 1 | 2 | 3", "Operations": [ { @@ -2493,7 +2493,7 @@ { "$id": "285", "Name": "FloatsOnly", - "ClientNamespace": "Type.Union", + "Namespace": "Type.Union", "Doc": "Describe union of floats 1.1 | 2.2 | 3.3", "Operations": [ { @@ -2676,7 +2676,7 @@ { "$id": "302", "Name": "ModelsOnly", - "ClientNamespace": "Type.Union", + "Namespace": "Type.Union", "Doc": "Describe union of models", "Operations": [ { @@ -2859,7 +2859,7 @@ { "$id": "319", "Name": "EnumsOnly", - "ClientNamespace": "Type.Union", + "Namespace": "Type.Union", "Doc": "Describe union of 2 different enums", "Operations": [ { @@ -3042,7 +3042,7 @@ { "$id": "336", "Name": "StringAndArray", - "ClientNamespace": "Type.Union", + "Namespace": "Type.Union", "Doc": "Describe union of a string and an array of strings", "Operations": [ { @@ -3225,7 +3225,7 @@ { "$id": "353", "Name": "MixedLiterals", - "ClientNamespace": "Type.Union", + "Namespace": "Type.Union", "Doc": "Describe union of floats \"a\" | 2 | 3.3", "Operations": [ { @@ -3408,7 +3408,7 @@ { "$id": "370", "Name": "MixedTypes", - "ClientNamespace": "Type.Union", + "Namespace": "Type.Union", "Doc": "Describe union of floats \"a\" | 2 | 3.3", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/added/v1/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/added/v1/tspCodeModel.json index 81276fa5440..c4b8db94da0 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/added/v1/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/added/v1/tspCodeModel.json @@ -36,7 +36,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Added", + "namespace": "Versioning.Added", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -74,7 +74,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Added", + "namespace": "Versioning.Added", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -87,7 +87,7 @@ "$id": "10", "kind": "model", "name": "ModelV1", - "clientNamespace": "Versioning.Added", + "namespace": "Versioning.Added", "crossLanguageDefinitionId": "Versioning.Added.ModelV1", "usage": "Input,Output,Json", "decorators": [], @@ -147,7 +147,7 @@ { "$id": "18", "Name": "AddedClient", - "ClientNamespace": "Versioning.Added", + "Namespace": "Versioning.Added", "Doc": "Test for the `@added` decorator.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/added/v2/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/added/v2/tspCodeModel.json index d5889ae34bf..5043965791a 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/added/v2/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/added/v2/tspCodeModel.json @@ -54,7 +54,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Added", + "namespace": "Versioning.Added", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -91,7 +91,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Added", + "namespace": "Versioning.Added", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -147,7 +147,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Added", + "namespace": "Versioning.Added", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -160,7 +160,7 @@ "$id": "18", "kind": "model", "name": "ModelV1", - "clientNamespace": "Versioning.Added", + "namespace": "Versioning.Added", "crossLanguageDefinitionId": "Versioning.Added.ModelV1", "usage": "Input,Output,Json", "decorators": [], @@ -245,7 +245,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Added", + "namespace": "Versioning.Added", "decorators": [] }, "optional": false, @@ -268,7 +268,7 @@ "$id": "33", "kind": "model", "name": "ModelV2", - "clientNamespace": "Versioning.Added", + "namespace": "Versioning.Added", "crossLanguageDefinitionId": "Versioning.Added.ModelV2", "usage": "Input,Output,Json", "decorators": [], @@ -346,7 +346,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Added", + "namespace": "Versioning.Added", "decorators": [] }, "optional": false, @@ -370,7 +370,7 @@ { "$id": "47", "Name": "AddedClient", - "ClientNamespace": "Versioning.Added", + "Namespace": "Versioning.Added", "Doc": "Test for the `@added` decorator.", "Operations": [ { @@ -662,7 +662,7 @@ { "$id": "72", "Name": "InterfaceV2", - "ClientNamespace": "Versioning.Added", + "Namespace": "Versioning.Added", "Operations": [ { "$id": "73", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/madeOptional/v1/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/madeOptional/v1/tspCodeModel.json index c26dfbe62d0..49dd593b132 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/madeOptional/v1/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/madeOptional/v1/tspCodeModel.json @@ -37,7 +37,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.MadeOptional", + "namespace": "Versioning.MadeOptional", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -50,7 +50,7 @@ "$id": "6", "kind": "model", "name": "TestModel", - "clientNamespace": "Versioning.MadeOptional", + "namespace": "Versioning.MadeOptional", "crossLanguageDefinitionId": "Versioning.MadeOptional.TestModel", "usage": "Input,Output,Json", "decorators": [], @@ -114,7 +114,7 @@ { "$id": "15", "Name": "MadeOptionalClient", - "ClientNamespace": "Versioning.MadeOptional", + "Namespace": "Versioning.MadeOptional", "Doc": "Test for the `@madeOptional` decorator.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/madeOptional/v2/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/madeOptional/v2/tspCodeModel.json index 38376bbfe46..2ebbc6ade37 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/madeOptional/v2/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/madeOptional/v2/tspCodeModel.json @@ -56,7 +56,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.MadeOptional", + "namespace": "Versioning.MadeOptional", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -69,7 +69,7 @@ "$id": "8", "kind": "model", "name": "TestModel", - "clientNamespace": "Versioning.MadeOptional", + "namespace": "Versioning.MadeOptional", "crossLanguageDefinitionId": "Versioning.MadeOptional.TestModel", "usage": "Input,Output,Json", "decorators": [], @@ -133,7 +133,7 @@ { "$id": "17", "Name": "MadeOptionalClient", - "ClientNamespace": "Versioning.MadeOptional", + "Namespace": "Versioning.MadeOptional", "Doc": "Test for the `@madeOptional` decorator.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v1/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v1/tspCodeModel.json index ccda0ceb006..857e658c77e 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v1/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v1/tspCodeModel.json @@ -36,7 +36,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -90,7 +90,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -144,7 +144,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -182,7 +182,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -195,7 +195,7 @@ "$id": "22", "kind": "model", "name": "ModelV1", - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "crossLanguageDefinitionId": "Versioning.Removed.ModelV1", "usage": "Input,Output,Json", "decorators": [], @@ -273,7 +273,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "decorators": [] }, "optional": false, @@ -296,7 +296,7 @@ "$id": "36", "kind": "model", "name": "ModelV2", - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "crossLanguageDefinitionId": "Versioning.Removed.ModelV2", "usage": "Input,Output,Json", "decorators": [], @@ -414,7 +414,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "decorators": [] }, "optional": false, @@ -437,7 +437,7 @@ "$id": "56", "kind": "model", "name": "ModelV3", - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "crossLanguageDefinitionId": "Versioning.Removed.ModelV3", "usage": "Input,Output,Json", "decorators": [], @@ -497,7 +497,7 @@ { "$id": "64", "Name": "RemovedClient", - "ClientNamespace": "Versioning.Removed", + "Namespace": "Versioning.Removed", "Doc": "Test for the `@removed` decorator.", "Operations": [ { @@ -900,7 +900,7 @@ { "$id": "98", "Name": "InterfaceV1", - "ClientNamespace": "Versioning.Removed", + "Namespace": "Versioning.Removed", "Doc": "This operation group should not be generated with latest version.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v2/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v2/tspCodeModel.json index b270fe6ec88..8ccd366bf0b 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v2/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v2/tspCodeModel.json @@ -38,7 +38,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -92,7 +92,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -166,7 +166,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -179,7 +179,7 @@ "$id": "20", "kind": "model", "name": "ModelV2", - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "crossLanguageDefinitionId": "Versioning.Removed.ModelV2", "usage": "Input,Output,Json", "decorators": [], @@ -257,7 +257,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "decorators": [] }, "optional": false, @@ -280,7 +280,7 @@ "$id": "34", "kind": "model", "name": "ModelV3", - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "crossLanguageDefinitionId": "Versioning.Removed.ModelV3", "usage": "Input,Output,Json", "decorators": [], @@ -340,7 +340,7 @@ { "$id": "42", "Name": "RemovedClient", - "ClientNamespace": "Versioning.Removed", + "Namespace": "Versioning.Removed", "Doc": "Test for the `@removed` decorator.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v2Preview/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v2Preview/tspCodeModel.json index b03cdc450b9..49829380461 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v2Preview/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/removed/v2Preview/tspCodeModel.json @@ -37,7 +37,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -91,7 +91,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -147,7 +147,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -160,7 +160,7 @@ "$id": "18", "kind": "model", "name": "ModelV1", - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "crossLanguageDefinitionId": "Versioning.Removed.ModelV1", "usage": "Input,Output,Json", "decorators": [], @@ -238,7 +238,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "decorators": [] }, "optional": false, @@ -261,7 +261,7 @@ "$id": "32", "kind": "model", "name": "ModelV2", - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "crossLanguageDefinitionId": "Versioning.Removed.ModelV2", "usage": "Input,Output,Json", "decorators": [], @@ -379,7 +379,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "decorators": [] }, "optional": false, @@ -402,7 +402,7 @@ "$id": "52", "kind": "model", "name": "ModelV3", - "clientNamespace": "Versioning.Removed", + "namespace": "Versioning.Removed", "crossLanguageDefinitionId": "Versioning.Removed.ModelV3", "usage": "Input,Output,Json", "decorators": [], @@ -440,7 +440,7 @@ { "$id": "57", "Name": "RemovedClient", - "ClientNamespace": "Versioning.Removed", + "Namespace": "Versioning.Removed", "Doc": "Test for the `@removed` decorator.", "Operations": [ { @@ -843,7 +843,7 @@ { "$id": "91", "Name": "InterfaceV1", - "ClientNamespace": "Versioning.Removed", + "Namespace": "Versioning.Removed", "Doc": "This operation group should not be generated with latest version.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/renamedFrom/v1/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/renamedFrom/v1/tspCodeModel.json index 37a9d367fbc..c1c805e3e85 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/renamedFrom/v1/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/renamedFrom/v1/tspCodeModel.json @@ -36,7 +36,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.RenamedFrom", + "namespace": "Versioning.RenamedFrom", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -74,7 +74,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.RenamedFrom", + "namespace": "Versioning.RenamedFrom", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -87,7 +87,7 @@ "$id": "10", "kind": "model", "name": "OldModel", - "clientNamespace": "Versioning.RenamedFrom", + "namespace": "Versioning.RenamedFrom", "crossLanguageDefinitionId": "Versioning.RenamedFrom.OldModel", "usage": "Input,Output,Json", "decorators": [], @@ -172,7 +172,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.RenamedFrom", + "namespace": "Versioning.RenamedFrom", "decorators": [] }, "optional": false, @@ -196,7 +196,7 @@ { "$id": "25", "Name": "RenamedFromClient", - "ClientNamespace": "Versioning.RenamedFrom", + "Namespace": "Versioning.RenamedFrom", "Doc": "Test for the `@renamedFrom` decorator.", "Operations": [ { @@ -379,7 +379,7 @@ { "$id": "41", "Name": "OldInterface", - "ClientNamespace": "Versioning.RenamedFrom", + "Namespace": "Versioning.RenamedFrom", "Operations": [ { "$id": "42", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/renamedFrom/v2/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/renamedFrom/v2/tspCodeModel.json index c9c9aa0ab1b..8a8eec72fb4 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/renamedFrom/v2/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/renamedFrom/v2/tspCodeModel.json @@ -37,7 +37,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.RenamedFrom", + "namespace": "Versioning.RenamedFrom", "isFixed": true, "isFlags": false, "usage": "Input,Output,Json", @@ -93,7 +93,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.RenamedFrom", + "namespace": "Versioning.RenamedFrom", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -106,7 +106,7 @@ "$id": "12", "kind": "model", "name": "NewModel", - "clientNamespace": "Versioning.RenamedFrom", + "namespace": "Versioning.RenamedFrom", "crossLanguageDefinitionId": "Versioning.RenamedFrom.NewModel", "usage": "Input,Output,Json", "decorators": [], @@ -191,7 +191,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.RenamedFrom", + "namespace": "Versioning.RenamedFrom", "decorators": [] }, "optional": false, @@ -215,7 +215,7 @@ { "$id": "27", "Name": "RenamedFromClient", - "ClientNamespace": "Versioning.RenamedFrom", + "Namespace": "Versioning.RenamedFrom", "Doc": "Test for the `@renamedFrom` decorator.", "Operations": [ { @@ -398,7 +398,7 @@ { "$id": "43", "Name": "NewInterface", - "ClientNamespace": "Versioning.RenamedFrom", + "Namespace": "Versioning.RenamedFrom", "Operations": [ { "$id": "44", diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/returnTypeChangedFrom/v1/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/returnTypeChangedFrom/v1/tspCodeModel.json index edac8a3045e..53f248b339c 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/returnTypeChangedFrom/v1/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/returnTypeChangedFrom/v1/tspCodeModel.json @@ -37,7 +37,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.ReturnTypeChangedFrom", + "namespace": "Versioning.ReturnTypeChangedFrom", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -50,7 +50,7 @@ { "$id": "6", "Name": "ReturnTypeChangedFromClient", - "ClientNamespace": "Versioning.ReturnTypeChangedFrom", + "Namespace": "Versioning.ReturnTypeChangedFrom", "Doc": "Test for the `@returnTypeChangedFrom` decorator.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/returnTypeChangedFrom/v2/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/returnTypeChangedFrom/v2/tspCodeModel.json index 0224cbc58fa..f4425dd35c5 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/returnTypeChangedFrom/v2/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/returnTypeChangedFrom/v2/tspCodeModel.json @@ -56,7 +56,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.ReturnTypeChangedFrom", + "namespace": "Versioning.ReturnTypeChangedFrom", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -69,7 +69,7 @@ { "$id": "8", "Name": "ReturnTypeChangedFromClient", - "ClientNamespace": "Versioning.ReturnTypeChangedFrom", + "Namespace": "Versioning.ReturnTypeChangedFrom", "Doc": "Test for the `@returnTypeChangedFrom` decorator.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/typeChangedFrom/v1/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/typeChangedFrom/v1/tspCodeModel.json index efc4db662ce..5e55391396d 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/typeChangedFrom/v1/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/typeChangedFrom/v1/tspCodeModel.json @@ -37,7 +37,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.TypeChangedFrom", + "namespace": "Versioning.TypeChangedFrom", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -50,7 +50,7 @@ "$id": "6", "kind": "model", "name": "TestModel", - "clientNamespace": "Versioning.TypeChangedFrom", + "namespace": "Versioning.TypeChangedFrom", "crossLanguageDefinitionId": "Versioning.TypeChangedFrom.TestModel", "usage": "Input,Output,Json", "decorators": [], @@ -114,7 +114,7 @@ { "$id": "15", "Name": "TypeChangedFromClient", - "ClientNamespace": "Versioning.TypeChangedFrom", + "Namespace": "Versioning.TypeChangedFrom", "Doc": "Test for the `@typeChangedFrom` decorator.", "Operations": [ { diff --git a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/typeChangedFrom/v2/tspCodeModel.json b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/typeChangedFrom/v2/tspCodeModel.json index 90f4d1157e8..f817189914b 100644 --- a/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/typeChangedFrom/v2/tspCodeModel.json +++ b/packages/http-client-csharp/generator/TestProjects/Spector/http/versioning/typeChangedFrom/v2/tspCodeModel.json @@ -56,7 +56,7 @@ "decorators": [] } ], - "clientNamespace": "Versioning.TypeChangedFrom", + "namespace": "Versioning.TypeChangedFrom", "doc": "The version of the API.", "isFixed": true, "isFlags": false, @@ -69,7 +69,7 @@ "$id": "8", "kind": "model", "name": "TestModel", - "clientNamespace": "Versioning.TypeChangedFrom", + "namespace": "Versioning.TypeChangedFrom", "crossLanguageDefinitionId": "Versioning.TypeChangedFrom.TestModel", "usage": "Input,Output,Json", "decorators": [], @@ -133,7 +133,7 @@ { "$id": "17", "Name": "TypeChangedFromClient", - "ClientNamespace": "Versioning.TypeChangedFrom", + "Namespace": "Versioning.TypeChangedFrom", "Doc": "Test for the `@typeChangedFrom` decorator.", "Operations": [ { diff --git a/packages/http-client-csharp/package-lock.json b/packages/http-client-csharp/package-lock.json index 9b6b125c2bf..65545c1c1e7 100644 --- a/packages/http-client-csharp/package-lock.json +++ b/packages/http-client-csharp/package-lock.json @@ -15,7 +15,7 @@ "devDependencies": { "@azure-tools/azure-http-specs": "0.1.0-alpha.6", "@azure-tools/typespec-azure-core": "0.51.0", - "@azure-tools/typespec-client-generator-core": "0.51.1", + "@azure-tools/typespec-client-generator-core": "0.51.3", "@microsoft/api-extractor": "^7.47.11", "@types/node": "~22.7.5", "@typespec/compiler": "0.65.0", @@ -94,9 +94,9 @@ } }, "node_modules/@azure-tools/typespec-client-generator-core": { - "version": "0.51.1", - "resolved": "https://registry.npmjs.org/@azure-tools/typespec-client-generator-core/-/typespec-client-generator-core-0.51.1.tgz", - "integrity": "sha512-FkkH6RWQpIXsug1egIcjZP4/9slGyFxJsKzVqpgvMoZDYfl+6dYfQkesmpTJx1SB96VHyI1SPz2Wk6MLoeuTXQ==", + "version": "0.51.3", + "resolved": "https://registry.npmjs.org/@azure-tools/typespec-client-generator-core/-/typespec-client-generator-core-0.51.3.tgz", + "integrity": "sha512-gwHpnZsUdfJAiJ3vlLzZeBQB/2Z/CKvL8144v9mOBuqrTnF4NVr+KWahFY6GrH+5/2gWxcVVKBYsGOS6eTdKuA==", "dev": true, "license": "MIT", "dependencies": { diff --git a/packages/http-client-csharp/package.json b/packages/http-client-csharp/package.json index 158ff9da956..e0df6cf0207 100644 --- a/packages/http-client-csharp/package.json +++ b/packages/http-client-csharp/package.json @@ -59,7 +59,7 @@ "devDependencies": { "@azure-tools/azure-http-specs": "0.1.0-alpha.6", "@azure-tools/typespec-azure-core": "0.51.0", - "@azure-tools/typespec-client-generator-core": "0.51.1", + "@azure-tools/typespec-client-generator-core": "0.51.3", "@microsoft/api-extractor": "^7.47.11", "@types/node": "~22.7.5", "@typespec/compiler": "0.65.0",