Skip to content
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

Various minor improvements for E4 EMF Xpath #2289

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

HannesWell
Copy link
Member

This PR contains three commits with minor improvements of the E4 EMF Xpath bundle:

  1. Unify and clean-up definitions of generic type arguments
  2. Import org.apache.commons.jxpath packages
    as suggested in Remove dependencies on org.apache.commons.jxpath #423 (comment)
  3. Add XPathContext.stream() and strengthen type of getValue(String, Class)

The new method is for example useful in:
https://github.com/eclipse-pde/eclipse.pde/blob/ba11267159a1f5eed242af8f18dadc299f763637/e4tools/bundles/org.eclipse.e4.tools.emf.ui/src/org/eclipse/e4/tools/emf/ui/internal/common/component/StringModelFragment.java#L587-L600

Copy link
Contributor

github-actions bot commented Sep 17, 2024

Test Results

  605 files   -   605    605 suites   - 605   29m 54s ⏱️ - 40m 14s
7 699 tests ±    0  7 465 ✅ ±    0  234 💤 +  1  0 ❌  - 1 
8 086 runs   - 8 086  7 852 ✅  - 7 805  234 💤  - 280  0 ❌  - 1 

Results for commit 367b81b. ± Comparison against base commit 8df2017.

This pull request skips 1 test.
org.eclipse.jface.text.tests.contentassist.AsyncContentAssistTest ‑ testCompleteActivationChar

♻️ This comment has been updated with latest results.

@@ -42,19 +46,35 @@ public interface XPathContext {
* required type
* @return Object found
*/
Object getValue(String xpath, Class<?> requiredType);
<T> T getValue(String xpath, Class<T> requiredType);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since the method signature is the same after generic erasure this is a binary and source compatible change.
But as far as I can tell, this method and its overload is not used within the SDK at all, besides tests.

@HannesWell
Copy link
Member Author

If there are no unresolved remarks I plan to submit this tomorrow (European) evening.

instead of requiring the bundle 'org.apache.commons.jxpath'. This allows
interested parties to supply alternative providers than the old and
problematic 'org.apache.commons.jxpath'.

Helps for
eclipse-platform#423
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant