public class HtmlTemplatesWriter extends Object
Constructor and Description |
---|
HtmlTemplatesWriter(FieldManager fieldManager,
MortalLogger logger) |
Modifier and Type | Method and Description |
---|---|
HtmlTemplateMethodWriter |
addSafeHtmlTemplate(String html,
Tokenator t)
Add a SafeHtml template and an instance method for invoking the template to
the generated BinderImpl class.
|
int |
getNumTemplates() |
List<HtmlTemplateMethodWriter> |
getTemplates() |
boolean |
isEmpty() |
boolean |
isSafeConstant(String expression) |
boolean |
isUri(String expression) |
void |
noteSafeConstant(String expression) |
void |
noteUri(String expression) |
void |
writeInterface(IndentedWriter w)
Write the SafeHtmlTemplates interface and its GWT.create() call.
|
void |
writeTemplateCallers(IndentedWriter w)
Write the no-arg methods that that call each template method.
|
public HtmlTemplatesWriter(FieldManager fieldManager, MortalLogger logger)
public HtmlTemplateMethodWriter addSafeHtmlTemplate(String html, Tokenator t) throws IllegalArgumentException
Note that the UiBinder#tokenator is used to determine the arguments to the generated SafeHtml template.
IllegalArgumentException
public int getNumTemplates()
public List<HtmlTemplateMethodWriter> getTemplates()
public boolean isEmpty()
public boolean isSafeConstant(String expression)
public boolean isUri(String expression)
public void noteSafeConstant(String expression)
public void noteUri(String expression)
public void writeInterface(IndentedWriter w)
public void writeTemplateCallers(IndentedWriter w)
Copyright © 2016. All rights reserved.