use of jakarta.xml.ws.handler.LogicalHandler in project metro-jax-ws by eclipse-ee4j.
the class ClientLogicalHandlerTube method setUpProcessor.
void setUpProcessor() {
if (handlers == null) {
// Take a snapshot, User may change chain after invocation, Same chain
// should be used for the entire MEP
handlers = new ArrayList<>();
WSBinding binding = getBinding();
List<LogicalHandler> logicalSnapShot = ((BindingImpl) binding).getHandlerConfig().getLogicalHandlers();
if (!logicalSnapShot.isEmpty()) {
handlers.addAll(logicalSnapShot);
if (binding.getSOAPVersion() == null) {
processor = new XMLHandlerProcessor(this, binding, handlers);
} else {
processor = new SOAPHandlerProcessor(true, this, binding, handlers);
}
}
}
}
use of jakarta.xml.ws.handler.LogicalHandler in project tomee by apache.
the class HandlerResolverImpl method sortHandlers.
/**
* sorts the handlers into correct order. All of the logical handlers first
* followed by the protocol handlers
*
* @param handlers
* @return sorted list of handlers
*/
private List<Handler> sortHandlers(final List<Handler> handlers) {
final List<LogicalHandler> logicalHandlers = new ArrayList<>();
final List<Handler> protocolHandlers = new ArrayList<>();
for (final Handler handler : handlers) {
if (handler instanceof LogicalHandler) {
logicalHandlers.add((LogicalHandler) handler);
} else {
protocolHandlers.add(handler);
}
}
final List<Handler> sortedHandlers = new ArrayList<>();
sortedHandlers.addAll(logicalHandlers);
sortedHandlers.addAll(protocolHandlers);
return sortedHandlers;
}
use of jakarta.xml.ws.handler.LogicalHandler in project tomee by apache.
the class ClientHandlerResolverImpl method sortHandlers.
/**
* sorts the handlers into correct order. All of the logical handlers first
* followed by the protocol handlers
*
* @param handlers List
* @return sorted list of handlers
*/
private List<Handler> sortHandlers(final List<Handler> handlers) {
final List<LogicalHandler> logicalHandlers = new ArrayList<LogicalHandler>();
final List<Handler> protocolHandlers = new ArrayList<Handler>();
for (final Handler handler : handlers) {
if (handler instanceof LogicalHandler) {
logicalHandlers.add((LogicalHandler) handler);
} else {
protocolHandlers.add(handler);
}
}
final List<Handler> sortedHandlers = new ArrayList<Handler>();
sortedHandlers.addAll(logicalHandlers);
sortedHandlers.addAll(protocolHandlers);
return sortedHandlers;
}
Aggregations