InternalChannelRule
private static class NoInternalChannelPredicate implements Predicate {
/**
*
*/
public NoInternalChannelPredicate() {
super();
}
public boolean evaluate(Object obj) {
if(obj == null){
return false;
}
if(obj instanceof MessageEnvelope){
obj = ((MessageEnvelope)obj).getRequest();
}
if( obj instanceof SSHXMessage){
if(Internal_Channel_Name.equalsIgnoreCase(((SSHXMessage)obj).getChannel())){
return false;
}
}
return true;
}
}
LinkedList list = new LinkedList();
for(Iterator itr = new FilterListIterator(results.getResults().listIterator(),new NoInternalChannelPredicate()); itr.hasNext();){
list.add(itr.next());
}