Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.tibco.forms.client
Class FormRunner

    java.lang.Object
      com.tibco.forms.client.FormRunner

    public final class FormRunner

extends java.lang.Object

Main class that provides API access to TIBCO Forms.

Since:
  2.2.2

Method Summary
`static void` | `loadForm(java.lang.String formURL, java.lang.String initialData, java.lang.String bomJSPath, java.lang.String locale, java.lang.String parentNodeId, FormLoaderCallbackHandler handler)` Loads the Form at the given URL and adds it to the node specified.
`static void` | `loadForm(java.lang.String formURL, java.lang.String initialData, java.lang.String bomJSPath, java.lang.String locale, java.lang.String parentNodeId, FormLoaderCallbackHandler handler, boolean useJSONPadding)` Loads the Form at the given URL and adds it to the node specified.
`static void` | `loadFormWithRemoteData(java.lang.String formURL, java.lang.String initDataURL, java.lang.String bomJSPath, java.lang.String locale, java.lang.String parentNodeId, FormLoaderCallbackHandler handler)` Loads the Form at the given URL and adds it to the node specified.
`static void` | `loadFormWithRemoteData(java.lang.String formURL, java.lang.String initDataURL, java.lang.String bomJSPath, java.lang.String locale, java.lang.String parentNodeId, FormLoaderCallbackHandler handler, boolean useJSONPadding)` Loads the Form at the given URL and adds it to the node specified.
`static void` | `renderStaticView(java.lang.String initialData, java.lang.String bomJSPath, java.lang.String locale, java.lang.String parentNodeId, FormLoaderCallbackHandler handler, boolean provideCloseAction, boolean useJSONP)` Renders a tree representation of the data provided in the initialData parameter.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Method Detail

### loadForm

    public static void loadForm(java.lang.String formURL,
                                java.lang.String initialData,
                                java.lang.String bomJSPath,
                                java.lang.String locale,
                                java.lang.String parentNodeId,
                                FormLoaderCallbackHandler handler)

  Loads the Form at the given URL and adds it to the node specified. It is the responsibility of the client application to clear any previous Forms from this node prior to adding the new one.

  Parameters:
    `formURL` - URL to the Form model.
    `initialData` - JSON representation of the initial data to be loaded in the Form.
    `bomJSPath` - The root folder path to be used for loading the BOM JavScript files used by the form.
    `locale` - The locale to be used in the form runtime. The language code and country code must be normalised in such a way that the language codes are always two digit and in lowercase(ISO-639), country codes are always two digit and in upper case(ISO-3166). Both '_' and '-' are supported as delimiters.
    `parentNodeId` - Pass in the DOM id of the node to which the form should be added. e.g. this may be specified in HTML with something like <div id="myNodeName"></div>.
    `handler` - The handler to be notified when the form loading is complete or fails.
  See Also:
    `FormLoaderCallbackHandler`

### loadForm

    public static void loadForm(java.lang.String formURL,
                                java.lang.String initialData,
                                java.lang.String bomJSPath,
                                java.lang.String locale,
                                java.lang.String parentNodeId,
                                FormLoaderCallbackHandler handler,
                                boolean useJSONPadding)

  Loads the Form at the given URL and adds it to the node specified. It is the responsibility of the client application to clear any previous Forms from this node prior to adding the new one.

  Parameters:
    `formURL` - URL to the Form model.
    `initialData` - JSON representation of the initial data to be loaded in the Form.
    `bomJSPath` - The root folder path to be used for loading the BOM JavScript files used by the form.
    `locale` - The locale to be used in the form runtime. The language code and country code must be normalised in such a way that the language codes are always two digit and in lowercase(ISO-639), country codes are always two digit and in upper case(ISO-3166). Both '_' and '-' are supported as delimiters.
    `parentNodeId` - Pass in the DOM id of the node to which the form should be added. e.g. this may be specified in HTML with something like <div id="myNodeName"></div>.
    `handler` - The handler to be notified when the form loading is complete or fails.
    `useJSONPadding` - If JSON with Padding technique to be used while retrieving JSON resources. Need to use this when FormRunner is hosted on a different domain than the current page.
  See Also:
    `FormLoaderCallbackHandler`

### loadFormWithRemoteData

    public static void loadFormWithRemoteData(java.lang.String formURL,
                                              java.lang.String initDataURL,
                                              java.lang.String bomJSPath,
                                              java.lang.String locale,
                                              java.lang.String parentNodeId,
                                              FormLoaderCallbackHandler handler)

  Loads the Form at the given URL and adds it to the node specified. It is the responsibility of the client application to clear any previous Forms from this node prior to adding the new one.

  Parameters:
    `formURL` - URL to the Form model.
    `initDataURL` - URL to the form initial JSON data.
    `bomJSPath` - The root folder path to be used for loading the BOM JavScript files used by the form.
    `locale` - The locale to be used in the form runtime. The language code and country code must be normalised in such a way that the language codes are always two digit and in lowercase(ISO-639), country codes are always two digit and in upper case(ISO-3166). Both '_' and '-' are supported as delimiters.
    `parentNodeId` - Pass in the DOM id of the node to which the form should be added. e.g. this may be specified in HTML with something like <div id="myNodeName"></div>.
    `handler` - The handler to be notified when the form loading is complete or fails.
  See Also:
    `FormLoaderCallbackHandler`

### loadFormWithRemoteData

    public static void loadFormWithRemoteData(java.lang.String formURL,
                                              java.lang.String initDataURL,
                                              java.lang.String bomJSPath,
                                              java.lang.String locale,
                                              java.lang.String parentNodeId,
                                              FormLoaderCallbackHandler handler,
                                              boolean useJSONPadding)

  Loads the Form at the given URL and adds it to the node specified. It is the responsibility of the client application to clear any previous Forms from this node prior to adding the new one.

  Parameters:
    `formURL` - URL to the Form model.
    `initDataURL` - URL to the form initial JSON data.
    `bomJSPath` - The root folder path to be used for loading the BOM JavScript files used by the form.
    `locale` - The locale to be used in the form runtime. The language code and country code must be normalised in such a way that the language codes are always two digit and in lowercase(ISO-639), country codes are always two digit and in upper case(ISO-3166). Both '_' and '-' are supported as delimiters.
    `parentNodeId` - Pass in the DOM id of the node to which the form should be added. e.g. this may be specified in HTML with something like <div id="myNodeName"></div>.
    `handler` - The handler to be notified when the form loading is complete or fails.
    `useJSONPadding` - If JSON with Padding technique to be used while retrieving JSON resources. Need to use this when FormRunner is hosted on a different domain than the current page.
  See Also:
    `FormLoaderCallbackHandler`

### renderStaticView

    public static void renderStaticView(java.lang.String initialData,
                                        java.lang.String bomJSPath,
                                        java.lang.String locale,
                                        java.lang.String parentNodeId,
                                        FormLoaderCallbackHandler handler,
                                        boolean provideCloseAction,
                                        boolean useJSONP)

  Renders a tree representation of the data provided in the initialData parameter.

  Parameters:
    `initialData` - Specifies the JSON representation of the initial data that are provided to the form.
    `bomJSPath` - Specifies the root folder path used for loading the BOM JavaScript files used by the form, e.g. "http://10.97.110.17:8080/bpmresources/1.0.0.201107291435"
    `locale` - Specifies the locale to be used in the form runtime with format [_] where [] denotes optionality, e.g. "en_US". The locale need to be represented such that is a valid two-character lowercase ISO-639 language code and if present the optional is a valid two-character upper case ISO-3166 country code. Both '_' and '-' are supported as delimiters.
    `parentNodeId` - Specifies the DOM identifier of the node to which the form should be added. The value cannot be null.
    `handler` - The handler to be notified when the work item form loading is complete or fails.
    `provideCloseAction` - - if true, the form will rendered with a button that will close the form and clean up any resources used. If false, then it is the responsibility of the containing application to clean up the form when no longer needed.
    `useJSONP` - Informs the Forms Runtime Adapter to use JSON with Padding (JSONP) when loading JSON resources. The default value is false. When the custom client and Forms Runtime Adapter are hosted on different servers, set the JSONP parameter as true. In this scenario, there are SOP (Single Origin Policy) issues while loading JSON resources. By using the JSONP technique, the JSON response is wrapped to a call to a function by the server and send to the client. A JSON resource can then be loaded using a script tag to avoid any SOP violations.
  Since:
    2.5.0

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2015 TIBCO Software Inc. All Rights Reserved.