Closed shai-almog closed 1 year ago
@shai-almog Hi. Yep, looks like an error in the example. The class should be declared abstract
. In fact, all custom BaseTemplate subclasses should be declared abstract since the implementation for getTemplateResourceAsStream() is generated in the final class.
For instance, in the example ShowContact is generated and extends ExampleTemplate. Since getTemplateResourceAsStream() is abstract and generated in ShowContact, ExampleTemplate should be declared abstract.
I'll correct the docs shortly. Apologies for the mix-up and thanks for reporting this!
That makes a lot of sense. Thanks!
This page: https://github.com/manifold-systems/manifold/blob/master/manifold-deps-parent/manifold-templates/README.md
Includes this example code:
Unfortunately
getTemplateResourceAsStream()
is abstract and missing from that sample. I wanted to fix the code but I'm a bit baffled about the default implementation. I looked here, but that code seems to relate to compile time processing. Not to runtime which is where the template should be relevant.