Package org.eclipse.birt.report.engine.api

# Class TaskOption

java.lang.Object
org.eclipse.birt.report.engine.api.TaskOption

All Implemented Interfaces:
  `ITaskOption`

Direct Known Subclasses:
  `DataExtractionOption`, `RenderOption`

public class TaskOption extends Object implements ITaskOption
Define the class of task options

Since:
  3.3

## Field Summary

Fields
Modifier and Type
Field
Description
`protected Map<String,Object>`
`options`
a hash map that stores the rendering options

## Constructor Summary

Constructors
Constructor
Description
`TaskOption()`
constructor
`TaskOption(Map<String,Object> options)`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`boolean`
`getBooleanOption(String name, boolean defaultValue)`
Get boolean option value by name.
`int`
`getIntOption(String name, int defaultValue)`
Get the options int based
`Object`
`getOption(String name)`
get option value for one rendering option
`Map<String,Object>`
`getOptions()`
Get options.
`String`
`getStringOption(String name)`
Get option value by name.
`boolean`
`hasOption(String name)`
Check if an option is defined.
`void`
`setOption(String name, Object value)`
set value for one rendering option

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### options

protected Map<String,Object> options
a hash map that stores the rendering options

## Constructor Details

### TaskOption

public TaskOption()
constructor

### TaskOption

public TaskOption(Map<String,Object> options)
Constructor.

Parameters:
  `options` -

## Method Details

### setOption

public void setOption(String name, Object value)
set value for one rendering option

Specified by:
  `setOption` in interface `ITaskOption`
Parameters:
  `name` - the option name
  `value` - value for the option

### getOption

public Object getOption(String name)
get option value for one rendering option

Specified by:
  `getOption` in interface `ITaskOption`
Parameters:
  `name` - the option name
Returns:
  the option value

### hasOption

public boolean hasOption(String name)
Check if an option is defined.

Specified by:
  `hasOption` in interface `ITaskOption`
Parameters:
  `name` - option name.
Returns:
  true if user has defined an option with this name, even if the value is NULL. false otherwise.

### getOptions

public Map<String,Object> getOptions()
Get options.

Specified by:
  `getOptions` in interface `ITaskOption`
Returns:
  options

### getStringOption

public String getStringOption(String name)
Get option value by name.

Parameters:
  `name` - the option name
Returns:
  the option value

### getBooleanOption

public boolean getBooleanOption(String name, boolean defaultValue)
Get boolean option value by name.

Parameters:
  `name` - the option name
  `defaultValue` - default option value
Returns:
  default value

### getIntOption

public int getIntOption(String name, int defaultValue)
Get the options int based

Parameters:
  `name` -
  `defaultValue` -
Returns:
  Return the options int based