|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.xwiki.rendering.macro.AbstractMacro<P>
P - the type of the macro parameters beanpublic abstract class AbstractMacro<P>
| Field Summary | |
|---|---|
protected org.xwiki.properties.BeanManager |
beanManager
The BeanManager component. |
static String |
DEFAULT_CATEGORY_CONTENT
"Content" default macro category. |
static String |
DEFAULT_CATEGORY_DEVELOPMENT
"Development" default macro category. |
static String |
DEFAULT_CATEGORY_FORMATTING
"Formatting" default macro category. |
static String |
DEFAULT_CATEGORY_NAVIGATION
"Navigation" default macro category. |
| Constructor Summary | |
|---|---|
AbstractMacro(String name)
Creates a new Macro instance. |
|
AbstractMacro(String name,
String description)
Creates a new Macro instance. |
|
AbstractMacro(String name,
String description,
Class<?> parametersBeanClass)
Creates a new Macro instance. |
|
AbstractMacro(String name,
String description,
ContentDescriptor contentDescriptor)
Creates a new Macro instance. |
|
AbstractMacro(String name,
String description,
ContentDescriptor contentDescriptor,
Class<?> parametersBeanClass)
Creates a new Macro instance. |
|
| Method Summary | |
|---|---|
int |
compareTo(Macro<?> macro)
|
MacroDescriptor |
getDescriptor()
|
int |
getPriority()
The priority of execution relative to the other Macros. |
void |
initialize()
|
protected void |
setDefaultCategory(String defaultCategory)
Allows sub classes to set the default macro category. |
protected void |
setDescriptor(MacroDescriptor descriptor)
Allows macro classes extending other macro classes to override the macro descriptor with their own. |
void |
setPriority(int priority)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.xwiki.rendering.macro.Macro |
|---|
execute, supportsInlineMode |
| Field Detail |
|---|
public static final String DEFAULT_CATEGORY_FORMATTING
public static final String DEFAULT_CATEGORY_DEVELOPMENT
public static final String DEFAULT_CATEGORY_CONTENT
public static final String DEFAULT_CATEGORY_NAVIGATION
@Inject protected org.xwiki.properties.BeanManager beanManager
BeanManager component.
| Constructor Detail |
|---|
public AbstractMacro(String name)
Macro instance.
name - the name of the macro (eg "Table Of Contents" for the TOC macro)
public AbstractMacro(String name,
String description)
Macro instance.
name - the name of the macro (eg "Table Of Contents" for the TOC macro)description - a string describing this macro.
public AbstractMacro(String name,
String description,
ContentDescriptor contentDescriptor)
Macro instance.
name - the name of the macro (eg "Table Of Contents" for the TOC macro)description - a string describing this macro.contentDescriptor - ContentDescriptor for this macro.
public AbstractMacro(String name,
String description,
Class<?> parametersBeanClass)
Macro instance.
name - the name of the macro (eg "Table Of Contents" for the TOC macro)description - a string describing this macro.parametersBeanClass - class of the parameters bean of this macro.
public AbstractMacro(String name,
String description,
ContentDescriptor contentDescriptor,
Class<?> parametersBeanClass)
Macro instance.
name - the name of the macro (eg "Table Of Contents" for the TOC macro)description - string describing this macro.contentDescriptor - the ContentDescriptor describing the content of this macro.parametersBeanClass - class of the parameters bean.| Method Detail |
|---|
public void initialize()
throws org.xwiki.component.phase.InitializationException
initialize in interface org.xwiki.component.phase.Initializableorg.xwiki.component.phase.InitializationExceptionpublic int getPriority()
getPriority in interface Macro<P>Macro.getPriority()public void setPriority(int priority)
priority - the macro priority to use (lower means execute before others)public MacroDescriptor getDescriptor()
getDescriptor in interface Macro<P>Macro.getDescriptor()public int compareTo(Macro<?> macro)
compareTo in interface Comparable<Macro<?>>Comparable.compareTo(java.lang.Object)protected void setDescriptor(MacroDescriptor descriptor)
descriptor - the overriding descriptor to setprotected void setDefaultCategory(String defaultCategory)
MacroDescriptor is of type AbstractMacroDescriptor.
defaultCategory - the default macro category to be set.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||