Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Release History

## 1.0.0 (2020-12-22)

- GA release

## 1.0.0b1 (2020-11-04)

This is beta preview version.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
# --------------------------------------------------------------------------

VERSION = "1.0.0b1"
VERSION = "1.0.0"
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
from azure.core.pipeline.transport import AsyncHttpResponse, HttpRequest
from azure.mgmt.core.exceptions import ARMErrorFormat

from ... import models
from ... import models as _models

T = TypeVar('T')
ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]]
Expand All @@ -32,7 +32,7 @@ class MarketplaceAgreementsOperations:
:param deserializer: An object model deserializer.
"""

models = models
models = _models

def __init__(self, client, config, serializer, deserializer) -> None:
self._client = client
Expand All @@ -42,12 +42,12 @@ def __init__(self, client, config, serializer, deserializer) -> None:

async def get(
self,
offer_type: Union[str, "models.OfferType"],
offer_type: Union[str, "_models.OfferType"],
publisher_id: str,
offer_id: str,
plan_id: str,
**kwargs
) -> "models.AgreementTerms":
) -> "_models.AgreementTerms":
"""Get marketplace terms.

:param offer_type: Offer Type, currently only virtualmachine type is supported.
Expand All @@ -63,7 +63,7 @@ async def get(
:rtype: ~azure.mgmt.marketplaceordering.models.AgreementTerms
:raises: ~azure.core.exceptions.HttpResponseError
"""
cls = kwargs.pop('cls', None) # type: ClsType["models.AgreementTerms"]
cls = kwargs.pop('cls', None) # type: ClsType["_models.AgreementTerms"]
error_map = {
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
Expand Down Expand Up @@ -96,7 +96,7 @@ async def get(

if response.status_code not in [200]:
map_error(status_code=response.status_code, response=response, error_map=error_map)
error = self._deserialize(models.ErrorResponse, response)
error = self._deserialize(_models.ErrorResponse, response)
raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

deserialized = self._deserialize('AgreementTerms', pipeline_response)
Expand All @@ -109,13 +109,13 @@ async def get(

async def create(
self,
offer_type: Union[str, "models.OfferType"],
offer_type: Union[str, "_models.OfferType"],
publisher_id: str,
offer_id: str,
plan_id: str,
parameters: "models.AgreementTerms",
parameters: "_models.AgreementTerms",
**kwargs
) -> "models.AgreementTerms":
) -> "_models.AgreementTerms":
"""Save marketplace terms.

:param offer_type: Offer Type, currently only virtualmachine type is supported.
Expand All @@ -133,7 +133,7 @@ async def create(
:rtype: ~azure.mgmt.marketplaceordering.models.AgreementTerms
:raises: ~azure.core.exceptions.HttpResponseError
"""
cls = kwargs.pop('cls', None) # type: ClsType["models.AgreementTerms"]
cls = kwargs.pop('cls', None) # type: ClsType["_models.AgreementTerms"]
error_map = {
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
Expand Down Expand Up @@ -171,7 +171,7 @@ async def create(

if response.status_code not in [200]:
map_error(status_code=response.status_code, response=response, error_map=error_map)
error = self._deserialize(models.ErrorResponse, response)
error = self._deserialize(_models.ErrorResponse, response)
raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

deserialized = self._deserialize('AgreementTerms', pipeline_response)
Expand All @@ -188,7 +188,7 @@ async def sign(
offer_id: str,
plan_id: str,
**kwargs
) -> "models.AgreementTerms":
) -> "_models.AgreementTerms":
"""Sign marketplace terms.

:param publisher_id: Publisher identifier string of image being deployed.
Expand All @@ -202,7 +202,7 @@ async def sign(
:rtype: ~azure.mgmt.marketplaceordering.models.AgreementTerms
:raises: ~azure.core.exceptions.HttpResponseError
"""
cls = kwargs.pop('cls', None) # type: ClsType["models.AgreementTerms"]
cls = kwargs.pop('cls', None) # type: ClsType["_models.AgreementTerms"]
error_map = {
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
Expand Down Expand Up @@ -234,7 +234,7 @@ async def sign(

if response.status_code not in [200]:
map_error(status_code=response.status_code, response=response, error_map=error_map)
error = self._deserialize(models.ErrorResponse, response)
error = self._deserialize(_models.ErrorResponse, response)
raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

deserialized = self._deserialize('AgreementTerms', pipeline_response)
Expand All @@ -251,7 +251,7 @@ async def cancel(
offer_id: str,
plan_id: str,
**kwargs
) -> "models.AgreementTerms":
) -> "_models.AgreementTerms":
"""Cancel marketplace terms.

:param publisher_id: Publisher identifier string of image being deployed.
Expand All @@ -265,7 +265,7 @@ async def cancel(
:rtype: ~azure.mgmt.marketplaceordering.models.AgreementTerms
:raises: ~azure.core.exceptions.HttpResponseError
"""
cls = kwargs.pop('cls', None) # type: ClsType["models.AgreementTerms"]
cls = kwargs.pop('cls', None) # type: ClsType["_models.AgreementTerms"]
error_map = {
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
Expand Down Expand Up @@ -297,7 +297,7 @@ async def cancel(

if response.status_code not in [200]:
map_error(status_code=response.status_code, response=response, error_map=error_map)
error = self._deserialize(models.ErrorResponse, response)
error = self._deserialize(_models.ErrorResponse, response)
raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

deserialized = self._deserialize('AgreementTerms', pipeline_response)
Expand All @@ -314,7 +314,7 @@ async def get_agreement(
offer_id: str,
plan_id: str,
**kwargs
) -> "models.AgreementTerms":
) -> "_models.AgreementTerms":
"""Get marketplace agreement.

:param publisher_id: Publisher identifier string of image being deployed.
Expand All @@ -328,7 +328,7 @@ async def get_agreement(
:rtype: ~azure.mgmt.marketplaceordering.models.AgreementTerms
:raises: ~azure.core.exceptions.HttpResponseError
"""
cls = kwargs.pop('cls', None) # type: ClsType["models.AgreementTerms"]
cls = kwargs.pop('cls', None) # type: ClsType["_models.AgreementTerms"]
error_map = {
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
Expand Down Expand Up @@ -360,7 +360,7 @@ async def get_agreement(

if response.status_code not in [200]:
map_error(status_code=response.status_code, response=response, error_map=error_map)
error = self._deserialize(models.ErrorResponse, response)
error = self._deserialize(_models.ErrorResponse, response)
raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

deserialized = self._deserialize('AgreementTerms', pipeline_response)
Expand All @@ -374,15 +374,15 @@ async def get_agreement(
async def list(
self,
**kwargs
) -> List["models.AgreementTerms"]:
) -> List["_models.AgreementTerms"]:
"""List marketplace agreements in the subscription.

:keyword callable cls: A custom type or function that will be passed the direct response
:return: list of AgreementTerms, or the result of cls(response)
:rtype: list[~azure.mgmt.marketplaceordering.models.AgreementTerms]
:raises: ~azure.core.exceptions.HttpResponseError
"""
cls = kwargs.pop('cls', None) # type: ClsType[List["models.AgreementTerms"]]
cls = kwargs.pop('cls', None) # type: ClsType[List["_models.AgreementTerms"]]
error_map = {
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
Expand Down Expand Up @@ -411,7 +411,7 @@ async def list(

if response.status_code not in [200]:
map_error(status_code=response.status_code, response=response, error_map=error_map)
error = self._deserialize(models.ErrorResponse, response)
error = self._deserialize(_models.ErrorResponse, response)
raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

deserialized = self._deserialize('[AgreementTerms]', pipeline_response)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
from azure.core.pipeline.transport import AsyncHttpResponse, HttpRequest
from azure.mgmt.core.exceptions import ARMErrorFormat

from ... import models
from ... import models as _models

T = TypeVar('T')
ClsType = Optional[Callable[[PipelineResponse[HttpRequest, AsyncHttpResponse], T, Dict[str, Any]], Any]]
Expand All @@ -33,7 +33,7 @@ class Operations:
:param deserializer: An object model deserializer.
"""

models = models
models = _models

def __init__(self, client, config, serializer, deserializer) -> None:
self._client = client
Expand All @@ -44,15 +44,15 @@ def __init__(self, client, config, serializer, deserializer) -> None:
def list(
self,
**kwargs
) -> AsyncIterable["models.OperationListResult"]:
) -> AsyncIterable["_models.OperationListResult"]:
"""Lists all of the available Microsoft.MarketplaceOrdering REST API operations.

:keyword callable cls: A custom type or function that will be passed the direct response
:return: An iterator like instance of either OperationListResult or the result of cls(response)
:rtype: ~azure.core.async_paging.AsyncItemPaged[~azure.mgmt.marketplaceordering.models.OperationListResult]
:raises: ~azure.core.exceptions.HttpResponseError
"""
cls = kwargs.pop('cls', None) # type: ClsType["models.OperationListResult"]
cls = kwargs.pop('cls', None) # type: ClsType["_models.OperationListResult"]
error_map = {
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
}
Expand Down Expand Up @@ -93,7 +93,7 @@ async def get_next(next_link=None):
response = pipeline_response.http_response

if response.status_code not in [200]:
error = self._deserialize(models.ErrorResponse, response)
error = self._deserialize(_models.ErrorResponse, response)
map_error(status_code=response.status_code, response=response, error_map=error_map)
raise HttpResponseError(response=response, model=error, error_format=ARMErrorFormat)

Expand Down
Loading