question

Upvotes
Accepted
11 4 3 7

Comsumer example 370

Among most of the Elektron consumer examples, most of the ReqMsg have not set domain. I mean ReqMsg::domainType() functions, Why?

btw. the following code crash, could anyone take a look? Thank!

OmmArray RicList;

RicList.addAscii( "TRI.N" ).addAscii( "AAPL.O" ).complete();

OmmArray FieldList;

FieldList.fixedWidth( 2 ).addInt( 21 ).addInt( 22 ).addInt( 25 ).complete();

ReqMsg MyReqMsg;

MyReqMsg.serviceName( "EED_DELAYED" )

.payload( ElementList().addArray( ":ItemList", RicList )

.addUInt( ":ViewType", 1 ).addArray( ":ViewData", FieldList)

.complete() );

MyReqMsg.domainType();

auto domaintype=

MyReqMsg.getDomainType();// this line crash

elektronconsumer
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.

1 Answer

Upvotes
Accepted
11.3k 25 8 13

The default value of domainType in the ReqMsg is MarketPrice(6), so there is no need to set domain for MarketPrice request message.

With regard to the crash issue, I'm able to replicate the issue in our application. However, this usage of ReqMsg is not supported. The EMA Reference Manual document states in the description of ReqMsg class that decoding of just encoded ReqMsg in the same application is not supported.

Please see the following screenshot for the reference.


reqmsg.png (35.0 KiB)
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.

Thanks, I got it.

Click below to post an Idea Post Idea