Create a List Provider

Create a List Provider

The following describes the steps specific to creating a List Provider plugin. For steps on creating and installing a plugin, see the Create a plugin topic. Although it focuses on Java development, the same steps can be followed for .Net (with slight implementation difference in certain areas of course).

For more information about List Provider plugins, see the topic, List Provider plugin.

Assets and information needed

The following are assets that are needed to develop the List Provider plugin, or information that will be referred to in the Steps section below:

 

Web Determinations library jars

 

Java IDE -  this is the Java development application you are using. While this is optional, it will make it much easier when referring to objects in the web-determinations.jar and determinations-interview-engine.jar.

 

Datasource - this is the datasource (or datasources) that this List Provider will connect to, to retrieve datasets for List control values.

 

Datasource library jars - the datasource may have Java jar library files that is required for the List Provider.

 

Datasource connection details - the List Provider plugin will need to be able to connect to the datasource, so connection details must be known. This might be a specific port in a server; for example, //server:portnumber/databasename.

Steps

Analyze and design:

Before starting on the development of the plugin, read the List Provider plugin topic to understand the List Provider plugin.

Once familiarized with the List Provider plugin, do the following: 

  1. Determine what rulebase (or rulebases) the List Provider will service.
  2. Determine which attributes in the rulebase/s will need the List Provider, and whether the List Provider relies on other requirements; for example, the current locale, a certain goal attribute has to be known, and so on.
  3. Map out how the List Provider will connect and interact with the datasource, including transaction integrity processes, fallback on error, and so on.
  4. Design how the List Provider will retrieve datasets from the datasource; for example a map might be created where a List Control attribute determines the table/columns to use for data retrieval (see List Provider - sample code).

 

Develop

  1. Set up the Java IDE so that it has the Web Determinations library jars and Datasource library jars. This makes it easier to refer to objects for the Web Determinations or the datasource.
  2. Start the List Provider plugin class from the following pseudo code - List Provider - pseudo code.
  3. Develop the List Provider plugin based on the Analyze and design section above.

 

Install and test

For steps on installing the List Provider and testing, see the topic, Create a plugin.