psdi.app.recontask.engine

Class ReconCompFilterExpression

    • Field Detail

      • dataSet

        protected DataSet dataSet
      • filterOperators

        protected java.lang.String[] filterOperators
    • Constructor Detail

      • ReconCompFilterExpression

        public ReconCompFilterExpression(DataSet dataSet,
                                         ReconInfo reconInfo)
    • Method Detail

      • evaluateExpression

        public ReconCompFilterReturn evaluateExpression(ComparisonQueryHelper queries)
                                                 throws MXException
        Evaluates the expression, compiling it first if needed. The expression evaluation process will remove from the data those records that fail to satisfy the filtering conditions
        Returns:
        teh number of objects that satisfy teh condition
        Throws:
        MXException
      • evaluateExpressionTree

        protected ReconCompFilterReturn evaluateExpressionTree(BinaryTreeNode root,
                                                               ComparisonQueryHelper queries)
                                                        throws MXApplicationException
        Traverse the binary tree using a recursive algorithm

        The pseudocode is

        if (root != null)

        if ( [current node contains an operator] )

        x = evaluateTree(root.left_child);

        y = evaluateTree(root.right_child);

        // Consult the design document why the logical operator AND is handled in the way it is

        [Perform operation on x and y, specified by the operator and store result in z]

        return z;

        else

        return root->data;

        Returns:
        a list of all IDs of all AssetObject instances that graduated successfully from the filter. Don't worry they may originate from different records database
        Throws:
        MXApplicationException
      • readOperator

        protected void readOperator(MboRemote clause)
                             throws MXException,
                                    java.rmi.RemoteException
        Read the operator and value for the reconciliation comparison filter clause. If the operator is missing, substitute with the operator 'EXISTS' that lets through all instances found in the database
        Parameters:
        clause - for the reconciliation comparison filter clause
        Throws:
        MXException
        java.rmi.RemoteException