@Generated(value="OracleSDKGenerator", comments="API Version: 20170115") public final class RedirectRule extends Rule
An object that represents the action of returning a specified response code and a redirect URI. Each RedirectRule object is configured for a particular listener and a designated path.
The default response code is 302 Found
.
*NOTES:** * This rule applies only to HTTP listeners. * You can specify this rule only with
the ruleCondition
type PATH
. * A listener
can have only one RedirectRule object for a given original path. The pathMatchCondition
attributeValue
specifies the original path.
Note: Objects should always be created or deserialized using the RedirectRule.Builder
. This model
distinguishes fields that are null
because they are unset from fields that are explicitly
set to null
. This is done in the setter methods of the RedirectRule.Builder
, which maintain a
set of all explicitly set fields called RedirectRule.Builder.__explicitlySet__
. The hashCode()
and equals(Object)
methods are implemented to take the explicitly set
fields into account. The constructor, on the other hand, does not take the explicitly set fields
into account (since the constructor cannot distinguish explicit null
from unset null
).
Modifier and Type | Class and Description |
---|---|
static class |
RedirectRule.Builder |
Rule.Action
EXPLICITLY_SET_FILTER_NAME, EXPLICITLY_SET_PROPERTY_NAME
Constructor and Description |
---|
RedirectRule(Integer responseCode,
List<RuleCondition> conditions,
RedirectUri redirectUri)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
static RedirectRule.Builder |
builder()
Create a new builder.
|
boolean |
equals(Object o) |
List<RuleCondition> |
getConditions() |
RedirectUri |
getRedirectUri() |
Integer |
getResponseCode()
The HTTP status code to return when the incoming request is redirected.
|
int |
hashCode() |
RedirectRule.Builder |
toBuilder() |
String |
toString() |
String |
toString(boolean includeByteArrayContents)
Return a string representation of the object.
|
markPropertyAsExplicitlySet, wasPropertyExplicitlySet
@Deprecated public RedirectRule(Integer responseCode, List<RuleCondition> conditions, RedirectUri redirectUri)
public static RedirectRule.Builder builder()
Create a new builder.
public RedirectRule.Builder toBuilder()
public Integer getResponseCode()
The HTTP status code to return when the incoming request is redirected.
The status line returned with the code is mapped from the standard HTTP specification. Valid response codes for redirection are:
301 * 302 * 303 * 307 * 308
The default value is 302
(Found).
Example: 301
public List<RuleCondition> getConditions()
public RedirectUri getRedirectUri()
public String toString(boolean includeByteArrayContents)
Return a string representation of the object.
Copyright © 2016–2024. All rights reserved.