Class SnarfTemplate
java.lang.Object
sunlabs.brazil.template.Template
sunlabs.brazil.sunlabs.SnarfTemplate
- All Implemented Interfaces:
TemplateInterface
Template class for extracting content out of
<snarf property=xxx> ... </snarf> pairs.
xxx is the name of the property to append the snarfed
content to. Defaults to
[prepend].snarf
.
All snarf'ed content is deleted.
Properties:
-
prepend
- The string to prepend all properties with. Defaults to the handler's prefix.
-
debug
- If set, the snarf tags will be replaced by comments.
- Version:
- 2.2
- Author:
- Stephen Uhler
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
init
(RewriteContext hr) Get the debug flag and reset page.void
Save the content gathered so far.void
Mark the current location in the document.
-
Constructor Details
-
SnarfTemplate
public SnarfTemplate()
-
-
Method Details
-
init
Get the debug flag and reset page.- Specified by:
init
in interfaceTemplateInterface
- Overrides:
init
in classTemplate
-
tag_snarf
Mark the current location in the document. -
tag_slash_snarf
Save the content gathered so far.
-