Package org.radeox.macro
Class CodeMacro
- java.lang.Object
-
- org.radeox.macro.BaseMacro
-
- org.radeox.macro.Preserved
-
- org.radeox.macro.LocalePreserved
-
- org.radeox.macro.CodeMacro
-
- All Implemented Interfaces:
Comparable,org.radeox.api.macro.Macro,LocaleMacro
public class CodeMacro extends LocalePreserved
-
-
Field Summary
-
Fields inherited from class org.radeox.macro.BaseMacro
description, initialContext
-
-
Constructor Summary
Constructors Constructor Description CodeMacro()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidexecute(Writer writer, org.radeox.api.macro.MacroParameter params)Execute the macro.StringgetLocaleKey()String[]getParamDescription()Get a description of the paramters of the macro.voidsetInitialContext(org.radeox.api.engine.context.InitialRenderContext context)-
Methods inherited from class org.radeox.macro.LocalePreserved
getName
-
Methods inherited from class org.radeox.macro.Preserved
addSpecial, addSpecial, replace
-
Methods inherited from class org.radeox.macro.BaseMacro
compareTo, getDescription, toString
-
-
-
-
Method Detail
-
getParamDescription
public String[] getParamDescription()
Description copied from class:BaseMacroGet a description of the paramters of the macro. The method returns an array with an String entry for every parameter. The format is {"1: description", ...} where 1 is the position of the parameter.- Specified by:
getParamDescriptionin interfaceorg.radeox.api.macro.Macro- Overrides:
getParamDescriptionin classBaseMacro- Returns:
- description Array describing the parameters of the macro
-
getLocaleKey
public String getLocaleKey()
-
setInitialContext
public void setInitialContext(org.radeox.api.engine.context.InitialRenderContext context)
- Specified by:
setInitialContextin interfaceorg.radeox.api.macro.Macro- Overrides:
setInitialContextin classLocalePreserved
-
execute
public void execute(Writer writer, org.radeox.api.macro.MacroParameter params) throws IllegalArgumentException, IOException
Description copied from class:BaseMacroExecute the macro. This method is called by MacroFilter to handle macros.- Specified by:
executein interfaceorg.radeox.api.macro.Macro- Specified by:
executein classBaseMacro- Parameters:
writer- A write where the macro should write its output toparams- Macro parameters with the parameters the macro is called with- Throws:
IllegalArgumentExceptionIOException
-
-