Skip to content

Java decorators #214

@paraniraja

Description

@paraniraja

In Java project, decorators are not added to node.

Below is the analysis from codewiki.google

====

Looking at the _extract_decorators method in codebase_rag/parsers/definition_processor.py, it specifically checks for Tree-sitter node types related to Python (cs.TS_PY_DECORATED_DEFINITION, cs.TS_PY_DECORATOR, cs.TS_PY_IDENTIFIER, cs.TS_PY_ATTRIBUTE, cs.TS_PY_CALL).

For Java, while the JavaTypeInferenceEngine in codebase_rag/parsers/java/type_inference.py has a _build_fqn_lookup_map method and other type inference capabilities, there isn't an explicit implementation of _extract_decorators for Java within the provided code.

Therefore, although Java annotations are mentioned as being extracted by extract_method_info and extract_field_info in codebase_rag/parsers/java/utils.py, the generic _extract_decorators method inherited by the ingestion mixins would not populate the KEY_DECORATORS property for Java nodes. This suggests that the current implementation doesn't yet fully integrate Java annotation extraction into the general decorators field for node properties.

====

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions