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

Add a method that can get the reference class name, and add the parsing of generics based on the #getRefClasses method. #451

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

kiteeel
Copy link

@kiteeel kiteeel commented Mar 25, 2023

We require the fully qualified name on the classes referenced by a specific class. However, the CtClass#getRefClasses method appears to overlook the analysis of generic objects. To illustrate this issue, let us take the following classes as an example.
If we utilize the CtClass#getRefClasses method for the DemoB class, the returned collection solely comprises java.util.List.
However, with the incorporation of the latest CtClass#getAllRefClasses method, the returned collection comprises java.util.List and com.kite.DemoA.
Therefore, I kindly request you to consider and merge this pull request.

package com.kite;

import java.util.List;

public class DemoA {
    // ignored
}

interface DemoB{
    List<DemoA> getList();
}

…lass name, and add the parsing of generics based on the #getRefClasses method.
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