, IotHubDescriptionInner> beginCrea
String ifMatch,
Context context);
- /**
- * Create or update the metadata of an IoT hub.
- *
- * Create or update the metadata of an Iot hub. The usual pattern to modify a property is to retrieve the IoT hub
- * metadata and security metadata, and then combine them with the modified values in a new body to update the IoT
- * hub.
- *
- * @param resourceGroupName The name of the resource group that contains the IoT hub.
- * @param resourceName The name of the IoT hub.
- * @param iotHubDescription The IoT hub metadata and security metadata.
- * @param ifMatch ETag of the IoT Hub. Do not specify for creating a brand new IoT Hub. Required to update an
- * existing IoT Hub.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
- * server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the description of the IoT hub.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- IotHubDescriptionInner createOrUpdate(
- String resourceGroupName, String resourceName, IotHubDescriptionInner iotHubDescription, String ifMatch);
-
/**
* Create or update the metadata of an IoT hub.
*
@@ -387,14 +363,16 @@ SyncPoller, IotHubDescriptionInner> beginDele
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the statistics from an IoT hub.
+ * @return the statistics from an IoT hub along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- RegistryStatisticsInner getStats(String resourceGroupName, String resourceName);
+ Response getStatsWithResponse(
+ String resourceGroupName, String resourceName, Context context);
/**
* Get the statistics from an IoT hub
@@ -403,16 +381,14 @@ SyncPoller, IotHubDescriptionInner> beginDele
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the statistics from an IoT hub along with {@link Response}.
+ * @return the statistics from an IoT hub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response getStatsWithResponse(
- String resourceGroupName, String resourceName, Context context);
+ RegistryStatisticsInner getStats(String resourceGroupName, String resourceName);
/**
* Get the list of valid SKUs for an IoT hub
@@ -496,15 +472,17 @@ PagedIterable listEventHubConsumerGroups(
* @param resourceName The name of the IoT hub.
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to retrieve.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub.
+ * @return a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub along with {@link
+ * Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- EventHubConsumerGroupInfoInner getEventHubConsumerGroup(
- String resourceGroupName, String resourceName, String eventHubEndpointName, String name);
+ Response getEventHubConsumerGroupWithResponse(
+ String resourceGroupName, String resourceName, String eventHubEndpointName, String name, Context context);
/**
* Get a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub
@@ -515,17 +493,15 @@ EventHubConsumerGroupInfoInner getEventHubConsumerGroup(
* @param resourceName The name of the IoT hub.
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to retrieve.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub along with {@link
- * Response}.
+ * @return a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response getEventHubConsumerGroupWithResponse(
- String resourceGroupName, String resourceName, String eventHubEndpointName, String name, Context context);
+ EventHubConsumerGroupInfoInner getEventHubConsumerGroup(
+ String resourceGroupName, String resourceName, String eventHubEndpointName, String name);
/**
* Add a consumer group to an Event Hub-compatible endpoint in an IoT hub
@@ -537,19 +513,21 @@ Response getEventHubConsumerGroupWithResponse(
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to add.
* @param consumerGroupBody The consumer group to add.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the EventHubConsumerGroupInfo object.
+ * @return the properties of the EventHubConsumerGroupInfo object along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- EventHubConsumerGroupInfoInner createEventHubConsumerGroup(
+ Response createEventHubConsumerGroupWithResponse(
String resourceGroupName,
String resourceName,
String eventHubEndpointName,
String name,
- EventHubConsumerGroupBodyDescription consumerGroupBody);
+ EventHubConsumerGroupBodyDescription consumerGroupBody,
+ Context context);
/**
* Add a consumer group to an Event Hub-compatible endpoint in an IoT hub
@@ -561,21 +539,19 @@ EventHubConsumerGroupInfoInner createEventHubConsumerGroup(
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to add.
* @param consumerGroupBody The consumer group to add.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the EventHubConsumerGroupInfo object along with {@link Response}.
+ * @return the properties of the EventHubConsumerGroupInfo object.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response createEventHubConsumerGroupWithResponse(
+ EventHubConsumerGroupInfoInner createEventHubConsumerGroup(
String resourceGroupName,
String resourceName,
String eventHubEndpointName,
String name,
- EventHubConsumerGroupBodyDescription consumerGroupBody,
- Context context);
+ EventHubConsumerGroupBodyDescription consumerGroupBody);
/**
* Delete a consumer group from an Event Hub-compatible endpoint in an IoT hub
@@ -586,14 +562,16 @@ Response createEventHubConsumerGroupWithResponse
* @param resourceName The name of the IoT hub.
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to delete.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- void deleteEventHubConsumerGroup(
- String resourceGroupName, String resourceName, String eventHubEndpointName, String name);
+ Response deleteEventHubConsumerGroupWithResponse(
+ String resourceGroupName, String resourceName, String eventHubEndpointName, String name, Context context);
/**
* Delete a consumer group from an Event Hub-compatible endpoint in an IoT hub
@@ -604,16 +582,14 @@ void deleteEventHubConsumerGroup(
* @param resourceName The name of the IoT hub.
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to delete.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response deleteEventHubConsumerGroupWithResponse(
- String resourceGroupName, String resourceName, String eventHubEndpointName, String name, Context context);
+ void deleteEventHubConsumerGroup(
+ String resourceGroupName, String resourceName, String eventHubEndpointName, String name);
/**
* Get a list of all the jobs in an IoT hub. For more information, see:
@@ -662,14 +638,16 @@ Response deleteEventHubConsumerGroupWithResponse(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param jobId The job identifier.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the details of a job from an IoT hub.
+ * @return the details of a job from an IoT hub along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- JobResponseInner getJob(String resourceGroupName, String resourceName, String jobId);
+ Response getJobWithResponse(
+ String resourceGroupName, String resourceName, String jobId, Context context);
/**
* Get the details of a job from an IoT hub. For more information, see:
@@ -681,16 +659,14 @@ Response deleteEventHubConsumerGroupWithResponse(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param jobId The job identifier.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the details of a job from an IoT hub along with {@link Response}.
+ * @return the details of a job from an IoT hub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response getJobWithResponse(
- String resourceGroupName, String resourceName, String jobId, Context context);
+ JobResponseInner getJob(String resourceGroupName, String resourceName, String jobId);
/**
* Get the quota metrics for an IoT hub
@@ -767,14 +743,16 @@ PagedIterable getEndpointHealth(
*
* @param operationInputs Set the name parameter in the OperationInputs structure to the name of the IoT hub to
* check.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties indicating whether a given IoT hub name is available.
+ * @return the properties indicating whether a given IoT hub name is available along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- IotHubNameAvailabilityInfoInner checkNameAvailability(OperationInputs operationInputs);
+ Response checkNameAvailabilityWithResponse(
+ OperationInputs operationInputs, Context context);
/**
* Check if an IoT hub name is available
@@ -783,16 +761,14 @@ PagedIterable getEndpointHealth(
*
* @param operationInputs Set the name parameter in the OperationInputs structure to the name of the IoT hub to
* check.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties indicating whether a given IoT hub name is available along with {@link Response}.
+ * @return the properties indicating whether a given IoT hub name is available.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response checkNameAvailabilityWithResponse(
- OperationInputs operationInputs, Context context);
+ IotHubNameAvailabilityInfoInner checkNameAvailability(OperationInputs operationInputs);
/**
* Test all routes
@@ -802,14 +778,16 @@ Response checkNameAvailabilityWithResponse(
* @param iotHubName IotHub to be tested.
* @param resourceGroupName resource group which Iot Hub belongs to.
* @param input Input for testing all routes.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return result of testing all routes.
+ * @return result of testing all routes along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- TestAllRoutesResultInner testAllRoutes(String iotHubName, String resourceGroupName, TestAllRoutesInput input);
+ Response testAllRoutesWithResponse(
+ String iotHubName, String resourceGroupName, TestAllRoutesInput input, Context context);
/**
* Test all routes
@@ -819,16 +797,14 @@ Response checkNameAvailabilityWithResponse(
* @param iotHubName IotHub to be tested.
* @param resourceGroupName resource group which Iot Hub belongs to.
* @param input Input for testing all routes.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return result of testing all routes along with {@link Response}.
+ * @return result of testing all routes.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response testAllRoutesWithResponse(
- String iotHubName, String resourceGroupName, TestAllRoutesInput input, Context context);
+ TestAllRoutesResultInner testAllRoutes(String iotHubName, String resourceGroupName, TestAllRoutesInput input);
/**
* Test the new route
@@ -838,14 +814,16 @@ Response testAllRoutesWithResponse(
* @param iotHubName IotHub to be tested.
* @param resourceGroupName resource group which Iot Hub belongs to.
* @param input Route that needs to be tested.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return result of testing one route.
+ * @return result of testing one route along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- TestRouteResultInner testRoute(String iotHubName, String resourceGroupName, TestRouteInput input);
+ Response testRouteWithResponse(
+ String iotHubName, String resourceGroupName, TestRouteInput input, Context context);
/**
* Test the new route
@@ -855,16 +833,14 @@ Response testAllRoutesWithResponse(
* @param iotHubName IotHub to be tested.
* @param resourceGroupName resource group which Iot Hub belongs to.
* @param input Route that needs to be tested.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return result of testing one route along with {@link Response}.
+ * @return result of testing one route.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response testRouteWithResponse(
- String iotHubName, String resourceGroupName, TestRouteInput input, Context context);
+ TestRouteResultInner testRoute(String iotHubName, String resourceGroupName, TestRouteInput input);
/**
* Get the security metadata for an IoT hub. For more information, see:
@@ -914,15 +890,16 @@ PagedIterable listKeys(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param keyName The name of the shared access policy.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a shared access policy by name from an IoT hub.
+ * @return a shared access policy by name from an IoT hub along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- SharedAccessSignatureAuthorizationRuleInner getKeysForKeyName(
- String resourceGroupName, String resourceName, String keyName);
+ Response getKeysForKeyNameWithResponse(
+ String resourceGroupName, String resourceName, String keyName, Context context);
/**
* Get a shared access policy by name from an IoT hub. For more information, see:
@@ -934,16 +911,15 @@ SharedAccessSignatureAuthorizationRuleInner getKeysForKeyName(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param keyName The name of the shared access policy.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a shared access policy by name from an IoT hub along with {@link Response}.
+ * @return a shared access policy by name from an IoT hub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response getKeysForKeyNameWithResponse(
- String resourceGroupName, String resourceName, String keyName, Context context);
+ SharedAccessSignatureAuthorizationRuleInner getKeysForKeyName(
+ String resourceGroupName, String resourceName, String keyName);
/**
* Exports all the device identities in the IoT hub identity registry to an Azure Storage blob container. For more
@@ -957,15 +933,16 @@ Response getKeysForKeyNameWithRespo
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param exportDevicesParameters The parameters that specify the export devices operation.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the Job Response object.
+ * @return the properties of the Job Response object along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- JobResponseInner exportDevices(
- String resourceGroupName, String resourceName, ExportDevicesRequest exportDevicesParameters);
+ Response exportDevicesWithResponse(
+ String resourceGroupName, String resourceName, ExportDevicesRequest exportDevicesParameters, Context context);
/**
* Exports all the device identities in the IoT hub identity registry to an Azure Storage blob container. For more
@@ -979,16 +956,15 @@ JobResponseInner exportDevices(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param exportDevicesParameters The parameters that specify the export devices operation.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the Job Response object along with {@link Response}.
+ * @return the properties of the Job Response object.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response exportDevicesWithResponse(
- String resourceGroupName, String resourceName, ExportDevicesRequest exportDevicesParameters, Context context);
+ JobResponseInner exportDevices(
+ String resourceGroupName, String resourceName, ExportDevicesRequest exportDevicesParameters);
/**
* Import, update, or delete device identities in the IoT hub identity registry from a blob. For more information,
@@ -1002,15 +978,16 @@ Response exportDevicesWithResponse(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param importDevicesParameters The parameters that specify the import devices operation.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the Job Response object.
+ * @return the properties of the Job Response object along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- JobResponseInner importDevices(
- String resourceGroupName, String resourceName, ImportDevicesRequest importDevicesParameters);
+ Response importDevicesWithResponse(
+ String resourceGroupName, String resourceName, ImportDevicesRequest importDevicesParameters, Context context);
/**
* Import, update, or delete device identities in the IoT hub identity registry from a blob. For more information,
@@ -1024,14 +1001,13 @@ JobResponseInner importDevices(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param importDevicesParameters The parameters that specify the import devices operation.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the Job Response object along with {@link Response}.
+ * @return the properties of the Job Response object.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response importDevicesWithResponse(
- String resourceGroupName, String resourceName, ImportDevicesRequest importDevicesParameters, Context context);
+ JobResponseInner importDevices(
+ String resourceGroupName, String resourceName, ImportDevicesRequest importDevicesParameters);
}
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/PrivateEndpointConnectionsClient.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/PrivateEndpointConnectionsClient.java
index 6a701e6f94e2..41246583c47a 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/PrivateEndpointConnectionsClient.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/PrivateEndpointConnectionsClient.java
@@ -22,14 +22,16 @@ public interface PrivateEndpointConnectionsClient {
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the list of private endpoint connections for an IotHub.
+ * @return the list of private endpoint connections for an IotHub along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- List list(String resourceGroupName, String resourceName);
+ Response> listWithResponse(
+ String resourceGroupName, String resourceName, Context context);
/**
* List private endpoint connections
@@ -38,16 +40,14 @@ public interface PrivateEndpointConnectionsClient {
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the list of private endpoint connections for an IotHub along with {@link Response}.
+ * @return the list of private endpoint connections for an IotHub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response> listWithResponse(
- String resourceGroupName, String resourceName, Context context);
+ List list(String resourceGroupName, String resourceName);
/**
* Get private endpoint connection
@@ -57,15 +57,16 @@ Response> listWithResponse(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param privateEndpointConnectionName The name of the private endpoint connection.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return private endpoint connection properties.
+ * @return private endpoint connection properties along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- PrivateEndpointConnectionInner get(
- String resourceGroupName, String resourceName, String privateEndpointConnectionName);
+ Response getWithResponse(
+ String resourceGroupName, String resourceName, String privateEndpointConnectionName, Context context);
/**
* Get private endpoint connection
@@ -75,16 +76,15 @@ PrivateEndpointConnectionInner get(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param privateEndpointConnectionName The name of the private endpoint connection.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return private endpoint connection properties along with {@link Response}.
+ * @return private endpoint connection properties.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(
- String resourceGroupName, String resourceName, String privateEndpointConnectionName, Context context);
+ PrivateEndpointConnectionInner get(
+ String resourceGroupName, String resourceName, String privateEndpointConnectionName);
/**
* Update private endpoint connection
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/PrivateLinkResourcesOperationsClient.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/PrivateLinkResourcesOperationsClient.java
index b6072ee9b95b..6cec15e84e68 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/PrivateLinkResourcesOperationsClient.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/PrivateLinkResourcesOperationsClient.java
@@ -20,14 +20,16 @@ public interface PrivateLinkResourcesOperationsClient {
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the available private link resources for an IotHub.
+ * @return the available private link resources for an IotHub along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- PrivateLinkResourcesInner list(String resourceGroupName, String resourceName);
+ Response listWithResponse(
+ String resourceGroupName, String resourceName, Context context);
/**
* List private link resources
@@ -36,16 +38,14 @@ public interface PrivateLinkResourcesOperationsClient {
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the available private link resources for an IotHub along with {@link Response}.
+ * @return the available private link resources for an IotHub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response listWithResponse(
- String resourceGroupName, String resourceName, Context context);
+ PrivateLinkResourcesInner list(String resourceGroupName, String resourceName);
/**
* Get the specified private link resource
@@ -55,14 +55,16 @@ Response listWithResponse(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param groupId The name of the private link resource.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the specified private link resource for the given IotHub.
+ * @return the specified private link resource for the given IotHub along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- GroupIdInformationInner get(String resourceGroupName, String resourceName, String groupId);
+ Response getWithResponse(
+ String resourceGroupName, String resourceName, String groupId, Context context);
/**
* Get the specified private link resource
@@ -72,14 +74,12 @@ Response listWithResponse(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param groupId The name of the private link resource.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the specified private link resource for the given IotHub along with {@link Response}.
+ * @return the specified private link resource for the given IotHub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(
- String resourceGroupName, String resourceName, String groupId, Context context);
+ GroupIdInformationInner get(String resourceGroupName, String resourceName, String groupId);
}
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/ResourceProviderCommonsClient.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/ResourceProviderCommonsClient.java
index bce652fdbcee..cf2cfc785d90 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/ResourceProviderCommonsClient.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/ResourceProviderCommonsClient.java
@@ -17,26 +17,26 @@ public interface ResourceProviderCommonsClient {
*
* Get the number of free and paid iot hubs in the subscription.
*
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the number of free and paid iot hubs in the subscription.
+ * @return the number of free and paid iot hubs in the subscription along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- UserSubscriptionQuotaListResultInner getSubscriptionQuota();
+ Response getSubscriptionQuotaWithResponse(Context context);
/**
* Get the number of iot hubs in the subscription
*
* Get the number of free and paid iot hubs in the subscription.
*
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.resourcemanager.iothub.models.ErrorDetailsException thrown if the request is rejected by
* server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the number of free and paid iot hubs in the subscription along with {@link Response}.
+ * @return the number of free and paid iot hubs in the subscription.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response getSubscriptionQuotaWithResponse(Context context);
+ UserSubscriptionQuotaListResultInner getSubscriptionQuota();
}
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateDescriptionInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateDescriptionInner.java
index 9a279107e23d..5029f8127414 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateDescriptionInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateDescriptionInner.java
@@ -24,6 +24,10 @@ public final class CertificateDescriptionInner extends ProxyResource {
@JsonProperty(value = "etag", access = JsonProperty.Access.WRITE_ONLY)
private String etag;
+ /** Creates an instance of CertificateDescriptionInner class. */
+ public CertificateDescriptionInner() {
+ }
+
/**
* Get the properties property: The description of an X509 CA Certificate.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateListDescriptionInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateListDescriptionInner.java
index 224446fc9059..38978a03b38b 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateListDescriptionInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateListDescriptionInner.java
@@ -17,6 +17,10 @@ public final class CertificateListDescriptionInner {
@JsonProperty(value = "value")
private List value;
+ /** Creates an instance of CertificateListDescriptionInner class. */
+ public CertificateListDescriptionInner() {
+ }
+
/**
* Get the value property: The array of Certificate objects.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateWithNonceDescriptionInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateWithNonceDescriptionInner.java
index f4660a738d8d..6bd0db9900ef 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateWithNonceDescriptionInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/CertificateWithNonceDescriptionInner.java
@@ -24,6 +24,10 @@ public final class CertificateWithNonceDescriptionInner extends ProxyResource {
@JsonProperty(value = "etag", access = JsonProperty.Access.WRITE_ONLY)
private String etag;
+ /** Creates an instance of CertificateWithNonceDescriptionInner class. */
+ public CertificateWithNonceDescriptionInner() {
+ }
+
/**
* Get the properties property: The description of an X509 CA Certificate including the challenge nonce issued for
* the Proof-Of-Possession flow.
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/EndpointHealthDataInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/EndpointHealthDataInner.java
index b019ff304074..8670be2531c6 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/EndpointHealthDataInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/EndpointHealthDataInner.java
@@ -55,6 +55,10 @@ public final class EndpointHealthDataInner {
@JsonProperty(value = "lastSendAttemptTime")
private DateTimeRfc1123 lastSendAttemptTime;
+ /** Creates an instance of EndpointHealthDataInner class. */
+ public EndpointHealthDataInner() {
+ }
+
/**
* Get the endpointId property: Id of the endpoint.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/EventHubConsumerGroupInfoInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/EventHubConsumerGroupInfoInner.java
index 3f31cc5a8b65..dfe6c896c944 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/EventHubConsumerGroupInfoInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/EventHubConsumerGroupInfoInner.java
@@ -26,6 +26,10 @@ public final class EventHubConsumerGroupInfoInner extends ProxyResource {
@JsonProperty(value = "etag", access = JsonProperty.Access.WRITE_ONLY)
private String etag;
+ /** Creates an instance of EventHubConsumerGroupInfoInner class. */
+ public EventHubConsumerGroupInfoInner() {
+ }
+
/**
* Get the properties property: The tags.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/GroupIdInformationInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/GroupIdInformationInner.java
index 9b709713887e..f65727faa6c2 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/GroupIdInformationInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/GroupIdInformationInner.java
@@ -36,6 +36,10 @@ public final class GroupIdInformationInner {
@JsonProperty(value = "properties", required = true)
private GroupIdInformationProperties properties;
+ /** Creates an instance of GroupIdInformationInner class. */
+ public GroupIdInformationInner() {
+ }
+
/**
* Get the id property: The resource identifier.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubDescriptionInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubDescriptionInner.java
index 0aa1cf7d3ba5..3903fcd46fae 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubDescriptionInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubDescriptionInner.java
@@ -48,6 +48,10 @@ public final class IotHubDescriptionInner extends Resource {
@JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
private SystemData systemData;
+ /** Creates an instance of IotHubDescriptionInner class. */
+ public IotHubDescriptionInner() {
+ }
+
/**
* Get the etag property: The Etag field is *not* required. If it is provided in the response body, it must also be
* provided as a header per the normal ETag convention.
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubNameAvailabilityInfoInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubNameAvailabilityInfoInner.java
index 220c14db378b..21ddc7a0d922 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubNameAvailabilityInfoInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubNameAvailabilityInfoInner.java
@@ -29,6 +29,10 @@ public final class IotHubNameAvailabilityInfoInner {
@JsonProperty(value = "message")
private String message;
+ /** Creates an instance of IotHubNameAvailabilityInfoInner class. */
+ public IotHubNameAvailabilityInfoInner() {
+ }
+
/**
* Get the nameAvailable property: The value which indicates whether the provided name is available.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubQuotaMetricInfoInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubQuotaMetricInfoInner.java
index 84c9b471bbac..75d6ec425d34 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubQuotaMetricInfoInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubQuotaMetricInfoInner.java
@@ -28,6 +28,10 @@ public final class IotHubQuotaMetricInfoInner {
@JsonProperty(value = "maxValue", access = JsonProperty.Access.WRITE_ONLY)
private Long maxValue;
+ /** Creates an instance of IotHubQuotaMetricInfoInner class. */
+ public IotHubQuotaMetricInfoInner() {
+ }
+
/**
* Get the name property: The name of the quota metric.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubSkuDescriptionInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubSkuDescriptionInner.java
index a0d9c52024a1..d4a09d1c9d44 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubSkuDescriptionInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/IotHubSkuDescriptionInner.java
@@ -31,6 +31,10 @@ public final class IotHubSkuDescriptionInner {
@JsonProperty(value = "capacity", required = true)
private IotHubCapacity capacity;
+ /** Creates an instance of IotHubSkuDescriptionInner class. */
+ public IotHubSkuDescriptionInner() {
+ }
+
/**
* Get the resourceType property: The type of the resource.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/JobResponseInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/JobResponseInner.java
index 2f9c443287c7..b3ff56066725 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/JobResponseInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/JobResponseInner.java
@@ -62,6 +62,10 @@ public final class JobResponseInner {
@JsonProperty(value = "parentJobId", access = JsonProperty.Access.WRITE_ONLY)
private String parentJobId;
+ /** Creates an instance of JobResponseInner class. */
+ public JobResponseInner() {
+ }
+
/**
* Get the jobId property: The job identifier.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/OperationInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/OperationInner.java
index fe3c409f1305..cbcd098a8212 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/OperationInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/OperationInner.java
@@ -23,6 +23,10 @@ public final class OperationInner {
@JsonProperty(value = "display")
private OperationDisplay display;
+ /** Creates an instance of OperationInner class. */
+ public OperationInner() {
+ }
+
/**
* Get the name property: Operation name: {provider}/{resource}/{read | write | action | delete}.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/PrivateEndpointConnectionInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/PrivateEndpointConnectionInner.java
index 70ec1e4bb3fe..f547e63363a8 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/PrivateEndpointConnectionInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/PrivateEndpointConnectionInner.java
@@ -19,6 +19,10 @@ public final class PrivateEndpointConnectionInner extends ProxyResource {
@JsonProperty(value = "properties", required = true)
private PrivateEndpointConnectionProperties properties;
+ /** Creates an instance of PrivateEndpointConnectionInner class. */
+ public PrivateEndpointConnectionInner() {
+ }
+
/**
* Get the properties property: The properties of a private endpoint connection.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/PrivateLinkResourcesInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/PrivateLinkResourcesInner.java
index 6b642dedb9ef..bdf58e8fc5e2 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/PrivateLinkResourcesInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/PrivateLinkResourcesInner.java
@@ -17,6 +17,10 @@ public final class PrivateLinkResourcesInner {
@JsonProperty(value = "value")
private List value;
+ /** Creates an instance of PrivateLinkResourcesInner class. */
+ public PrivateLinkResourcesInner() {
+ }
+
/**
* Get the value property: The list of available private link resources for an IotHub.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/RegistryStatisticsInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/RegistryStatisticsInner.java
index 5188da0f6567..bb46abf9ca79 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/RegistryStatisticsInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/RegistryStatisticsInner.java
@@ -28,6 +28,10 @@ public final class RegistryStatisticsInner {
@JsonProperty(value = "disabledDeviceCount", access = JsonProperty.Access.WRITE_ONLY)
private Long disabledDeviceCount;
+ /** Creates an instance of RegistryStatisticsInner class. */
+ public RegistryStatisticsInner() {
+ }
+
/**
* Get the totalDeviceCount property: The total count of devices in the identity registry.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/SharedAccessSignatureAuthorizationRuleInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/SharedAccessSignatureAuthorizationRuleInner.java
index d7d38620b29f..82e956a3802c 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/SharedAccessSignatureAuthorizationRuleInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/SharedAccessSignatureAuthorizationRuleInner.java
@@ -36,6 +36,10 @@ public final class SharedAccessSignatureAuthorizationRuleInner {
@JsonProperty(value = "rights", required = true)
private AccessRights rights;
+ /** Creates an instance of SharedAccessSignatureAuthorizationRuleInner class. */
+ public SharedAccessSignatureAuthorizationRuleInner() {
+ }
+
/**
* Get the keyName property: The name of the shared access policy.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/TestAllRoutesResultInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/TestAllRoutesResultInner.java
index d89d3d46ca99..6daf3997c419 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/TestAllRoutesResultInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/TestAllRoutesResultInner.java
@@ -18,6 +18,10 @@ public final class TestAllRoutesResultInner {
@JsonProperty(value = "routes")
private List routes;
+ /** Creates an instance of TestAllRoutesResultInner class. */
+ public TestAllRoutesResultInner() {
+ }
+
/**
* Get the routes property: JSON-serialized array of matched routes.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/TestRouteResultInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/TestRouteResultInner.java
index bd47269a717d..eb142e816b21 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/TestRouteResultInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/TestRouteResultInner.java
@@ -24,6 +24,10 @@ public final class TestRouteResultInner {
@JsonProperty(value = "details")
private TestRouteResultDetails details;
+ /** Creates an instance of TestRouteResultInner class. */
+ public TestRouteResultInner() {
+ }
+
/**
* Get the result property: Result of testing route.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/UserSubscriptionQuotaListResultInner.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/UserSubscriptionQuotaListResultInner.java
index 4e64d127c9bd..c797bddb3768 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/UserSubscriptionQuotaListResultInner.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/fluent/models/UserSubscriptionQuotaListResultInner.java
@@ -24,6 +24,10 @@ public final class UserSubscriptionQuotaListResultInner {
@JsonProperty(value = "nextLink", access = JsonProperty.Access.WRITE_ONLY)
private String nextLink;
+ /** Creates an instance of UserSubscriptionQuotaListResultInner class. */
+ public UserSubscriptionQuotaListResultInner() {
+ }
+
/**
* Get the value property: The value property.
*
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/CertificatesClientImpl.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/CertificatesClientImpl.java
index d71cd21c22ae..958a850707e4 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/CertificatesClientImpl.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/CertificatesClientImpl.java
@@ -57,11 +57,10 @@ public final class CertificatesClientImpl implements CertificatesClient {
*/
@Host("{$host}")
@ServiceInterface(name = "IotHubClientCertific")
- private interface CertificatesService {
+ public interface CertificatesService {
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/certificates")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/certificates")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> listByIotHub(
@@ -75,8 +74,7 @@ Mono> listByIotHub(
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/certificates/{certificateName}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/certificates/{certificateName}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> get(
@@ -91,8 +89,7 @@ Mono> get(
@Headers({"Content-Type: application/json"})
@Put(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/certificates/{certificateName}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/certificates/{certificateName}")
@ExpectedResponses({200, 201})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> createOrUpdate(
@@ -109,8 +106,7 @@ Mono> createOrUpdate(
@Headers({"Content-Type: application/json"})
@Delete(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/certificates/{certificateName}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/certificates/{certificateName}")
@ExpectedResponses({200, 204})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> delete(
@@ -126,8 +122,7 @@ Mono> delete(
@Headers({"Content-Type: application/json"})
@Post(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/certificates/{certificateName}/generateVerificationCode")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/certificates/{certificateName}/generateVerificationCode")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> generateVerificationCode(
@@ -143,8 +138,7 @@ Mono> generateVerificationCode(
@Headers({"Content-Type: application/json"})
@Post(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/certificates/{certificateName}/verify")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/certificates/{certificateName}/verify")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> verify(
@@ -285,14 +279,16 @@ private Mono listByIotHubAsync(String resourceG
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the JSON-serialized array of Certificate objects.
+ * @return the JSON-serialized array of Certificate objects along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public CertificateListDescriptionInner listByIotHub(String resourceGroupName, String resourceName) {
- return listByIotHubAsync(resourceGroupName, resourceName).block();
+ public Response listByIotHubWithResponse(
+ String resourceGroupName, String resourceName, Context context) {
+ return listByIotHubWithResponseAsync(resourceGroupName, resourceName, context).block();
}
/**
@@ -302,16 +298,14 @@ public CertificateListDescriptionInner listByIotHub(String resourceGroupName, St
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the JSON-serialized array of Certificate objects along with {@link Response}.
+ * @return the JSON-serialized array of Certificate objects.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response listByIotHubWithResponse(
- String resourceGroupName, String resourceName, Context context) {
- return listByIotHubWithResponseAsync(resourceGroupName, resourceName, context).block();
+ public CertificateListDescriptionInner listByIotHub(String resourceGroupName, String resourceName) {
+ return listByIotHubWithResponse(resourceGroupName, resourceName, Context.NONE).getValue();
}
/**
@@ -452,14 +446,16 @@ private Mono getAsync(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param certificateName The name of the certificate.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the X509 Certificate.
+ * @return the X509 Certificate along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public CertificateDescriptionInner get(String resourceGroupName, String resourceName, String certificateName) {
- return getAsync(resourceGroupName, resourceName, certificateName).block();
+ public Response getWithResponse(
+ String resourceGroupName, String resourceName, String certificateName, Context context) {
+ return getWithResponseAsync(resourceGroupName, resourceName, certificateName, context).block();
}
/**
@@ -470,16 +466,14 @@ public CertificateDescriptionInner get(String resourceGroupName, String resource
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param certificateName The name of the certificate.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the X509 Certificate along with {@link Response}.
+ * @return the X509 Certificate.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response getWithResponse(
- String resourceGroupName, String resourceName, String certificateName, Context context) {
- return getWithResponseAsync(resourceGroupName, resourceName, certificateName, context).block();
+ public CertificateDescriptionInner get(String resourceGroupName, String resourceName, String certificateName) {
+ return getWithResponse(resourceGroupName, resourceName, certificateName, Context.NONE).getValue();
}
/**
@@ -634,8 +628,6 @@ private Mono> createOrUpdateWithResponseAs
* @param resourceName The name of the IoT hub.
* @param certificateName The name of the certificate.
* @param certificateDescription The certificate body.
- * @param ifMatch ETag of the Certificate. Do not specify for creating a brand new certificate. Required to update
- * an existing certificate.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
@@ -646,8 +638,8 @@ private Mono createOrUpdateAsync(
String resourceGroupName,
String resourceName,
String certificateName,
- CertificateDescriptionInner certificateDescription,
- String ifMatch) {
+ CertificateDescriptionInner certificateDescription) {
+ final String ifMatch = null;
return createOrUpdateWithResponseAsync(
resourceGroupName, resourceName, certificateName, certificateDescription, ifMatch)
.flatMap(res -> Mono.justOrEmpty(res.getValue()));
@@ -662,21 +654,25 @@ private Mono createOrUpdateAsync(
* @param resourceName The name of the IoT hub.
* @param certificateName The name of the certificate.
* @param certificateDescription The certificate body.
+ * @param ifMatch ETag of the Certificate. Do not specify for creating a brand new certificate. Required to update
+ * an existing certificate.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the X509 Certificate on successful completion of {@link Mono}.
+ * @return the X509 Certificate along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(
+ public Response createOrUpdateWithResponse(
String resourceGroupName,
String resourceName,
String certificateName,
- CertificateDescriptionInner certificateDescription) {
- final String ifMatch = null;
+ CertificateDescriptionInner certificateDescription,
+ String ifMatch,
+ Context context) {
return createOrUpdateWithResponseAsync(
- resourceGroupName, resourceName, certificateName, certificateDescription, ifMatch)
- .flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ resourceGroupName, resourceName, certificateName, certificateDescription, ifMatch, context)
+ .block();
}
/**
@@ -700,38 +696,9 @@ public CertificateDescriptionInner createOrUpdate(
String certificateName,
CertificateDescriptionInner certificateDescription) {
final String ifMatch = null;
- return createOrUpdateAsync(resourceGroupName, resourceName, certificateName, certificateDescription, ifMatch)
- .block();
- }
-
- /**
- * Upload the certificate to the IoT hub.
- *
- * Adds new or replaces existing certificate.
- *
- * @param resourceGroupName The name of the resource group that contains the IoT hub.
- * @param resourceName The name of the IoT hub.
- * @param certificateName The name of the certificate.
- * @param certificateDescription The certificate body.
- * @param ifMatch ETag of the Certificate. Do not specify for creating a brand new certificate. Required to update
- * an existing certificate.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ErrorDetailsException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the X509 Certificate along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response createOrUpdateWithResponse(
- String resourceGroupName,
- String resourceName,
- String certificateName,
- CertificateDescriptionInner certificateDescription,
- String ifMatch,
- Context context) {
- return createOrUpdateWithResponseAsync(
- resourceGroupName, resourceName, certificateName, certificateDescription, ifMatch, context)
- .block();
+ return createOrUpdateWithResponse(
+ resourceGroupName, resourceName, certificateName, certificateDescription, ifMatch, Context.NONE)
+ .getValue();
}
/**
@@ -884,13 +851,16 @@ private Mono deleteAsync(
* @param resourceName The name of the IoT hub.
* @param certificateName The name of the certificate.
* @param ifMatch ETag of the Certificate.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public void delete(String resourceGroupName, String resourceName, String certificateName, String ifMatch) {
- deleteAsync(resourceGroupName, resourceName, certificateName, ifMatch).block();
+ public Response deleteWithResponse(
+ String resourceGroupName, String resourceName, String certificateName, String ifMatch, Context context) {
+ return deleteWithResponseAsync(resourceGroupName, resourceName, certificateName, ifMatch, context).block();
}
/**
@@ -902,16 +872,13 @@ public void delete(String resourceGroupName, String resourceName, String certifi
* @param resourceName The name of the IoT hub.
* @param certificateName The name of the certificate.
* @param ifMatch ETag of the Certificate.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response deleteWithResponse(
- String resourceGroupName, String resourceName, String certificateName, String ifMatch, Context context) {
- return deleteWithResponseAsync(resourceGroupName, resourceName, certificateName, ifMatch, context).block();
+ public void delete(String resourceGroupName, String resourceName, String certificateName, String ifMatch) {
+ deleteWithResponse(resourceGroupName, resourceName, certificateName, ifMatch, Context.NONE);
}
/**
@@ -1068,15 +1035,18 @@ private Mono generateVerificationCodeAsync
* @param resourceName The name of the IoT hub.
* @param certificateName The name of the certificate.
* @param ifMatch ETag of the Certificate.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the X509 Certificate.
+ * @return the X509 Certificate along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public CertificateWithNonceDescriptionInner generateVerificationCode(
- String resourceGroupName, String resourceName, String certificateName, String ifMatch) {
- return generateVerificationCodeAsync(resourceGroupName, resourceName, certificateName, ifMatch).block();
+ public Response generateVerificationCodeWithResponse(
+ String resourceGroupName, String resourceName, String certificateName, String ifMatch, Context context) {
+ return generateVerificationCodeWithResponseAsync(
+ resourceGroupName, resourceName, certificateName, ifMatch, context)
+ .block();
}
/**
@@ -1089,18 +1059,17 @@ public CertificateWithNonceDescriptionInner generateVerificationCode(
* @param resourceName The name of the IoT hub.
* @param certificateName The name of the certificate.
* @param ifMatch ETag of the Certificate.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the X509 Certificate along with {@link Response}.
+ * @return the X509 Certificate.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response generateVerificationCodeWithResponse(
- String resourceGroupName, String resourceName, String certificateName, String ifMatch, Context context) {
- return generateVerificationCodeWithResponseAsync(
- resourceGroupName, resourceName, certificateName, ifMatch, context)
- .block();
+ public CertificateWithNonceDescriptionInner generateVerificationCode(
+ String resourceGroupName, String resourceName, String certificateName, String ifMatch) {
+ return generateVerificationCodeWithResponse(
+ resourceGroupName, resourceName, certificateName, ifMatch, Context.NONE)
+ .getValue();
}
/**
@@ -1293,19 +1262,22 @@ private Mono verifyAsync(
* @param certificateName The name of the certificate.
* @param ifMatch ETag of the Certificate.
* @param certificateVerificationBody The name of the certificate.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the X509 Certificate.
+ * @return the X509 Certificate along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public CertificateDescriptionInner verify(
+ public Response verifyWithResponse(
String resourceGroupName,
String resourceName,
String certificateName,
String ifMatch,
- CertificateVerificationDescription certificateVerificationBody) {
- return verifyAsync(resourceGroupName, resourceName, certificateName, ifMatch, certificateVerificationBody)
+ CertificateVerificationDescription certificateVerificationBody,
+ Context context) {
+ return verifyWithResponseAsync(
+ resourceGroupName, resourceName, certificateName, ifMatch, certificateVerificationBody, context)
.block();
}
@@ -1320,22 +1292,20 @@ public CertificateDescriptionInner verify(
* @param certificateName The name of the certificate.
* @param ifMatch ETag of the Certificate.
* @param certificateVerificationBody The name of the certificate.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the X509 Certificate along with {@link Response}.
+ * @return the X509 Certificate.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response verifyWithResponse(
+ public CertificateDescriptionInner verify(
String resourceGroupName,
String resourceName,
String certificateName,
String ifMatch,
- CertificateVerificationDescription certificateVerificationBody,
- Context context) {
- return verifyWithResponseAsync(
- resourceGroupName, resourceName, certificateName, ifMatch, certificateVerificationBody, context)
- .block();
+ CertificateVerificationDescription certificateVerificationBody) {
+ return verifyWithResponse(
+ resourceGroupName, resourceName, certificateName, ifMatch, certificateVerificationBody, Context.NONE)
+ .getValue();
}
}
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/CertificatesImpl.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/CertificatesImpl.java
index 3cdd59adceaa..44fbec70418f 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/CertificatesImpl.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/CertificatesImpl.java
@@ -31,15 +31,6 @@ public CertificatesImpl(
this.serviceManager = serviceManager;
}
- public CertificateListDescription listByIotHub(String resourceGroupName, String resourceName) {
- CertificateListDescriptionInner inner = this.serviceClient().listByIotHub(resourceGroupName, resourceName);
- if (inner != null) {
- return new CertificateListDescriptionImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
public Response listByIotHubWithResponse(
String resourceGroupName, String resourceName, Context context) {
Response inner =
@@ -55,10 +46,10 @@ public Response listByIotHubWithResponse(
}
}
- public CertificateDescription get(String resourceGroupName, String resourceName, String certificateName) {
- CertificateDescriptionInner inner = this.serviceClient().get(resourceGroupName, resourceName, certificateName);
+ public CertificateListDescription listByIotHub(String resourceGroupName, String resourceName) {
+ CertificateListDescriptionInner inner = this.serviceClient().listByIotHub(resourceGroupName, resourceName);
if (inner != null) {
- return new CertificateDescriptionImpl(inner, this.manager());
+ return new CertificateListDescriptionImpl(inner, this.manager());
} else {
return null;
}
@@ -79,8 +70,13 @@ public Response getWithResponse(
}
}
- public void delete(String resourceGroupName, String resourceName, String certificateName, String ifMatch) {
- this.serviceClient().delete(resourceGroupName, resourceName, certificateName, ifMatch);
+ public CertificateDescription get(String resourceGroupName, String resourceName, String certificateName) {
+ CertificateDescriptionInner inner = this.serviceClient().get(resourceGroupName, resourceName, certificateName);
+ if (inner != null) {
+ return new CertificateDescriptionImpl(inner, this.manager());
+ } else {
+ return null;
+ }
}
public Response deleteWithResponse(
@@ -90,15 +86,8 @@ public Response deleteWithResponse(
.deleteWithResponse(resourceGroupName, resourceName, certificateName, ifMatch, context);
}
- public CertificateWithNonceDescription generateVerificationCode(
- String resourceGroupName, String resourceName, String certificateName, String ifMatch) {
- CertificateWithNonceDescriptionInner inner =
- this.serviceClient().generateVerificationCode(resourceGroupName, resourceName, certificateName, ifMatch);
- if (inner != null) {
- return new CertificateWithNonceDescriptionImpl(inner, this.manager());
- } else {
- return null;
- }
+ public void delete(String resourceGroupName, String resourceName, String certificateName, String ifMatch) {
+ this.serviceClient().delete(resourceGroupName, resourceName, certificateName, ifMatch);
}
public Response generateVerificationCodeWithResponse(
@@ -119,18 +108,12 @@ public Response generateVerificationCodeWithRes
}
}
- public CertificateDescription verify(
- String resourceGroupName,
- String resourceName,
- String certificateName,
- String ifMatch,
- CertificateVerificationDescription certificateVerificationBody) {
- CertificateDescriptionInner inner =
- this
- .serviceClient()
- .verify(resourceGroupName, resourceName, certificateName, ifMatch, certificateVerificationBody);
+ public CertificateWithNonceDescription generateVerificationCode(
+ String resourceGroupName, String resourceName, String certificateName, String ifMatch) {
+ CertificateWithNonceDescriptionInner inner =
+ this.serviceClient().generateVerificationCode(resourceGroupName, resourceName, certificateName, ifMatch);
if (inner != null) {
- return new CertificateDescriptionImpl(inner, this.manager());
+ return new CertificateWithNonceDescriptionImpl(inner, this.manager());
} else {
return null;
}
@@ -159,6 +142,23 @@ public Response verifyWithResponse(
}
}
+ public CertificateDescription verify(
+ String resourceGroupName,
+ String resourceName,
+ String certificateName,
+ String ifMatch,
+ CertificateVerificationDescription certificateVerificationBody) {
+ CertificateDescriptionInner inner =
+ this
+ .serviceClient()
+ .verify(resourceGroupName, resourceName, certificateName, ifMatch, certificateVerificationBody);
+ if (inner != null) {
+ return new CertificateDescriptionImpl(inner, this.manager());
+ } else {
+ return null;
+ }
+ }
+
public CertificateDescription getById(String id) {
String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubClientImpl.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubClientImpl.java
index 3d89f5ebaa03..bac045f9f008 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubClientImpl.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubClientImpl.java
@@ -220,7 +220,7 @@ public PrivateEndpointConnectionsClient getPrivateEndpointConnections() {
this.defaultPollInterval = defaultPollInterval;
this.subscriptionId = subscriptionId;
this.endpoint = endpoint;
- this.apiVersion = "2022-04-30-preview";
+ this.apiVersion = "2022-11-15-preview";
this.operations = new OperationsClientImpl(this);
this.iotHubResources = new IotHubResourcesClientImpl(this);
this.resourceProviderCommons = new ResourceProviderCommonsClientImpl(this);
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubDescriptionImpl.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubDescriptionImpl.java
index 488b458ae10d..ee3654eefa21 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubDescriptionImpl.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubDescriptionImpl.java
@@ -190,10 +190,6 @@ public PagedIterable listKeys(Context co
return serviceManager.iotHubResources().listKeys(resourceGroupName, resourceName, context);
}
- public JobResponse exportDevices(ExportDevicesRequest exportDevicesParameters) {
- return serviceManager.iotHubResources().exportDevices(resourceGroupName, resourceName, exportDevicesParameters);
- }
-
public Response exportDevicesWithResponse(
ExportDevicesRequest exportDevicesParameters, Context context) {
return serviceManager
@@ -201,8 +197,8 @@ public Response exportDevicesWithResponse(
.exportDevicesWithResponse(resourceGroupName, resourceName, exportDevicesParameters, context);
}
- public JobResponse importDevices(ImportDevicesRequest importDevicesParameters) {
- return serviceManager.iotHubResources().importDevices(resourceGroupName, resourceName, importDevicesParameters);
+ public JobResponse exportDevices(ExportDevicesRequest exportDevicesParameters) {
+ return serviceManager.iotHubResources().exportDevices(resourceGroupName, resourceName, exportDevicesParameters);
}
public Response importDevicesWithResponse(
@@ -212,6 +208,10 @@ public Response importDevicesWithResponse(
.importDevicesWithResponse(resourceGroupName, resourceName, importDevicesParameters, context);
}
+ public JobResponse importDevices(ImportDevicesRequest importDevicesParameters) {
+ return serviceManager.iotHubResources().importDevices(resourceGroupName, resourceName, importDevicesParameters);
+ }
+
public IotHubDescriptionImpl withRegion(Region location) {
this.innerModel().withLocation(location.toString());
return this;
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubResourcesClientImpl.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubResourcesClientImpl.java
index 90cc8da5e809..2f6835b2ae6e 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubResourcesClientImpl.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubResourcesClientImpl.java
@@ -89,11 +89,10 @@ public final class IotHubResourcesClientImpl implements IotHubResourcesClient {
*/
@Host("{$host}")
@ServiceInterface(name = "IotHubClientIotHubRe")
- private interface IotHubResourcesService {
+ public interface IotHubResourcesService {
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> getByResourceGroup(
@@ -107,8 +106,7 @@ Mono> getByResourceGroup(
@Headers({"Content-Type: application/json"})
@Put(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}")
@ExpectedResponses({200, 201})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono>> createOrUpdate(
@@ -124,8 +122,7 @@ Mono>> createOrUpdate(
@Headers({"Content-Type: application/json"})
@Patch(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ManagementException.class)
Mono>> update(
@@ -140,8 +137,7 @@ Mono>> update(
@Headers({"Content-Type: application/json"})
@Delete(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}")
@ExpectedResponses({200, 202, 204, 404})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono>> delete(
@@ -178,8 +174,7 @@ Mono> listByResourceGroup(
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/IotHubStats")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/IotHubStats")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> getStats(
@@ -193,8 +188,7 @@ Mono> getStats(
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/skus")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/skus")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> getValidSkus(
@@ -208,8 +202,7 @@ Mono> getValidSkus(
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/eventHubEndpoints/{eventHubEndpointName}/ConsumerGroups")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/eventHubEndpoints/{eventHubEndpointName}/ConsumerGroups")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> listEventHubConsumerGroups(
@@ -224,8 +217,7 @@ Mono> listEventHubConsumerGroups(
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/eventHubEndpoints/{eventHubEndpointName}/ConsumerGroups/{name}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/eventHubEndpoints/{eventHubEndpointName}/ConsumerGroups/{name}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> getEventHubConsumerGroup(
@@ -241,8 +233,7 @@ Mono> getEventHubConsumerGroup(
@Headers({"Content-Type: application/json"})
@Put(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/eventHubEndpoints/{eventHubEndpointName}/ConsumerGroups/{name}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/eventHubEndpoints/{eventHubEndpointName}/ConsumerGroups/{name}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> createEventHubConsumerGroup(
@@ -259,8 +250,7 @@ Mono> createEventHubConsumerGroup(
@Headers({"Content-Type: application/json"})
@Delete(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/eventHubEndpoints/{eventHubEndpointName}/ConsumerGroups/{name}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/eventHubEndpoints/{eventHubEndpointName}/ConsumerGroups/{name}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> deleteEventHubConsumerGroup(
@@ -276,8 +266,7 @@ Mono> deleteEventHubConsumerGroup(
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/jobs")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/jobs")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> listJobs(
@@ -291,8 +280,7 @@ Mono> listJobs(
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/jobs/{jobId}")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/jobs/{jobId}")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> getJob(
@@ -307,8 +295,7 @@ Mono> getJob(
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/quotaMetrics")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/quotaMetrics")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> getQuotaMetrics(
@@ -322,8 +309,7 @@ Mono> getQuotaMetrics(
@Headers({"Content-Type: application/json"})
@Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{iotHubName}/routingEndpointsHealth")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{iotHubName}/routingEndpointsHealth")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> getEndpointHealth(
@@ -349,8 +335,7 @@ Mono> checkNameAvailability(
@Headers({"Content-Type: application/json"})
@Post(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{iotHubName}/routing/routes/$testall")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{iotHubName}/routing/routes/$testall")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> testAllRoutes(
@@ -365,8 +350,7 @@ Mono> testAllRoutes(
@Headers({"Content-Type: application/json"})
@Post(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{iotHubName}/routing/routes/$testnew")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{iotHubName}/routing/routes/$testnew")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> testRoute(
@@ -381,8 +365,7 @@ Mono> testRoute(
@Headers({"Content-Type: application/json"})
@Post(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/listkeys")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/listkeys")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> listKeys(
@@ -396,8 +379,7 @@ Mono> listKeys(
@Headers({"Content-Type: application/json"})
@Post(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/IotHubKeys/{keyName}/listkeys")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/IotHubKeys/{keyName}/listkeys")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> getKeysForKeyName(
@@ -412,8 +394,7 @@ Mono> getKeysForKeyName(
@Headers({"Content-Type: application/json"})
@Post(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/exportDevices")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/exportDevices")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> exportDevices(
@@ -428,8 +409,7 @@ Mono> exportDevices(
@Headers({"Content-Type: application/json"})
@Post(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs"
- + "/{resourceName}/importDevices")
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/importDevices")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ErrorDetailsException.class)
Mono> importDevices(
@@ -648,14 +628,16 @@ private Mono getByResourceGroupAsync(String resourceGrou
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the non-security related metadata of an IoT hub.
+ * @return the non-security related metadata of an IoT hub along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public IotHubDescriptionInner getByResourceGroup(String resourceGroupName, String resourceName) {
- return getByResourceGroupAsync(resourceGroupName, resourceName).block();
+ public Response getByResourceGroupWithResponse(
+ String resourceGroupName, String resourceName, Context context) {
+ return getByResourceGroupWithResponseAsync(resourceGroupName, resourceName, context).block();
}
/**
@@ -665,16 +647,14 @@ public IotHubDescriptionInner getByResourceGroup(String resourceGroupName, Strin
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the non-security related metadata of an IoT hub along with {@link Response}.
+ * @return the non-security related metadata of an IoT hub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response getByResourceGroupWithResponse(
- String resourceGroupName, String resourceName, Context context) {
- return getByResourceGroupWithResponseAsync(resourceGroupName, resourceName, context).block();
+ public IotHubDescriptionInner getByResourceGroup(String resourceGroupName, String resourceName) {
+ return getByResourceGroupWithResponse(resourceGroupName, resourceName, Context.NONE).getValue();
}
/**
@@ -837,6 +817,37 @@ private PollerFlux, IotHubDescriptionInner> b
this.client.getContext());
}
+ /**
+ * Create or update the metadata of an IoT hub.
+ *
+ * Create or update the metadata of an Iot hub. The usual pattern to modify a property is to retrieve the IoT hub
+ * metadata and security metadata, and then combine them with the modified values in a new body to update the IoT
+ * hub.
+ *
+ * @param resourceGroupName The name of the resource group that contains the IoT hub.
+ * @param resourceName The name of the IoT hub.
+ * @param iotHubDescription The IoT hub metadata and security metadata.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ErrorDetailsException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the {@link PollerFlux} for polling of the description of the IoT hub.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, IotHubDescriptionInner> beginCreateOrUpdateAsync(
+ String resourceGroupName, String resourceName, IotHubDescriptionInner iotHubDescription) {
+ final String ifMatch = null;
+ Mono>> mono =
+ createOrUpdateWithResponseAsync(resourceGroupName, resourceName, iotHubDescription, ifMatch);
+ return this
+ .client
+ .getLroResult(
+ mono,
+ this.client.getHttpPipeline(),
+ IotHubDescriptionInner.class,
+ IotHubDescriptionInner.class,
+ this.client.getContext());
+ }
+
/**
* Create or update the metadata of an IoT hub.
*
@@ -885,8 +896,6 @@ private PollerFlux, IotHubDescriptionInner> b
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param iotHubDescription The IoT hub metadata and security metadata.
- * @param ifMatch ETag of the IoT Hub. Do not specify for creating a brand new IoT Hub. Required to update an
- * existing IoT Hub.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
@@ -894,8 +903,11 @@ private PollerFlux, IotHubDescriptionInner> b
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, IotHubDescriptionInner> beginCreateOrUpdate(
- String resourceGroupName, String resourceName, IotHubDescriptionInner iotHubDescription, String ifMatch) {
- return beginCreateOrUpdateAsync(resourceGroupName, resourceName, iotHubDescription, ifMatch).getSyncPoller();
+ String resourceGroupName, String resourceName, IotHubDescriptionInner iotHubDescription) {
+ final String ifMatch = null;
+ return this
+ .beginCreateOrUpdateAsync(resourceGroupName, resourceName, iotHubDescription, ifMatch)
+ .getSyncPoller();
}
/**
@@ -923,7 +935,8 @@ public SyncPoller, IotHubDescriptionInner> be
IotHubDescriptionInner iotHubDescription,
String ifMatch,
Context context) {
- return beginCreateOrUpdateAsync(resourceGroupName, resourceName, iotHubDescription, ifMatch, context)
+ return this
+ .beginCreateOrUpdateAsync(resourceGroupName, resourceName, iotHubDescription, ifMatch, context)
.getSyncPoller();
}
@@ -1006,29 +1019,6 @@ private Mono createOrUpdateAsync(
.flatMap(this.client::getLroFinalResultOrError);
}
- /**
- * Create or update the metadata of an IoT hub.
- *
- * Create or update the metadata of an Iot hub. The usual pattern to modify a property is to retrieve the IoT hub
- * metadata and security metadata, and then combine them with the modified values in a new body to update the IoT
- * hub.
- *
- * @param resourceGroupName The name of the resource group that contains the IoT hub.
- * @param resourceName The name of the IoT hub.
- * @param iotHubDescription The IoT hub metadata and security metadata.
- * @param ifMatch ETag of the IoT Hub. Do not specify for creating a brand new IoT Hub. Required to update an
- * existing IoT Hub.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ErrorDetailsException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the description of the IoT hub.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public IotHubDescriptionInner createOrUpdate(
- String resourceGroupName, String resourceName, IotHubDescriptionInner iotHubDescription, String ifMatch) {
- return createOrUpdateAsync(resourceGroupName, resourceName, iotHubDescription, ifMatch).block();
- }
-
/**
* Create or update the metadata of an IoT hub.
*
@@ -1264,7 +1254,7 @@ private PollerFlux, IotHubDescriptionInner> b
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, IotHubDescriptionInner> beginUpdate(
String resourceGroupName, String resourceName, TagsResource iotHubTags) {
- return beginUpdateAsync(resourceGroupName, resourceName, iotHubTags).getSyncPoller();
+ return this.beginUpdateAsync(resourceGroupName, resourceName, iotHubTags).getSyncPoller();
}
/**
@@ -1284,7 +1274,7 @@ public SyncPoller, IotHubDescriptionInner> be
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, IotHubDescriptionInner> beginUpdate(
String resourceGroupName, String resourceName, TagsResource iotHubTags, Context context) {
- return beginUpdateAsync(resourceGroupName, resourceName, iotHubTags, context).getSyncPoller();
+ return this.beginUpdateAsync(resourceGroupName, resourceName, iotHubTags, context).getSyncPoller();
}
/**
@@ -1534,7 +1524,7 @@ private PollerFlux, IotHubDescriptionInner> b
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, IotHubDescriptionInner> beginDelete(
String resourceGroupName, String resourceName) {
- return beginDeleteAsync(resourceGroupName, resourceName).getSyncPoller();
+ return this.beginDeleteAsync(resourceGroupName, resourceName).getSyncPoller();
}
/**
@@ -1553,7 +1543,7 @@ public SyncPoller, IotHubDescriptionInner> be
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, IotHubDescriptionInner> beginDelete(
String resourceGroupName, String resourceName, Context context) {
- return beginDeleteAsync(resourceGroupName, resourceName, context).getSyncPoller();
+ return this.beginDeleteAsync(resourceGroupName, resourceName, context).getSyncPoller();
}
/**
@@ -2083,14 +2073,16 @@ private Mono getStatsAsync(String resourceGroupName, St
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the statistics from an IoT hub.
+ * @return the statistics from an IoT hub along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public RegistryStatisticsInner getStats(String resourceGroupName, String resourceName) {
- return getStatsAsync(resourceGroupName, resourceName).block();
+ public Response getStatsWithResponse(
+ String resourceGroupName, String resourceName, Context context) {
+ return getStatsWithResponseAsync(resourceGroupName, resourceName, context).block();
}
/**
@@ -2100,16 +2092,14 @@ public RegistryStatisticsInner getStats(String resourceGroupName, String resourc
*
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the statistics from an IoT hub along with {@link Response}.
+ * @return the statistics from an IoT hub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response getStatsWithResponse(
- String resourceGroupName, String resourceName, Context context) {
- return getStatsWithResponseAsync(resourceGroupName, resourceName, context).block();
+ public RegistryStatisticsInner getStats(String resourceGroupName, String resourceName) {
+ return getStatsWithResponse(resourceGroupName, resourceName, Context.NONE).getValue();
}
/**
@@ -2679,15 +2669,19 @@ private Mono getEventHubConsumerGroupAsync(
* @param resourceName The name of the IoT hub.
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to retrieve.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub.
+ * @return a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub along with {@link
+ * Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public EventHubConsumerGroupInfoInner getEventHubConsumerGroup(
- String resourceGroupName, String resourceName, String eventHubEndpointName, String name) {
- return getEventHubConsumerGroupAsync(resourceGroupName, resourceName, eventHubEndpointName, name).block();
+ public Response getEventHubConsumerGroupWithResponse(
+ String resourceGroupName, String resourceName, String eventHubEndpointName, String name, Context context) {
+ return getEventHubConsumerGroupWithResponseAsync(
+ resourceGroupName, resourceName, eventHubEndpointName, name, context)
+ .block();
}
/**
@@ -2699,19 +2693,17 @@ public EventHubConsumerGroupInfoInner getEventHubConsumerGroup(
* @param resourceName The name of the IoT hub.
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to retrieve.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub along with {@link
- * Response}.
+ * @return a consumer group from the Event Hub-compatible device-to-cloud endpoint for an IoT hub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response getEventHubConsumerGroupWithResponse(
- String resourceGroupName, String resourceName, String eventHubEndpointName, String name, Context context) {
- return getEventHubConsumerGroupWithResponseAsync(
- resourceGroupName, resourceName, eventHubEndpointName, name, context)
- .block();
+ public EventHubConsumerGroupInfoInner getEventHubConsumerGroup(
+ String resourceGroupName, String resourceName, String eventHubEndpointName, String name) {
+ return getEventHubConsumerGroupWithResponse(
+ resourceGroupName, resourceName, eventHubEndpointName, name, Context.NONE)
+ .getValue();
}
/**
@@ -2898,20 +2890,22 @@ private Mono createEventHubConsumerGroupAsync(
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to add.
* @param consumerGroupBody The consumer group to add.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the EventHubConsumerGroupInfo object.
+ * @return the properties of the EventHubConsumerGroupInfo object along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public EventHubConsumerGroupInfoInner createEventHubConsumerGroup(
+ public Response createEventHubConsumerGroupWithResponse(
String resourceGroupName,
String resourceName,
String eventHubEndpointName,
String name,
- EventHubConsumerGroupBodyDescription consumerGroupBody) {
- return createEventHubConsumerGroupAsync(
- resourceGroupName, resourceName, eventHubEndpointName, name, consumerGroupBody)
+ EventHubConsumerGroupBodyDescription consumerGroupBody,
+ Context context) {
+ return createEventHubConsumerGroupWithResponseAsync(
+ resourceGroupName, resourceName, eventHubEndpointName, name, consumerGroupBody, context)
.block();
}
@@ -2925,23 +2919,21 @@ public EventHubConsumerGroupInfoInner createEventHubConsumerGroup(
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to add.
* @param consumerGroupBody The consumer group to add.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the EventHubConsumerGroupInfo object along with {@link Response}.
+ * @return the properties of the EventHubConsumerGroupInfo object.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response createEventHubConsumerGroupWithResponse(
+ public EventHubConsumerGroupInfoInner createEventHubConsumerGroup(
String resourceGroupName,
String resourceName,
String eventHubEndpointName,
String name,
- EventHubConsumerGroupBodyDescription consumerGroupBody,
- Context context) {
- return createEventHubConsumerGroupWithResponseAsync(
- resourceGroupName, resourceName, eventHubEndpointName, name, consumerGroupBody, context)
- .block();
+ EventHubConsumerGroupBodyDescription consumerGroupBody) {
+ return createEventHubConsumerGroupWithResponse(
+ resourceGroupName, resourceName, eventHubEndpointName, name, consumerGroupBody, Context.NONE)
+ .getValue();
}
/**
@@ -3094,14 +3086,18 @@ private Mono deleteEventHubConsumerGroupAsync(
* @param resourceName The name of the IoT hub.
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to delete.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public void deleteEventHubConsumerGroup(
- String resourceGroupName, String resourceName, String eventHubEndpointName, String name) {
- deleteEventHubConsumerGroupAsync(resourceGroupName, resourceName, eventHubEndpointName, name).block();
+ public Response deleteEventHubConsumerGroupWithResponse(
+ String resourceGroupName, String resourceName, String eventHubEndpointName, String name, Context context) {
+ return deleteEventHubConsumerGroupWithResponseAsync(
+ resourceGroupName, resourceName, eventHubEndpointName, name, context)
+ .block();
}
/**
@@ -3113,18 +3109,15 @@ public void deleteEventHubConsumerGroup(
* @param resourceName The name of the IoT hub.
* @param eventHubEndpointName The name of the Event Hub-compatible endpoint in the IoT hub.
* @param name The name of the consumer group to delete.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response deleteEventHubConsumerGroupWithResponse(
- String resourceGroupName, String resourceName, String eventHubEndpointName, String name, Context context) {
- return deleteEventHubConsumerGroupWithResponseAsync(
- resourceGroupName, resourceName, eventHubEndpointName, name, context)
- .block();
+ public void deleteEventHubConsumerGroup(
+ String resourceGroupName, String resourceName, String eventHubEndpointName, String name) {
+ deleteEventHubConsumerGroupWithResponse(
+ resourceGroupName, resourceName, eventHubEndpointName, name, Context.NONE);
}
/**
@@ -3476,14 +3469,16 @@ private Mono getJobAsync(String resourceGroupName, String reso
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param jobId The job identifier.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the details of a job from an IoT hub.
+ * @return the details of a job from an IoT hub along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public JobResponseInner getJob(String resourceGroupName, String resourceName, String jobId) {
- return getJobAsync(resourceGroupName, resourceName, jobId).block();
+ public Response getJobWithResponse(
+ String resourceGroupName, String resourceName, String jobId, Context context) {
+ return getJobWithResponseAsync(resourceGroupName, resourceName, jobId, context).block();
}
/**
@@ -3496,16 +3491,14 @@ public JobResponseInner getJob(String resourceGroupName, String resourceName, St
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param jobId The job identifier.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the details of a job from an IoT hub along with {@link Response}.
+ * @return the details of a job from an IoT hub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response getJobWithResponse(
- String resourceGroupName, String resourceName, String jobId, Context context) {
- return getJobWithResponseAsync(resourceGroupName, resourceName, jobId, context).block();
+ public JobResponseInner getJob(String resourceGroupName, String resourceName, String jobId) {
+ return getJobWithResponse(resourceGroupName, resourceName, jobId, Context.NONE).getValue();
}
/**
@@ -4017,14 +4010,16 @@ private Mono checkNameAvailabilityAsync(Operati
*
* @param operationInputs Set the name parameter in the OperationInputs structure to the name of the IoT hub to
* check.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties indicating whether a given IoT hub name is available.
+ * @return the properties indicating whether a given IoT hub name is available along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public IotHubNameAvailabilityInfoInner checkNameAvailability(OperationInputs operationInputs) {
- return checkNameAvailabilityAsync(operationInputs).block();
+ public Response checkNameAvailabilityWithResponse(
+ OperationInputs operationInputs, Context context) {
+ return checkNameAvailabilityWithResponseAsync(operationInputs, context).block();
}
/**
@@ -4034,16 +4029,14 @@ public IotHubNameAvailabilityInfoInner checkNameAvailability(OperationInputs ope
*
* @param operationInputs Set the name parameter in the OperationInputs structure to the name of the IoT hub to
* check.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties indicating whether a given IoT hub name is available along with {@link Response}.
+ * @return the properties indicating whether a given IoT hub name is available.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response checkNameAvailabilityWithResponse(
- OperationInputs operationInputs, Context context) {
- return checkNameAvailabilityWithResponseAsync(operationInputs, context).block();
+ public IotHubNameAvailabilityInfoInner checkNameAvailability(OperationInputs operationInputs) {
+ return checkNameAvailabilityWithResponse(operationInputs, Context.NONE).getValue();
}
/**
@@ -4186,15 +4179,16 @@ private Mono testAllRoutesAsync(
* @param iotHubName IotHub to be tested.
* @param resourceGroupName resource group which Iot Hub belongs to.
* @param input Input for testing all routes.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return result of testing all routes.
+ * @return result of testing all routes along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public TestAllRoutesResultInner testAllRoutes(
- String iotHubName, String resourceGroupName, TestAllRoutesInput input) {
- return testAllRoutesAsync(iotHubName, resourceGroupName, input).block();
+ public Response testAllRoutesWithResponse(
+ String iotHubName, String resourceGroupName, TestAllRoutesInput input, Context context) {
+ return testAllRoutesWithResponseAsync(iotHubName, resourceGroupName, input, context).block();
}
/**
@@ -4205,16 +4199,15 @@ public TestAllRoutesResultInner testAllRoutes(
* @param iotHubName IotHub to be tested.
* @param resourceGroupName resource group which Iot Hub belongs to.
* @param input Input for testing all routes.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return result of testing all routes along with {@link Response}.
+ * @return result of testing all routes.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response testAllRoutesWithResponse(
- String iotHubName, String resourceGroupName, TestAllRoutesInput input, Context context) {
- return testAllRoutesWithResponseAsync(iotHubName, resourceGroupName, input, context).block();
+ public TestAllRoutesResultInner testAllRoutes(
+ String iotHubName, String resourceGroupName, TestAllRoutesInput input) {
+ return testAllRoutesWithResponse(iotHubName, resourceGroupName, input, Context.NONE).getValue();
}
/**
@@ -4357,14 +4350,16 @@ private Mono testRouteAsync(
* @param iotHubName IotHub to be tested.
* @param resourceGroupName resource group which Iot Hub belongs to.
* @param input Route that needs to be tested.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return result of testing one route.
+ * @return result of testing one route along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public TestRouteResultInner testRoute(String iotHubName, String resourceGroupName, TestRouteInput input) {
- return testRouteAsync(iotHubName, resourceGroupName, input).block();
+ public Response testRouteWithResponse(
+ String iotHubName, String resourceGroupName, TestRouteInput input, Context context) {
+ return testRouteWithResponseAsync(iotHubName, resourceGroupName, input, context).block();
}
/**
@@ -4375,16 +4370,14 @@ public TestRouteResultInner testRoute(String iotHubName, String resourceGroupNam
* @param iotHubName IotHub to be tested.
* @param resourceGroupName resource group which Iot Hub belongs to.
* @param input Route that needs to be tested.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return result of testing one route along with {@link Response}.
+ * @return result of testing one route.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response testRouteWithResponse(
- String iotHubName, String resourceGroupName, TestRouteInput input, Context context) {
- return testRouteWithResponseAsync(iotHubName, resourceGroupName, input, context).block();
+ public TestRouteResultInner testRoute(String iotHubName, String resourceGroupName, TestRouteInput input) {
+ return testRouteWithResponse(iotHubName, resourceGroupName, input, Context.NONE).getValue();
}
/**
@@ -4741,15 +4734,16 @@ private Mono getKeysForKeyNameAsync
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param keyName The name of the shared access policy.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a shared access policy by name from an IoT hub.
+ * @return a shared access policy by name from an IoT hub along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public SharedAccessSignatureAuthorizationRuleInner getKeysForKeyName(
- String resourceGroupName, String resourceName, String keyName) {
- return getKeysForKeyNameAsync(resourceGroupName, resourceName, keyName).block();
+ public Response getKeysForKeyNameWithResponse(
+ String resourceGroupName, String resourceName, String keyName, Context context) {
+ return getKeysForKeyNameWithResponseAsync(resourceGroupName, resourceName, keyName, context).block();
}
/**
@@ -4762,16 +4756,15 @@ public SharedAccessSignatureAuthorizationRuleInner getKeysForKeyName(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param keyName The name of the shared access policy.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a shared access policy by name from an IoT hub along with {@link Response}.
+ * @return a shared access policy by name from an IoT hub.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response getKeysForKeyNameWithResponse(
- String resourceGroupName, String resourceName, String keyName, Context context) {
- return getKeysForKeyNameWithResponseAsync(resourceGroupName, resourceName, keyName, context).block();
+ public SharedAccessSignatureAuthorizationRuleInner getKeysForKeyName(
+ String resourceGroupName, String resourceName, String keyName) {
+ return getKeysForKeyNameWithResponse(resourceGroupName, resourceName, keyName, Context.NONE).getValue();
}
/**
@@ -4936,15 +4929,17 @@ private Mono exportDevicesAsync(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param exportDevicesParameters The parameters that specify the export devices operation.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the Job Response object.
+ * @return the properties of the Job Response object along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public JobResponseInner exportDevices(
- String resourceGroupName, String resourceName, ExportDevicesRequest exportDevicesParameters) {
- return exportDevicesAsync(resourceGroupName, resourceName, exportDevicesParameters).block();
+ public Response exportDevicesWithResponse(
+ String resourceGroupName, String resourceName, ExportDevicesRequest exportDevicesParameters, Context context) {
+ return exportDevicesWithResponseAsync(resourceGroupName, resourceName, exportDevicesParameters, context)
+ .block();
}
/**
@@ -4959,17 +4954,16 @@ public JobResponseInner exportDevices(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param exportDevicesParameters The parameters that specify the export devices operation.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the Job Response object along with {@link Response}.
+ * @return the properties of the Job Response object.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response exportDevicesWithResponse(
- String resourceGroupName, String resourceName, ExportDevicesRequest exportDevicesParameters, Context context) {
- return exportDevicesWithResponseAsync(resourceGroupName, resourceName, exportDevicesParameters, context)
- .block();
+ public JobResponseInner exportDevices(
+ String resourceGroupName, String resourceName, ExportDevicesRequest exportDevicesParameters) {
+ return exportDevicesWithResponse(resourceGroupName, resourceName, exportDevicesParameters, Context.NONE)
+ .getValue();
}
/**
@@ -5134,15 +5128,17 @@ private Mono importDevicesAsync(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param importDevicesParameters The parameters that specify the import devices operation.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the Job Response object.
+ * @return the properties of the Job Response object along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public JobResponseInner importDevices(
- String resourceGroupName, String resourceName, ImportDevicesRequest importDevicesParameters) {
- return importDevicesAsync(resourceGroupName, resourceName, importDevicesParameters).block();
+ public Response importDevicesWithResponse(
+ String resourceGroupName, String resourceName, ImportDevicesRequest importDevicesParameters, Context context) {
+ return importDevicesWithResponseAsync(resourceGroupName, resourceName, importDevicesParameters, context)
+ .block();
}
/**
@@ -5157,17 +5153,16 @@ public JobResponseInner importDevices(
* @param resourceGroupName The name of the resource group that contains the IoT hub.
* @param resourceName The name of the IoT hub.
* @param importDevicesParameters The parameters that specify the import devices operation.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ErrorDetailsException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the properties of the Job Response object along with {@link Response}.
+ * @return the properties of the Job Response object.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response importDevicesWithResponse(
- String resourceGroupName, String resourceName, ImportDevicesRequest importDevicesParameters, Context context) {
- return importDevicesWithResponseAsync(resourceGroupName, resourceName, importDevicesParameters, context)
- .block();
+ public JobResponseInner importDevices(
+ String resourceGroupName, String resourceName, ImportDevicesRequest importDevicesParameters) {
+ return importDevicesWithResponse(resourceGroupName, resourceName, importDevicesParameters, Context.NONE)
+ .getValue();
}
/**
diff --git a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubResourcesImpl.java b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubResourcesImpl.java
index 7e38b0c8edc4..46e33008ecd1 100644
--- a/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubResourcesImpl.java
+++ b/sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/implementation/IotHubResourcesImpl.java
@@ -52,15 +52,6 @@ public IotHubResourcesImpl(
this.serviceManager = serviceManager;
}
- public IotHubDescription getByResourceGroup(String resourceGroupName, String resourceName) {
- IotHubDescriptionInner inner = this.serviceClient().getByResourceGroup(resourceGroupName, resourceName);
- if (inner != null) {
- return new IotHubDescriptionImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
public Response getByResourceGroupWithResponse(
String resourceGroupName, String resourceName, Context context) {
Response inner =
@@ -76,6 +67,15 @@ public Response getByResourceGroupWithResponse(
}
}
+ public IotHubDescription getByResourceGroup(String resourceGroupName, String resourceName) {
+ IotHubDescriptionInner inner = this.serviceClient().getByResourceGroup(resourceGroupName, resourceName);
+ if (inner != null) {
+ return new IotHubDescriptionImpl(inner, this.manager());
+ } else {
+ return null;
+ }
+ }
+
public IotHubDescription deleteByResourceGroup(String resourceGroupName, String resourceName) {
IotHubDescriptionInner inner = this.serviceClient().delete(resourceGroupName, resourceName);
if (inner != null) {
@@ -115,15 +115,6 @@ public PagedIterable listByResourceGroup(String resourceGroup
return Utils.mapPage(inner, inner1 -> new IotHubDescriptionImpl(inner1, this.manager()));
}
- public RegistryStatistics getStats(String resourceGroupName, String resourceName) {
- RegistryStatisticsInner inner = this.serviceClient().getStats(resourceGroupName, resourceName);
- if (inner != null) {
- return new RegistryStatisticsImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
public Response getStatsWithResponse(
String resourceGroupName, String resourceName, Context context) {
Response inner =
@@ -139,6 +130,15 @@ public Response getStatsWithResponse(
}
}
+ public RegistryStatistics getStats(String resourceGroupName, String resourceName) {
+ RegistryStatisticsInner inner = this.serviceClient().getStats(resourceGroupName, resourceName);
+ if (inner != null) {
+ return new RegistryStatisticsImpl(inner, this.manager());
+ } else {
+ return null;
+ }
+ }
+
public PagedIterable getValidSkus(String resourceGroupName, String resourceName) {
PagedIterable inner =
this.serviceClient().getValidSkus(resourceGroupName, resourceName);
@@ -168,17 +168,6 @@ public PagedIterable listEventHubConsumerGroups(
return Utils.mapPage(inner, inner1 -> new EventHubConsumerGroupInfoImpl(inner1, this.manager()));
}
- public EventHubConsumerGroupInfo getEventHubConsumerGroup(
- String resourceGroupName, String resourceName, String eventHubEndpointName, String name) {
- EventHubConsumerGroupInfoInner inner =
- this.serviceClient().getEventHubConsumerGroup(resourceGroupName, resourceName, eventHubEndpointName, name);
- if (inner != null) {
- return new EventHubConsumerGroupInfoImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
public Response getEventHubConsumerGroupWithResponse(
String resourceGroupName, String resourceName, String eventHubEndpointName, String name, Context context) {
Response inner =
@@ -197,9 +186,15 @@ public Response getEventHubConsumerGroupWithResponse(
}
}
- public void deleteEventHubConsumerGroup(
+ public EventHubConsumerGroupInfo getEventHubConsumerGroup(
String resourceGroupName, String resourceName, String eventHubEndpointName, String name) {
- this.serviceClient().deleteEventHubConsumerGroup(resourceGroupName, resourceName, eventHubEndpointName, name);
+ EventHubConsumerGroupInfoInner inner =
+ this.serviceClient().getEventHubConsumerGroup(resourceGroupName, resourceName, eventHubEndpointName, name);
+ if (inner != null) {
+ return new EventHubConsumerGroupInfoImpl(inner, this.manager());
+ } else {
+ return null;
+ }
}
public Response deleteEventHubConsumerGroupWithResponse(
@@ -210,6 +205,11 @@ public Response deleteEventHubConsumerGroupWithResponse(
resourceGroupName, resourceName, eventHubEndpointName, name, context);
}
+ public void deleteEventHubConsumerGroup(
+ String resourceGroupName, String resourceName, String eventHubEndpointName, String name) {
+ this.serviceClient().deleteEventHubConsumerGroup(resourceGroupName, resourceName, eventHubEndpointName, name);
+ }
+
public PagedIterable listJobs(String resourceGroupName, String resourceName) {
PagedIterable inner = this.serviceClient().listJobs(resourceGroupName, resourceName);
return Utils.mapPage(inner, inner1 -> new JobResponseImpl(inner1, this.manager()));
@@ -220,15 +220,6 @@ public PagedIterable listJobs(String resourceGroupName, String reso
return Utils.mapPage(inner, inner1 -> new JobResponseImpl(inner1, this.manager()));
}
- public JobResponse getJob(String resourceGroupName, String resourceName, String jobId) {
- JobResponseInner inner = this.serviceClient().getJob(resourceGroupName, resourceName, jobId);
- if (inner != null) {
- return new JobResponseImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
public Response getJobWithResponse(
String resourceGroupName, String resourceName, String jobId, Context context) {
Response inner =
@@ -244,6 +235,15 @@ public Response getJobWithResponse(
}
}
+ public JobResponse getJob(String resourceGroupName, String resourceName, String jobId) {
+ JobResponseInner inner = this.serviceClient().getJob(resourceGroupName, resourceName, jobId);
+ if (inner != null) {
+ return new JobResponseImpl(inner, this.manager());
+ } else {
+ return null;
+ }
+ }
+
public PagedIterable getQuotaMetrics(String resourceGroupName, String resourceName) {
PagedIterable inner =
this.serviceClient().getQuotaMetrics(resourceGroupName, resourceName);
@@ -270,15 +270,6 @@ public PagedIterable getEndpointHealth(
return Utils.mapPage(inner, inner1 -> new EndpointHealthDataImpl(inner1, this.manager()));
}
- public IotHubNameAvailabilityInfo checkNameAvailability(OperationInputs operationInputs) {
- IotHubNameAvailabilityInfoInner inner = this.serviceClient().checkNameAvailability(operationInputs);
- if (inner != null) {
- return new IotHubNameAvailabilityInfoImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
public Response checkNameAvailabilityWithResponse(
OperationInputs operationInputs, Context context) {
Response inner =
@@ -294,10 +285,10 @@ public Response checkNameAvailabilityWithResponse(
}
}
- public TestAllRoutesResult testAllRoutes(String iotHubName, String resourceGroupName, TestAllRoutesInput input) {
- TestAllRoutesResultInner inner = this.serviceClient().testAllRoutes(iotHubName, resourceGroupName, input);
+ public IotHubNameAvailabilityInfo checkNameAvailability(OperationInputs operationInputs) {
+ IotHubNameAvailabilityInfoInner inner = this.serviceClient().checkNameAvailability(operationInputs);
if (inner != null) {
- return new TestAllRoutesResultImpl(inner, this.manager());
+ return new IotHubNameAvailabilityInfoImpl(inner, this.manager());
} else {
return null;
}
@@ -318,10 +309,10 @@ public Response