Oracle UIX API Reference
Release 2.1.22.0.0
B12196-01

oracle.cabo.ui.data.help
Class HelpProvider

java.lang.Object
  |
  +--oracle.cabo.ui.data.help.HelpProvider
All Implemented Interfaces:
DataProvider
Direct Known Subclasses:
SecondaryWindowHelpProvider

public abstract class HelpProvider
extends java.lang.Object
implements DataProvider

The HelpProvider abstract class provides flexible mechanism for enabling context-sensitive help from applications created with the UIX UI Components or UIX language. HelpProvider is a specialization of DataProvider that defines two standard DataObjects in the UIX UI namespace(helpTopics and helpSystem) and a set of standard keys.

Similar to most UI frameworks, context sensitive help in the UIX Framework is topic-id based. Developers use topic-ids in their pages and components, and these topic-ids are passed to the help technology which resolves the topic-id at runtime and displays the desired help topic. In UIX, developers will be able to use topic-ids as keys to the "helpTopics" DataObject when data-binding the destination attribute of various components (links, buttons, global buttons). In addition, the developer will be able to use the standard HelpProvider constant keys (like FRONT_PAGE_KEY) when data-binding destinations using the "helpSystem" DataObject to display navigation and system pages in the help system.

HelpProvider can be extended to support a variety of different help technologies. Subclasses only need to implement the selectHelpSystemValue() method and the selectHelpTopicsValue() method. Implementations can use various schemes to create the value returned for a given topic-id or system key (remember that the value will be used as a destination).

For example, a simple selectHelpTopicsValue() implementation would simply map the topic-ID to the URL of a static webpage, and return that string URL as the value. A HelpProvider subclass for a web-based help system, like the OracleHelpProvider, may choose to generate a URL off to a separate servlet and simply pass the topic-id as a parameter.

Most HelpProvider subclasses will wish to return a javascript pseudo URL that will launch a secondary window for displaying the help topics. See the SecondaryWindowHelpProvider abstract class for more information.

Developers should create an instance of a HelpProvider subclass and register the instance with the Configuration object. Once registered, the HelpProvider DataProvider will automatically be stored on the UIX UI Component's RenderingContext and be available for databinding from the UI Component's Java API and the UIX language.


Field Summary
static java.lang.String FRONT_PAGE_KEY
           
static java.lang.String HELP_SYSTEM_NAME
           
static java.lang.String HELP_TOPICS_NAME
           
 
Constructor Summary
HelpProvider()
           
 
Method Summary
 void cleanup(RenderingContext context)
          HelpProvider cleanup() implementation, public as a result of DataProvider.
 DataObject getDataObject(RenderingContext context, java.lang.String namespace, java.lang.String name)
          HelpProvider getDataObject() implementation.
 void init(RenderingContext context)
          HelpProvider init() implementation, public as a result of DataProvider.
protected abstract  java.lang.Object selectHelpSystemValue(RenderingContext context, java.lang.Object select)
          Subclasses of HelpProvider must implement this selectHelpSystemValue() method.
protected abstract  java.lang.Object selectHelpTopicsValue(RenderingContext context, java.lang.Object select)
          Subclasses of HelpProvider must implement this selectHelpTopicsValue() method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

HELP_TOPICS_NAME

public static final java.lang.String HELP_TOPICS_NAME

HELP_SYSTEM_NAME

public static final java.lang.String HELP_SYSTEM_NAME

FRONT_PAGE_KEY

public static final java.lang.String FRONT_PAGE_KEY
Constructor Detail

HelpProvider

public HelpProvider()
Method Detail

getDataObject

public DataObject getDataObject(RenderingContext context,
                                java.lang.String namespace,
                                java.lang.String name)
HelpProvider getDataObject() implementation. Checks for and returns private implementations of the helpTopics and helpSystem DataObjects.
Specified by:
getDataObject in interface DataProvider
Parameters:
context - the current rendering context
namespace - the namespace of the requested DataObject
name - the name of the requested DataObject
Returns:
the DataObject for the specified namespace and name, or null if no such dataObject exists.

init

public void init(RenderingContext context)
HelpProvider init() implementation, public as a result of DataProvider.
Specified by:
init in interface DataProvider
Parameters:
context - the current rendering context
namespace - the namespace of the requested DataObject
name - the name of the requested DataObject
Returns:
the DataObject for the specified namespace and name, or null if no such dataObject exists.

cleanup

public void cleanup(RenderingContext context)
HelpProvider cleanup() implementation, public as a result of DataProvider. and returns private implementations of the helpTopics and helpSystem DataObjects.
Specified by:
cleanup in interface DataProvider
Parameters:
context - the current rendering context
namespace - the namespace of the requested DataObject
name - the name of the requested DataObject
Returns:
the DataObject for the specified namespace and name, or null if no such dataObject exists.

selectHelpTopicsValue

protected abstract java.lang.Object selectHelpTopicsValue(RenderingContext context,
                                                          java.lang.Object select)
Subclasses of HelpProvider must implement this selectHelpTopicsValue() method. The key passed as the selection criteria should be treated as a topic-id, and the return value should be a destination (URL string or javascript) for the help topic page.
Parameters:
context - the current rendering context
select - the selection criteria (topic-id)
Returns:
the value (should be string destination) for the selection criteria

selectHelpSystemValue

protected abstract java.lang.Object selectHelpSystemValue(RenderingContext context,
                                                          java.lang.Object select)
Subclasses of HelpProvider must implement this selectHelpSystemValue() method. The key passed as the selection criteria should be one of the keys defined as HelpProvider constants, otherwise implementations are free to return null. The return value should be a destination (URL string or javascript) for the appropriate page in the help system.
Parameters:
context - the current rendering context
select - the selection criteria (HelpProvider key)
Returns:
the value (should be string destination) for the selection criteria

Oracle UIX API Reference
Release 2.1.22.0.0
B12196-01

Copyright © 2002,2003, Oracle. All Rights Reserved.