you can use rules in gateway conditions just to make sure that the rule evaluates to boolean value, for instance
<conditionExpression xsi:type="tFormalExpression" language="http://www.jboss.org/drools/rule" >org.jbpm.bpmn2.ScannerChangeSetTest.Message( message matches 'AND' )</conditionExpression>
Thank you for your help. I'll try this out.
What about my first question, is it possible to get a custom task with multiple output flows? I guess it requires changing of editor source code, which is not a problem for me, I just need some guidance where to start?
It could be only an eclipse editor limitation. According to BPMN2 spec activity can have both multiple incoming and outgoing sequence flows and in such case it is considered uncontrolled flow. For details look at 10.2 of BPMN2 spec.