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

Merged
merged 4 commits into from
Sep 23, 2024

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

 1 815 files   1 815 suites   1h 40m 10s ⏱️
 7 699 tests  7 470 ✅ 228 💤 1 ❌
24 258 runs  23 510 ✅ 747 💤 1 ❌

For more details on these failures, see this check.

Results for commit b9fe844.

♻️ 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.

@HannesWell HannesWell force-pushed the improve-xpath branch 3 times, most recently from 367b81b to 4950874 Compare September 22, 2024 21:29
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
@HannesWell HannesWell merged commit 95cf53a into eclipse-platform:master Sep 23, 2024
11 of 16 checks passed
@HannesWell HannesWell deleted the improve-xpath branch September 23, 2024 20:23
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