All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.nanocontainer.aop.dynaop..svn.text-base.DynaopClassPointcut.svn-base Maven / Gradle / Ivy

/*****************************************************************************
 * Copyright (c) PicoContainer Organization. All rights reserved.            *
 * ------------------------------------------------------------------------- *
 * The software in this package is published under the terms of the BSD      *
 * style license a copy of which has been included with this distribution in *
 * the LICENSE.txt file.                                                     *
 *                                                                           *
 * Idea by Rachel Davies, Original code by various                           *
 *****************************************************************************/
package org.nanocontainer.aop.dynaop;

import org.nanocontainer.aop.ClassPointcut;

/**
 * Adapts a dynaop.ClassPointcut to the
 * org.nanocontainer.aop.ClassPointcut interface.
 *
 * @author Stephen Molitor
 * @version $Revision$
 */
class DynaopClassPointcut implements dynaop.ClassPointcut, ClassPointcut {

    private final dynaop.ClassPointcut delegate;

    /**
     * Creates a new DynaoClassPointcut that will delegate to the
     * given dyanop.ClassPointcut.
     *
     * @param delegate the dyanop.ClassPointcut to delegate to.
     */
    DynaopClassPointcut(dynaop.ClassPointcut delegate) {
        this.delegate = delegate;
    }

    /**
     * Returns true if the dynaop.ClassPointcut delegate passed
     * to the constructor picks clazz.
     *
     * @param clazz the class to match against.
     * @return true if this pointcut picks clazz, else false.
     */
    public boolean picks(Class clazz) {
        return delegate.picks(clazz);
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy