Package com.vaadin.client.bootstrap
Class JsoConfiguration
java.lang.Object
com.google.gwt.core.client.JavaScriptObject
com.vaadin.client.bootstrap.JsoConfiguration
public final class JsoConfiguration
extends com.google.gwt.core.client.JavaScriptObject
Helper class for reading configuration options from the bootstrap javascript.
- Since:
- 1.0
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the JS version used in the Atmosphere framework.Gets the version of the Atmosphere framework.booleangetConfigBoolean(String name) Reads a configuration parameter as a boolean.getConfigError(String name) Reads a configuration parameter as anErrorMessageobject.getConfigInteger(String name) Reads a configuration parameter as an integer object.getConfigString(String name) Reads a configuration parameter as a string.String[]getConfigStringArray(String name) Reads a configuration parameter as a String array.getConfigValueMap(String name) Reads a configuration parameter as aValueMap.getUIDL()Gets the initial UIDL from the bootstrap page.Gets the version of the Vaadin framework used on the server.Methods inherited from class com.google.gwt.core.client.JavaScriptObject
cast, createArray, createArray, createFunction, createObject, equals, hashCode, toSource, toString
-
Constructor Details
-
JsoConfiguration
protected JsoConfiguration()
-
-
Method Details
-
getConfigString
Reads a configuration parameter as a string. Please note that the javascript value of the parameter should also be a string, or else an undefined exception may be thrown.- Parameters:
name- name of the configuration parameter- Returns:
- value of the configuration parameter, or
nullif not defined
-
getConfigValueMap
Reads a configuration parameter as aValueMap. Please note that the javascript value of the parameter should also be a javascript object, or else an undefined exception may be thrown.- Parameters:
name- name of the configuration parameter- Returns:
- value of the configuration parameter, or
nullif not defined
-
getConfigStringArray
Reads a configuration parameter as a String array.- Parameters:
name- name of the configuration parameter- Returns:
- value of the configuration parameter, or
nullif not defined
-
getConfigBoolean
Reads a configuration parameter as a boolean.Please note that the javascript value of the parameter should also be a boolean, or else an undefined exception may be thrown.
- Parameters:
name- name of the configuration parameter- Returns:
- the boolean value of the configuration parameter, or
falseif no value is defined
-
getConfigInteger
Reads a configuration parameter as an integer object. Please note that the javascript value of the parameter should also be an integer, or else an undefined exception may be thrown.- Parameters:
name- name of the configuration parameter- Returns:
- integer value of the configuration parameter, or
nullif no value is defined
-
getConfigError
Reads a configuration parameter as anErrorMessageobject. Please note that the javascript value of the parameter should also be an object with appropriate fields, or else an undefined exception may be thrown when calling this method or when calling methods on the returned object.- Parameters:
name- name of the configuration parameter- Returns:
- error message with the given name, or
nullif no value is defined
-
getVaadinVersion
Gets the version of the Vaadin framework used on the server.- Returns:
- a string with the version
-
getAtmosphereVersion
Gets the version of the Atmosphere framework.- Returns:
- a string with the version
-
getAtmosphereJSVersion
Gets the JS version used in the Atmosphere framework.- Returns:
- a string with the version
-
getUIDL
Gets the initial UIDL from the bootstrap page.- Returns:
- the initial UIDL
-