use of org.drools.compiler.lang.descr.ConnectiveDescr in project drools by kiegroup.
the class FieldConstraintHandler method start.
public Object start(final String uri, final String localName, final Attributes attrs, final ExtensibleXmlParser parser) throws SAXException {
parser.startElementBuilder(localName, attrs);
final String fieldName = attrs.getValue("field-name");
emptyAttributeCheck(localName, "field-name", fieldName, parser);
final ConnectiveDescr connective = new ConnectiveDescr(RestrictionConnectiveType.AND);
connective.setParen(false);
connective.setPrefix(fieldName);
return connective;
}
use of org.drools.compiler.lang.descr.ConnectiveDescr in project drools by kiegroup.
the class VariableRestrictionsHandler method end.
public Object end(final String uri, final String localName, final ExtensibleXmlParser parser) throws SAXException {
final Element element = parser.endElementBuilder();
ConnectiveDescr c = (ConnectiveDescr) parser.getParent();
String s = (String) parser.getCurrent();
c.add(s);
return null;
}
Aggregations