question

Upvotes
Accepted
1 0 0 0

OMMMsg 这个API如何获取路透发送的原报文?应该通过哪个方法查看?

OMMMsg 这个API如何获取路透发送的原报文?应该通过哪个方法查看?

#technologyrfa-api
icon clock
10 |1500

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

Upvote
Accepted
82.3k 277 53 77

@235601

Thank you for reaching out to us.

OMMMsg is an interface class in the RFA package. This interface contains set of accessor methods, used to set and get message data elements, and utility methods.

If you would like to retrive the raw unencoded data, you can use the getBytes method which returns the encoded message as a byte array.

For more information, please refer to the RFA reference guide in the RFA package.


icon clock
10 |1500

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

getBytes后如何将内容解析成字符串,编码格式是什么,尝试了UTF-8、GBK都不行
Upvotes
82.3k 277 53 77

@235601

It is encoded by our proprietary format.

You can try the OMMPool.acquireMsg(byte[] data) method which acquires a read-only OMMMsg. Temporary ownership of the byte[] is claimed by the OMMMsg, so the caller must not change the byte[] until after the OMMMsg is released with releaseMsg(OMMMsg).

There are other interfaces in the OMMPool which can direclty copy a message, such as acquireCopy.

For more information, please refer to the RFA Reference Manual in the RFA Java package.

icon clock
10 |1500

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

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

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