Package org.codehaus.aspectwerkz.definition.expression

Examples of org.codehaus.aspectwerkz.definition.expression.Expression.match()


        List interfaceIntroductionDefs = new ArrayList();
        for (Iterator it = m_interfaceIntroductionMap.values().iterator(); it.hasNext();) {
            InterfaceIntroductionDefinition introDef = (InterfaceIntroductionDefinition)it.next();
            for (int i = 0; i < introDef.getExpressions().length; i++) {
                Expression expression = introDef.getExpressions()[i];
                if (expression.isOfType(PointcutType.CLASS) && expression.match(classMetaData, PointcutType.CLASS)) {
                    interfaceIntroductionDefs.add(introDef);
                }
            }
        }
        // add introduction definitions as well
View Full Code Here


            // filter out if does not contains CFLOW exprs
            // and ignores CFLOW only expression (since they are CALL pc with CFlowSystemAspect bounded, which
            // must not be filtered out)
            if (expression.isOfType(PointcutType.CFLOW)
                && expression.getTypes().size()>1
                && expression.match(classMetaData, memberMetaData, pointcutType)) {


                // generate a minimalist expression like "TRUE AND cflow OR FALSE"
                // where TRUE , FALSE etc is the result of the match as done at TF time
                expressions.add(expression.extractCflowExpression(classMetaData, memberMetaData, pointcutType));
View Full Code Here

        if (expression != null) {
            if (PointcutType.isCflowTypeOnly(expression.getTypes())) {
                return null;//Boolean.TRUE;//match at TF time
            } else {
                //TODO WITHIN
                return new Boolean(expression.match(ctx.getClassMetaData(),
                        ctx.getMemberMetaData(), ctx.getExceptionType(), ctx.getPointcutType())
                );
            }
        }
        else {
View Full Code Here

                        ""
                );
            } else {
                throw new RuntimeException("unknown anonymous: "+expr);
            }
            if (expression.match(
                    ctx.getClassMetaData(), ctx.getMemberMetaData(), ctx.getExceptionType(), ctx.getPointcutType())) {
                return Boolean.TRUE;
            } else {
                return Boolean.FALSE;
            }
View Full Code Here

        for (Iterator it = m_introductionMap.values().iterator(); it.hasNext();) {
            IntroductionDefinition introDef = (IntroductionDefinition)it.next();
            for (int i = 0; i < introDef.getExpressions().length; i++) {
                Expression expression = introDef.getExpressions()[i];
                if (expression.isOfType(PointcutType.CLASS)
                    && expression.match(classMetaData, PointcutType.CLASS)) {
                    return true;
                }
            }
        }
        return false;
View Full Code Here

            AspectDefinition aspectDef = (AspectDefinition)it.next();
            for (Iterator it2 = aspectDef.getAllAdvices().iterator(); it2.hasNext();) {
                AdviceDefinition adviceDef = (AdviceDefinition)it2.next();
                Expression expression = adviceDef.getExpression();
                if (expression.isOfType(PointcutType.EXECUTION)
                    && expression.match(classMetaData, PointcutType.EXECUTION)) {
                    return true;
                }
            }
        }
        return false;
View Full Code Here

            AspectDefinition aspectDef = (AspectDefinition)it.next();
            for (Iterator it2 = aspectDef.getAllAdvices().iterator(); it2.hasNext();) {
                AdviceDefinition adviceDef = (AdviceDefinition)it2.next();
                Expression expression = adviceDef.getExpression();
                if (expression.isOfType(PointcutType.EXECUTION)
                    && expression.match(classMetaData, memberMetaData, PointcutType.EXECUTION)) {
                    return true;
                }
            }
        }
        return false;
View Full Code Here

            AspectDefinition aspectDef = (AspectDefinition)it.next();
            for (Iterator it2 = aspectDef.getAllAdvices().iterator(); it2.hasNext();) {
                AdviceDefinition adviceDef = (AdviceDefinition)it2.next();
                Expression expression = adviceDef.getExpression();
                if (expression.isOfType(PointcutType.GET)
                    && expression.match(classMetaData, PointcutType.GET)) {
                    return true;
                }
            }
        }
        return false;
View Full Code Here

            AspectDefinition aspectDef = (AspectDefinition)it.next();
            for (Iterator it2 = aspectDef.getAllAdvices().iterator(); it2.hasNext();) {
                AdviceDefinition adviceDef = (AdviceDefinition)it2.next();
                Expression expression = adviceDef.getExpression();
                if (expression.isOfType(PointcutType.GET)
                    && expression.match(classMetaData, fieldMetaData, PointcutType.GET)) {
                    return true;
                }
            }
        }
        return false;
View Full Code Here

            AspectDefinition aspectDef = (AspectDefinition)it.next();
            for (Iterator it2 = aspectDef.getAllAdvices().iterator(); it2.hasNext();) {
                AdviceDefinition adviceDef = (AdviceDefinition)it2.next();
                Expression expression = adviceDef.getExpression();
                if (expression.isOfType(PointcutType.SET)
                    && expression.match(classMetaData, PointcutType.SET)) {
                    return true;
                }
            }
        }
        return false;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.