org.apache.synapse.config.xml
Class URLRewriteMediatorFactory

java.lang.Object
  extended by org.apache.synapse.config.xml.AbstractMediatorFactory
      extended by org.apache.synapse.config.xml.URLRewriteMediatorFactory
All Implemented Interfaces:
MediatorFactory

public class URLRewriteMediatorFactory
extends AbstractMediatorFactory

Creates an instance of the URLRewriteMediator given an XML configuration which adheres to the following grammar.

  <rewrite [inProperty="inputURL"] [outProperty="outputURL"]>
      <rewriterule>
          <condition>
              evaluator configuration
          </condition> ?
          <action
              value="value"
              xpath="xpath"
              [type="set | append | prepend | replace | remove"]
              [fragment="protocol | user | host | port | path | query | ref | full"]
              [regex="regex"] /> +
      </rewriterule> *
  </rewrite>
 


Field Summary
static String ACTION_APPEND
           
static String ACTION_PREPEND
           
static String ACTION_REMOVE
           
static String ACTION_REPLACE
           
static String ACTION_SET
           
static String FRAGMENT_FULL_URI
           
static String FRAGMENT_HOST
           
static String FRAGMENT_PATH
           
static String FRAGMENT_PORT
           
static String FRAGMENT_PROTOCOL
           
static String FRAGMENT_QUERY
           
static String FRAGMENT_REF
           
static String FRAGMENT_USER_INFO
           
 
Fields inherited from class org.apache.synapse.config.xml.AbstractMediatorFactory
ATT_EXPRN, ATT_KEY, ATT_NAME, ATT_ONERROR, ATT_REGEX, ATT_SEQUENCE, ATT_SOURCE, ATT_STATS, ATT_TARGET, ATT_VALUE, ATT_XPATH, DESCRIPTION_Q, FEATURE_Q, PROP_Q, TARGET_Q
 
Constructor Summary
URLRewriteMediatorFactory()
           
 
Method Summary
protected  Mediator createSpecificMediator(OMElement element, Properties properties)
          Specific mediator factory implementations should implement this method to build the Mediator by the given XML configuration
 QName getTagQName()
          The QName of this mediator element in the XML config
 
Methods inherited from class org.apache.synapse.config.xml.AbstractMediatorFactory
collectNameValuePairs, createMediator, handleException, handleException, processAuditStatus, processTraceState
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ACTION_SET

public static final String ACTION_SET
See Also:
Constant Field Values

ACTION_APPEND

public static final String ACTION_APPEND
See Also:
Constant Field Values

ACTION_PREPEND

public static final String ACTION_PREPEND
See Also:
Constant Field Values

ACTION_REPLACE

public static final String ACTION_REPLACE
See Also:
Constant Field Values

ACTION_REMOVE

public static final String ACTION_REMOVE
See Also:
Constant Field Values

FRAGMENT_PROTOCOL

public static final String FRAGMENT_PROTOCOL
See Also:
Constant Field Values

FRAGMENT_USER_INFO

public static final String FRAGMENT_USER_INFO
See Also:
Constant Field Values

FRAGMENT_HOST

public static final String FRAGMENT_HOST
See Also:
Constant Field Values

FRAGMENT_PORT

public static final String FRAGMENT_PORT
See Also:
Constant Field Values

FRAGMENT_PATH

public static final String FRAGMENT_PATH
See Also:
Constant Field Values

FRAGMENT_QUERY

public static final String FRAGMENT_QUERY
See Also:
Constant Field Values

FRAGMENT_REF

public static final String FRAGMENT_REF
See Also:
Constant Field Values

FRAGMENT_FULL_URI

public static final String FRAGMENT_FULL_URI
See Also:
Constant Field Values
Constructor Detail

URLRewriteMediatorFactory

public URLRewriteMediatorFactory()
Method Detail

createSpecificMediator

protected Mediator createSpecificMediator(OMElement element,
                                          Properties properties)
Description copied from class: AbstractMediatorFactory
Specific mediator factory implementations should implement this method to build the Mediator by the given XML configuration

Specified by:
createSpecificMediator in class AbstractMediatorFactory
Parameters:
element - configuration element describing the properties of the mediator
properties - bag of properties to pass in any information to the factory
Returns:
built mediator of that specific type

getTagQName

public QName getTagQName()
Description copied from interface: MediatorFactory
The QName of this mediator element in the XML config

Returns:
QName of the mediator element


Copyright © 2005-2012 Apache Software Foundation. All Rights Reserved.