1 /* 2 * This file is part of Pease Plate Template Engine. 3 * 4 * Pease Plate Template Engine is free software: you can redistribute 5 * it and/or modify it under the terms of the GNU Lesser General 6 * Public License as published by the Free Software Foundation, 7 * either version 3 of the License, or any later version. 8 * 9 * Pease Plate Template Engine is distributed in the hope that it 10 * will be useful, but WITHOUT ANY WARRANTY; without even the implied 11 * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 12 * See the GNU Lesser General Public License for more details. 13 * 14 * You should have received a copy of the GNU Lesser General Public 15 * License along with Pease Plate Template Engine. If not, see 16 * <http://www.gnu.org/licenses/>. 17 * 18 * Copyright (c) 2008 Manfred HANTSCHEL 19 */ 20 package org.peaseplate; 21 22 import java.io.Writer; 23 import java.lang.annotation.ElementType; 24 import java.lang.annotation.Retention; 25 import java.lang.annotation.RetentionPolicy; 26 import java.lang.annotation.Target; 27 28 29 /** 30 * Signs a method as the default macro. 31 * 32 * This macro can be called only by the macro class level name. 33 * 34 * The annotated method must conform the following rules: 35 * 36 * <ul> 37 * <li>The method must have no return value</li> 38 * <li>The first parameter must be a {@link RenderContext}</li> 39 * <li>The second parameter must be a {@link Writer}</li> 40 * </ul> 41 * 42 * Any following parameters can be of any type and will be passed from the template. 43 * 44 * @author Manfred HANTSCHEL 45 */ 46 @Target(ElementType.METHOD) 47 @Retention(RetentionPolicy.RUNTIME) 48 public @interface DefaultMacro { 49 }