DH_SetReceiveFormat

Cogent API and Utilities: Version 4.1
Prev |  | Next

# `DH_SetReceiveFormat`

`DH_SetReceiveFormat` -- sets datahub-to-client transmissions to binary or ASCII.

## Syntax

    #include <cogdb.h>

``ST_STATUS DH_SetReceiveFormat`(IP_Task* myself, IP_Msg* hmsg, char* domain, int flag, ER_hLIST elist);`

## Arguments

`myself`

  The task handle associated with this task. This should always be the return value from `IP_NserveInit`.

`hmsg`

  A handle to a previously allocated message structure (using IP_MsgCreate) providing enough buffer space to handle the inter-process communication associated with the datahub transaction.

`domain`

  The name of the Cascade DataHub domain.

`flag`

  One of these:

  `PT_FMT_ASCII` | Constructs a humanly readable ASCII string (the default).
  `PT_FMT_BINARY` | Encodes data as a raw binary representation, efficient for parsing.
  `PT_FMT_HEX` | Encodes data as ASCII encoded hex. This is not a valuable format since it is more difficult to parse and less space efficient than binary, and it is more difficult for humans to read than regular ASCII.

`elist`

  A return value containing error information. This is unimplemented in this version, and should be `NULL`.

## Returns

`ST_OK` on success, `ST_ERROR` on failure, or some other value of `ST_STATUS`.

## Description

This function sets a global variable that determines whether transmissions from the Cascade DataHub to a client will be in binary or ASCII format.

## See Also

`DH_SetTransmitFormat`

Prev | Home | Next
`DH_SetLock`, `DH_SetSecurity` | Up | `DH_SetTransmitFormat`

Copyright 1995-2002 by Cogent Real-Time Systems, Inc.