Package org.codehaus.aspectwerkz.attribdef.definition

Examples of org.codehaus.aspectwerkz.attribdef.definition.AspectDefinition


     */
    public Collection getAdviceDefinitions() {
        if (!m_aspectsLoaded) throw new IllegalStateException("aspects are not loaded");
        final Collection adviceDefs = new ArrayList();
        for (Iterator it = m_aspectMap.values().iterator(); it.hasNext();) {
            AspectDefinition aspectDef = (AspectDefinition)it.next();
            adviceDefs.addAll(aspectDef.getAroundAdvices());
            adviceDefs.addAll(aspectDef.getBeforeAdvices());
            adviceDefs.addAll(aspectDef.getAfterAdvices());
        }
        return adviceDefs;
    }
View Full Code Here


        if (!m_aspectsLoaded) throw new IllegalStateException("aspects are not loaded");
        if (classMetaData == null) throw new IllegalArgumentException("class meta-data can not be null");
        if (methodMetaData == null) throw new IllegalArgumentException("method meta-data can not be null");

        for (Iterator it = m_aspectMap.values().iterator(); it.hasNext();) {
            AspectDefinition aspectDef = (AspectDefinition)it.next();
            Collection controllerDefs = aspectDef.getControllers();
            for (Iterator it2 = controllerDefs.iterator(); it2.hasNext();) {
                ControllerDefinition controllerDef = (ControllerDefinition)it2.next();
                if (controllerDef.getExpression().match(classMetaData, methodMetaData)) {
                    return controllerDef.getClassName();
                }
View Full Code Here

    public boolean hasExecutionPointcut(final ClassMetaData classMetaData) {
        if (!m_aspectsLoaded) throw new IllegalStateException("aspects are not loaded");
        if (classMetaData == null) throw new IllegalArgumentException("class meta-data can not be null");

        for (Iterator it = m_aspectMap.values().iterator(); it.hasNext();) {
            AspectDefinition aspectDef = (AspectDefinition)it.next();

            for (Iterator it2 = aspectDef.getAllAdvices().iterator(); it2.hasNext();) {
                AdviceDefinition adviceDef = (AdviceDefinition)it2.next();
                Expression expression = adviceDef.getExpression();
                if (expression.getType().equals(PointcutType.EXECUTION)
                        && expression.match(classMetaData)) {
                    return true;
View Full Code Here

        if (!m_aspectsLoaded) throw new IllegalStateException("aspects are not loaded");
        if (classMetaData == null) throw new IllegalArgumentException("class meta-data can not be null");
        if (methodMetaData == null) throw new IllegalArgumentException("method meta-data can not be null");

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

    public boolean hasGetPointcut(final ClassMetaData classMetaData) {
        if (!m_aspectsLoaded) throw new IllegalStateException("aspects are not loaded");
        if (classMetaData == null) throw new IllegalArgumentException("class meta-data can not be null");

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

        if (!m_aspectsLoaded) throw new IllegalStateException("aspects are not loaded");
        if (classMetaData == null) throw new IllegalArgumentException("class meta-data can not be null");
        if (fieldMetaData == null) throw new IllegalArgumentException("field meta-data can not be null");

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

    public boolean hasSetPointcut(final ClassMetaData classMetaData) {
        if (!m_aspectsLoaded) throw new IllegalStateException("aspects are not loaded");
        if (classMetaData == null) throw new IllegalArgumentException("class meta-data can not be null");

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

        if (!m_aspectsLoaded) throw new IllegalStateException("aspects are not loaded");
        if (classMetaData == null) throw new IllegalArgumentException("class meta-data can not be null");
        if (fieldMetaData == null) throw new IllegalArgumentException("field meta-data can not be null");

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

    public boolean hasThrowsPointcut(final ClassMetaData classMetaData) {
        if (!m_aspectsLoaded) throw new IllegalStateException("aspects are not loaded");
        if (classMetaData == null) throw new IllegalArgumentException("class meta-data can not be null");

        for (Iterator it = m_aspectMap.values().iterator(); it.hasNext();) {
            AspectDefinition aspectDef = (AspectDefinition)it.next();
            for (Iterator it2 = aspectDef.getAllAdvices().iterator(); it2.hasNext();) {
                AdviceDefinition adviceDef = (AdviceDefinition)it2.next();
                Expression expression = adviceDef.getExpression();
                if (expression.getType().equals(PointcutType.THROWS)
                        && expression.match(classMetaData)) {
                    return true;
View Full Code Here

        if (!m_aspectsLoaded) throw new IllegalStateException("aspects are not loaded");
        if (classMetaData == null) throw new IllegalArgumentException("class meta-data can not be null");
        if (methodMetaData == null) throw new IllegalArgumentException("method meta-data can not be null");

        for (Iterator it = m_aspectMap.values().iterator(); it.hasNext();) {
            AspectDefinition aspectDef = (AspectDefinition)it.next();
            for (Iterator it2 = aspectDef.getAllAdvices().iterator(); it2.hasNext();) {
                AdviceDefinition adviceDef = (AdviceDefinition)it2.next();
                Expression expression = adviceDef.getExpression();
                if (expression.getType().equals(PointcutType.THROWS)
                        && expression.match(classMetaData, methodMetaData)) {
                    return true;
View Full Code Here

TOP

Related Classes of org.codehaus.aspectwerkz.attribdef.definition.AspectDefinition

Copyright © 2018 www.massapicom. 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.