Class AiRuntimeHints

java.lang.Object
org.springframework.ai.aot.AiRuntimeHints

public abstract class AiRuntimeHints extends Object
Utility methods for creating native runtime hints. See other modules for their respective native runtime hints.
Author:
Josh Long, Christian Tzolov, Mark Pollack
  • Constructor Details

    • AiRuntimeHints

      public AiRuntimeHints()
  • Method Details

    • findJsonAnnotatedClassesInPackage

      public static Set<org.springframework.aot.hint.TypeReference> findJsonAnnotatedClassesInPackage(String packageName)
      Finds classes in a package that are annotated with JsonInclude or have Jackson annotations.
      Parameters:
      packageName - The name of the package to search for annotated classes.
      Returns:
      A set of TypeReference objects representing the annotated classes found.
    • findJsonAnnotatedClassesInPackage

      public static Set<org.springframework.aot.hint.TypeReference> findJsonAnnotatedClassesInPackage(Class<?> packageClass)
      Finds classes in a package that are annotated with JsonInclude or have Jackson annotations.
      Parameters:
      packageClass - The class in the package to search for annotated classes.
      Returns:
      A set of TypeReference objects representing the annotated classes found.
    • findClassesInPackage

      public static Set<org.springframework.aot.hint.TypeReference> findClassesInPackage(String packageName, org.springframework.core.type.filter.TypeFilter typeFilter)
      Finds all classes in the specified package that match the given type filter.
      Parameters:
      packageName - The name of the package to scan for classes.
      typeFilter - The type filter used to filter the scanned classes.
      Returns:
      A set of TypeReference objects representing the found classes.