Class ScanTypeInfoFactory

java.lang.Object
io.helidon.codegen.TypeInfoFactoryBase
io.helidon.codegen.scan.ScanTypeInfoFactory

public final class ScanTypeInfoFactory extends TypeInfoFactoryBase
Factory to analyze processed types and to provide TypeInfo for them.
  • Method Details

    • create

      public static Optional<TypeInfo> create(ScanContext ctx, TypeName typeName)
      Create type information for a type name, reading all child elements.
      Parameters:
      ctx - annotation processor processing context
      typeName - type name to find
      Returns:
      type info for the type element
      Throws:
      IllegalArgumentException - when the element cannot be resolved into type info (such as if you ask for a primitive type)
    • create

      public static Optional<TypeInfo> create(ScanContext ctx, TypeName typeName, Predicate<TypedElementInfo> elementPredicate) throws IllegalArgumentException
      Create type information for a type name.
      Parameters:
      ctx - annotation processor processing environment
      typeName - type name to find
      elementPredicate - predicate for child elements
      Returns:
      type info for the type element, or empty if it cannot be resolved
      Throws:
      IllegalArgumentException
    • create

      public static Optional<TypeInfo> create(ScanContext ctx, io.github.classgraph.ClassInfo classInfo)
      Create type information from a type element, reading all child elements.
      Parameters:
      ctx - annotation processor processing context
      classInfo - type element of the type we want to analyze
      Returns:
      type info for the type element
      Throws:
      IllegalArgumentException - when the element cannot be resolved into type info (such as if you ask for a primitive type)
    • create

      public static Optional<TypeInfo> create(ScanContext ctx, io.github.classgraph.ClassInfo classInfo, Predicate<TypedElementInfo> elementPredicate) throws IllegalArgumentException
      Create type information from a type element.
      Parameters:
      ctx - annotation processor processing context
      classInfo - type element of the type we want to analyze
      elementPredicate - predicate for child elements
      Returns:
      type info for the type element, or empty if it cannot be resolved
      Throws:
      IllegalArgumentException