parse

fun parse(payload: String, requireAllPrivateData: Boolean = false): Rfq

Takes an existing Rfq in the form of a json string and parses it into a Rfq object. Validates object structure and performs an integrity check using the message signature.

Return

The json string parsed into a Rfq.

Parameters

payload

The message as a json string.

requireAllPrivateData

If true, validate that all private data properties are present and run integrity check. Otherwise, only check integrity of private fields which are present. If false or omitted, validate only the private data properties that are currently present in privateData

Throws

if hashed values in Rfq.privateData does not match values in Rfq.data