Interface Roles
public interface Roles
Resource collection API of Roles.
-
Method Summary
Modifier and TypeMethodDescriptioncreateOrUpdate
(String deviceName, String name, String resourceGroupName, RoleInner role) Create or update a role.createOrUpdate
(String deviceName, String name, String resourceGroupName, RoleInner role, com.azure.core.util.Context context) Create or update a role.void
Deletes the role on the device.void
delete
(String deviceName, String name, String resourceGroupName, com.azure.core.util.Context context) Deletes the role on the device.Gets a specific role by name.com.azure.core.http.rest.Response<Role>
getWithResponse
(String deviceName, String name, String resourceGroupName, com.azure.core.util.Context context) Gets a specific role by name.com.azure.core.http.rest.PagedIterable<Role>
listByDataBoxEdgeDevice
(String deviceName, String resourceGroupName) Lists all the roles configured in a Data Box Edge/Data Box Gateway device.com.azure.core.http.rest.PagedIterable<Role>
listByDataBoxEdgeDevice
(String deviceName, String resourceGroupName, com.azure.core.util.Context context) Lists all the roles configured in a Data Box Edge/Data Box Gateway device.
-
Method Details
-
listByDataBoxEdgeDevice
com.azure.core.http.rest.PagedIterable<Role> listByDataBoxEdgeDevice(String deviceName, String resourceGroupName) Lists all the roles configured in a Data Box Edge/Data Box Gateway device.- Parameters:
deviceName
- The device name.resourceGroupName
- The resource group name.- Returns:
- collection of all the roles on the Data Box Edge device as paginated response with
PagedIterable
. - Throws:
IllegalArgumentException
- thrown if parameters fail the validation.com.azure.core.management.exception.ManagementException
- thrown if the request is rejected by server.RuntimeException
- all other wrapped checked exceptions if the request fails to be sent.
-
listByDataBoxEdgeDevice
com.azure.core.http.rest.PagedIterable<Role> listByDataBoxEdgeDevice(String deviceName, String resourceGroupName, com.azure.core.util.Context context) Lists all the roles configured in a Data Box Edge/Data Box Gateway device.- Parameters:
deviceName
- The device name.resourceGroupName
- The resource group name.context
- The context to associate with this operation.- Returns:
- collection of all the roles on the Data Box Edge device as paginated response with
PagedIterable
. - Throws:
IllegalArgumentException
- thrown if parameters fail the validation.com.azure.core.management.exception.ManagementException
- thrown if the request is rejected by server.RuntimeException
- all other wrapped checked exceptions if the request fails to be sent.
-
getWithResponse
com.azure.core.http.rest.Response<Role> getWithResponse(String deviceName, String name, String resourceGroupName, com.azure.core.util.Context context) Gets a specific role by name.- Parameters:
deviceName
- The device name.name
- The role name.resourceGroupName
- The resource group name.context
- The context to associate with this operation.- Returns:
- a specific role by name along with
Response
. - Throws:
IllegalArgumentException
- thrown if parameters fail the validation.com.azure.core.management.exception.ManagementException
- thrown if the request is rejected by server.RuntimeException
- all other wrapped checked exceptions if the request fails to be sent.
-
get
Gets a specific role by name.- Parameters:
deviceName
- The device name.name
- The role name.resourceGroupName
- The resource group name.- Returns:
- a specific role by name.
- Throws:
IllegalArgumentException
- thrown if parameters fail the validation.com.azure.core.management.exception.ManagementException
- thrown if the request is rejected by server.RuntimeException
- all other wrapped checked exceptions if the request fails to be sent.
-
createOrUpdate
Create or update a role.- Parameters:
deviceName
- The device name.name
- The role name.resourceGroupName
- The resource group name.role
- The role properties.- Returns:
- compute role.
- Throws:
IllegalArgumentException
- thrown if parameters fail the validation.com.azure.core.management.exception.ManagementException
- thrown if the request is rejected by server.RuntimeException
- all other wrapped checked exceptions if the request fails to be sent.
-
createOrUpdate
Role createOrUpdate(String deviceName, String name, String resourceGroupName, RoleInner role, com.azure.core.util.Context context) Create or update a role.- Parameters:
deviceName
- The device name.name
- The role name.resourceGroupName
- The resource group name.role
- The role properties.context
- The context to associate with this operation.- Returns:
- compute role.
- Throws:
IllegalArgumentException
- thrown if parameters fail the validation.com.azure.core.management.exception.ManagementException
- thrown if the request is rejected by server.RuntimeException
- all other wrapped checked exceptions if the request fails to be sent.
-
delete
Deletes the role on the device.- Parameters:
deviceName
- The device name.name
- The role name.resourceGroupName
- The resource group name.- Throws:
IllegalArgumentException
- thrown if parameters fail the validation.com.azure.core.management.exception.ManagementException
- thrown if the request is rejected by server.RuntimeException
- all other wrapped checked exceptions if the request fails to be sent.
-
delete
void delete(String deviceName, String name, String resourceGroupName, com.azure.core.util.Context context) Deletes the role on the device.- Parameters:
deviceName
- The device name.name
- The role name.resourceGroupName
- The resource group name.context
- The context to associate with this operation.- Throws:
IllegalArgumentException
- thrown if parameters fail the validation.com.azure.core.management.exception.ManagementException
- thrown if the request is rejected by server.RuntimeException
- all other wrapped checked exceptions if the request fails to be sent.
-