Package htmlflow
Class StaticHtml
- java.lang.Object
-
- htmlflow.HtmlView<Object>
-
- htmlflow.StaticHtml
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected HtmlView<Object>clone(HtmlVisitorCache visitor)Resulting in a non thread safe view.protected HtmlView<Object>clone(Supplier<HtmlVisitorCache> visitorSupplier, boolean threadSafe)Since HtmlView is immutable this is the preferred way to create a copy of the existing HtmlView instance with a different threadSafe state.Stringrender()Returns a new String with the HTML content of this view.Stringrender(Object model)Returns a new String with the HTML content of this view.static StaticHtmlview()static StaticHtmlview(PrintStream out)static StaticHtmlview(PrintStream out, Consumer<StaticHtml> template)static StaticHtmlview(Consumer<StaticHtml> template)voidwrite()Writes into an internal PrintStream the HTML content.voidwrite(Object model)Writes into an internal PrintStream the HTML content binding the object model with the HTML elements.-
Methods inherited from class htmlflow.HtmlView
__, addPartial, addPartial, defineRoot, div, getName, getParent, getVisitor, html, self, setIndented, setPrintStream, threadSafe, tr
-
-
-
-
Method Detail
-
view
public static StaticHtml view(PrintStream out, Consumer<StaticHtml> template)
-
view
public static StaticHtml view(PrintStream out)
-
view
public static StaticHtml view(Consumer<StaticHtml> template)
-
view
public static StaticHtml view()
-
render
public final String render()
Description copied from interface:HtmlWriterReturns a new String with the HTML content of this view.
-
render
public final String render(Object model)
Description copied from interface:HtmlWriterReturns a new String with the HTML content of this view.- Parameters:
model- An object model that could be bind to each element of the view.
-
write
public final void write()
Description copied from interface:HtmlWriterWrites into an internal PrintStream the HTML content.
-
write
public final void write(Object model)
Description copied from interface:HtmlWriterWrites into an internal PrintStream the HTML content binding the object model with the HTML elements.- Parameters:
model- An object model that could be bind to each element.
-
clone
protected final HtmlView<Object> clone(Supplier<HtmlVisitorCache> visitorSupplier, boolean threadSafe)
Since HtmlView is immutable this is the preferred way to create a copy of the existing HtmlView instance with a different threadSafe state.
-
-