public class

TaskParameterMetadataImpl

extends AbstractConfigurationElement
implements TaskParameterMetadata
java.lang.Object
   ↳ com.microstrategy.utils.config.AbstractConfigurationElement
     ↳ com.microstrategy.web.tasks.config.TaskParameterMetadataImpl

Class Overview

THIS CLASS IS NOT SUPPORTED FOR USE IN CUSTOM APPLICATION DEVELOPMENT. THE CLASS IS SUBJECT TO CHANGE IN FUTURE RELEASES AND SOME METHODS AND PROPERTIES MAY NOT BE SUITABLE FOR CUSTOM DEVELOPMENT.

Summary

Constants
String NODE_PARAMETER
[Expand]
Inherited Constants
From class com.microstrategy.utils.config.AbstractConfigurationElement
Public Constructors
TaskParameterMetadataImpl()
Constructs a TaskParameterMetadataImpl object.
TaskParameterMetadataImpl(String name)
Constructs a TaskParameterMetadataImpl object.
Public Methods
String[] getArrayValue(RequestKeys requestKeys)
Returns an array of string values by parsing the parameter value.
String[] getArrayValue(RequestKeys requestKeys, String delim)
Returns an array of string values by parsing the parameter value and using the specified delimiter.
boolean getBooleanValue(RequestKeys requestKeys)
Returns the boolean value of a parameter.
String getDefaultValue()
Get the default value associated with this parameter.
Object getDefaultValueObject()
Get the default generic object associated with this parameter.
String getDescription()
Returns the textual description of this Task parameter.
int getIntValue(RequestKeys requestKeys)
Returns the integer value of a parameter.
long getLongValue(RequestKeys requestKeys)
Returns the long value of a parameter.
String getName()
Returns the name of this Task parameter.
PostedFile getPostedFile(TaskRequestContext context)
Returns data file uploaded by user via a "multipart/form-data" request form.
String getType()
Returns the data type of this Task parameter.
String getValidator()
Returns the data type validator of this Task parameter.
String getValue(RequestKeys requestKeys)
Returns the value of a parameter, given the supplied input parameters.
Enumeration getValueObject(RequestKeys requestKeys)
Returns the enumeration of value objects of a parameter, given the supplied input parameters.
boolean isHidden()
boolean isRequired()
Whether this Task parameter is required, and must be supplied in all Task invocations.
void setDefaultValue(String defValue)
This method is deprecated. Use setDefaultValue(Object) instead
void setDefaultValue(Object defValue)
Specifies a default value for this parameter.
void setDescription(String desc)
Sets the description for a task parameter.
void setHidden(boolean isHidden)
Sets whether this parameter is private or not.
void setName(String name)
void setRequired(boolean required)
Sets whether this parameter is required or not.
void setType(String type)
void setValidator(String validator)
Protected Methods
String getKeyAttribute()
This method must return the attribute that uniquely identifies this element among its siblings; if no single attribute can be used, return null and override the getKey and setKey methods.
[Expand]
Inherited Methods
From class com.microstrategy.utils.config.AbstractConfigurationElement
From class java.lang.Object
From interface com.microstrategy.utils.config.ConfigurationElement
From interface com.microstrategy.utils.config.ConfigurationFile
From interface com.microstrategy.web.tasks.TaskParameterMetadata

Constants

public static final String NODE_PARAMETER

Constant Value: "parameter"

Public Constructors

public TaskParameterMetadataImpl ()

Constructs a TaskParameterMetadataImpl object.

public TaskParameterMetadataImpl (String name)

Constructs a TaskParameterMetadataImpl object.

Parameters
name The name of the task parameter.

Public Methods

public String[] getArrayValue (RequestKeys requestKeys)

Returns an array of string values by parsing the parameter value. It assumes that array elements are separated (delimited) by commas.

Returns
  • An array of Strings (without delimiters included).

public String[] getArrayValue (RequestKeys requestKeys, String delim)

Returns an array of string values by parsing the parameter value and using the specified delimiter.

Parameters
requestKeys A RequestKeys object that contains the input parameters.
delim The String delimiter used to separate array elements.
Returns
  • An array of Strings (without delimiters included).

public boolean getBooleanValue (RequestKeys requestKeys)

Returns the boolean value of a parameter. If not specified, a parameter's default value may be used.

Parameters
requestKeys A RequestKeys object that contains the input parameters.
Returns
  • A boolean value for the parameter.

public String getDefaultValue ()

Get the default value associated with this parameter.

Returns
  • The default value, or null, if no default value is specified.

public Object getDefaultValueObject ()

Get the default generic object associated with this parameter.

Returns
  • The default value object, or null, if no default value is specified.

public String getDescription ()

Returns the textual description of this Task parameter.

Returns
  • The textual description of this Task parameter.

public int getIntValue (RequestKeys requestKeys)

Returns the integer value of a parameter. If not specified, a parameter's default value may be used.

Parameters
requestKeys A RequestKeys object that contains the input parameters.
Returns
  • An integer value for the parameter.

public long getLongValue (RequestKeys requestKeys)

Returns the long value of a parameter. If not specified, a parameter's default value may be used.

Parameters
requestKeys A RequestKeys object that contains the input parameters.
Returns
  • A long (integer) value for the parameter.

public String getName ()

Returns the name of this Task parameter.

Returns
  • The name of this Task parameter.

public PostedFile getPostedFile (TaskRequestContext context)

Returns data file uploaded by user via a "multipart/form-data" request form. Note that PostedFile is always returned even if the user uploaded nothing - getLength() should be checked for non-zero to indicate existence of data.

Returns
  • the data uploaded with "multipart/form-data".

public String getType ()

Returns the data type of this Task parameter.

Returns
  • The data type of this Task parameter.

public String getValidator ()

Returns the data type validator of this Task parameter.

Returns
  • The the data type validator of this Task parameter.

public String getValue (RequestKeys requestKeys)

Returns the value of a parameter, given the supplied input parameters. If the parameter has been explicitly specified in the input parameters, it is returned. If not, and the default value is non-null, then that is returned. Otherwise, null is returned.

Parameters
requestKeys A RequestKeys object that contains the input parameters.
Returns
  • The computed value of the parameter for a specific request.

public Enumeration getValueObject (RequestKeys requestKeys)

Returns the enumeration of value objects of a parameter, given the supplied input parameters. If the parameter has been explicitly specified in the input parameters, it is returned. If not, and the default value is non-null, then that is returned. Otherwise, null is returned.

Parameters
requestKeys A RequestKeys object that contains the input parameters.
Returns
  • The computed value of the parameter for a specific request.

public boolean isHidden ()

public boolean isRequired ()

Whether this Task parameter is required, and must be supplied in all Task invocations.

Returns
  • True, if this parameter is required; otherwise, false.

public void setDefaultValue (String defValue)

This method is deprecated.
Use setDefaultValue(Object) instead

Specifies a default value for this parameter.

Parameters
defValue The value to use if none is supplied.

public void setDefaultValue (Object defValue)

Specifies a default value for this parameter.

Parameters
defValue The value to use if none is supplied.

public void setDescription (String desc)

Sets the description for a task parameter.

Parameters
desc The description to associate with this task parameter.

public void setHidden (boolean isHidden)

Sets whether this parameter is private or not.

public void setName (String name)

public void setRequired (boolean required)

Sets whether this parameter is required or not.

Parameters
required Whether this parameter is required or not.

public void setType (String type)

public void setValidator (String validator)

Protected Methods

protected String getKeyAttribute ()

This method must return the attribute that uniquely identifies this element among its siblings; if no single attribute can be used, return null and override the getKey and setKey methods.