Class CustomComponentDetector

java.lang.Object
com.vaadin.copilot.customcomponent.CustomComponentDetector

public final class CustomComponentDetector extends Object
Provides information about component is whether a custom component or not. Once custom component is detected, it is stored in CustomComponents where it can be accessed statically from anywhere
  • Method Details

    • detectAndPutIfPresent

      public static void detectAndPutIfPresent(com.vaadin.flow.component.Component component, com.vaadin.flow.server.VaadinSession vaadinSession)
      Detects if given class is a custom component class. If it is a custom component, it is saved and can be accessible in CustomComponents
      Parameters:
      component - Component to put into the customComponentsMap
      vaadinSession - the VaadinSession
    • detectAndPutIfPresent

      public static void detectAndPutIfPresent(com.vaadin.flow.server.VaadinSession vaadinSession, Class<?> componentClass)
      Detects if given class is a custom component class. If it is a custom component, it is saved and can be accessible in CustomComponents
      Parameters:
      vaadinSession - the session to get the classes from
      componentClass - Component class