Class CtxExtraDateSerializerRenderer
java.lang.Object
dk.mada.jaxrs.generator.mpclient.dto.tmpl.CtxExtraDateSerializerRenderer
Generated Renderer.
-
Constructor Summary
ConstructorsConstructorDescriptionRenderer constructor for reflection (use of() instead).Renderer constructor for manual wiring. -
Method Summary
Modifier and TypeMethodDescriptionexecute(CtxExtraDateSerializer model) Convenience method that directly renders the model as a String.voidexecute(CtxExtraDateSerializer model, Appendable a) Renders the passed in model.protected voidexecute(CtxExtraDateSerializer model, Appendable a, Function<Object, String> formatter, Function<String, String> escaper) Renders the passed in model.Class<?> Model class.of()Convience static factory that will reuse the same singleton instance.static voidrender(CtxExtraDateSerializer data, Appendable unescapedWriter, Function<Object, String> formatter, Function<String, String> escaper) Renders the passed in model.booleansupportsType(Class<?> type) If this template support the model classTemplate charset name.Current escaper.Current formatter.Logical template name.Template path.Template contents or blank if path.
-
Constructor Details
-
CtxExtraDateSerializerRenderer
-
CtxExtraDateSerializerRenderer
public CtxExtraDateSerializerRenderer()Renderer constructor for reflection (use of() instead). For programmatic consider usingof()for a shared singleton.
-
-
Method Details
-
execute
Renders the passed in model.- Parameters:
model- a model assumed never to benull.a- the appendable to write to.- Throws:
IOException- if there is an error writing to the appendable
-
execute
Convenience method that directly renders the model as a String.- Parameters:
model- never null.- Returns:
- the rendered model.
-
execute
protected void execute(CtxExtraDateSerializer model, Appendable a, Function<Object, String> formatter, Function<String, throws IOExceptionString> escaper) Renders the passed in model.- Parameters:
model- a model assumed never to benull.a- appendable to write to.formatter- formats variables before they are passed to the escaperescaper- used to write escaped variables- Throws:
IOException- if an error occurs while writing to the appendable
-
supportsType
If this template support the model class- Parameters:
type- model class.- Returns:
- true if the renderer supports the class
-
templatePath
Template path.- Returns:
- template path of resource or pseudo inline path
-
templateName
-
templateCharset
-
templateString
-
templateEscaper
-
templateFormatter
-
modelClass
-
of
Convience static factory that will reuse the same singleton instance.- Returns:
- renderer same as calling no-arg constructor but is cached with singleton instance
-
render
public static void render(CtxExtraDateSerializer data, Appendable unescapedWriter, Function<Object, String> formatter, Function<String, throws IOExceptionString> escaper) Renders the passed in model.- Parameters:
data- modelunescapedWriter- appendable to write to.formatter- formats variables before they are passed to the escaper.escaper- used to write escaped variables.- Throws:
IOException- if an error occurs while writing to the appendable
-