setValueAsString

The setValueAsString method defines the value of a NameValuePair object.

setValueAsString(valueAsString)
  • valueAsString-a string containing the value of a NameValuePair object

Return value

None.

Example

The following example shows how to define the value component of a NameValuePair if the value is a numeric.

NameValuePair parm3 = new NameValuePairImpl();
parm3.setName("Browser");
parm3.setValueAsString("IE6");
parm3.setValueDataType(NameValuePair.DATA_TYPE_STRING);