Java Code Examples for com.microsoft.rest.ServiceFuture.fromResponse()

The following are Jave code examples for showing how to use fromResponse() of the com.microsoft.rest.ServiceFuture class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
+ Save this method
Example 1
Project: azure-libraries-for-java   File: MapsInner.java   View Source Code Vote up 2 votes
/**
 * Gets an integration account map.
 *
 * @param resourceGroupName The resource group name.
 * @param integrationAccountName The integration account name.
 * @param mapName The integration account map name.
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<IntegrationAccountMapInner> getAsync(String resourceGroupName, String integrationAccountName, String mapName, final ServiceCallback<IntegrationAccountMapInner> serviceCallback) {
    return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName), serviceCallback);
}
 
Example 2
Project: azure-libraries-for-java   File: LabsInner.java   View Source Code Vote up 2 votes
/**
 * Generate a URI for uploading custom disk images to a Lab.
 *
 * @param resourceGroupName The name of the resource group.
 * @param name The name of the lab.
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<GenerateUploadUriResponseInner> generateUploadUriAsync(String resourceGroupName, String name, final ServiceCallback<GenerateUploadUriResponseInner> serviceCallback) {
    return ServiceFuture.fromResponse(generateUploadUriWithServiceResponseAsync(resourceGroupName, name), serviceCallback);
}
 
Example 3
Project: azure-libraries-for-java   File: AlertRulesInner.java   View Source Code Vote up 2 votes
/**
 * Creates or updates an alert rule.
 Request method: PUT        Request URI: https://management.azure.com/subscriptions/{subscription-id}/resourceGroups/{resource-group-name}/providers/microsoft.insights/alertRules/{alert-rule-name}?api-version={api-version}.
 *
 * @param resourceGroupName The name of the resource group.
 * @param ruleName The name of the rule.
 * @param parameters The parameters of the rule to create or update.
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<AlertRuleResourceInner> createOrUpdateAsync(String resourceGroupName, String ruleName, AlertRuleResourceInner parameters, final ServiceCallback<AlertRuleResourceInner> serviceCallback) {
    return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroupName, ruleName, parameters), serviceCallback);
}
 
Example 4
Project: autorest.java   File: AutoRestResourceFlatteningTestServiceImpl.java   View Source Code Vote up 2 votes
/**
 * Get External Resource as a Dictionary.
 *
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<Map<String, FlattenedProduct>> getDictionaryAsync(final ServiceCallback<Map<String, FlattenedProduct>> serviceCallback) {
    return ServiceFuture.fromResponse(getDictionaryWithServiceResponseAsync(), serviceCallback);
}
 
Example 5
Project: azure-libraries-for-java   File: IntegrationAccountsInner.java   View Source Code Vote up 2 votes
/**
 * Deletes an integration account.
 *
 * @param resourceGroupName The resource group name.
 * @param integrationAccountName The integration account name.
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<Void> deleteAsync(String resourceGroupName, String integrationAccountName, final ServiceCallback<Void> serviceCallback) {
    return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName), serviceCallback);
}
 
Example 6
Project: azure-libraries-for-java   File: ApplicationGatewaysInner.java   View Source Code Vote up 2 votes
/**
 * Gets the backend health of the specified application gateway in a resource group.
 *
 * @param resourceGroupName The name of the resource group.
 * @param applicationGatewayName The name of the application gateway.
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<ApplicationGatewayBackendHealthInner> backendHealthAsync(String resourceGroupName, String applicationGatewayName, final ServiceCallback<ApplicationGatewayBackendHealthInner> serviceCallback) {
    return ServiceFuture.fromResponse(backendHealthWithServiceResponseAsync(resourceGroupName, applicationGatewayName), serviceCallback);
}
 
Example 7
Project: azure-libraries-for-java   File: LabsInner.java   View Source Code Vote up 2 votes
/**
 * Get lab.
 *
 * @param resourceGroupName The name of the resource group.
 * @param name The name of the lab.
 * @param expand Specify the $expand query. Example: 'properties($select=defaultStorageAccount)'
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<LabInner> getByResourceGroupAsync(String resourceGroupName, String name, String expand, final ServiceCallback<LabInner> serviceCallback) {
    return ServiceFuture.fromResponse(getByResourceGroupWithServiceResponseAsync(resourceGroupName, name, expand), serviceCallback);
}
 
Example 8
Project: autorest.java   File: QueriesImpl.java   View Source Code Vote up 2 votes
/**
 * Get null numeric value (no query parameter).
 *
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<Void> doubleNullAsync(final ServiceCallback<Void> serviceCallback) {
    return ServiceFuture.fromResponse(doubleNullWithServiceResponseAsync(), serviceCallback);
}
 
Example 9
Project: autorest.java   File: PathsImpl.java   View Source Code Vote up 2 votes
/**
 * Get ''.
 *
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<Void> stringEmptyAsync(final ServiceCallback<Void> serviceCallback) {
    return ServiceFuture.fromResponse(stringEmptyWithServiceResponseAsync(), serviceCallback);
}
 
Example 10
Project: azure-libraries-for-java   File: RouteTablesInner.java   View Source Code Vote up 2 votes
/**
 * Deletes the specified route table.
 *
 * @param resourceGroupName The name of the resource group.
 * @param routeTableName The name of the route table.
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<Void> deleteAsync(String resourceGroupName, String routeTableName, final ServiceCallback<Void> serviceCallback) {
    return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, routeTableName), serviceCallback);
}
 
Example 11
Project: azure-libraries-for-java   File: WorkspaceCollectionsInner.java   View Source Code Vote up 2 votes
/**
 * Regenerates the primary or secondary access key for the specified Power BI Workspace Collection.
 *
 * @param resourceGroupName Azure resource group
 * @param workspaceCollectionName Power BI Embedded Workspace Collection name
 * @param keyName Key name. Possible values include: 'key1', 'key2'
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<WorkspaceCollectionAccessKeysInner> regenerateKeyAsync(String resourceGroupName, String workspaceCollectionName, AccessKeyName keyName, final ServiceCallback<WorkspaceCollectionAccessKeysInner> serviceCallback) {
    return ServiceFuture.fromResponse(regenerateKeyWithServiceResponseAsync(resourceGroupName, workspaceCollectionName, keyName), serviceCallback);
}
 
Example 12
Project: azure-libraries-for-java   File: EndpointsInner.java   View Source Code Vote up 2 votes
/**
 * Pre-loads a content to CDN. Available for Verizon Profiles.
 *
 * @param resourceGroupName Name of the Resource group within the Azure subscription.
 * @param profileName Name of the CDN profile which is unique within the resource group.
 * @param endpointName Name of the endpoint under the profile which is unique globally.
 * @param contentPaths The path to the content to be loaded. Path should be a relative file URL of the origin.
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<Void> loadContentAsync(String resourceGroupName, String profileName, String endpointName, List<String> contentPaths, final ServiceCallback<Void> serviceCallback) {
    return ServiceFuture.fromResponse(loadContentWithServiceResponseAsync(resourceGroupName, profileName, endpointName, contentPaths), serviceCallback);
}
 
Example 13
Project: azure-libraries-for-java   File: AppServicePlansInner.java   View Source Code Vote up 2 votes
/**
 * Get a Virtual Network gateway.
 * Get a Virtual Network gateway.
 *
 * @param resourceGroupName Name of the resource group to which the resource belongs.
 * @param name Name of the App Service plan.
 * @param vnetName Name of the Virtual Network.
 * @param gatewayName Name of the gateway. Only the 'primary' gateway is supported.
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<VnetGatewayInner> getVnetGatewayAsync(String resourceGroupName, String name, String vnetName, String gatewayName, final ServiceCallback<VnetGatewayInner> serviceCallback) {
    return ServiceFuture.fromResponse(getVnetGatewayWithServiceResponseAsync(resourceGroupName, name, vnetName, gatewayName), serviceCallback);
}
 
Example 14
Project: azure-libraries-for-java   File: NetworkManagementClientImpl.java   View Source Code Vote up 2 votes
/**
 * Checks whether a domain name in the cloudapp.net zone is available for use.
 *
 * @param location The location of the domain name.
 * @param domainNameLabel The domain name to be verified. It must conform to the following regular expression: ^[a-z][a-z0-9-]{1,61}[a-z0-9]$.
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<DnsNameAvailabilityResultInner> checkDnsNameAvailabilityAsync(String location, String domainNameLabel, final ServiceCallback<DnsNameAvailabilityResultInner> serviceCallback) {
    return ServiceFuture.fromResponse(checkDnsNameAvailabilityWithServiceResponseAsync(location, domainNameLabel), serviceCallback);
}
 
Example 15
Project: autorest.java   File: LROSADsInner.java   View Source Code Vote up 2 votes
/**
 * Long running put request, service returns a 201 to the initial request with no payload.
 *
 * @param product Product to put
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<ProductInner> putError201NoProvisioningStatePayloadAsync(ProductInner product, final ServiceCallback<ProductInner> serviceCallback) {
    return ServiceFuture.fromResponse(putError201NoProvisioningStatePayloadWithServiceResponseAsync(product), serviceCallback);
}
 
Example 16
Project: azure-libraries-for-java   File: FirewallRulesImpl.java   View Source Code Vote up 2 votes
/**
 * Deletes the specified firewall rule from the specified Data Lake Store account.
 *
 * @param resourceGroupName The name of the Azure resource group that contains the Data Lake Store account.
 * @param accountName The name of the Data Lake Store account from which to delete the firewall rule.
 * @param firewallRuleName The name of the firewall rule to delete.
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<Void> deleteAsync(String resourceGroupName, String accountName, String firewallRuleName, final ServiceCallback<Void> serviceCallback) {
    return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, accountName, firewallRuleName), serviceCallback);
}
 
Example 17
Project: azure-libraries-for-java   File: VirtualMachineExtensionsInner.java   View Source Code Vote up 2 votes
/**
 * The operation to get the extension.
 *
 * @param resourceGroupName The name of the resource group.
 * @param vmName The name of the virtual machine containing the extension.
 * @param vmExtensionName The name of the virtual machine extension.
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<VirtualMachineExtensionInner> getAsync(String resourceGroupName, String vmName, String vmExtensionName, final ServiceCallback<VirtualMachineExtensionInner> serviceCallback) {
    return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, vmName, vmExtensionName), serviceCallback);
}
 
Example 18
Project: autorest.java   File: PrimitivesImpl.java   View Source Code Vote up 2 votes
/**
 * Get complex types with bool properties.
 *
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<BooleanWrapper> getBoolAsync(final ServiceCallback<BooleanWrapper> serviceCallback) {
    return ServiceFuture.fromResponse(getBoolWithServiceResponseAsync(), serviceCallback);
}
 
Example 19
Project: autorest.java   File: LROsInner.java   View Source Code Vote up 2 votes
/**
 * Long running put request with sub resource.
 *
 * @param product Sub Product to put
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<SubProductInner> putAsyncSubResourceAsync(SubProductInner product, final ServiceCallback<SubProductInner> serviceCallback) {
    return ServiceFuture.fromResponse(putAsyncSubResourceWithServiceResponseAsync(product), serviceCallback);
}
 
Example 20
Project: azure-libraries-for-java   File: NamespacesInner.java   View Source Code Vote up 2 votes
/**
 * Check the give Namespace name availability.
 *
 * @param name Name to check the namespace name availability
 * @param serviceCallback the async ServiceCallback to handle successful and failed responses.
 * @throws IllegalArgumentException thrown if parameters fail the validation
 * @return the {@link ServiceFuture} object
 */
public ServiceFuture<CheckNameAvailabilityResultInner> checkNameAvailabilityAsync(String name, final ServiceCallback<CheckNameAvailabilityResultInner> serviceCallback) {
    return ServiceFuture.fromResponse(checkNameAvailabilityWithServiceResponseAsync(name), serviceCallback);
}