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 sdk/cosmos/mgmt-v2020_06_01_preview] [CosmosDB] Fixing gaps in the new apiVersion #5797

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
4 changes: 2 additions & 2 deletions sdk/cosmos/mgmt-v2020_06_01_preview/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
<parent>
<groupId>com.microsoft.azure</groupId>
<artifactId>azure-arm-parent</artifactId>
<version>1.3.2</version>
<relativePath>../../parents/azure-arm-parent/pom.xml</relativePath>
<version>1.1.0</version>
<relativePath>../../../pom.management.xml</relativePath>
</parent>
<artifactId>azure-mgmt-cosmosdb</artifactId>
<version>1.0.0-beta</version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
import com.microsoft.azure.ProxyResource;

/**
* The resource model definition for a Azure Resource Manager resource with an
* Entity Resource.
* The resource model definition for an Azure Resource Manager resource with an
* etag.
*/
public class AzureEntityResource extends ProxyResource {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,152 @@
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/

package com.microsoft.azure.management.cosmosdb.v2020_06_01_preview;

import com.fasterxml.jackson.annotation.JsonProperty;

/**
* The CORS policy for the Cosmos DB database account.
*/
public class CorsPolicy {
/**
* The origin domains that are permitted to make a request against the
* service via CORS.
*/
@JsonProperty(value = "allowedOrigins", required = true)
private String allowedOrigins;

/**
* The methods (HTTP request verbs) that the origin domain may use for a
* CORS request.
*/
@JsonProperty(value = "allowedMethods")
private String allowedMethods;

/**
* The request headers that the origin domain may specify on the CORS
* request.
*/
@JsonProperty(value = "allowedHeaders")
private String allowedHeaders;

/**
* The response headers that may be sent in the response to the CORS
* request and exposed by the browser to the request issuer.
*/
@JsonProperty(value = "exposedHeaders")
private String exposedHeaders;

/**
* The maximum amount time that a browser should cache the preflight
* OPTIONS request.
*/
@JsonProperty(value = "maxAgeInSeconds")
private Long maxAgeInSeconds;

/**
* Get the origin domains that are permitted to make a request against the service via CORS.
*
* @return the allowedOrigins value
*/
public String allowedOrigins() {
return this.allowedOrigins;
}

/**
* Set the origin domains that are permitted to make a request against the service via CORS.
*
* @param allowedOrigins the allowedOrigins value to set
* @return the CorsPolicy object itself.
*/
public CorsPolicy withAllowedOrigins(String allowedOrigins) {
this.allowedOrigins = allowedOrigins;
return this;
}

/**
* Get the methods (HTTP request verbs) that the origin domain may use for a CORS request.
*
* @return the allowedMethods value
*/
public String allowedMethods() {
return this.allowedMethods;
}

/**
* Set the methods (HTTP request verbs) that the origin domain may use for a CORS request.
*
* @param allowedMethods the allowedMethods value to set
* @return the CorsPolicy object itself.
*/
public CorsPolicy withAllowedMethods(String allowedMethods) {
this.allowedMethods = allowedMethods;
return this;
}

/**
* Get the request headers that the origin domain may specify on the CORS request.
*
* @return the allowedHeaders value
*/
public String allowedHeaders() {
return this.allowedHeaders;
}

/**
* Set the request headers that the origin domain may specify on the CORS request.
*
* @param allowedHeaders the allowedHeaders value to set
* @return the CorsPolicy object itself.
*/
public CorsPolicy withAllowedHeaders(String allowedHeaders) {
this.allowedHeaders = allowedHeaders;
return this;
}

/**
* Get the response headers that may be sent in the response to the CORS request and exposed by the browser to the request issuer.
*
* @return the exposedHeaders value
*/
public String exposedHeaders() {
return this.exposedHeaders;
}

/**
* Set the response headers that may be sent in the response to the CORS request and exposed by the browser to the request issuer.
*
* @param exposedHeaders the exposedHeaders value to set
* @return the CorsPolicy object itself.
*/
public CorsPolicy withExposedHeaders(String exposedHeaders) {
this.exposedHeaders = exposedHeaders;
return this;
}

/**
* Get the maximum amount time that a browser should cache the preflight OPTIONS request.
*
* @return the maxAgeInSeconds value
*/
public Long maxAgeInSeconds() {
return this.maxAgeInSeconds;
}

/**
* Set the maximum amount time that a browser should cache the preflight OPTIONS request.
*
* @param maxAgeInSeconds the maxAgeInSeconds value to set
* @return the CorsPolicy object itself.
*/
public CorsPolicy withMaxAgeInSeconds(Long maxAgeInSeconds) {
this.maxAgeInSeconds = maxAgeInSeconds;
return this;
}

}
Loading