Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR azure-resourcemanager-iotcentral] Add batch tag 10/14 #11155

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion sdk/iotcentral/azure-resourcemanager-iotcentral/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# Release History

## 1.0.0-beta.2 (Unreleased)
## 1.0.0-beta.1 (2021-10-14)

- Azure Resource Manager IotCentral client library for Java. This package contains Microsoft Azure SDK for IotCentral Management SDK. Use this API to manage IoT Central Applications in your Azure subscription. Package tag package-2021-06. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).

## 1.0.0-beta.1 (2021-04-22)

Expand Down
7 changes: 5 additions & 2 deletions sdk/iotcentral/azure-resourcemanager-iotcentral/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Azure Resource Manager IotCentral client library for Java.

This package contains Microsoft Azure SDK for IotCentral Management SDK. Use this API to manage IoT Central Applications in your Azure subscription. Package tag package-2018-09-01. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
This package contains Microsoft Azure SDK for IotCentral Management SDK. Use this API to manage IoT Central Applications in your Azure subscription. Package tag package-2021-06. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).

## We'd love to hear your feedback

Expand Down Expand Up @@ -32,7 +32,7 @@ Various documentation is available to help you get started
<dependency>
<groupId>com.azure.resourcemanager</groupId>
<artifactId>azure-resourcemanager-iotcentral</artifactId>
<version>1.0.0-beta.1</version>
<version>1.0.0-beta.2</version>
</dependency>
```
[//]: # ({x-version-update-end})
Expand Down Expand Up @@ -74,6 +74,9 @@ See [API design][design] for general introduction on design and key concepts on

## Examples

[Code snippets and samples](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/iotcentral/azure-resourcemanager-iotcentral/SAMPLE.md)


## Troubleshooting

## Next steps
Expand Down
260 changes: 260 additions & 0 deletions sdk/iotcentral/azure-resourcemanager-iotcentral/SAMPLE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,260 @@
# Code snippets and samples


## Apps

- [CheckNameAvailability](#apps_checknameavailability)
- [CheckSubdomainAvailability](#apps_checksubdomainavailability)
- [CreateOrUpdate](#apps_createorupdate)
- [Delete](#apps_delete)
- [GetByResourceGroup](#apps_getbyresourcegroup)
- [List](#apps_list)
- [ListByResourceGroup](#apps_listbyresourcegroup)
- [ListTemplates](#apps_listtemplates)
- [Update](#apps_update)

## Operations

- [List](#operations_list)
### Apps_CheckNameAvailability

```java
import com.azure.core.util.Context;
import com.azure.resourcemanager.iotcentral.models.OperationInputs;

/** Samples for Apps CheckNameAvailability. */
public final class AppsCheckNameAvailabilitySamples {
/*
* x-ms-original-file: specification/iotcentral/resource-manager/Microsoft.IoTCentral/stable/2021-06-01/examples/Apps_CheckNameAvailability.json
*/
/**
* Sample code: Apps_CheckNameAvailability.
*
* @param manager Entry point to IotCentralManager.
*/
public static void appsCheckNameAvailability(com.azure.resourcemanager.iotcentral.IotCentralManager manager) {
manager
.apps()
.checkNameAvailabilityWithResponse(
new OperationInputs().withName("myiotcentralapp").withType("IoTApps"), Context.NONE);
}
}
```

### Apps_CheckSubdomainAvailability

```java
import com.azure.core.util.Context;
import com.azure.resourcemanager.iotcentral.models.OperationInputs;

/** Samples for Apps CheckSubdomainAvailability. */
public final class AppsCheckSubdomainAvailabilitySamples {
/*
* x-ms-original-file: specification/iotcentral/resource-manager/Microsoft.IoTCentral/stable/2021-06-01/examples/Apps_CheckSubdomainAvailability.json
*/
/**
* Sample code: Apps_SubdomainAvailability.
*
* @param manager Entry point to IotCentralManager.
*/
public static void appsSubdomainAvailability(com.azure.resourcemanager.iotcentral.IotCentralManager manager) {
manager
.apps()
.checkSubdomainAvailabilityWithResponse(
new OperationInputs().withName("myiotcentralapp").withType("IoTApps"), Context.NONE);
}
}
```

### Apps_CreateOrUpdate

```java
import com.azure.resourcemanager.iotcentral.models.AppSku;
import com.azure.resourcemanager.iotcentral.models.AppSkuInfo;
import com.azure.resourcemanager.iotcentral.models.SystemAssignedServiceIdentity;
import com.azure.resourcemanager.iotcentral.models.SystemAssignedServiceIdentityType;

/** Samples for Apps CreateOrUpdate. */
public final class AppsCreateOrUpdateSamples {
/*
* x-ms-original-file: specification/iotcentral/resource-manager/Microsoft.IoTCentral/stable/2021-06-01/examples/Apps_CreateOrUpdate.json
*/
/**
* Sample code: Apps_CreateOrUpdate.
*
* @param manager Entry point to IotCentralManager.
*/
public static void appsCreateOrUpdate(com.azure.resourcemanager.iotcentral.IotCentralManager manager) {
manager
.apps()
.define("myIoTCentralApp")
.withRegion("westus")
.withExistingResourceGroup("resRg")
.withSku(new AppSkuInfo().withName(AppSku.ST2))
.withIdentity(
new SystemAssignedServiceIdentity().withType(SystemAssignedServiceIdentityType.SYSTEM_ASSIGNED))
.withDisplayName("My IoT Central App")
.withSubdomain("my-iot-central-app")
.withTemplate("iotc-pnp-preview@1.0.0")
.create();
}
}
```

### Apps_Delete

```java
import com.azure.core.util.Context;

/** Samples for Apps Delete. */
public final class AppsDeleteSamples {
/*
* x-ms-original-file: specification/iotcentral/resource-manager/Microsoft.IoTCentral/stable/2021-06-01/examples/Apps_Delete.json
*/
/**
* Sample code: Apps_Delete.
*
* @param manager Entry point to IotCentralManager.
*/
public static void appsDelete(com.azure.resourcemanager.iotcentral.IotCentralManager manager) {
manager.apps().delete("resRg", "myIoTCentralApp", Context.NONE);
}
}
```

### Apps_GetByResourceGroup

```java
import com.azure.core.util.Context;

/** Samples for Apps GetByResourceGroup. */
public final class AppsGetByResourceGroupSamples {
/*
* x-ms-original-file: specification/iotcentral/resource-manager/Microsoft.IoTCentral/stable/2021-06-01/examples/Apps_Get.json
*/
/**
* Sample code: Apps_Get.
*
* @param manager Entry point to IotCentralManager.
*/
public static void appsGet(com.azure.resourcemanager.iotcentral.IotCentralManager manager) {
manager.apps().getByResourceGroupWithResponse("resRg", "myIoTCentralApp", Context.NONE);
}
}
```

### Apps_List

```java
import com.azure.core.util.Context;

/** Samples for Apps List. */
public final class AppsListSamples {
/*
* x-ms-original-file: specification/iotcentral/resource-manager/Microsoft.IoTCentral/stable/2021-06-01/examples/Apps_ListBySubscription.json
*/
/**
* Sample code: Apps_ListBySubscription.
*
* @param manager Entry point to IotCentralManager.
*/
public static void appsListBySubscription(com.azure.resourcemanager.iotcentral.IotCentralManager manager) {
manager.apps().list(Context.NONE);
}
}
```

### Apps_ListByResourceGroup

```java
import com.azure.core.util.Context;

/** Samples for Apps ListByResourceGroup. */
public final class AppsListByResourceGroupSamples {
/*
* x-ms-original-file: specification/iotcentral/resource-manager/Microsoft.IoTCentral/stable/2021-06-01/examples/Apps_ListByResourceGroup.json
*/
/**
* Sample code: Apps_ListByResourceGroup.
*
* @param manager Entry point to IotCentralManager.
*/
public static void appsListByResourceGroup(com.azure.resourcemanager.iotcentral.IotCentralManager manager) {
manager.apps().listByResourceGroup("resRg", Context.NONE);
}
}
```

### Apps_ListTemplates

```java
import com.azure.core.util.Context;

/** Samples for Apps ListTemplates. */
public final class AppsListTemplatesSamples {
/*
* x-ms-original-file: specification/iotcentral/resource-manager/Microsoft.IoTCentral/stable/2021-06-01/examples/Apps_Templates.json
*/
/**
* Sample code: Apps_ListTemplates.
*
* @param manager Entry point to IotCentralManager.
*/
public static void appsListTemplates(com.azure.resourcemanager.iotcentral.IotCentralManager manager) {
manager.apps().listTemplates(Context.NONE);
}
}
```

### Apps_Update

```java
import com.azure.core.util.Context;
import com.azure.resourcemanager.iotcentral.models.App;
import com.azure.resourcemanager.iotcentral.models.SystemAssignedServiceIdentity;
import com.azure.resourcemanager.iotcentral.models.SystemAssignedServiceIdentityType;

/** Samples for Apps Update. */
public final class AppsUpdateSamples {
/*
* x-ms-original-file: specification/iotcentral/resource-manager/Microsoft.IoTCentral/stable/2021-06-01/examples/Apps_Update.json
*/
/**
* Sample code: Apps_Update.
*
* @param manager Entry point to IotCentralManager.
*/
public static void appsUpdate(com.azure.resourcemanager.iotcentral.IotCentralManager manager) {
App resource =
manager.apps().getByResourceGroupWithResponse("resRg", "myIoTCentralApp", Context.NONE).getValue();
resource
.update()
.withIdentity(
new SystemAssignedServiceIdentity().withType(SystemAssignedServiceIdentityType.SYSTEM_ASSIGNED))
.withDisplayName("My IoT Central App 2")
.apply();
}
}
```

### Operations_List

```java
import com.azure.core.util.Context;

/** Samples for Operations List. */
public final class OperationsListSamples {
/*
* x-ms-original-file: specification/iotcentral/resource-manager/Microsoft.IoTCentral/stable/2021-06-01/examples/Operations_List.json
*/
/**
* Sample code: Operations_List.
*
* @param manager Entry point to IotCentralManager.
*/
public static void operationsList(com.azure.resourcemanager.iotcentral.IotCentralManager manager) {
manager.operations().list(Context.NONE);
}
}
```

Loading