Class LabelSearchProvider

    • Constructor Detail

      • LabelSearchProvider

        public LabelSearchProvider()
    • Method Detail

      • canSuggest

        public boolean canSuggest​(GraphService graphService,
                                  String namespace)
        Description copied from interface: SearchProvider
        Defines if the search can provide suggestions to the given namespace
        Specified by:
        canSuggest in interface SearchProvider
        namespace - The namespace to make suggestions to.
        Returns:
        True if suggestions can be made, false otherwise
      • getSuggestions

        public List<SearchSuggestion> getSuggestions​(SearchContext searchContext,
                                                     String namespace,
                                                     String input)
        Description copied from interface: SearchProvider
        Provide suggestions for the given namespace, given the input. Be aware that the input may only contain snippets of the actual input, e.g. `Rout` instead of `Routers` (type ahead).
        Specified by:
        getSuggestions in interface SearchProvider
        Parameters:
        searchContext - The SearchContext to allow access to graphs and other configuration
        namespace - The namespace of the current selected provider to make mappings
        input - The current input, may be a snippet of the final input for type ahead support. It is never null or empty.
        Returns:
        A list of suggestions the SearchProvider can use later to resolve to actual Vertices. Be aware, that this should only return actual results, e.g. "Routers" when input was "Rout".
      • resolve

        public List<GenericVertex> resolve​(GraphService graphService,
                                           SearchCriteria searchCriteria)
        Description copied from interface: SearchProvider
        Resolves the given SearchCriteria to a list of vertices.
        Specified by:
        resolve in interface SearchProvider
        Parameters:
        graphService - The GraphService to get access to a graph
        searchCriteria - The SearchCriteria to resolve
        Returns:
        A list of vertices matching the SearchCriteria.