public class CorsRule extends Object
Constructor and Description |
---|
CorsRule() |
Modifier and Type | Method and Description |
---|---|
List<String> |
getAllowedHeaders()
Gets the allowed headers.
|
EnumSet<CorsHttpMethods> |
getAllowedMethods()
Gets the allowed methods.
|
List<String> |
getAllowedOrigins()
Gets the allowed origins.
|
List<String> |
getExposedHeaders()
Gets the exposed headers.
|
int |
getMaxAgeInSeconds()
Gets the maximum age in seconds.
|
void |
setAllowedHeaders(List<String> allowedHeaders)
Sets the allowed headers.
|
void |
setAllowedMethods(EnumSet<CorsHttpMethods> allowedMethods)
Sets the allowed methods.
|
void |
setAllowedOrigins(List<String> allowedOrigins)
Sets the allowed origins.
|
void |
setExposedHeaders(List<String> exposedHeaders)
Sets the exposed headers.
|
void |
setMaxAgeInSeconds(int maxAgeInSeconds)
Sets the maximum age in seconds.
|
public List<String> getAllowedOrigins()
List
object which contains the allowed origins.public void setAllowedOrigins(List<String> allowedOrigins)
allowedOrigins
- A List
object which contains the allowed origins.public List<String> getExposedHeaders()
List
object which contains the exposed headers.public void setExposedHeaders(List<String> exposedHeaders)
exposedHeaders
- A List
object which contains the exposed headers.public List<String> getAllowedHeaders()
List
object which contains the allowed headers.public void setAllowedHeaders(List<String> allowedHeaders)
allowedHeaders
- A List
object which contains the allowed headers.public EnumSet<CorsHttpMethods> getAllowedMethods()
List
object which contains the allowed methods.public void setAllowedMethods(EnumSet<CorsHttpMethods> allowedMethods)
allowedMethods
- A List
object which contains the allowed methods.public int getMaxAgeInSeconds()
int
which represents the the maximum age in seconds.public void setMaxAgeInSeconds(int maxAgeInSeconds)
maxAgeInSeconds
- An int
which represents the the maximum age in seconds./**
* Copyright Microsoft Corporation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/