Skip to content

Commit 35e3a22

Browse files
authored
Merge pull request #32 from IBM/add-method
revert uncomment code
2 parents 4125358 + 5316c3c commit 35e3a22

1 file changed

Lines changed: 29 additions & 33 deletions

File tree

cldk/analysis/java/java.py

Lines changed: 29 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -83,14 +83,10 @@ def get_variables(self, **kwargs):
8383
raise NotImplementedError(f"Support for this functionality has not been implemented yet.")
8484

8585
def get_service_entry_point_classes(self, **kwargs):
86-
if self.analysis_backend in [AnalysisEngine.CODEQL, AnalysisEngine.TREESITTER]:
87-
raise NotImplementedError(f"Support for this functionality has not been implemented yet.")
88-
return self.backend.get_all_entry_point_classes()
86+
raise NotImplementedError(f"Support for this functionality has not been implemented yet.")
8987

9088
def get_service_entry_point_methods(self, **kwargs):
91-
if self.analysis_backend in [AnalysisEngine.CODEQL, AnalysisEngine.TREESITTER]:
92-
raise NotImplementedError(f"Support for this functionality has not been implemented yet.")
93-
return self.backend.get_all_entry_point_methods()
89+
raise NotImplementedError(f"Support for this functionality has not been implemented yet.")
9490

9591
def get_application_view(self) -> JApplication:
9692
"""
@@ -487,33 +483,33 @@ def get_class_call_graph(self, qualified_class_name: str, method_signature: str
487483
raise NotImplementedError(f"Support for this functionality has not been implemented yet.")
488484
return self.backend.get_class_call_graph(qualified_class_name, method_signature)
489485

490-
# def get_entry_point_classes(self) -> Dict[str, JType]:
491-
# """
492-
# Returns a dictionary of all entry point classes in the Java code.
493-
#
494-
# Returns:
495-
# --------
496-
# Dict[str, JType]
497-
# A dict of all entry point classes in the Java code, with qualified class names as keys
498-
# """
499-
# if self.analysis_backend in [AnalysisEngine.CODEQL, AnalysisEngine.TREESITTER]:
500-
# raise NotImplementedError(f"Support for this functionality has not been implemented yet.")
501-
# return self.backend.get_all_entry_point_classes()
502-
#
503-
# def get_entry_point_methods(self) -> Dict[str, Dict[str, JCallable]]:
504-
# """
505-
# Returns a dictionary of all entry point methods in the Java code with
506-
# qualified class name as key and dictionary of methods in that class
507-
# as value
508-
#
509-
# Returns:
510-
# --------
511-
# Dict[str, Dict[str, JCallable]]:
512-
# A dictionary of dictionaries of entry point methods in the Java code.
513-
# """
514-
# if self.analysis_backend in [AnalysisEngine.CODEQL, AnalysisEngine.TREESITTER]:
515-
# raise NotImplementedError(f"Support for this functionality has not been implemented yet.")
516-
# return self.backend.get_all_entry_point_methods()
486+
def get_entry_point_classes(self) -> Dict[str, JType]:
487+
"""
488+
Returns a dictionary of all entry point classes in the Java code.
489+
490+
Returns:
491+
--------
492+
Dict[str, JType]
493+
A dict of all entry point classes in the Java code, with qualified class names as keys
494+
"""
495+
if self.analysis_backend in [AnalysisEngine.CODEQL, AnalysisEngine.TREESITTER]:
496+
raise NotImplementedError(f"Support for this functionality has not been implemented yet.")
497+
return self.backend.get_all_entry_point_classes()
498+
499+
def get_entry_point_methods(self) -> Dict[str, Dict[str, JCallable]]:
500+
"""
501+
Returns a dictionary of all entry point methods in the Java code with
502+
qualified class name as key and dictionary of methods in that class
503+
as value
504+
505+
Returns:
506+
--------
507+
Dict[str, Dict[str, JCallable]]:
508+
A dictionary of dictionaries of entry point methods in the Java code.
509+
"""
510+
if self.analysis_backend in [AnalysisEngine.CODEQL, AnalysisEngine.TREESITTER]:
511+
raise NotImplementedError(f"Support for this functionality has not been implemented yet.")
512+
return self.backend.get_all_entry_point_methods()
517513

518514
def remove_all_comments(self) -> str:
519515
"""

0 commit comments

Comments
 (0)