Class UiExtension.Builder

  • Enclosing class:
    UiExtension

    public static class UiExtension.Builder
    extends Object
    UI Extension Builder.
    • Constructor Detail

      • Builder

        public Builder​(ClassLoader cl,
                       List<UiView> views)
        Create a builder with the given class loader. Resource path defaults to "". Views defaults to an empty list. MessageHandler, TopoOverlay, and TopoMap factories default to null.
        Parameters:
        cl - the class loader
        views - list of views contributed by this extension
    • Method Detail

      • lionBundles

        public UiExtension.Builder lionBundles​(List<LionBundle> bundles)
        Sets the localization bundles (aka LionBundles) that this UI extension is contributing.
        Parameters:
        bundles - the bundles to register
        Returns:
        self, for chaining
      • resourcePath

        public UiExtension.Builder resourcePath​(String path)
        Set the resource path. That is, the path to where the CSS and JS files are located.
        Parameters:
        path - resource path
        Returns:
        self, for chaining
      • messageHandlerFactory

        public UiExtension.Builder messageHandlerFactory​(UiMessageHandlerFactory mhFactory)
        Sets the message handler factory for this extension.
        Parameters:
        mhFactory - message handler factory
        Returns:
        self, for chaining
      • topoOverlayFactory

        public UiExtension.Builder topoOverlayFactory​(UiTopoOverlayFactory toFactory)
        Sets the topology overlay factory for this extension.
        Parameters:
        toFactory - topology overlay factory
        Returns:
        self, for chaining
      • topo2OverlayFactory

        public UiExtension.Builder topo2OverlayFactory​(UiTopo2OverlayFactory to2Factory)
        Sets the topology-2 overlay factory for this extension.
        Parameters:
        to2Factory - topology-2 overlay factory
        Returns:
        self, for chaining
      • topoMapFactory

        public UiExtension.Builder topoMapFactory​(UiTopoMapFactory tmFactory)
        Sets the topology map factory for this extension.
        Parameters:
        tmFactory - topology map factory
        Returns:
        self, for chaining
      • ui2

        public UiExtension.Builder ui2()
        Marks this as ui2valid for Ui2. This is because Ui2 does not include the same layout of embedded html, js and css
        Returns:
        self, for chaining
      • build

        public UiExtension build()
        Builds the user interface extension.
        Returns:
        UI extension instance