Interface for all Template Resolvers.
Template resolvers are in charge of resolving template names into {@link TemplateResolution} objects that contain additional information related tothe template like:
The Template Resolver will usually get all this information from a set of configurations like applicability patterns, template mode patterns, etc. Each {@link ITemplateResolver}implementation will provide its own set of methods for specifying such configurations.
Note that it is allowed for a Template Resolver to return a result even if a template will not be resolvable by its Resource Resolver in the end. Many times it is not possible to know whether a template can be effectively resolved by a template resolver until the template resource is actually read into an InputStream so, in order to avoid two read operations for each template, many times Template Resolvers will return a result but Resource Resolvers will return none once executed.
A Template Engine can be configured several template resolvers, and these will be asked in order (according to the value returned by {@link #getOrder()}) to return a {@link TemplateResolution} object for each template name. If a template resolverreturns null or its resource resolver does, the next one in the chain is asked.
@author Daniel Fernández @since 1.0
|
|
|
|