IP*Works! WS V9 - Online Help
IP*Works! WS V9
Questions / Feedback?

WSConnectionDataFormat Property

The format of the data being sent.

Syntax

 wsserver.getWSConnectionDataFormat(index, [callback])
 wsserver.setWSConnectionDataFormat(index,  WSConnectionDataFormat, [callback])

Possible Values

  0 (dfAutomatic), 
  1 (dfText), 
  2 (dfBinary), 
  9 (dfPing)

Default Value

0


Callback

The 'callback' parameter specifies a function which will be called when the operation completes (or an error is encountered). If the 'callback' parameter is not specified, then the method will block and will not return until the operation completes (or an error is encountered).

The callback for the getWSConnectionDataFormat([callback]) method is defined as:

function(err, data){ }

'err' is the error that occurred. If there was no error, then 'err' is 'null'.

'data' is the value returned by the method.

The callback for the setWSConnectionDataFormat([callback]) method is defined as:

function(err){ }

'err' is the error that occurred. If there was no error, then 'err' is 'null'.

'err' has 2 properties which hold detailed information:

err.code
err.message

Remarks

The format of the data being sent. When data is sent over an established connection it is either considered as text or binary data. Text data is UTF-8 encoded. Binary data has no encoding associated with it.

Possible values are:

0 (dfAutomatic - default) The class will attempt to automatically determine the correct data format. This is suitable for most cases.
1 (dfText) The class will UTF-8 encode the specified data before sending. Data that has already been UTF-8 encoded may also be supplied.
2 (dfBinary) The class will send the data exactly as it is provided.
9 (dfPing) The class will send the ping with data exactly as it is provided.

The size of the array is controlled by the WSConnectionCount property.

This property is not available at design time.

Data Type

Integer

 
 
Copyright (c) 2017 /n software inc. - All rights reserved.
Build 9.0.6240.0