Skip to content

Commit 365929b

Browse files
Regenerate IoT Hub control plane to match latest swagger
Most of these changes appear to be from how autorest generates the code now vs the last time it generated, but the important part is that the isVerified flag in CertificateProperties.java is no longer write-only Azure/azure-rest-api-specs#15722
1 parent 51ea350 commit 365929b

File tree

214 files changed

+5628
-7901
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

214 files changed

+5628
-7901
lines changed

sdk/iothub/azure-resourcemanager-iothub/src/main/java/com/azure/resourcemanager/iothub/IotHubManager.java

Lines changed: 47 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99
import com.azure.core.http.HttpPipeline;
1010
import com.azure.core.http.HttpPipelineBuilder;
1111
import com.azure.core.http.policy.AddDatePolicy;
12-
import com.azure.core.http.policy.HttpLogOptions;
1312
import com.azure.core.http.policy.HttpLoggingPolicy;
13+
import com.azure.core.http.policy.HttpLogOptions;
1414
import com.azure.core.http.policy.HttpPipelinePolicy;
1515
import com.azure.core.http.policy.HttpPolicyProviders;
1616
import com.azure.core.http.policy.RequestIdPolicy;
@@ -42,7 +42,10 @@
4242
import java.util.List;
4343
import java.util.Objects;
4444

45-
/** Entry point to IotHubManager. Use this API to manage the IoT hubs in your Azure subscription. */
45+
/**
46+
* Entry point to IotHubManager.
47+
* Use this API to manage the IoT hubs in your Azure subscription.
48+
*/
4649
public final class IotHubManager {
4750
private Operations operations;
4851

@@ -63,18 +66,17 @@ public final class IotHubManager {
6366
private IotHubManager(HttpPipeline httpPipeline, AzureProfile profile, Duration defaultPollInterval) {
6467
Objects.requireNonNull(httpPipeline, "'httpPipeline' cannot be null.");
6568
Objects.requireNonNull(profile, "'profile' cannot be null.");
66-
this.clientObject =
67-
new IotHubClientBuilder()
68-
.pipeline(httpPipeline)
69-
.endpoint(profile.getEnvironment().getResourceManagerEndpoint())
70-
.subscriptionId(profile.getSubscriptionId())
71-
.defaultPollInterval(defaultPollInterval)
72-
.buildClient();
69+
this.clientObject = new IotHubClientBuilder()
70+
.pipeline(httpPipeline)
71+
.endpoint(profile.getEnvironment().getResourceManagerEndpoint())
72+
.subscriptionId(profile.getSubscriptionId())
73+
.defaultPollInterval(defaultPollInterval)
74+
.buildClient();
7375
}
7476

7577
/**
7678
* Creates an instance of IotHub service API entry point.
77-
*
79+
*
7880
* @param credential the credential to use.
7981
* @param profile the Azure profile for client.
8082
* @return the IotHub service API instance.
@@ -87,14 +89,16 @@ public static IotHubManager authenticate(TokenCredential credential, AzureProfil
8789

8890
/**
8991
* Gets a Configurable instance that can be used to create IotHubManager with optional configuration.
90-
*
92+
*
9193
* @return the Configurable instance allowing configurations.
9294
*/
9395
public static Configurable configure() {
9496
return new IotHubManager.Configurable();
9597
}
9698

97-
/** The Configurable allowing configurations to be set. */
99+
/**
100+
* The Configurable allowing configurations to be set.
101+
*/
98102
public static final class Configurable {
99103
private final ClientLogger logger = new ClientLogger(Configurable.class);
100104

@@ -189,15 +193,13 @@ public IotHubManager authenticate(TokenCredential credential, AzureProfile profi
189193
Objects.requireNonNull(profile, "'profile' cannot be null.");
190194

191195
StringBuilder userAgentBuilder = new StringBuilder();
192-
userAgentBuilder
193-
.append("azsdk-java")
196+
userAgentBuilder.append("azsdk-java")
194197
.append("-")
195198
.append("com.azure.resourcemanager.iothub")
196199
.append("/")
197-
.append("1.0.0");
200+
.append("1.1.0");
198201
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
199-
userAgentBuilder
200-
.append(" (")
202+
userAgentBuilder.append(" (")
201203
.append(Configuration.getGlobalConfiguration().get("java.version"))
202204
.append("; ")
203205
.append(Configuration.getGlobalConfiguration().get("os.name"))
@@ -224,77 +226,85 @@ public IotHubManager authenticate(TokenCredential credential, AzureProfile profi
224226
policies.addAll(this.policies);
225227
HttpPolicyProviders.addAfterRetryPolicies(policies);
226228
policies.add(new HttpLoggingPolicy(httpLogOptions));
227-
HttpPipeline httpPipeline =
228-
new HttpPipelineBuilder()
229-
.httpClient(httpClient)
230-
.policies(policies.toArray(new HttpPipelinePolicy[0]))
231-
.build();
229+
HttpPipeline httpPipeline = new HttpPipelineBuilder()
230+
.httpClient(httpClient)
231+
.policies(policies.toArray(new HttpPipelinePolicy[0])).build();
232232
return new IotHubManager(httpPipeline, profile, defaultPollInterval);
233233
}
234234
}
235235

236-
/** @return Resource collection API of Operations. */
236+
/**
237+
* @return Resource collection API of Operations.
238+
*/
237239
public Operations operations() {
238240
if (this.operations == null) {
239241
this.operations = new OperationsImpl(clientObject.getOperations(), this);
240242
}
241243
return operations;
242244
}
243245

244-
/** @return Resource collection API of IotHubResources. */
246+
/**
247+
* @return Resource collection API of IotHubResources.
248+
*/
245249
public IotHubResources iotHubResources() {
246250
if (this.iotHubResources == null) {
247251
this.iotHubResources = new IotHubResourcesImpl(clientObject.getIotHubResources(), this);
248252
}
249253
return iotHubResources;
250254
}
251255

252-
/** @return Resource collection API of ResourceProviderCommons. */
256+
/**
257+
* @return Resource collection API of ResourceProviderCommons.
258+
*/
253259
public ResourceProviderCommons resourceProviderCommons() {
254260
if (this.resourceProviderCommons == null) {
255-
this.resourceProviderCommons =
256-
new ResourceProviderCommonsImpl(clientObject.getResourceProviderCommons(), this);
261+
this.resourceProviderCommons = new ResourceProviderCommonsImpl(clientObject.getResourceProviderCommons(), this);
257262
}
258263
return resourceProviderCommons;
259264
}
260265

261-
/** @return Resource collection API of Certificates. */
266+
/**
267+
* @return Resource collection API of Certificates.
268+
*/
262269
public Certificates certificates() {
263270
if (this.certificates == null) {
264271
this.certificates = new CertificatesImpl(clientObject.getCertificates(), this);
265272
}
266273
return certificates;
267274
}
268275

269-
/** @return Resource collection API of IotHubs. */
276+
/**
277+
* @return Resource collection API of IotHubs.
278+
*/
270279
public IotHubs iotHubs() {
271280
if (this.iotHubs == null) {
272281
this.iotHubs = new IotHubsImpl(clientObject.getIotHubs(), this);
273282
}
274283
return iotHubs;
275284
}
276285

277-
/** @return Resource collection API of PrivateLinkResourcesOperations. */
286+
/**
287+
* @return Resource collection API of PrivateLinkResourcesOperations.
288+
*/
278289
public PrivateLinkResourcesOperations privateLinkResourcesOperations() {
279290
if (this.privateLinkResourcesOperations == null) {
280-
this.privateLinkResourcesOperations =
281-
new PrivateLinkResourcesOperationsImpl(clientObject.getPrivateLinkResourcesOperations(), this);
291+
this.privateLinkResourcesOperations = new PrivateLinkResourcesOperationsImpl(clientObject.getPrivateLinkResourcesOperations(), this);
282292
}
283293
return privateLinkResourcesOperations;
284294
}
285295

286-
/** @return Resource collection API of PrivateEndpointConnections. */
296+
/**
297+
* @return Resource collection API of PrivateEndpointConnections.
298+
*/
287299
public PrivateEndpointConnections privateEndpointConnections() {
288300
if (this.privateEndpointConnections == null) {
289-
this.privateEndpointConnections =
290-
new PrivateEndpointConnectionsImpl(clientObject.getPrivateEndpointConnections(), this);
301+
this.privateEndpointConnections = new PrivateEndpointConnectionsImpl(clientObject.getPrivateEndpointConnections(), this);
291302
}
292303
return privateEndpointConnections;
293304
}
294305

295306
/**
296-
* @return Wrapped service client IotHubClient providing direct access to the underlying auto-generated API
297-
* implementation, based on Azure REST API.
307+
* @return Wrapped service client IotHubClient providing direct access to the underlying auto-generated API implementation, based on Azure REST API.
298308
*/
299309
public IotHubClient serviceClient() {
300310
return this.clientObject;

0 commit comments

Comments
 (0)