| com.uwyn.rife.template.TemplateEncoder
All known Subclasses: com.uwyn.rife.template.EncoderXml, com.uwyn.rife.template.EncoderSql, com.uwyn.rife.template.EncoderDummy, com.uwyn.rife.template.EncoderHtml,
TemplateEncoder | public interface TemplateEncoder (Code) | | Encodes String s into a corresponding template output format,
so they will be displayed correctly in the resulting file. For example, a
TemplateEncoder for a template file will
TemplateEncoder.encode encode > as > .
author: Keith Lea <keith[remove] at cs dot oswego dot edu> author: Geert Bevin (gbevin[remove] at uwyn dot com) version: $Revision: 3634 $ since: 1.0 |
Method Summary | |
public String | encode(String value) Encodes the given value, returning a string which contains only valid
characters and represents the given value correctly in the
output format. | public String | encodeDefensive(String value) Encodes the given value in a looser fashion than
TemplateEncoder.encode 's,
only converting patterns which are explicitly not allowed by the output
format, but not guaranteeing that the output value exactly represents
the given value in the output format. |
encode | public String encode(String value)(Code) | | Encodes the given value, returning a string which contains only valid
characters and represents the given value correctly in the
output format.
For example, an HTML template's encoder will encode
> as > .
Parameters: value - a string an encoded version of the given string since: 1.0 |
encodeDefensive | public String encodeDefensive(String value)(Code) | | Encodes the given value in a looser fashion than
TemplateEncoder.encode 's,
only converting patterns which are explicitly not allowed by the output
format, but not guaranteeing that the output value exactly represents
the given value in the output format.
For example, an HTML template's encoder will encode some Unicode
characters to corresponding XML entities (such as
é ) when this method is called but not encode
< or & .
Parameters: value - a string a loosely encoded version of the given value since: 1.0 |
|
|