-
Notifications
You must be signed in to change notification settings - Fork 13
MCR-3497 Remove Xalan extensions from XEditor #2677
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
yagee-de
merged 66 commits into
main
from
issues/MCR-3497_Remove_Xalan_extensions_from_XEditor
Dec 16, 2025
Merged
MCR-3497 Remove Xalan extensions from XEditor #2677
yagee-de
merged 66 commits into
main
from
issues/MCR-3497_Remove_Xalan_extensions_from_XEditor
Dec 16, 2025
Conversation
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
Member
Author
|
Testing requires minor changes in the application: |
kkrebs
approved these changes
Dec 16, 2025
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.
Link to jira: MCR-3497.
New Package org.mycore.frontend.xeditor.transform contanis all classes involved in this transformation.
Before:
xeditor.xsl makes many calls to MCRIncludeHandler and MCRXEditorTransformer classes via Xalan Java extensions.
After:
xeditor.xsl calls the new MCRTransformerHelperResolver via document() function.
MCRTransformerHelperCall parses the URI of the document() call.
MCRTransformerHelperBase is the common abstract base class of all classes implementing a single xml element transformation.
For example, xed:bind is transformed with the help of MCRBindTransformerHelper.
The xsl's have been migrated to XSLT 3, and the XEditor transformer is now Saxon.
Xalan support is removed.
For applications defining custom xml templates (e.g. MIR), there is and was a hook to plug-in the XSL stylesheets to preprocess them from custom xml templates to xed+xhtml templates, which are then processed by xeditor.xsl. This had to be changed too:
Before:
XEditorTransformer processed these both via Xalan:
MCR.ContentTransformer.xeditor.Stylesheet=xsl/xeditor-templates.xsl,xsl/xeditor.xsl
After:
To minimize migration, XEditorTransformer uses two steps now, one via Xalan and one via Saxon.
Applicatons that have converted their XSLs to v3/Saxon, can change the properties.
CR.ContentTransformer.xeditor.Class=org.mycore.common.content.transformer.MCRTransformerPipe
MCR.ContentTransformer.xeditor.Steps=transform-xeditor-templates,transform-xeditor
MCR.ContentTransformer.transform-xeditor.Class=org.mycore.common.content.transformer.MCRXSL2XMLTransformer
MCR.ContentTransformer.transform-xeditor.TransformerFactoryClass=%SAXON%
MCR.ContentTransformer.transform-xeditor.Stylesheet=xslt/xeditor.xsl
MCR.ContentTransformer.transform-xeditor-templates.Class=org.mycore.common.content.transformer.MCRXSL2XMLTransformer
MCR.ContentTransformer.transform-xeditor-templates.TransformerFactoryClass=%XALAN%
MCR.ContentTransformer.transform-xeditor-templates.Stylesheet=xsl/xeditor-templates.xsl