Package com.aspectran.core.context.rule
Class ResponseRule
- java.lang.Object
-
- com.aspectran.core.context.rule.ResponseRule
-
- All Implemented Interfaces:
Replicable<ResponseRule>
,ResponseRuleApplicable
public class ResponseRule extends java.lang.Object implements ResponseRuleApplicable, Replicable<ResponseRule>
The Class ResponseRule.Created: 2008. 03. 22 PM 5:48:09
-
-
Constructor Summary
Constructors Constructor Description ResponseRule()
Instantiates a new ResponseRule.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Response
applyResponseRule(DispatchResponseRule dispatchResponseRule)
Apply the dispatch response rule to the response rule.Response
applyResponseRule(ForwardResponseRule forwardResponseRule)
Apply the forward response rule to the response rule.Response
applyResponseRule(RedirectResponseRule redirectResponseRule)
Apply the redirect response rule to the response rule.Response
applyResponseRule(TransformRule transformRule)
Apply the transform response rule to the response rule.java.lang.String
getEncoding()
Gets the response encoding.java.lang.String
getName()
<T> T
getRespondent()
Response
getResponse()
ResponseType
getResponseType()
static ResponseRule
newInstance(DispatchResponseRule drr)
static ResponseRule
newInstance(ForwardResponseRule frr)
static ResponseRule
newInstance(RedirectResponseRule rrr)
static ResponseRule
newInstance(TransformRule tr)
static ResponseRule
newInstance(java.lang.String name, java.lang.String encoding)
ResponseRule
replicate()
Creates and returns a new instance after replicating a rule or Object.static ResponseRule
replicate(ResponseRule responseRule)
void
setEncoding(java.lang.String encoding)
Sets the response encoding.void
setName(java.lang.String name)
void
setResponse(Response response)
java.lang.String
toString()
-
-
-
Method Detail
-
getName
public java.lang.String getName()
-
setName
public void setName(java.lang.String name)
-
getEncoding
public java.lang.String getEncoding()
Gets the response encoding.- Returns:
- the response encoding
-
setEncoding
public void setEncoding(java.lang.String encoding)
Sets the response encoding.- Parameters:
encoding
- the new response encoding
-
getResponse
public Response getResponse()
-
setResponse
public void setResponse(Response response)
-
getResponseType
public ResponseType getResponseType()
-
getRespondent
public <T> T getRespondent()
-
applyResponseRule
public Response applyResponseRule(DispatchResponseRule dispatchResponseRule)
Description copied from interface:ResponseRuleApplicable
Apply the dispatch response rule to the response rule.- Specified by:
applyResponseRule
in interfaceResponseRuleApplicable
- Parameters:
dispatchResponseRule
- the dispatch response rule- Returns:
- the response
-
applyResponseRule
public Response applyResponseRule(TransformRule transformRule)
Description copied from interface:ResponseRuleApplicable
Apply the transform response rule to the response rule.- Specified by:
applyResponseRule
in interfaceResponseRuleApplicable
- Parameters:
transformRule
- the transform rule- Returns:
- the response
-
applyResponseRule
public Response applyResponseRule(ForwardResponseRule forwardResponseRule)
Description copied from interface:ResponseRuleApplicable
Apply the forward response rule to the response rule.- Specified by:
applyResponseRule
in interfaceResponseRuleApplicable
- Parameters:
forwardResponseRule
- the forward response rule- Returns:
- the response
-
applyResponseRule
public Response applyResponseRule(RedirectResponseRule redirectResponseRule)
Description copied from interface:ResponseRuleApplicable
Apply the redirect response rule to the response rule.- Specified by:
applyResponseRule
in interfaceResponseRuleApplicable
- Parameters:
redirectResponseRule
- the redirect response rule- Returns:
- the response
-
replicate
public ResponseRule replicate()
Description copied from interface:Replicable
Creates and returns a new instance after replicating a rule or Object.- Specified by:
replicate
in interfaceReplicable<ResponseRule>
- Returns:
- replicated rule or new instance of Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
newInstance
public static ResponseRule newInstance(java.lang.String name, java.lang.String encoding) throws IllegalRuleException
- Throws:
IllegalRuleException
-
newInstance
public static ResponseRule newInstance(DispatchResponseRule drr)
-
newInstance
public static ResponseRule newInstance(TransformRule tr)
-
newInstance
public static ResponseRule newInstance(ForwardResponseRule frr)
-
newInstance
public static ResponseRule newInstance(RedirectResponseRule rrr)
-
replicate
public static ResponseRule replicate(ResponseRule responseRule)
-
-