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

## org.eclipse.birt.report.engine.api
Interface IGetParameterDefinitionTask

All Superinterfaces:
  IEngineTask

    public interface IGetParameterDefinitionTask

extends IEngineTask

an engine task that retrieves parameter definitions from a report. The task retrieves parameter definitions, default values and dynamic selection lists.

Field Summary

Fields inherited from interface org.eclipse.birt.report.engine.api.IEngineTask
`CANCEL_ON_ERROR, CONTINUE_ON_ERROR, STATUS_CANCELLED, STATUS_FAILED, STATUS_NOT_STARTED, STATUS_RUNNING, STATUS_SUCCEEDED, TASK_DATAEXTRACTION, TASK_GETPARAMETERDEFINITION, TASK_RENDER, TASK_RUN, TASK_RUNANDRENDER, TASK_UNKNOWN`

Method Summary
`void` | `evaluateDefaults()` Deprecated. use getDefaultParameterValues() directly.
`void` | `evaluateQuery(java.lang.String parameterGroupName)` Deprecated. This api has no use.
`java.lang.Object` | `getDefaultValue(IParameterDefnBase param)` get default value by parameter name
`java.lang.Object` | `getDefaultValue(java.lang.String name)` get the default value of parameter.
`java.util.HashMap` | `getDefaultValues()` get all default values
`ParameterHandle` | `getParameter(java.lang.String name)` Deprecated.
`IParameterDefnBase` | `getParameterDefn(java.lang.String name)` returns the parameter definition given the parameter name name
`java.util.Collection` | `getParameterDefns(boolean includeParameterGroups)` return report parameter definitions
`SlotHandle` | `getParameters()` Deprecated.
`java.util.Collection` | `getSelectionList(java.lang.String name)` get the collections of a selection choices.
`java.util.Collection` | `getSelectionListForCascadingGroup(java.lang.String parameterGroupName, java.lang.Object[] groupKeyValues)` The second step to work with the cascading parameters.
`java.util.Collection` | `getSelectionTreeForCascadingGroup(java.lang.String parameterGroupName)` Gets selection tree for a cascading parameter group.
`void` | `setValue(java.lang.String name, java.lang.Object value)` Set one parameter value.

Methods inherited from interface org.eclipse.birt.report.engine.api.IEngineTask
`addScriptableJavaObject, cancel, cancel, close, getAppContext, getCancelFlag, getEngine, getErrors, getID, getLocale, getLogger, getParameterDisplayText, getParameterValue, getParameterValues, getReportRunnable, getStatus, getTaskType, getULocale, setAppContext, setDataSource, setDataSource, setErrorHandlingOption, setLocale, setLocale, setLogger, setParameter, setParameterDisplayText, setParameterValue, setParameterValues, setTimeZone, setUserACL, validateParameters`

Method Detail

### getParameterDefns

    java.util.Collection getParameterDefns(boolean includeParameterGroups)

  return report parameter definitions

  Parameters:
    `includeParameterGroups` - whether returns one level of parameters with parameter groups or return a flatten collection of all parameters
  Returns:
    if includeParameterGroups = true, an ordered collection of report parameters. Each item in the colleciton is of type IParameterDefnBase if includeParameterGroups = false, a collection of parameters. Each item in the collection is of type IParameterDefn.

### getParameterDefn

    IParameterDefnBase getParameterDefn(java.lang.String name)

  returns the parameter definition given the parameter name name

  Parameters:
    `name` - the parameter name
  Returns:
    the definition

### evaluateDefaults

    void evaluateDefaults()
                          throws EngineException

  Deprecated. use getDefaultParameterValues() directly.

  evaluates the default value expressions for defined parameters. this function may cause the runtime environment to be set up, and default parameter expressions being evaluated. If getDefaultValue is called on a IScalarParameterDefn right after getParameterDefns without calling this function, the default value is null.

  Throws:
    `EngineException` - throws exception when there is an error evaluating default value expressions

### setValue

    void setValue(java.lang.String name,
                  java.lang.Object value)

  Set one parameter value. If parameter does not exist in report design, do nothing.

  Parameters:
    `name` - the parameter
    `value` - the value of the parameter

### getDefaultValues

    java.util.HashMap getDefaultValues()

  get all default values

  Returns:
    the default value map

### getDefaultValue

    java.lang.Object getDefaultValue(IParameterDefnBase param)

  get default value by parameter name

  Parameters:
    `param` - reference to a parameter
  Returns:
    default value for a parameter

### getDefaultValue

    java.lang.Object getDefaultValue(java.lang.String name)

  get the default value of parameter.

  Parameters:
    `name` - parameter name
  Returns:
    the default value defined in the design. null if not defined.

### getParameter

    ParameterHandle getParameter(java.lang.String name)

  Deprecated.

  get parameter definitions.

  Parameters:
    `name` - parameter name
  Returns:

### getParameters

    SlotHandle getParameters()

  Deprecated.

  get all the parameters & parameter groups defined in the report design.

  Returns:
    SlotHandle get from MODEL.

### getSelectionList

    java.util.Collection getSelectionList(java.lang.String name)

  get the collections of a selection choices. if the name is dynamic selection choice, the engine query the data base, return the choice.

  Parameters:
    `name` - parameter name
  Returns:
    collection of IParameterSelectionChoice

### evaluateQuery

    void evaluateQuery(java.lang.String parameterGroupName)

  Deprecated. This api has no use.

  Parameters:
    `parameterGroupName` - - the cascading parameter group name

### getSelectionListForCascadingGroup

    java.util.Collection getSelectionListForCascadingGroup(java.lang.String parameterGroupName,
                                                           java.lang.Object[] groupKeyValues)

  The second step to work with the cascading parameters. Get the selection choices for a parameter in the cascading group. The parameter to work on is the parameter on the next level in the parameter cascading hierarchy. For the "parameter to work on", please see the following example. Assume we have a cascading parameter group as Country - State - City. If user specified an empty array in groupKeyValues (meaning user doesn't have any parameter value), the parameter to work on will be the first level which is Country in this case. If user specified groupKeyValues as Object[]{"USA"} (meaning user has set the value of the top level), the parameter to work on will be the second level which is State in "USA" in this case. If user specified groupKeyValues as Object[]{"USA", "CA"} (meaning user has set the values of the top and the second level), the parameter to work on will be the third level which is City in "USA, CA" in this case.

  Parameters:
    `parameterGroupName` - - the cascading parameter group name
    `groupKeyValues` - - the array of known parameter values (see the example above)
  Returns:
    the selection list of the parameter to work on

### getSelectionTreeForCascadingGroup

    java.util.Collection getSelectionTreeForCascadingGroup(java.lang.String parameterGroupName)

  Gets selection tree for a cascading parameter group. Root of the tree is a collection of choices which type is ICascadingParameterSelectionChoice.

  Parameters:
    `parameterGroupName` - name of the cascading parameter group.
  Returns:
    root choices.

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 © 2008 Actuate Corp. All rights reserved.