You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In order to allow a second processing of already-processed elements (for example, when a processor modifies an already processed element and add some th:* attributes to it), a "dirty" boolean flag could be added to the Node class.
When set to true, this flag should be automatically propagated towards the root of the node tree up to the Document node, so that after the first pass of processing we can know whether a second pass has to be executed just by checking the root node (instead of performing a full-depth search).
This node could be automatically set when an already-processed node is changed (change in children or attributes).
Also, it should be noted that in order for this to work OK, we should avoid that already-executed processors remain in the list of to-be-processed processors for their respective nodes (so that they are not executed again and --potentially-- fail on the non-existence of the attribute). See http://forum.thymeleaf.org/Adding-elements-with-th-annotation-in-custom-processor-td4024907.html
The text was updated successfully, but these errors were encountered:
In order to allow a second processing of already-processed elements (for example, when a processor modifies an already processed element and add some th:* attributes to it), a "dirty" boolean flag could be added to the Node class.
When set to true, this flag should be automatically propagated towards the root of the node tree up to the Document node, so that after the first pass of processing we can know whether a second pass has to be executed just by checking the root node (instead of performing a full-depth search).
This node could be automatically set when an already-processed node is changed (change in children or attributes).
Also, it should be noted that in order for this to work OK, we should avoid that already-executed processors remain in the list of to-be-processed processors for their respective nodes (so that they are not executed again and --potentially-- fail on the non-existence of the attribute). See http://forum.thymeleaf.org/Adding-elements-with-th-annotation-in-custom-processor-td4024907.html
The text was updated successfully, but these errors were encountered: