Class Parser

java.lang.Object
com.vaadin.hilla.parser.core.Parser

@Deprecated public final class Parser extends Object
Deprecated.
Internal API, not deprecated for removal. The Java API of hilla-typescript-generator is used only by Hilla itself, and may change or be removed in any release without notice. Do not use it in application code or libraries. It is marked deprecated only to make the compiler warn about such use.
The entrypoint class. It walks the browser callable classes of the application, letting the plugins build what the TypeScript of them is written from.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static final class 
    Deprecated.
    An immutable parser configuration object.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Deprecated.
     
  • Method Summary

    Modifier and Type
    Method
    Description
    @NonNull Parser
    addPlugin(@NonNull Plugin plugin)
    Deprecated.
    Adds a parser Plugin.
    @NonNull Parser
    classPath(@NonNull String... classPathElements)
    Deprecated.
    Specifies the classpath where the parser will scan for endpoints.
    @NonNull Parser
    classPath(@NonNull String[] classPathElements, boolean override)
    Deprecated.
    Specifies the classpath where the parser will scan for endpoints.
    @NonNull Parser
    classPath(@NonNull Collection<String> classPathElements)
    Deprecated.
    Specifies the classpath where the parser will scan for endpoints.
    @NonNull Parser
    classPath(@NonNull Collection<String> classPathElements, boolean override)
    Deprecated.
    Specifies the classpath where the parser will scan for endpoints.
    @NonNull Parser
    endpointAnnotations(@NonNull List<Class<? extends Annotation>> annotations)
    Deprecated.
    Specifies the name of the endpoint annotation by which the parser will search for the endpoints.
    @NonNull Parser
    endpointAnnotations(@NonNull List<Class<? extends Annotation>> annotations, boolean override)
    Deprecated.
    Specifies the name of the endpoint annotation by which the parser will search for the endpoints.
    @NonNull Parser
    endpointExposedAnnotations(@NonNull List<Class<? extends Annotation>> annotations)
    Deprecated.
    Specifies the name of the `EndpointExposed` annotation by which the parser will detect if the endpoint superclass should be considered as the part of the endpoint.
    @NonNull Parser
    endpointExposedAnnotations(@NonNull List<Class<? extends Annotation>> annotations, boolean override)
    Deprecated.
    Specifies the name of the `EndpointExposed` annotation by which the parser will detect if the endpoint superclass should be considered as the part of the endpoint.
    void
    execute(List<Class<?>> browserCallables)
    Deprecated.
    Scans the classpath, blocking until the scan is complete.
    @NonNull Parser.Config
    Deprecated.
    Gets the internal configuration object.
    @NonNull Parser
    plugins(@NonNull Plugin... plugins)
    Deprecated.
    Adds a collection of parser Plugins.
    @NonNull Parser
    plugins(@NonNull Collection<? extends Plugin> plugins)
    Deprecated.
    Adds a collection of parser Plugins.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Parser

      public Parser()
      Deprecated.
  • Method Details

    • addPlugin

      public @NonNull Parser addPlugin(@NonNull Plugin plugin)
      Deprecated.
      Adds a parser Plugin.

      Note that the order of the method calls will be maintained during processing.

      Parameters:
      plugin - An instance of the parser plugin.
      Returns:
      this (for method chaining).
    • classPath

      public @NonNull Parser classPath(@NonNull String... classPathElements)
      Deprecated.
      Specifies the classpath where the parser will scan for endpoints. Specifying the classpath is required.

      If the classpath is already set, it will be overridden.

      Parameters:
      classPathElements - a list of paths forming the classpath.
      Returns:
      this (for method chaining).
    • classPath

      public @NonNull Parser classPath(@NonNull String[] classPathElements, boolean override)
      Deprecated.
      Specifies the classpath where the parser will scan for endpoints. Specifying the classpath is required.
      Parameters:
      classPathElements - a list of paths forming the classpath.
      override - specifies if the parser should override the classpath if it is already specified.
      Returns:
      this (for method chaining).
    • classPath

      public @NonNull Parser classPath(@NonNull Collection<String> classPathElements)
      Deprecated.
      Specifies the classpath where the parser will scan for endpoints. Specifying the classpath is required.

      If the classpath is already set, it will be overridden.

      Parameters:
      classPathElements - a list of paths forming the classpath.
      Returns:
      this (for method chaining).
    • classPath

      public @NonNull Parser classPath(@NonNull Collection<String> classPathElements, boolean override)
      Deprecated.
      Specifies the classpath where the parser will scan for endpoints. Specifying the classpath is required.
      Parameters:
      classPathElements - a list of paths forming the classpath.
      override - specifies if the parser should override the classpath if it is already specified.
      Returns:
      this (for method chaining).
    • endpointAnnotations

      public @NonNull Parser endpointAnnotations(@NonNull List<Class<? extends Annotation>> annotations)
      Deprecated.
      Specifies the name of the endpoint annotation by which the parser will search for the endpoints. Only classes with this annotation will be chosen.

      If the annotation name is already set, it will be overridden.

      Parameters:
      annotations - The fully qualified names of the annotations
      Returns:
      this (for method chaining).
    • endpointAnnotations

      public @NonNull Parser endpointAnnotations(@NonNull List<Class<? extends Annotation>> annotations, boolean override)
      Deprecated.
      Specifies the name of the endpoint annotation by which the parser will search for the endpoints. Only classes with this annotation will be chosen.
      Parameters:
      annotations - The fully qualified names of the annotations
      override - specifies if the parser should override the annotation name if it is already specified.
      Returns:
      this (for method chaining).
    • endpointExposedAnnotations

      public @NonNull Parser endpointExposedAnnotations(@NonNull List<Class<? extends Annotation>> annotations)
      Deprecated.
      Specifies the name of the `EndpointExposed` annotation by which the parser will detect if the endpoint superclass should be considered as the part of the endpoint. Any superclass in the endpoint's inheritance chain will be skipped if it doesn't have this annotation.

      If the annotation name is already set, it will be overridden.

      Parameters:
      annotations - The fully qualified names of the annotations
      Returns:
      this (for method chaining).
    • endpointExposedAnnotations

      public @NonNull Parser endpointExposedAnnotations(@NonNull List<Class<? extends Annotation>> annotations, boolean override)
      Deprecated.
      Specifies the name of the `EndpointExposed` annotation by which the parser will detect if the endpoint superclass should be considered as the part of the endpoint. Any superclass in the endpoint's inheritance chain will be skipped if it doesn't have this annotation.
      Parameters:
      annotations - The fully qualified names of the annotations
      override - specifies if the parser should override the annotation name if it is already specified.
      Returns:
      this (for method chaining).
    • execute

      public void execute(List<Class<?>> browserCallables)
      Deprecated.
      Scans the classpath, blocking until the scan is complete. What the walk finds is left to the plugins: the parser itself keeps nothing of it.
    • getConfig

      public @NonNull Parser.Config getConfig()
      Deprecated.
      Gets the internal configuration object.
      Returns:
      configuration object.
    • plugins

      public @NonNull Parser plugins(@NonNull Plugin... plugins)
      Deprecated.
      Adds a collection of parser Plugins. If there are plugins already specified, they will be removed before addition.

      Note that the order of the arguments will be maintained during processing.

      Parameters:
      plugins - a collection of parser plugins.
      Returns:
      this (for method chaining).
    • plugins

      public @NonNull Parser plugins(@NonNull Collection<? extends Plugin> plugins)
      Deprecated.
      Adds a collection of parser Plugins. If there are already specified plugins, they will be removed before addition.

      Note that the order of collection will be maintained during processing.

      Parameters:
      plugins - a collection of parser plugins.
      Returns:
      this (for method chaining).