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

TypeElementWrapper.getOuterType() fails for class contained in an interface #163

Open
odrotbohm opened this issue Oct 3, 2024 · 1 comment

Comments

@odrotbohm
Copy link

Given the following arrangement:

interface Foo {

  class Bar {}
}

, a TypeElementWrapper obtained for Bar will return an empty Optional for the call to getOuterType() as that only looks for parent elements of ElementKind.CLASS.

@odrotbohm
Copy link
Author

This has just come up again in Spring Moduliths APT in a related way.

odrotbohm added a commit to spring-projects/spring-modulith that referenced this issue Nov 25, 2024
… in interfaces.

A bug [0] in APTK causes our Javadoc extraction to fail for methods whose parameters are classes nested in interfaces. We fix that by temporarily including a fixed copy of TypeElementWrapper, that looks up outer types on interfaces as well.

[0] toolisticon/aptk#163
odrotbohm added a commit to spring-projects/spring-modulith that referenced this issue Nov 25, 2024
… in interfaces.

A bug [0] in APTK causes our Javadoc extraction to fail for methods whose parameters are classes nested in interfaces. We fix that by temporarily including a fixed copy of TypeElementWrapper, that looks up outer types on interfaces as well.

[0] toolisticon/aptk#163
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

No branches or pull requests

1 participant