本文整理汇总了Java中org.thymeleaf.templateresolver.ITemplateResolutionValidity类的典型用法代码示例。如果您正苦于以下问题:Java ITemplateResolutionValidity类的具体用法?Java ITemplateResolutionValidity怎么用?Java ITemplateResolutionValidity使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ITemplateResolutionValidity类属于org.thymeleaf.templateresolver包,在下文中一共展示了ITemplateResolutionValidity类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: resolveTemplate
import org.thymeleaf.templateresolver.ITemplateResolutionValidity; //导入依赖的package包/类
@Override
public TemplateResolution resolveTemplate(final TemplateProcessingParameters tpp) {
String templateName = "CustomTemplate";
String resourceName = "CustomResource";
IResourceResolver resourceResolver = new FixedMemoryResourceResolver(templateContent);
ITemplateResolutionValidity validity = new NonCacheableTemplateResolutionValidity();
return new TemplateResolution(templateName, resourceName, resourceResolver, StandardCharsets.UTF_8.toString(),
templateMode, validity);
}
示例2: resolveTemplate
import org.thymeleaf.templateresolver.ITemplateResolutionValidity; //导入依赖的package包/类
@Override
public TemplateResolution resolveTemplate(TemplateProcessingParameters templateProcessingParameters) {
String templateName = templateProcessingParameters.getTemplateName();
String resourceName = "";
// TODO Get character encoding from the capability
String characterEncoding = "UTF8";
// TODO Get the mode from the capability if specified
String templateMode = StandardTemplateModeHandlers.XHTML.getTemplateModeName();
ITemplateResolutionValidity validity = null;
new TemplateResolution(templateName, resourceName, resourceResolver, characterEncoding, templateMode, validity);
return null;
}
示例3: computeValidity
import org.thymeleaf.templateresolver.ITemplateResolutionValidity; //导入依赖的package包/类
@Override
protected ITemplateResolutionValidity computeValidity(TemplateProcessingParameters templateProcessingParameters)
{
return nonCacheableTemplateResolutionValidity;
}