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

🐛 Temptative solution for basic annotation inspection #621

Closed
wants to merge 6 commits into from

Conversation

jmle
Copy link
Contributor

@jmle jmle commented Jun 18, 2024

Partially fixes #460

This PR would introduce a new field to the java.referenced condition. For instance, the following condition

    java.referenced:
      pattern: org.home.Bean*
      location: CLASS
      annotated:
        pattern: org.home.BeanAnnotation

would match this:

package org.home;

@org.home.BeanAnnotation
public class BeanClass {
  // ...
}

Possible values for annotated locations are CLASS, METHOD and FIELD.

⚠️ When using FIELD in java.referenced.location, the user might expect to be able to put a type in the pattern field, as in "please look for any field of type type that has annotation annotated.pattern. That is not possible at the moment, since the LS only returns the name of the field.

jmle added 2 commits June 18, 2024 15:53
Signed-off-by: Juan Manuel Leflet Estrada <[email protected]>
Signed-off-by: Juan Manuel Leflet Estrada <[email protected]>
@jmle jmle changed the title Temptative solution for basic annotation inspection 🐛 Temptative solution for basic annotation inspection Jun 21, 2024
@jmle jmle requested a review from abrugaro June 21, 2024 12:33
jmle added 3 commits June 21, 2024 16:38
Signed-off-by: Juan Manuel Leflet Estrada <[email protected]>
Signed-off-by: Juan Manuel Leflet Estrada <[email protected]>
Signed-off-by: Juan Manuel Leflet Estrada <[email protected]>
@jmle jmle closed this Jul 2, 2024
@jmle jmle deleted the annotation-inspection branch July 16, 2024 13:07
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.

Add the ability to query on annotation information
2 participants