diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/CHANGELOG.md b/sdk/mediaservices/azure-resourcemanager-mediaservices/CHANGELOG.md
index f81ab5a8b13e..8c5a6da04258 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/CHANGELOG.md
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/CHANGELOG.md
@@ -1,7 +1,8 @@
# Release History
-## 1.1.0-beta.3 (Unreleased)
+## 1.0.0-beta.1 (2021-10-18)
+- Azure Resource Manager MediaServices client library for Java. This package contains Microsoft Azure SDK for MediaServices Management SDK. This Swagger was generated by the API Framework. Package tag package-2021-06. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
## 1.1.0-beta.2 (2021-07-16)
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/README.md b/sdk/mediaservices/azure-resourcemanager-mediaservices/README.md
index 254fd1343a46..4971917b5b97 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/README.md
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/README.md
@@ -32,7 +32,7 @@ Various documentation is available to help you get started
com.azure.resourcemanager
azure-resourcemanager-mediaservices
- 1.1.0-beta.2
+ 1.1.0-beta.3
```
[//]: # ({x-version-update-end})
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/SAMPLE.md b/sdk/mediaservices/azure-resourcemanager-mediaservices/SAMPLE.md
index fe21e814f923..0d52e77ea994 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/SAMPLE.md
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/SAMPLE.md
@@ -1,132 +1,3201 @@
# Code snippets and samples
-### AccountFilters
+## AccountFilters
-- [CreateOrUpdate](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AccountFiltersCreateOrUpdateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AccountFiltersDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AccountFiltersGetSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AccountFiltersListSamples.java)
-- [Update](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AccountFiltersUpdateSamples.java)
+- [CreateOrUpdate](#accountfilters_createorupdate)
+- [Delete](#accountfilters_delete)
+- [Get](#accountfilters_get)
+- [List](#accountfilters_list)
+- [Update](#accountfilters_update)
-### AssetFilters
+## AssetFilters
-- [CreateOrUpdate](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetFiltersCreateOrUpdateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetFiltersDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetFiltersGetSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetFiltersListSamples.java)
-- [Update](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetFiltersUpdateSamples.java)
-
-### Assets
+- [CreateOrUpdate](#assetfilters_createorupdate)
+- [Delete](#assetfilters_delete)
+- [Get](#assetfilters_get)
+- [List](#assetfilters_list)
+- [Update](#assetfilters_update)
-- [CreateOrUpdate](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetsCreateOrUpdateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetsDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetsGetSamples.java)
-- [GetEncryptionKey](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetsGetEncryptionKeySamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetsListSamples.java)
-- [ListContainerSas](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetsListContainerSasSamples.java)
-- [ListStreamingLocators](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetsListStreamingLocatorsSamples.java)
-- [Update](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/AssetsUpdateSamples.java)
+## Assets
-### ContentKeyPolicies
-
-- [CreateOrUpdate](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/ContentKeyPoliciesCreateOrUpdateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/ContentKeyPoliciesDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/ContentKeyPoliciesGetSamples.java)
-- [GetPolicyPropertiesWithSecrets](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/ContentKeyPoliciesGetPolicyPropertiesWithSecretsSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/ContentKeyPoliciesListSamples.java)
-- [Update](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/ContentKeyPoliciesUpdateSamples.java)
-
-### Jobs
-
-- [CancelJob](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/JobsCancelJobSamples.java)
-- [Create](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/JobsCreateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/JobsDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/JobsGetSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/JobsListSamples.java)
-- [Update](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/JobsUpdateSamples.java)
-
-### LiveEvents
-
-- [Allocate](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveEventsAllocateSamples.java)
-- [Create](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveEventsCreateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveEventsDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveEventsGetSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveEventsListSamples.java)
-- [Reset](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveEventsResetSamples.java)
-- [Start](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveEventsStartSamples.java)
-- [Stop](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveEventsStopSamples.java)
-- [Update](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveEventsUpdateSamples.java)
-
-### LiveOutputs
-
-- [Create](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveOutputsCreateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveOutputsDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveOutputsGetSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LiveOutputsListSamples.java)
-
-### Locations
-
-- [CheckNameAvailability](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/LocationsCheckNameAvailabilitySamples.java)
-
-### Mediaservices
-
-- [CreateOrUpdate](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/MediaservicesCreateOrUpdateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/MediaservicesDeleteSamples.java)
-- [GetByResourceGroup](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/MediaservicesGetByResourceGroupSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/MediaservicesListSamples.java)
-- [ListByResourceGroup](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/MediaservicesListByResourceGroupSamples.java)
-- [ListEdgePolicies](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/MediaservicesListEdgePoliciesSamples.java)
-- [SyncStorageKeys](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/MediaservicesSyncStorageKeysSamples.java)
-- [Update](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/MediaservicesUpdateSamples.java)
-
-### Operations
-
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/OperationsListSamples.java)
-
-### PrivateEndpointConnections
-
-- [CreateOrUpdate](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/PrivateEndpointConnectionsCreateOrUpdateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/PrivateEndpointConnectionsDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/PrivateEndpointConnectionsGetSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/PrivateEndpointConnectionsListSamples.java)
-
-### PrivateLinkResources
-
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/PrivateLinkResourcesGetSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/PrivateLinkResourcesListSamples.java)
-
-### StreamingEndpoints
-
-- [Create](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingEndpointsCreateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingEndpointsDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingEndpointsGetSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingEndpointsListSamples.java)
-- [Scale](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingEndpointsScaleSamples.java)
-- [Start](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingEndpointsStartSamples.java)
-- [Stop](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingEndpointsStopSamples.java)
-- [Update](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingEndpointsUpdateSamples.java)
-
-### StreamingLocators
+- [CreateOrUpdate](#assets_createorupdate)
+- [Delete](#assets_delete)
+- [Get](#assets_get)
+- [GetEncryptionKey](#assets_getencryptionkey)
+- [List](#assets_list)
+- [ListContainerSas](#assets_listcontainersas)
+- [ListStreamingLocators](#assets_liststreaminglocators)
+- [Update](#assets_update)
-- [Create](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingLocatorsCreateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingLocatorsDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingLocatorsGetSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingLocatorsListSamples.java)
-- [ListContentKeys](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingLocatorsListContentKeysSamples.java)
-- [ListPaths](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingLocatorsListPathsSamples.java)
+## ContentKeyPolicies
-### StreamingPolicies
-
-- [Create](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingPoliciesCreateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingPoliciesDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingPoliciesGetSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/StreamingPoliciesListSamples.java)
-
-### Transforms
+- [CreateOrUpdate](#contentkeypolicies_createorupdate)
+- [Delete](#contentkeypolicies_delete)
+- [Get](#contentkeypolicies_get)
+- [GetPolicyPropertiesWithSecrets](#contentkeypolicies_getpolicypropertieswithsecrets)
+- [List](#contentkeypolicies_list)
+- [Update](#contentkeypolicies_update)
+
+## Jobs
+
+- [CancelJob](#jobs_canceljob)
+- [Create](#jobs_create)
+- [Delete](#jobs_delete)
+- [Get](#jobs_get)
+- [List](#jobs_list)
+- [Update](#jobs_update)
+
+## LiveEvents
+
+- [Allocate](#liveevents_allocate)
+- [Create](#liveevents_create)
+- [Delete](#liveevents_delete)
+- [Get](#liveevents_get)
+- [List](#liveevents_list)
+- [Reset](#liveevents_reset)
+- [Start](#liveevents_start)
+- [Stop](#liveevents_stop)
+- [Update](#liveevents_update)
+
+## LiveOutputs
+
+- [Create](#liveoutputs_create)
+- [Delete](#liveoutputs_delete)
+- [Get](#liveoutputs_get)
+- [List](#liveoutputs_list)
+
+## Locations
+
+- [CheckNameAvailability](#locations_checknameavailability)
+
+## Mediaservices
+
+- [CreateOrUpdate](#mediaservices_createorupdate)
+- [Delete](#mediaservices_delete)
+- [GetByResourceGroup](#mediaservices_getbyresourcegroup)
+- [List](#mediaservices_list)
+- [ListByResourceGroup](#mediaservices_listbyresourcegroup)
+- [ListEdgePolicies](#mediaservices_listedgepolicies)
+- [SyncStorageKeys](#mediaservices_syncstoragekeys)
+- [Update](#mediaservices_update)
+
+## Operations
+
+- [List](#operations_list)
+
+## PrivateEndpointConnections
+
+- [CreateOrUpdate](#privateendpointconnections_createorupdate)
+- [Delete](#privateendpointconnections_delete)
+- [Get](#privateendpointconnections_get)
+- [List](#privateendpointconnections_list)
+
+## PrivateLinkResources
+
+- [Get](#privatelinkresources_get)
+- [List](#privatelinkresources_list)
+
+## StreamingEndpoints
+
+- [Create](#streamingendpoints_create)
+- [Delete](#streamingendpoints_delete)
+- [Get](#streamingendpoints_get)
+- [List](#streamingendpoints_list)
+- [Scale](#streamingendpoints_scale)
+- [Start](#streamingendpoints_start)
+- [Stop](#streamingendpoints_stop)
+- [Update](#streamingendpoints_update)
+
+## StreamingLocators
+
+- [Create](#streaminglocators_create)
+- [Delete](#streaminglocators_delete)
+- [Get](#streaminglocators_get)
+- [List](#streaminglocators_list)
+- [ListContentKeys](#streaminglocators_listcontentkeys)
+- [ListPaths](#streaminglocators_listpaths)
+
+## StreamingPolicies
+
+- [Create](#streamingpolicies_create)
+- [Delete](#streamingpolicies_delete)
+- [Get](#streamingpolicies_get)
+- [List](#streamingpolicies_list)
+
+## Transforms
+
+- [CreateOrUpdate](#transforms_createorupdate)
+- [Delete](#transforms_delete)
+- [Get](#transforms_get)
+- [List](#transforms_list)
+- [Update](#transforms_update)
+### AccountFilters_CreateOrUpdate
+
+```java
+import com.azure.resourcemanager.mediaservices.models.FilterTrackPropertyCompareOperation;
+import com.azure.resourcemanager.mediaservices.models.FilterTrackPropertyCondition;
+import com.azure.resourcemanager.mediaservices.models.FilterTrackPropertyType;
+import com.azure.resourcemanager.mediaservices.models.FilterTrackSelection;
+import com.azure.resourcemanager.mediaservices.models.FirstQuality;
+import com.azure.resourcemanager.mediaservices.models.PresentationTimeRange;
+import java.util.Arrays;
+
+/** Samples for AccountFilters CreateOrUpdate. */
+public final class AccountFiltersCreateOrUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accountFilters-create.json
+ */
+ /**
+ * Sample code: Create an Account Filter.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createAnAccountFilter(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .accountFilters()
+ .define("newAccountFilter")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withPresentationTimeRange(
+ new PresentationTimeRange()
+ .withStartTimestamp(0L)
+ .withEndTimestamp(170000000L)
+ .withPresentationWindowDuration(9223372036854775000L)
+ .withLiveBackoffDuration(0L)
+ .withTimescale(10000000L)
+ .withForceEndTimestamp(false))
+ .withFirstQuality(new FirstQuality().withBitrate(128000))
+ .withTracks(
+ Arrays
+ .asList(
+ new FilterTrackSelection()
+ .withTrackSelections(
+ Arrays
+ .asList(
+ new FilterTrackPropertyCondition()
+ .withProperty(FilterTrackPropertyType.TYPE)
+ .withValue("Audio")
+ .withOperation(FilterTrackPropertyCompareOperation.EQUAL),
+ new FilterTrackPropertyCondition()
+ .withProperty(FilterTrackPropertyType.LANGUAGE)
+ .withValue("en")
+ .withOperation(FilterTrackPropertyCompareOperation.NOT_EQUAL),
+ new FilterTrackPropertyCondition()
+ .withProperty(FilterTrackPropertyType.FOUR_CC)
+ .withValue("EC-3")
+ .withOperation(FilterTrackPropertyCompareOperation.NOT_EQUAL))),
+ new FilterTrackSelection()
+ .withTrackSelections(
+ Arrays
+ .asList(
+ new FilterTrackPropertyCondition()
+ .withProperty(FilterTrackPropertyType.TYPE)
+ .withValue("Video")
+ .withOperation(FilterTrackPropertyCompareOperation.EQUAL),
+ new FilterTrackPropertyCondition()
+ .withProperty(FilterTrackPropertyType.BITRATE)
+ .withValue("3000000-5000000")
+ .withOperation(FilterTrackPropertyCompareOperation.EQUAL)))))
+ .create();
+ }
+}
+```
+
+### AccountFilters_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for AccountFilters Delete. */
+public final class AccountFiltersDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accountFilters-delete.json
+ */
+ /**
+ * Sample code: Delete an Account Filter.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteAnAccountFilter(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .accountFilters()
+ .deleteWithResponse("contoso", "contosomedia", "accountFilterWithTimeWindowAndTrack", Context.NONE);
+ }
+}
+```
+
+### AccountFilters_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for AccountFilters Get. */
+public final class AccountFiltersGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accountFilters-get-by-name.json
+ */
+ /**
+ * Sample code: Get an Account Filter by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAnAccountFilterByName(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.accountFilters().getWithResponse("contoso", "contosomedia", "accountFilterWithTrack", Context.NONE);
+ }
+}
+```
+
+### AccountFilters_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for AccountFilters List. */
+public final class AccountFiltersListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accountFilters-list-all.json
+ */
+ /**
+ * Sample code: List all Account Filters.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAllAccountFilters(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.accountFilters().list("contoso", "contosomedia", Context.NONE);
+ }
+}
+```
+
+### AccountFilters_Update
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.AccountFilter;
+import com.azure.resourcemanager.mediaservices.models.FirstQuality;
+import com.azure.resourcemanager.mediaservices.models.PresentationTimeRange;
+
+/** Samples for AccountFilters Update. */
+public final class AccountFiltersUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accountFilters-update.json
+ */
+ /**
+ * Sample code: Update an Account Filter.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void updateAnAccountFilter(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ AccountFilter resource =
+ manager
+ .accountFilters()
+ .getWithResponse("contoso", "contosomedia", "accountFilterWithTimeWindowAndTrack", Context.NONE)
+ .getValue();
+ resource
+ .update()
+ .withPresentationTimeRange(
+ new PresentationTimeRange()
+ .withStartTimestamp(10L)
+ .withEndTimestamp(170000000L)
+ .withPresentationWindowDuration(9223372036854775000L)
+ .withLiveBackoffDuration(0L)
+ .withTimescale(10000000L)
+ .withForceEndTimestamp(false))
+ .withFirstQuality(new FirstQuality().withBitrate(128000))
+ .apply();
+ }
+}
+```
+
+### AssetFilters_CreateOrUpdate
+
+```java
+import com.azure.resourcemanager.mediaservices.models.FilterTrackPropertyCompareOperation;
+import com.azure.resourcemanager.mediaservices.models.FilterTrackPropertyCondition;
+import com.azure.resourcemanager.mediaservices.models.FilterTrackPropertyType;
+import com.azure.resourcemanager.mediaservices.models.FilterTrackSelection;
+import com.azure.resourcemanager.mediaservices.models.FirstQuality;
+import com.azure.resourcemanager.mediaservices.models.PresentationTimeRange;
+import java.util.Arrays;
+
+/** Samples for AssetFilters CreateOrUpdate. */
+public final class AssetFiltersCreateOrUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assetFilters-create.json
+ */
+ /**
+ * Sample code: Create an Asset Filter.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createAnAssetFilter(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .assetFilters()
+ .define("newAssetFilter")
+ .withExistingAsset("contoso", "contosomedia", "ClimbingMountRainer")
+ .withPresentationTimeRange(
+ new PresentationTimeRange()
+ .withStartTimestamp(0L)
+ .withEndTimestamp(170000000L)
+ .withPresentationWindowDuration(9223372036854775000L)
+ .withLiveBackoffDuration(0L)
+ .withTimescale(10000000L)
+ .withForceEndTimestamp(false))
+ .withFirstQuality(new FirstQuality().withBitrate(128000))
+ .withTracks(
+ Arrays
+ .asList(
+ new FilterTrackSelection()
+ .withTrackSelections(
+ Arrays
+ .asList(
+ new FilterTrackPropertyCondition()
+ .withProperty(FilterTrackPropertyType.TYPE)
+ .withValue("Audio")
+ .withOperation(FilterTrackPropertyCompareOperation.EQUAL),
+ new FilterTrackPropertyCondition()
+ .withProperty(FilterTrackPropertyType.LANGUAGE)
+ .withValue("en")
+ .withOperation(FilterTrackPropertyCompareOperation.NOT_EQUAL),
+ new FilterTrackPropertyCondition()
+ .withProperty(FilterTrackPropertyType.FOUR_CC)
+ .withValue("EC-3")
+ .withOperation(FilterTrackPropertyCompareOperation.NOT_EQUAL))),
+ new FilterTrackSelection()
+ .withTrackSelections(
+ Arrays
+ .asList(
+ new FilterTrackPropertyCondition()
+ .withProperty(FilterTrackPropertyType.TYPE)
+ .withValue("Video")
+ .withOperation(FilterTrackPropertyCompareOperation.EQUAL),
+ new FilterTrackPropertyCondition()
+ .withProperty(FilterTrackPropertyType.BITRATE)
+ .withValue("3000000-5000000")
+ .withOperation(FilterTrackPropertyCompareOperation.EQUAL)))))
+ .create();
+ }
+}
+```
+
+### AssetFilters_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for AssetFilters Delete. */
+public final class AssetFiltersDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assetFilters-delete.json
+ */
+ /**
+ * Sample code: Delete an Asset Filter.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteAnAssetFilter(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .assetFilters()
+ .deleteWithResponse(
+ "contoso", "contosomedia", "ClimbingMountRainer", "assetFilterWithTimeWindowAndTrack", Context.NONE);
+ }
+}
+```
+
+### AssetFilters_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for AssetFilters Get. */
+public final class AssetFiltersGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assetFilters-get-by-name.json
+ */
+ /**
+ * Sample code: Get an Asset Filter by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAnAssetFilterByName(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .assetFilters()
+ .getWithResponse(
+ "contoso", "contosomedia", "ClimbingMountRainer", "assetFilterWithTimeWindowAndTrack", Context.NONE);
+ }
+}
+```
+
+### AssetFilters_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for AssetFilters List. */
+public final class AssetFiltersListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assetFilters-list-all.json
+ */
+ /**
+ * Sample code: List all Asset Filters.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAllAssetFilters(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.assetFilters().list("contoso", "contosomedia", "ClimbingMountRainer", Context.NONE);
+ }
+}
+```
+
+### AssetFilters_Update
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.AssetFilter;
+import com.azure.resourcemanager.mediaservices.models.FirstQuality;
+import com.azure.resourcemanager.mediaservices.models.PresentationTimeRange;
+
+/** Samples for AssetFilters Update. */
+public final class AssetFiltersUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assetFilters-update.json
+ */
+ /**
+ * Sample code: Update an Asset Filter.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void updateAnAssetFilter(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ AssetFilter resource =
+ manager
+ .assetFilters()
+ .getWithResponse(
+ "contoso", "contosomedia", "ClimbingMountRainer", "assetFilterWithTimeWindowAndTrack", Context.NONE)
+ .getValue();
+ resource
+ .update()
+ .withPresentationTimeRange(
+ new PresentationTimeRange()
+ .withStartTimestamp(10L)
+ .withEndTimestamp(170000000L)
+ .withPresentationWindowDuration(9223372036854775000L)
+ .withLiveBackoffDuration(0L)
+ .withTimescale(10000000L)
+ .withForceEndTimestamp(false))
+ .withFirstQuality(new FirstQuality().withBitrate(128000))
+ .apply();
+ }
+}
+```
+
+### Assets_CreateOrUpdate
+
+```java
+/** Samples for Assets CreateOrUpdate. */
+public final class AssetsCreateOrUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assets-create.json
+ */
+ /**
+ * Sample code: Create an Asset.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createAnAsset(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .assets()
+ .define("ClimbingMountLogan")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withDescription("A documentary showing the ascent of Mount Logan")
+ .withStorageAccountName("storage0")
+ .create();
+ }
+}
+```
+
+### Assets_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Assets Delete. */
+public final class AssetsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assets-delete.json
+ */
+ /**
+ * Sample code: Delete an Asset.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteAnAsset(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.assets().deleteWithResponse("contoso", "contosomedia", "ClimbingMountAdams", Context.NONE);
+ }
+}
+```
+
+### Assets_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Assets Get. */
+public final class AssetsGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assets-get-by-name.json
+ */
+ /**
+ * Sample code: Get an Asset by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAnAssetByName(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.assets().getWithResponse("contoso", "contosomedia", "ClimbingMountAdams", Context.NONE);
+ }
+}
+```
+
+### Assets_GetEncryptionKey
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Assets GetEncryptionKey. */
+public final class AssetsGetEncryptionKeySamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assets-get-encryption-keys.json
+ */
+ /**
+ * Sample code: Get Asset Storage Encryption Keys.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAssetStorageEncryptionKeys(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .assets()
+ .getEncryptionKeyWithResponse("contoso", "contosomedia", "ClimbingMountSaintHelens", Context.NONE);
+ }
+}
+```
+
+### Assets_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Assets List. */
+public final class AssetsListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assets-list-by-date.json
+ */
+ /**
+ * Sample code: List Asset ordered by date.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAssetOrderedByDate(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.assets().list("contoso", "contosomedia", null, null, "properties/created", Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assets-list-in-date-range.json
+ */
+ /**
+ * Sample code: List Asset created in a date range.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAssetCreatedInADateRange(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .assets()
+ .list(
+ "contoso",
+ "contosomedia",
+ "properties/created gt 2012-06-01 and properties/created lt 2013-07-01",
+ null,
+ "properties/created",
+ Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assets-list-all.json
+ */
+ /**
+ * Sample code: List all Assets.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAllAssets(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.assets().list("contoso", "contosomedia", null, null, null, Context.NONE);
+ }
+}
+```
+
+### Assets_ListContainerSas
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.AssetContainerPermission;
+import com.azure.resourcemanager.mediaservices.models.ListContainerSasInput;
+import java.time.OffsetDateTime;
+
+/** Samples for Assets ListContainerSas. */
+public final class AssetsListContainerSasSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assets-list-sas-urls.json
+ */
+ /**
+ * Sample code: List Asset SAS URLs.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAssetSASURLs(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .assets()
+ .listContainerSasWithResponse(
+ "contoso",
+ "contosomedia",
+ "ClimbingMountBaker",
+ new ListContainerSasInput()
+ .withPermissions(AssetContainerPermission.READ_WRITE)
+ .withExpiryTime(OffsetDateTime.parse("2018-01-01T10:00:00.007Z")),
+ Context.NONE);
+ }
+}
+```
+
+### Assets_ListStreamingLocators
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Assets ListStreamingLocators. */
+public final class AssetsListStreamingLocatorsSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assets-list-streaming-locators.json
+ */
+ /**
+ * Sample code: List Asset SAS URLs.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAssetSASURLs(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .assets()
+ .listStreamingLocatorsWithResponse("contoso", "contosomedia", "ClimbingMountSaintHelens", Context.NONE);
+ }
+}
+```
+
+### Assets_Update
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.Asset;
+
+/** Samples for Assets Update. */
+public final class AssetsUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/assets-update.json
+ */
+ /**
+ * Sample code: Update an Asset.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void updateAnAsset(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ Asset resource =
+ manager.assets().getWithResponse("contoso", "contosomedia", "ClimbingMountBaker", Context.NONE).getValue();
+ resource.update().withDescription("A documentary showing the ascent of Mount Baker in HD").apply();
+ }
+}
+```
+
+### ContentKeyPolicies_CreateOrUpdate
+
+```java
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyClearKeyConfiguration;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyOpenRestriction;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyOption;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyPlayReadyConfiguration;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyPlayReadyContentEncryptionKeyFromHeader;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyPlayReadyContentType;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyPlayReadyLicense;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyPlayReadyLicenseType;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyPlayReadyPlayRight;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyPlayReadyUnknownOutputPassingOption;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyRestrictionTokenType;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyRsaTokenKey;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicySymmetricTokenKey;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyTokenRestriction;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyWidevineConfiguration;
+import java.time.OffsetDateTime;
+import java.util.Arrays;
+
+/** Samples for ContentKeyPolicies CreateOrUpdate. */
+public final class ContentKeyPoliciesCreateOrUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/content-key-policies-create-multiple-options.json
+ */
+ /**
+ * Sample code: Creates a Content Key Policy with multiple options.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAContentKeyPolicyWithMultipleOptions(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .contentKeyPolicies()
+ .define("PolicyCreatedWithMultipleOptions")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withDescription("ArmPolicyDescription")
+ .withOptions(
+ Arrays
+ .asList(
+ new ContentKeyPolicyOption()
+ .withName("ClearKeyOption")
+ .withConfiguration(new ContentKeyPolicyClearKeyConfiguration())
+ .withRestriction(
+ new ContentKeyPolicyTokenRestriction()
+ .withIssuer("urn:issuer")
+ .withAudience("urn:audience")
+ .withPrimaryVerificationKey(
+ new ContentKeyPolicySymmetricTokenKey()
+ .withKeyValue("AAAAAAAAAAAAAAAAAAAAAA==".getBytes()))
+ .withRestrictionTokenType(ContentKeyPolicyRestrictionTokenType.SWT)),
+ new ContentKeyPolicyOption()
+ .withName("widevineoption")
+ .withConfiguration(
+ new ContentKeyPolicyWidevineConfiguration()
+ .withWidevineTemplate(
+ "{\"allowed_track_types\":\"SD_HD\",\"content_key_specs\":[{\"track_type\":\"SD\",\"security_level\":1,\"required_output_protection\":{\"hdcp\":\"HDCP_V2\"}}],\"policy_overrides\":{\"can_play\":true,\"can_persist\":true,\"can_renew\":false}}"))
+ .withRestriction(new ContentKeyPolicyOpenRestriction())))
+ .create();
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/content-key-policies-create-nodrm-token.json
+ */
+ /**
+ * Sample code: Creates a Content Key Policy with ClearKey option and Token Restriction.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAContentKeyPolicyWithClearKeyOptionAndTokenRestriction(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .contentKeyPolicies()
+ .define("PolicyWithClearKeyOptionAndSwtTokenRestriction")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withDescription("ArmPolicyDescription")
+ .withOptions(
+ Arrays
+ .asList(
+ new ContentKeyPolicyOption()
+ .withName("ClearKeyOption")
+ .withConfiguration(new ContentKeyPolicyClearKeyConfiguration())
+ .withRestriction(
+ new ContentKeyPolicyTokenRestriction()
+ .withIssuer("urn:issuer")
+ .withAudience("urn:audience")
+ .withPrimaryVerificationKey(
+ new ContentKeyPolicySymmetricTokenKey()
+ .withKeyValue("AAAAAAAAAAAAAAAAAAAAAA==".getBytes()))
+ .withRestrictionTokenType(ContentKeyPolicyRestrictionTokenType.SWT))))
+ .create();
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/content-key-policies-create-playready-open.json
+ */
+ /**
+ * Sample code: Creates a Content Key Policy with PlayReady option and Open Restriction.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAContentKeyPolicyWithPlayReadyOptionAndOpenRestriction(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .contentKeyPolicies()
+ .define("PolicyWithPlayReadyOptionAndOpenRestriction")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withDescription("ArmPolicyDescription")
+ .withOptions(
+ Arrays
+ .asList(
+ new ContentKeyPolicyOption()
+ .withName("ArmPolicyOptionName")
+ .withConfiguration(
+ new ContentKeyPolicyPlayReadyConfiguration()
+ .withLicenses(
+ Arrays
+ .asList(
+ new ContentKeyPolicyPlayReadyLicense()
+ .withAllowTestDevices(true)
+ .withBeginDate(OffsetDateTime.parse("2017-10-16T18:22:53.46Z"))
+ .withPlayRight(
+ new ContentKeyPolicyPlayReadyPlayRight()
+ .withScmsRestriction(2)
+ .withDigitalVideoOnlyContentRestriction(false)
+ .withImageConstraintForAnalogComponentVideoRestriction(true)
+ .withImageConstraintForAnalogComputerMonitorRestriction(
+ false)
+ .withAllowPassingVideoContentToUnknownOutput(
+ ContentKeyPolicyPlayReadyUnknownOutputPassingOption
+ .NOT_ALLOWED))
+ .withLicenseType(ContentKeyPolicyPlayReadyLicenseType.PERSISTENT)
+ .withContentKeyLocation(
+ new ContentKeyPolicyPlayReadyContentEncryptionKeyFromHeader())
+ .withContentType(
+ ContentKeyPolicyPlayReadyContentType.ULTRA_VIOLET_DOWNLOAD))))
+ .withRestriction(new ContentKeyPolicyOpenRestriction())))
+ .create();
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/content-key-policies-create-widevine-token.json
+ */
+ /**
+ * Sample code: Creates a Content Key Policy with Widevine option and Token Restriction.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAContentKeyPolicyWithWidevineOptionAndTokenRestriction(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .contentKeyPolicies()
+ .define("PolicyWithWidevineOptionAndJwtTokenRestriction")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withDescription("ArmPolicyDescription")
+ .withOptions(
+ Arrays
+ .asList(
+ new ContentKeyPolicyOption()
+ .withName("widevineoption")
+ .withConfiguration(
+ new ContentKeyPolicyWidevineConfiguration()
+ .withWidevineTemplate(
+ "{\"allowed_track_types\":\"SD_HD\",\"content_key_specs\":[{\"track_type\":\"SD\",\"security_level\":1,\"required_output_protection\":{\"hdcp\":\"HDCP_V2\"}}],\"policy_overrides\":{\"can_play\":true,\"can_persist\":true,\"can_renew\":false}}"))
+ .withRestriction(
+ new ContentKeyPolicyTokenRestriction()
+ .withIssuer("urn:issuer")
+ .withAudience("urn:audience")
+ .withPrimaryVerificationKey(
+ new ContentKeyPolicyRsaTokenKey()
+ .withExponent("AQAB".getBytes())
+ .withModulus("AQAD".getBytes()))
+ .withAlternateVerificationKeys(
+ Arrays
+ .asList(
+ new ContentKeyPolicySymmetricTokenKey()
+ .withKeyValue("AAAAAAAAAAAAAAAAAAAAAA==".getBytes())))
+ .withRestrictionTokenType(ContentKeyPolicyRestrictionTokenType.JWT))))
+ .create();
+ }
+}
+```
+
+### ContentKeyPolicies_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for ContentKeyPolicies Delete. */
+public final class ContentKeyPoliciesDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/content-key-policies-delete.json
+ */
+ /**
+ * Sample code: Delete a Key Policy.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteAKeyPolicy(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .contentKeyPolicies()
+ .deleteWithResponse("contoso", "contosomedia", "PolicyWithPlayReadyOptionAndOpenRestriction", Context.NONE);
+ }
+}
+```
+
+### ContentKeyPolicies_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for ContentKeyPolicies Get. */
+public final class ContentKeyPoliciesGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/content-key-policies-get-by-name.json
+ */
+ /**
+ * Sample code: Get a Content Key Policy by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAContentKeyPolicyByName(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .contentKeyPolicies()
+ .getWithResponse("contoso", "contosomedia", "PolicyWithMultipleOptions", Context.NONE);
+ }
+}
+```
+
+### ContentKeyPolicies_GetPolicyPropertiesWithSecrets
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for ContentKeyPolicies GetPolicyPropertiesWithSecrets. */
+public final class ContentKeyPoliciesGetPolicyPropertiesWithSecretsSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/content-key-policies-get-with-secrets.json
+ */
+ /**
+ * Sample code: Get an Content Key Policy with secrets.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAnContentKeyPolicyWithSecrets(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .contentKeyPolicies()
+ .getPolicyPropertiesWithSecretsWithResponse(
+ "contoso", "contosomedia", "PolicyWithMultipleOptions", Context.NONE);
+ }
+}
+```
+
+### ContentKeyPolicies_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for ContentKeyPolicies List. */
+public final class ContentKeyPoliciesListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/content-key-policies-list-all.json
+ */
+ /**
+ * Sample code: Lists all Content Key Policies.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsAllContentKeyPolicies(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.contentKeyPolicies().list("contoso", "contosomedia", null, null, null, Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/content-key-policies-list-in-date-range.json
+ */
+ /**
+ * Sample code: Lists Content Key Policies with created and last modified filters.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsContentKeyPoliciesWithCreatedAndLastModifiedFilters(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .contentKeyPolicies()
+ .list(
+ "contoso",
+ "contosomedia",
+ "properties/lastModified gt 2016-06-01 and properties/created lt 2013-07-01",
+ null,
+ null,
+ Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/content-key-policies-list-by-lastModified.json
+ */
+ /**
+ * Sample code: Lists Content Key Policies ordered by last modified.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsContentKeyPoliciesOrderedByLastModified(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .contentKeyPolicies()
+ .list("contoso", "contosomedia", null, null, "properties/lastModified", Context.NONE);
+ }
+}
+```
+
+### ContentKeyPolicies_Update
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicy;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyClearKeyConfiguration;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyOpenRestriction;
+import com.azure.resourcemanager.mediaservices.models.ContentKeyPolicyOption;
+import java.util.Arrays;
+
+/** Samples for ContentKeyPolicies Update. */
+public final class ContentKeyPoliciesUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/content-key-policies-update.json
+ */
+ /**
+ * Sample code: Update a Content Key Policy.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void updateAContentKeyPolicy(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ ContentKeyPolicy resource =
+ manager
+ .contentKeyPolicies()
+ .getWithResponse("contoso", "contosomedia", "PolicyWithClearKeyOptionAndTokenRestriction", Context.NONE)
+ .getValue();
+ resource
+ .update()
+ .withDescription("Updated Policy")
+ .withOptions(
+ Arrays
+ .asList(
+ new ContentKeyPolicyOption()
+ .withName("ClearKeyOption")
+ .withConfiguration(new ContentKeyPolicyClearKeyConfiguration())
+ .withRestriction(new ContentKeyPolicyOpenRestriction())))
+ .apply();
+ }
+}
+```
+
+### Jobs_CancelJob
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Jobs CancelJob. */
+public final class JobsCancelJobSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-cancel.json
+ */
+ /**
+ * Sample code: Cancel a Job.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void cancelAJob(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .jobs()
+ .cancelJobWithResponse("contosoresources", "contosomedia", "exampleTransform", "job1", Context.NONE);
+ }
+}
+```
+
+### Jobs_Create
+
+```java
+import com.azure.resourcemanager.mediaservices.models.JobInput;
+import com.azure.resourcemanager.mediaservices.models.JobOutputAsset;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.Map;
+
+/** Samples for Jobs Create. */
+public final class JobsCreateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-create.json
+ */
+ /**
+ * Sample code: Create a Job.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createAJob(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .jobs()
+ .define("job1")
+ .withExistingTransform("contosoresources", "contosomedia", "exampleTransform")
+ .withInput(new JobInput())
+ .withOutputs(Arrays.asList(new JobOutputAsset().withAssetName("job1-OutputAsset")))
+ .withCorrelationData(mapOf("Key 2", "Value 2", "key1", "value1"))
+ .create();
+ }
+
+ @SuppressWarnings("unchecked")
+ private static Map mapOf(Object... inputs) {
+ Map map = new HashMap<>();
+ for (int i = 0; i < inputs.length; i += 2) {
+ String key = (String) inputs[i];
+ T value = (T) inputs[i + 1];
+ map.put(key, value);
+ }
+ return map;
+ }
+}
+```
+
+### Jobs_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Jobs Delete. */
+public final class JobsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-delete.json
+ */
+ /**
+ * Sample code: Delete a Job.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteAJob(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .jobs()
+ .deleteWithResponse("contosoresources", "contosomedia", "exampleTransform", "jobToDelete", Context.NONE);
+ }
+}
+```
+
+### Jobs_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Jobs Get. */
+public final class JobsGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-get-by-name.json
+ */
+ /**
+ * Sample code: Get a Job by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAJobByName(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.jobs().getWithResponse("contosoresources", "contosomedia", "exampleTransform", "job1", Context.NONE);
+ }
+}
+```
+
+### Jobs_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Jobs List. */
+public final class JobsListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-list-all-filter-by-state-ne.json
+ */
+ /**
+ * Sample code: Lists Jobs for the Transform filter by state not equal.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsJobsForTheTransformFilterByStateNotEqual(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .jobs()
+ .list(
+ "contosoresources",
+ "contosomedia",
+ "exampleTransform",
+ "properties/state ne Microsoft.Media.JobState'processing'",
+ null,
+ Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-list-all-filter-by-state-eq.json
+ */
+ /**
+ * Sample code: Lists Jobs for the Transform filter by state equal.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsJobsForTheTransformFilterByStateEqual(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .jobs()
+ .list(
+ "contosoresources",
+ "contosomedia",
+ "exampleTransform",
+ "properties/state eq Microsoft.Media.JobState'Processing'",
+ null,
+ Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-list-all-filter-by-name.json
+ */
+ /**
+ * Sample code: Lists Jobs for the Transform filter by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsJobsForTheTransformFilterByName(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .jobs()
+ .list(
+ "contosoresources",
+ "contosomedia",
+ "exampleTransform",
+ "name eq 'job1' or name eq 'job2'",
+ "name",
+ Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-list-all-filter-by-lastmodified.json
+ */
+ /**
+ * Sample code: Lists Jobs for the Transform filter by lastmodified.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsJobsForTheTransformFilterByLastmodified(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .jobs()
+ .list(
+ "contosoresources",
+ "contosomedia",
+ "exampleTransform",
+ "properties/lastmodified ge 2021-06-01T00:00:10.0000000Z and properties/lastmodified le"
+ + " 2021-06-01T00:00:20.0000000Z",
+ "properties/lastmodified desc",
+ Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-list-all-filter-by-created.json
+ */
+ /**
+ * Sample code: Lists Jobs for the Transform filter by created.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsJobsForTheTransformFilterByCreated(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .jobs()
+ .list(
+ "contosoresources",
+ "contosomedia",
+ "exampleTransform",
+ "properties/created ge 2021-06-01T00:00:10.0000000Z and properties/created le"
+ + " 2021-06-01T00:00:20.0000000Z",
+ "properties/created",
+ Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-list-all.json
+ */
+ /**
+ * Sample code: Lists all of the Jobs for the Transform.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsAllOfTheJobsForTheTransform(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.jobs().list("contosoresources", "contosomedia", "exampleTransform", null, null, Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-list-all-filter-by-name-and-state.json
+ */
+ /**
+ * Sample code: Lists Jobs for the Transform filter by name and state.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsJobsForTheTransformFilterByNameAndState(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .jobs()
+ .list(
+ "contosoresources",
+ "contosomedia",
+ "exampleTransform",
+ "name eq 'job3' and properties/state eq Microsoft.Media.JobState'finished'",
+ null,
+ Context.NONE);
+ }
+}
+```
+
+### Jobs_Update
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.Job;
+import com.azure.resourcemanager.mediaservices.models.JobInput;
+import com.azure.resourcemanager.mediaservices.models.JobOutputAsset;
+import com.azure.resourcemanager.mediaservices.models.Priority;
+import java.util.Arrays;
+
+/** Samples for Jobs Update. */
+public final class JobsUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/jobs-update.json
+ */
+ /**
+ * Sample code: Update a Job.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void updateAJob(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ Job resource =
+ manager
+ .jobs()
+ .getWithResponse("contosoresources", "contosomedia", "exampleTransform", "job1", Context.NONE)
+ .getValue();
+ resource
+ .update()
+ .withDescription("Example job to illustrate update.")
+ .withInput(new JobInput())
+ .withOutputs(Arrays.asList(new JobOutputAsset().withAssetName("job1-OutputAsset")))
+ .withPriority(Priority.HIGH)
+ .apply();
+ }
+}
+```
+
+### LiveEvents_Allocate
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for LiveEvents Allocate. */
+public final class LiveEventsAllocateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveevent-allocate.json
+ */
+ /**
+ * Sample code: Allocate a LiveEvent.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void allocateALiveEvent(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.liveEvents().allocate("mediaresources", "slitestmedia10", "myLiveEvent1", Context.NONE);
+ }
+}
+```
+
+### LiveEvents_Create
+
+```java
+import com.azure.resourcemanager.mediaservices.models.IpAccessControl;
+import com.azure.resourcemanager.mediaservices.models.IpRange;
+import com.azure.resourcemanager.mediaservices.models.LiveEventInput;
+import com.azure.resourcemanager.mediaservices.models.LiveEventInputAccessControl;
+import com.azure.resourcemanager.mediaservices.models.LiveEventInputProtocol;
+import com.azure.resourcemanager.mediaservices.models.LiveEventPreview;
+import com.azure.resourcemanager.mediaservices.models.LiveEventPreviewAccessControl;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.Map;
+
+/** Samples for LiveEvents Create. */
+public final class LiveEventsCreateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveevent-create.json
+ */
+ /**
+ * Sample code: Create a LiveEvent.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createALiveEvent(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .liveEvents()
+ .define("myLiveEvent1")
+ .withRegion("West US")
+ .withExistingMediaservice("mediaresources", "slitestmedia10")
+ .withTags(mapOf("tag1", "value1", "tag2", "value2"))
+ .withDescription("test event 1")
+ .withInput(
+ new LiveEventInput()
+ .withStreamingProtocol(LiveEventInputProtocol.RTMP)
+ .withAccessControl(
+ new LiveEventInputAccessControl()
+ .withIp(
+ new IpAccessControl()
+ .withAllow(
+ Arrays
+ .asList(
+ new IpRange()
+ .withName("AllowAll")
+ .withAddress("0.0.0.0")
+ .withSubnetPrefixLength(0)))))
+ .withKeyFrameIntervalDuration("PT6S"))
+ .withPreview(
+ new LiveEventPreview()
+ .withAccessControl(
+ new LiveEventPreviewAccessControl()
+ .withIp(
+ new IpAccessControl()
+ .withAllow(
+ Arrays
+ .asList(
+ new IpRange()
+ .withName("AllowAll")
+ .withAddress("0.0.0.0")
+ .withSubnetPrefixLength(0))))))
+ .create();
+ }
+
+ @SuppressWarnings("unchecked")
+ private static Map mapOf(Object... inputs) {
+ Map map = new HashMap<>();
+ for (int i = 0; i < inputs.length; i += 2) {
+ String key = (String) inputs[i];
+ T value = (T) inputs[i + 1];
+ map.put(key, value);
+ }
+ return map;
+ }
+}
+```
+
+### LiveEvents_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for LiveEvents Delete. */
+public final class LiveEventsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveevent-delete.json
+ */
+ /**
+ * Sample code: Delete a LiveEvent.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteALiveEvent(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.liveEvents().delete("mediaresources", "slitestmedia10", "myLiveEvent1", Context.NONE);
+ }
+}
+```
+
+### LiveEvents_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for LiveEvents Get. */
+public final class LiveEventsGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveevent-list-by-name.json
+ */
+ /**
+ * Sample code: Get a LiveEvent by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getALiveEventByName(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.liveEvents().getWithResponse("mediaresources", "slitestmedia10", "myLiveEvent1", Context.NONE);
+ }
+}
+```
+
+### LiveEvents_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for LiveEvents List. */
+public final class LiveEventsListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveevent-list-all.json
+ */
+ /**
+ * Sample code: List all LiveEvents.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAllLiveEvents(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.liveEvents().list("mediaresources", "slitestmedia10", Context.NONE);
+ }
+}
+```
+
+### LiveEvents_Reset
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for LiveEvents Reset. */
+public final class LiveEventsResetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveevent-reset.json
+ */
+ /**
+ * Sample code: Reset a LiveEvent.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void resetALiveEvent(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.liveEvents().reset("mediaresources", "slitestmedia10", "myLiveEvent1", Context.NONE);
+ }
+}
+```
+
+### LiveEvents_Start
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for LiveEvents Start. */
+public final class LiveEventsStartSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveevent-start.json
+ */
+ /**
+ * Sample code: Start a LiveEvent.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void startALiveEvent(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.liveEvents().start("mediaresources", "slitestmedia10", "myLiveEvent1", Context.NONE);
+ }
+}
+```
+
+### LiveEvents_Stop
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.LiveEventActionInput;
+
+/** Samples for LiveEvents Stop. */
+public final class LiveEventsStopSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveevent-stop.json
+ */
+ /**
+ * Sample code: Stop a LiveEvent.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void stopALiveEvent(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .liveEvents()
+ .stop(
+ "mediaresources",
+ "slitestmedia10",
+ "myLiveEvent1",
+ new LiveEventActionInput().withRemoveOutputsOnStop(false),
+ Context.NONE);
+ }
+}
+```
+
+### LiveEvents_Update
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.IpAccessControl;
+import com.azure.resourcemanager.mediaservices.models.IpRange;
+import com.azure.resourcemanager.mediaservices.models.LiveEvent;
+import com.azure.resourcemanager.mediaservices.models.LiveEventInput;
+import com.azure.resourcemanager.mediaservices.models.LiveEventInputAccessControl;
+import com.azure.resourcemanager.mediaservices.models.LiveEventInputProtocol;
+import com.azure.resourcemanager.mediaservices.models.LiveEventPreview;
+import com.azure.resourcemanager.mediaservices.models.LiveEventPreviewAccessControl;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.Map;
+
+/** Samples for LiveEvents Update. */
+public final class LiveEventsUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveevent-update.json
+ */
+ /**
+ * Sample code: Update a LiveEvent.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void updateALiveEvent(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ LiveEvent resource =
+ manager
+ .liveEvents()
+ .getWithResponse("mediaresources", "slitestmedia10", "myLiveEvent1", Context.NONE)
+ .getValue();
+ resource
+ .update()
+ .withTags(mapOf("tag1", "value1", "tag2", "value2", "tag3", "value3"))
+ .withDescription("test event updated")
+ .withInput(
+ new LiveEventInput()
+ .withStreamingProtocol(LiveEventInputProtocol.FRAGMENTED_MP4)
+ .withAccessControl(
+ new LiveEventInputAccessControl()
+ .withIp(
+ new IpAccessControl()
+ .withAllow(
+ Arrays.asList(new IpRange().withName("AllowOne").withAddress("192.1.1.0")))))
+ .withKeyFrameIntervalDuration("PT6S"))
+ .withPreview(
+ new LiveEventPreview()
+ .withAccessControl(
+ new LiveEventPreviewAccessControl()
+ .withIp(
+ new IpAccessControl()
+ .withAllow(
+ Arrays.asList(new IpRange().withName("AllowOne").withAddress("192.1.1.0"))))))
+ .apply();
+ }
+
+ @SuppressWarnings("unchecked")
+ private static Map mapOf(Object... inputs) {
+ Map map = new HashMap<>();
+ for (int i = 0; i < inputs.length; i += 2) {
+ String key = (String) inputs[i];
+ T value = (T) inputs[i + 1];
+ map.put(key, value);
+ }
+ return map;
+ }
+}
+```
+
+### LiveOutputs_Create
+
+```java
+import com.azure.resourcemanager.mediaservices.models.Hls;
+import java.time.Duration;
+
+/** Samples for LiveOutputs Create. */
+public final class LiveOutputsCreateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveoutput-create.json
+ */
+ /**
+ * Sample code: Create a LiveOutput.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createALiveOutput(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .liveOutputs()
+ .define("myLiveOutput1")
+ .withExistingLiveEvent("mediaresources", "slitestmedia10", "myLiveEvent1")
+ .withDescription("test live output 1")
+ .withAssetName("6f3264f5-a189-48b4-a29a-a40f22575212")
+ .withArchiveWindowLength(Duration.parse("PT5M"))
+ .withManifestName("testmanifest")
+ .withHls(new Hls().withFragmentsPerTsSegment(5))
+ .create();
+ }
+}
+```
+
+### LiveOutputs_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for LiveOutputs Delete. */
+public final class LiveOutputsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveoutput-delete.json
+ */
+ /**
+ * Sample code: Delete a LiveOutput.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteALiveOutput(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.liveOutputs().delete("mediaresources", "slitestmedia10", "myLiveEvent1", "myLiveOutput1", Context.NONE);
+ }
+}
+```
+
+### LiveOutputs_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for LiveOutputs Get. */
+public final class LiveOutputsGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveoutput-list-by-name.json
+ */
+ /**
+ * Sample code: Get a LiveOutput by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getALiveOutputByName(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .liveOutputs()
+ .getWithResponse("mediaresources", "slitestmedia10", "myLiveEvent1", "myLiveOutput1", Context.NONE);
+ }
+}
+```
+
+### LiveOutputs_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for LiveOutputs List. */
+public final class LiveOutputsListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/liveoutput-list-all.json
+ */
+ /**
+ * Sample code: List all LiveOutputs.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAllLiveOutputs(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.liveOutputs().list("mediaresources", "slitestmedia10", "myLiveEvent1", Context.NONE);
+ }
+}
+```
+
+### Locations_CheckNameAvailability
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.CheckNameAvailabilityInput;
+
+/** Samples for Locations CheckNameAvailability. */
+public final class LocationsCheckNameAvailabilitySamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accounts-check-name-availability.json
+ */
+ /**
+ * Sample code: Check Name Availability.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void checkNameAvailability(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .locations()
+ .checkNameAvailabilityWithResponse(
+ "japanwest",
+ new CheckNameAvailabilityInput().withName("contosotv").withType("videoAnalyzers"),
+ Context.NONE);
+ }
+}
+```
+
+### Mediaservices_CreateOrUpdate
+
+```java
+import com.azure.resourcemanager.mediaservices.models.AccountEncryption;
+import com.azure.resourcemanager.mediaservices.models.AccountEncryptionKeyType;
+import com.azure.resourcemanager.mediaservices.models.KeyVaultProperties;
+import com.azure.resourcemanager.mediaservices.models.MediaServiceIdentity;
+import com.azure.resourcemanager.mediaservices.models.ResourceIdentity;
+import com.azure.resourcemanager.mediaservices.models.StorageAccount;
+import com.azure.resourcemanager.mediaservices.models.StorageAccountType;
+import com.azure.resourcemanager.mediaservices.models.StorageAuthentication;
+import com.azure.resourcemanager.mediaservices.models.UserAssignedManagedIdentity;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.Map;
+
+/** Samples for Mediaservices CreateOrUpdate. */
+public final class MediaservicesCreateOrUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accounts-create.json
+ */
+ /**
+ * Sample code: Create a Media Services account.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createAMediaServicesAccount(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .mediaservices()
+ .define("contososports")
+ .withRegion("South Central US")
+ .withExistingResourceGroup("contoso")
+ .withTags(mapOf("key1", "value1", "key2", "value2"))
+ .withIdentity(
+ new MediaServiceIdentity()
+ .withType("UserAssigned")
+ .withUserAssignedIdentities(
+ mapOf(
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/id1",
+ new UserAssignedManagedIdentity(),
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/id2",
+ new UserAssignedManagedIdentity())))
+ .withStorageAccounts(
+ Arrays
+ .asList(
+ new StorageAccount()
+ .withId(
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/contoso/providers/Microsoft.Storage/storageAccounts/contososportsstore")
+ .withType(StorageAccountType.PRIMARY)
+ .withIdentity(
+ new ResourceIdentity()
+ .withUserAssignedIdentity(
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/id1")
+ .withUseSystemAssignedIdentity(false))))
+ .withStorageAuthentication(StorageAuthentication.MANAGED_IDENTITY)
+ .withEncryption(
+ new AccountEncryption()
+ .withType(AccountEncryptionKeyType.CUSTOMER_KEY)
+ .withKeyVaultProperties(
+ new KeyVaultProperties().withKeyIdentifier("https://keyvault.vault.azure.net/keys/key1"))
+ .withIdentity(
+ new ResourceIdentity()
+ .withUserAssignedIdentity(
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/id1")
+ .withUseSystemAssignedIdentity(false)))
+ .create();
+ }
+
+ @SuppressWarnings("unchecked")
+ private static Map mapOf(Object... inputs) {
+ Map map = new HashMap<>();
+ for (int i = 0; i < inputs.length; i += 2) {
+ String key = (String) inputs[i];
+ T value = (T) inputs[i + 1];
+ map.put(key, value);
+ }
+ return map;
+ }
+}
+```
+
+### Mediaservices_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Mediaservices Delete. */
+public final class MediaservicesDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accounts-delete.json
+ */
+ /**
+ * Sample code: Delete a Media Services account.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteAMediaServicesAccount(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.mediaservices().deleteWithResponse("contoso", "contososports", Context.NONE);
+ }
+}
+```
+
+### Mediaservices_GetByResourceGroup
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Mediaservices GetByResourceGroup. */
+public final class MediaservicesGetByResourceGroupSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accounts-get-by-name.json
+ */
+ /**
+ * Sample code: Get a Media Services account by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAMediaServicesAccountByName(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.mediaservices().getByResourceGroupWithResponse("contoso", "contosotv", Context.NONE);
+ }
+}
+```
+
+### Mediaservices_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Mediaservices List. */
+public final class MediaservicesListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accounts-subscription-list-all-accounts.json
+ */
+ /**
+ * Sample code: List all Media Services accounts.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAllMediaServicesAccounts(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.mediaservices().list(Context.NONE);
+ }
+}
+```
+
+### Mediaservices_ListByResourceGroup
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Mediaservices ListByResourceGroup. */
+public final class MediaservicesListByResourceGroupSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accounts-list-all-accounts.json
+ */
+ /**
+ * Sample code: List all Media Services accounts.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAllMediaServicesAccounts(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.mediaservices().listByResourceGroup("contoso", Context.NONE);
+ }
+}
+```
+
+### Mediaservices_ListEdgePolicies
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.ListEdgePoliciesInput;
+
+/** Samples for Mediaservices ListEdgePolicies. */
+public final class MediaservicesListEdgePoliciesSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accounts-list-media-edge-policies.json
+ */
+ /**
+ * Sample code: List the media edge policies.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listTheMediaEdgePolicies(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .mediaservices()
+ .listEdgePoliciesWithResponse(
+ "contoso",
+ "contososports",
+ new ListEdgePoliciesInput().withDeviceId("contosiothubhost_contosoiotdevice"),
+ Context.NONE);
+ }
+}
+```
+
+### Mediaservices_SyncStorageKeys
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.SyncStorageKeysInput;
+
+/** Samples for Mediaservices SyncStorageKeys. */
+public final class MediaservicesSyncStorageKeysSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accounts-sync-storage-keys.json
+ */
+ /**
+ * Sample code: Synchronizes Storage Account Keys.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void synchronizesStorageAccountKeys(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .mediaservices()
+ .syncStorageKeysWithResponse(
+ "contoso", "contososports", new SyncStorageKeysInput().withId("contososportsstore"), Context.NONE);
+ }
+}
+```
+
+### Mediaservices_Update
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.MediaService;
+import java.util.HashMap;
+import java.util.Map;
+
+/** Samples for Mediaservices Update. */
+public final class MediaservicesUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/accounts-update.json
+ */
+ /**
+ * Sample code: Update a Media Services accounts.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void updateAMediaServicesAccounts(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ MediaService resource =
+ manager.mediaservices().getByResourceGroupWithResponse("contoso", "contososports", Context.NONE).getValue();
+ resource.update().withTags(mapOf("key1", "value3")).apply();
+ }
+
+ @SuppressWarnings("unchecked")
+ private static Map mapOf(Object... inputs) {
+ Map map = new HashMap<>();
+ for (int i = 0; i < inputs.length; i += 2) {
+ String key = (String) inputs[i];
+ T value = (T) inputs[i + 1];
+ map.put(key, value);
+ }
+ return map;
+ }
+}
+```
+
+### Operations_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Operations List. */
+public final class OperationsListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/operations-list-all.json
+ */
+ /**
+ * Sample code: List Operations.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listOperations(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.operations().listWithResponse(Context.NONE);
+ }
+}
+```
+
+### PrivateEndpointConnections_CreateOrUpdate
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.PrivateEndpointConnection;
+import com.azure.resourcemanager.mediaservices.models.PrivateEndpointServiceConnectionStatus;
+import com.azure.resourcemanager.mediaservices.models.PrivateLinkServiceConnectionState;
+
+/** Samples for PrivateEndpointConnections CreateOrUpdate. */
+public final class PrivateEndpointConnectionsCreateOrUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/private-endpoint-connection-put.json
+ */
+ /**
+ * Sample code: Update private endpoint connection.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void updatePrivateEndpointConnection(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ PrivateEndpointConnection resource =
+ manager
+ .privateEndpointConnections()
+ .getWithResponse("contoso", "contososports", "connectionName1", Context.NONE)
+ .getValue();
+ resource
+ .update()
+ .withPrivateLinkServiceConnectionState(
+ new PrivateLinkServiceConnectionState()
+ .withStatus(PrivateEndpointServiceConnectionStatus.APPROVED)
+ .withDescription("Test description."))
+ .apply();
+ }
+}
+```
+
+### PrivateEndpointConnections_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for PrivateEndpointConnections Delete. */
+public final class PrivateEndpointConnectionsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/private-endpoint-connection-delete.json
+ */
+ /**
+ * Sample code: Delete private endpoint connection.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deletePrivateEndpointConnection(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .privateEndpointConnections()
+ .deleteWithResponse("contoso", "contososports", "connectionName1", Context.NONE);
+ }
+}
+```
+
+### PrivateEndpointConnections_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for PrivateEndpointConnections Get. */
+public final class PrivateEndpointConnectionsGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/private-endpoint-connection-get-by-name.json
+ */
+ /**
+ * Sample code: Get private endpoint connection.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getPrivateEndpointConnection(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .privateEndpointConnections()
+ .getWithResponse("contoso", "contososports", "connectionName1", Context.NONE);
+ }
+}
+```
+
+### PrivateEndpointConnections_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for PrivateEndpointConnections List. */
+public final class PrivateEndpointConnectionsListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/private-endpoint-connection-list.json
+ */
+ /**
+ * Sample code: Get all private endpoint connections.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAllPrivateEndpointConnections(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.privateEndpointConnections().listWithResponse("contoso", "contososports", Context.NONE);
+ }
+}
+```
+
+### PrivateLinkResources_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for PrivateLinkResources Get. */
+public final class PrivateLinkResourcesGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/private-link-resources-get-by-name.json
+ */
+ /**
+ * Sample code: Get details of a group ID.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getDetailsOfAGroupID(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.privateLinkResources().getWithResponse("contoso", "contososports", "keydelivery", Context.NONE);
+ }
+}
+```
+
+### PrivateLinkResources_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for PrivateLinkResources List. */
+public final class PrivateLinkResourcesListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/private-link-resources-list.json
+ */
+ /**
+ * Sample code: Get list of all group IDs.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getListOfAllGroupIDs(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.privateLinkResources().listWithResponse("contoso", "contososports", Context.NONE);
+ }
+}
+```
+
+### StreamingEndpoints_Create
+
+```java
+import com.azure.resourcemanager.mediaservices.models.AkamaiAccessControl;
+import com.azure.resourcemanager.mediaservices.models.AkamaiSignatureHeaderAuthenticationKey;
+import com.azure.resourcemanager.mediaservices.models.IpAccessControl;
+import com.azure.resourcemanager.mediaservices.models.IpRange;
+import com.azure.resourcemanager.mediaservices.models.StreamingEndpointAccessControl;
+import java.time.OffsetDateTime;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.Map;
+
+/** Samples for StreamingEndpoints Create. */
+public final class StreamingEndpointsCreateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streamingendpoint-create.json
+ */
+ /**
+ * Sample code: Create a streaming endpoint.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createAStreamingEndpoint(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingEndpoints()
+ .define("myStreamingEndpoint1")
+ .withRegion("West US")
+ .withExistingMediaservice("mediaresources", "slitestmedia10")
+ .withTags(mapOf("tag1", "value1", "tag2", "value2"))
+ .withDescription("test event 1")
+ .withScaleUnits(1)
+ .withAvailabilitySetName("availableset")
+ .withAccessControl(
+ new StreamingEndpointAccessControl()
+ .withAkamai(
+ new AkamaiAccessControl()
+ .withAkamaiSignatureHeaderAuthenticationKeyList(
+ Arrays
+ .asList(
+ new AkamaiSignatureHeaderAuthenticationKey()
+ .withIdentifier("id1")
+ .withBase64Key("dGVzdGlkMQ==")
+ .withExpiration(OffsetDateTime.parse("2029-12-31T16:00:00-08:00")),
+ new AkamaiSignatureHeaderAuthenticationKey()
+ .withIdentifier("id2")
+ .withBase64Key("dGVzdGlkMQ==")
+ .withExpiration(OffsetDateTime.parse("2030-12-31T16:00:00-08:00")))))
+ .withIp(
+ new IpAccessControl()
+ .withAllow(Arrays.asList(new IpRange().withName("AllowedIp").withAddress("192.168.1.1")))))
+ .withCdnEnabled(false)
+ .create();
+ }
+
+ @SuppressWarnings("unchecked")
+ private static Map mapOf(Object... inputs) {
+ Map map = new HashMap<>();
+ for (int i = 0; i < inputs.length; i += 2) {
+ String key = (String) inputs[i];
+ T value = (T) inputs[i + 1];
+ map.put(key, value);
+ }
+ return map;
+ }
+}
+```
+
+### StreamingEndpoints_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingEndpoints Delete. */
+public final class StreamingEndpointsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streamingendpoint-delete.json
+ */
+ /**
+ * Sample code: Delete a streaming endpoint.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteAStreamingEndpoint(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.streamingEndpoints().delete("mediaresources", "slitestmedia10", "myStreamingEndpoint1", Context.NONE);
+ }
+}
+```
+
+### StreamingEndpoints_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingEndpoints Get. */
+public final class StreamingEndpointsGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streamingendpoint-list-by-name.json
+ */
+ /**
+ * Sample code: Get a streaming endpoint by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAStreamingEndpointByName(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingEndpoints()
+ .getWithResponse("mediaresources", "slitestmedia10", "myStreamingEndpoint1", Context.NONE);
+ }
+}
+```
+
+### StreamingEndpoints_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingEndpoints List. */
+public final class StreamingEndpointsListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streamingendpoint-list-all.json
+ */
+ /**
+ * Sample code: List all streaming endpoints.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listAllStreamingEndpoints(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.streamingEndpoints().list("mediaresources", "slitestmedia10", Context.NONE);
+ }
+}
+```
+
+### StreamingEndpoints_Scale
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.StreamingEntityScaleUnit;
+
+/** Samples for StreamingEndpoints Scale. */
+public final class StreamingEndpointsScaleSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streamingendpoint-scale.json
+ */
+ /**
+ * Sample code: Scale a StreamingEndpoint.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void scaleAStreamingEndpoint(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingEndpoints()
+ .scale(
+ "mediaresources",
+ "slitestmedia10",
+ "myStreamingEndpoint1",
+ new StreamingEntityScaleUnit().withScaleUnit(5),
+ Context.NONE);
+ }
+}
+```
+
+### StreamingEndpoints_Start
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingEndpoints Start. */
+public final class StreamingEndpointsStartSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streamingendpoint-start.json
+ */
+ /**
+ * Sample code: Start a streaming endpoint.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void startAStreamingEndpoint(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.streamingEndpoints().start("mediaresources", "slitestmedia10", "myStreamingEndpoint1", Context.NONE);
+ }
+}
+```
+
+### StreamingEndpoints_Stop
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingEndpoints Stop. */
+public final class StreamingEndpointsStopSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streamingendpoint-stop.json
+ */
+ /**
+ * Sample code: Stop a streaming endpoint.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void stopAStreamingEndpoint(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.streamingEndpoints().stop("mediaresources", "slitestmedia10", "myStreamingEndpoint1", Context.NONE);
+ }
+}
+```
+
+### StreamingEndpoints_Update
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.StreamingEndpoint;
+import java.util.HashMap;
+import java.util.Map;
+
+/** Samples for StreamingEndpoints Update. */
+public final class StreamingEndpointsUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streamingendpoint-update.json
+ */
+ /**
+ * Sample code: Update a streaming endpoint.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void updateAStreamingEndpoint(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ StreamingEndpoint resource =
+ manager
+ .streamingEndpoints()
+ .getWithResponse("mediaresources", "slitestmedia10", "myStreamingEndpoint1", Context.NONE)
+ .getValue();
+ resource
+ .update()
+ .withTags(mapOf("tag3", "value3", "tag5", "value5"))
+ .withDescription("test event 2")
+ .withScaleUnits(5)
+ .withAvailabilitySetName("availableset")
+ .apply();
+ }
+
+ @SuppressWarnings("unchecked")
+ private static Map mapOf(Object... inputs) {
+ Map map = new HashMap<>();
+ for (int i = 0; i < inputs.length; i += 2) {
+ String key = (String) inputs[i];
+ T value = (T) inputs[i + 1];
+ map.put(key, value);
+ }
+ return map;
+ }
+}
+```
+
+### StreamingLocators_Create
+
+```java
+import com.azure.resourcemanager.mediaservices.models.StreamingLocatorContentKey;
+import java.time.OffsetDateTime;
+import java.util.Arrays;
+import java.util.UUID;
+
+/** Samples for StreamingLocators Create. */
+public final class StreamingLocatorsCreateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-locators-create-clear.json
+ */
+ /**
+ * Sample code: Creates a Streaming Locator with clear streaming.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAStreamingLocatorWithClearStreaming(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingLocators()
+ .define("UserCreatedClearStreamingLocator")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withAssetName("ClimbingMountRainier")
+ .withStreamingPolicyName("clearStreamingPolicy")
+ .create();
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-locators-create-secure.json
+ */
+ /**
+ * Sample code: Creates a Streaming Locator with secure streaming.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAStreamingLocatorWithSecureStreaming(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingLocators()
+ .define("UserCreatedSecureStreamingLocator")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withAssetName("ClimbingMountRainier")
+ .withStartTime(OffsetDateTime.parse("2018-03-01T00:00:00Z"))
+ .withEndTime(OffsetDateTime.parse("2028-12-31T23:59:59.9999999Z"))
+ .withStreamingPolicyName("secureStreamingPolicy")
+ .create();
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-locators-create-secure-userDefinedContentKeys.json
+ */
+ /**
+ * Sample code: Creates a Streaming Locator with user defined content keys.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAStreamingLocatorWithUserDefinedContentKeys(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingLocators()
+ .define("UserCreatedSecureStreamingLocatorWithUserDefinedContentKeys")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withAssetName("ClimbingMountRainier")
+ .withStreamingLocatorId(UUID.fromString("90000000-0000-0000-0000-00000000000A"))
+ .withStreamingPolicyName("secureStreamingPolicy")
+ .withContentKeys(
+ Arrays
+ .asList(
+ new StreamingLocatorContentKey()
+ .withId(UUID.fromString("60000000-0000-0000-0000-000000000001"))
+ .withLabelReferenceInStreamingPolicy("aesDefaultKey")
+ .withValue("1UqLohAfWsEGkULYxHjYZg=="),
+ new StreamingLocatorContentKey()
+ .withId(UUID.fromString("60000000-0000-0000-0000-000000000004"))
+ .withLabelReferenceInStreamingPolicy("cencDefaultKey")
+ .withValue("4UqLohAfWsEGkULYxHjYZg=="),
+ new StreamingLocatorContentKey()
+ .withId(UUID.fromString("60000000-0000-0000-0000-000000000007"))
+ .withLabelReferenceInStreamingPolicy("cbcsDefaultKey")
+ .withValue("7UqLohAfWsEGkULYxHjYZg==")))
+ .create();
+ }
+}
+```
+
+### StreamingLocators_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingLocators Delete. */
+public final class StreamingLocatorsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-locators-delete.json
+ */
+ /**
+ * Sample code: Delete a Streaming Locator.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteAStreamingLocator(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingLocators()
+ .deleteWithResponse("contoso", "contosomedia", "clearStreamingLocator", Context.NONE);
+ }
+}
+```
+
+### StreamingLocators_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingLocators Get. */
+public final class StreamingLocatorsGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-locators-get-by-name.json
+ */
+ /**
+ * Sample code: Get a Streaming Locator by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAStreamingLocatorByName(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.streamingLocators().getWithResponse("contoso", "contosomedia", "clearStreamingLocator", Context.NONE);
+ }
+}
+```
+
+### StreamingLocators_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingLocators List. */
+public final class StreamingLocatorsListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-locators-list.json
+ */
+ /**
+ * Sample code: Lists Streaming Locators.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsStreamingLocators(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.streamingLocators().list("contoso", "contosomedia", null, null, null, Context.NONE);
+ }
+}
+```
+
+### StreamingLocators_ListContentKeys
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingLocators ListContentKeys. */
+public final class StreamingLocatorsListContentKeysSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-locators-list-content-keys.json
+ */
+ /**
+ * Sample code: List Content Keys.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listContentKeys(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingLocators()
+ .listContentKeysWithResponse("contoso", "contosomedia", "secureStreamingLocator", Context.NONE);
+ }
+}
+```
+
+### StreamingLocators_ListPaths
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingLocators ListPaths. */
+public final class StreamingLocatorsListPathsSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-locators-list-paths-streaming-only.json
+ */
+ /**
+ * Sample code: List Paths which has streaming paths only.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listPathsWhichHasStreamingPathsOnly(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingLocators()
+ .listPathsWithResponse("contoso", "contosomedia", "secureStreamingLocator", Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-locators-list-paths-streaming-and-download.json
+ */
+ /**
+ * Sample code: List Paths which has streaming paths and download paths.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listPathsWhichHasStreamingPathsAndDownloadPaths(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingLocators()
+ .listPathsWithResponse("contoso", "contosomedia", "clearStreamingLocator", Context.NONE);
+ }
+}
+```
+
+### StreamingPolicies_Create
+
+```java
+import com.azure.resourcemanager.mediaservices.models.CbcsDrmConfiguration;
+import com.azure.resourcemanager.mediaservices.models.CencDrmConfiguration;
+import com.azure.resourcemanager.mediaservices.models.CommonEncryptionCbcs;
+import com.azure.resourcemanager.mediaservices.models.CommonEncryptionCenc;
+import com.azure.resourcemanager.mediaservices.models.DefaultKey;
+import com.azure.resourcemanager.mediaservices.models.EnabledProtocols;
+import com.azure.resourcemanager.mediaservices.models.EnvelopeEncryption;
+import com.azure.resourcemanager.mediaservices.models.NoEncryption;
+import com.azure.resourcemanager.mediaservices.models.StreamingPolicyContentKeys;
+import com.azure.resourcemanager.mediaservices.models.StreamingPolicyFairPlayConfiguration;
+import com.azure.resourcemanager.mediaservices.models.StreamingPolicyPlayReadyConfiguration;
+import com.azure.resourcemanager.mediaservices.models.StreamingPolicyWidevineConfiguration;
+import com.azure.resourcemanager.mediaservices.models.TrackPropertyCompareOperation;
+import com.azure.resourcemanager.mediaservices.models.TrackPropertyCondition;
+import com.azure.resourcemanager.mediaservices.models.TrackPropertyType;
+import com.azure.resourcemanager.mediaservices.models.TrackSelection;
+import java.util.Arrays;
+
+/** Samples for StreamingPolicies Create. */
+public final class StreamingPoliciesCreateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-policies-create-secure-streaming.json
+ */
+ /**
+ * Sample code: Creates a Streaming Policy with secure streaming.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAStreamingPolicyWithSecureStreaming(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingPolicies()
+ .define("UserCreatedSecureStreamingPolicy")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withDefaultContentKeyPolicyName("PolicyWithMultipleOptions")
+ .withEnvelopeEncryption(
+ new EnvelopeEncryption()
+ .withEnabledProtocols(
+ new EnabledProtocols()
+ .withDownload(false)
+ .withDash(true)
+ .withHls(true)
+ .withSmoothStreaming(true))
+ .withContentKeys(
+ new StreamingPolicyContentKeys().withDefaultKey(new DefaultKey().withLabel("aesDefaultKey")))
+ .withCustomKeyAcquisitionUrlTemplate(
+ "https://contoso.com/{AssetAlternativeId}/envelope/{ContentKeyId}"))
+ .withCommonEncryptionCenc(
+ new CommonEncryptionCenc()
+ .withEnabledProtocols(
+ new EnabledProtocols()
+ .withDownload(false)
+ .withDash(true)
+ .withHls(false)
+ .withSmoothStreaming(true))
+ .withClearTracks(
+ Arrays
+ .asList(
+ new TrackSelection()
+ .withTrackSelections(
+ Arrays
+ .asList(
+ new TrackPropertyCondition()
+ .withProperty(TrackPropertyType.FOUR_CC)
+ .withOperation(TrackPropertyCompareOperation.EQUAL)
+ .withValue("hev1")))))
+ .withContentKeys(
+ new StreamingPolicyContentKeys().withDefaultKey(new DefaultKey().withLabel("cencDefaultKey")))
+ .withDrm(
+ new CencDrmConfiguration()
+ .withPlayReady(
+ new StreamingPolicyPlayReadyConfiguration()
+ .withCustomLicenseAcquisitionUrlTemplate(
+ "https://contoso.com/{AssetAlternativeId}/playready/{ContentKeyId}")
+ .withPlayReadyCustomAttributes("PlayReady CustomAttributes"))
+ .withWidevine(
+ new StreamingPolicyWidevineConfiguration()
+ .withCustomLicenseAcquisitionUrlTemplate(
+ "https://contoso.com/{AssetAlternativeId}/widevine/{ContentKeyId"))))
+ .withCommonEncryptionCbcs(
+ new CommonEncryptionCbcs()
+ .withEnabledProtocols(
+ new EnabledProtocols()
+ .withDownload(false)
+ .withDash(false)
+ .withHls(true)
+ .withSmoothStreaming(false))
+ .withContentKeys(
+ new StreamingPolicyContentKeys().withDefaultKey(new DefaultKey().withLabel("cbcsDefaultKey")))
+ .withDrm(
+ new CbcsDrmConfiguration()
+ .withFairPlay(
+ new StreamingPolicyFairPlayConfiguration()
+ .withCustomLicenseAcquisitionUrlTemplate(
+ "https://contoso.com/{AssetAlternativeId}/fairplay/{ContentKeyId}")
+ .withAllowPersistentLicense(true))))
+ .create();
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-policies-create-commonEncryptionCenc-only.json
+ */
+ /**
+ * Sample code: Creates a Streaming Policy with commonEncryptionCenc only.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAStreamingPolicyWithCommonEncryptionCencOnly(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingPolicies()
+ .define("UserCreatedSecureStreamingPolicyWithCommonEncryptionCencOnly")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withDefaultContentKeyPolicyName("PolicyWithPlayReadyOptionAndOpenRestriction")
+ .withCommonEncryptionCenc(
+ new CommonEncryptionCenc()
+ .withEnabledProtocols(
+ new EnabledProtocols()
+ .withDownload(false)
+ .withDash(true)
+ .withHls(false)
+ .withSmoothStreaming(true))
+ .withClearTracks(
+ Arrays
+ .asList(
+ new TrackSelection()
+ .withTrackSelections(
+ Arrays
+ .asList(
+ new TrackPropertyCondition()
+ .withProperty(TrackPropertyType.FOUR_CC)
+ .withOperation(TrackPropertyCompareOperation.EQUAL)
+ .withValue("hev1")))))
+ .withContentKeys(
+ new StreamingPolicyContentKeys().withDefaultKey(new DefaultKey().withLabel("cencDefaultKey")))
+ .withDrm(
+ new CencDrmConfiguration()
+ .withPlayReady(
+ new StreamingPolicyPlayReadyConfiguration()
+ .withCustomLicenseAcquisitionUrlTemplate(
+ "https://contoso.com/{AssetAlternativeId}/playready/{ContentKeyId}")
+ .withPlayReadyCustomAttributes("PlayReady CustomAttributes"))
+ .withWidevine(
+ new StreamingPolicyWidevineConfiguration()
+ .withCustomLicenseAcquisitionUrlTemplate(
+ "https://contoso.com/{AssetAlternativeId}/widevine/{ContentKeyId"))))
+ .create();
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-policies-create-commonEncryptionCbcs-only.json
+ */
+ /**
+ * Sample code: Creates a Streaming Policy with commonEncryptionCbcs only.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAStreamingPolicyWithCommonEncryptionCbcsOnly(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingPolicies()
+ .define("UserCreatedSecureStreamingPolicyWithCommonEncryptionCbcsOnly")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withDefaultContentKeyPolicyName("PolicyWithMultipleOptions")
+ .withCommonEncryptionCbcs(
+ new CommonEncryptionCbcs()
+ .withEnabledProtocols(
+ new EnabledProtocols()
+ .withDownload(false)
+ .withDash(false)
+ .withHls(true)
+ .withSmoothStreaming(false))
+ .withContentKeys(
+ new StreamingPolicyContentKeys().withDefaultKey(new DefaultKey().withLabel("cbcsDefaultKey")))
+ .withDrm(
+ new CbcsDrmConfiguration()
+ .withFairPlay(
+ new StreamingPolicyFairPlayConfiguration()
+ .withCustomLicenseAcquisitionUrlTemplate(
+ "https://contoso.com/{AssetAlternativeId}/fairplay/{ContentKeyId}")
+ .withAllowPersistentLicense(true))))
+ .create();
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-policies-create-clear.json
+ */
+ /**
+ * Sample code: Creates a Streaming Policy with clear streaming.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAStreamingPolicyWithClearStreaming(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingPolicies()
+ .define("UserCreatedClearStreamingPolicy")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withNoEncryption(
+ new NoEncryption()
+ .withEnabledProtocols(
+ new EnabledProtocols()
+ .withDownload(true)
+ .withDash(true)
+ .withHls(true)
+ .withSmoothStreaming(true)))
+ .create();
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-policies-create-envelopeEncryption-only.json
+ */
+ /**
+ * Sample code: Creates a Streaming Policy with envelopeEncryption only.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createsAStreamingPolicyWithEnvelopeEncryptionOnly(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingPolicies()
+ .define("UserCreatedSecureStreamingPolicyWithEnvelopeEncryptionOnly")
+ .withExistingMediaService("contoso", "contosomedia")
+ .withDefaultContentKeyPolicyName("PolicyWithClearKeyOptionAndTokenRestriction")
+ .withEnvelopeEncryption(
+ new EnvelopeEncryption()
+ .withEnabledProtocols(
+ new EnabledProtocols()
+ .withDownload(false)
+ .withDash(true)
+ .withHls(true)
+ .withSmoothStreaming(true))
+ .withContentKeys(
+ new StreamingPolicyContentKeys().withDefaultKey(new DefaultKey().withLabel("aesDefaultKey")))
+ .withCustomKeyAcquisitionUrlTemplate(
+ "https://contoso.com/{AssetAlternativeId}/envelope/{ContentKeyId}"))
+ .create();
+ }
+}
+```
+
+### StreamingPolicies_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingPolicies Delete. */
+public final class StreamingPoliciesDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-policies-delete.json
+ */
+ /**
+ * Sample code: Delete a Streaming Policy.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteAStreamingPolicy(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .streamingPolicies()
+ .deleteWithResponse(
+ "contoso", "contosomedia", "secureStreamingPolicyWithCommonEncryptionCbcsOnly", Context.NONE);
+ }
+}
+```
+
+### StreamingPolicies_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingPolicies Get. */
+public final class StreamingPoliciesGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-policy-get-by-name.json
+ */
+ /**
+ * Sample code: Get a Streaming Policy by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getAStreamingPolicyByName(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.streamingPolicies().getWithResponse("contoso", "contosomedia", "clearStreamingPolicy", Context.NONE);
+ }
+}
+```
+
+### StreamingPolicies_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for StreamingPolicies List. */
+public final class StreamingPoliciesListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/streaming-policies-list.json
+ */
+ /**
+ * Sample code: Lists Streaming Policies.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsStreamingPolicies(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.streamingPolicies().list("contoso", "contosomedia", null, null, null, Context.NONE);
+ }
+}
+```
+
+### Transforms_CreateOrUpdate
+
+```java
+import com.azure.resourcemanager.mediaservices.models.BuiltInStandardEncoderPreset;
+import com.azure.resourcemanager.mediaservices.models.EncoderNamedPreset;
+import com.azure.resourcemanager.mediaservices.models.TransformOutput;
+import java.util.Arrays;
+
+/** Samples for Transforms CreateOrUpdate. */
+public final class TransformsCreateOrUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/transforms-create.json
+ */
+ /**
+ * Sample code: Create or update a Transform.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void createOrUpdateATransform(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .transforms()
+ .define("createdTransform")
+ .withExistingMediaService("contosoresources", "contosomedia")
+ .withDescription("Example Transform to illustrate create and update.")
+ .withOutputs(
+ Arrays
+ .asList(
+ new TransformOutput()
+ .withPreset(
+ new BuiltInStandardEncoderPreset()
+ .withPresetName(EncoderNamedPreset.ADAPTIVE_STREAMING))))
+ .create();
+ }
+}
+```
+
+### Transforms_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Transforms Delete. */
+public final class TransformsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/transforms-delete.json
+ */
+ /**
+ * Sample code: Delete a Transform.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void deleteATransform(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.transforms().deleteWithResponse("contosoresources", "contosomedia", "sampleTransform", Context.NONE);
+ }
+}
+```
+
+### Transforms_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Transforms Get. */
+public final class TransformsGetSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/transforms-get-by-name.json
+ */
+ /**
+ * Sample code: Get a Transform by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void getATransformByName(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.transforms().getWithResponse("contosoresources", "contosomedia", "sampleTransform", Context.NONE);
+ }
+}
+```
+
+### Transforms_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Transforms List. */
+public final class TransformsListSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/transforms-list-all-filter-by-created.json
+ */
+ /**
+ * Sample code: Lists the Transforms filter by created.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsTheTransformsFilterByCreated(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .transforms()
+ .list(
+ "contosoresources",
+ "contosomedia",
+ "properties/created gt 2021-06-01T00:00:00.0000000Z and properties/created le"
+ + " 2021-06-01T00:00:10.0000000Z",
+ "properties/created",
+ Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/transforms-list-all-filter-by-name.json
+ */
+ /**
+ * Sample code: Lists the Transforms filter by name.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsTheTransformsFilterByName(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .transforms()
+ .list(
+ "contosoresources",
+ "contosomedia",
+ "(name eq 'sampleEncode') or (name eq 'sampleEncodeAndVideoIndex')",
+ "name desc",
+ Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/transforms-list-all-filter-by-lastmodified.json
+ */
+ /**
+ * Sample code: Lists the Transforms filter by lastmodified.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsTheTransformsFilterByLastmodified(
+ com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager
+ .transforms()
+ .list(
+ "contosoresources",
+ "contosomedia",
+ "properties/lastmodified gt 2021-06-01T00:00:00.0000000Z and properties/lastmodified le"
+ + " 2021-06-01T00:00:10.0000000Z",
+ "properties/lastmodified desc",
+ Context.NONE);
+ }
+
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/transforms-list-all.json
+ */
+ /**
+ * Sample code: Lists the Transforms.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void listsTheTransforms(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ manager.transforms().list("contosoresources", "contosomedia", null, null, Context.NONE);
+ }
+}
+```
+
+### Transforms_Update
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.mediaservices.models.BuiltInStandardEncoderPreset;
+import com.azure.resourcemanager.mediaservices.models.EncoderNamedPreset;
+import com.azure.resourcemanager.mediaservices.models.Priority;
+import com.azure.resourcemanager.mediaservices.models.Transform;
+import com.azure.resourcemanager.mediaservices.models.TransformOutput;
+import java.util.Arrays;
+
+/** Samples for Transforms Update. */
+public final class TransformsUpdateSamples {
+ /*
+ * x-ms-original-file: specification/mediaservices/resource-manager/Microsoft.Media/stable/2021-06-01/examples/transforms-update.json
+ */
+ /**
+ * Sample code: Update a Transform.
+ *
+ * @param manager Entry point to MediaServicesManager.
+ */
+ public static void updateATransform(com.azure.resourcemanager.mediaservices.MediaServicesManager manager) {
+ Transform resource =
+ manager
+ .transforms()
+ .getWithResponse("contosoresources", "contosomedia", "transformToUpdate", Context.NONE)
+ .getValue();
+ resource
+ .update()
+ .withDescription("Example transform to illustrate update.")
+ .withOutputs(
+ Arrays
+ .asList(
+ new TransformOutput()
+ .withRelativePriority(Priority.HIGH)
+ .withPreset(
+ new BuiltInStandardEncoderPreset()
+ .withPresetName(EncoderNamedPreset.H264MULTIPLE_BITRATE720P))))
+ .apply();
+ }
+}
+```
-- [CreateOrUpdate](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/TransformsCreateOrUpdateSamples.java)
-- [Delete](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/TransformsDeleteSamples.java)
-- [Get](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/TransformsGetSamples.java)
-- [List](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/TransformsListSamples.java)
-- [Update](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/mediaservices/azure-resourcemanager-mediaservices/src/samples/java/com/azure/resourcemanager/mediaservices/TransformsUpdateSamples.java)
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/pom.xml b/sdk/mediaservices/azure-resourcemanager-mediaservices/pom.xml
index a88741f07ef0..6401ff620165 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/pom.xml
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/pom.xml
@@ -67,7 +67,6 @@
revapi-maven-plugin
0.11.2
- true
-
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/MediaServicesManager.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/MediaServicesManager.java
index 056bd0d3a1d5..c1afc5be9160 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/MediaServicesManager.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/MediaServicesManager.java
@@ -230,7 +230,7 @@ public MediaServicesManager authenticate(TokenCredential credential, AzureProfil
.append("-")
.append("com.azure.resourcemanager.mediaservices")
.append("/")
- .append("1.1.0-beta.2");
+ .append("1.0.0-beta.1");
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
userAgentBuilder
.append(" (")
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/LiveEventsClient.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/LiveEventsClient.java
index a08ead220ef7..07fa1709e92f 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/LiveEventsClient.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/LiveEventsClient.java
@@ -24,7 +24,7 @@ public interface LiveEventsClient {
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the LiveEvent list result.
+ * @return liveEventListResult.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
PagedIterable list(String resourceGroupName, String accountName);
@@ -38,7 +38,7 @@ public interface LiveEventsClient {
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the LiveEvent list result.
+ * @return liveEventListResult.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
PagedIterable list(String resourceGroupName, String accountName, Context context);
@@ -86,7 +86,7 @@ Response getWithResponse(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, LiveEventInner> beginCreate(
String resourceGroupName,
String accountName,
@@ -108,7 +108,7 @@ SyncPoller, LiveEventInner> beginCreate(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, LiveEventInner> beginCreate(
String resourceGroupName,
String accountName,
@@ -189,7 +189,7 @@ LiveEventInner create(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, LiveEventInner> beginUpdate(
String resourceGroupName, String accountName, String liveEventName, LiveEventInner parameters);
@@ -206,7 +206,7 @@ SyncPoller, LiveEventInner> beginUpdate(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, LiveEventInner> beginUpdate(
String resourceGroupName, String accountName, String liveEventName, LiveEventInner parameters, Context context);
@@ -254,7 +254,7 @@ LiveEventInner update(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginDelete(String resourceGroupName, String accountName, String liveEventName);
/**
@@ -269,7 +269,7 @@ LiveEventInner update(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginDelete(
String resourceGroupName, String accountName, String liveEventName, Context context);
@@ -311,7 +311,7 @@ SyncPoller, Void> beginDelete(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginAllocate(
String resourceGroupName, String accountName, String liveEventName);
@@ -327,7 +327,7 @@ SyncPoller, Void> beginAllocate(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginAllocate(
String resourceGroupName, String accountName, String liveEventName, Context context);
@@ -369,7 +369,7 @@ SyncPoller, Void> beginAllocate(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginStart(String resourceGroupName, String accountName, String liveEventName);
/**
@@ -384,7 +384,7 @@ SyncPoller, Void> beginAllocate(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginStart(
String resourceGroupName, String accountName, String liveEventName, Context context);
@@ -427,7 +427,7 @@ SyncPoller, Void> beginStart(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginStop(
String resourceGroupName, String accountName, String liveEventName, LiveEventActionInput parameters);
@@ -444,7 +444,7 @@ SyncPoller, Void> beginStop(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginStop(
String resourceGroupName,
String accountName,
@@ -499,7 +499,7 @@ void stop(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginReset(String resourceGroupName, String accountName, String liveEventName);
/**
@@ -516,7 +516,7 @@ void stop(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginReset(
String resourceGroupName, String accountName, String liveEventName, Context context);
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/LiveOutputsClient.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/LiveOutputsClient.java
index f02c8906e67a..85565db98ba9 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/LiveOutputsClient.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/LiveOutputsClient.java
@@ -24,7 +24,7 @@ public interface LiveOutputsClient {
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the LiveOutput list result.
+ * @return liveOutputListResult.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
PagedIterable list(String resourceGroupName, String accountName, String liveEventName);
@@ -39,7 +39,7 @@ public interface LiveOutputsClient {
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the LiveOutput list result.
+ * @return liveOutputListResult.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
PagedIterable list(
@@ -90,7 +90,7 @@ Response getWithResponse(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the Live Output.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, LiveOutputInner> beginCreate(
String resourceGroupName,
String accountName,
@@ -112,7 +112,7 @@ SyncPoller, LiveOutputInner> beginCreate(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the Live Output.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, LiveOutputInner> beginCreate(
String resourceGroupName,
String accountName,
@@ -177,7 +177,7 @@ LiveOutputInner create(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginDelete(
String resourceGroupName, String accountName, String liveEventName, String liveOutputName);
@@ -194,7 +194,7 @@ SyncPoller, Void> beginDelete(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginDelete(
String resourceGroupName, String accountName, String liveEventName, String liveOutputName, Context context);
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/StreamingEndpointsClient.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/StreamingEndpointsClient.java
index 26cb0f6ae3d2..876bcf2870b8 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/StreamingEndpointsClient.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/StreamingEndpointsClient.java
@@ -24,7 +24,7 @@ public interface StreamingEndpointsClient {
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the streaming endpoint list result.
+ * @return streamingEndpointListResult.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
PagedIterable list(String resourceGroupName, String accountName);
@@ -38,7 +38,7 @@ public interface StreamingEndpointsClient {
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the streaming endpoint list result.
+ * @return streamingEndpointListResult.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
PagedIterable list(String resourceGroupName, String accountName, Context context);
@@ -86,7 +86,7 @@ Response getWithResponse(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the streaming endpoint.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, StreamingEndpointInner> beginCreate(
String resourceGroupName,
String accountName,
@@ -108,7 +108,7 @@ SyncPoller, StreamingEndpointInner> beginCrea
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the streaming endpoint.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, StreamingEndpointInner> beginCreate(
String resourceGroupName,
String accountName,
@@ -189,7 +189,7 @@ StreamingEndpointInner create(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the streaming endpoint.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, StreamingEndpointInner> beginUpdate(
String resourceGroupName, String accountName, String streamingEndpointName, StreamingEndpointInner parameters);
@@ -206,7 +206,7 @@ SyncPoller, StreamingEndpointInner> beginUpda
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the streaming endpoint.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, StreamingEndpointInner> beginUpdate(
String resourceGroupName,
String accountName,
@@ -262,7 +262,7 @@ StreamingEndpointInner update(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginDelete(
String resourceGroupName, String accountName, String streamingEndpointName);
@@ -278,7 +278,7 @@ SyncPoller, Void> beginDelete(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginDelete(
String resourceGroupName, String accountName, String streamingEndpointName, Context context);
@@ -320,7 +320,7 @@ SyncPoller, Void> beginDelete(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginStart(
String resourceGroupName, String accountName, String streamingEndpointName);
@@ -336,7 +336,7 @@ SyncPoller, Void> beginStart(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginStart(
String resourceGroupName, String accountName, String streamingEndpointName, Context context);
@@ -378,7 +378,7 @@ SyncPoller, Void> beginStart(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginStop(
String resourceGroupName, String accountName, String streamingEndpointName);
@@ -394,7 +394,7 @@ SyncPoller, Void> beginStop(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginStop(
String resourceGroupName, String accountName, String streamingEndpointName, Context context);
@@ -437,7 +437,7 @@ SyncPoller, Void> beginStop(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginScale(
String resourceGroupName,
String accountName,
@@ -457,7 +457,7 @@ SyncPoller, Void> beginScale(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
SyncPoller, Void> beginScale(
String resourceGroupName,
String accountName,
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AccountFilterInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AccountFilterInner.java
index 2f5568962d98..88809436fcab 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AccountFilterInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AccountFilterInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -17,34 +16,30 @@
import java.util.List;
/** An Account Filter. */
-@JsonFlatten
@Fluent
-public class AccountFilterInner extends ProxyResource {
+public final class AccountFilterInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(AccountFilterInner.class);
/*
- * The system metadata relating to this resource.
+ * The Media Filter properties.
*/
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
+ @JsonProperty(value = "properties")
+ private MediaFilterProperties innerProperties;
/*
- * The presentation time range.
- */
- @JsonProperty(value = "properties.presentationTimeRange")
- private PresentationTimeRange presentationTimeRange;
-
- /*
- * The first quality.
+ * The system metadata relating to this resource.
*/
- @JsonProperty(value = "properties.firstQuality")
- private FirstQuality firstQuality;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData systemData;
- /*
- * The tracks selection conditions.
+ /**
+ * Get the innerProperties property: The Media Filter properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.tracks")
- private List tracks;
+ private MediaFilterProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the systemData property: The system metadata relating to this resource.
@@ -61,7 +56,7 @@ public SystemData systemData() {
* @return the presentationTimeRange value.
*/
public PresentationTimeRange presentationTimeRange() {
- return this.presentationTimeRange;
+ return this.innerProperties() == null ? null : this.innerProperties().presentationTimeRange();
}
/**
@@ -71,7 +66,10 @@ public PresentationTimeRange presentationTimeRange() {
* @return the AccountFilterInner object itself.
*/
public AccountFilterInner withPresentationTimeRange(PresentationTimeRange presentationTimeRange) {
- this.presentationTimeRange = presentationTimeRange;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MediaFilterProperties();
+ }
+ this.innerProperties().withPresentationTimeRange(presentationTimeRange);
return this;
}
@@ -81,7 +79,7 @@ public AccountFilterInner withPresentationTimeRange(PresentationTimeRange presen
* @return the firstQuality value.
*/
public FirstQuality firstQuality() {
- return this.firstQuality;
+ return this.innerProperties() == null ? null : this.innerProperties().firstQuality();
}
/**
@@ -91,7 +89,10 @@ public FirstQuality firstQuality() {
* @return the AccountFilterInner object itself.
*/
public AccountFilterInner withFirstQuality(FirstQuality firstQuality) {
- this.firstQuality = firstQuality;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MediaFilterProperties();
+ }
+ this.innerProperties().withFirstQuality(firstQuality);
return this;
}
@@ -101,7 +102,7 @@ public AccountFilterInner withFirstQuality(FirstQuality firstQuality) {
* @return the tracks value.
*/
public List tracks() {
- return this.tracks;
+ return this.innerProperties() == null ? null : this.innerProperties().tracks();
}
/**
@@ -111,7 +112,10 @@ public List tracks() {
* @return the AccountFilterInner object itself.
*/
public AccountFilterInner withTracks(List tracks) {
- this.tracks = tracks;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MediaFilterProperties();
+ }
+ this.innerProperties().withTracks(tracks);
return this;
}
@@ -121,14 +125,8 @@ public AccountFilterInner withTracks(List tracks) {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (presentationTimeRange() != null) {
- presentationTimeRange().validate();
- }
- if (firstQuality() != null) {
- firstQuality().validate();
- }
- if (tracks() != null) {
- tracks().forEach(e -> e.validate());
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AssetFilterInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AssetFilterInner.java
index be566f6265db..28844db4d536 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AssetFilterInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AssetFilterInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -17,34 +16,30 @@
import java.util.List;
/** An Asset Filter. */
-@JsonFlatten
@Fluent
-public class AssetFilterInner extends ProxyResource {
+public final class AssetFilterInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(AssetFilterInner.class);
/*
- * The system metadata relating to this resource.
+ * The Media Filter properties.
*/
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
+ @JsonProperty(value = "properties")
+ private MediaFilterProperties innerProperties;
/*
- * The presentation time range.
- */
- @JsonProperty(value = "properties.presentationTimeRange")
- private PresentationTimeRange presentationTimeRange;
-
- /*
- * The first quality.
+ * The system metadata relating to this resource.
*/
- @JsonProperty(value = "properties.firstQuality")
- private FirstQuality firstQuality;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData systemData;
- /*
- * The tracks selection conditions.
+ /**
+ * Get the innerProperties property: The Media Filter properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.tracks")
- private List tracks;
+ private MediaFilterProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the systemData property: The system metadata relating to this resource.
@@ -61,7 +56,7 @@ public SystemData systemData() {
* @return the presentationTimeRange value.
*/
public PresentationTimeRange presentationTimeRange() {
- return this.presentationTimeRange;
+ return this.innerProperties() == null ? null : this.innerProperties().presentationTimeRange();
}
/**
@@ -71,7 +66,10 @@ public PresentationTimeRange presentationTimeRange() {
* @return the AssetFilterInner object itself.
*/
public AssetFilterInner withPresentationTimeRange(PresentationTimeRange presentationTimeRange) {
- this.presentationTimeRange = presentationTimeRange;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MediaFilterProperties();
+ }
+ this.innerProperties().withPresentationTimeRange(presentationTimeRange);
return this;
}
@@ -81,7 +79,7 @@ public AssetFilterInner withPresentationTimeRange(PresentationTimeRange presenta
* @return the firstQuality value.
*/
public FirstQuality firstQuality() {
- return this.firstQuality;
+ return this.innerProperties() == null ? null : this.innerProperties().firstQuality();
}
/**
@@ -91,7 +89,10 @@ public FirstQuality firstQuality() {
* @return the AssetFilterInner object itself.
*/
public AssetFilterInner withFirstQuality(FirstQuality firstQuality) {
- this.firstQuality = firstQuality;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MediaFilterProperties();
+ }
+ this.innerProperties().withFirstQuality(firstQuality);
return this;
}
@@ -101,7 +102,7 @@ public AssetFilterInner withFirstQuality(FirstQuality firstQuality) {
* @return the tracks value.
*/
public List tracks() {
- return this.tracks;
+ return this.innerProperties() == null ? null : this.innerProperties().tracks();
}
/**
@@ -111,7 +112,10 @@ public List tracks() {
* @return the AssetFilterInner object itself.
*/
public AssetFilterInner withTracks(List tracks) {
- this.tracks = tracks;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MediaFilterProperties();
+ }
+ this.innerProperties().withTracks(tracks);
return this;
}
@@ -121,14 +125,8 @@ public AssetFilterInner withTracks(List tracks) {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (presentationTimeRange() != null) {
- presentationTimeRange().validate();
- }
- if (firstQuality() != null) {
- firstQuality().validate();
- }
- if (tracks() != null) {
- tracks().forEach(e -> e.validate());
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AssetInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AssetInner.java
index 46786ef6cb8b..cdce8ffe67f4 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AssetInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AssetInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -16,64 +15,30 @@
import java.util.UUID;
/** An Asset. */
-@JsonFlatten
@Fluent
-public class AssetInner extends ProxyResource {
+public final class AssetInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(AssetInner.class);
/*
- * The system metadata relating to this resource.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /*
- * The Asset ID.
- */
- @JsonProperty(value = "properties.assetId", access = JsonProperty.Access.WRITE_ONLY)
- private UUID assetId;
-
- /*
- * The creation date of the Asset.
- */
- @JsonProperty(value = "properties.created", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime created;
-
- /*
- * The last modified date of the Asset.
- */
- @JsonProperty(value = "properties.lastModified", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime lastModified;
-
- /*
- * The alternate ID of the Asset.
- */
- @JsonProperty(value = "properties.alternateId")
- private String alternateId;
-
- /*
- * The Asset description.
- */
- @JsonProperty(value = "properties.description")
- private String description;
-
- /*
- * The name of the asset blob container.
+ * The resource properties.
*/
- @JsonProperty(value = "properties.container")
- private String container;
+ @JsonProperty(value = "properties")
+ private AssetProperties innerProperties;
/*
- * The name of the storage account.
+ * The system metadata relating to this resource.
*/
- @JsonProperty(value = "properties.storageAccountName")
- private String storageAccountName;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData systemData;
- /*
- * The Asset encryption format. One of None or MediaStorageEncryption.
+ /**
+ * Get the innerProperties property: The resource properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.storageEncryptionFormat", access = JsonProperty.Access.WRITE_ONLY)
- private AssetStorageEncryptionFormat storageEncryptionFormat;
+ private AssetProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the systemData property: The system metadata relating to this resource.
@@ -90,7 +55,7 @@ public SystemData systemData() {
* @return the assetId value.
*/
public UUID assetId() {
- return this.assetId;
+ return this.innerProperties() == null ? null : this.innerProperties().assetId();
}
/**
@@ -99,7 +64,7 @@ public UUID assetId() {
* @return the created value.
*/
public OffsetDateTime created() {
- return this.created;
+ return this.innerProperties() == null ? null : this.innerProperties().created();
}
/**
@@ -108,7 +73,7 @@ public OffsetDateTime created() {
* @return the lastModified value.
*/
public OffsetDateTime lastModified() {
- return this.lastModified;
+ return this.innerProperties() == null ? null : this.innerProperties().lastModified();
}
/**
@@ -117,7 +82,7 @@ public OffsetDateTime lastModified() {
* @return the alternateId value.
*/
public String alternateId() {
- return this.alternateId;
+ return this.innerProperties() == null ? null : this.innerProperties().alternateId();
}
/**
@@ -127,7 +92,10 @@ public String alternateId() {
* @return the AssetInner object itself.
*/
public AssetInner withAlternateId(String alternateId) {
- this.alternateId = alternateId;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new AssetProperties();
+ }
+ this.innerProperties().withAlternateId(alternateId);
return this;
}
@@ -137,7 +105,7 @@ public AssetInner withAlternateId(String alternateId) {
* @return the description value.
*/
public String description() {
- return this.description;
+ return this.innerProperties() == null ? null : this.innerProperties().description();
}
/**
@@ -147,7 +115,10 @@ public String description() {
* @return the AssetInner object itself.
*/
public AssetInner withDescription(String description) {
- this.description = description;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new AssetProperties();
+ }
+ this.innerProperties().withDescription(description);
return this;
}
@@ -157,7 +128,7 @@ public AssetInner withDescription(String description) {
* @return the container value.
*/
public String container() {
- return this.container;
+ return this.innerProperties() == null ? null : this.innerProperties().container();
}
/**
@@ -167,7 +138,10 @@ public String container() {
* @return the AssetInner object itself.
*/
public AssetInner withContainer(String container) {
- this.container = container;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new AssetProperties();
+ }
+ this.innerProperties().withContainer(container);
return this;
}
@@ -177,7 +151,7 @@ public AssetInner withContainer(String container) {
* @return the storageAccountName value.
*/
public String storageAccountName() {
- return this.storageAccountName;
+ return this.innerProperties() == null ? null : this.innerProperties().storageAccountName();
}
/**
@@ -187,7 +161,10 @@ public String storageAccountName() {
* @return the AssetInner object itself.
*/
public AssetInner withStorageAccountName(String storageAccountName) {
- this.storageAccountName = storageAccountName;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new AssetProperties();
+ }
+ this.innerProperties().withStorageAccountName(storageAccountName);
return this;
}
@@ -197,7 +174,7 @@ public AssetInner withStorageAccountName(String storageAccountName) {
* @return the storageEncryptionFormat value.
*/
public AssetStorageEncryptionFormat storageEncryptionFormat() {
- return this.storageEncryptionFormat;
+ return this.innerProperties() == null ? null : this.innerProperties().storageEncryptionFormat();
}
/**
@@ -206,5 +183,8 @@ public AssetStorageEncryptionFormat storageEncryptionFormat() {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AssetProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AssetProperties.java
new file mode 100644
index 000000000000..d64a31ae0a04
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/AssetProperties.java
@@ -0,0 +1,191 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.mediaservices.models.AssetStorageEncryptionFormat;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+import java.util.UUID;
+
+/** The Asset properties. */
+@Fluent
+public final class AssetProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(AssetProperties.class);
+
+ /*
+ * The Asset ID.
+ */
+ @JsonProperty(value = "assetId", access = JsonProperty.Access.WRITE_ONLY)
+ private UUID assetId;
+
+ /*
+ * The creation date of the Asset.
+ */
+ @JsonProperty(value = "created", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime created;
+
+ /*
+ * The last modified date of the Asset.
+ */
+ @JsonProperty(value = "lastModified", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime lastModified;
+
+ /*
+ * The alternate ID of the Asset.
+ */
+ @JsonProperty(value = "alternateId")
+ private String alternateId;
+
+ /*
+ * The Asset description.
+ */
+ @JsonProperty(value = "description")
+ private String description;
+
+ /*
+ * The name of the asset blob container.
+ */
+ @JsonProperty(value = "container")
+ private String container;
+
+ /*
+ * The name of the storage account.
+ */
+ @JsonProperty(value = "storageAccountName")
+ private String storageAccountName;
+
+ /*
+ * The Asset encryption format. One of None or MediaStorageEncryption.
+ */
+ @JsonProperty(value = "storageEncryptionFormat", access = JsonProperty.Access.WRITE_ONLY)
+ private AssetStorageEncryptionFormat storageEncryptionFormat;
+
+ /**
+ * Get the assetId property: The Asset ID.
+ *
+ * @return the assetId value.
+ */
+ public UUID assetId() {
+ return this.assetId;
+ }
+
+ /**
+ * Get the created property: The creation date of the Asset.
+ *
+ * @return the created value.
+ */
+ public OffsetDateTime created() {
+ return this.created;
+ }
+
+ /**
+ * Get the lastModified property: The last modified date of the Asset.
+ *
+ * @return the lastModified value.
+ */
+ public OffsetDateTime lastModified() {
+ return this.lastModified;
+ }
+
+ /**
+ * Get the alternateId property: The alternate ID of the Asset.
+ *
+ * @return the alternateId value.
+ */
+ public String alternateId() {
+ return this.alternateId;
+ }
+
+ /**
+ * Set the alternateId property: The alternate ID of the Asset.
+ *
+ * @param alternateId the alternateId value to set.
+ * @return the AssetProperties object itself.
+ */
+ public AssetProperties withAlternateId(String alternateId) {
+ this.alternateId = alternateId;
+ return this;
+ }
+
+ /**
+ * Get the description property: The Asset description.
+ *
+ * @return the description value.
+ */
+ public String description() {
+ return this.description;
+ }
+
+ /**
+ * Set the description property: The Asset description.
+ *
+ * @param description the description value to set.
+ * @return the AssetProperties object itself.
+ */
+ public AssetProperties withDescription(String description) {
+ this.description = description;
+ return this;
+ }
+
+ /**
+ * Get the container property: The name of the asset blob container.
+ *
+ * @return the container value.
+ */
+ public String container() {
+ return this.container;
+ }
+
+ /**
+ * Set the container property: The name of the asset blob container.
+ *
+ * @param container the container value to set.
+ * @return the AssetProperties object itself.
+ */
+ public AssetProperties withContainer(String container) {
+ this.container = container;
+ return this;
+ }
+
+ /**
+ * Get the storageAccountName property: The name of the storage account.
+ *
+ * @return the storageAccountName value.
+ */
+ public String storageAccountName() {
+ return this.storageAccountName;
+ }
+
+ /**
+ * Set the storageAccountName property: The name of the storage account.
+ *
+ * @param storageAccountName the storageAccountName value to set.
+ * @return the AssetProperties object itself.
+ */
+ public AssetProperties withStorageAccountName(String storageAccountName) {
+ this.storageAccountName = storageAccountName;
+ return this;
+ }
+
+ /**
+ * Get the storageEncryptionFormat property: The Asset encryption format. One of None or MediaStorageEncryption.
+ *
+ * @return the storageEncryptionFormat value.
+ */
+ public AssetStorageEncryptionFormat storageEncryptionFormat() {
+ return this.storageEncryptionFormat;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/ContentKeyPolicyInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/ContentKeyPolicyInner.java
index 84ce6a6cc66f..341a27cd3c3d 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/ContentKeyPolicyInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/ContentKeyPolicyInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -17,46 +16,30 @@
import java.util.UUID;
/** A Content Key Policy resource. */
-@JsonFlatten
@Fluent
-public class ContentKeyPolicyInner extends ProxyResource {
+public final class ContentKeyPolicyInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(ContentKeyPolicyInner.class);
/*
- * The system metadata relating to this resource.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /*
- * The legacy Policy ID.
+ * The properties of the Content Key Policy.
*/
- @JsonProperty(value = "properties.policyId", access = JsonProperty.Access.WRITE_ONLY)
- private UUID policyId;
+ @JsonProperty(value = "properties")
+ private ContentKeyPolicyPropertiesInner innerProperties;
/*
- * The creation date of the Policy
- */
- @JsonProperty(value = "properties.created", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime created;
-
- /*
- * The last modified date of the Policy
- */
- @JsonProperty(value = "properties.lastModified", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime lastModified;
-
- /*
- * A description for the Policy.
+ * The system metadata relating to this resource.
*/
- @JsonProperty(value = "properties.description")
- private String description;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData systemData;
- /*
- * The Key Policy options.
+ /**
+ * Get the innerProperties property: The properties of the Content Key Policy.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.options")
- private List options;
+ private ContentKeyPolicyPropertiesInner innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the systemData property: The system metadata relating to this resource.
@@ -73,7 +56,7 @@ public SystemData systemData() {
* @return the policyId value.
*/
public UUID policyId() {
- return this.policyId;
+ return this.innerProperties() == null ? null : this.innerProperties().policyId();
}
/**
@@ -82,7 +65,7 @@ public UUID policyId() {
* @return the created value.
*/
public OffsetDateTime created() {
- return this.created;
+ return this.innerProperties() == null ? null : this.innerProperties().created();
}
/**
@@ -91,7 +74,7 @@ public OffsetDateTime created() {
* @return the lastModified value.
*/
public OffsetDateTime lastModified() {
- return this.lastModified;
+ return this.innerProperties() == null ? null : this.innerProperties().lastModified();
}
/**
@@ -100,7 +83,7 @@ public OffsetDateTime lastModified() {
* @return the description value.
*/
public String description() {
- return this.description;
+ return this.innerProperties() == null ? null : this.innerProperties().description();
}
/**
@@ -110,7 +93,10 @@ public String description() {
* @return the ContentKeyPolicyInner object itself.
*/
public ContentKeyPolicyInner withDescription(String description) {
- this.description = description;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ContentKeyPolicyPropertiesInner();
+ }
+ this.innerProperties().withDescription(description);
return this;
}
@@ -120,7 +106,7 @@ public ContentKeyPolicyInner withDescription(String description) {
* @return the options value.
*/
public List options() {
- return this.options;
+ return this.innerProperties() == null ? null : this.innerProperties().options();
}
/**
@@ -130,7 +116,10 @@ public List options() {
* @return the ContentKeyPolicyInner object itself.
*/
public ContentKeyPolicyInner withOptions(List options) {
- this.options = options;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ContentKeyPolicyPropertiesInner();
+ }
+ this.innerProperties().withOptions(options);
return this;
}
@@ -140,8 +129,8 @@ public ContentKeyPolicyInner withOptions(List options) {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (options() != null) {
- options().forEach(e -> e.validate());
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/JobInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/JobInner.java
index b048a694c7e4..74a73240b9fe 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/JobInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/JobInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -23,81 +22,30 @@
* A Job resource type. The progress and state can be obtained by polling a Job or subscribing to events using
* EventGrid.
*/
-@JsonFlatten
@Fluent
-public class JobInner extends ProxyResource {
+public final class JobInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(JobInner.class);
/*
- * The system metadata relating to this resource.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /*
- * The UTC date and time when the customer has created the Job, in
- * 'YYYY-MM-DDThh:mm:ssZ' format.
- */
- @JsonProperty(value = "properties.created", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime created;
-
- /*
- * The current state of the job.
- */
- @JsonProperty(value = "properties.state", access = JsonProperty.Access.WRITE_ONLY)
- private JobState state;
-
- /*
- * Optional customer supplied description of the Job.
- */
- @JsonProperty(value = "properties.description")
- private String description;
-
- /*
- * The inputs for the Job.
- */
- @JsonProperty(value = "properties.input")
- private JobInput input;
-
- /*
- * The UTC date and time when the customer has last updated the Job, in
- * 'YYYY-MM-DDThh:mm:ssZ' format.
- */
- @JsonProperty(value = "properties.lastModified", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime lastModified;
-
- /*
- * The outputs for the Job.
- */
- @JsonProperty(value = "properties.outputs")
- private List outputs;
-
- /*
- * Priority with which the job should be processed. Higher priority jobs
- * are processed before lower priority jobs. If not set, the default is
- * normal.
+ * The resource properties.
*/
- @JsonProperty(value = "properties.priority")
- private Priority priority;
+ @JsonProperty(value = "properties")
+ private JobProperties innerProperties;
/*
- * Customer provided key, value pairs that will be returned in Job and
- * JobOutput state events.
- */
- @JsonProperty(value = "properties.correlationData")
- private Map correlationData;
-
- /*
- * The UTC date and time at which this Job began processing.
+ * The system metadata relating to this resource.
*/
- @JsonProperty(value = "properties.startTime", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime startTime;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData systemData;
- /*
- * The UTC date and time at which this Job finished processing.
+ /**
+ * Get the innerProperties property: The resource properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.endTime", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime endTime;
+ private JobProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the systemData property: The system metadata relating to this resource.
@@ -115,7 +63,7 @@ public SystemData systemData() {
* @return the created value.
*/
public OffsetDateTime created() {
- return this.created;
+ return this.innerProperties() == null ? null : this.innerProperties().created();
}
/**
@@ -124,7 +72,7 @@ public OffsetDateTime created() {
* @return the state value.
*/
public JobState state() {
- return this.state;
+ return this.innerProperties() == null ? null : this.innerProperties().state();
}
/**
@@ -133,7 +81,7 @@ public JobState state() {
* @return the description value.
*/
public String description() {
- return this.description;
+ return this.innerProperties() == null ? null : this.innerProperties().description();
}
/**
@@ -143,7 +91,10 @@ public String description() {
* @return the JobInner object itself.
*/
public JobInner withDescription(String description) {
- this.description = description;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new JobProperties();
+ }
+ this.innerProperties().withDescription(description);
return this;
}
@@ -153,7 +104,7 @@ public JobInner withDescription(String description) {
* @return the input value.
*/
public JobInput input() {
- return this.input;
+ return this.innerProperties() == null ? null : this.innerProperties().input();
}
/**
@@ -163,7 +114,10 @@ public JobInput input() {
* @return the JobInner object itself.
*/
public JobInner withInput(JobInput input) {
- this.input = input;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new JobProperties();
+ }
+ this.innerProperties().withInput(input);
return this;
}
@@ -174,7 +128,7 @@ public JobInner withInput(JobInput input) {
* @return the lastModified value.
*/
public OffsetDateTime lastModified() {
- return this.lastModified;
+ return this.innerProperties() == null ? null : this.innerProperties().lastModified();
}
/**
@@ -183,7 +137,7 @@ public OffsetDateTime lastModified() {
* @return the outputs value.
*/
public List outputs() {
- return this.outputs;
+ return this.innerProperties() == null ? null : this.innerProperties().outputs();
}
/**
@@ -193,7 +147,10 @@ public List outputs() {
* @return the JobInner object itself.
*/
public JobInner withOutputs(List outputs) {
- this.outputs = outputs;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new JobProperties();
+ }
+ this.innerProperties().withOutputs(outputs);
return this;
}
@@ -204,7 +161,7 @@ public JobInner withOutputs(List outputs) {
* @return the priority value.
*/
public Priority priority() {
- return this.priority;
+ return this.innerProperties() == null ? null : this.innerProperties().priority();
}
/**
@@ -215,7 +172,10 @@ public Priority priority() {
* @return the JobInner object itself.
*/
public JobInner withPriority(Priority priority) {
- this.priority = priority;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new JobProperties();
+ }
+ this.innerProperties().withPriority(priority);
return this;
}
@@ -226,7 +186,7 @@ public JobInner withPriority(Priority priority) {
* @return the correlationData value.
*/
public Map correlationData() {
- return this.correlationData;
+ return this.innerProperties() == null ? null : this.innerProperties().correlationData();
}
/**
@@ -237,7 +197,10 @@ public Map correlationData() {
* @return the JobInner object itself.
*/
public JobInner withCorrelationData(Map correlationData) {
- this.correlationData = correlationData;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new JobProperties();
+ }
+ this.innerProperties().withCorrelationData(correlationData);
return this;
}
@@ -247,7 +210,7 @@ public JobInner withCorrelationData(Map correlationData) {
* @return the startTime value.
*/
public OffsetDateTime startTime() {
- return this.startTime;
+ return this.innerProperties() == null ? null : this.innerProperties().startTime();
}
/**
@@ -256,7 +219,7 @@ public OffsetDateTime startTime() {
* @return the endTime value.
*/
public OffsetDateTime endTime() {
- return this.endTime;
+ return this.innerProperties() == null ? null : this.innerProperties().endTime();
}
/**
@@ -265,11 +228,8 @@ public OffsetDateTime endTime() {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (input() != null) {
- input().validate();
- }
- if (outputs() != null) {
- outputs().forEach(e -> e.validate());
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/JobProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/JobProperties.java
new file mode 100644
index 000000000000..9f7274a45df8
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/JobProperties.java
@@ -0,0 +1,263 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.mediaservices.models.JobInput;
+import com.azure.resourcemanager.mediaservices.models.JobOutput;
+import com.azure.resourcemanager.mediaservices.models.JobState;
+import com.azure.resourcemanager.mediaservices.models.Priority;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonInclude;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+import java.util.List;
+import java.util.Map;
+
+/** Properties of the Job. */
+@Fluent
+public final class JobProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(JobProperties.class);
+
+ /*
+ * The UTC date and time when the customer has created the Job, in
+ * 'YYYY-MM-DDThh:mm:ssZ' format.
+ */
+ @JsonProperty(value = "created", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime created;
+
+ /*
+ * The current state of the job.
+ */
+ @JsonProperty(value = "state", access = JsonProperty.Access.WRITE_ONLY)
+ private JobState state;
+
+ /*
+ * Optional customer supplied description of the Job.
+ */
+ @JsonProperty(value = "description")
+ private String description;
+
+ /*
+ * The inputs for the Job.
+ */
+ @JsonProperty(value = "input", required = true)
+ private JobInput input;
+
+ /*
+ * The UTC date and time when the customer has last updated the Job, in
+ * 'YYYY-MM-DDThh:mm:ssZ' format.
+ */
+ @JsonProperty(value = "lastModified", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime lastModified;
+
+ /*
+ * The outputs for the Job.
+ */
+ @JsonProperty(value = "outputs", required = true)
+ private List outputs;
+
+ /*
+ * Priority with which the job should be processed. Higher priority jobs
+ * are processed before lower priority jobs. If not set, the default is
+ * normal.
+ */
+ @JsonProperty(value = "priority")
+ private Priority priority;
+
+ /*
+ * Customer provided key, value pairs that will be returned in Job and
+ * JobOutput state events.
+ */
+ @JsonProperty(value = "correlationData")
+ @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS)
+ private Map correlationData;
+
+ /*
+ * The UTC date and time at which this Job began processing.
+ */
+ @JsonProperty(value = "startTime", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime startTime;
+
+ /*
+ * The UTC date and time at which this Job finished processing.
+ */
+ @JsonProperty(value = "endTime", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime endTime;
+
+ /**
+ * Get the created property: The UTC date and time when the customer has created the Job, in 'YYYY-MM-DDThh:mm:ssZ'
+ * format.
+ *
+ * @return the created value.
+ */
+ public OffsetDateTime created() {
+ return this.created;
+ }
+
+ /**
+ * Get the state property: The current state of the job.
+ *
+ * @return the state value.
+ */
+ public JobState state() {
+ return this.state;
+ }
+
+ /**
+ * Get the description property: Optional customer supplied description of the Job.
+ *
+ * @return the description value.
+ */
+ public String description() {
+ return this.description;
+ }
+
+ /**
+ * Set the description property: Optional customer supplied description of the Job.
+ *
+ * @param description the description value to set.
+ * @return the JobProperties object itself.
+ */
+ public JobProperties withDescription(String description) {
+ this.description = description;
+ return this;
+ }
+
+ /**
+ * Get the input property: The inputs for the Job.
+ *
+ * @return the input value.
+ */
+ public JobInput input() {
+ return this.input;
+ }
+
+ /**
+ * Set the input property: The inputs for the Job.
+ *
+ * @param input the input value to set.
+ * @return the JobProperties object itself.
+ */
+ public JobProperties withInput(JobInput input) {
+ this.input = input;
+ return this;
+ }
+
+ /**
+ * Get the lastModified property: The UTC date and time when the customer has last updated the Job, in
+ * 'YYYY-MM-DDThh:mm:ssZ' format.
+ *
+ * @return the lastModified value.
+ */
+ public OffsetDateTime lastModified() {
+ return this.lastModified;
+ }
+
+ /**
+ * Get the outputs property: The outputs for the Job.
+ *
+ * @return the outputs value.
+ */
+ public List outputs() {
+ return this.outputs;
+ }
+
+ /**
+ * Set the outputs property: The outputs for the Job.
+ *
+ * @param outputs the outputs value to set.
+ * @return the JobProperties object itself.
+ */
+ public JobProperties withOutputs(List outputs) {
+ this.outputs = outputs;
+ return this;
+ }
+
+ /**
+ * Get the priority property: Priority with which the job should be processed. Higher priority jobs are processed
+ * before lower priority jobs. If not set, the default is normal.
+ *
+ * @return the priority value.
+ */
+ public Priority priority() {
+ return this.priority;
+ }
+
+ /**
+ * Set the priority property: Priority with which the job should be processed. Higher priority jobs are processed
+ * before lower priority jobs. If not set, the default is normal.
+ *
+ * @param priority the priority value to set.
+ * @return the JobProperties object itself.
+ */
+ public JobProperties withPriority(Priority priority) {
+ this.priority = priority;
+ return this;
+ }
+
+ /**
+ * Get the correlationData property: Customer provided key, value pairs that will be returned in Job and JobOutput
+ * state events.
+ *
+ * @return the correlationData value.
+ */
+ public Map correlationData() {
+ return this.correlationData;
+ }
+
+ /**
+ * Set the correlationData property: Customer provided key, value pairs that will be returned in Job and JobOutput
+ * state events.
+ *
+ * @param correlationData the correlationData value to set.
+ * @return the JobProperties object itself.
+ */
+ public JobProperties withCorrelationData(Map correlationData) {
+ this.correlationData = correlationData;
+ return this;
+ }
+
+ /**
+ * Get the startTime property: The UTC date and time at which this Job began processing.
+ *
+ * @return the startTime value.
+ */
+ public OffsetDateTime startTime() {
+ return this.startTime;
+ }
+
+ /**
+ * Get the endTime property: The UTC date and time at which this Job finished processing.
+ *
+ * @return the endTime value.
+ */
+ public OffsetDateTime endTime() {
+ return this.endTime;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (input() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException("Missing required property input in model JobProperties"));
+ } else {
+ input().validate();
+ }
+ if (outputs() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException("Missing required property outputs in model JobProperties"));
+ } else {
+ outputs().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveEventInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveEventInner.java
index e3bc48222309..b748d8f416fb 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveEventInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveEventInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.Resource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -23,109 +22,30 @@
import java.util.Map;
/** The live event. */
-@JsonFlatten
@Fluent
-public class LiveEventInner extends Resource {
+public final class LiveEventInner extends Resource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(LiveEventInner.class);
/*
- * The system metadata relating to this resource.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /*
- * A description for the live event.
- */
- @JsonProperty(value = "properties.description")
- private String description;
-
- /*
- * Live event input settings. It defines how the live event receives input
- * from a contribution encoder.
- */
- @JsonProperty(value = "properties.input")
- private LiveEventInput input;
-
- /*
- * Live event preview settings. Preview allows live event producers to
- * preview the live streaming content without creating any live output.
- */
- @JsonProperty(value = "properties.preview")
- private LiveEventPreview preview;
-
- /*
- * Encoding settings for the live event. It configures whether a live
- * encoder is used for the live event and settings for the live encoder if
- * it is used.
+ * The live event properties.
*/
- @JsonProperty(value = "properties.encoding")
- private LiveEventEncoding encoding;
+ @JsonProperty(value = "properties")
+ private LiveEventProperties innerProperties;
/*
- * Live transcription settings for the live event. See
- * https://go.microsoft.com/fwlink/?linkid=2133742 for more information
- * about the live transcription feature.
- */
- @JsonProperty(value = "properties.transcriptions")
- private List transcriptions;
-
- /*
- * The provisioning state of the live event.
- */
- @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY)
- private String provisioningState;
-
- /*
- * The resource state of the live event. See
- * https://go.microsoft.com/fwlink/?linkid=2139012 for more information.
- */
- @JsonProperty(value = "properties.resourceState", access = JsonProperty.Access.WRITE_ONLY)
- private LiveEventResourceState resourceState;
-
- /*
- * Live event cross site access policies.
- */
- @JsonProperty(value = "properties.crossSiteAccessPolicies")
- private CrossSiteAccessPolicies crossSiteAccessPolicies;
-
- /*
- * Specifies whether a static hostname would be assigned to the live event
- * preview and ingest endpoints. This value can only be updated if the live
- * event is in Standby state
- */
- @JsonProperty(value = "properties.useStaticHostname")
- private Boolean useStaticHostname;
-
- /*
- * When useStaticHostname is set to true, the hostnamePrefix specifies the
- * first part of the hostname assigned to the live event preview and ingest
- * endpoints. The final hostname would be a combination of this prefix, the
- * media service account name and a short code for the Azure Media Services
- * data center.
- */
- @JsonProperty(value = "properties.hostnamePrefix")
- private String hostnamePrefix;
-
- /*
- * The options to use for the LiveEvent. This value is specified at
- * creation time and cannot be updated. The valid values for the array
- * entry values are 'Default' and 'LowLatency'.
- */
- @JsonProperty(value = "properties.streamOptions")
- private List streamOptions;
-
- /*
- * The creation time for the live event
+ * The system metadata relating to this resource.
*/
- @JsonProperty(value = "properties.created", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime created;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData systemData;
- /*
- * The last modified time of the live event.
+ /**
+ * Get the innerProperties property: The live event properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.lastModified", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime lastModified;
+ private LiveEventProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the systemData property: The system metadata relating to this resource.
@@ -136,13 +56,27 @@ public SystemData systemData() {
return this.systemData;
}
+ /** {@inheritDoc} */
+ @Override
+ public LiveEventInner withLocation(String location) {
+ super.withLocation(location);
+ return this;
+ }
+
+ /** {@inheritDoc} */
+ @Override
+ public LiveEventInner withTags(Map tags) {
+ super.withTags(tags);
+ return this;
+ }
+
/**
* Get the description property: A description for the live event.
*
* @return the description value.
*/
public String description() {
- return this.description;
+ return this.innerProperties() == null ? null : this.innerProperties().description();
}
/**
@@ -152,7 +86,10 @@ public String description() {
* @return the LiveEventInner object itself.
*/
public LiveEventInner withDescription(String description) {
- this.description = description;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveEventProperties();
+ }
+ this.innerProperties().withDescription(description);
return this;
}
@@ -163,7 +100,7 @@ public LiveEventInner withDescription(String description) {
* @return the input value.
*/
public LiveEventInput input() {
- return this.input;
+ return this.innerProperties() == null ? null : this.innerProperties().input();
}
/**
@@ -174,7 +111,10 @@ public LiveEventInput input() {
* @return the LiveEventInner object itself.
*/
public LiveEventInner withInput(LiveEventInput input) {
- this.input = input;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveEventProperties();
+ }
+ this.innerProperties().withInput(input);
return this;
}
@@ -185,7 +125,7 @@ public LiveEventInner withInput(LiveEventInput input) {
* @return the preview value.
*/
public LiveEventPreview preview() {
- return this.preview;
+ return this.innerProperties() == null ? null : this.innerProperties().preview();
}
/**
@@ -196,7 +136,10 @@ public LiveEventPreview preview() {
* @return the LiveEventInner object itself.
*/
public LiveEventInner withPreview(LiveEventPreview preview) {
- this.preview = preview;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveEventProperties();
+ }
+ this.innerProperties().withPreview(preview);
return this;
}
@@ -207,7 +150,7 @@ public LiveEventInner withPreview(LiveEventPreview preview) {
* @return the encoding value.
*/
public LiveEventEncoding encoding() {
- return this.encoding;
+ return this.innerProperties() == null ? null : this.innerProperties().encoding();
}
/**
@@ -218,7 +161,10 @@ public LiveEventEncoding encoding() {
* @return the LiveEventInner object itself.
*/
public LiveEventInner withEncoding(LiveEventEncoding encoding) {
- this.encoding = encoding;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveEventProperties();
+ }
+ this.innerProperties().withEncoding(encoding);
return this;
}
@@ -229,7 +175,7 @@ public LiveEventInner withEncoding(LiveEventEncoding encoding) {
* @return the transcriptions value.
*/
public List transcriptions() {
- return this.transcriptions;
+ return this.innerProperties() == null ? null : this.innerProperties().transcriptions();
}
/**
@@ -240,7 +186,10 @@ public List transcriptions() {
* @return the LiveEventInner object itself.
*/
public LiveEventInner withTranscriptions(List transcriptions) {
- this.transcriptions = transcriptions;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveEventProperties();
+ }
+ this.innerProperties().withTranscriptions(transcriptions);
return this;
}
@@ -250,7 +199,7 @@ public LiveEventInner withTranscriptions(List transcript
* @return the provisioningState value.
*/
public String provisioningState() {
- return this.provisioningState;
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
}
/**
@@ -260,7 +209,7 @@ public String provisioningState() {
* @return the resourceState value.
*/
public LiveEventResourceState resourceState() {
- return this.resourceState;
+ return this.innerProperties() == null ? null : this.innerProperties().resourceState();
}
/**
@@ -269,7 +218,7 @@ public LiveEventResourceState resourceState() {
* @return the crossSiteAccessPolicies value.
*/
public CrossSiteAccessPolicies crossSiteAccessPolicies() {
- return this.crossSiteAccessPolicies;
+ return this.innerProperties() == null ? null : this.innerProperties().crossSiteAccessPolicies();
}
/**
@@ -279,7 +228,10 @@ public CrossSiteAccessPolicies crossSiteAccessPolicies() {
* @return the LiveEventInner object itself.
*/
public LiveEventInner withCrossSiteAccessPolicies(CrossSiteAccessPolicies crossSiteAccessPolicies) {
- this.crossSiteAccessPolicies = crossSiteAccessPolicies;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveEventProperties();
+ }
+ this.innerProperties().withCrossSiteAccessPolicies(crossSiteAccessPolicies);
return this;
}
@@ -290,7 +242,7 @@ public LiveEventInner withCrossSiteAccessPolicies(CrossSiteAccessPolicies crossS
* @return the useStaticHostname value.
*/
public Boolean useStaticHostname() {
- return this.useStaticHostname;
+ return this.innerProperties() == null ? null : this.innerProperties().useStaticHostname();
}
/**
@@ -301,7 +253,10 @@ public Boolean useStaticHostname() {
* @return the LiveEventInner object itself.
*/
public LiveEventInner withUseStaticHostname(Boolean useStaticHostname) {
- this.useStaticHostname = useStaticHostname;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveEventProperties();
+ }
+ this.innerProperties().withUseStaticHostname(useStaticHostname);
return this;
}
@@ -314,7 +269,7 @@ public LiveEventInner withUseStaticHostname(Boolean useStaticHostname) {
* @return the hostnamePrefix value.
*/
public String hostnamePrefix() {
- return this.hostnamePrefix;
+ return this.innerProperties() == null ? null : this.innerProperties().hostnamePrefix();
}
/**
@@ -327,7 +282,10 @@ public String hostnamePrefix() {
* @return the LiveEventInner object itself.
*/
public LiveEventInner withHostnamePrefix(String hostnamePrefix) {
- this.hostnamePrefix = hostnamePrefix;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveEventProperties();
+ }
+ this.innerProperties().withHostnamePrefix(hostnamePrefix);
return this;
}
@@ -338,7 +296,7 @@ public LiveEventInner withHostnamePrefix(String hostnamePrefix) {
* @return the streamOptions value.
*/
public List streamOptions() {
- return this.streamOptions;
+ return this.innerProperties() == null ? null : this.innerProperties().streamOptions();
}
/**
@@ -349,7 +307,10 @@ public List streamOptions() {
* @return the LiveEventInner object itself.
*/
public LiveEventInner withStreamOptions(List streamOptions) {
- this.streamOptions = streamOptions;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveEventProperties();
+ }
+ this.innerProperties().withStreamOptions(streamOptions);
return this;
}
@@ -359,7 +320,7 @@ public LiveEventInner withStreamOptions(List streamOptions) {
* @return the created value.
*/
public OffsetDateTime created() {
- return this.created;
+ return this.innerProperties() == null ? null : this.innerProperties().created();
}
/**
@@ -368,21 +329,7 @@ public OffsetDateTime created() {
* @return the lastModified value.
*/
public OffsetDateTime lastModified() {
- return this.lastModified;
- }
-
- /** {@inheritDoc} */
- @Override
- public LiveEventInner withLocation(String location) {
- super.withLocation(location);
- return this;
- }
-
- /** {@inheritDoc} */
- @Override
- public LiveEventInner withTags(Map tags) {
- super.withTags(tags);
- return this;
+ return this.innerProperties() == null ? null : this.innerProperties().lastModified();
}
/**
@@ -391,20 +338,8 @@ public LiveEventInner withTags(Map tags) {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (input() != null) {
- input().validate();
- }
- if (preview() != null) {
- preview().validate();
- }
- if (encoding() != null) {
- encoding().validate();
- }
- if (transcriptions() != null) {
- transcriptions().forEach(e -> e.validate());
- }
- if (crossSiteAccessPolicies() != null) {
- crossSiteAccessPolicies().validate();
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveEventProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveEventProperties.java
new file mode 100644
index 000000000000..0c6856d3d88a
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveEventProperties.java
@@ -0,0 +1,380 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.mediaservices.models.CrossSiteAccessPolicies;
+import com.azure.resourcemanager.mediaservices.models.LiveEventEncoding;
+import com.azure.resourcemanager.mediaservices.models.LiveEventInput;
+import com.azure.resourcemanager.mediaservices.models.LiveEventPreview;
+import com.azure.resourcemanager.mediaservices.models.LiveEventResourceState;
+import com.azure.resourcemanager.mediaservices.models.LiveEventTranscription;
+import com.azure.resourcemanager.mediaservices.models.StreamOptionsFlag;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+import java.util.List;
+
+/** The live event properties. */
+@Fluent
+public final class LiveEventProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(LiveEventProperties.class);
+
+ /*
+ * A description for the live event.
+ */
+ @JsonProperty(value = "description")
+ private String description;
+
+ /*
+ * Live event input settings. It defines how the live event receives input
+ * from a contribution encoder.
+ */
+ @JsonProperty(value = "input", required = true)
+ private LiveEventInput input;
+
+ /*
+ * Live event preview settings. Preview allows live event producers to
+ * preview the live streaming content without creating any live output.
+ */
+ @JsonProperty(value = "preview")
+ private LiveEventPreview preview;
+
+ /*
+ * Encoding settings for the live event. It configures whether a live
+ * encoder is used for the live event and settings for the live encoder if
+ * it is used.
+ */
+ @JsonProperty(value = "encoding")
+ private LiveEventEncoding encoding;
+
+ /*
+ * Live transcription settings for the live event. See
+ * https://go.microsoft.com/fwlink/?linkid=2133742 for more information
+ * about the live transcription feature.
+ */
+ @JsonProperty(value = "transcriptions")
+ private List transcriptions;
+
+ /*
+ * The provisioning state of the live event.
+ */
+ @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY)
+ private String provisioningState;
+
+ /*
+ * The resource state of the live event. See
+ * https://go.microsoft.com/fwlink/?linkid=2139012 for more information.
+ */
+ @JsonProperty(value = "resourceState", access = JsonProperty.Access.WRITE_ONLY)
+ private LiveEventResourceState resourceState;
+
+ /*
+ * Live event cross site access policies.
+ */
+ @JsonProperty(value = "crossSiteAccessPolicies")
+ private CrossSiteAccessPolicies crossSiteAccessPolicies;
+
+ /*
+ * Specifies whether a static hostname would be assigned to the live event
+ * preview and ingest endpoints. This value can only be updated if the live
+ * event is in Standby state
+ */
+ @JsonProperty(value = "useStaticHostname")
+ private Boolean useStaticHostname;
+
+ /*
+ * When useStaticHostname is set to true, the hostnamePrefix specifies the
+ * first part of the hostname assigned to the live event preview and ingest
+ * endpoints. The final hostname would be a combination of this prefix, the
+ * media service account name and a short code for the Azure Media Services
+ * data center.
+ */
+ @JsonProperty(value = "hostnamePrefix")
+ private String hostnamePrefix;
+
+ /*
+ * The options to use for the LiveEvent. This value is specified at
+ * creation time and cannot be updated. The valid values for the array
+ * entry values are 'Default' and 'LowLatency'.
+ */
+ @JsonProperty(value = "streamOptions")
+ private List streamOptions;
+
+ /*
+ * The creation time for the live event
+ */
+ @JsonProperty(value = "created", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime created;
+
+ /*
+ * The last modified time of the live event.
+ */
+ @JsonProperty(value = "lastModified", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime lastModified;
+
+ /**
+ * Get the description property: A description for the live event.
+ *
+ * @return the description value.
+ */
+ public String description() {
+ return this.description;
+ }
+
+ /**
+ * Set the description property: A description for the live event.
+ *
+ * @param description the description value to set.
+ * @return the LiveEventProperties object itself.
+ */
+ public LiveEventProperties withDescription(String description) {
+ this.description = description;
+ return this;
+ }
+
+ /**
+ * Get the input property: Live event input settings. It defines how the live event receives input from a
+ * contribution encoder.
+ *
+ * @return the input value.
+ */
+ public LiveEventInput input() {
+ return this.input;
+ }
+
+ /**
+ * Set the input property: Live event input settings. It defines how the live event receives input from a
+ * contribution encoder.
+ *
+ * @param input the input value to set.
+ * @return the LiveEventProperties object itself.
+ */
+ public LiveEventProperties withInput(LiveEventInput input) {
+ this.input = input;
+ return this;
+ }
+
+ /**
+ * Get the preview property: Live event preview settings. Preview allows live event producers to preview the live
+ * streaming content without creating any live output.
+ *
+ * @return the preview value.
+ */
+ public LiveEventPreview preview() {
+ return this.preview;
+ }
+
+ /**
+ * Set the preview property: Live event preview settings. Preview allows live event producers to preview the live
+ * streaming content without creating any live output.
+ *
+ * @param preview the preview value to set.
+ * @return the LiveEventProperties object itself.
+ */
+ public LiveEventProperties withPreview(LiveEventPreview preview) {
+ this.preview = preview;
+ return this;
+ }
+
+ /**
+ * Get the encoding property: Encoding settings for the live event. It configures whether a live encoder is used for
+ * the live event and settings for the live encoder if it is used.
+ *
+ * @return the encoding value.
+ */
+ public LiveEventEncoding encoding() {
+ return this.encoding;
+ }
+
+ /**
+ * Set the encoding property: Encoding settings for the live event. It configures whether a live encoder is used for
+ * the live event and settings for the live encoder if it is used.
+ *
+ * @param encoding the encoding value to set.
+ * @return the LiveEventProperties object itself.
+ */
+ public LiveEventProperties withEncoding(LiveEventEncoding encoding) {
+ this.encoding = encoding;
+ return this;
+ }
+
+ /**
+ * Get the transcriptions property: Live transcription settings for the live event. See
+ * https://go.microsoft.com/fwlink/?linkid=2133742 for more information about the live transcription feature.
+ *
+ * @return the transcriptions value.
+ */
+ public List transcriptions() {
+ return this.transcriptions;
+ }
+
+ /**
+ * Set the transcriptions property: Live transcription settings for the live event. See
+ * https://go.microsoft.com/fwlink/?linkid=2133742 for more information about the live transcription feature.
+ *
+ * @param transcriptions the transcriptions value to set.
+ * @return the LiveEventProperties object itself.
+ */
+ public LiveEventProperties withTranscriptions(List transcriptions) {
+ this.transcriptions = transcriptions;
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: The provisioning state of the live event.
+ *
+ * @return the provisioningState value.
+ */
+ public String provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Get the resourceState property: The resource state of the live event. See
+ * https://go.microsoft.com/fwlink/?linkid=2139012 for more information.
+ *
+ * @return the resourceState value.
+ */
+ public LiveEventResourceState resourceState() {
+ return this.resourceState;
+ }
+
+ /**
+ * Get the crossSiteAccessPolicies property: Live event cross site access policies.
+ *
+ * @return the crossSiteAccessPolicies value.
+ */
+ public CrossSiteAccessPolicies crossSiteAccessPolicies() {
+ return this.crossSiteAccessPolicies;
+ }
+
+ /**
+ * Set the crossSiteAccessPolicies property: Live event cross site access policies.
+ *
+ * @param crossSiteAccessPolicies the crossSiteAccessPolicies value to set.
+ * @return the LiveEventProperties object itself.
+ */
+ public LiveEventProperties withCrossSiteAccessPolicies(CrossSiteAccessPolicies crossSiteAccessPolicies) {
+ this.crossSiteAccessPolicies = crossSiteAccessPolicies;
+ return this;
+ }
+
+ /**
+ * Get the useStaticHostname property: Specifies whether a static hostname would be assigned to the live event
+ * preview and ingest endpoints. This value can only be updated if the live event is in Standby state.
+ *
+ * @return the useStaticHostname value.
+ */
+ public Boolean useStaticHostname() {
+ return this.useStaticHostname;
+ }
+
+ /**
+ * Set the useStaticHostname property: Specifies whether a static hostname would be assigned to the live event
+ * preview and ingest endpoints. This value can only be updated if the live event is in Standby state.
+ *
+ * @param useStaticHostname the useStaticHostname value to set.
+ * @return the LiveEventProperties object itself.
+ */
+ public LiveEventProperties withUseStaticHostname(Boolean useStaticHostname) {
+ this.useStaticHostname = useStaticHostname;
+ return this;
+ }
+
+ /**
+ * Get the hostnamePrefix property: When useStaticHostname is set to true, the hostnamePrefix specifies the first
+ * part of the hostname assigned to the live event preview and ingest endpoints. The final hostname would be a
+ * combination of this prefix, the media service account name and a short code for the Azure Media Services data
+ * center.
+ *
+ * @return the hostnamePrefix value.
+ */
+ public String hostnamePrefix() {
+ return this.hostnamePrefix;
+ }
+
+ /**
+ * Set the hostnamePrefix property: When useStaticHostname is set to true, the hostnamePrefix specifies the first
+ * part of the hostname assigned to the live event preview and ingest endpoints. The final hostname would be a
+ * combination of this prefix, the media service account name and a short code for the Azure Media Services data
+ * center.
+ *
+ * @param hostnamePrefix the hostnamePrefix value to set.
+ * @return the LiveEventProperties object itself.
+ */
+ public LiveEventProperties withHostnamePrefix(String hostnamePrefix) {
+ this.hostnamePrefix = hostnamePrefix;
+ return this;
+ }
+
+ /**
+ * Get the streamOptions property: The options to use for the LiveEvent. This value is specified at creation time
+ * and cannot be updated. The valid values for the array entry values are 'Default' and 'LowLatency'.
+ *
+ * @return the streamOptions value.
+ */
+ public List streamOptions() {
+ return this.streamOptions;
+ }
+
+ /**
+ * Set the streamOptions property: The options to use for the LiveEvent. This value is specified at creation time
+ * and cannot be updated. The valid values for the array entry values are 'Default' and 'LowLatency'.
+ *
+ * @param streamOptions the streamOptions value to set.
+ * @return the LiveEventProperties object itself.
+ */
+ public LiveEventProperties withStreamOptions(List streamOptions) {
+ this.streamOptions = streamOptions;
+ return this;
+ }
+
+ /**
+ * Get the created property: The creation time for the live event.
+ *
+ * @return the created value.
+ */
+ public OffsetDateTime created() {
+ return this.created;
+ }
+
+ /**
+ * Get the lastModified property: The last modified time of the live event.
+ *
+ * @return the lastModified value.
+ */
+ public OffsetDateTime lastModified() {
+ return this.lastModified;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (input() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException("Missing required property input in model LiveEventProperties"));
+ } else {
+ input().validate();
+ }
+ if (preview() != null) {
+ preview().validate();
+ }
+ if (encoding() != null) {
+ encoding().validate();
+ }
+ if (transcriptions() != null) {
+ transcriptions().forEach(e -> e.validate());
+ }
+ if (crossSiteAccessPolicies() != null) {
+ crossSiteAccessPolicies().validate();
+ }
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveOutputInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveOutputInner.java
index 6d9be1687e7d..c0090e32b3dd 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveOutputInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveOutputInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -17,82 +16,30 @@
import java.time.OffsetDateTime;
/** The Live Output. */
-@JsonFlatten
@Fluent
-public class LiveOutputInner extends ProxyResource {
+public final class LiveOutputInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(LiveOutputInner.class);
/*
- * The system metadata relating to this resource.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /*
- * The description of the live output.
+ * Live output properties.
*/
- @JsonProperty(value = "properties.description")
- private String description;
+ @JsonProperty(value = "properties")
+ private LiveOutputProperties innerProperties;
/*
- * The asset that the live output will write to.
- */
- @JsonProperty(value = "properties.assetName")
- private String assetName;
-
- /*
- * ISO 8601 time between 1 minute to 25 hours to indicate the maximum
- * content length that can be archived in the asset for this live output.
- * This also sets the maximum content length for the rewind window. For
- * example, use PT1H30M to indicate 1 hour and 30 minutes of archive
- * window.
- */
- @JsonProperty(value = "properties.archiveWindowLength")
- private Duration archiveWindowLength;
-
- /*
- * The manifest file name. If not provided, the service will generate one
- * automatically.
- */
- @JsonProperty(value = "properties.manifestName")
- private String manifestName;
-
- /*
- * HTTP Live Streaming (HLS) packing setting for the live output.
- */
- @JsonProperty(value = "properties.hls")
- private Hls hls;
-
- /*
- * The initial timestamp that the live output will start at, any content
- * before this value will not be archived.
- */
- @JsonProperty(value = "properties.outputSnapTime")
- private Long outputSnapTime;
-
- /*
- * The creation time the live output.
- */
- @JsonProperty(value = "properties.created", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime created;
-
- /*
- * The time the live output was last modified.
- */
- @JsonProperty(value = "properties.lastModified", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime lastModified;
-
- /*
- * The provisioning state of the live output.
+ * The system metadata relating to this resource.
*/
- @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY)
- private String provisioningState;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData systemData;
- /*
- * The resource state of the live output.
+ /**
+ * Get the innerProperties property: Live output properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.resourceState", access = JsonProperty.Access.WRITE_ONLY)
- private LiveOutputResourceState resourceState;
+ private LiveOutputProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the systemData property: The system metadata relating to this resource.
@@ -109,7 +56,7 @@ public SystemData systemData() {
* @return the description value.
*/
public String description() {
- return this.description;
+ return this.innerProperties() == null ? null : this.innerProperties().description();
}
/**
@@ -119,7 +66,10 @@ public String description() {
* @return the LiveOutputInner object itself.
*/
public LiveOutputInner withDescription(String description) {
- this.description = description;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveOutputProperties();
+ }
+ this.innerProperties().withDescription(description);
return this;
}
@@ -129,7 +79,7 @@ public LiveOutputInner withDescription(String description) {
* @return the assetName value.
*/
public String assetName() {
- return this.assetName;
+ return this.innerProperties() == null ? null : this.innerProperties().assetName();
}
/**
@@ -139,7 +89,10 @@ public String assetName() {
* @return the LiveOutputInner object itself.
*/
public LiveOutputInner withAssetName(String assetName) {
- this.assetName = assetName;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveOutputProperties();
+ }
+ this.innerProperties().withAssetName(assetName);
return this;
}
@@ -151,7 +104,7 @@ public LiveOutputInner withAssetName(String assetName) {
* @return the archiveWindowLength value.
*/
public Duration archiveWindowLength() {
- return this.archiveWindowLength;
+ return this.innerProperties() == null ? null : this.innerProperties().archiveWindowLength();
}
/**
@@ -163,7 +116,10 @@ public Duration archiveWindowLength() {
* @return the LiveOutputInner object itself.
*/
public LiveOutputInner withArchiveWindowLength(Duration archiveWindowLength) {
- this.archiveWindowLength = archiveWindowLength;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveOutputProperties();
+ }
+ this.innerProperties().withArchiveWindowLength(archiveWindowLength);
return this;
}
@@ -174,7 +130,7 @@ public LiveOutputInner withArchiveWindowLength(Duration archiveWindowLength) {
* @return the manifestName value.
*/
public String manifestName() {
- return this.manifestName;
+ return this.innerProperties() == null ? null : this.innerProperties().manifestName();
}
/**
@@ -185,7 +141,10 @@ public String manifestName() {
* @return the LiveOutputInner object itself.
*/
public LiveOutputInner withManifestName(String manifestName) {
- this.manifestName = manifestName;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveOutputProperties();
+ }
+ this.innerProperties().withManifestName(manifestName);
return this;
}
@@ -195,7 +154,7 @@ public LiveOutputInner withManifestName(String manifestName) {
* @return the hls value.
*/
public Hls hls() {
- return this.hls;
+ return this.innerProperties() == null ? null : this.innerProperties().hls();
}
/**
@@ -205,7 +164,10 @@ public Hls hls() {
* @return the LiveOutputInner object itself.
*/
public LiveOutputInner withHls(Hls hls) {
- this.hls = hls;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveOutputProperties();
+ }
+ this.innerProperties().withHls(hls);
return this;
}
@@ -216,7 +178,7 @@ public LiveOutputInner withHls(Hls hls) {
* @return the outputSnapTime value.
*/
public Long outputSnapTime() {
- return this.outputSnapTime;
+ return this.innerProperties() == null ? null : this.innerProperties().outputSnapTime();
}
/**
@@ -227,7 +189,10 @@ public Long outputSnapTime() {
* @return the LiveOutputInner object itself.
*/
public LiveOutputInner withOutputSnapTime(Long outputSnapTime) {
- this.outputSnapTime = outputSnapTime;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new LiveOutputProperties();
+ }
+ this.innerProperties().withOutputSnapTime(outputSnapTime);
return this;
}
@@ -237,7 +202,7 @@ public LiveOutputInner withOutputSnapTime(Long outputSnapTime) {
* @return the created value.
*/
public OffsetDateTime created() {
- return this.created;
+ return this.innerProperties() == null ? null : this.innerProperties().created();
}
/**
@@ -246,7 +211,7 @@ public OffsetDateTime created() {
* @return the lastModified value.
*/
public OffsetDateTime lastModified() {
- return this.lastModified;
+ return this.innerProperties() == null ? null : this.innerProperties().lastModified();
}
/**
@@ -255,7 +220,7 @@ public OffsetDateTime lastModified() {
* @return the provisioningState value.
*/
public String provisioningState() {
- return this.provisioningState;
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
}
/**
@@ -264,7 +229,7 @@ public String provisioningState() {
* @return the resourceState value.
*/
public LiveOutputResourceState resourceState() {
- return this.resourceState;
+ return this.innerProperties() == null ? null : this.innerProperties().resourceState();
}
/**
@@ -273,8 +238,8 @@ public LiveOutputResourceState resourceState() {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (hls() != null) {
- hls().validate();
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveOutputProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveOutputProperties.java
new file mode 100644
index 000000000000..c2ec09ca357a
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/LiveOutputProperties.java
@@ -0,0 +1,272 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.mediaservices.models.Hls;
+import com.azure.resourcemanager.mediaservices.models.LiveOutputResourceState;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.Duration;
+import java.time.OffsetDateTime;
+
+/** The JSON object that contains the properties required to create a live output. */
+@Fluent
+public final class LiveOutputProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(LiveOutputProperties.class);
+
+ /*
+ * The description of the live output.
+ */
+ @JsonProperty(value = "description")
+ private String description;
+
+ /*
+ * The asset that the live output will write to.
+ */
+ @JsonProperty(value = "assetName", required = true)
+ private String assetName;
+
+ /*
+ * ISO 8601 time between 1 minute to 25 hours to indicate the maximum
+ * content length that can be archived in the asset for this live output.
+ * This also sets the maximum content length for the rewind window. For
+ * example, use PT1H30M to indicate 1 hour and 30 minutes of archive
+ * window.
+ */
+ @JsonProperty(value = "archiveWindowLength", required = true)
+ private Duration archiveWindowLength;
+
+ /*
+ * The manifest file name. If not provided, the service will generate one
+ * automatically.
+ */
+ @JsonProperty(value = "manifestName")
+ private String manifestName;
+
+ /*
+ * HTTP Live Streaming (HLS) packing setting for the live output.
+ */
+ @JsonProperty(value = "hls")
+ private Hls hls;
+
+ /*
+ * The initial timestamp that the live output will start at, any content
+ * before this value will not be archived.
+ */
+ @JsonProperty(value = "outputSnapTime")
+ private Long outputSnapTime;
+
+ /*
+ * The creation time the live output.
+ */
+ @JsonProperty(value = "created", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime created;
+
+ /*
+ * The time the live output was last modified.
+ */
+ @JsonProperty(value = "lastModified", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime lastModified;
+
+ /*
+ * The provisioning state of the live output.
+ */
+ @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY)
+ private String provisioningState;
+
+ /*
+ * The resource state of the live output.
+ */
+ @JsonProperty(value = "resourceState", access = JsonProperty.Access.WRITE_ONLY)
+ private LiveOutputResourceState resourceState;
+
+ /**
+ * Get the description property: The description of the live output.
+ *
+ * @return the description value.
+ */
+ public String description() {
+ return this.description;
+ }
+
+ /**
+ * Set the description property: The description of the live output.
+ *
+ * @param description the description value to set.
+ * @return the LiveOutputProperties object itself.
+ */
+ public LiveOutputProperties withDescription(String description) {
+ this.description = description;
+ return this;
+ }
+
+ /**
+ * Get the assetName property: The asset that the live output will write to.
+ *
+ * @return the assetName value.
+ */
+ public String assetName() {
+ return this.assetName;
+ }
+
+ /**
+ * Set the assetName property: The asset that the live output will write to.
+ *
+ * @param assetName the assetName value to set.
+ * @return the LiveOutputProperties object itself.
+ */
+ public LiveOutputProperties withAssetName(String assetName) {
+ this.assetName = assetName;
+ return this;
+ }
+
+ /**
+ * Get the archiveWindowLength property: ISO 8601 time between 1 minute to 25 hours to indicate the maximum content
+ * length that can be archived in the asset for this live output. This also sets the maximum content length for the
+ * rewind window. For example, use PT1H30M to indicate 1 hour and 30 minutes of archive window.
+ *
+ * @return the archiveWindowLength value.
+ */
+ public Duration archiveWindowLength() {
+ return this.archiveWindowLength;
+ }
+
+ /**
+ * Set the archiveWindowLength property: ISO 8601 time between 1 minute to 25 hours to indicate the maximum content
+ * length that can be archived in the asset for this live output. This also sets the maximum content length for the
+ * rewind window. For example, use PT1H30M to indicate 1 hour and 30 minutes of archive window.
+ *
+ * @param archiveWindowLength the archiveWindowLength value to set.
+ * @return the LiveOutputProperties object itself.
+ */
+ public LiveOutputProperties withArchiveWindowLength(Duration archiveWindowLength) {
+ this.archiveWindowLength = archiveWindowLength;
+ return this;
+ }
+
+ /**
+ * Get the manifestName property: The manifest file name. If not provided, the service will generate one
+ * automatically.
+ *
+ * @return the manifestName value.
+ */
+ public String manifestName() {
+ return this.manifestName;
+ }
+
+ /**
+ * Set the manifestName property: The manifest file name. If not provided, the service will generate one
+ * automatically.
+ *
+ * @param manifestName the manifestName value to set.
+ * @return the LiveOutputProperties object itself.
+ */
+ public LiveOutputProperties withManifestName(String manifestName) {
+ this.manifestName = manifestName;
+ return this;
+ }
+
+ /**
+ * Get the hls property: HTTP Live Streaming (HLS) packing setting for the live output.
+ *
+ * @return the hls value.
+ */
+ public Hls hls() {
+ return this.hls;
+ }
+
+ /**
+ * Set the hls property: HTTP Live Streaming (HLS) packing setting for the live output.
+ *
+ * @param hls the hls value to set.
+ * @return the LiveOutputProperties object itself.
+ */
+ public LiveOutputProperties withHls(Hls hls) {
+ this.hls = hls;
+ return this;
+ }
+
+ /**
+ * Get the outputSnapTime property: The initial timestamp that the live output will start at, any content before
+ * this value will not be archived.
+ *
+ * @return the outputSnapTime value.
+ */
+ public Long outputSnapTime() {
+ return this.outputSnapTime;
+ }
+
+ /**
+ * Set the outputSnapTime property: The initial timestamp that the live output will start at, any content before
+ * this value will not be archived.
+ *
+ * @param outputSnapTime the outputSnapTime value to set.
+ * @return the LiveOutputProperties object itself.
+ */
+ public LiveOutputProperties withOutputSnapTime(Long outputSnapTime) {
+ this.outputSnapTime = outputSnapTime;
+ return this;
+ }
+
+ /**
+ * Get the created property: The creation time the live output.
+ *
+ * @return the created value.
+ */
+ public OffsetDateTime created() {
+ return this.created;
+ }
+
+ /**
+ * Get the lastModified property: The time the live output was last modified.
+ *
+ * @return the lastModified value.
+ */
+ public OffsetDateTime lastModified() {
+ return this.lastModified;
+ }
+
+ /**
+ * Get the provisioningState property: The provisioning state of the live output.
+ *
+ * @return the provisioningState value.
+ */
+ public String provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Get the resourceState property: The resource state of the live output.
+ *
+ * @return the resourceState value.
+ */
+ public LiveOutputResourceState resourceState() {
+ return this.resourceState;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (assetName() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException("Missing required property assetName in model LiveOutputProperties"));
+ }
+ if (archiveWindowLength() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ "Missing required property archiveWindowLength in model LiveOutputProperties"));
+ }
+ if (hls() != null) {
+ hls().validate();
+ }
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/MediaFilterProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/MediaFilterProperties.java
new file mode 100644
index 000000000000..7533aad64c20
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/MediaFilterProperties.java
@@ -0,0 +1,115 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.mediaservices.models.FilterTrackSelection;
+import com.azure.resourcemanager.mediaservices.models.FirstQuality;
+import com.azure.resourcemanager.mediaservices.models.PresentationTimeRange;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** The Media Filter properties. */
+@Fluent
+public final class MediaFilterProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(MediaFilterProperties.class);
+
+ /*
+ * The presentation time range.
+ */
+ @JsonProperty(value = "presentationTimeRange")
+ private PresentationTimeRange presentationTimeRange;
+
+ /*
+ * The first quality.
+ */
+ @JsonProperty(value = "firstQuality")
+ private FirstQuality firstQuality;
+
+ /*
+ * The tracks selection conditions.
+ */
+ @JsonProperty(value = "tracks")
+ private List tracks;
+
+ /**
+ * Get the presentationTimeRange property: The presentation time range.
+ *
+ * @return the presentationTimeRange value.
+ */
+ public PresentationTimeRange presentationTimeRange() {
+ return this.presentationTimeRange;
+ }
+
+ /**
+ * Set the presentationTimeRange property: The presentation time range.
+ *
+ * @param presentationTimeRange the presentationTimeRange value to set.
+ * @return the MediaFilterProperties object itself.
+ */
+ public MediaFilterProperties withPresentationTimeRange(PresentationTimeRange presentationTimeRange) {
+ this.presentationTimeRange = presentationTimeRange;
+ return this;
+ }
+
+ /**
+ * Get the firstQuality property: The first quality.
+ *
+ * @return the firstQuality value.
+ */
+ public FirstQuality firstQuality() {
+ return this.firstQuality;
+ }
+
+ /**
+ * Set the firstQuality property: The first quality.
+ *
+ * @param firstQuality the firstQuality value to set.
+ * @return the MediaFilterProperties object itself.
+ */
+ public MediaFilterProperties withFirstQuality(FirstQuality firstQuality) {
+ this.firstQuality = firstQuality;
+ return this;
+ }
+
+ /**
+ * Get the tracks property: The tracks selection conditions.
+ *
+ * @return the tracks value.
+ */
+ public List tracks() {
+ return this.tracks;
+ }
+
+ /**
+ * Set the tracks property: The tracks selection conditions.
+ *
+ * @param tracks the tracks value to set.
+ * @return the MediaFilterProperties object itself.
+ */
+ public MediaFilterProperties withTracks(List tracks) {
+ this.tracks = tracks;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (presentationTimeRange() != null) {
+ presentationTimeRange().validate();
+ }
+ if (firstQuality() != null) {
+ firstQuality().validate();
+ }
+ if (tracks() != null) {
+ tracks().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/MediaServiceInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/MediaServiceInner.java
index b5d2c57d143b..636a0294d442 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/MediaServiceInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/MediaServiceInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.Resource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -22,11 +21,16 @@
import java.util.UUID;
/** A Media Services account. */
-@JsonFlatten
@Fluent
-public class MediaServiceInner extends Resource {
+public final class MediaServiceInner extends Resource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(MediaServiceInner.class);
+ /*
+ * The resource properties.
+ */
+ @JsonProperty(value = "properties")
+ private MediaServiceProperties innerProperties;
+
/*
* The Managed Identity for the Media Services account.
*/
@@ -39,42 +43,14 @@ public class MediaServiceInner extends Resource {
@JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
private SystemData systemData;
- /*
- * The Media Services account ID.
- */
- @JsonProperty(value = "properties.mediaServiceId", access = JsonProperty.Access.WRITE_ONLY)
- private UUID mediaServiceId;
-
- /*
- * The storage accounts for this resource.
- */
- @JsonProperty(value = "properties.storageAccounts")
- private List storageAccounts;
-
- /*
- * The storageAuthentication property.
- */
- @JsonProperty(value = "properties.storageAuthentication")
- private StorageAuthentication storageAuthentication;
-
- /*
- * The account encryption properties.
- */
- @JsonProperty(value = "properties.encryption")
- private AccountEncryption encryption;
-
- /*
- * The Key Delivery properties for Media Services account.
- */
- @JsonProperty(value = "properties.keyDelivery")
- private KeyDelivery keyDelivery;
-
- /*
- * Whether or not public network access is allowed for resources under the
- * Media Services account.
+ /**
+ * Get the innerProperties property: The resource properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.publicNetworkAccess")
- private PublicNetworkAccess publicNetworkAccess;
+ private MediaServiceProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the identity property: The Managed Identity for the Media Services account.
@@ -105,13 +81,27 @@ public SystemData systemData() {
return this.systemData;
}
+ /** {@inheritDoc} */
+ @Override
+ public MediaServiceInner withLocation(String location) {
+ super.withLocation(location);
+ return this;
+ }
+
+ /** {@inheritDoc} */
+ @Override
+ public MediaServiceInner withTags(Map tags) {
+ super.withTags(tags);
+ return this;
+ }
+
/**
* Get the mediaServiceId property: The Media Services account ID.
*
* @return the mediaServiceId value.
*/
public UUID mediaServiceId() {
- return this.mediaServiceId;
+ return this.innerProperties() == null ? null : this.innerProperties().mediaServiceId();
}
/**
@@ -120,7 +110,7 @@ public UUID mediaServiceId() {
* @return the storageAccounts value.
*/
public List storageAccounts() {
- return this.storageAccounts;
+ return this.innerProperties() == null ? null : this.innerProperties().storageAccounts();
}
/**
@@ -130,7 +120,10 @@ public List storageAccounts() {
* @return the MediaServiceInner object itself.
*/
public MediaServiceInner withStorageAccounts(List storageAccounts) {
- this.storageAccounts = storageAccounts;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MediaServiceProperties();
+ }
+ this.innerProperties().withStorageAccounts(storageAccounts);
return this;
}
@@ -140,7 +133,7 @@ public MediaServiceInner withStorageAccounts(List storageAccount
* @return the storageAuthentication value.
*/
public StorageAuthentication storageAuthentication() {
- return this.storageAuthentication;
+ return this.innerProperties() == null ? null : this.innerProperties().storageAuthentication();
}
/**
@@ -150,7 +143,10 @@ public StorageAuthentication storageAuthentication() {
* @return the MediaServiceInner object itself.
*/
public MediaServiceInner withStorageAuthentication(StorageAuthentication storageAuthentication) {
- this.storageAuthentication = storageAuthentication;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MediaServiceProperties();
+ }
+ this.innerProperties().withStorageAuthentication(storageAuthentication);
return this;
}
@@ -160,7 +156,7 @@ public MediaServiceInner withStorageAuthentication(StorageAuthentication storage
* @return the encryption value.
*/
public AccountEncryption encryption() {
- return this.encryption;
+ return this.innerProperties() == null ? null : this.innerProperties().encryption();
}
/**
@@ -170,7 +166,10 @@ public AccountEncryption encryption() {
* @return the MediaServiceInner object itself.
*/
public MediaServiceInner withEncryption(AccountEncryption encryption) {
- this.encryption = encryption;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MediaServiceProperties();
+ }
+ this.innerProperties().withEncryption(encryption);
return this;
}
@@ -180,7 +179,7 @@ public MediaServiceInner withEncryption(AccountEncryption encryption) {
* @return the keyDelivery value.
*/
public KeyDelivery keyDelivery() {
- return this.keyDelivery;
+ return this.innerProperties() == null ? null : this.innerProperties().keyDelivery();
}
/**
@@ -190,7 +189,10 @@ public KeyDelivery keyDelivery() {
* @return the MediaServiceInner object itself.
*/
public MediaServiceInner withKeyDelivery(KeyDelivery keyDelivery) {
- this.keyDelivery = keyDelivery;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MediaServiceProperties();
+ }
+ this.innerProperties().withKeyDelivery(keyDelivery);
return this;
}
@@ -201,7 +203,7 @@ public MediaServiceInner withKeyDelivery(KeyDelivery keyDelivery) {
* @return the publicNetworkAccess value.
*/
public PublicNetworkAccess publicNetworkAccess() {
- return this.publicNetworkAccess;
+ return this.innerProperties() == null ? null : this.innerProperties().publicNetworkAccess();
}
/**
@@ -212,21 +214,10 @@ public PublicNetworkAccess publicNetworkAccess() {
* @return the MediaServiceInner object itself.
*/
public MediaServiceInner withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess) {
- this.publicNetworkAccess = publicNetworkAccess;
- return this;
- }
-
- /** {@inheritDoc} */
- @Override
- public MediaServiceInner withLocation(String location) {
- super.withLocation(location);
- return this;
- }
-
- /** {@inheritDoc} */
- @Override
- public MediaServiceInner withTags(Map tags) {
- super.withTags(tags);
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MediaServiceProperties();
+ }
+ this.innerProperties().withPublicNetworkAccess(publicNetworkAccess);
return this;
}
@@ -236,17 +227,11 @@ public MediaServiceInner withTags(Map tags) {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
if (identity() != null) {
identity().validate();
}
- if (storageAccounts() != null) {
- storageAccounts().forEach(e -> e.validate());
- }
- if (encryption() != null) {
- encryption().validate();
- }
- if (keyDelivery() != null) {
- keyDelivery().validate();
- }
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/MediaServiceProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/MediaServiceProperties.java
new file mode 100644
index 000000000000..b80e4738794e
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/MediaServiceProperties.java
@@ -0,0 +1,188 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.mediaservices.models.AccountEncryption;
+import com.azure.resourcemanager.mediaservices.models.KeyDelivery;
+import com.azure.resourcemanager.mediaservices.models.PublicNetworkAccess;
+import com.azure.resourcemanager.mediaservices.models.StorageAccount;
+import com.azure.resourcemanager.mediaservices.models.StorageAuthentication;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+import java.util.UUID;
+
+/** Properties of the Media Services account. */
+@Fluent
+public final class MediaServiceProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(MediaServiceProperties.class);
+
+ /*
+ * The Media Services account ID.
+ */
+ @JsonProperty(value = "mediaServiceId", access = JsonProperty.Access.WRITE_ONLY)
+ private UUID mediaServiceId;
+
+ /*
+ * The storage accounts for this resource.
+ */
+ @JsonProperty(value = "storageAccounts")
+ private List storageAccounts;
+
+ /*
+ * The storageAuthentication property.
+ */
+ @JsonProperty(value = "storageAuthentication")
+ private StorageAuthentication storageAuthentication;
+
+ /*
+ * The account encryption properties.
+ */
+ @JsonProperty(value = "encryption")
+ private AccountEncryption encryption;
+
+ /*
+ * The Key Delivery properties for Media Services account.
+ */
+ @JsonProperty(value = "keyDelivery")
+ private KeyDelivery keyDelivery;
+
+ /*
+ * Whether or not public network access is allowed for resources under the
+ * Media Services account.
+ */
+ @JsonProperty(value = "publicNetworkAccess")
+ private PublicNetworkAccess publicNetworkAccess;
+
+ /**
+ * Get the mediaServiceId property: The Media Services account ID.
+ *
+ * @return the mediaServiceId value.
+ */
+ public UUID mediaServiceId() {
+ return this.mediaServiceId;
+ }
+
+ /**
+ * Get the storageAccounts property: The storage accounts for this resource.
+ *
+ * @return the storageAccounts value.
+ */
+ public List storageAccounts() {
+ return this.storageAccounts;
+ }
+
+ /**
+ * Set the storageAccounts property: The storage accounts for this resource.
+ *
+ * @param storageAccounts the storageAccounts value to set.
+ * @return the MediaServiceProperties object itself.
+ */
+ public MediaServiceProperties withStorageAccounts(List storageAccounts) {
+ this.storageAccounts = storageAccounts;
+ return this;
+ }
+
+ /**
+ * Get the storageAuthentication property: The storageAuthentication property.
+ *
+ * @return the storageAuthentication value.
+ */
+ public StorageAuthentication storageAuthentication() {
+ return this.storageAuthentication;
+ }
+
+ /**
+ * Set the storageAuthentication property: The storageAuthentication property.
+ *
+ * @param storageAuthentication the storageAuthentication value to set.
+ * @return the MediaServiceProperties object itself.
+ */
+ public MediaServiceProperties withStorageAuthentication(StorageAuthentication storageAuthentication) {
+ this.storageAuthentication = storageAuthentication;
+ return this;
+ }
+
+ /**
+ * Get the encryption property: The account encryption properties.
+ *
+ * @return the encryption value.
+ */
+ public AccountEncryption encryption() {
+ return this.encryption;
+ }
+
+ /**
+ * Set the encryption property: The account encryption properties.
+ *
+ * @param encryption the encryption value to set.
+ * @return the MediaServiceProperties object itself.
+ */
+ public MediaServiceProperties withEncryption(AccountEncryption encryption) {
+ this.encryption = encryption;
+ return this;
+ }
+
+ /**
+ * Get the keyDelivery property: The Key Delivery properties for Media Services account.
+ *
+ * @return the keyDelivery value.
+ */
+ public KeyDelivery keyDelivery() {
+ return this.keyDelivery;
+ }
+
+ /**
+ * Set the keyDelivery property: The Key Delivery properties for Media Services account.
+ *
+ * @param keyDelivery the keyDelivery value to set.
+ * @return the MediaServiceProperties object itself.
+ */
+ public MediaServiceProperties withKeyDelivery(KeyDelivery keyDelivery) {
+ this.keyDelivery = keyDelivery;
+ return this;
+ }
+
+ /**
+ * Get the publicNetworkAccess property: Whether or not public network access is allowed for resources under the
+ * Media Services account.
+ *
+ * @return the publicNetworkAccess value.
+ */
+ public PublicNetworkAccess publicNetworkAccess() {
+ return this.publicNetworkAccess;
+ }
+
+ /**
+ * Set the publicNetworkAccess property: Whether or not public network access is allowed for resources under the
+ * Media Services account.
+ *
+ * @param publicNetworkAccess the publicNetworkAccess value to set.
+ * @return the MediaServiceProperties object itself.
+ */
+ public MediaServiceProperties withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess) {
+ this.publicNetworkAccess = publicNetworkAccess;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (storageAccounts() != null) {
+ storageAccounts().forEach(e -> e.validate());
+ }
+ if (encryption() != null) {
+ encryption().validate();
+ }
+ if (keyDelivery() != null) {
+ keyDelivery().validate();
+ }
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateEndpointConnectionInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateEndpointConnectionInner.java
index 68ba355b5d53..33940041a962 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateEndpointConnectionInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateEndpointConnectionInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.mediaservices.models.PrivateEndpoint;
@@ -15,29 +14,24 @@
import com.fasterxml.jackson.annotation.JsonProperty;
/** The Private Endpoint Connection resource. */
-@JsonFlatten
@Fluent
-public class PrivateEndpointConnectionInner extends ProxyResource {
+public final class PrivateEndpointConnectionInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionInner.class);
/*
- * The resource of private end point.
+ * Resource properties.
*/
- @JsonProperty(value = "properties.privateEndpoint")
- private PrivateEndpoint privateEndpoint;
+ @JsonProperty(value = "properties")
+ private PrivateEndpointConnectionProperties innerProperties;
- /*
- * A collection of information about the state of the connection between
- * service consumer and provider.
- */
- @JsonProperty(value = "properties.privateLinkServiceConnectionState")
- private PrivateLinkServiceConnectionState privateLinkServiceConnectionState;
-
- /*
- * The provisioning state of the private endpoint connection resource.
+ /**
+ * Get the innerProperties property: Resource properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY)
- private PrivateEndpointConnectionProvisioningState provisioningState;
+ private PrivateEndpointConnectionProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the privateEndpoint property: The resource of private end point.
@@ -45,7 +39,7 @@ public class PrivateEndpointConnectionInner extends ProxyResource {
* @return the privateEndpoint value.
*/
public PrivateEndpoint privateEndpoint() {
- return this.privateEndpoint;
+ return this.innerProperties() == null ? null : this.innerProperties().privateEndpoint();
}
/**
@@ -55,7 +49,10 @@ public PrivateEndpoint privateEndpoint() {
* @return the PrivateEndpointConnectionInner object itself.
*/
public PrivateEndpointConnectionInner withPrivateEndpoint(PrivateEndpoint privateEndpoint) {
- this.privateEndpoint = privateEndpoint;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new PrivateEndpointConnectionProperties();
+ }
+ this.innerProperties().withPrivateEndpoint(privateEndpoint);
return this;
}
@@ -66,7 +63,7 @@ public PrivateEndpointConnectionInner withPrivateEndpoint(PrivateEndpoint privat
* @return the privateLinkServiceConnectionState value.
*/
public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() {
- return this.privateLinkServiceConnectionState;
+ return this.innerProperties() == null ? null : this.innerProperties().privateLinkServiceConnectionState();
}
/**
@@ -78,7 +75,10 @@ public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() {
*/
public PrivateEndpointConnectionInner withPrivateLinkServiceConnectionState(
PrivateLinkServiceConnectionState privateLinkServiceConnectionState) {
- this.privateLinkServiceConnectionState = privateLinkServiceConnectionState;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new PrivateEndpointConnectionProperties();
+ }
+ this.innerProperties().withPrivateLinkServiceConnectionState(privateLinkServiceConnectionState);
return this;
}
@@ -88,7 +88,7 @@ public PrivateEndpointConnectionInner withPrivateLinkServiceConnectionState(
* @return the provisioningState value.
*/
public PrivateEndpointConnectionProvisioningState provisioningState() {
- return this.provisioningState;
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
}
/**
@@ -97,11 +97,8 @@ public PrivateEndpointConnectionProvisioningState provisioningState() {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (privateEndpoint() != null) {
- privateEndpoint().validate();
- }
- if (privateLinkServiceConnectionState() != null) {
- privateLinkServiceConnectionState().validate();
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateEndpointConnectionProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateEndpointConnectionProperties.java
new file mode 100644
index 000000000000..c8e5241f3960
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateEndpointConnectionProperties.java
@@ -0,0 +1,110 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.mediaservices.models.PrivateEndpoint;
+import com.azure.resourcemanager.mediaservices.models.PrivateEndpointConnectionProvisioningState;
+import com.azure.resourcemanager.mediaservices.models.PrivateLinkServiceConnectionState;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** Properties of the PrivateEndpointConnectProperties. */
+@Fluent
+public final class PrivateEndpointConnectionProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionProperties.class);
+
+ /*
+ * The resource of private end point.
+ */
+ @JsonProperty(value = "privateEndpoint")
+ private PrivateEndpoint privateEndpoint;
+
+ /*
+ * A collection of information about the state of the connection between
+ * service consumer and provider.
+ */
+ @JsonProperty(value = "privateLinkServiceConnectionState", required = true)
+ private PrivateLinkServiceConnectionState privateLinkServiceConnectionState;
+
+ /*
+ * The provisioning state of the private endpoint connection resource.
+ */
+ @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY)
+ private PrivateEndpointConnectionProvisioningState provisioningState;
+
+ /**
+ * Get the privateEndpoint property: The resource of private end point.
+ *
+ * @return the privateEndpoint value.
+ */
+ public PrivateEndpoint privateEndpoint() {
+ return this.privateEndpoint;
+ }
+
+ /**
+ * Set the privateEndpoint property: The resource of private end point.
+ *
+ * @param privateEndpoint the privateEndpoint value to set.
+ * @return the PrivateEndpointConnectionProperties object itself.
+ */
+ public PrivateEndpointConnectionProperties withPrivateEndpoint(PrivateEndpoint privateEndpoint) {
+ this.privateEndpoint = privateEndpoint;
+ return this;
+ }
+
+ /**
+ * Get the privateLinkServiceConnectionState property: A collection of information about the state of the connection
+ * between service consumer and provider.
+ *
+ * @return the privateLinkServiceConnectionState value.
+ */
+ public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() {
+ return this.privateLinkServiceConnectionState;
+ }
+
+ /**
+ * Set the privateLinkServiceConnectionState property: A collection of information about the state of the connection
+ * between service consumer and provider.
+ *
+ * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set.
+ * @return the PrivateEndpointConnectionProperties object itself.
+ */
+ public PrivateEndpointConnectionProperties withPrivateLinkServiceConnectionState(
+ PrivateLinkServiceConnectionState privateLinkServiceConnectionState) {
+ this.privateLinkServiceConnectionState = privateLinkServiceConnectionState;
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: The provisioning state of the private endpoint connection resource.
+ *
+ * @return the provisioningState value.
+ */
+ public PrivateEndpointConnectionProvisioningState provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (privateEndpoint() != null) {
+ privateEndpoint().validate();
+ }
+ if (privateLinkServiceConnectionState() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ "Missing required property privateLinkServiceConnectionState in model"
+ + " PrivateEndpointConnectionProperties"));
+ } else {
+ privateLinkServiceConnectionState().validate();
+ }
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateLinkResourceInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateLinkResourceInner.java
index b4eb20d28ea3..0b0621273aa4 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateLinkResourceInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateLinkResourceInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.util.logging.ClientLogger;
import com.fasterxml.jackson.annotation.JsonIgnore;
@@ -13,28 +12,24 @@
import java.util.List;
/** A private link resource. */
-@JsonFlatten
@Fluent
-public class PrivateLinkResourceInner extends ProxyResource {
+public final class PrivateLinkResourceInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResourceInner.class);
/*
- * The private link resource group id.
+ * Resource properties.
*/
- @JsonProperty(value = "properties.groupId", access = JsonProperty.Access.WRITE_ONLY)
- private String groupId;
+ @JsonProperty(value = "properties")
+ private PrivateLinkResourceProperties innerProperties;
- /*
- * The private link resource required member names.
- */
- @JsonProperty(value = "properties.requiredMembers", access = JsonProperty.Access.WRITE_ONLY)
- private List requiredMembers;
-
- /*
- * The private link resource Private link DNS zone name.
+ /**
+ * Get the innerProperties property: Resource properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.requiredZoneNames")
- private List requiredZoneNames;
+ private PrivateLinkResourceProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the groupId property: The private link resource group id.
@@ -42,7 +37,7 @@ public class PrivateLinkResourceInner extends ProxyResource {
* @return the groupId value.
*/
public String groupId() {
- return this.groupId;
+ return this.innerProperties() == null ? null : this.innerProperties().groupId();
}
/**
@@ -51,7 +46,7 @@ public String groupId() {
* @return the requiredMembers value.
*/
public List requiredMembers() {
- return this.requiredMembers;
+ return this.innerProperties() == null ? null : this.innerProperties().requiredMembers();
}
/**
@@ -60,7 +55,7 @@ public List requiredMembers() {
* @return the requiredZoneNames value.
*/
public List requiredZoneNames() {
- return this.requiredZoneNames;
+ return this.innerProperties() == null ? null : this.innerProperties().requiredZoneNames();
}
/**
@@ -70,7 +65,10 @@ public List requiredZoneNames() {
* @return the PrivateLinkResourceInner object itself.
*/
public PrivateLinkResourceInner withRequiredZoneNames(List requiredZoneNames) {
- this.requiredZoneNames = requiredZoneNames;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new PrivateLinkResourceProperties();
+ }
+ this.innerProperties().withRequiredZoneNames(requiredZoneNames);
return this;
}
@@ -80,5 +78,8 @@ public PrivateLinkResourceInner withRequiredZoneNames(List requiredZoneN
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateLinkResourceProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateLinkResourceProperties.java
new file mode 100644
index 000000000000..7a6259bb3108
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/PrivateLinkResourceProperties.java
@@ -0,0 +1,81 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** Properties of a private link resource. */
+@Fluent
+public final class PrivateLinkResourceProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResourceProperties.class);
+
+ /*
+ * The private link resource group id.
+ */
+ @JsonProperty(value = "groupId", access = JsonProperty.Access.WRITE_ONLY)
+ private String groupId;
+
+ /*
+ * The private link resource required member names.
+ */
+ @JsonProperty(value = "requiredMembers", access = JsonProperty.Access.WRITE_ONLY)
+ private List requiredMembers;
+
+ /*
+ * The private link resource Private link DNS zone name.
+ */
+ @JsonProperty(value = "requiredZoneNames")
+ private List requiredZoneNames;
+
+ /**
+ * Get the groupId property: The private link resource group id.
+ *
+ * @return the groupId value.
+ */
+ public String groupId() {
+ return this.groupId;
+ }
+
+ /**
+ * Get the requiredMembers property: The private link resource required member names.
+ *
+ * @return the requiredMembers value.
+ */
+ public List requiredMembers() {
+ return this.requiredMembers;
+ }
+
+ /**
+ * Get the requiredZoneNames property: The private link resource Private link DNS zone name.
+ *
+ * @return the requiredZoneNames value.
+ */
+ public List requiredZoneNames() {
+ return this.requiredZoneNames;
+ }
+
+ /**
+ * Set the requiredZoneNames property: The private link resource Private link DNS zone name.
+ *
+ * @param requiredZoneNames the requiredZoneNames value to set.
+ * @return the PrivateLinkResourceProperties object itself.
+ */
+ public PrivateLinkResourceProperties withRequiredZoneNames(List requiredZoneNames) {
+ this.requiredZoneNames = requiredZoneNames;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingEndpointInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingEndpointInner.java
index 09d3a0129715..4437871f3841 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingEndpointInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingEndpointInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.Resource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -19,112 +18,30 @@
import java.util.Map;
/** The streaming endpoint. */
-@JsonFlatten
@Fluent
-public class StreamingEndpointInner extends Resource {
+public final class StreamingEndpointInner extends Resource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(StreamingEndpointInner.class);
/*
- * The system metadata relating to this resource.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /*
- * The streaming endpoint description.
- */
- @JsonProperty(value = "properties.description")
- private String description;
-
- /*
- * The number of scale units. Use the Scale operation to adjust this value.
- */
- @JsonProperty(value = "properties.scaleUnits")
- private Integer scaleUnits;
-
- /*
- * This feature is deprecated, do not set a value for this property.
- */
- @JsonProperty(value = "properties.availabilitySetName")
- private String availabilitySetName;
-
- /*
- * The access control definition of the streaming endpoint.
- */
- @JsonProperty(value = "properties.accessControl")
- private StreamingEndpointAccessControl accessControl;
-
- /*
- * Max cache age
- */
- @JsonProperty(value = "properties.maxCacheAge")
- private Long maxCacheAge;
-
- /*
- * The custom host names of the streaming endpoint
- */
- @JsonProperty(value = "properties.customHostNames")
- private List customHostNames;
-
- /*
- * The streaming endpoint host name.
- */
- @JsonProperty(value = "properties.hostName", access = JsonProperty.Access.WRITE_ONLY)
- private String hostname;
-
- /*
- * The CDN enabled flag.
- */
- @JsonProperty(value = "properties.cdnEnabled")
- private Boolean cdnEnabled;
-
- /*
- * The CDN provider name.
- */
- @JsonProperty(value = "properties.cdnProvider")
- private String cdnProvider;
-
- /*
- * The CDN profile name.
+ * The streaming endpoint properties.
*/
- @JsonProperty(value = "properties.cdnProfile")
- private String cdnProfile;
+ @JsonProperty(value = "properties")
+ private StreamingEndpointProperties innerProperties;
/*
- * The provisioning state of the streaming endpoint.
- */
- @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY)
- private String provisioningState;
-
- /*
- * The resource state of the streaming endpoint.
- */
- @JsonProperty(value = "properties.resourceState", access = JsonProperty.Access.WRITE_ONLY)
- private StreamingEndpointResourceState resourceState;
-
- /*
- * The streaming endpoint access policies.
- */
- @JsonProperty(value = "properties.crossSiteAccessPolicies")
- private CrossSiteAccessPolicies crossSiteAccessPolicies;
-
- /*
- * The free trial expiration time.
- */
- @JsonProperty(value = "properties.freeTrialEndTime", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime freeTrialEndTime;
-
- /*
- * The exact time the streaming endpoint was created.
+ * The system metadata relating to this resource.
*/
- @JsonProperty(value = "properties.created", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime created;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData systemData;
- /*
- * The exact time the streaming endpoint was last modified.
+ /**
+ * Get the innerProperties property: The streaming endpoint properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.lastModified", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime lastModified;
+ private StreamingEndpointProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the systemData property: The system metadata relating to this resource.
@@ -135,13 +52,27 @@ public SystemData systemData() {
return this.systemData;
}
+ /** {@inheritDoc} */
+ @Override
+ public StreamingEndpointInner withLocation(String location) {
+ super.withLocation(location);
+ return this;
+ }
+
+ /** {@inheritDoc} */
+ @Override
+ public StreamingEndpointInner withTags(Map tags) {
+ super.withTags(tags);
+ return this;
+ }
+
/**
* Get the description property: The streaming endpoint description.
*
* @return the description value.
*/
public String description() {
- return this.description;
+ return this.innerProperties() == null ? null : this.innerProperties().description();
}
/**
@@ -151,7 +82,10 @@ public String description() {
* @return the StreamingEndpointInner object itself.
*/
public StreamingEndpointInner withDescription(String description) {
- this.description = description;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingEndpointProperties();
+ }
+ this.innerProperties().withDescription(description);
return this;
}
@@ -161,7 +95,7 @@ public StreamingEndpointInner withDescription(String description) {
* @return the scaleUnits value.
*/
public Integer scaleUnits() {
- return this.scaleUnits;
+ return this.innerProperties() == null ? null : this.innerProperties().scaleUnits();
}
/**
@@ -171,7 +105,10 @@ public Integer scaleUnits() {
* @return the StreamingEndpointInner object itself.
*/
public StreamingEndpointInner withScaleUnits(Integer scaleUnits) {
- this.scaleUnits = scaleUnits;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingEndpointProperties();
+ }
+ this.innerProperties().withScaleUnits(scaleUnits);
return this;
}
@@ -181,7 +118,7 @@ public StreamingEndpointInner withScaleUnits(Integer scaleUnits) {
* @return the availabilitySetName value.
*/
public String availabilitySetName() {
- return this.availabilitySetName;
+ return this.innerProperties() == null ? null : this.innerProperties().availabilitySetName();
}
/**
@@ -191,7 +128,10 @@ public String availabilitySetName() {
* @return the StreamingEndpointInner object itself.
*/
public StreamingEndpointInner withAvailabilitySetName(String availabilitySetName) {
- this.availabilitySetName = availabilitySetName;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingEndpointProperties();
+ }
+ this.innerProperties().withAvailabilitySetName(availabilitySetName);
return this;
}
@@ -201,7 +141,7 @@ public StreamingEndpointInner withAvailabilitySetName(String availabilitySetName
* @return the accessControl value.
*/
public StreamingEndpointAccessControl accessControl() {
- return this.accessControl;
+ return this.innerProperties() == null ? null : this.innerProperties().accessControl();
}
/**
@@ -211,7 +151,10 @@ public StreamingEndpointAccessControl accessControl() {
* @return the StreamingEndpointInner object itself.
*/
public StreamingEndpointInner withAccessControl(StreamingEndpointAccessControl accessControl) {
- this.accessControl = accessControl;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingEndpointProperties();
+ }
+ this.innerProperties().withAccessControl(accessControl);
return this;
}
@@ -221,7 +164,7 @@ public StreamingEndpointInner withAccessControl(StreamingEndpointAccessControl a
* @return the maxCacheAge value.
*/
public Long maxCacheAge() {
- return this.maxCacheAge;
+ return this.innerProperties() == null ? null : this.innerProperties().maxCacheAge();
}
/**
@@ -231,7 +174,10 @@ public Long maxCacheAge() {
* @return the StreamingEndpointInner object itself.
*/
public StreamingEndpointInner withMaxCacheAge(Long maxCacheAge) {
- this.maxCacheAge = maxCacheAge;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingEndpointProperties();
+ }
+ this.innerProperties().withMaxCacheAge(maxCacheAge);
return this;
}
@@ -241,7 +187,7 @@ public StreamingEndpointInner withMaxCacheAge(Long maxCacheAge) {
* @return the customHostNames value.
*/
public List customHostNames() {
- return this.customHostNames;
+ return this.innerProperties() == null ? null : this.innerProperties().customHostNames();
}
/**
@@ -251,7 +197,10 @@ public List customHostNames() {
* @return the StreamingEndpointInner object itself.
*/
public StreamingEndpointInner withCustomHostNames(List customHostNames) {
- this.customHostNames = customHostNames;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingEndpointProperties();
+ }
+ this.innerProperties().withCustomHostNames(customHostNames);
return this;
}
@@ -261,7 +210,7 @@ public StreamingEndpointInner withCustomHostNames(List customHostNames)
* @return the hostname value.
*/
public String hostname() {
- return this.hostname;
+ return this.innerProperties() == null ? null : this.innerProperties().hostname();
}
/**
@@ -270,7 +219,7 @@ public String hostname() {
* @return the cdnEnabled value.
*/
public Boolean cdnEnabled() {
- return this.cdnEnabled;
+ return this.innerProperties() == null ? null : this.innerProperties().cdnEnabled();
}
/**
@@ -280,7 +229,10 @@ public Boolean cdnEnabled() {
* @return the StreamingEndpointInner object itself.
*/
public StreamingEndpointInner withCdnEnabled(Boolean cdnEnabled) {
- this.cdnEnabled = cdnEnabled;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingEndpointProperties();
+ }
+ this.innerProperties().withCdnEnabled(cdnEnabled);
return this;
}
@@ -290,7 +242,7 @@ public StreamingEndpointInner withCdnEnabled(Boolean cdnEnabled) {
* @return the cdnProvider value.
*/
public String cdnProvider() {
- return this.cdnProvider;
+ return this.innerProperties() == null ? null : this.innerProperties().cdnProvider();
}
/**
@@ -300,7 +252,10 @@ public String cdnProvider() {
* @return the StreamingEndpointInner object itself.
*/
public StreamingEndpointInner withCdnProvider(String cdnProvider) {
- this.cdnProvider = cdnProvider;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingEndpointProperties();
+ }
+ this.innerProperties().withCdnProvider(cdnProvider);
return this;
}
@@ -310,7 +265,7 @@ public StreamingEndpointInner withCdnProvider(String cdnProvider) {
* @return the cdnProfile value.
*/
public String cdnProfile() {
- return this.cdnProfile;
+ return this.innerProperties() == null ? null : this.innerProperties().cdnProfile();
}
/**
@@ -320,7 +275,10 @@ public String cdnProfile() {
* @return the StreamingEndpointInner object itself.
*/
public StreamingEndpointInner withCdnProfile(String cdnProfile) {
- this.cdnProfile = cdnProfile;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingEndpointProperties();
+ }
+ this.innerProperties().withCdnProfile(cdnProfile);
return this;
}
@@ -330,7 +288,7 @@ public StreamingEndpointInner withCdnProfile(String cdnProfile) {
* @return the provisioningState value.
*/
public String provisioningState() {
- return this.provisioningState;
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
}
/**
@@ -339,7 +297,7 @@ public String provisioningState() {
* @return the resourceState value.
*/
public StreamingEndpointResourceState resourceState() {
- return this.resourceState;
+ return this.innerProperties() == null ? null : this.innerProperties().resourceState();
}
/**
@@ -348,7 +306,7 @@ public StreamingEndpointResourceState resourceState() {
* @return the crossSiteAccessPolicies value.
*/
public CrossSiteAccessPolicies crossSiteAccessPolicies() {
- return this.crossSiteAccessPolicies;
+ return this.innerProperties() == null ? null : this.innerProperties().crossSiteAccessPolicies();
}
/**
@@ -358,7 +316,10 @@ public CrossSiteAccessPolicies crossSiteAccessPolicies() {
* @return the StreamingEndpointInner object itself.
*/
public StreamingEndpointInner withCrossSiteAccessPolicies(CrossSiteAccessPolicies crossSiteAccessPolicies) {
- this.crossSiteAccessPolicies = crossSiteAccessPolicies;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingEndpointProperties();
+ }
+ this.innerProperties().withCrossSiteAccessPolicies(crossSiteAccessPolicies);
return this;
}
@@ -368,7 +329,7 @@ public StreamingEndpointInner withCrossSiteAccessPolicies(CrossSiteAccessPolicie
* @return the freeTrialEndTime value.
*/
public OffsetDateTime freeTrialEndTime() {
- return this.freeTrialEndTime;
+ return this.innerProperties() == null ? null : this.innerProperties().freeTrialEndTime();
}
/**
@@ -377,7 +338,7 @@ public OffsetDateTime freeTrialEndTime() {
* @return the created value.
*/
public OffsetDateTime created() {
- return this.created;
+ return this.innerProperties() == null ? null : this.innerProperties().created();
}
/**
@@ -386,21 +347,7 @@ public OffsetDateTime created() {
* @return the lastModified value.
*/
public OffsetDateTime lastModified() {
- return this.lastModified;
- }
-
- /** {@inheritDoc} */
- @Override
- public StreamingEndpointInner withLocation(String location) {
- super.withLocation(location);
- return this;
- }
-
- /** {@inheritDoc} */
- @Override
- public StreamingEndpointInner withTags(Map tags) {
- super.withTags(tags);
- return this;
+ return this.innerProperties() == null ? null : this.innerProperties().lastModified();
}
/**
@@ -409,11 +356,8 @@ public StreamingEndpointInner withTags(Map tags) {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (accessControl() != null) {
- accessControl().validate();
- }
- if (crossSiteAccessPolicies() != null) {
- crossSiteAccessPolicies().validate();
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingEndpointProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingEndpointProperties.java
new file mode 100644
index 000000000000..8bb1c90e4f19
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingEndpointProperties.java
@@ -0,0 +1,385 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.mediaservices.models.CrossSiteAccessPolicies;
+import com.azure.resourcemanager.mediaservices.models.StreamingEndpointAccessControl;
+import com.azure.resourcemanager.mediaservices.models.StreamingEndpointResourceState;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+import java.util.List;
+
+/** The streaming endpoint properties. */
+@Fluent
+public final class StreamingEndpointProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(StreamingEndpointProperties.class);
+
+ /*
+ * The streaming endpoint description.
+ */
+ @JsonProperty(value = "description")
+ private String description;
+
+ /*
+ * The number of scale units. Use the Scale operation to adjust this value.
+ */
+ @JsonProperty(value = "scaleUnits", required = true)
+ private int scaleUnits;
+
+ /*
+ * This feature is deprecated, do not set a value for this property.
+ */
+ @JsonProperty(value = "availabilitySetName")
+ private String availabilitySetName;
+
+ /*
+ * The access control definition of the streaming endpoint.
+ */
+ @JsonProperty(value = "accessControl")
+ private StreamingEndpointAccessControl accessControl;
+
+ /*
+ * Max cache age
+ */
+ @JsonProperty(value = "maxCacheAge")
+ private Long maxCacheAge;
+
+ /*
+ * The custom host names of the streaming endpoint
+ */
+ @JsonProperty(value = "customHostNames")
+ private List customHostNames;
+
+ /*
+ * The streaming endpoint host name.
+ */
+ @JsonProperty(value = "hostName", access = JsonProperty.Access.WRITE_ONLY)
+ private String hostname;
+
+ /*
+ * The CDN enabled flag.
+ */
+ @JsonProperty(value = "cdnEnabled")
+ private Boolean cdnEnabled;
+
+ /*
+ * The CDN provider name.
+ */
+ @JsonProperty(value = "cdnProvider")
+ private String cdnProvider;
+
+ /*
+ * The CDN profile name.
+ */
+ @JsonProperty(value = "cdnProfile")
+ private String cdnProfile;
+
+ /*
+ * The provisioning state of the streaming endpoint.
+ */
+ @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY)
+ private String provisioningState;
+
+ /*
+ * The resource state of the streaming endpoint.
+ */
+ @JsonProperty(value = "resourceState", access = JsonProperty.Access.WRITE_ONLY)
+ private StreamingEndpointResourceState resourceState;
+
+ /*
+ * The streaming endpoint access policies.
+ */
+ @JsonProperty(value = "crossSiteAccessPolicies")
+ private CrossSiteAccessPolicies crossSiteAccessPolicies;
+
+ /*
+ * The free trial expiration time.
+ */
+ @JsonProperty(value = "freeTrialEndTime", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime freeTrialEndTime;
+
+ /*
+ * The exact time the streaming endpoint was created.
+ */
+ @JsonProperty(value = "created", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime created;
+
+ /*
+ * The exact time the streaming endpoint was last modified.
+ */
+ @JsonProperty(value = "lastModified", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime lastModified;
+
+ /**
+ * Get the description property: The streaming endpoint description.
+ *
+ * @return the description value.
+ */
+ public String description() {
+ return this.description;
+ }
+
+ /**
+ * Set the description property: The streaming endpoint description.
+ *
+ * @param description the description value to set.
+ * @return the StreamingEndpointProperties object itself.
+ */
+ public StreamingEndpointProperties withDescription(String description) {
+ this.description = description;
+ return this;
+ }
+
+ /**
+ * Get the scaleUnits property: The number of scale units. Use the Scale operation to adjust this value.
+ *
+ * @return the scaleUnits value.
+ */
+ public int scaleUnits() {
+ return this.scaleUnits;
+ }
+
+ /**
+ * Set the scaleUnits property: The number of scale units. Use the Scale operation to adjust this value.
+ *
+ * @param scaleUnits the scaleUnits value to set.
+ * @return the StreamingEndpointProperties object itself.
+ */
+ public StreamingEndpointProperties withScaleUnits(int scaleUnits) {
+ this.scaleUnits = scaleUnits;
+ return this;
+ }
+
+ /**
+ * Get the availabilitySetName property: This feature is deprecated, do not set a value for this property.
+ *
+ * @return the availabilitySetName value.
+ */
+ public String availabilitySetName() {
+ return this.availabilitySetName;
+ }
+
+ /**
+ * Set the availabilitySetName property: This feature is deprecated, do not set a value for this property.
+ *
+ * @param availabilitySetName the availabilitySetName value to set.
+ * @return the StreamingEndpointProperties object itself.
+ */
+ public StreamingEndpointProperties withAvailabilitySetName(String availabilitySetName) {
+ this.availabilitySetName = availabilitySetName;
+ return this;
+ }
+
+ /**
+ * Get the accessControl property: The access control definition of the streaming endpoint.
+ *
+ * @return the accessControl value.
+ */
+ public StreamingEndpointAccessControl accessControl() {
+ return this.accessControl;
+ }
+
+ /**
+ * Set the accessControl property: The access control definition of the streaming endpoint.
+ *
+ * @param accessControl the accessControl value to set.
+ * @return the StreamingEndpointProperties object itself.
+ */
+ public StreamingEndpointProperties withAccessControl(StreamingEndpointAccessControl accessControl) {
+ this.accessControl = accessControl;
+ return this;
+ }
+
+ /**
+ * Get the maxCacheAge property: Max cache age.
+ *
+ * @return the maxCacheAge value.
+ */
+ public Long maxCacheAge() {
+ return this.maxCacheAge;
+ }
+
+ /**
+ * Set the maxCacheAge property: Max cache age.
+ *
+ * @param maxCacheAge the maxCacheAge value to set.
+ * @return the StreamingEndpointProperties object itself.
+ */
+ public StreamingEndpointProperties withMaxCacheAge(Long maxCacheAge) {
+ this.maxCacheAge = maxCacheAge;
+ return this;
+ }
+
+ /**
+ * Get the customHostNames property: The custom host names of the streaming endpoint.
+ *
+ * @return the customHostNames value.
+ */
+ public List customHostNames() {
+ return this.customHostNames;
+ }
+
+ /**
+ * Set the customHostNames property: The custom host names of the streaming endpoint.
+ *
+ * @param customHostNames the customHostNames value to set.
+ * @return the StreamingEndpointProperties object itself.
+ */
+ public StreamingEndpointProperties withCustomHostNames(List customHostNames) {
+ this.customHostNames = customHostNames;
+ return this;
+ }
+
+ /**
+ * Get the hostname property: The streaming endpoint host name.
+ *
+ * @return the hostname value.
+ */
+ public String hostname() {
+ return this.hostname;
+ }
+
+ /**
+ * Get the cdnEnabled property: The CDN enabled flag.
+ *
+ * @return the cdnEnabled value.
+ */
+ public Boolean cdnEnabled() {
+ return this.cdnEnabled;
+ }
+
+ /**
+ * Set the cdnEnabled property: The CDN enabled flag.
+ *
+ * @param cdnEnabled the cdnEnabled value to set.
+ * @return the StreamingEndpointProperties object itself.
+ */
+ public StreamingEndpointProperties withCdnEnabled(Boolean cdnEnabled) {
+ this.cdnEnabled = cdnEnabled;
+ return this;
+ }
+
+ /**
+ * Get the cdnProvider property: The CDN provider name.
+ *
+ * @return the cdnProvider value.
+ */
+ public String cdnProvider() {
+ return this.cdnProvider;
+ }
+
+ /**
+ * Set the cdnProvider property: The CDN provider name.
+ *
+ * @param cdnProvider the cdnProvider value to set.
+ * @return the StreamingEndpointProperties object itself.
+ */
+ public StreamingEndpointProperties withCdnProvider(String cdnProvider) {
+ this.cdnProvider = cdnProvider;
+ return this;
+ }
+
+ /**
+ * Get the cdnProfile property: The CDN profile name.
+ *
+ * @return the cdnProfile value.
+ */
+ public String cdnProfile() {
+ return this.cdnProfile;
+ }
+
+ /**
+ * Set the cdnProfile property: The CDN profile name.
+ *
+ * @param cdnProfile the cdnProfile value to set.
+ * @return the StreamingEndpointProperties object itself.
+ */
+ public StreamingEndpointProperties withCdnProfile(String cdnProfile) {
+ this.cdnProfile = cdnProfile;
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: The provisioning state of the streaming endpoint.
+ *
+ * @return the provisioningState value.
+ */
+ public String provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Get the resourceState property: The resource state of the streaming endpoint.
+ *
+ * @return the resourceState value.
+ */
+ public StreamingEndpointResourceState resourceState() {
+ return this.resourceState;
+ }
+
+ /**
+ * Get the crossSiteAccessPolicies property: The streaming endpoint access policies.
+ *
+ * @return the crossSiteAccessPolicies value.
+ */
+ public CrossSiteAccessPolicies crossSiteAccessPolicies() {
+ return this.crossSiteAccessPolicies;
+ }
+
+ /**
+ * Set the crossSiteAccessPolicies property: The streaming endpoint access policies.
+ *
+ * @param crossSiteAccessPolicies the crossSiteAccessPolicies value to set.
+ * @return the StreamingEndpointProperties object itself.
+ */
+ public StreamingEndpointProperties withCrossSiteAccessPolicies(CrossSiteAccessPolicies crossSiteAccessPolicies) {
+ this.crossSiteAccessPolicies = crossSiteAccessPolicies;
+ return this;
+ }
+
+ /**
+ * Get the freeTrialEndTime property: The free trial expiration time.
+ *
+ * @return the freeTrialEndTime value.
+ */
+ public OffsetDateTime freeTrialEndTime() {
+ return this.freeTrialEndTime;
+ }
+
+ /**
+ * Get the created property: The exact time the streaming endpoint was created.
+ *
+ * @return the created value.
+ */
+ public OffsetDateTime created() {
+ return this.created;
+ }
+
+ /**
+ * Get the lastModified property: The exact time the streaming endpoint was last modified.
+ *
+ * @return the lastModified value.
+ */
+ public OffsetDateTime lastModified() {
+ return this.lastModified;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (accessControl() != null) {
+ accessControl().validate();
+ }
+ if (crossSiteAccessPolicies() != null) {
+ crossSiteAccessPolicies().validate();
+ }
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingLocatorInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingLocatorInner.java
index 683a4fb4c226..7f10434080ca 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingLocatorInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingLocatorInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -17,82 +16,30 @@
import java.util.UUID;
/** A Streaming Locator resource. */
-@JsonFlatten
@Fluent
-public class StreamingLocatorInner extends ProxyResource {
+public final class StreamingLocatorInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(StreamingLocatorInner.class);
/*
- * The system metadata relating to this resource.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /*
- * Asset Name
- */
- @JsonProperty(value = "properties.assetName")
- private String assetName;
-
- /*
- * The creation time of the Streaming Locator.
- */
- @JsonProperty(value = "properties.created", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime created;
-
- /*
- * The start time of the Streaming Locator.
- */
- @JsonProperty(value = "properties.startTime")
- private OffsetDateTime startTime;
-
- /*
- * The end time of the Streaming Locator.
+ * Properties of the Streaming Locator.
*/
- @JsonProperty(value = "properties.endTime")
- private OffsetDateTime endTime;
+ @JsonProperty(value = "properties")
+ private StreamingLocatorProperties innerProperties;
/*
- * The StreamingLocatorId of the Streaming Locator.
- */
- @JsonProperty(value = "properties.streamingLocatorId")
- private UUID streamingLocatorId;
-
- /*
- * Name of the Streaming Policy used by this Streaming Locator. Either
- * specify the name of Streaming Policy you created or use one of the
- * predefined Streaming Policies. The predefined Streaming Policies
- * available are: 'Predefined_DownloadOnly',
- * 'Predefined_ClearStreamingOnly', 'Predefined_DownloadAndClearStreaming',
- * 'Predefined_ClearKey', 'Predefined_MultiDrmCencStreaming' and
- * 'Predefined_MultiDrmStreaming'
- */
- @JsonProperty(value = "properties.streamingPolicyName")
- private String streamingPolicyName;
-
- /*
- * Name of the default ContentKeyPolicy used by this Streaming Locator.
- */
- @JsonProperty(value = "properties.defaultContentKeyPolicyName")
- private String defaultContentKeyPolicyName;
-
- /*
- * The ContentKeys used by this Streaming Locator.
- */
- @JsonProperty(value = "properties.contentKeys")
- private List contentKeys;
-
- /*
- * Alternative Media ID of this Streaming Locator
+ * The system metadata relating to this resource.
*/
- @JsonProperty(value = "properties.alternativeMediaId")
- private String alternativeMediaId;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData systemData;
- /*
- * A list of asset or account filters which apply to this streaming locator
+ /**
+ * Get the innerProperties property: Properties of the Streaming Locator.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.filters")
- private List filters;
+ private StreamingLocatorProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the systemData property: The system metadata relating to this resource.
@@ -109,7 +56,7 @@ public SystemData systemData() {
* @return the assetName value.
*/
public String assetName() {
- return this.assetName;
+ return this.innerProperties() == null ? null : this.innerProperties().assetName();
}
/**
@@ -119,7 +66,10 @@ public String assetName() {
* @return the StreamingLocatorInner object itself.
*/
public StreamingLocatorInner withAssetName(String assetName) {
- this.assetName = assetName;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingLocatorProperties();
+ }
+ this.innerProperties().withAssetName(assetName);
return this;
}
@@ -129,7 +79,7 @@ public StreamingLocatorInner withAssetName(String assetName) {
* @return the created value.
*/
public OffsetDateTime created() {
- return this.created;
+ return this.innerProperties() == null ? null : this.innerProperties().created();
}
/**
@@ -138,7 +88,7 @@ public OffsetDateTime created() {
* @return the startTime value.
*/
public OffsetDateTime startTime() {
- return this.startTime;
+ return this.innerProperties() == null ? null : this.innerProperties().startTime();
}
/**
@@ -148,7 +98,10 @@ public OffsetDateTime startTime() {
* @return the StreamingLocatorInner object itself.
*/
public StreamingLocatorInner withStartTime(OffsetDateTime startTime) {
- this.startTime = startTime;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingLocatorProperties();
+ }
+ this.innerProperties().withStartTime(startTime);
return this;
}
@@ -158,7 +111,7 @@ public StreamingLocatorInner withStartTime(OffsetDateTime startTime) {
* @return the endTime value.
*/
public OffsetDateTime endTime() {
- return this.endTime;
+ return this.innerProperties() == null ? null : this.innerProperties().endTime();
}
/**
@@ -168,7 +121,10 @@ public OffsetDateTime endTime() {
* @return the StreamingLocatorInner object itself.
*/
public StreamingLocatorInner withEndTime(OffsetDateTime endTime) {
- this.endTime = endTime;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingLocatorProperties();
+ }
+ this.innerProperties().withEndTime(endTime);
return this;
}
@@ -178,7 +134,7 @@ public StreamingLocatorInner withEndTime(OffsetDateTime endTime) {
* @return the streamingLocatorId value.
*/
public UUID streamingLocatorId() {
- return this.streamingLocatorId;
+ return this.innerProperties() == null ? null : this.innerProperties().streamingLocatorId();
}
/**
@@ -188,7 +144,10 @@ public UUID streamingLocatorId() {
* @return the StreamingLocatorInner object itself.
*/
public StreamingLocatorInner withStreamingLocatorId(UUID streamingLocatorId) {
- this.streamingLocatorId = streamingLocatorId;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingLocatorProperties();
+ }
+ this.innerProperties().withStreamingLocatorId(streamingLocatorId);
return this;
}
@@ -202,7 +161,7 @@ public StreamingLocatorInner withStreamingLocatorId(UUID streamingLocatorId) {
* @return the streamingPolicyName value.
*/
public String streamingPolicyName() {
- return this.streamingPolicyName;
+ return this.innerProperties() == null ? null : this.innerProperties().streamingPolicyName();
}
/**
@@ -216,7 +175,10 @@ public String streamingPolicyName() {
* @return the StreamingLocatorInner object itself.
*/
public StreamingLocatorInner withStreamingPolicyName(String streamingPolicyName) {
- this.streamingPolicyName = streamingPolicyName;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingLocatorProperties();
+ }
+ this.innerProperties().withStreamingPolicyName(streamingPolicyName);
return this;
}
@@ -227,7 +189,7 @@ public StreamingLocatorInner withStreamingPolicyName(String streamingPolicyName)
* @return the defaultContentKeyPolicyName value.
*/
public String defaultContentKeyPolicyName() {
- return this.defaultContentKeyPolicyName;
+ return this.innerProperties() == null ? null : this.innerProperties().defaultContentKeyPolicyName();
}
/**
@@ -238,7 +200,10 @@ public String defaultContentKeyPolicyName() {
* @return the StreamingLocatorInner object itself.
*/
public StreamingLocatorInner withDefaultContentKeyPolicyName(String defaultContentKeyPolicyName) {
- this.defaultContentKeyPolicyName = defaultContentKeyPolicyName;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingLocatorProperties();
+ }
+ this.innerProperties().withDefaultContentKeyPolicyName(defaultContentKeyPolicyName);
return this;
}
@@ -248,7 +213,7 @@ public StreamingLocatorInner withDefaultContentKeyPolicyName(String defaultConte
* @return the contentKeys value.
*/
public List contentKeys() {
- return this.contentKeys;
+ return this.innerProperties() == null ? null : this.innerProperties().contentKeys();
}
/**
@@ -258,7 +223,10 @@ public List contentKeys() {
* @return the StreamingLocatorInner object itself.
*/
public StreamingLocatorInner withContentKeys(List contentKeys) {
- this.contentKeys = contentKeys;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingLocatorProperties();
+ }
+ this.innerProperties().withContentKeys(contentKeys);
return this;
}
@@ -268,7 +236,7 @@ public StreamingLocatorInner withContentKeys(List co
* @return the alternativeMediaId value.
*/
public String alternativeMediaId() {
- return this.alternativeMediaId;
+ return this.innerProperties() == null ? null : this.innerProperties().alternativeMediaId();
}
/**
@@ -278,7 +246,10 @@ public String alternativeMediaId() {
* @return the StreamingLocatorInner object itself.
*/
public StreamingLocatorInner withAlternativeMediaId(String alternativeMediaId) {
- this.alternativeMediaId = alternativeMediaId;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingLocatorProperties();
+ }
+ this.innerProperties().withAlternativeMediaId(alternativeMediaId);
return this;
}
@@ -288,7 +259,7 @@ public StreamingLocatorInner withAlternativeMediaId(String alternativeMediaId) {
* @return the filters value.
*/
public List filters() {
- return this.filters;
+ return this.innerProperties() == null ? null : this.innerProperties().filters();
}
/**
@@ -298,7 +269,10 @@ public List filters() {
* @return the StreamingLocatorInner object itself.
*/
public StreamingLocatorInner withFilters(List filters) {
- this.filters = filters;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingLocatorProperties();
+ }
+ this.innerProperties().withFilters(filters);
return this;
}
@@ -308,8 +282,8 @@ public StreamingLocatorInner withFilters(List filters) {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (contentKeys() != null) {
- contentKeys().forEach(e -> e.validate());
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingLocatorProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingLocatorProperties.java
new file mode 100644
index 000000000000..8bb98a994783
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingLocatorProperties.java
@@ -0,0 +1,308 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.mediaservices.models.StreamingLocatorContentKey;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+import java.util.List;
+import java.util.UUID;
+
+/** Properties of the Streaming Locator. */
+@Fluent
+public final class StreamingLocatorProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(StreamingLocatorProperties.class);
+
+ /*
+ * Asset Name
+ */
+ @JsonProperty(value = "assetName", required = true)
+ private String assetName;
+
+ /*
+ * The creation time of the Streaming Locator.
+ */
+ @JsonProperty(value = "created", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime created;
+
+ /*
+ * The start time of the Streaming Locator.
+ */
+ @JsonProperty(value = "startTime")
+ private OffsetDateTime startTime;
+
+ /*
+ * The end time of the Streaming Locator.
+ */
+ @JsonProperty(value = "endTime")
+ private OffsetDateTime endTime;
+
+ /*
+ * The StreamingLocatorId of the Streaming Locator.
+ */
+ @JsonProperty(value = "streamingLocatorId")
+ private UUID streamingLocatorId;
+
+ /*
+ * Name of the Streaming Policy used by this Streaming Locator. Either
+ * specify the name of Streaming Policy you created or use one of the
+ * predefined Streaming Policies. The predefined Streaming Policies
+ * available are: 'Predefined_DownloadOnly',
+ * 'Predefined_ClearStreamingOnly', 'Predefined_DownloadAndClearStreaming',
+ * 'Predefined_ClearKey', 'Predefined_MultiDrmCencStreaming' and
+ * 'Predefined_MultiDrmStreaming'
+ */
+ @JsonProperty(value = "streamingPolicyName", required = true)
+ private String streamingPolicyName;
+
+ /*
+ * Name of the default ContentKeyPolicy used by this Streaming Locator.
+ */
+ @JsonProperty(value = "defaultContentKeyPolicyName")
+ private String defaultContentKeyPolicyName;
+
+ /*
+ * The ContentKeys used by this Streaming Locator.
+ */
+ @JsonProperty(value = "contentKeys")
+ private List contentKeys;
+
+ /*
+ * Alternative Media ID of this Streaming Locator
+ */
+ @JsonProperty(value = "alternativeMediaId")
+ private String alternativeMediaId;
+
+ /*
+ * A list of asset or account filters which apply to this streaming locator
+ */
+ @JsonProperty(value = "filters")
+ private List filters;
+
+ /**
+ * Get the assetName property: Asset Name.
+ *
+ * @return the assetName value.
+ */
+ public String assetName() {
+ return this.assetName;
+ }
+
+ /**
+ * Set the assetName property: Asset Name.
+ *
+ * @param assetName the assetName value to set.
+ * @return the StreamingLocatorProperties object itself.
+ */
+ public StreamingLocatorProperties withAssetName(String assetName) {
+ this.assetName = assetName;
+ return this;
+ }
+
+ /**
+ * Get the created property: The creation time of the Streaming Locator.
+ *
+ * @return the created value.
+ */
+ public OffsetDateTime created() {
+ return this.created;
+ }
+
+ /**
+ * Get the startTime property: The start time of the Streaming Locator.
+ *
+ * @return the startTime value.
+ */
+ public OffsetDateTime startTime() {
+ return this.startTime;
+ }
+
+ /**
+ * Set the startTime property: The start time of the Streaming Locator.
+ *
+ * @param startTime the startTime value to set.
+ * @return the StreamingLocatorProperties object itself.
+ */
+ public StreamingLocatorProperties withStartTime(OffsetDateTime startTime) {
+ this.startTime = startTime;
+ return this;
+ }
+
+ /**
+ * Get the endTime property: The end time of the Streaming Locator.
+ *
+ * @return the endTime value.
+ */
+ public OffsetDateTime endTime() {
+ return this.endTime;
+ }
+
+ /**
+ * Set the endTime property: The end time of the Streaming Locator.
+ *
+ * @param endTime the endTime value to set.
+ * @return the StreamingLocatorProperties object itself.
+ */
+ public StreamingLocatorProperties withEndTime(OffsetDateTime endTime) {
+ this.endTime = endTime;
+ return this;
+ }
+
+ /**
+ * Get the streamingLocatorId property: The StreamingLocatorId of the Streaming Locator.
+ *
+ * @return the streamingLocatorId value.
+ */
+ public UUID streamingLocatorId() {
+ return this.streamingLocatorId;
+ }
+
+ /**
+ * Set the streamingLocatorId property: The StreamingLocatorId of the Streaming Locator.
+ *
+ * @param streamingLocatorId the streamingLocatorId value to set.
+ * @return the StreamingLocatorProperties object itself.
+ */
+ public StreamingLocatorProperties withStreamingLocatorId(UUID streamingLocatorId) {
+ this.streamingLocatorId = streamingLocatorId;
+ return this;
+ }
+
+ /**
+ * Get the streamingPolicyName property: Name of the Streaming Policy used by this Streaming Locator. Either specify
+ * the name of Streaming Policy you created or use one of the predefined Streaming Policies. The predefined
+ * Streaming Policies available are: 'Predefined_DownloadOnly', 'Predefined_ClearStreamingOnly',
+ * 'Predefined_DownloadAndClearStreaming', 'Predefined_ClearKey', 'Predefined_MultiDrmCencStreaming' and
+ * 'Predefined_MultiDrmStreaming'.
+ *
+ * @return the streamingPolicyName value.
+ */
+ public String streamingPolicyName() {
+ return this.streamingPolicyName;
+ }
+
+ /**
+ * Set the streamingPolicyName property: Name of the Streaming Policy used by this Streaming Locator. Either specify
+ * the name of Streaming Policy you created or use one of the predefined Streaming Policies. The predefined
+ * Streaming Policies available are: 'Predefined_DownloadOnly', 'Predefined_ClearStreamingOnly',
+ * 'Predefined_DownloadAndClearStreaming', 'Predefined_ClearKey', 'Predefined_MultiDrmCencStreaming' and
+ * 'Predefined_MultiDrmStreaming'.
+ *
+ * @param streamingPolicyName the streamingPolicyName value to set.
+ * @return the StreamingLocatorProperties object itself.
+ */
+ public StreamingLocatorProperties withStreamingPolicyName(String streamingPolicyName) {
+ this.streamingPolicyName = streamingPolicyName;
+ return this;
+ }
+
+ /**
+ * Get the defaultContentKeyPolicyName property: Name of the default ContentKeyPolicy used by this Streaming
+ * Locator.
+ *
+ * @return the defaultContentKeyPolicyName value.
+ */
+ public String defaultContentKeyPolicyName() {
+ return this.defaultContentKeyPolicyName;
+ }
+
+ /**
+ * Set the defaultContentKeyPolicyName property: Name of the default ContentKeyPolicy used by this Streaming
+ * Locator.
+ *
+ * @param defaultContentKeyPolicyName the defaultContentKeyPolicyName value to set.
+ * @return the StreamingLocatorProperties object itself.
+ */
+ public StreamingLocatorProperties withDefaultContentKeyPolicyName(String defaultContentKeyPolicyName) {
+ this.defaultContentKeyPolicyName = defaultContentKeyPolicyName;
+ return this;
+ }
+
+ /**
+ * Get the contentKeys property: The ContentKeys used by this Streaming Locator.
+ *
+ * @return the contentKeys value.
+ */
+ public List contentKeys() {
+ return this.contentKeys;
+ }
+
+ /**
+ * Set the contentKeys property: The ContentKeys used by this Streaming Locator.
+ *
+ * @param contentKeys the contentKeys value to set.
+ * @return the StreamingLocatorProperties object itself.
+ */
+ public StreamingLocatorProperties withContentKeys(List contentKeys) {
+ this.contentKeys = contentKeys;
+ return this;
+ }
+
+ /**
+ * Get the alternativeMediaId property: Alternative Media ID of this Streaming Locator.
+ *
+ * @return the alternativeMediaId value.
+ */
+ public String alternativeMediaId() {
+ return this.alternativeMediaId;
+ }
+
+ /**
+ * Set the alternativeMediaId property: Alternative Media ID of this Streaming Locator.
+ *
+ * @param alternativeMediaId the alternativeMediaId value to set.
+ * @return the StreamingLocatorProperties object itself.
+ */
+ public StreamingLocatorProperties withAlternativeMediaId(String alternativeMediaId) {
+ this.alternativeMediaId = alternativeMediaId;
+ return this;
+ }
+
+ /**
+ * Get the filters property: A list of asset or account filters which apply to this streaming locator.
+ *
+ * @return the filters value.
+ */
+ public List filters() {
+ return this.filters;
+ }
+
+ /**
+ * Set the filters property: A list of asset or account filters which apply to this streaming locator.
+ *
+ * @param filters the filters value to set.
+ * @return the StreamingLocatorProperties object itself.
+ */
+ public StreamingLocatorProperties withFilters(List filters) {
+ this.filters = filters;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (assetName() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ "Missing required property assetName in model StreamingLocatorProperties"));
+ }
+ if (streamingPolicyName() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ "Missing required property streamingPolicyName in model StreamingLocatorProperties"));
+ }
+ if (contentKeys() != null) {
+ contentKeys().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingPolicyInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingPolicyInner.java
index 71e99a50eaa9..e5632903bae5 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingPolicyInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingPolicyInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -18,52 +17,30 @@
import java.time.OffsetDateTime;
/** A Streaming Policy resource. */
-@JsonFlatten
@Fluent
-public class StreamingPolicyInner extends ProxyResource {
+public final class StreamingPolicyInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(StreamingPolicyInner.class);
/*
- * The system metadata relating to this resource.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /*
- * Creation time of Streaming Policy
- */
- @JsonProperty(value = "properties.created", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime created;
-
- /*
- * Default ContentKey used by current Streaming Policy
- */
- @JsonProperty(value = "properties.defaultContentKeyPolicyName")
- private String defaultContentKeyPolicyName;
-
- /*
- * Configuration of EnvelopeEncryption
- */
- @JsonProperty(value = "properties.envelopeEncryption")
- private EnvelopeEncryption envelopeEncryption;
-
- /*
- * Configuration of CommonEncryptionCenc
+ * Class to specify properties of Streaming Policy
*/
- @JsonProperty(value = "properties.commonEncryptionCenc")
- private CommonEncryptionCenc commonEncryptionCenc;
+ @JsonProperty(value = "properties")
+ private StreamingPolicyProperties innerProperties;
/*
- * Configuration of CommonEncryptionCbcs
+ * The system metadata relating to this resource.
*/
- @JsonProperty(value = "properties.commonEncryptionCbcs")
- private CommonEncryptionCbcs commonEncryptionCbcs;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData systemData;
- /*
- * Configurations of NoEncryption
+ /**
+ * Get the innerProperties property: Class to specify properties of Streaming Policy.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.noEncryption")
- private NoEncryption noEncryption;
+ private StreamingPolicyProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the systemData property: The system metadata relating to this resource.
@@ -80,7 +57,7 @@ public SystemData systemData() {
* @return the created value.
*/
public OffsetDateTime created() {
- return this.created;
+ return this.innerProperties() == null ? null : this.innerProperties().created();
}
/**
@@ -89,7 +66,7 @@ public OffsetDateTime created() {
* @return the defaultContentKeyPolicyName value.
*/
public String defaultContentKeyPolicyName() {
- return this.defaultContentKeyPolicyName;
+ return this.innerProperties() == null ? null : this.innerProperties().defaultContentKeyPolicyName();
}
/**
@@ -99,7 +76,10 @@ public String defaultContentKeyPolicyName() {
* @return the StreamingPolicyInner object itself.
*/
public StreamingPolicyInner withDefaultContentKeyPolicyName(String defaultContentKeyPolicyName) {
- this.defaultContentKeyPolicyName = defaultContentKeyPolicyName;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingPolicyProperties();
+ }
+ this.innerProperties().withDefaultContentKeyPolicyName(defaultContentKeyPolicyName);
return this;
}
@@ -109,7 +89,7 @@ public StreamingPolicyInner withDefaultContentKeyPolicyName(String defaultConten
* @return the envelopeEncryption value.
*/
public EnvelopeEncryption envelopeEncryption() {
- return this.envelopeEncryption;
+ return this.innerProperties() == null ? null : this.innerProperties().envelopeEncryption();
}
/**
@@ -119,7 +99,10 @@ public EnvelopeEncryption envelopeEncryption() {
* @return the StreamingPolicyInner object itself.
*/
public StreamingPolicyInner withEnvelopeEncryption(EnvelopeEncryption envelopeEncryption) {
- this.envelopeEncryption = envelopeEncryption;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingPolicyProperties();
+ }
+ this.innerProperties().withEnvelopeEncryption(envelopeEncryption);
return this;
}
@@ -129,7 +112,7 @@ public StreamingPolicyInner withEnvelopeEncryption(EnvelopeEncryption envelopeEn
* @return the commonEncryptionCenc value.
*/
public CommonEncryptionCenc commonEncryptionCenc() {
- return this.commonEncryptionCenc;
+ return this.innerProperties() == null ? null : this.innerProperties().commonEncryptionCenc();
}
/**
@@ -139,7 +122,10 @@ public CommonEncryptionCenc commonEncryptionCenc() {
* @return the StreamingPolicyInner object itself.
*/
public StreamingPolicyInner withCommonEncryptionCenc(CommonEncryptionCenc commonEncryptionCenc) {
- this.commonEncryptionCenc = commonEncryptionCenc;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingPolicyProperties();
+ }
+ this.innerProperties().withCommonEncryptionCenc(commonEncryptionCenc);
return this;
}
@@ -149,7 +135,7 @@ public StreamingPolicyInner withCommonEncryptionCenc(CommonEncryptionCenc common
* @return the commonEncryptionCbcs value.
*/
public CommonEncryptionCbcs commonEncryptionCbcs() {
- return this.commonEncryptionCbcs;
+ return this.innerProperties() == null ? null : this.innerProperties().commonEncryptionCbcs();
}
/**
@@ -159,7 +145,10 @@ public CommonEncryptionCbcs commonEncryptionCbcs() {
* @return the StreamingPolicyInner object itself.
*/
public StreamingPolicyInner withCommonEncryptionCbcs(CommonEncryptionCbcs commonEncryptionCbcs) {
- this.commonEncryptionCbcs = commonEncryptionCbcs;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingPolicyProperties();
+ }
+ this.innerProperties().withCommonEncryptionCbcs(commonEncryptionCbcs);
return this;
}
@@ -169,7 +158,7 @@ public StreamingPolicyInner withCommonEncryptionCbcs(CommonEncryptionCbcs common
* @return the noEncryption value.
*/
public NoEncryption noEncryption() {
- return this.noEncryption;
+ return this.innerProperties() == null ? null : this.innerProperties().noEncryption();
}
/**
@@ -179,7 +168,10 @@ public NoEncryption noEncryption() {
* @return the StreamingPolicyInner object itself.
*/
public StreamingPolicyInner withNoEncryption(NoEncryption noEncryption) {
- this.noEncryption = noEncryption;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new StreamingPolicyProperties();
+ }
+ this.innerProperties().withNoEncryption(noEncryption);
return this;
}
@@ -189,17 +181,8 @@ public StreamingPolicyInner withNoEncryption(NoEncryption noEncryption) {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (envelopeEncryption() != null) {
- envelopeEncryption().validate();
- }
- if (commonEncryptionCenc() != null) {
- commonEncryptionCenc().validate();
- }
- if (commonEncryptionCbcs() != null) {
- commonEncryptionCbcs().validate();
- }
- if (noEncryption() != null) {
- noEncryption().validate();
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingPolicyProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingPolicyProperties.java
new file mode 100644
index 000000000000..a3e747f7f111
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/StreamingPolicyProperties.java
@@ -0,0 +1,186 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.mediaservices.models.CommonEncryptionCbcs;
+import com.azure.resourcemanager.mediaservices.models.CommonEncryptionCenc;
+import com.azure.resourcemanager.mediaservices.models.EnvelopeEncryption;
+import com.azure.resourcemanager.mediaservices.models.NoEncryption;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+
+/** Class to specify properties of Streaming Policy. */
+@Fluent
+public final class StreamingPolicyProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(StreamingPolicyProperties.class);
+
+ /*
+ * Creation time of Streaming Policy
+ */
+ @JsonProperty(value = "created", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime created;
+
+ /*
+ * Default ContentKey used by current Streaming Policy
+ */
+ @JsonProperty(value = "defaultContentKeyPolicyName")
+ private String defaultContentKeyPolicyName;
+
+ /*
+ * Configuration of EnvelopeEncryption
+ */
+ @JsonProperty(value = "envelopeEncryption")
+ private EnvelopeEncryption envelopeEncryption;
+
+ /*
+ * Configuration of CommonEncryptionCenc
+ */
+ @JsonProperty(value = "commonEncryptionCenc")
+ private CommonEncryptionCenc commonEncryptionCenc;
+
+ /*
+ * Configuration of CommonEncryptionCbcs
+ */
+ @JsonProperty(value = "commonEncryptionCbcs")
+ private CommonEncryptionCbcs commonEncryptionCbcs;
+
+ /*
+ * Configurations of NoEncryption
+ */
+ @JsonProperty(value = "noEncryption")
+ private NoEncryption noEncryption;
+
+ /**
+ * Get the created property: Creation time of Streaming Policy.
+ *
+ * @return the created value.
+ */
+ public OffsetDateTime created() {
+ return this.created;
+ }
+
+ /**
+ * Get the defaultContentKeyPolicyName property: Default ContentKey used by current Streaming Policy.
+ *
+ * @return the defaultContentKeyPolicyName value.
+ */
+ public String defaultContentKeyPolicyName() {
+ return this.defaultContentKeyPolicyName;
+ }
+
+ /**
+ * Set the defaultContentKeyPolicyName property: Default ContentKey used by current Streaming Policy.
+ *
+ * @param defaultContentKeyPolicyName the defaultContentKeyPolicyName value to set.
+ * @return the StreamingPolicyProperties object itself.
+ */
+ public StreamingPolicyProperties withDefaultContentKeyPolicyName(String defaultContentKeyPolicyName) {
+ this.defaultContentKeyPolicyName = defaultContentKeyPolicyName;
+ return this;
+ }
+
+ /**
+ * Get the envelopeEncryption property: Configuration of EnvelopeEncryption.
+ *
+ * @return the envelopeEncryption value.
+ */
+ public EnvelopeEncryption envelopeEncryption() {
+ return this.envelopeEncryption;
+ }
+
+ /**
+ * Set the envelopeEncryption property: Configuration of EnvelopeEncryption.
+ *
+ * @param envelopeEncryption the envelopeEncryption value to set.
+ * @return the StreamingPolicyProperties object itself.
+ */
+ public StreamingPolicyProperties withEnvelopeEncryption(EnvelopeEncryption envelopeEncryption) {
+ this.envelopeEncryption = envelopeEncryption;
+ return this;
+ }
+
+ /**
+ * Get the commonEncryptionCenc property: Configuration of CommonEncryptionCenc.
+ *
+ * @return the commonEncryptionCenc value.
+ */
+ public CommonEncryptionCenc commonEncryptionCenc() {
+ return this.commonEncryptionCenc;
+ }
+
+ /**
+ * Set the commonEncryptionCenc property: Configuration of CommonEncryptionCenc.
+ *
+ * @param commonEncryptionCenc the commonEncryptionCenc value to set.
+ * @return the StreamingPolicyProperties object itself.
+ */
+ public StreamingPolicyProperties withCommonEncryptionCenc(CommonEncryptionCenc commonEncryptionCenc) {
+ this.commonEncryptionCenc = commonEncryptionCenc;
+ return this;
+ }
+
+ /**
+ * Get the commonEncryptionCbcs property: Configuration of CommonEncryptionCbcs.
+ *
+ * @return the commonEncryptionCbcs value.
+ */
+ public CommonEncryptionCbcs commonEncryptionCbcs() {
+ return this.commonEncryptionCbcs;
+ }
+
+ /**
+ * Set the commonEncryptionCbcs property: Configuration of CommonEncryptionCbcs.
+ *
+ * @param commonEncryptionCbcs the commonEncryptionCbcs value to set.
+ * @return the StreamingPolicyProperties object itself.
+ */
+ public StreamingPolicyProperties withCommonEncryptionCbcs(CommonEncryptionCbcs commonEncryptionCbcs) {
+ this.commonEncryptionCbcs = commonEncryptionCbcs;
+ return this;
+ }
+
+ /**
+ * Get the noEncryption property: Configurations of NoEncryption.
+ *
+ * @return the noEncryption value.
+ */
+ public NoEncryption noEncryption() {
+ return this.noEncryption;
+ }
+
+ /**
+ * Set the noEncryption property: Configurations of NoEncryption.
+ *
+ * @param noEncryption the noEncryption value to set.
+ * @return the StreamingPolicyProperties object itself.
+ */
+ public StreamingPolicyProperties withNoEncryption(NoEncryption noEncryption) {
+ this.noEncryption = noEncryption;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (envelopeEncryption() != null) {
+ envelopeEncryption().validate();
+ }
+ if (commonEncryptionCenc() != null) {
+ commonEncryptionCenc().validate();
+ }
+ if (commonEncryptionCbcs() != null) {
+ commonEncryptionCbcs().validate();
+ }
+ if (noEncryption() != null) {
+ noEncryption().validate();
+ }
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/TransformInner.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/TransformInner.java
index bcbc457b633f..43b491291c20 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/TransformInner.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/TransformInner.java
@@ -5,7 +5,6 @@
package com.azure.resourcemanager.mediaservices.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
@@ -20,43 +19,30 @@
* transcoding or by extracting insights. After the Transform is created, it can be applied to input media by creating
* Jobs.
*/
-@JsonFlatten
@Fluent
-public class TransformInner extends ProxyResource {
+public final class TransformInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(TransformInner.class);
/*
- * The system metadata relating to this resource.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /*
- * The UTC date and time when the Transform was created, in
- * 'YYYY-MM-DDThh:mm:ssZ' format.
- */
- @JsonProperty(value = "properties.created", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime created;
-
- /*
- * An optional verbose description of the Transform.
+ * The resource properties.
*/
- @JsonProperty(value = "properties.description")
- private String description;
+ @JsonProperty(value = "properties")
+ private TransformProperties innerProperties;
/*
- * The UTC date and time when the Transform was last updated, in
- * 'YYYY-MM-DDThh:mm:ssZ' format.
+ * The system metadata relating to this resource.
*/
- @JsonProperty(value = "properties.lastModified", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime lastModified;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData systemData;
- /*
- * An array of one or more TransformOutputs that the Transform should
- * generate.
+ /**
+ * Get the innerProperties property: The resource properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "properties.outputs")
- private List outputs;
+ private TransformProperties innerProperties() {
+ return this.innerProperties;
+ }
/**
* Get the systemData property: The system metadata relating to this resource.
@@ -73,7 +59,7 @@ public SystemData systemData() {
* @return the created value.
*/
public OffsetDateTime created() {
- return this.created;
+ return this.innerProperties() == null ? null : this.innerProperties().created();
}
/**
@@ -82,7 +68,7 @@ public OffsetDateTime created() {
* @return the description value.
*/
public String description() {
- return this.description;
+ return this.innerProperties() == null ? null : this.innerProperties().description();
}
/**
@@ -92,7 +78,10 @@ public String description() {
* @return the TransformInner object itself.
*/
public TransformInner withDescription(String description) {
- this.description = description;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new TransformProperties();
+ }
+ this.innerProperties().withDescription(description);
return this;
}
@@ -103,7 +92,7 @@ public TransformInner withDescription(String description) {
* @return the lastModified value.
*/
public OffsetDateTime lastModified() {
- return this.lastModified;
+ return this.innerProperties() == null ? null : this.innerProperties().lastModified();
}
/**
@@ -112,7 +101,7 @@ public OffsetDateTime lastModified() {
* @return the outputs value.
*/
public List outputs() {
- return this.outputs;
+ return this.innerProperties() == null ? null : this.innerProperties().outputs();
}
/**
@@ -122,7 +111,10 @@ public List outputs() {
* @return the TransformInner object itself.
*/
public TransformInner withOutputs(List outputs) {
- this.outputs = outputs;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new TransformProperties();
+ }
+ this.innerProperties().withOutputs(outputs);
return this;
}
@@ -132,8 +124,8 @@ public TransformInner withOutputs(List outputs) {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (outputs() != null) {
- outputs().forEach(e -> e.validate());
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/TransformProperties.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/TransformProperties.java
new file mode 100644
index 000000000000..15247fa05e29
--- /dev/null
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/fluent/models/TransformProperties.java
@@ -0,0 +1,120 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.mediaservices.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.mediaservices.models.TransformOutput;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+import java.util.List;
+
+/** A Transform. */
+@Fluent
+public final class TransformProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(TransformProperties.class);
+
+ /*
+ * The UTC date and time when the Transform was created, in
+ * 'YYYY-MM-DDThh:mm:ssZ' format.
+ */
+ @JsonProperty(value = "created", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime created;
+
+ /*
+ * An optional verbose description of the Transform.
+ */
+ @JsonProperty(value = "description")
+ private String description;
+
+ /*
+ * The UTC date and time when the Transform was last updated, in
+ * 'YYYY-MM-DDThh:mm:ssZ' format.
+ */
+ @JsonProperty(value = "lastModified", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime lastModified;
+
+ /*
+ * An array of one or more TransformOutputs that the Transform should
+ * generate.
+ */
+ @JsonProperty(value = "outputs", required = true)
+ private List outputs;
+
+ /**
+ * Get the created property: The UTC date and time when the Transform was created, in 'YYYY-MM-DDThh:mm:ssZ' format.
+ *
+ * @return the created value.
+ */
+ public OffsetDateTime created() {
+ return this.created;
+ }
+
+ /**
+ * Get the description property: An optional verbose description of the Transform.
+ *
+ * @return the description value.
+ */
+ public String description() {
+ return this.description;
+ }
+
+ /**
+ * Set the description property: An optional verbose description of the Transform.
+ *
+ * @param description the description value to set.
+ * @return the TransformProperties object itself.
+ */
+ public TransformProperties withDescription(String description) {
+ this.description = description;
+ return this;
+ }
+
+ /**
+ * Get the lastModified property: The UTC date and time when the Transform was last updated, in
+ * 'YYYY-MM-DDThh:mm:ssZ' format.
+ *
+ * @return the lastModified value.
+ */
+ public OffsetDateTime lastModified() {
+ return this.lastModified;
+ }
+
+ /**
+ * Get the outputs property: An array of one or more TransformOutputs that the Transform should generate.
+ *
+ * @return the outputs value.
+ */
+ public List outputs() {
+ return this.outputs;
+ }
+
+ /**
+ * Set the outputs property: An array of one or more TransformOutputs that the Transform should generate.
+ *
+ * @param outputs the outputs value to set.
+ * @return the TransformProperties object itself.
+ */
+ public TransformProperties withOutputs(List outputs) {
+ this.outputs = outputs;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (outputs() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException("Missing required property outputs in model TransformProperties"));
+ } else {
+ outputs().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/implementation/LiveEventsClientImpl.java b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/implementation/LiveEventsClientImpl.java
index 8182f925da39..bf7fb19acde6 100644
--- a/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/implementation/LiveEventsClientImpl.java
+++ b/sdk/mediaservices/azure-resourcemanager-mediaservices/src/main/java/com/azure/resourcemanager/mediaservices/implementation/LiveEventsClientImpl.java
@@ -236,7 +236,7 @@ Mono> listNext(
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the LiveEvent list result.
+ * @return liveEventListResult.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono> listSinglePageAsync(String resourceGroupName, String accountName) {
@@ -293,7 +293,7 @@ private Mono> listSinglePageAsync(String resourceG
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the LiveEvent list result.
+ * @return liveEventListResult.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono> listSinglePageAsync(
@@ -347,7 +347,7 @@ private Mono> listSinglePageAsync(
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the LiveEvent list result.
+ * @return liveEventListResult.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
private PagedFlux listAsync(String resourceGroupName, String accountName) {
@@ -364,7 +364,7 @@ private PagedFlux listAsync(String resourceGroupName, String acc
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the LiveEvent list result.
+ * @return liveEventListResult.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
private PagedFlux listAsync(String resourceGroupName, String accountName, Context context) {
@@ -381,7 +381,7 @@ private PagedFlux listAsync(String resourceGroupName, String acc
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the LiveEvent list result.
+ * @return liveEventListResult.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
public PagedIterable list(String resourceGroupName, String accountName) {
@@ -397,7 +397,7 @@ public PagedIterable list(String resourceGroupName, String accou
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the LiveEvent list result.
+ * @return liveEventListResult.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
public PagedIterable list(String resourceGroupName, String accountName, Context context) {
@@ -710,7 +710,7 @@ private Mono>> createWithResponseAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
private PollerFlux, LiveEventInner> beginCreateAsync(
String resourceGroupName,
String accountName,
@@ -739,7 +739,7 @@ private PollerFlux, LiveEventInner> beginCreateAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
private PollerFlux, LiveEventInner> beginCreateAsync(
String resourceGroupName,
String accountName,
@@ -769,7 +769,7 @@ private PollerFlux, LiveEventInner> beginCreateAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, LiveEventInner> beginCreate(
String resourceGroupName,
String accountName,
@@ -793,7 +793,7 @@ public SyncPoller, LiveEventInner> beginCreate(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, LiveEventInner> beginCreate(
String resourceGroupName,
String accountName,
@@ -1079,7 +1079,7 @@ private Mono>> updateWithResponseAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
private PollerFlux, LiveEventInner> beginUpdateAsync(
String resourceGroupName, String accountName, String liveEventName, LiveEventInner parameters) {
Mono>> mono =
@@ -1103,7 +1103,7 @@ private PollerFlux, LiveEventInner> beginUpdateAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
private PollerFlux, LiveEventInner> beginUpdateAsync(
String resourceGroupName,
String accountName,
@@ -1131,7 +1131,7 @@ private PollerFlux, LiveEventInner> beginUpdateAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, LiveEventInner> beginUpdate(
String resourceGroupName, String accountName, String liveEventName, LiveEventInner parameters) {
return beginUpdateAsync(resourceGroupName, accountName, liveEventName, parameters).getSyncPoller();
@@ -1150,7 +1150,7 @@ public SyncPoller, LiveEventInner> beginUpdate(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the live event.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, LiveEventInner> beginUpdate(
String resourceGroupName,
String accountName,
@@ -1361,7 +1361,7 @@ private Mono>> deleteWithResponseAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
private PollerFlux, Void> beginDeleteAsync(
String resourceGroupName, String accountName, String liveEventName) {
Mono>> mono = deleteWithResponseAsync(resourceGroupName, accountName, liveEventName);
@@ -1382,7 +1382,7 @@ private PollerFlux, Void> beginDeleteAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
private PollerFlux, Void> beginDeleteAsync(
String resourceGroupName, String accountName, String liveEventName, Context context) {
context = this.client.mergeContext(context);
@@ -1404,7 +1404,7 @@ private PollerFlux, Void> beginDeleteAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, Void> beginDelete(
String resourceGroupName, String accountName, String liveEventName) {
return beginDeleteAsync(resourceGroupName, accountName, liveEventName).getSyncPoller();
@@ -1422,7 +1422,7 @@ public SyncPoller, Void> beginDelete(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, Void> beginDelete(
String resourceGroupName, String accountName, String liveEventName, Context context) {
return beginDeleteAsync(resourceGroupName, accountName, liveEventName, context).getSyncPoller();
@@ -1612,7 +1612,7 @@ private Mono>> allocateWithResponseAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
private PollerFlux, Void> beginAllocateAsync(
String resourceGroupName, String accountName, String liveEventName) {
Mono>> mono =
@@ -1634,7 +1634,7 @@ private PollerFlux, Void> beginAllocateAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
private PollerFlux, Void> beginAllocateAsync(
String resourceGroupName, String accountName, String liveEventName, Context context) {
context = this.client.mergeContext(context);
@@ -1656,7 +1656,7 @@ private PollerFlux, Void> beginAllocateAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, Void> beginAllocate(
String resourceGroupName, String accountName, String liveEventName) {
return beginAllocateAsync(resourceGroupName, accountName, liveEventName).getSyncPoller();
@@ -1674,7 +1674,7 @@ public SyncPoller, Void> beginAllocate(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, Void> beginAllocate(
String resourceGroupName, String accountName, String liveEventName, Context context) {
return beginAllocateAsync(resourceGroupName, accountName, liveEventName, context).getSyncPoller();
@@ -1864,7 +1864,7 @@ private Mono>> startWithResponseAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
private PollerFlux, Void> beginStartAsync(
String resourceGroupName, String accountName, String liveEventName) {
Mono>> mono = startWithResponseAsync(resourceGroupName, accountName, liveEventName);
@@ -1885,7 +1885,7 @@ private PollerFlux, Void> beginStartAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
private PollerFlux, Void> beginStartAsync(
String resourceGroupName, String accountName, String liveEventName, Context context) {
context = this.client.mergeContext(context);
@@ -1907,7 +1907,7 @@ private PollerFlux, Void> beginStartAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, Void> beginStart(
String resourceGroupName, String accountName, String liveEventName) {
return beginStartAsync(resourceGroupName, accountName, liveEventName).getSyncPoller();
@@ -1925,7 +1925,7 @@ public SyncPoller, Void> beginStart(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, Void> beginStart(
String resourceGroupName, String accountName, String liveEventName, Context context) {
return beginStartAsync(resourceGroupName, accountName, liveEventName, context).getSyncPoller();
@@ -2133,7 +2133,7 @@ private Mono>> stopWithResponseAsync(
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the completion.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
private PollerFlux, Void> beginStopAsync(
String resourceGroupName, String accountName, String liveEventName, LiveEventActionInput parameters) {
Mono>> mono =
@@ -2156,7 +2156,7 @@ private PollerFlux