Class ApplicationConfiguration

  • All Implemented Interfaces:
    com.google.gwt.core.client.EntryPoint

    public class ApplicationConfiguration
    extends Object
    implements com.google.gwt.core.client.EntryPoint
    • Constructor Detail

      • ApplicationConfiguration

        public ApplicationConfiguration()
    • Method Detail

      • useServiceUrlPathParam

        public boolean useServiceUrlPathParam()
        Checks whether path info in requests to the server-side service should be in a request parameter (named v-resourcePath) or appended to the end of the service URL.
        Returns:
        true if path info should be a request parameter; false if the path info goes after the service URL
        See Also:
        getServiceUrl()
      • getServiceUrlParameterName

        public String getServiceUrlParameterName()
        Return the name of the parameter used to to send data to the service url. This method should only be called if useServiceUrlPathParam() is true.
        Returns:
        The parameter name, by default v-resourcePath
        Since:
        7.1.6
      • getRootPanelId

        public String getRootPanelId()
      • getServiceUrl

        public String getServiceUrl()
        Gets the URL to the server-side VaadinService. If useServiceUrlPathParam() return true, the requested path info should be in the v-resourcePath query parameter; else the path info should be appended to the end of the URL.
        Returns:
        the URL to the server-side service as a string
        See Also:
        useServiceUrlPathParam()
      • getVaadinDirUrl

        public String getVaadinDirUrl()
        Gets the URL of the VAADIN directory on the server.
        Returns:
        the URL of the VAADIN directory
      • setAppId

        public void setAppId​(String appId)
      • getUIDL

        public String getUIDL()
        Gets the initial UIDL from the DOM, if it was provided during the init process.
        Returns:
      • isStandalone

        public boolean isStandalone()
        Returns:
        true if the application is served by std. Vaadin servlet and is considered to be the only or main content of the host page.
      • getUIId

        public int getUIId()
        Gets the UI id of the server-side UI associated with this client-side instance. The UI id should be included in every request originating from this instance in order to associate the request with the right UI instance on the server.
        Returns:
        the UI id
      • getHeartbeatInterval

        public int getHeartbeatInterval()
        Returns:
        The interval in seconds between heartbeat requests, or a non-positive number if heartbeat is disabled.
      • getVersionInfoJSObject

        public com.google.gwt.core.client.JavaScriptObject getVersionInfoJSObject()
      • startApplication

        public static void startApplication​(String applicationId)
        Starts the application with a given id by reading the configuration options stored by the bootstrap javascript.
        Parameters:
        applicationId - id of the application to load, this is also the id of the html element into which the application should be rendered.
      • getServletVersion

        public String getServletVersion()
      • getAtmosphereVersion

        public String getAtmosphereVersion()
        Return Atmosphere version.
        Returns:
        Atmosphere version.
        Since:
        7.4
      • getAtmosphereJSVersion

        public String getAtmosphereJSVersion()
        Return Atmosphere JS version.
        Returns:
        Atmosphere JS version.
        Since:
        7.4
      • getConnectorClassByEncodedTag

        public Class<? extends ServerConnector> getConnectorClassByEncodedTag​(int tag)
      • addComponentInheritanceInfo

        public void addComponentInheritanceInfo​(ValueMap valueMap)
      • addComponentMappings

        public void addComponentMappings​(ValueMap valueMap,
                                         WidgetSet widgetSet)
      • getTagsForServerSideClassName

        public Integer[] getTagsForServerSideClassName​(String classname)
        Returns all tags for given class. Tags are used in ApplicationConfiguration to keep track of different classes and their hierarchy
        Parameters:
        classname - name of class which tags we want
        Returns:
        Integer array of tags pointing to this classname
        Since:
        7.2
      • getParentTag

        public Integer getParentTag​(int tag)
      • getServerSideClassNameForTag

        public String getServerSideClassNameForTag​(Integer tag)
      • runWhenDependenciesLoaded

        public static void runWhenDependenciesLoaded​(com.google.gwt.user.client.Command c)
        Parameters:
        c -
        Since:
        7.6
      • onModuleLoad

        public void onModuleLoad()
        Specified by:
        onModuleLoad in interface com.google.gwt.core.client.EntryPoint
      • registerCallback

        public static void registerCallback​(String widgetsetName)
        Registers that callback that the bootstrap javascript uses to start applications once the widgetset is loaded and all required information is available
        Parameters:
        widgetsetName - the name of this widgetset
      • isDebugMode

        public static boolean isDebugMode()
        Checks if client side is in debug mode. Practically this is invoked by adding ?debug parameter to URI. Please note that debug mode is always disabled if production mode is enabled, but disabling production mode does not automatically enable debug mode.
        Returns:
        true if client side is currently been debugged
        See Also:
        isProductionMode()
      • isProductionMode

        public static boolean isProductionMode()
        Checks if production mode is enabled. When production mode is enabled, client-side logging is disabled. There may also be other performance optimizations.
        Returns:
        true if production mode is enabled; otherwise false.
        Since:
        7.1.2
      • isQuietDebugMode

        public static boolean isQuietDebugMode()
        Checks whether debug logging should be quiet
        Returns:
        true if debug logging should be quiet
      • isWidgetsetVersionSent

        public boolean isWidgetsetVersionSent()
        Checks whether the widget set version has been sent to the server. It is sent in the first UIDL request.
        Returns:
        true if browser information has already been sent
      • setWidgetsetVersionSent

        public void setWidgetsetVersionSent()
        Registers that the widget set version has been sent to the server.