Class NetBeansJavaQueryUtils
java.lang.Object
uno.anahata.ai.nb.util.NetBeansJavaQueryUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic ClassSearchResultfindClassFile(String classAsPath) Finds the FileObject corresponding to the compiled class file for a given FQN.static org.openide.filesystems.FileObjectfindSourceFile(String fqn) Finds the FileObject corresponding to the source file for a given FQN.
-
Constructor Details
-
NetBeansJavaQueryUtils
public NetBeansJavaQueryUtils()
-
-
Method Details
-
findSourceFile
Finds the FileObject corresponding to the source file for a given FQN. This is a low-level utility for bridging a class name to its source file.- Parameters:
fqn- The fully qualified class name.- Returns:
- The FileObject of the source file, or null if not found.
- Throws:
Exception- if an error occurs.
-
findClassFile
Finds the FileObject corresponding to the compiled class file for a given FQN. This is a low-level utility that searches all registered classpaths.- Parameters:
classAsPath- The path to the class file (e.g., java/lang/String.class).- Returns:
- A ClassSearchResult containing the FileObject and its ClassPath, or null if not found.
-
