Clover coverage report - Code Coverage for tapestry-annotations release 4.0.2
Coverage timestamp: Thu Apr 13 2006 10:55:35 EDT
file stats: LOC: 57   Methods: 0
NCLOC: 11   Classes: 1
 
 Source file Conditionals Statements Methods TOTAL
SecondaryAnnotationWorker.java - - - -
coverage
 1    // Copyright 2005 The Apache Software Foundation
 2    //
 3    // Licensed under the Apache License, Version 2.0 (the "License");
 4    // you may not use this file except in compliance with the License.
 5    // You may obtain a copy of the License at
 6    //
 7    // http://www.apache.org/licenses/LICENSE-2.0
 8    //
 9    // Unless required by applicable law or agreed to in writing, software
 10    // distributed under the License is distributed on an "AS IS" BASIS,
 11    // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 12    // See the License for the specific language governing permissions and
 13    // limitations under the License.
 14   
 15    package org.apache.tapestry.annotations;
 16   
 17    import java.lang.reflect.Method;
 18   
 19    import org.apache.hivemind.Resource;
 20    import org.apache.tapestry.enhance.EnhancementOperation;
 21    import org.apache.tapestry.spec.IComponentSpecification;
 22   
 23    /**
 24    * A chain-of-command interface for secondary annotation workers; workers that must execute
 25    * <em>after</em> other workers.
 26    *
 27    * @author Howard M. Lewis Ship
 28    */
 29    public interface SecondaryAnnotationWorker
 30    {
 31    /**
 32    * Sees if the particular worker can process the method (because it handles an annotation
 33    * associated with the method).
 34    *
 35    * @param method
 36    * to check
 37    * @return true if the worker should be invoked, false otherwise
 38    */
 39    public boolean canEnhance(Method method);
 40   
 41    /**
 42    * Invoked an <em>all</em> workers in the command chain, if <em>any</em> worker returns true
 43    * from {@link #canEnhance(Method)}.
 44    *
 45    * @param op
 46    * enhancement operation
 47    * @param spec
 48    * specification for the component being enhanced
 49    * @param method
 50    * the method
 51    * @param classResource
 52    * a resource representing the class; combined with the method a
 53    * {@link org.apache.hivemind.Location} can be created
 54    */
 55    public void peformEnhancement(EnhancementOperation op, IComponentSpecification spec,
 56    Method method, Resource classResource);
 57    }