org.apache.maven.doxia.logging.LogEnabled, Macro@Component(role=Macro.class, hint="snippet") public class SnippetMacro extends AbstractMacro
| Constructor | Description |
|---|---|
SnippetMacro() |
| Modifier and Type | Method | Description |
|---|---|---|
void |
cacheSnippet(java.net.URL url,
java.lang.String id,
java.lang.String content) |
Puts the given snippet into the cache.
|
void |
execute(org.apache.maven.doxia.sink.Sink sink,
MacroRequest request) |
Execute the current macro using the given MacroRequest,
and emit events into the given sink.
|
void |
setCacheTimeout(int time) |
Set the cache timeout.
|
enableLogging, getAttributesFromMap, getLog, requiredpublic void execute(org.apache.maven.doxia.sink.Sink sink,
MacroRequest request)
throws MacroExecutionException
sink - The sink to receive the events.request - The corresponding MacroRequest.MacroExecutionException - if an error occurred during execution.public void cacheSnippet(java.net.URL url,
java.lang.String id,
java.lang.String content)
url - The URL to parse.id - The id of the snippet.content - The content of the snippet.public void setCacheTimeout(int time)
time - The timeout to set.