diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-client-generator-core-alternate-type/specs/azure/clientgenerator/core/alternatetype/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-client-generator-core-alternate-type/specs/azure/clientgenerator/core/alternatetype/types.py index d804ba96d0c9..9e3c4d762f93 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-client-generator-core-alternate-type/specs/azure/clientgenerator/core/alternatetype/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-client-generator-core-alternate-type/specs/azure/clientgenerator/core/alternatetype/types.py @@ -11,21 +11,6 @@ import geojson -class Geometry(TypedDict, total=False): - """Geometry. - - :ivar type: Required. - :vartype type: str - :ivar coordinates: Required. - :vartype coordinates: list[float] - """ - - type: Required[str] - """Required.""" - coordinates: Required[list[float]] - """Required.""" - - class ModelWithFeatureProperty(TypedDict, total=False): """ModelWithFeatureProperty. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-client-generator-core-client-initialization-default/specs/azure/clientgenerator/core/clientinitialization/default/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-client-generator-core-client-initialization-default/specs/azure/clientgenerator/core/clientinitialization/default/types.py index b617a28d9cf5..e4aead5fb51a 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-client-generator-core-client-initialization-default/specs/azure/clientgenerator/core/clientinitialization/default/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-client-generator-core-client-initialization-default/specs/azure/clientgenerator/core/clientinitialization/default/types.py @@ -9,29 +9,6 @@ from typing_extensions import Required, TypedDict -class BlobProperties(TypedDict, total=False): - """Properties of a blob. - - :ivar name: Required. - :vartype name: str - :ivar size: Required. - :vartype size: int - :ivar content_type: Required. - :vartype content_type: str - :ivar created_on: Required. - :vartype created_on: str - """ - - name: Required[str] - """Required.""" - size: Required[int] - """Required.""" - contentType: Required[str] - """Required.""" - createdOn: Required[str] - """Required.""" - - class Input(TypedDict, total=False): """Input. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-basic/specs/azure/core/basic/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-basic/specs/azure/core/basic/types.py index b32887ac4217..800050fd9bb3 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-basic/specs/azure/core/basic/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-basic/specs/azure/core/basic/types.py @@ -32,17 +32,6 @@ class User(TypedDict, total=False): """The entity tag for this resource. Required.""" -class UserList(TypedDict, total=False): - """UserList. - - :ivar users: Required. - :vartype users: list["User"] - """ - - users: Required[list["User"]] - """Required.""" - - class UserOrder(TypedDict, total=False): """UserOrder for testing list with expand. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-lro-rpc/specs/azure/core/lro/rpc/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-lro-rpc/specs/azure/core/lro/rpc/types.py index 9b3bc6f4e284..d4103fdfd8aa 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-lro-rpc/specs/azure/core/lro/rpc/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-lro-rpc/specs/azure/core/lro/rpc/types.py @@ -18,14 +18,3 @@ class GenerationOptions(TypedDict, total=False): prompt: Required[str] """Prompt. Required.""" - - -class GenerationResult(TypedDict, total=False): - """Result of the generation. - - :ivar data: The data. Required. - :vartype data: str - """ - - data: Required[str] - """The data. Required.""" diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-lro-standard/specs/azure/core/lro/standard/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-lro-standard/specs/azure/core/lro/standard/types.py index a0844fed0b43..fabef8da10d4 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-lro-standard/specs/azure/core/lro/standard/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-lro-standard/specs/azure/core/lro/standard/types.py @@ -9,21 +9,6 @@ from typing_extensions import Required, TypedDict -class ExportedUser(TypedDict, total=False): - """The exported user data. - - :ivar name: The name of user. Required. - :vartype name: str - :ivar resource_uri: The exported URI. Required. - :vartype resource_uri: str - """ - - name: Required[str] - """The name of user. Required.""" - resourceUri: Required[str] - """The exported URI. Required.""" - - class User(TypedDict, total=False): """Details about a user. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-page/specs/azure/core/page/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-page/specs/azure/core/page/types.py index a37ffad62a75..f6015f524854 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-page/specs/azure/core/page/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-page/specs/azure/core/page/types.py @@ -9,17 +9,6 @@ from typing_extensions import Required, TypedDict -class FirstItem(TypedDict, total=False): - """First item. - - :ivar id: The id of the item. Required. - :vartype id: int - """ - - id: Required[int] - """The id of the item. Required.""" - - class ListItemInputBody(TypedDict, total=False): """The body of the input. @@ -29,56 +18,3 @@ class ListItemInputBody(TypedDict, total=False): inputName: Required[str] """The name of the input. Required.""" - - -class SecondItem(TypedDict, total=False): - """Second item. - - :ivar name: The name of the item. Required. - :vartype name: str - """ - - name: Required[str] - """The name of the item. Required.""" - - -class User(TypedDict, total=False): - """Details about a user. - - :ivar id: The user's id. Required. - :vartype id: int - :ivar name: The user's name. Required. - :vartype name: str - :ivar orders: The user's order list. - :vartype orders: list["UserOrder"] - :ivar etag: The entity tag for this resource. Required. - :vartype etag: str - """ - - id: Required[int] - """The user's id. Required.""" - name: Required[str] - """The user's name. Required.""" - orders: list["UserOrder"] - """The user's order list.""" - etag: Required[str] - """The entity tag for this resource. Required.""" - - -class UserOrder(TypedDict, total=False): - """UserOrder for testing list with expand. - - :ivar id: The user's id. Required. - :vartype id: int - :ivar user_id: The user's id. Required. - :vartype user_id: int - :ivar detail: The user's order detail. Required. - :vartype detail: str - """ - - id: Required[int] - """The user's id. Required.""" - userId: Required[int] - """The user's id. Required.""" - detail: Required[str] - """The user's order detail. Required.""" diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-traits/specs/azure/core/traits/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-traits/specs/azure/core/traits/types.py index 321efad9915b..e8a00e58e0c2 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-traits/specs/azure/core/traits/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-core-traits/specs/azure/core/traits/types.py @@ -9,21 +9,6 @@ from typing_extensions import Required, TypedDict -class User(TypedDict, total=False): - """Sample Model. - - :ivar id: The user's id. Required. - :vartype id: int - :ivar name: The user's name. - :vartype name: str - """ - - id: Required[int] - """The user's id. Required.""" - name: str - """The user's name.""" - - class UserActionParam(TypedDict, total=False): """User action param. @@ -33,14 +18,3 @@ class UserActionParam(TypedDict, total=False): userActionValue: Required[str] """User action value. Required.""" - - -class UserActionResponse(TypedDict, total=False): - """User action response. - - :ivar user_action_result: User action result. Required. - :vartype user_action_result: str - """ - - userActionResult: Required[str] - """User action result. Required.""" diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-example-basic/specs/azure/example/basic/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-example-basic/specs/azure/example/basic/types.py index 2c952a8cc58a..4a6f425a2a94 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-example-basic/specs/azure/example/basic/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-example-basic/specs/azure/example/basic/types.py @@ -33,26 +33,6 @@ class ActionRequest(TypedDict, total=False): recordProperty: dict[str, str] -class ActionResponse(TypedDict, total=False): - """ActionResponse. - - :ivar string_property: Required. - :vartype string_property: str - :ivar model_property: - :vartype model_property: "Model" - :ivar array_property: - :vartype array_property: list[str] - :ivar record_property: - :vartype record_property: dict[str, str] - """ - - stringProperty: Required[str] - """Required.""" - modelProperty: "Model" - arrayProperty: list[str] - recordProperty: dict[str, str] - - class Model(TypedDict, total=False): """Model. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-common-properties/azure/resourcemanager/commonproperties/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-common-properties/azure/resourcemanager/commonproperties/types.py index 08c91a739631..a0aecd3340fd 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-common-properties/azure/resourcemanager/commonproperties/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-common-properties/azure/resourcemanager/commonproperties/types.py @@ -7,59 +7,13 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any, TYPE_CHECKING, Union +from typing import TYPE_CHECKING, Union from typing_extensions import Required, TypedDict if TYPE_CHECKING: from .models import CreatedByType, ManagedServiceIdentityType, ResourceProvisioningState -class ApiError(TypedDict, total=False): - """Api error. - - :ivar details: The Api error details. - :vartype details: list["ApiErrorBase"] - :ivar innererror: The Api inner error. - :vartype innererror: "InnerError" - :ivar code: The error code. - :vartype code: str - :ivar target: The target of the particular error. - :vartype target: str - :ivar message: The error message. - :vartype message: str - """ - - details: list["ApiErrorBase"] - """The Api error details.""" - innererror: "InnerError" - """The Api inner error.""" - code: str - """The error code.""" - target: str - """The target of the particular error.""" - message: str - """The error message.""" - - -class ApiErrorBase(TypedDict, total=False): - """Api error base. - - :ivar code: The error code. - :vartype code: str - :ivar target: The target of the particular error. - :vartype target: str - :ivar message: The error message. - :vartype message: str - """ - - code: str - """The error code.""" - target: str - """The target of the particular error.""" - message: str - """The error message.""" - - class Resource(TypedDict, total=False): """Resource. @@ -170,17 +124,6 @@ class ArmResourceIdentifierResourceProperties(TypedDict, total=False): """An ARM resource identifier with all scopes. Required.""" -class CloudError(TypedDict, total=False): - """An error response. - - :ivar error: Api error. - :vartype error: "ApiError" - """ - - error: "ApiError" - """Api error.""" - - class ConfidentialResource(TrackedResource): """Concrete tracked resource types can be created by aliasing this type using a specific property type. @@ -223,74 +166,6 @@ class ConfidentialResourceProperties(TypedDict, total=False): """Required.""" -class ErrorAdditionalInfo(TypedDict, total=False): - """The resource management error additional info. - - :ivar type: The additional info type. - :vartype type: str - :ivar info: The additional info. - :vartype info: Any - """ - - type: str - """The additional info type.""" - info: Any - """The additional info.""" - - -class ErrorDetail(TypedDict, total=False): - """The error detail. - - :ivar code: The error code. - :vartype code: str - :ivar message: The error message. - :vartype message: str - :ivar target: The error target. - :vartype target: str - :ivar details: The error details. - :vartype details: list["ErrorDetail"] - :ivar additional_info: The error additional info. - :vartype additional_info: list["ErrorAdditionalInfo"] - """ - - code: str - """The error code.""" - message: str - """The error message.""" - target: str - """The error target.""" - details: list["ErrorDetail"] - """The error details.""" - additionalInfo: list["ErrorAdditionalInfo"] - """The error additional info.""" - - -class ErrorResponse(TypedDict, total=False): - """Error response. - - :ivar error: The error object. - :vartype error: "ErrorDetail" - """ - - error: "ErrorDetail" - """The error object.""" - - -class InnerError(TypedDict, total=False): - """Inner error details. - - :ivar exceptiontype: The exception type. - :vartype exceptiontype: str - :ivar errordetail: The internal error message or exception dump. - :vartype errordetail: str - """ - - exceptiontype: str - """The exception type.""" - errordetail: str - """The internal error message or exception dump.""" - - class ManagedIdentityTrackedResource(TrackedResource): """Concrete tracked resource types can be created by aliasing this type using a specific property type. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-management-group/azure/resourcemanager/managementgroup/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-management-group/azure/resourcemanager/managementgroup/types.py index 20fae1245dd6..58e629254007 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-management-group/azure/resourcemanager/managementgroup/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-management-group/azure/resourcemanager/managementgroup/types.py @@ -7,66 +7,13 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any, TYPE_CHECKING, Union +from typing import TYPE_CHECKING, Union from typing_extensions import TypedDict if TYPE_CHECKING: from .models import CreatedByType, ProvisioningState -class ErrorAdditionalInfo(TypedDict, total=False): - """The resource management error additional info. - - :ivar type: The additional info type. - :vartype type: str - :ivar info: The additional info. - :vartype info: Any - """ - - type: str - """The additional info type.""" - info: Any - """The additional info.""" - - -class ErrorDetail(TypedDict, total=False): - """The error detail. - - :ivar code: The error code. - :vartype code: str - :ivar message: The error message. - :vartype message: str - :ivar target: The error target. - :vartype target: str - :ivar details: The error details. - :vartype details: list["ErrorDetail"] - :ivar additional_info: The error additional info. - :vartype additional_info: list["ErrorAdditionalInfo"] - """ - - code: str - """The error code.""" - message: str - """The error message.""" - target: str - """The error target.""" - details: list["ErrorDetail"] - """The error details.""" - additionalInfo: list["ErrorAdditionalInfo"] - """The error additional info.""" - - -class ErrorResponse(TypedDict, total=False): - """Error response. - - :ivar error: The error object. - :vartype error: "ErrorDetail" - """ - - error: "ErrorDetail" - """The error object.""" - - class Resource(TypedDict, total=False): """Resource. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-method-subscription-id/azure/resourcemanager/methodsubscriptionid/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-method-subscription-id/azure/resourcemanager/methodsubscriptionid/types.py index 24e3a04c0427..c49dd0de397e 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-method-subscription-id/azure/resourcemanager/methodsubscriptionid/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-method-subscription-id/azure/resourcemanager/methodsubscriptionid/types.py @@ -7,133 +7,11 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any, TYPE_CHECKING, Union +from typing import TYPE_CHECKING, Union from typing_extensions import Required, TypedDict if TYPE_CHECKING: - from .models import ActionType, CreatedByType, Origin, ResourceProvisioningState - - -class ErrorAdditionalInfo(TypedDict, total=False): - """The resource management error additional info. - - :ivar type: The additional info type. - :vartype type: str - :ivar info: The additional info. - :vartype info: Any - """ - - type: str - """The additional info type.""" - info: Any - """The additional info.""" - - -class ErrorDetail(TypedDict, total=False): - """The error detail. - - :ivar code: The error code. - :vartype code: str - :ivar message: The error message. - :vartype message: str - :ivar target: The error target. - :vartype target: str - :ivar details: The error details. - :vartype details: list["ErrorDetail"] - :ivar additional_info: The error additional info. - :vartype additional_info: list["ErrorAdditionalInfo"] - """ - - code: str - """The error code.""" - message: str - """The error message.""" - target: str - """The error target.""" - details: list["ErrorDetail"] - """The error details.""" - additionalInfo: list["ErrorAdditionalInfo"] - """The error additional info.""" - - -class ErrorResponse(TypedDict, total=False): - """Error response. - - :ivar error: The error object. - :vartype error: "ErrorDetail" - """ - - error: "ErrorDetail" - """The error object.""" - - -class Operation(TypedDict, total=False): - """REST API Operation. - - :ivar name: The name of the operation, as per Resource-Based Access Control (RBAC). Examples: - "Microsoft.Compute/virtualMachines/write", "Microsoft.Compute/virtualMachines/capture/action". - :vartype name: str - :ivar is_data_action: Whether the operation applies to data-plane. This is "true" for - data-plane operations and "false" for Azure Resource Manager/control-plane operations. - :vartype is_data_action: bool - :ivar display: Localized display information for this particular operation. - :vartype display: "OperationDisplay" - :ivar origin: The intended executor of the operation; as in Resource Based Access Control - (RBAC) and audit logs UX. Default value is "user,system". Known values are: "user", "system", - and "user,system". - :vartype origin: Union[str, "Origin"] - :ivar action_type: Extensible enum. Indicates the action type. "Internal" refers to actions - that are for internal only APIs. "Internal" - :vartype action_type: Union[str, "ActionType"] - """ - - name: str - """The name of the operation, as per Resource-Based Access Control (RBAC). Examples: - \"Microsoft.Compute/virtualMachines/write\", - \"Microsoft.Compute/virtualMachines/capture/action\".""" - isDataAction: bool - """Whether the operation applies to data-plane. This is \"true\" for data-plane operations and - \"false\" for Azure Resource Manager/control-plane operations.""" - display: "OperationDisplay" - """Localized display information for this particular operation.""" - origin: Union[str, "Origin"] - """The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit - logs UX. Default value is \"user,system\". Known values are: \"user\", \"system\", and - \"user,system\".""" - actionType: Union[str, "ActionType"] - """Extensible enum. Indicates the action type. \"Internal\" refers to actions that are for - internal only APIs. \"Internal\"""" - - -class OperationDisplay(TypedDict, total=False): - """Localized display information for an operation. - - :ivar provider: The localized friendly form of the resource provider name, e.g. "Microsoft - Monitoring Insights" or "Microsoft Compute". - :vartype provider: str - :ivar resource: The localized friendly name of the resource type related to this operation. - E.g. "Virtual Machines" or "Job Schedule Collections". - :vartype resource: str - :ivar operation: The concise, localized friendly name for the operation; suitable for - dropdowns. E.g. "Create or Update Virtual Machine", "Restart Virtual Machine". - :vartype operation: str - :ivar description: The short, localized friendly description of the operation; suitable for - tool tips and detailed views. - :vartype description: str - """ - - provider: str - """The localized friendly form of the resource provider name, e.g. \"Microsoft Monitoring - Insights\" or \"Microsoft Compute\".""" - resource: str - """The localized friendly name of the resource type related to this operation. E.g. \"Virtual - Machines\" or \"Job Schedule Collections\".""" - operation: str - """The concise, localized friendly name for the operation; suitable for dropdowns. E.g. \"Create - or Update Virtual Machine\", \"Restart Virtual Machine\".""" - description: str - """The short, localized friendly description of the operation; suitable for tool tips and detailed - views.""" + from .models import CreatedByType, ResourceProvisioningState class Resource(TypedDict, total=False): diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-multi-service-shared-models/azure/resourcemanager/multiservicesharedmodels/combined/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-multi-service-shared-models/azure/resourcemanager/multiservicesharedmodels/combined/types.py index 8752191e1531..cfd5f1dea6ee 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-multi-service-shared-models/azure/resourcemanager/multiservicesharedmodels/combined/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-multi-service-shared-models/azure/resourcemanager/multiservicesharedmodels/combined/types.py @@ -7,66 +7,13 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any, TYPE_CHECKING, Union +from typing import TYPE_CHECKING, Union from typing_extensions import Required, TypedDict if TYPE_CHECKING: from .models import CreatedByType, ResourceProvisioningState -class ErrorAdditionalInfo(TypedDict, total=False): - """The resource management error additional info. - - :ivar type: The additional info type. - :vartype type: str - :ivar info: The additional info. - :vartype info: Any - """ - - type: str - """The additional info type.""" - info: Any - """The additional info.""" - - -class ErrorDetail(TypedDict, total=False): - """The error detail. - - :ivar code: The error code. - :vartype code: str - :ivar message: The error message. - :vartype message: str - :ivar target: The error target. - :vartype target: str - :ivar details: The error details. - :vartype details: list["ErrorDetail"] - :ivar additional_info: The error additional info. - :vartype additional_info: list["ErrorAdditionalInfo"] - """ - - code: str - """The error code.""" - message: str - """The error message.""" - target: str - """The error target.""" - details: list["ErrorDetail"] - """The error details.""" - additionalInfo: list["ErrorAdditionalInfo"] - """The error additional info.""" - - -class ErrorResponse(TypedDict, total=False): - """Error response. - - :ivar error: The error object. - :vartype error: "ErrorDetail" - """ - - error: "ErrorDetail" - """The error object.""" - - class Resource(TypedDict, total=False): """Resource. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-multi-service/azure/resourcemanager/multiservice/combined/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-multi-service/azure/resourcemanager/multiservice/combined/types.py index be6fb6ccb479..75eaafa3ec8a 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-multi-service/azure/resourcemanager/multiservice/combined/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-multi-service/azure/resourcemanager/multiservice/combined/types.py @@ -7,7 +7,7 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any, TYPE_CHECKING, Union +from typing import TYPE_CHECKING, Union from typing_extensions import Required, TypedDict if TYPE_CHECKING: @@ -105,59 +105,6 @@ class DiskProperties(TypedDict, total=False): """Known values are: \"Succeeded\", \"Failed\", and \"Canceled\".""" -class ErrorAdditionalInfo(TypedDict, total=False): - """The resource management error additional info. - - :ivar type: The additional info type. - :vartype type: str - :ivar info: The additional info. - :vartype info: Any - """ - - type: str - """The additional info type.""" - info: Any - """The additional info.""" - - -class ErrorDetail(TypedDict, total=False): - """The error detail. - - :ivar code: The error code. - :vartype code: str - :ivar message: The error message. - :vartype message: str - :ivar target: The error target. - :vartype target: str - :ivar details: The error details. - :vartype details: list["ErrorDetail"] - :ivar additional_info: The error additional info. - :vartype additional_info: list["ErrorAdditionalInfo"] - """ - - code: str - """The error code.""" - message: str - """The error message.""" - target: str - """The error target.""" - details: list["ErrorDetail"] - """The error details.""" - additionalInfo: list["ErrorAdditionalInfo"] - """The error additional info.""" - - -class ErrorResponse(TypedDict, total=False): - """Error response. - - :ivar error: The error object. - :vartype error: "ErrorDetail" - """ - - error: "ErrorDetail" - """The error object.""" - - class SystemData(TypedDict, total=False): """Metadata pertaining to creation and last modification of the resource. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-non-resource/azure/resourcemanager/nonresource/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-non-resource/azure/resourcemanager/nonresource/types.py index 98f12ab04840..271a06d17b83 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-non-resource/azure/resourcemanager/nonresource/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-non-resource/azure/resourcemanager/nonresource/types.py @@ -6,63 +6,9 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any from typing_extensions import TypedDict -class ErrorAdditionalInfo(TypedDict, total=False): - """The resource management error additional info. - - :ivar type: The additional info type. - :vartype type: str - :ivar info: The additional info. - :vartype info: Any - """ - - type: str - """The additional info type.""" - info: Any - """The additional info.""" - - -class ErrorDetail(TypedDict, total=False): - """The error detail. - - :ivar code: The error code. - :vartype code: str - :ivar message: The error message. - :vartype message: str - :ivar target: The error target. - :vartype target: str - :ivar details: The error details. - :vartype details: list["ErrorDetail"] - :ivar additional_info: The error additional info. - :vartype additional_info: list["ErrorAdditionalInfo"] - """ - - code: str - """The error code.""" - message: str - """The error message.""" - target: str - """The error target.""" - details: list["ErrorDetail"] - """The error details.""" - additionalInfo: list["ErrorAdditionalInfo"] - """The error additional info.""" - - -class ErrorResponse(TypedDict, total=False): - """Error response. - - :ivar error: The error object. - :vartype error: "ErrorDetail" - """ - - error: "ErrorDetail" - """The error object.""" - - class NonResource(TypedDict, total=False): """Though this model has ``id``, ``name``, ``type`` properties, it is not a resource as it doesn't extends ``Resource``. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-operation-templates/azure/resourcemanager/operationtemplates/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-operation-templates/azure/resourcemanager/operationtemplates/types.py index f988c0b9954b..88067776a6ee 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-operation-templates/azure/resourcemanager/operationtemplates/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-operation-templates/azure/resourcemanager/operationtemplates/types.py @@ -7,11 +7,11 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any, TYPE_CHECKING, Union +from typing import TYPE_CHECKING, Union from typing_extensions import Required, TypedDict if TYPE_CHECKING: - from .models import ActionType, CheckNameAvailabilityReason, CreatedByType, Origin + from .models import CreatedByType class ActionRequest(TypedDict, total=False): @@ -29,17 +29,6 @@ class ActionRequest(TypedDict, total=False): """Additional action parameters.""" -class ActionResult(TypedDict, total=False): - """ActionResult. - - :ivar result: The result of the action. Required. - :vartype result: str - """ - - result: Required[str] - """The result of the action. Required.""" - - class ChangeAllowanceRequest(TypedDict, total=False): """ChangeAllowanceRequest. @@ -55,21 +44,6 @@ class ChangeAllowanceRequest(TypedDict, total=False): """The reason for the change.""" -class ChangeAllowanceResult(TypedDict, total=False): - """ChangeAllowanceResult. - - :ivar total_allowed: The new total allowed widgets. Required. - :vartype total_allowed: int - :ivar status: The status of the change. Required. - :vartype status: str - """ - - totalAllowed: Required[int] - """The new total allowed widgets. Required.""" - status: Required[str] - """The status of the change. Required.""" - - class CheckNameAvailabilityRequest(TypedDict, total=False): """The check availability request body. @@ -85,80 +59,6 @@ class CheckNameAvailabilityRequest(TypedDict, total=False): """The resource type.""" -class CheckNameAvailabilityResponse(TypedDict, total=False): - """The check availability result. - - :ivar name_available: Indicates if the resource name is available. - :vartype name_available: bool - :ivar reason: The reason why the given name is not available. Known values are: "Invalid" and - "AlreadyExists". - :vartype reason: Union[str, "CheckNameAvailabilityReason"] - :ivar message: Detailed reason why the given name is not available. - :vartype message: str - """ - - nameAvailable: bool - """Indicates if the resource name is available.""" - reason: Union[str, "CheckNameAvailabilityReason"] - """The reason why the given name is not available. Known values are: \"Invalid\" and - \"AlreadyExists\".""" - message: str - """Detailed reason why the given name is not available.""" - - -class ErrorAdditionalInfo(TypedDict, total=False): - """The resource management error additional info. - - :ivar type: The additional info type. - :vartype type: str - :ivar info: The additional info. - :vartype info: Any - """ - - type: str - """The additional info type.""" - info: Any - """The additional info.""" - - -class ErrorDetail(TypedDict, total=False): - """The error detail. - - :ivar code: The error code. - :vartype code: str - :ivar message: The error message. - :vartype message: str - :ivar target: The error target. - :vartype target: str - :ivar details: The error details. - :vartype details: list["ErrorDetail"] - :ivar additional_info: The error additional info. - :vartype additional_info: list["ErrorAdditionalInfo"] - """ - - code: str - """The error code.""" - message: str - """The error message.""" - target: str - """The error target.""" - details: list["ErrorDetail"] - """The error details.""" - additionalInfo: list["ErrorAdditionalInfo"] - """The error additional info.""" - - -class ErrorResponse(TypedDict, total=False): - """Error response. - - :ivar error: The error object. - :vartype error: "ErrorDetail" - """ - - error: "ErrorDetail" - """The error object.""" - - class ExportRequest(TypedDict, total=False): """ExportRequest. @@ -170,86 +70,6 @@ class ExportRequest(TypedDict, total=False): """Format of the exported order. Required.""" -class ExportResult(TypedDict, total=False): - """ExportResult. - - :ivar content: Content of the exported order. Required. - :vartype content: str - """ - - content: Required[str] - """Content of the exported order. Required.""" - - -class Operation(TypedDict, total=False): - """REST API Operation. - - :ivar name: The name of the operation, as per Resource-Based Access Control (RBAC). Examples: - "Microsoft.Compute/virtualMachines/write", "Microsoft.Compute/virtualMachines/capture/action". - :vartype name: str - :ivar is_data_action: Whether the operation applies to data-plane. This is "true" for - data-plane operations and "false" for Azure Resource Manager/control-plane operations. - :vartype is_data_action: bool - :ivar display: Localized display information for this particular operation. - :vartype display: "OperationDisplay" - :ivar origin: The intended executor of the operation; as in Resource Based Access Control - (RBAC) and audit logs UX. Default value is "user,system". Known values are: "user", "system", - and "user,system". - :vartype origin: Union[str, "Origin"] - :ivar action_type: Extensible enum. Indicates the action type. "Internal" refers to actions - that are for internal only APIs. "Internal" - :vartype action_type: Union[str, "ActionType"] - """ - - name: str - """The name of the operation, as per Resource-Based Access Control (RBAC). Examples: - \"Microsoft.Compute/virtualMachines/write\", - \"Microsoft.Compute/virtualMachines/capture/action\".""" - isDataAction: bool - """Whether the operation applies to data-plane. This is \"true\" for data-plane operations and - \"false\" for Azure Resource Manager/control-plane operations.""" - display: "OperationDisplay" - """Localized display information for this particular operation.""" - origin: Union[str, "Origin"] - """The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit - logs UX. Default value is \"user,system\". Known values are: \"user\", \"system\", and - \"user,system\".""" - actionType: Union[str, "ActionType"] - """Extensible enum. Indicates the action type. \"Internal\" refers to actions that are for - internal only APIs. \"Internal\"""" - - -class OperationDisplay(TypedDict, total=False): - """Localized display information for an operation. - - :ivar provider: The localized friendly form of the resource provider name, e.g. "Microsoft - Monitoring Insights" or "Microsoft Compute". - :vartype provider: str - :ivar resource: The localized friendly name of the resource type related to this operation. - E.g. "Virtual Machines" or "Job Schedule Collections". - :vartype resource: str - :ivar operation: The concise, localized friendly name for the operation; suitable for - dropdowns. E.g. "Create or Update Virtual Machine", "Restart Virtual Machine". - :vartype operation: str - :ivar description: The short, localized friendly description of the operation; suitable for - tool tips and detailed views. - :vartype description: str - """ - - provider: str - """The localized friendly form of the resource provider name, e.g. \"Microsoft Monitoring - Insights\" or \"Microsoft Compute\".""" - resource: str - """The localized friendly name of the resource type related to this operation. E.g. \"Virtual - Machines\" or \"Job Schedule Collections\".""" - operation: str - """The concise, localized friendly name for the operation; suitable for dropdowns. E.g. \"Create - or Update Virtual Machine\", \"Restart Virtual Machine\".""" - description: str - """The short, localized friendly description of the operation; suitable for tool tips and detailed - views.""" - - class Resource(TypedDict, total=False): """Resource. @@ -350,48 +170,6 @@ class OrderProperties(TypedDict, total=False): """The provisioning state of the product.""" -class Product(TrackedResource): - """Concrete tracked resource types can be created by aliasing this type using a specific property - type. - - :ivar id: Fully qualified resource ID for the resource. Ex - - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. - :vartype id: str - :ivar name: The name of the resource. - :vartype name: str - :ivar type: The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or - "Microsoft.Storage/storageAccounts". - :vartype type: str - :ivar system_data: Azure Resource Manager metadata containing createdBy and modifiedBy - information. - :vartype system_data: "SystemData" - :ivar tags: Resource tags. - :vartype tags: dict[str, str] - :ivar location: The geo-location where the resource lives. Required. - :vartype location: str - :ivar properties: The resource-specific properties for this resource. - :vartype properties: "ProductProperties" - """ - - properties: "ProductProperties" - """The resource-specific properties for this resource.""" - - -class ProductProperties(TypedDict, total=False): - """ProductProperties. - - :ivar product_id: The product ID. - :vartype product_id: str - :ivar provisioning_state: The provisioning state of the product. - :vartype provisioning_state: str - """ - - productId: str - """The product ID.""" - provisioningState: str - """The provisioning state of the product.""" - - class SystemData(TypedDict, total=False): """Metadata pertaining to creation and last modification of the resource. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-resources/azure/resourcemanager/resources/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-resources/azure/resourcemanager/resources/types.py index 473d20956232..1bff7dd074cb 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-resources/azure/resourcemanager/resources/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-resource-manager-resources/azure/resourcemanager/resources/types.py @@ -7,66 +7,13 @@ # Changes may cause incorrect behavior and will be lost if the code is regenerated. # -------------------------------------------------------------------------- -from typing import Any, TYPE_CHECKING, Union +from typing import TYPE_CHECKING, Union from typing_extensions import Required, TypedDict if TYPE_CHECKING: from .models import CreatedByType, ProvisioningState -class ErrorAdditionalInfo(TypedDict, total=False): - """The resource management error additional info. - - :ivar type: The additional info type. - :vartype type: str - :ivar info: The additional info. - :vartype info: Any - """ - - type: str - """The additional info type.""" - info: Any - """The additional info.""" - - -class ErrorDetail(TypedDict, total=False): - """The error detail. - - :ivar code: The error code. - :vartype code: str - :ivar message: The error message. - :vartype message: str - :ivar target: The error target. - :vartype target: str - :ivar details: The error details. - :vartype details: list["ErrorDetail"] - :ivar additional_info: The error additional info. - :vartype additional_info: list["ErrorAdditionalInfo"] - """ - - code: str - """The error code.""" - message: str - """The error message.""" - target: str - """The error target.""" - details: list["ErrorDetail"] - """The error details.""" - additionalInfo: list["ErrorAdditionalInfo"] - """The error additional info.""" - - -class ErrorResponse(TypedDict, total=False): - """Error response. - - :ivar error: The error object. - :vartype error: "ErrorDetail" - """ - - error: "ErrorDetail" - """The error object.""" - - class Resource(TypedDict, total=False): """Resource. diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-versioning-previewversion/specs/azure/versioning/previewversion/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-versioning-previewversion/specs/azure/versioning/previewversion/types.py index c3fada4c37a4..ca44b4e03a8a 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-versioning-previewversion/specs/azure/versioning/previewversion/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/azure-versioning-previewversion/specs/azure/versioning/previewversion/types.py @@ -9,17 +9,6 @@ from typing_extensions import Required, TypedDict -class ListWidgetsResponse(TypedDict, total=False): - """ListWidgetsResponse. - - :ivar widgets: Required. - :vartype widgets: list["Widget"] - """ - - widgets: Required[list["Widget"]] - """Required.""" - - class UpdateWidgetColorRequest(TypedDict, total=False): """Update widget color request. @@ -29,22 +18,3 @@ class UpdateWidgetColorRequest(TypedDict, total=False): color: Required[str] """New color for the widget. Required.""" - - -class Widget(TypedDict, total=False): - """A simple model for testing. - - :ivar id: Widget identifier. Required. - :vartype id: str - :ivar name: Widget name. Required. - :vartype name: str - :ivar color: Widget color, only available in preview version. - :vartype color: str - """ - - id: Required[str] - """Widget identifier. Required.""" - name: Required[str] - """Widget name. Required.""" - color: str - """Widget color, only available in preview version.""" diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-empty/typetest/model/empty/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-empty/typetest/model/empty/types.py index 1ecc1c8a331c..695b50c067bb 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-empty/typetest/model/empty/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-empty/typetest/model/empty/types.py @@ -15,7 +15,3 @@ class EmptyInput(TypedDict, total=False): class EmptyInputOutput(TypedDict, total=False): """Empty model used in both parameter and return type.""" - - -class EmptyOutput(TypedDict, total=False): - """Empty model used in operation return type.""" diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-singlediscriminator-typeddict/typetest/model/singlediscriminator/typeddict/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-singlediscriminator-typeddict/typetest/model/singlediscriminator/typeddict/types.py index eebc5e7be505..d8602e6ed87c 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-singlediscriminator-typeddict/typetest/model/singlediscriminator/typeddict/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-singlediscriminator-typeddict/typetest/model/singlediscriminator/typeddict/types.py @@ -96,20 +96,4 @@ class Sparrow(TypedDict, total=False): """Required. Default value is \"sparrow\".""" -class TRex(TypedDict, total=False): - """The second level legacy model in polymorphic single level inheritance. - - :ivar size: Required. - :vartype size: int - :ivar kind: Required. Default value is "t-rex". - :vartype kind: Literal["t-rex"] - """ - - size: Required[int] - """Required.""" - kind: Required[Literal["t-rex"]] - """Required. Default value is \"t-rex\".""" - - Bird = Union[Eagle, Goose, SeaGull, Sparrow] -Dinosaur = Union[TRex] diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-singlediscriminator/typetest/model/singlediscriminator/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-singlediscriminator/typetest/model/singlediscriminator/types.py index eebc5e7be505..d8602e6ed87c 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-singlediscriminator/typetest/model/singlediscriminator/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-singlediscriminator/typetest/model/singlediscriminator/types.py @@ -96,20 +96,4 @@ class Sparrow(TypedDict, total=False): """Required. Default value is \"sparrow\".""" -class TRex(TypedDict, total=False): - """The second level legacy model in polymorphic single level inheritance. - - :ivar size: Required. - :vartype size: int - :ivar kind: Required. Default value is "t-rex". - :vartype kind: Literal["t-rex"] - """ - - size: Required[int] - """Required.""" - kind: Required[Literal["t-rex"]] - """Required. Default value is \"t-rex\".""" - - Bird = Union[Eagle, Goose, SeaGull, Sparrow] -Dinosaur = Union[TRex] diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-usage/typetest/model/usage/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-usage/typetest/model/usage/types.py index 137fc8828b86..5a9eb1e1b64b 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-usage/typetest/model/usage/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-model-usage/typetest/model/usage/types.py @@ -29,14 +29,3 @@ class InputRecord(TypedDict, total=False): requiredProp: Required[str] """Required.""" - - -class OutputRecord(TypedDict, total=False): - """Record used in operation return type. - - :ivar required_prop: Required. - :vartype required_prop: str - """ - - requiredProp: Required[str] - """Required.""" diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/aio/operations/_operations.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/aio/operations/_operations.py index 8ad19a138841..5b8ef3708208 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/aio/operations/_operations.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/aio/operations/_operations.py @@ -152,11 +152,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -182,15 +182,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", @distributed_trace_async async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest, IO[bytes]] = _Unset, *, prop: Literal["a", "b", "c"] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest or IO[bytes] :keyword prop: Is one of the following types: Literal["a"], Literal["b"], Literal["c"] Required. :paramtype prop: str or str or str @@ -533,11 +533,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest2, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest2 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -563,15 +563,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", @distributed_trace_async async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest2, IO[bytes]] = _Unset, *, prop: Union[str, _models.StringExtensibleNamedUnion] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest2, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest2 or IO[bytes] :keyword prop: Known values are: "b" and "c". Required. :paramtype prop: str or ~typetest.union.models.StringExtensibleNamedUnion :return: None @@ -719,11 +719,11 @@ async def send(self, *, prop: Literal[1, 2, 3], content_type: str = "application """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest3, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest3 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -749,15 +749,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", @distributed_trace_async async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest3, IO[bytes]] = _Unset, *, prop: Literal[1, 2, 3] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest3, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest3 or IO[bytes] :keyword prop: Is one of the following types: Literal[1], Literal[2], Literal[3] Required. :paramtype prop: int or int or int :return: None @@ -905,11 +905,11 @@ async def send(self, *, prop: float, content_type: str = "application/json", **k """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest4, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest4 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -934,12 +934,12 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", @distributed_trace_async async def send( - self, body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, *, prop: float = _Unset, **kwargs: Any + self, body: Union[JSON, _types.SendRequest4, IO[bytes]] = _Unset, *, prop: float = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest4, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest4 or IO[bytes] :keyword prop: Is one of the following types: float Required. :paramtype prop: float or float or float :return: None @@ -1089,11 +1089,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest5, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest5 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1119,15 +1119,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", @distributed_trace_async async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest5, IO[bytes]] = _Unset, *, prop: Union[_models.Cat, _models.Dog] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest5, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest5 or IO[bytes] :keyword prop: Is either a Cat type or a Dog type. Required. :paramtype prop: ~typetest.union.models.Cat or ~typetest.union.models.Dog :return: None @@ -1277,11 +1277,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest6, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest6 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1307,15 +1307,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", @distributed_trace_async async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest6, IO[bytes]] = _Unset, *, prop: _models.EnumsOnlyCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest6, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest6 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.EnumsOnlyCases :return: None @@ -1465,11 +1465,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest7, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest7 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1495,15 +1495,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", @distributed_trace_async async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest7, IO[bytes]] = _Unset, *, prop: _models.StringAndArrayCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest7, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest7 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.StringAndArrayCases :return: None @@ -1653,11 +1653,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest8, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest8 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1683,15 +1683,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", @distributed_trace_async async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest8, IO[bytes]] = _Unset, *, prop: _models.MixedLiteralsCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest8, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest8 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.MixedLiteralsCases :return: None @@ -1841,11 +1841,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest9, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest9 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1871,15 +1871,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", @distributed_trace_async async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest9, IO[bytes]] = _Unset, *, prop: _models.MixedTypesCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest9, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest9 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.MixedTypesCases :return: None diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/operations/_operations.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/operations/_operations.py index 9a471b733bd4..35ecb4df66ec 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/operations/_operations.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/operations/_operations.py @@ -411,11 +411,11 @@ def send(self, *, prop: Literal["a", "b", "c"], content_type: str = "application """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -441,15 +441,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa @distributed_trace def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest, IO[bytes]] = _Unset, *, prop: Literal["a", "b", "c"] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest or IO[bytes] :keyword prop: Is one of the following types: Literal["a"], Literal["b"], Literal["c"] Required. :paramtype prop: str or str or str @@ -792,11 +792,11 @@ def send( """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest2, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest2 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -822,15 +822,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa @distributed_trace def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest2, IO[bytes]] = _Unset, *, prop: Union[str, _models.StringExtensibleNamedUnion] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest2, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest2 or IO[bytes] :keyword prop: Known values are: "b" and "c". Required. :paramtype prop: str or ~typetest.union.models.StringExtensibleNamedUnion :return: None @@ -978,11 +978,11 @@ def send(self, *, prop: Literal[1, 2, 3], content_type: str = "application/json" """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest3, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest3 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1008,15 +1008,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa @distributed_trace def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest3, IO[bytes]] = _Unset, *, prop: Literal[1, 2, 3] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest3, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest3 or IO[bytes] :keyword prop: Is one of the following types: Literal[1], Literal[2], Literal[3] Required. :paramtype prop: int or int or int :return: None @@ -1164,11 +1164,11 @@ def send(self, *, prop: float, content_type: str = "application/json", **kwargs: """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest4, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest4 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1193,12 +1193,12 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa @distributed_trace def send( # pylint: disable=inconsistent-return-statements - self, body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, *, prop: float = _Unset, **kwargs: Any + self, body: Union[JSON, _types.SendRequest4, IO[bytes]] = _Unset, *, prop: float = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest4, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest4 or IO[bytes] :keyword prop: Is one of the following types: float Required. :paramtype prop: float or float or float :return: None @@ -1348,11 +1348,11 @@ def send( """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest5, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest5 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1378,15 +1378,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa @distributed_trace def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest5, IO[bytes]] = _Unset, *, prop: Union[_models.Cat, _models.Dog] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest5, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest5 or IO[bytes] :keyword prop: Is either a Cat type or a Dog type. Required. :paramtype prop: ~typetest.union.models.Cat or ~typetest.union.models.Dog :return: None @@ -1534,11 +1534,11 @@ def send(self, *, prop: _models.EnumsOnlyCases, content_type: str = "application """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest6, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest6 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1564,15 +1564,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa @distributed_trace def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest6, IO[bytes]] = _Unset, *, prop: _models.EnumsOnlyCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest6, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest6 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.EnumsOnlyCases :return: None @@ -1720,11 +1720,11 @@ def send(self, *, prop: _models.StringAndArrayCases, content_type: str = "applic """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest7, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest7 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1750,15 +1750,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa @distributed_trace def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest7, IO[bytes]] = _Unset, *, prop: _models.StringAndArrayCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest7, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest7 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.StringAndArrayCases :return: None @@ -1906,11 +1906,11 @@ def send(self, *, prop: _models.MixedLiteralsCases, content_type: str = "applica """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest8, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest8 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1936,15 +1936,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa @distributed_trace def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest8, IO[bytes]] = _Unset, *, prop: _models.MixedLiteralsCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest8, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest8 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.MixedLiteralsCases :return: None @@ -2092,11 +2092,11 @@ def send(self, *, prop: _models.MixedTypesCases, content_type: str = "applicatio """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest9, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest9 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -2122,15 +2122,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa @distributed_trace def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest9, IO[bytes]] = _Unset, *, prop: _models.MixedTypesCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest9, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest9 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.MixedTypesCases :return: None diff --git a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/types.py b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/types.py index 21529f60c065..4494c058991f 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/azure/typetest-union/typetest/union/types.py @@ -7,9 +7,12 @@ # -------------------------------------------------------------------------- import builtins -from typing import Literal, Union +from typing import Literal, TYPE_CHECKING, Union from typing_extensions import Required, TypedDict +if TYPE_CHECKING: + from .models import StringExtensibleNamedUnion + class Cat(TypedDict, total=False): """Cat. @@ -52,17 +55,6 @@ class EnumsOnlyCases(TypedDict, total=False): Literal[\"down\"] type.""" -class GetResponse(TypedDict, total=False): - """GetResponse. - - :ivar prop: Required. Is one of the following types: Literal["a"], Literal["b"], Literal["c"] - :vartype prop: Literal["a", "b", "c"] - """ - - prop: Required[Literal["a", "b", "c"]] - """Required. Is one of the following types: Literal[\"a\"], Literal[\"b\"], Literal[\"c\"]""" - - class MixedLiteralsCases(TypedDict, total=False): """MixedLiteralsCases. @@ -146,6 +138,17 @@ class StringAndArrayCases(TypedDict, total=False): """This should be receive/send the array variant. Required. Is either a str type or a [str] type.""" +class SendRequest(TypedDict, total=False): + """SendRequest. + + :ivar prop: Required. Is one of the following types: Literal["a"], Literal["b"], Literal["c"] + :vartype prop: Literal["a", "b", "c"] + """ + + prop: Required[Literal["a", "b", "c"]] + """Required. Is one of the following types: Literal[\"a\"], Literal[\"b\"], Literal[\"c\"]""" + + class SendRequest1(TypedDict, total=False): """SendRequest1. @@ -155,3 +158,91 @@ class SendRequest1(TypedDict, total=False): prop: Required[Union[Literal["b"], Literal["c"], str]] """Required. Is one of the following types: Literal[\"b\"], Literal[\"c\"], str""" + + +class SendRequest2(TypedDict, total=False): + """SendRequest2. + + :ivar prop: Required. Known values are: "b" and "c". + :vartype prop: Union[str, "StringExtensibleNamedUnion"] + """ + + prop: Required[Union[str, "StringExtensibleNamedUnion"]] + """Required. Known values are: \"b\" and \"c\".""" + + +class SendRequest3(TypedDict, total=False): + """SendRequest3. + + :ivar prop: Required. Is one of the following types: Literal[1], Literal[2], Literal[3] + :vartype prop: Literal[1, 2, 3] + """ + + prop: Required[Literal[1, 2, 3]] + """Required. Is one of the following types: Literal[1], Literal[2], Literal[3]""" + + +class SendRequest4(TypedDict, total=False): + """SendRequest4. + + :ivar prop: Required. Is one of the following types: float + :vartype prop: float + """ + + prop: Required[float] + """Required. Is one of the following types: float""" + + +class SendRequest5(TypedDict, total=False): + """SendRequest5. + + :ivar prop: Required. Is either a Cat type or a Dog type. + :vartype prop: Union["Cat", "Dog"] + """ + + prop: Required[Union["Cat", "Dog"]] + """Required. Is either a Cat type or a Dog type.""" + + +class SendRequest6(TypedDict, total=False): + """SendRequest6. + + :ivar prop: Required. + :vartype prop: "EnumsOnlyCases" + """ + + prop: Required["EnumsOnlyCases"] + """Required.""" + + +class SendRequest7(TypedDict, total=False): + """SendRequest7. + + :ivar prop: Required. + :vartype prop: "StringAndArrayCases" + """ + + prop: Required["StringAndArrayCases"] + """Required.""" + + +class SendRequest8(TypedDict, total=False): + """SendRequest8. + + :ivar prop: Required. + :vartype prop: "MixedLiteralsCases" + """ + + prop: Required["MixedLiteralsCases"] + """Required.""" + + +class SendRequest9(TypedDict, total=False): + """SendRequest9. + + :ivar prop: Required. + :vartype prop: "MixedTypesCases" + """ + + prop: Required["MixedTypesCases"] + """Required.""" diff --git a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-empty/typetest/model/empty/types.py b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-empty/typetest/model/empty/types.py index 1b65929ee31f..3c8591f8db0a 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-empty/typetest/model/empty/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-empty/typetest/model/empty/types.py @@ -9,7 +9,3 @@ class EmptyInput(TypedDict, total=False): class EmptyInputOutput(TypedDict, total=False): """Empty model used in both parameter and return type.""" - - -class EmptyOutput(TypedDict, total=False): - """Empty model used in operation return type.""" diff --git a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-singlediscriminator-typeddict/typetest/model/singlediscriminator/typeddict/types.py b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-singlediscriminator-typeddict/typetest/model/singlediscriminator/typeddict/types.py index 626c8dbf5307..59547a197b36 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-singlediscriminator-typeddict/typetest/model/singlediscriminator/typeddict/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-singlediscriminator-typeddict/typetest/model/singlediscriminator/typeddict/types.py @@ -90,20 +90,4 @@ class Sparrow(TypedDict, total=False): """Required. Default value is \"sparrow\".""" -class TRex(TypedDict, total=False): - """The second level legacy model in polymorphic single level inheritance. - - :ivar size: Required. - :vartype size: int - :ivar kind: Required. Default value is "t-rex". - :vartype kind: Literal["t-rex"] - """ - - size: Required[int] - """Required.""" - kind: Required[Literal["t-rex"]] - """Required. Default value is \"t-rex\".""" - - Bird = Union[Eagle, Goose, SeaGull, Sparrow] -Dinosaur = Union[TRex] diff --git a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-singlediscriminator/typetest/model/singlediscriminator/types.py b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-singlediscriminator/typetest/model/singlediscriminator/types.py index 626c8dbf5307..59547a197b36 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-singlediscriminator/typetest/model/singlediscriminator/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-singlediscriminator/typetest/model/singlediscriminator/types.py @@ -90,20 +90,4 @@ class Sparrow(TypedDict, total=False): """Required. Default value is \"sparrow\".""" -class TRex(TypedDict, total=False): - """The second level legacy model in polymorphic single level inheritance. - - :ivar size: Required. - :vartype size: int - :ivar kind: Required. Default value is "t-rex". - :vartype kind: Literal["t-rex"] - """ - - size: Required[int] - """Required.""" - kind: Required[Literal["t-rex"]] - """Required. Default value is \"t-rex\".""" - - Bird = Union[Eagle, Goose, SeaGull, Sparrow] -Dinosaur = Union[TRex] diff --git a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-usage/typetest/model/usage/types.py b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-usage/typetest/model/usage/types.py index 492e8eb34ea9..5c912a387696 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-usage/typetest/model/usage/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-model-usage/typetest/model/usage/types.py @@ -23,14 +23,3 @@ class InputRecord(TypedDict, total=False): requiredProp: Required[str] """Required.""" - - -class OutputRecord(TypedDict, total=False): - """Record used in operation return type. - - :ivar required_prop: Required. - :vartype required_prop: str - """ - - requiredProp: Required[str] - """Required.""" diff --git a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/aio/operations/_operations.py b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/aio/operations/_operations.py index f1a714595808..266b026b4e94 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/aio/operations/_operations.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/aio/operations/_operations.py @@ -142,11 +142,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -171,15 +171,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest, IO[bytes]] = _Unset, *, prop: Literal["a", "b", "c"] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest or IO[bytes] :keyword prop: Is one of the following types: Literal["a"], Literal["b"], Literal["c"] Required. :paramtype prop: str or str or str @@ -511,11 +511,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest2, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest2 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -540,15 +540,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest2, IO[bytes]] = _Unset, *, prop: Union[str, _models.StringExtensibleNamedUnion] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest2, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest2 or IO[bytes] :keyword prop: Known values are: "b" and "c". Required. :paramtype prop: str or ~typetest.union.models.StringExtensibleNamedUnion :return: None @@ -691,11 +691,11 @@ async def send(self, *, prop: Literal[1, 2, 3], content_type: str = "application """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest3, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest3 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -720,15 +720,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest3, IO[bytes]] = _Unset, *, prop: Literal[1, 2, 3] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest3, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest3 or IO[bytes] :keyword prop: Is one of the following types: Literal[1], Literal[2], Literal[3] Required. :paramtype prop: int or int or int :return: None @@ -871,11 +871,11 @@ async def send(self, *, prop: float, content_type: str = "application/json", **k """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest4, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest4 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -899,12 +899,12 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", """ async def send( - self, body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, *, prop: float = _Unset, **kwargs: Any + self, body: Union[JSON, _types.SendRequest4, IO[bytes]] = _Unset, *, prop: float = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest4, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest4 or IO[bytes] :keyword prop: Is one of the following types: float Required. :paramtype prop: float or float or float :return: None @@ -1049,11 +1049,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest5, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest5 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1078,15 +1078,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest5, IO[bytes]] = _Unset, *, prop: Union[_models.Cat, _models.Dog] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest5, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest5 or IO[bytes] :keyword prop: Is either a Cat type or a Dog type. Required. :paramtype prop: ~typetest.union.models.Cat or ~typetest.union.models.Dog :return: None @@ -1231,11 +1231,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest6, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest6 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1260,15 +1260,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest6, IO[bytes]] = _Unset, *, prop: _models.EnumsOnlyCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest6, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest6 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.EnumsOnlyCases :return: None @@ -1413,11 +1413,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest7, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest7 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1442,15 +1442,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest7, IO[bytes]] = _Unset, *, prop: _models.StringAndArrayCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest7, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest7 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.StringAndArrayCases :return: None @@ -1595,11 +1595,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest8, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest8 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1624,15 +1624,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest8, IO[bytes]] = _Unset, *, prop: _models.MixedLiteralsCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest8, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest8 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.MixedLiteralsCases :return: None @@ -1777,11 +1777,11 @@ async def send( """ @overload - async def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + async def send(self, body: _types.SendRequest9, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest9 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1806,15 +1806,15 @@ async def send(self, body: IO[bytes], *, content_type: str = "application/json", async def send( self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest9, IO[bytes]] = _Unset, *, prop: _models.MixedTypesCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest9, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest9 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.MixedTypesCases :return: None diff --git a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/operations/_operations.py b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/operations/_operations.py index 58f4e25e5dc5..b1a8850f3642 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/operations/_operations.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/operations/_operations.py @@ -401,11 +401,11 @@ def send(self, *, prop: Literal["a", "b", "c"], content_type: str = "application """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -430,15 +430,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest, IO[bytes]] = _Unset, *, prop: Literal["a", "b", "c"] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest or IO[bytes] :keyword prop: Is one of the following types: Literal["a"], Literal["b"], Literal["c"] Required. :paramtype prop: str or str or str @@ -770,11 +770,11 @@ def send( """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest2, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest2 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -799,15 +799,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest2, IO[bytes]] = _Unset, *, prop: Union[str, _models.StringExtensibleNamedUnion] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest2, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest2 or IO[bytes] :keyword prop: Known values are: "b" and "c". Required. :paramtype prop: str or ~typetest.union.models.StringExtensibleNamedUnion :return: None @@ -950,11 +950,11 @@ def send(self, *, prop: Literal[1, 2, 3], content_type: str = "application/json" """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest3, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest3 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -979,15 +979,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest3, IO[bytes]] = _Unset, *, prop: Literal[1, 2, 3] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest3, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest3 or IO[bytes] :keyword prop: Is one of the following types: Literal[1], Literal[2], Literal[3] Required. :paramtype prop: int or int or int :return: None @@ -1130,11 +1130,11 @@ def send(self, *, prop: float, content_type: str = "application/json", **kwargs: """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest4, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest4 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1158,12 +1158,12 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa """ def send( # pylint: disable=inconsistent-return-statements - self, body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, *, prop: float = _Unset, **kwargs: Any + self, body: Union[JSON, _types.SendRequest4, IO[bytes]] = _Unset, *, prop: float = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest4, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest4 or IO[bytes] :keyword prop: Is one of the following types: float Required. :paramtype prop: float or float or float :return: None @@ -1308,11 +1308,11 @@ def send( """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest5, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest5 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1337,15 +1337,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest5, IO[bytes]] = _Unset, *, prop: Union[_models.Cat, _models.Dog] = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest5, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest5 or IO[bytes] :keyword prop: Is either a Cat type or a Dog type. Required. :paramtype prop: ~typetest.union.models.Cat or ~typetest.union.models.Dog :return: None @@ -1488,11 +1488,11 @@ def send(self, *, prop: _models.EnumsOnlyCases, content_type: str = "application """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest6, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest6 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1517,15 +1517,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest6, IO[bytes]] = _Unset, *, prop: _models.EnumsOnlyCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest6, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest6 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.EnumsOnlyCases :return: None @@ -1668,11 +1668,11 @@ def send(self, *, prop: _models.StringAndArrayCases, content_type: str = "applic """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest7, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest7 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1697,15 +1697,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest7, IO[bytes]] = _Unset, *, prop: _models.StringAndArrayCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest7, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest7 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.StringAndArrayCases :return: None @@ -1848,11 +1848,11 @@ def send(self, *, prop: _models.MixedLiteralsCases, content_type: str = "applica """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest8, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest8 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -1877,15 +1877,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest8, IO[bytes]] = _Unset, *, prop: _models.MixedLiteralsCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest8, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest8 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.MixedLiteralsCases :return: None @@ -2028,11 +2028,11 @@ def send(self, *, prop: _models.MixedTypesCases, content_type: str = "applicatio """ @overload - def send(self, body: _types.SendRequest1, *, content_type: str = "application/json", **kwargs: Any) -> None: + def send(self, body: _types.SendRequest9, *, content_type: str = "application/json", **kwargs: Any) -> None: """send. :param body: Required. - :type body: ~typetest.union.types.SendRequest1 + :type body: ~typetest.union.types.SendRequest9 :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. Default value is "application/json". :paramtype content_type: str @@ -2057,15 +2057,15 @@ def send(self, body: IO[bytes], *, content_type: str = "application/json", **kwa def send( # pylint: disable=inconsistent-return-statements self, - body: Union[JSON, _types.SendRequest1, IO[bytes]] = _Unset, + body: Union[JSON, _types.SendRequest9, IO[bytes]] = _Unset, *, prop: _models.MixedTypesCases = _Unset, **kwargs: Any ) -> None: """send. - :param body: Is one of the following types: JSON, SendRequest1, IO[bytes] Required. - :type body: JSON or ~typetest.union.types.SendRequest1 or IO[bytes] + :param body: Is one of the following types: JSON, SendRequest9, IO[bytes] Required. + :type body: JSON or ~typetest.union.types.SendRequest9 or IO[bytes] :keyword prop: Required. :paramtype prop: ~typetest.union.models.MixedTypesCases :return: None diff --git a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/types.py b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/types.py index 919bd1dda245..2ea601cdbf98 100644 --- a/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/types.py +++ b/eng/tools/azure-sdk-tools/emitter/generated/unbranded/typetest-union/typetest/union/types.py @@ -1,9 +1,12 @@ # coding=utf-8 import builtins -from typing import Literal, Union +from typing import Literal, TYPE_CHECKING, Union from typing_extensions import Required, TypedDict +if TYPE_CHECKING: + from .models import StringExtensibleNamedUnion + class Cat(TypedDict, total=False): """Cat. @@ -46,17 +49,6 @@ class EnumsOnlyCases(TypedDict, total=False): Literal[\"down\"] type.""" -class GetResponse(TypedDict, total=False): - """GetResponse. - - :ivar prop: Required. Is one of the following types: Literal["a"], Literal["b"], Literal["c"] - :vartype prop: Literal["a", "b", "c"] - """ - - prop: Required[Literal["a", "b", "c"]] - """Required. Is one of the following types: Literal[\"a\"], Literal[\"b\"], Literal[\"c\"]""" - - class MixedLiteralsCases(TypedDict, total=False): """MixedLiteralsCases. @@ -140,6 +132,17 @@ class StringAndArrayCases(TypedDict, total=False): """This should be receive/send the array variant. Required. Is either a str type or a [str] type.""" +class SendRequest(TypedDict, total=False): + """SendRequest. + + :ivar prop: Required. Is one of the following types: Literal["a"], Literal["b"], Literal["c"] + :vartype prop: Literal["a", "b", "c"] + """ + + prop: Required[Literal["a", "b", "c"]] + """Required. Is one of the following types: Literal[\"a\"], Literal[\"b\"], Literal[\"c\"]""" + + class SendRequest1(TypedDict, total=False): """SendRequest1. @@ -149,3 +152,91 @@ class SendRequest1(TypedDict, total=False): prop: Required[Union[Literal["b"], Literal["c"], str]] """Required. Is one of the following types: Literal[\"b\"], Literal[\"c\"], str""" + + +class SendRequest2(TypedDict, total=False): + """SendRequest2. + + :ivar prop: Required. Known values are: "b" and "c". + :vartype prop: Union[str, "StringExtensibleNamedUnion"] + """ + + prop: Required[Union[str, "StringExtensibleNamedUnion"]] + """Required. Known values are: \"b\" and \"c\".""" + + +class SendRequest3(TypedDict, total=False): + """SendRequest3. + + :ivar prop: Required. Is one of the following types: Literal[1], Literal[2], Literal[3] + :vartype prop: Literal[1, 2, 3] + """ + + prop: Required[Literal[1, 2, 3]] + """Required. Is one of the following types: Literal[1], Literal[2], Literal[3]""" + + +class SendRequest4(TypedDict, total=False): + """SendRequest4. + + :ivar prop: Required. Is one of the following types: float + :vartype prop: float + """ + + prop: Required[float] + """Required. Is one of the following types: float""" + + +class SendRequest5(TypedDict, total=False): + """SendRequest5. + + :ivar prop: Required. Is either a Cat type or a Dog type. + :vartype prop: Union["Cat", "Dog"] + """ + + prop: Required[Union["Cat", "Dog"]] + """Required. Is either a Cat type or a Dog type.""" + + +class SendRequest6(TypedDict, total=False): + """SendRequest6. + + :ivar prop: Required. + :vartype prop: "EnumsOnlyCases" + """ + + prop: Required["EnumsOnlyCases"] + """Required.""" + + +class SendRequest7(TypedDict, total=False): + """SendRequest7. + + :ivar prop: Required. + :vartype prop: "StringAndArrayCases" + """ + + prop: Required["StringAndArrayCases"] + """Required.""" + + +class SendRequest8(TypedDict, total=False): + """SendRequest8. + + :ivar prop: Required. + :vartype prop: "MixedLiteralsCases" + """ + + prop: Required["MixedLiteralsCases"] + """Required.""" + + +class SendRequest9(TypedDict, total=False): + """SendRequest9. + + :ivar prop: Required. + :vartype prop: "MixedTypesCases" + """ + + prop: Required["MixedTypesCases"] + """Required."""