for (ProcessorType<?> type : types) {
if (type instanceof PolicyRef) {
policy = (PolicyRef) type;
} else if (policy != null) {
// the outputs should be moved to the policy
policy.addOutput(type);
}
}
// did we find a policy if so add replace it as the only output on the route
if (policy != null) {
route.clearOutput();