ExpressionFactory.matchAllExp(...)

From: Marcel (emmpeege..mail.com)
Date: Mon Jul 24 2006 - 21:38:22 EDT

  • Next message: Andrus Adamchik: "JPA license headers"

    As far as I can tell there is a bug in
    ExpressionFactory.*matchAllExp*(java.util.Map map, int type).

    With a map of keys and values, an exception will always arise here:

    Thread [main] (Suspended)
        ASTAnd(AggregateConditionNode).jjtAddChild(Node, int) line: 120
        ASTAnd(SimpleNode).setOperand(int, Object) line: 187
        ExpressionFactory.matchAllExp(Map, int) line: 298

    jjtAddChild throws an exception whenNode is not of type ConditionNode or
    AggregateConditionNode. However, the Node parameter is just the Object
    parameter from setOperand, which is called from matchAllExp as:

    exp.setOperand(0, new ASTObjPath(entry.getKey()));

    Where entry.getKey() is the object path (in my case just the name of an
    object attribute). ASTObjPath is not of the correct type, so an
    exception is thrown everytime, regardless of what entry.getKey() happens
    to be.

    Folks with more experience? I'll try just stringing my own expression
    together for now.

    Marcel



    This archive was generated by hypermail 2.0.0 : Mon Jul 24 2006 - 21:38:53 EDT