com.esri.adf.web.ags.data.gp
Class GPMultiValueParam

java.lang.Object
  extended by com.esri.adf.web.ags.data.gp.GPMultiValueParam
All Implemented Interfaces:
GPParam, TaskParamDescriptorModel, Serializable

public class GPMultiValueParam
extends Object
implements GPParam

Handles GPMultiValue: parameters. It works together with other MultiValue types (e.g. GPMultiStringParam) in GP Task. It can NOT be used as a xml renderer in AJAX response and it handles the request serialize/deserialize only.

           <GPParameterInfo xsi:type="tns:GPParameterInfo">
             <Name>Layers_to_Clip</Name>
             <DisplayName>Layers to Clip</DisplayName>
             <Category/>
             <DataType>GPMultiValue:GPString</DataType>
             <Direction>esriGPParameterDirectionInput</Direction>
             <ParamType>esriGPParameterTypeRequired</ParamType>
             <Value xsi:type="tns:GPMultiValue">
               <MemberDataType>GPString</MemberDataType>
               <Values xsi:type="tns:GPValues">
                 <GPValue xsi:type="tns:GPString">
                   <Value>point_shp</Value>
                 </GPValue>
               </Values>
             </Value>
           </GPParameterInfo>
 

See Also:
GPMultiStringParam, Serialized Form

Constructor Summary
GPMultiValueParam()
           
 
Method Summary
 void afterTaskExecute(String jobID)
           
 void beforeTaskExecute()
           
 ResultNode createResultNode(String jobID)
           
 Element generateXML(Object task)
           Generates the XML content for this parameter.
 String getDisplayName()
          Returns the display text for the parameter.
 String getDisplayText()
          Represents the object as a String.
 String getGPDataType()
           
 com.esri.arcgisws.GPParameterInfo getGPParamInfo()
           
 String getName()
           Returns the name of the parameter.
 Object getParamValue(Object task)
           Returns the current value of the parameter for the given task.
 String getRendererType()
           Returns the renderer type for the parameter.
 List<GPParam> getValues()
          Converts a GPMultiValue parameter to a set of GPMultiStringParam objects.
 void initParam(AGSGPFunctionality func, com.esri.arcgisws.GPParameterInfo info)
           
 Object setParamValue(Object task, String strVal)
           Sets the parameter value on the task and returns the set value.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GPMultiValueParam

public GPMultiValueParam()
Method Detail

initParam

public void initParam(AGSGPFunctionality func,
                      com.esri.arcgisws.GPParameterInfo info)
Specified by:
initParam in interface GPParam

getValues

public List<GPParam> getValues()
Converts a GPMultiValue parameter to a set of GPMultiStringParam objects.

Returns:
a set of GPMultiStringParam objects.

afterTaskExecute

public void afterTaskExecute(String jobID)
Specified by:
afterTaskExecute in interface GPParam

beforeTaskExecute

public void beforeTaskExecute()
Specified by:
beforeTaskExecute in interface GPParam

getDisplayText

public String getDisplayText()
Represents the object as a String.

Returns:
the string.

createResultNode

public ResultNode createResultNode(String jobID)
Specified by:
createResultNode in interface GPParam

getGPDataType

public String getGPDataType()
Specified by:
getGPDataType in interface GPParam

getGPParamInfo

public com.esri.arcgisws.GPParameterInfo getGPParamInfo()
Specified by:
getGPParamInfo in interface GPParam

generateXML

public Element generateXML(Object task)
Description copied from interface: TaskParamDescriptorModel

Generates the XML content for this parameter. This XML is then transformed by the XSL used by the task control to generate the appropriate markup.

Note that if you implement this method and generate custom XML, you'll also need to provide the XSL that transforms this XML into the appropriate markup. The XSL file that the task control should use can be specified by using the xslFile attribute of the task tag.

Specified by:
generateXML in interface TaskParamDescriptorModel
Parameters:
task - the task object
Returns:
the generated XML Element

getDisplayName

public String getDisplayName()
Description copied from interface: TaskParamDescriptorModel
Returns the display text for the parameter. The value returned by this method is typically used to display the label for the parameter.

Specified by:
getDisplayName in interface TaskParamDescriptorModel
Returns:
the display text for the parameter

getName

public String getName()
Description copied from interface: TaskParamDescriptorModel

Returns the name of the parameter.

If your task class has a pair of setParam(paramValue) and getParam() (isParam() for booleans) methods, the name of your parameter is param.

Specified by:
getName in interface TaskParamDescriptorModel
Returns:
the name of the parameter

getParamValue

public Object getParamValue(Object task)
Description copied from interface: TaskParamDescriptorModel

Returns the current value of the parameter for the given task.

Specified by:
getParamValue in interface TaskParamDescriptorModel
Parameters:
task - the task object
Returns:
the parameter value

getRendererType

public String getRendererType()
Description copied from interface: TaskParamDescriptorModel

Returns the renderer type for the parameter. The renderers supported out of the box are text boxes, checkboxes, radio buttons and dropdowns.

Specified by:
getRendererType in interface TaskParamDescriptorModel
Returns:
the renderer type for the parameter

setParamValue

public Object setParamValue(Object task,
                            String strVal)
Description copied from interface: TaskParamDescriptorModel

Sets the parameter value on the task and returns the set value. This method should convert the string input to the appropriate parameter type before setting the parameter.

Specified by:
setParamValue in interface TaskParamDescriptorModel
Parameters:
task - the task object on which to set the parameter value
strVal - the string representation of the parameter value to be set
Returns:
the set parameter value

toString

public String toString()
Overrides:
toString in class Object