You are currently viewing Zend Server 5.x documentation. Click here to view the latest Zend Server online documentation.
You are here: API Reference Guide > PHP XMLSERVICE Toolkit > Toolkit Service Class > Define Program Parameters > The AddParameterBin i Method

The AddParameterBin i Method

AddParameterBin ($IOType, , $Size, $Comment, $Name, $Value) - Defines the binary  type parameter.  This parameter allows you to define data that does not require EBCDIC/ASCII conversion for example Unicode (UTF-8) data or Blob/Clob data.

 

The parameter input value, which is binary, should be converted to a hexadecimal string type and the output parameter returned by a program, which is a hexadecimal string should be converted to binary type.

 

Arguments

Value

Description

$IOType

  • in
  • out
  • both

Data direction type

$Size

 

Parameter size

$Comment

 

Developer comment

$Name

 

Parameter name

$Value

 

Parameter value

Sample Code

Usage Example

$string = bin2hex($bin);
$param[] = $ToolkitServiceObj->AddParameterBin('both', 20, 'UncodeSample', 'p1', $string);
$result = $ToolkitServiceObj->PgmCall($program, $library, $param, NULL, NULL);

$bin_str = pack("H*", $result[‘io_param’][‘p1’]));

 

 

 

Related Links

Related Links:

Define Program Parameters

Toolkit Service Class

 

 

 

© 1999-2013 Zend Technologies, Ltd. All rights reserved.