Conversation
… (TEDEFO-4370) New features: - LET template:name(params) DISPLAY syntax for definitions - INVOKE template-name(args) syntax for calls - WHEN condition DISPLAY/INVOKE template OTHERWISE ... - Deprecates/replaces some members of the MarkupGenerator
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR adds support for conditional templates and parameterized callable templates while refactoring the underlying model to use the new variables and parsed parameter/argument classes. Key changes include:
- Introduction of TemplateInvocation and TemplateDefinition classes that extend ContentBlock with new rendering semantics.
- Refactoring ContentBlock and related classes to use ParsedParameters, ParsedArguments, and Updated Variables.
- Improvements to exception handling and deprecation of outdated methods in MarkupGenerator and related modules.
Reviewed Changes
Copilot reviewed 43 out of 43 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| src/main/java/eu/europa/ted/efx/model/templates/TemplateInvocation.java | New implementation for template invocations using new argument handling. |
| src/main/java/eu/europa/ted/efx/model/templates/TemplateDefinition.java | New template definition implementation that integrates with the refactored ContentBlock. |
| src/main/java/eu/europa/ted/efx/model/templates/Markup.java | Added an isEmpty() helper method. |
| src/main/java/eu/europa/ted/efx/model/templates/ContentBlockStack.java | Updated child/sibling push methods to use the new Variables and Conditionals. |
| src/main/java/eu/europa/ted/efx/model/templates/ContentBlock.java | Major refactoring to incorporate ParsedParameters, ParsedArguments and updates to rendering methods. |
| Others (Conditionals, Conditional, Exception classes, interfaces, SdkSymbolResolver, ComponentFactory) | Adjustments for updated error handling, naming consistency, and SDK symbol resolution. |
rouschr
reviewed
Jun 2, 2025
rouschr
reviewed
Jun 2, 2025
rouschr
approved these changes
Jun 2, 2025
Contributor
rouschr
left a comment
There was a problem hiding this comment.
See my comments, cosmetic
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
New features: