use of org.thymeleaf.model.IStandaloneElementTag in project thymeleaf-tests by thymeleaf.
the class ReplaceWithNonProcessableDocTypeProcessor method doProcess.
@Override
protected void doProcess(final ITemplateContext context, final IDocType docType, final IDocTypeStructureHandler structureHandler) {
final IModelFactory modelFactory = context.getModelFactory();
final IStandaloneElementTag tag = modelFactory.createStandaloneElementTag("replaced", "th:text", "one", false, true);
final IModel model = modelFactory.createModel(tag);
structureHandler.replaceWith(model, false);
}
use of org.thymeleaf.model.IStandaloneElementTag in project thymeleaf-tests by thymeleaf.
the class ReplaceWithNonProcessableProcessingInstructionProcessor method doProcess.
@Override
protected void doProcess(final ITemplateContext context, final IProcessingInstruction processingInstruction, final IProcessingInstructionStructureHandler structureHandler) {
final IModelFactory modelFactory = context.getModelFactory();
final IStandaloneElementTag tag = modelFactory.createStandaloneElementTag("replaced", "th:text", "one", false, true);
final IModel model = modelFactory.createModel(tag);
structureHandler.replaceWith(model, false);
}
use of org.thymeleaf.model.IStandaloneElementTag in project thymeleaf-tests by thymeleaf.
the class ReplaceWithNonProcessableTextProcessor method doProcess.
@Override
protected void doProcess(final ITemplateContext context, final IText text, final ITextStructureHandler structureHandler) {
if (EngineEventUtils.isWhitespace(text) || text.getText().equals("one")) {
return;
}
final IModelFactory modelFactory = context.getModelFactory();
final IStandaloneElementTag tag = modelFactory.createStandaloneElementTag("replaced", "th:text", "one", false, true);
final IModel model = modelFactory.createModel(tag);
structureHandler.replaceWith(model, false);
}
use of org.thymeleaf.model.IStandaloneElementTag in project thymeleaf-tests by thymeleaf.
the class ReplaceWithNonProcessableXMLDeclarationProcessor method doProcess.
@Override
protected void doProcess(final ITemplateContext context, final IXMLDeclaration xmlDeclaration, final IXMLDeclarationStructureHandler structureHandler) {
final IModelFactory modelFactory = context.getModelFactory();
final IStandaloneElementTag tag = modelFactory.createStandaloneElementTag("replaced", "th:text", "one", false, true);
final IModel model = modelFactory.createModel(tag);
structureHandler.replaceWith(model, false);
}
use of org.thymeleaf.model.IStandaloneElementTag in project thymeleaf-tests by thymeleaf.
the class ReplaceWithProcessableDocTypeProcessor method doProcess.
@Override
protected void doProcess(final ITemplateContext context, final IDocType docType, final IDocTypeStructureHandler structureHandler) {
final IModelFactory modelFactory = context.getModelFactory();
final IStandaloneElementTag tag = modelFactory.createStandaloneElementTag("replaced", "th:text", "one", false, true);
final IModel model = modelFactory.createModel(tag);
structureHandler.replaceWith(model, true);
}
Aggregations