001    /*******************************************************************************
002     * Portions created by Sebastian Thomschke are copyright (c) 2005-2011 Sebastian
003     * Thomschke.
004     * 
005     * All Rights Reserved. This program and the accompanying materials
006     * are made available under the terms of the Eclipse Public License v1.0
007     * which accompanies this distribution, and is available at
008     * http://www.eclipse.org/legal/epl-v10.html
009     * 
010     * Contributors:
011     *     Sebastian Thomschke - initial implementation.
012     *******************************************************************************/
013    package net.sf.oval.configuration.annotation;
014    
015    import java.lang.annotation.Annotation;
016    
017    import net.sf.oval.CheckExclusion;
018    import net.sf.oval.exception.InvalidConfigurationException;
019    
020    /**
021     * Interface for constraint checks that are configurable via annotations.
022     * 
023     * @author Sebastian Thomschke
024     */
025    public interface AnnotationCheckExclusion<ExclusionAnnotation extends Annotation> extends CheckExclusion
026    {
027            /**
028             * Configures the check exclusion based on the given exclusion annotation.
029             * @param exclusionAnnotation the exclusion annotation to use for configuration
030             * @throws InvalidConfigurationException in case of an illegal configuration setting
031             */
032            void configure(ExclusionAnnotation exclusionAnnotation) throws InvalidConfigurationException;
033    }