question

Upvotes
Accepted

UPA - Encoding elementSetDefs

Hello,

Does anyone know how to encode elementSetDefs and the different entries Inside ?

Like

<elementSetDefs>

<elementSetDef setId="0">

<elementSetDefEntry name="NAME" dataType="RSSL_DT_ASCII_STRING" />

<elementSetDefEntry name="FID" dataType="RSSL_DT_INT_2" />

<elementSetDefEntry name="RIPPLETO" dataType="RSSL_DT_INT_2" />

<elementSetDefEntry name="TYPE" dataType="RSSL_DT_INT_1" />

<elementSetDefEntry name="LENGTH" dataType="RSSL_DT_UINT_2" />

<elementSetDefEntry name="RWFTYPE" dataType="RSSL_DT_UINT_1" />

<elementSetDefEntry name="RWFLEN" dataType="RSSL_DT_UINT_2" />

<elementSetDefEntry name="ENUMLENGTH" dataType="RSSL_DT_UINT_2" />

<elementSetDefEntry name="LONGNAME" dataType="RSSL_DT_ASCII_STRING" />

</elementSetDef>

</elementSetDefs>

In the documentation, it seems we can declare the elementSetDefs as an RsslBuffer :

Include/rtr/rsslVector.h: RsslBuffer encSetDefs; /*!< @brief Contains encoded set definition information when present. Presence is indicated by \ref RsslVectorFlags ::RSSL_VTF_HAS_SET_DEFS. When decoding, this contains encoded set definitions. When encoding, pre-encoded set definition information can be specified here; if not pre-encoded the user can encode set definitions and invoke rsslEncodeVectorSetDefsComplete() when ready to continue encoding RsslVector contents. */

But Can't find out how to declare the different elementSetDefEntry (what function to use and what kind of data).

Any clue ?

Kind regards,

Yannick

elektronelektron-sdkrrteta-apielektron-transport-api
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvote
Accepted
361 1 4 3

Hi Yannick,

The Developer's Guide included in the release has a section on encoding set-defined data (section 11.6 at last release). It details how set definitions are encoded and the functions involved, and also has an example that encodes & decodes a Series with a set definition and set-defined data (encoding with a Map or Vector is very similar).

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvotes

Hi,

Many thanks. Can't believe I missed that =).

Yannick

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Click below to post an Idea Post Idea