|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.servicemix.eip.support.SwitchPredicate
public class SwitchPredicate
Switch (on/off) predicate based on a property that can come from a system property, a property from a property file (specified as Spring resource), or a property from the exchange.
The property is interpreted as a boolean value.
| Constructor Summary | |
|---|---|
SwitchPredicate()
|
|
| Method Summary | |
|---|---|
void |
afterPropertiesSet()
|
void |
createResource(java.lang.String resource)
|
boolean |
getFromExchange()
|
java.lang.String |
getPropertyName()
|
org.springframework.core.io.Resource |
getPropertyResource()
|
boolean |
isOn()
|
boolean |
matches(javax.jbi.messaging.MessageExchange exchange)
|
void |
setFromExchange(boolean fromExchange)
Boolean flag indicating that the value is retrieved from the exchange properties. |
void |
setOn(boolean status)
Default value of this predicate |
void |
setPropertyName(java.lang.String newPropertyName)
The name of the property to retrieve |
void |
setPropertyResource(org.springframework.core.io.Resource newPropertyResource)
A spring resource to load a set of properties from. |
java.lang.String |
showResource()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SwitchPredicate()
| Method Detail |
|---|
public void afterPropertiesSet()
throws java.lang.Exception
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBeanjava.lang.Exceptionpublic boolean isOn()
public void setOn(boolean status)
public java.lang.String getPropertyName()
public void setPropertyName(java.lang.String newPropertyName)
public org.springframework.core.io.Resource getPropertyResource()
public void setPropertyResource(org.springframework.core.io.Resource newPropertyResource)
public boolean getFromExchange()
public void setFromExchange(boolean fromExchange)
public void createResource(java.lang.String resource)
public java.lang.String showResource()
throws java.io.IOException
java.io.IOExceptionpublic boolean matches(javax.jbi.messaging.MessageExchange exchange)
matches in interface Predicate
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||