public static class UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditions
extends com.aliyun.tea.TeaModel
限定符和类型 | 字段和说明 |
---|---|
UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditionsHostConfig |
hostConfig
The domain name configuration.
|
UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditionsPathConfig |
pathConfig
The path configuration.
|
String |
ruleConditionType
The type of the forwarding condition.
|
String |
ruleConditionValue
The value of the forwarding condition.
|
构造器和说明 |
---|
UpdateForwardingRulesRequestForwardingRulesRuleConditions() |
@NameInMap(value="HostConfig") public UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditionsHostConfig hostConfig
The domain name configuration.
> We recommend that you use **RuleConditionType** and **RuleConditionValue** rather than this parameter to configure forwarding conditions.
@NameInMap(value="PathConfig") public UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditionsPathConfig pathConfig
The path configuration.
> We recommend that you use **RuleConditionType** and **RuleConditionValue** rather than this parameter to configure forwarding conditions.
@NameInMap(value="RuleConditionType") public String ruleConditionType
The type of the forwarding condition. Valid values:
* **Host**: Requests are forwarded based on domain names.
* **Path**: Requests are forwarded based on paths.
* **RequestHeader**: Requests are forwarded based on HTTP headers.
* **Query**: Requests are forwarded based on query strings.
* **Method**: Requests are forwarded based on HTTP request methods.
* **Cookie**: Requests are forwarded based on cookies.
* **SourceIP**: Requests are forwarded based on source IP addresses.
@NameInMap(value="RuleConditionValue") public String ruleConditionValue
The value of the forwarding condition. You must specify different JSON strings based on the value of **RuleConditionType**.
* If you set **RuleConditionType** to **Host**, this parameter specifies a domain name condition. A forwarding rule can contain only one forwarding condition of the Host type. You can specify multiple domain names in a forwarding condition. The relationship between multiple domain names is OR. The domain name must be 3 to 128 characters in length and can contain letters, digits, hyphens (-), and periods (.). Supported wildcard characters are asterisks (\*) and question marks (?). Example: `["www.example.com", "www.aliyun.com"]`.
* If **RuleConditionType** is set to **Path**, this parameter specifies a path condition. A forwarding rule can contain multiple forwarding conditions of the Path type. The relationship between multiple path conditions is OR. You can specify multiple paths in a forwarding condition. The relationship between multiple paths is OR. The path must be 1 to 128 characters in length, and must start with a forward slash (/). The path can contain letters, digits, and the following special characters: $ - \_ . + / & ~ @ : \". Supported wildcard characters are asterisks (\*) and question marks (?). Example: `["/a", "/b/"]`.
* If you set **RuleConditionType** to **RequestHeader**, this parameter specifies an HTTP header condition that consists of key-value pairs. The header values in a forwarding condition must be unique. Example: `[{"header1":["value1","value2"]}]`.
* Key: The key of an HTTP header must be 1 to 40 characters in length, and can contain letters, digits, hyphens (-), and underscores (\_).
* Value: The value of an HTTP header must be 1 to 128 characters in length, and can contain printable characters whose ASCII values are `greater than or equal to 32 and less than 127`. The value cannot start or end with a space character.
* If you set **RuleConditionType** to **Query**, this parameter specifies a query string condition that consists of key-value pairs. Example: `[{"query1":["value1"]}, {"query2":["value2"]}]`.
* Key: The key of an HTTP header must be 1 to 100 characters in length, and can contain printable characters whose ASCII values are `greater than or equal to 32 and less than 127`. The key cannot contain uppercase letters, space characters, or the following special characters: `[ ] { } < > \ ; / ? : @ & = + , $ % | " ^ ~`.
* Value: The value of an HTTP header must be 1 to 128 characters in length, and can contain printable characters whose ASCII values are `greater than or equal to 32 and less than 127`. The value cannot contain uppercase letters, space characters, or the following special characters: `[ ] { } < > \ ; / ? : @ & = + , $ % | " ^ ~`.
* If you set **RuleConditionType** to **Method**, this parameter specifies an HTTP request method condition. Valid values: **HEAD**, **GET**, **POST**, **OPTIONS**, **PUT**, **PATCH**, and **DELETE**. Example: `["GET", "OPTIONS", "POST"]`.
* If you set **RuleConditionType** to **Cookie**, this parameter specifies a cookie condition that consists of key-value pairs. Example: `[{"cookie1":["value1"]}, {"cookie2":["value2"]}]`.
* Key: The key of a cookie must be 1 to 100 characters in length, and can contain printable characters whose ASCII values are `greater than or equal to 32 and less than 127`. The key cannot contain uppercase letters, space characters, or the following special characters: `# [ ] { } \ | < > &`.
* Value: The value of a cookie must be 1 to 128 characters in length, and can contain printable characters whose ASCII values are `greater than or equal to 32 and less than 127`. The value cannot contain uppercase letters, space characters, or the following special characters: `# [ ] { } \ | < > &`.
* If you set **RuleConditionType** to **SourceIP**, this parameter specifies a source IP address condition. You can specify IP addresses, such as 1.1.XX.XX/32. You can also specify CIDR blocks, such as 2.2.XX.XX/24. A forwarding rule can contain only one forwarding condition whose type is SourceIP. You can specify multiple source IP addresses in a forwarding condition. The relationship between multiple source IP addresses is OR. Example: `["1.1.XX.XX/32", "2.2.XX.XX/24"]`.
public UpdateForwardingRulesRequestForwardingRulesRuleConditions()
public static UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditions build(Map<String,?> map) throws Exception
Exception
public UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditions setHostConfig(UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditionsHostConfig hostConfig)
public UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditionsHostConfig getHostConfig()
public UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditions setPathConfig(UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditionsPathConfig pathConfig)
public UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditionsPathConfig getPathConfig()
public UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditions setRuleConditionType(String ruleConditionType)
public String getRuleConditionType()
public UpdateForwardingRulesRequest.UpdateForwardingRulesRequestForwardingRulesRuleConditions setRuleConditionValue(String ruleConditionValue)
public String getRuleConditionValue()
Copyright © 2024. All rights reserved.