if (ruleFlowGroup == null || "".equals(ruleFlowGroup)) {
errors.add( new ProcessValidationErrorImpl(process,
"RuleSet node '" + node.getName() + "' [" + node.getId() + "] has no ruleflow-group."));
}
} else if (node instanceof Split) {
final Split split = (Split) node;
if (split.getType() == Split.TYPE_UNDEFINED) {
errors.add(new ProcessValidationErrorImpl(process,
"Split node '" + node.getName() + "' [" + node.getId() + "] has no type."));
}
if (split.getFrom() == null) {
errors.add(new ProcessValidationErrorImpl(process,
"Split node '" + node.getName() + "' [" + node.getId() + "] has no incoming connection."));
}
if (split.getDefaultOutgoingConnections().size() < 2) {
errors.add(new ProcessValidationErrorImpl(process,
"Split node '" + node.getName() + "' [" + node.getId() + "] does not have more than one outgoing connection: " + split.getOutgoingConnections().size() + "."));
}
if (split.getType() == Split.TYPE_XOR || split.getType() == Split.TYPE_OR ) {
for ( final Iterator<Connection> it = split.getDefaultOutgoingConnections().iterator(); it.hasNext(); ) {
final Connection connection = it.next();
if (split.getConstraint(connection) == null) {
errors.add(new ProcessValidationErrorImpl(process,
"Split node '" + node.getName() + "' [" + node.getId() + "] does not have a constraint for " + connection.toString() + "."));
}
}
}