@DefaultKey(value="mark") public class MarkupTool extends SafeConfig
A tool to make it easy to generate XML or HTML on the fly. It uses a CSS-type syntax with a vaguely jQuery-ish API to help you generate the markup you need.
Example uses in a template: #set( $foospan = $markup.span.id($foo.id).body($foo) ) $markup.tag('table tr.bar td').body("This is $foospan") Output:
This is my first foo. |
Modifier and Type | Class and Description |
---|---|
static class |
MarkupTool.Tag |
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_DELIMITER |
static String |
DEFAULT_TAB |
LOCK_CONFIG_KEY, OLD_LOCK_CONFIG_KEY, SAFE_MODE_KEY
Constructor and Description |
---|
MarkupTool() |
Modifier and Type | Method and Description |
---|---|
MarkupTool.Tag |
get(String tag) |
String |
getTab() |
protected MarkupTool.Tag |
parse(String definition) |
void |
setTab(String tab) |
protected String[] |
split(String me) |
MarkupTool.Tag |
tag(String definition) |
configure, configure, isConfigLocked, isSafeMode, setLockConfig, setSafeMode
public static final String DEFAULT_TAB
public static final String DEFAULT_DELIMITER
public void setTab(String tab)
public String getTab()
public MarkupTool.Tag get(String tag)
public MarkupTool.Tag tag(String definition)
protected MarkupTool.Tag parse(String definition)
Copyright © 2002–2021 Apache Software Foundation. All rights reserved.