|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.norther.tammi.core.base.Adaptee org.norther.tammi.spray.filter.DefaultFilter org.norther.tammi.spray.protocol.DefaultHttpRelayFilter
public class DefaultHttpRelayFilter
A default implementation of HttpRelayFilter.
Field Summary |
---|
Fields inherited from class org.norther.tammi.core.base.Adaptee |
---|
ADAPTEE_NOTIF_DESCRIPTION, ADAPTEE_NOTIFICATIONS |
Constructor Summary | |
---|---|
DefaultHttpRelayFilter()
Constructs a new filter. |
Method Summary | |
---|---|
void |
addProperty(int index,
String key,
String value)
Inserts a multivalued property at the specified index. |
void |
addProperty(String key,
String value)
Adds a multivalued property. |
void |
addPropertyFilePath(String path)
Adds a property file path. |
void |
addPropertyFilePath(String path,
String encoding)
Adds a property file path with an encoding. |
void |
clearProperties()
Clears all properties. |
boolean |
containsProperty(String key)
Checks whether a property is defined. |
void |
doFilter(ServletRequest request,
ServletResponse response,
FilterChain chain)
|
String |
getConfigKey()
Gets the path finder key for resolving configuration paths. |
String[] |
getProperties(String key)
Gets a multivalued property. |
String |
getProperty(String key)
Gets a property. |
String |
getPropertyFilePath()
Gets the property file path. |
String[] |
getPropertyFilePaths()
Gets the property file paths. |
int |
indexOfProperty(String key,
String value)
Returns the index of a multivalued property value. |
protected String |
normalize(String uri)
Normalizes the specified URI. |
OrderedMap<String,Object> |
propertyMap()
Returns a map of properties. |
OrderedMap<String,Object> |
propertyMap(String prefix)
Returns a map of prefixed properties. |
Object |
removeProperty(String key)
Removes a property. |
boolean |
removeProperty(String key,
String value)
Removes a multivalued property. |
void |
removePropertyFilePath(String path)
Removes a property file path. |
void |
setConfigKey(String key)
Sets the path finder key for resolving configuration paths. |
Object |
setProperties(String key,
String[] values)
Sets a multivalued property. |
Object |
setProperty(String key,
String value)
Sets a property. |
void |
setPropertyFilePath(String path)
Sets the property file path. |
void |
setPropertyFilePath(String path,
String encoding)
Sets the property file path with an encoding. |
void |
setPropertyFilePaths(String[] paths)
Sets the property file paths. |
void |
setPropertyFilePaths(String[] paths,
String... encoding)
Sets the property file paths with encodings. |
void |
storeProperties()
Stores properties to the property file. |
Methods inherited from class org.norther.tammi.spray.filter.DefaultFilter |
---|
destroy, getFilterConfig, getRequestMap, getSessionMap, init |
Methods inherited from class org.norther.tammi.core.base.Adaptee |
---|
addAdaptee, addNotificationListener, getAttributeSupport, getBroker, getCanonicalName, getDomain, getFactory, getLoader, getLog, getLog, getMBean, getMBeanServer, getNotificationInfo, getObjectName, getRegistrationTime, getSequenceNumber, hasListeners, isRegistered, postmanaged, premanaged, removeNotificationListener, removeNotificationListener, sendNotification, sendNotification, sendNotification, sendNotification, unmanaged, unregister |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface javax.servlet.Filter |
---|
destroy, init |
Constructor Detail |
---|
public DefaultHttpRelayFilter()
Method Detail |
---|
public String getConfigKey()
Configurable
getConfigKey
in interface Configurable
public void setConfigKey(String key)
Configurable
setConfigKey
in interface Configurable
key
- the path finder key.public String getPropertyFilePath()
Configurable
getPropertyFilePath
in interface Configurable
public void setPropertyFilePath(String path)
Configurable
Note that all previously defined property file paths and properties are cleared.
setPropertyFilePath
in interface Configurable
path
- a property file path.public void setPropertyFilePath(String path, String encoding)
Configurable
setPropertyFilePath
in interface Configurable
path
- a property file path.encoding
- an encoding to use.public String[] getPropertyFilePaths()
Configurable
getPropertyFilePaths
in interface Configurable
public void setPropertyFilePaths(String[] paths)
Configurable
setPropertyFilePaths
in interface Configurable
paths
- property file paths.public void setPropertyFilePaths(String[] paths, String... encoding)
Configurable
setPropertyFilePaths
in interface Configurable
paths
- property file paths.encoding
- encodings to use.public void addPropertyFilePath(String path)
Configurable
addPropertyFilePath
in interface Configurable
path
- a property file path.public void addPropertyFilePath(String path, String encoding)
Configurable
addPropertyFilePath
in interface Configurable
path
- a property file path.encoding
- an encoding to use.public void removePropertyFilePath(String path)
Configurable
removePropertyFilePath
in interface Configurable
path
- the property file path.public boolean containsProperty(String key)
Configurable
containsProperty
in interface Configurable
key
- the key.
public String getProperty(String key)
Configurable
getProperty
in interface Configurable
key
- the key.
public Object setProperty(String key, String value)
Configurable
setProperty
in interface Configurable
key
- the key.value
- the value.
public String[] getProperties(String key)
Configurable
getProperties
in interface Configurable
key
- the key.
public Object setProperties(String key, String[] values)
Configurable
setProperties
in interface Configurable
key
- the key.values
- the values.
public Object removeProperty(String key)
Configurable
removeProperty
in interface Configurable
key
- the key.
public int indexOfProperty(String key, String value)
Configurable
indexOfProperty
in interface Configurable
key
- the key.value
- the value.
public void addProperty(String key, String value)
Configurable
addProperty
in interface Configurable
key
- the key.value
- the property.public void addProperty(int index, String key, String value)
Configurable
addProperty
in interface Configurable
index
- the index.key
- the key.value
- the value.public boolean removeProperty(String key, String value)
Configurable
removeProperty
in interface Configurable
key
- the key.value
- the value.
public void clearProperties()
Configurable
clearProperties
in interface Configurable
public OrderedMap<String,Object> propertyMap()
Configurable
propertyMap
in interface Configurable
public OrderedMap<String,Object> propertyMap(String prefix)
Configurable
propertyMap
in interface Configurable
prefix
- the prefix.
public void storeProperties() throws IOException
Configurable
storeProperties
in interface Configurable
IOException
- on I/O errors.public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws ServletException, IOException
doFilter
in interface Filter
doFilter
in class DefaultFilter
ServletException
IOException
protected String normalize(String uri)
uri
- the URI.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |