com.vaadin.ui.

Class Dependency

    • Constructor Detail

      • Dependency

        public Dependency​(Dependency.Type type,
                          String url)

        Creates a new dependency of the given type, to be loaded from the given URL.

        The URL is passed through the translation mechanism before loading, so custom protocols such as "vaadin://" can be used.

        Parameters:

        type - the type of dependency, not null

        url - the URL to load the dependency from, not null

    • Method Detail

      • getUrl

        public String getUrl()

        Gets the untranslated URL for the dependency.

        Returns:

        the URL for the dependency

      • getType

        public Dependency.Type getType()

        Gets the type of the dependency.

        Returns:

        the type of the dependency

      • findDependencies

        public static List<Dependency> findDependencies​(List<Class<? extends ClientConnector>> connectorTypes,
                                                        LegacyCommunicationManager manager,
                                                        DependencyFilter.FilterContext context)

        Finds all the URLs defined for the given classes, registers the URLs to the communication manager, passes the registered dependencies through any defined filters and returns the filtered collection of dependencies to load.

        Parameters:

        connectorTypes - the collection of connector classes to scan

        manager - a reference to the communication manager which tracks dependencies

        context - the context information for the filtering operation

        Returns:

        the list of found and filtered dependencies

        Since:

        8.1