Skip to content

Commit

Permalink
CodeGen from PR 12027 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge 0cc23f83128f3edd31f0771b6f560adf44033ac2 into 251ab91
  • Loading branch information
SDKAuto committed Dec 9, 2020
1 parent e1f2009 commit ebeb755
Show file tree
Hide file tree
Showing 12 changed files with 1,700 additions and 112 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
from .operations import ReservationOperations
from .operations import ReservationOrderOperations
from .operations import OperationOperations
from .operations import CalculateExchangeOperations
from .operations import ExchangeOperations
from . import models


Expand All @@ -41,6 +43,10 @@ class AzureReservationAPI(AzureReservationAPIOperationsMixin, SDKClient):
:vartype reservation_order: azure.mgmt.reservations.operations.ReservationOrderOperations
:ivar operation: Operation operations
:vartype operation: azure.mgmt.reservations.operations.OperationOperations
:ivar calculate_exchange: CalculateExchange operations
:vartype calculate_exchange: azure.mgmt.reservations.operations.CalculateExchangeOperations
:ivar exchange: Exchange operations
:vartype exchange: azure.mgmt.reservations.operations.ExchangeOperations
:param credentials: Credentials needed for the client to connect to Azure.
:type credentials: :mod:`A msrestazure Credentials
Expand Down Expand Up @@ -70,3 +76,7 @@ def __init__(
self._client, self.config, self._serialize, self._deserialize)
self.operation = OperationOperations(
self._client, self.config, self._serialize, self._deserialize)
self.calculate_exchange = CalculateExchangeOperations(
self._client, self.config, self._serialize, self._deserialize)
self.exchange = ExchangeOperations(
self._client, self.config, self._serialize, self._deserialize)
Original file line number Diff line number Diff line change
Expand Up @@ -15,29 +15,46 @@
from ._models_py3 import AppliedReservations
from ._models_py3 import AqiSettings
from ._models_py3 import AutoQuotaIncreaseDetail
from ._models_py3 import AvailableScopeProperties
from ._models_py3 import AvailableScopeRequest
from ._models_py3 import AvailableScopeRequestProperties
from ._models_py3 import BillingInformation
from ._models_py3 import CalculateExchangeOperationResultResponse
from ._models_py3 import CalculateExchangeRequest
from ._models_py3 import CalculateExchangeRequestProperties
from ._models_py3 import CalculateExchangeResponseProperties
from ._models_py3 import CalculatePriceResponse
from ._models_py3 import CalculatePriceResponseProperties
from ._models_py3 import CalculatePriceResponsePropertiesBillingCurrencyTotal
from ._models_py3 import CalculatePriceResponsePropertiesPricingCurrencyTotal
from ._models_py3 import Catalog
from ._models_py3 import ChangeDirectoryRequest
from ._models_py3 import ChangeDirectoryResponse
from ._models_py3 import ChangeDirectoryResult
from ._models_py3 import CreateGenericQuotaRequestParameters
from ._models_py3 import CurrentQuotaLimit
from ._models_py3 import CurrentQuotaLimitBase
from ._models_py3 import EmailAction
from ._models_py3 import EmailActions
from ._models_py3 import Error, ErrorException
from ._models_py3 import ExceptionResponse, ExceptionResponseException
from ._models_py3 import ExchangeOperationResultResponse
from ._models_py3 import ExchangePolicyError
from ._models_py3 import ExchangePolicyErrors
from ._models_py3 import ExchangeRequest
from ._models_py3 import ExchangeRequestProperties
from ._models_py3 import ExchangeResponseProperties
from ._models_py3 import ExtendedErrorInfo
from ._models_py3 import ExtendedStatusInfo
from ._models_py3 import MergeRequest
from ._models_py3 import OperationDisplay
from ._models_py3 import OperationResponse
from ._models_py3 import OperationResultError
from ._models_py3 import Patch
from ._models_py3 import PatchPropertiesRenewProperties
from ._models_py3 import PaymentDetail
from ._models_py3 import PhoneAction
from ._models_py3 import Price
from ._models_py3 import Properties
from ._models_py3 import PurchaseRequest
from ._models_py3 import PurchaseRequestPropertiesReservedResourceProperties
from ._models_py3 import QuotaLimitsResponse
Expand All @@ -56,6 +73,11 @@
from ._models_py3 import ReservationProperties
from ._models_py3 import ReservationResponse
from ._models_py3 import ReservationSplitProperties
from ._models_py3 import ReservationToExchange
from ._models_py3 import ReservationToPurchaseCalculateExchange
from ._models_py3 import ReservationToPurchaseExchange
from ._models_py3 import ReservationToReturn
from ._models_py3 import ReservationToReturnForExchange
from ._models_py3 import ResourceName
from ._models_py3 import ScopeProperties
from ._models_py3 import ServiceError
Expand All @@ -73,29 +95,46 @@
from ._models import AppliedReservations
from ._models import AqiSettings
from ._models import AutoQuotaIncreaseDetail
from ._models import AvailableScopeProperties
from ._models import AvailableScopeRequest
from ._models import AvailableScopeRequestProperties
from ._models import BillingInformation
from ._models import CalculateExchangeOperationResultResponse
from ._models import CalculateExchangeRequest
from ._models import CalculateExchangeRequestProperties
from ._models import CalculateExchangeResponseProperties
from ._models import CalculatePriceResponse
from ._models import CalculatePriceResponseProperties
from ._models import CalculatePriceResponsePropertiesBillingCurrencyTotal
from ._models import CalculatePriceResponsePropertiesPricingCurrencyTotal
from ._models import Catalog
from ._models import ChangeDirectoryRequest
from ._models import ChangeDirectoryResponse
from ._models import ChangeDirectoryResult
from ._models import CreateGenericQuotaRequestParameters
from ._models import CurrentQuotaLimit
from ._models import CurrentQuotaLimitBase
from ._models import EmailAction
from ._models import EmailActions
from ._models import Error, ErrorException
from ._models import ExceptionResponse, ExceptionResponseException
from ._models import ExchangeOperationResultResponse
from ._models import ExchangePolicyError
from ._models import ExchangePolicyErrors
from ._models import ExchangeRequest
from ._models import ExchangeRequestProperties
from ._models import ExchangeResponseProperties
from ._models import ExtendedErrorInfo
from ._models import ExtendedStatusInfo
from ._models import MergeRequest
from ._models import OperationDisplay
from ._models import OperationResponse
from ._models import OperationResultError
from ._models import Patch
from ._models import PatchPropertiesRenewProperties
from ._models import PaymentDetail
from ._models import PhoneAction
from ._models import Price
from ._models import Properties
from ._models import PurchaseRequest
from ._models import PurchaseRequestPropertiesReservedResourceProperties
from ._models import QuotaLimitsResponse
Expand All @@ -114,6 +153,11 @@
from ._models import ReservationProperties
from ._models import ReservationResponse
from ._models import ReservationSplitProperties
from ._models import ReservationToExchange
from ._models import ReservationToPurchaseCalculateExchange
from ._models import ReservationToPurchaseExchange
from ._models import ReservationToReturn
from ._models import ReservationToReturnForExchange
from ._models import ResourceName
from ._models import ScopeProperties
from ._models import ServiceError
Expand All @@ -131,14 +175,17 @@
from ._paged_models import ReservationOrderResponsePaged
from ._paged_models import ReservationResponsePaged
from ._azure_reservation_api_enums import (
ReservedResourceType,
ReservationTerm,
ReservationBillingPlan,
AppliedScopeType,
InstanceFlexibility,
ReservationStatusCode,
ErrorResponseCode,
ReservationBillingPlan,
ReservationTerm,
CalculateExchangeOperationResultStatus,
ExchangeOperationResultStatus,
OperationStatus,
PaymentStatus,
ReservedResourceType,
InstanceFlexibility,
AppliedScopeType,
)

__all__ = [
Expand All @@ -147,29 +194,46 @@
'AppliedReservations',
'AqiSettings',
'AutoQuotaIncreaseDetail',
'AvailableScopeProperties',
'AvailableScopeRequest',
'AvailableScopeRequestProperties',
'BillingInformation',
'CalculateExchangeOperationResultResponse',
'CalculateExchangeRequest',
'CalculateExchangeRequestProperties',
'CalculateExchangeResponseProperties',
'CalculatePriceResponse',
'CalculatePriceResponseProperties',
'CalculatePriceResponsePropertiesBillingCurrencyTotal',
'CalculatePriceResponsePropertiesPricingCurrencyTotal',
'Catalog',
'ChangeDirectoryRequest',
'ChangeDirectoryResponse',
'ChangeDirectoryResult',
'CreateGenericQuotaRequestParameters',
'CurrentQuotaLimit',
'CurrentQuotaLimitBase',
'EmailAction',
'EmailActions',
'Error', 'ErrorException',
'ExceptionResponse', 'ExceptionResponseException',
'ExchangeOperationResultResponse',
'ExchangePolicyError',
'ExchangePolicyErrors',
'ExchangeRequest',
'ExchangeRequestProperties',
'ExchangeResponseProperties',
'ExtendedErrorInfo',
'ExtendedStatusInfo',
'MergeRequest',
'OperationDisplay',
'OperationResponse',
'OperationResultError',
'Patch',
'PatchPropertiesRenewProperties',
'PaymentDetail',
'PhoneAction',
'Price',
'Properties',
'PurchaseRequest',
'PurchaseRequestPropertiesReservedResourceProperties',
'QuotaLimitsResponse',
Expand All @@ -188,6 +252,11 @@
'ReservationProperties',
'ReservationResponse',
'ReservationSplitProperties',
'ReservationToExchange',
'ReservationToPurchaseCalculateExchange',
'ReservationToPurchaseExchange',
'ReservationToReturn',
'ReservationToReturnForExchange',
'ResourceName',
'ScopeProperties',
'ServiceError',
Expand All @@ -204,12 +273,15 @@
'ReservationResponsePaged',
'ReservationOrderResponsePaged',
'OperationResponsePaged',
'ReservedResourceType',
'ReservationTerm',
'ReservationBillingPlan',
'AppliedScopeType',
'InstanceFlexibility',
'ReservationStatusCode',
'ErrorResponseCode',
'ReservationBillingPlan',
'ReservationTerm',
'CalculateExchangeOperationResultStatus',
'ExchangeOperationResultStatus',
'OperationStatus',
'PaymentStatus',
'ReservedResourceType',
'InstanceFlexibility',
'AppliedScopeType',
]
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,54 @@
from enum import Enum


class ReservedResourceType(str, Enum):

virtual_machines = "VirtualMachines"
sql_databases = "SqlDatabases"
suse_linux = "SuseLinux"
cosmos_db = "CosmosDb"
red_hat = "RedHat"
sql_data_warehouse = "SqlDataWarehouse"
vmware_cloud_simple = "VMwareCloudSimple"
red_hat_osa = "RedHatOsa"
databricks = "Databricks"
app_service = "AppService"
managed_disk = "ManagedDisk"
block_blob = "BlockBlob"
redis_cache = "RedisCache"
azure_data_explorer = "AzureDataExplorer"
my_sql = "MySql"
maria_db = "MariaDb"
postgre_sql = "PostgreSql"
dedicated_host = "DedicatedHost"
sap_hana = "SapHana"
sql_azure_hybrid_benefit = "SqlAzureHybridBenefit"


class ReservationTerm(str, Enum):

p1_y = "P1Y"
p3_y = "P3Y"


class ReservationBillingPlan(str, Enum):

upfront = "Upfront"
monthly = "Monthly"


class AppliedScopeType(str, Enum):

single = "Single"
shared = "Shared"


class InstanceFlexibility(str, Enum):

on = "On"
off = "Off"


class ReservationStatusCode(str, Enum):

none = "None"
Expand Down Expand Up @@ -84,57 +132,34 @@ class ErrorResponseCode(str, Enum):
calculate_price_failed = "CalculatePriceFailed"


class ReservationBillingPlan(str, Enum):

upfront = "Upfront"
monthly = "Monthly"


class ReservationTerm(str, Enum):

p1_y = "P1Y"
p3_y = "P3Y"


class PaymentStatus(str, Enum):
class CalculateExchangeOperationResultStatus(str, Enum):

succeeded = "Succeeded"
failed = "Failed"
scheduled = "Scheduled"
cancelled = "Cancelled"
pending = "Pending"


class ReservedResourceType(str, Enum):
class ExchangeOperationResultStatus(str, Enum):

virtual_machines = "VirtualMachines"
sql_databases = "SqlDatabases"
suse_linux = "SuseLinux"
cosmos_db = "CosmosDb"
red_hat = "RedHat"
sql_data_warehouse = "SqlDataWarehouse"
vmware_cloud_simple = "VMwareCloudSimple"
red_hat_osa = "RedHatOsa"
databricks = "Databricks"
app_service = "AppService"
managed_disk = "ManagedDisk"
block_blob = "BlockBlob"
redis_cache = "RedisCache"
azure_data_explorer = "AzureDataExplorer"
my_sql = "MySql"
maria_db = "MariaDb"
postgre_sql = "PostgreSql"
dedicated_host = "DedicatedHost"
sap_hana = "SapHana"
sql_azure_hybrid_benefit = "SqlAzureHybridBenefit"
succeeded = "Succeeded"
failed = "Failed"
cancelled = "Cancelled"
pending_refunds = "PendingRefunds"
pending_purchases = "PendingPurchases"


class InstanceFlexibility(str, Enum):
class OperationStatus(str, Enum):

on = "On"
off = "Off"
succeeded = "Succeeded"
failed = "Failed"
cancelled = "Cancelled"
pending = "Pending"


class AppliedScopeType(str, Enum):
class PaymentStatus(str, Enum):

single = "Single"
shared = "Shared"
succeeded = "Succeeded"
failed = "Failed"
scheduled = "Scheduled"
cancelled = "Cancelled"
Loading

0 comments on commit ebeb755

Please sign in to comment.