From 62973114e7b014ee843e161f4ae66e17baf9d3e7 Mon Sep 17 00:00:00 2001 From: Ewen Maclean Date: Thu, 8 Apr 2021 15:17:56 +0100 Subject: [PATCH 1/9] wip:adding decoders --- src-protocol-pp/full_admin_enums_decoder.iml | 110 +++++++++++++++ .../full_admin_messages_decoder.iml | 132 ++++++++++++++++++ src-protocol-pp/full_admin_tags_decoder.iml | 111 +++++++++++++++ 3 files changed, 353 insertions(+) create mode 100644 src-protocol-pp/full_admin_enums_decoder.iml create mode 100644 src-protocol-pp/full_admin_messages_decoder.iml create mode 100644 src-protocol-pp/full_admin_tags_decoder.iml diff --git a/src-protocol-pp/full_admin_enums_decoder.iml b/src-protocol-pp/full_admin_enums_decoder.iml new file mode 100644 index 00000000..b80af6e3 --- /dev/null +++ b/src-protocol-pp/full_admin_enums_decoder.iml @@ -0,0 +1,110 @@ +(* Imandra Inc. copyright 2021 *) +[@@@program] +[@@@require "decoders-yojson"] +[@@@import "../src-protocol/full_admin_enums.iml"] +open Full_admin_enums;; + +module D = Decoders_yojson.Basic.Decode + +let string_to_execinst_opt = + function + | "InvalidTagNumber" -> Some InvalidTagNumber + | "RequiredTagMissing" -> Some RequiredTagMissing + | "TagNotDefinedForThisMessageType" -> Some TagNotDefinedForThisMessageType + | "UndefinedTag" -> Some UndefinedTag + | "TagSecifiedWithoutAValue" -> Some TagSecifiedWithoutAValue + | "ValueIsIncorrect" -> Some ValueIsIncorrect + | "IncorrectDataFormatForValue" -> Some IncorrectDataFormatForValue + | "DecryptionProblem" -> Some DecryptionProblem + | "SignatureProblem" -> Some SignatureProblem + | "CompIDProblem" -> Some CompIDProblem + | "SendingTimeAccuracyProblem" -> Some SendingTimeAccuracyProblem + | "InvalidMsgType" -> Some InvalidMsgType + | "XMLValidationError" -> Some XMLValidationError + | "TagAppearsMoreThanOnce" -> Some TagAppearsMoreThanOnce + | "TagSpecifiedOutOfRequiredOrder" -> Some TagSpecifiedOutOfRequiredOrder + | "RepeatingGroupFieldsOutOfOrder" -> Some RepeatingGroupFieldsOutOfOrder + | "IncorrectNumInGroupCountForRepeatingGroup" -> Some IncorrectNumInGroupCountForRepeatingGroup + | "NonDataValueIncludesFieldDelimiter" -> Some NonDataValueIncludesFieldDelimiter + | _ -> None +;; + +let full_admin_enum_execinst_decoder : fix_session_reject_reason D.decoder = + let open D in + string >>= fun x -> match string_to_execinst_opt x with + | None -> fail "Unknown enum (fix_session_reject_reason) encoding." + | Some y -> succeed y +;; + +let string_to_fix_business_reject_reason_opt = function + | "ApplicationDown" -> Some ApplicationDown + | "MessageTypeNotSupported" -> Some MessageTypeNotSupported + | "FieldMissing" -> Some FieldMissing + | _ -> None +;; + +let full_admin_enum_fix_business_reject_reason_decoder : fix_business_reject_reason D.decoder = + let open D in + string >>= fun x -> match string_to_fix_business_reject_reason_opt x with + | None -> fail "Unknown enum (fix_business_reject_reason) encoding." + | Some y -> succeed y +;; + +let string_to_fix_app_reject_reason_opt = function + | "FIX_App_Reject_MissingReqField" -> Some FIX_App_Reject_MissingReqField + | "FIX_App_Reject_InvalidField" -> Some FIX_App_Reject_InvalidField + | "FIX_App_Reject_Custom" -> Some FIX_App_Reject_Custom + | _ -> None +;; + +let full_admin_enum_fix_app_reject_reason_decoder : fix_app_reject_reason D.decoder = + let open D in + string >>= fun x -> match string_to_fix_app_reject_reason_opt x with + | None -> fail "Unknown enum (fix_app_reject_reason) encoding." + | Some y -> succeed y +;; + +let string_to_fix_gapfillflag_opt = function + | "FIX_GapFillFlat_Y" -> Some FIX_GapFillFlag_Y + | "FIX_GapFillFlag_N" -> Some FIX_GapFillFlag_N + | _ -> None +;; + + +let full_admin_enum_fix_gapfillflag_decoder : fix_gapfillflag D.decoder = + let open D in + string >>= fun x -> match string_to_fix_gapfillflag_opt x with + | None -> fail "Unknown enum (fix_gapfillflag) encoding." + | Some y -> succeed y +;; + +let string_to_fix_encryption_method_opt = function + | "PKCS" -> Some PKCS + | "DES_ECB" -> Some DES_ECB + | "PKCS_DES" -> Some PKCS_DES + | "PGP_DES" -> Some PGP_DES + | "PGP_DES_MD5" -> Some PGP_DES_MD5 + | "PEM_DES_MD5" -> Some PEM_DES_MD5 + | "NoEncryption" -> Some NoEncryption + | _ -> None +;; + +let full_admin_enum_fix_encryption_method_decoder : fix_encryption_method D.decoder = + let open D in + string >>= fun x -> match string_to_fix_encryption_method_opt x with + | None -> fail "Unknown enum (fix_encryption_method) encoding." + | Some y -> succeed y +;; + +let string_to_fix_msgdirection_opt = function + | "FIX_MsgDirection_Send" -> Some FIX_MsgDirection_Send + | "FIX_MsgDirection_Receive" -> Some FIX_MsgDirection_Receive + | _ -> None +;; + +let full_admin_enum_fix_msgdirection_decoder : fix_msgdirection D.decoder = + let open D in + string >>= fun x -> match string_to_fix_msgdirection_opt x with + | None -> fail "Unknown enum (fix_msgdirection) encoding." + | Some y -> succeed y +;; diff --git a/src-protocol-pp/full_admin_messages_decoder.iml b/src-protocol-pp/full_admin_messages_decoder.iml new file mode 100644 index 00000000..216b83bc --- /dev/null +++ b/src-protocol-pp/full_admin_messages_decoder.iml @@ -0,0 +1,132 @@ +(* Imandra Inc. copyright 2021 *) +[@@@program] +[@@@import "../src-core-pp/base_types_json.iml"] +open Base_types_json;; +[@@@import "../src-core-pp/datetime_json.iml"] +open Datetime_json;; +[@@@import "full_admin_enums_decoder.iml"] +open Full_admin_enums_decoder;; +[@@@import "../src-protocol/full_admin_messages.iml"] +open Full_admin_messages;; +[@@@import "../src-protocol-exts-pp/full_app_tags_decoder.iml"] +open Full_app_tags_decoder;; + +module D = Decoders_yojson.Basic.Decode;; + +let full_msg_heartbeat_decoder : full_msg_heartbeat_data D.decoder = + let open D in + maybe @@ field "TestReqID" string >>= fun hb_test_req_id -> + D.succeed {hb_test_req_id} +;; + + +let full_msg_types_inner_rg_decoder : full_msg_types_inner_rg D.decoder = + let open D in + field "mtps_ref_msg_type" full_admin_msg_tag_of_json >>= fun mtps_ref_msg_type -> + field "mtps_direction" full_admin_enum_fix_msgdirection_decoder >>= fun mtps_direction -> + D.succeed {mtps_ref_msg_type;mtps_direction} +;; + + +(* +(** Repeating group for supported messages passed in Logon *) +type full_msg_types_inner_rg = { + mtps_ref_msg_type : full_msg_tag; (** Tag 372: Specifies a specific, supported MsgType <35>. *) + mtps_direction : fix_msgdirection (** Tag 385: Indicates direction (send vs. receive) from the point of view of the sender. *) +} +;; + +(** Logon message data. *) +type full_msg_logon_data = { + ln_encrypt_method : fix_encryption_method; (** Tag 98 *) + ln_heartbeat_interval : fix_duration; (** Tag 108 *) + ln_raw_data_length : int option; (** Tag 95 *) + ln_raw_data : string option; (** Tag 96 *) + ln_reset_seq_num_flag : bool option; (** Tag 141 *) + ln_next_expected_msg_seq_num : int option; (** Tag 789 *) + ln_max_message_size : int option; (** Tag 383 *) + + ln_test_message_indicator : bool option; (** Tag 464 *) + ln_username : string option; (** Tag 553 *) + ln_password : string option; (** Tag 554 *) + + ln_msg_types : full_msg_types_inner_rg list (** Repeating group at tag 384 *) +} +;; + +(** Logoff message data. *) +type full_msg_logoff_data = { + lo_encoded_text_len : int option; (** Tag 354 *) + lo_encoded_text : string option; (** Tag 355 *) +} +;; + +(** Resend Request message data. *) +type full_msg_resend_request_data = { + rr_begin_seq_num : int; (** Tag 7 *) + rr_end_seq_num : int; (** Tag 16 *) +} +;; + +(** Reject message data. *) +type full_msg_reject_data = { + sr_ref_seq_num : int; (** Tag 45. MsgSeqNum of rejected message. *) + sr_ref_tag_id : full_field_tag option; (** Tag 371. The tag number of the FIX field being referenced.*) + sr_ref_msg_type : full_msg_tag option; (** Tag 372. The MsgType of the FIX message being referenced.*) + sr_session_reject_reason : fix_session_reject_reason option; (** Tag 373. Code to identify reason for a session-level Reject <3> message.*) + sr_text : string option; (** Tag 58. Where possible, message to explain reason for rejection.*) + sr_encoded_text_len : int option; (** Tag 354. Encoded text length. *) + sr_encoded_text : string option; (** Tag 354. Encoded text. *) +} +;; + +(** Sequence Reset message data. *) +type full_msg_sequence_reset_data = { + seqr_new_seq_no : int; (** Tag 36 *) + seqr_gap_fill_flag : fix_gapfillflag option; (** Tag 123 *) +} +;; + +(** Test Request message data. *) +type full_msg_test_request_data = { + test_req_id : string; (** Tag 112 *) +} +;; + +(** Business Reject message data. *) +type full_msg_business_reject_data = { + br_ref_seq_num : int; (** Tag 45. MsgSeqNum of rejected message. *) + br_ref_msg_type : full_msg_tag; (** Tag 372. The MsgType of the FIX message being referenced.*) + br_ref_field_id : full_field_tag option; (** Tag 379. The business-level field on the message being referenced.*) + br_business_reject_reason : fix_business_reject_reason; (** Tag 380. Code to identify reason for a BusinessReject message.*) + br_text : string option; (** Tag 58. Where possible, message to explain reason for rejection.*) + br_encoded_text_len : int option; (** Tag 354. Encoded text length. *) + br_encoded_text : string option; (** Tag 354. Encoded text. *) +} +;; + +(** Top-level full administrative message data type. *) +type full_admin_msg_data = + | Full_Msg_Heartbeat of full_msg_heartbeat_data + | Full_Msg_Logon of full_msg_logon_data + | Full_Msg_Logoff of full_msg_logoff_data + | Full_Msg_Reject of full_msg_reject_data + | Full_Msg_Business_Reject of full_msg_business_reject_data + | Full_Msg_Resend_Request of full_msg_resend_request_data + | Full_Msg_Sequence_Reset of full_msg_sequence_reset_data + | Full_Msg_Test_Request of full_msg_test_request_data +;; + +(** Get the message tag code, given the admin message data*) +let get_full_admin_msg_tag ( msg : full_admin_msg_data ) = + match msg with + | Full_Msg_Heartbeat _ -> Full_Msg_Heartbeat_Tag + | Full_Msg_Logon _ -> Full_Msg_Logon_Tag + | Full_Msg_Logoff _ -> Full_Msg_Logoff_Tag + | Full_Msg_Reject _ -> Full_Msg_Reject_Tag + | Full_Msg_Business_Reject _ -> Full_Msg_Business_Reject_Tag + | Full_Msg_Resend_Request _ -> Full_Msg_Resend_Request_Tag + | Full_Msg_Sequence_Reset _ -> Full_Msg_Sequence_Reset_Tag + | Full_Msg_Test_Request _ -> Full_Msg_Test_Request_Tag +;; +*) \ No newline at end of file diff --git a/src-protocol-pp/full_admin_tags_decoder.iml b/src-protocol-pp/full_admin_tags_decoder.iml new file mode 100644 index 00000000..98d1ca77 --- /dev/null +++ b/src-protocol-pp/full_admin_tags_decoder.iml @@ -0,0 +1,111 @@ +(* Imandra Inc. copyright 2021 *) +[@@@program] +[@@@require "decoders-yojson"] +[@@@import "../src-protocol/full_admin_tags.iml"] +open Full_admin_tags;; + +module D = Decoders_yojson.Basic.Decode;; + +let full_admin_string_to_msg_tag = + function + | "Heartbeat_Tag" -> Some Full_Msg_Heartbeat_Tag + | "Logon_Tag" -> Some Full_Msg_Logon_Tag + | "Logoff_Tag" -> Some Full_Msg_Logoff_Tag + | "Reject_Tag" -> Some Full_Msg_Reject_Tag + | "Business_Reject_Tag" -> Some Full_Msg_Business_Reject_Tag + | "Resend_Request_Tag" -> Some Full_Msg_Resend_Request_Tag + | "Sequence_Reset_Tag" -> Some Full_Msg_Sequence_Reset_Tag + | "Test_Request_Tag" -> Some Full_Msg_Test_Request_Tag + | _ -> (None) +;; + + +let full_admin_string_to_field_tag = + function + | "BeginSeqNo" -> Some Full_Msg_BeginSeqNo_Tag + | "BeginString" -> Some Full_Msg_BeginString_Tag + | "BodyLength" -> Some Full_Msg_BodyLength_Tag + | "CheckSum" -> Some Full_Msg_CheckSum_Tag + | "EndSeqNo" -> Some Full_Msg_EndSeqNo_Tag + | "MsgSeqNum" -> Some Full_Msg_MsgSeqNum_Tag + | "NewSeqNo" -> Some Full_Msg_NewSeqNo_Tag + | "PossDupFlag" -> Some Full_Msg_PossDupFlag_Tag + | "RefSeqNum" -> Some Full_Msg_RefSeqNum_Tag + | "SenderCompID"-> Some Full_Msg_SenderCompID_Tag + | "SenderSubID" -> Some Full_Msg_SenderSubID_Tag + | "SendingTime" -> Some Full_Msg_SendingTime_Tag + | "TargetCompID" -> Some Full_Msg_TargetCompID_Tag + | "TargetSubID" -> Some Full_Msg_TargetSubID_Tag + | "Text" -> Some Full_Msg_Text_Tag + | "Signature" -> Some Full_Msg_Signature_Tag + | "SecureDataLen" -> Some Full_Msg_SecureDataLen_Tag + | "SecureData" -> Some Full_Msg_SecureData_Tag + | "SignatureLength" -> Some Full_Msg_SignatureLength_Tag + | "RawDataLength" -> Some Full_Msg_RawDataLength_Tag + | "RawData" -> Some Full_Msg_RawData_Tag + | "PossResend" -> Some Full_Msg_PossResend_Tag + | "EncryptMethod" -> Some Full_Msg_EncryptMethod_Tag + | "HeartBtInt" -> Some Full_Msg_HeartBtInt_Tag + | "TestReqID" -> Some Full_Msg_TestReqID_Tag + | "OnBehalfOfLocationID" -> Some Full_Msg_OnBehalfOfLocationID_Tag + | "OnBehalfOfCompID" -> Some Full_Msg_OnBehalfOfCompID_Tag + | "OnBehalfOfSubID" -> Some Full_Msg_OnBehalfOfSubID_Tag + | "OrigSendingTime" -> Some Full_Msg_OrigSendingTime_Tag + | "GapFillFlag" -> Some Full_Msg_GapFillFlag_Tag + | "DeliverToCompID" -> Some Full_Msg_DeliverToCompID_Tag + | "DeliverToSubID" -> Some Full_Msg_DeliverToSubID_Tag + | "ResetSeqNumFlag" -> Some Full_Msg_ResetSeqNumFlag_Tag + | "SenderLocationID" -> Some Full_Msg_SenderLocationID_Tag + | "TargetLocationID" -> Some Full_Msg_TargetLocationID_Tag + | "DeliverToLocationID" -> Some Full_Msg_DeliverToLocationID_Tag + | "XMLDataLen" -> Some Full_Msg_XMLDataLen_Tag + | "XMLData" -> Some Full_Msg_XMLData_Tag + | "MessageEnconding" -> Some Full_Msg_MessageEnconding_Tag + | "EncodedTextLen" -> Some Full_Msg_EncodedTextLen_Tag + | "EncodedText" -> Some Full_Msg_EncodedText_Tag + | "LastMsgSeqNumProcessed" -> Some Full_Msg_LastMsgSeqNumProcessed_Tag + | "RefTagID" -> Some Full_Msg_RefTagID_Tag + | "RefMsgType" -> Some Full_Msg_RefMsgType_Tag + | "SessionRejectReason" -> Some Full_Msg_SessionRejectReason_Tag + | "BusinessRejectReason" -> Some Full_Msg_BusinessRejectReason_Tag + | "MaxMessageSize" -> Some Full_Msg_MaxMessageSize_Tag + | "TestMessageIndicator" -> Some Full_Msg_TestMessageIndicator_Tag + | "Username" -> Some Full_Msg_Username_Tag + | "Password" -> Some Full_Msg_Password_Tag + | "NoHops" -> Some Full_Msg_NoHops_Tag + | "NextExpectedMsgSeqNum" -> Some Full_Msg_NextExpectedMsgSeqNum_Tag + | _ -> None +;; + +let full_admin_msg_tag_of_json : full_admin_msg_tag D.decoder = + let open D in + string >>= fun x -> + match full_admin_string_to_msg_tag x with + | None -> fail @@ "Unknown Tag: "^x + | Some x -> succeed x +;; + +let full_app_msg_tag_opt_of_json : full_admin_msg_tag option D.decoder = + let open D in + maybe string >>= fun x -> match x with + | None -> succeed None + | Some x -> succeed @@ full_admin_string_to_msg_tag x +;; + +let full_admin_field_tag_of_json : full_admin_field_tag D.decoder = + let open D in + string >>= fun x -> + match full_admin_string_to_field_tag x with + | None -> fail @@ "Unknown Tag: "^x + | Some x -> succeed x +;; + +let full_admim_field_tag_opt_of_json : full_admin_field_tag option D.decoder = + let open D in + maybe string >>= fun x -> + match x with + | None -> succeed None + | Some x -> succeed @@ full_admin_string_to_field_tag x +;; + +[@@@logic] From 211b5ea27169b261a0c4416a039af98eb389a7d4 Mon Sep 17 00:00:00 2001 From: Ewen Maclean Date: Thu, 8 Apr 2021 15:38:27 +0100 Subject: [PATCH 2/9] fixing enum gen --- .../full_app_enums_decoder.iml | 4973 +++++++++++++++++ .../full_app_messages_decoder.iml | 16 + .../full_app_records_decoder.iml | 5 + .../full_app_tags_decoder.iml | 55 + src-protocol-exts/full_app_enums.iml | 2 +- .../full_admin_messages_decoder.iml | 2 +- 6 files changed, 5051 insertions(+), 2 deletions(-) create mode 100644 src-protocol-exts-pp/full_app_enums_decoder.iml create mode 100644 src-protocol-exts-pp/full_app_messages_decoder.iml create mode 100644 src-protocol-exts-pp/full_app_records_decoder.iml create mode 100644 src-protocol-exts-pp/full_app_tags_decoder.iml diff --git a/src-protocol-exts-pp/full_app_enums_decoder.iml b/src-protocol-exts-pp/full_app_enums_decoder.iml new file mode 100644 index 00000000..5f8eee6d --- /dev/null +++ b/src-protocol-exts-pp/full_app_enums_decoder.iml @@ -0,0 +1,4973 @@ +(* Imandra Inc. copyright 2021 *) +[@@@program] +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode;; +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode.Infix;; +[@@@import "../src-protocol-exts/full_app_enums.iml"] +open Full_app_enums;; + + +let string_to_currency_opt (d) = + (match d with + | "CHF" -> (Some FIX_Currency_CHF) + | "EUR" -> (Some FIX_Currency_EUR) + | "GBP" -> (Some FIX_Currency_GBP) + | "USD" -> (Some FIX_Currency_USD) + | _ -> None + ) +;; + +let string_to_country_opt (d) = + (match d with + | "DE" -> (Some FIX_Country_DE) + | "GB" -> (Some FIX_Country_GB) + | "US" -> (Some FIX_Country_US) + | _ -> None + ) +;; + +let string_to_exchange_opt (d) = + (match d with + | "XSHG" -> (Some FIX_Exchange_XSHG) + | "SHSC" -> (Some FIX_Exchange_SHSC) + | "XJAS" -> (Some FIX_Exchange_XJAS) + | "XLON" -> (Some FIX_Exchange_XLON) + | "XNYS" -> (Some FIX_Exchange_XNYS) + | _ -> None + ) +;; + +let string_to_accounttype_opt (d) = + (match d with + | "CarriedCustomerSide" -> (Some FIX_AccountType_CarriedCustomerSide) + | "CarriedNonCustomerSide" -> (Some FIX_AccountType_CarriedNonCustomerSide) + | "HouseTrader" -> (Some FIX_AccountType_HouseTrader) + | "FloorTrader" -> (Some FIX_AccountType_FloorTrader) + | "CarriedNonCustomerSideCrossMargined" -> (Some FIX_AccountType_CarriedNonCustomerSideCrossMargined) + | "HouseTraderCrossMargined" -> (Some FIX_AccountType_HouseTraderCrossMargined) + | "JointBackOfficeAccount" -> (Some FIX_AccountType_JointBackOfficeAccount) + | _ -> None + ) +;; + +let string_to_acctidsource_opt (d) = + (match d with + | "BIC" -> (Some FIX_AcctIDSource_BIC) + | "SIDCode" -> (Some FIX_AcctIDSource_SIDCode) + | "TFM" -> (Some FIX_AcctIDSource_TFM) + | "OMGEO" -> (Some FIX_AcctIDSource_OMGEO) + | "DTCCCode" -> (Some FIX_AcctIDSource_DTCCCode) + | "Other" -> (Some FIX_AcctIDSource_Other) + | _ -> None + ) +;; + +let string_to_adjustment_opt (d) = + (match d with + | "Cancel" -> (Some FIX_Adjustment_Cancel) + | "Error" -> (Some FIX_Adjustment_Error) + | "Correction" -> (Some FIX_Adjustment_Correction) + | _ -> None + ) +;; + +let string_to_adjustmenttype_opt (d) = + (match d with + | "ProcessRequestAsMarginDisposition" -> (Some FIX_AdjustmentType_ProcessRequestAsMarginDisposition) + | "DeltaPlus" -> (Some FIX_AdjustmentType_DeltaPlus) + | "DeltaMinus" -> (Some FIX_AdjustmentType_DeltaMinus) + | "Final" -> (Some FIX_AdjustmentType_Final) + | _ -> None + ) +;; + +let string_to_advside_opt (d) = + (match d with + | "Buy" -> (Some FIX_AdvSide_Buy) + | "Sell" -> (Some FIX_AdvSide_Sell) + | "Cross" -> (Some FIX_AdvSide_Cross) + | "Trade" -> (Some FIX_AdvSide_Trade) + | _ -> None + ) +;; + +let string_to_advtranstype_opt (d) = + (match d with + | "New" -> (Some FIX_AdvTransType_New) + | "Cancel" -> (Some FIX_AdvTransType_Cancel) + | "Replace" -> (Some FIX_AdvTransType_Replace) + | _ -> None + ) +;; + +let string_to_affirmstatus_opt (d) = + (match d with + | "Received" -> (Some FIX_AffirmStatus_Received) + | "ConfirmRejected" -> (Some FIX_AffirmStatus_ConfirmRejected) + | "Affirmed" -> (Some FIX_AffirmStatus_Affirmed) + | _ -> None + ) +;; + +let string_to_aggregatedbook_opt (d) = + (match d with + | "BookEntriesToBeAggregated" -> (Some FIX_AggregatedBook_BookEntriesToBeAggregated) + | "BookEntriesShouldNotBeAggregated" -> (Some FIX_AggregatedBook_BookEntriesShouldNotBeAggregated) + | _ -> None + ) +;; + +let string_to_allocaccounttype_opt (d) = + (match d with + | "CarriedCustomerSide" -> (Some FIX_AllocAccountType_CarriedCustomerSide) + | "CarriedNonCustomerSide" -> (Some FIX_AllocAccountType_CarriedNonCustomerSide) + | "HouseTrader" -> (Some FIX_AllocAccountType_HouseTrader) + | "FloorTrader" -> (Some FIX_AllocAccountType_FloorTrader) + | "CarriedNonCustomerSideCrossMargined" -> (Some FIX_AllocAccountType_CarriedNonCustomerSideCrossMargined) + | "HouseTraderCrossMargined" -> (Some FIX_AllocAccountType_HouseTraderCrossMargined) + | "JointBackOfficeAccount" -> (Some FIX_AllocAccountType_JointBackOfficeAccount) + | _ -> None + ) +;; + +let string_to_alloccancreplacereason_opt (d) = + (match d with + | "OriginalDetailsIncomplete" -> (Some FIX_AllocCancReplaceReason_OriginalDetailsIncomplete) + | "ChangeInUnderlyingOrderDetails" -> (Some FIX_AllocCancReplaceReason_ChangeInUnderlyingOrderDetails) + | "Other" -> (Some FIX_AllocCancReplaceReason_Other) + | _ -> None + ) +;; + +let string_to_allochandlinst_opt (d) = + (match d with + | "Match" -> (Some FIX_AllocHandlInst_Match) + | "Forward" -> (Some FIX_AllocHandlInst_Forward) + | "ForwardAndMatch" -> (Some FIX_AllocHandlInst_ForwardAndMatch) + | _ -> None + ) +;; + +let string_to_allocintermedreqtype_opt (d) = + (match d with + | "PendingAccept" -> (Some FIX_AllocIntermedReqType_PendingAccept) + | "PendingRelease" -> (Some FIX_AllocIntermedReqType_PendingRelease) + | "PendingReversal" -> (Some FIX_AllocIntermedReqType_PendingReversal) + | "Accept" -> (Some FIX_AllocIntermedReqType_Accept) + | "BlockLevelReject" -> (Some FIX_AllocIntermedReqType_BlockLevelReject) + | "AccountLevelReject" -> (Some FIX_AllocIntermedReqType_AccountLevelReject) + | _ -> None + ) +;; + +let string_to_alloclinktype_opt (d) = + (match d with + | "FXNetting" -> (Some FIX_AllocLinkType_FXNetting) + | "FXSwap" -> (Some FIX_AllocLinkType_FXSwap) + | _ -> None + ) +;; + +let string_to_allocnoorderstype_opt (d) = + (match d with + | "NotSpecified" -> (Some FIX_AllocNoOrdersType_NotSpecified) + | "ExplicitListProvided" -> (Some FIX_AllocNoOrdersType_ExplicitListProvided) + | _ -> None + ) +;; + +let string_to_allocrejcode_opt (d) = + (match d with + | "UnknownAccount" -> (Some FIX_AllocRejCode_UnknownAccount) + | "IncorrectQuantity" -> (Some FIX_AllocRejCode_IncorrectQuantity) + | "IncorrectAveragegPrice" -> (Some FIX_AllocRejCode_IncorrectAveragegPrice) + | "UnknownExecutingBrokerMnemonic" -> (Some FIX_AllocRejCode_UnknownExecutingBrokerMnemonic) + | "CommissionDifference" -> (Some FIX_AllocRejCode_CommissionDifference) + | "UnknownOrderID" -> (Some FIX_AllocRejCode_UnknownOrderID) + | "UnknownListID" -> (Some FIX_AllocRejCode_UnknownListID) + | "OtherSeeText" -> (Some FIX_AllocRejCode_OtherSeeText) + | "IncorrectAllocatedQuantity" -> (Some FIX_AllocRejCode_IncorrectAllocatedQuantity) + | "CalculationDifference" -> (Some FIX_AllocRejCode_CalculationDifference) + | "UnknownOrStaleExecID" -> (Some FIX_AllocRejCode_UnknownOrStaleExecID) + | "MismatchedData" -> (Some FIX_AllocRejCode_MismatchedData) + | "UnknownClOrdID" -> (Some FIX_AllocRejCode_UnknownClOrdID) + | "WarehouseRequestRejected" -> (Some FIX_AllocRejCode_WarehouseRequestRejected) + | _ -> None + ) +;; + +let string_to_allocreporttype_opt (d) = + (match d with + | "SellsideCalculatedUsingPreliminary" -> (Some FIX_AllocReportType_SellsideCalculatedUsingPreliminary) + | "SellsideCalculatedWithoutPreliminary" -> (Some FIX_AllocReportType_SellsideCalculatedWithoutPreliminary) + | "WarehouseRecap" -> (Some FIX_AllocReportType_WarehouseRecap) + | "RequestToIntermediary" -> (Some FIX_AllocReportType_RequestToIntermediary) + | _ -> None + ) +;; + +let string_to_allocsettlinsttype_opt (d) = + (match d with + | "UseDefaultInstructions" -> (Some FIX_AllocSettlInstType_UseDefaultInstructions) + | "DeriveFromParametersProvided" -> (Some FIX_AllocSettlInstType_DeriveFromParametersProvided) + | "FullDetailsProvided" -> (Some FIX_AllocSettlInstType_FullDetailsProvided) + | "SSIDBIDsProvided" -> (Some FIX_AllocSettlInstType_SSIDBIDsProvided) + | "PhoneForInstructions" -> (Some FIX_AllocSettlInstType_PhoneForInstructions) + | _ -> None + ) +;; + +let string_to_allocstatus_opt (d) = + (match d with + | "Accepted" -> (Some FIX_AllocStatus_Accepted) + | "BlockLevelReject" -> (Some FIX_AllocStatus_BlockLevelReject) + | "AccountLevelReject" -> (Some FIX_AllocStatus_AccountLevelReject) + | "Received" -> (Some FIX_AllocStatus_Received) + | "Incomplete" -> (Some FIX_AllocStatus_Incomplete) + | "RejectedByIntermediary" -> (Some FIX_AllocStatus_RejectedByIntermediary) + | _ -> None + ) +;; + +let string_to_alloctranstype_opt (d) = + (match d with + | "New" -> (Some FIX_AllocTransType_New) + | "Replace" -> (Some FIX_AllocTransType_Replace) + | "Cancel" -> (Some FIX_AllocTransType_Cancel) + | _ -> None + ) +;; + +let string_to_alloctype_opt (d) = + (match d with + | "Calculated" -> (Some FIX_AllocType_Calculated) + | "Preliminary" -> (Some FIX_AllocType_Preliminary) + | "ReadyToBook" -> (Some FIX_AllocType_ReadyToBook) + | "WarehouseInstruction" -> (Some FIX_AllocType_WarehouseInstruction) + | "RequestToIntermediary" -> (Some FIX_AllocType_RequestToIntermediary) + | _ -> None + ) +;; + +let string_to_applqueueaction_opt (d) = + (match d with + | "NoActionTaken" -> (Some FIX_ApplQueueAction_NoActionTaken) + | "QueueFlushed" -> (Some FIX_ApplQueueAction_QueueFlushed) + | "OverlayLast" -> (Some FIX_ApplQueueAction_OverlayLast) + | "EndSession" -> (Some FIX_ApplQueueAction_EndSession) + | _ -> None + ) +;; + +let string_to_applqueueresolution_opt (d) = + (match d with + | "NoActionTaken" -> (Some FIX_ApplQueueResolution_NoActionTaken) + | "QueueFlushed" -> (Some FIX_ApplQueueResolution_QueueFlushed) + | "OverlayLast" -> (Some FIX_ApplQueueResolution_OverlayLast) + | "EndSession" -> (Some FIX_ApplQueueResolution_EndSession) + | _ -> None + ) +;; + +let string_to_assignmentmethod_opt (d) = + (match d with + | "Random" -> (Some FIX_AssignmentMethod_Random) + | "ProRata" -> (Some FIX_AssignmentMethod_ProRata) + | _ -> None + ) +;; + +let string_to_avgpxindicator_opt (d) = + (match d with + | "NoAveragePricing" -> (Some FIX_AvgPxIndicator_NoAveragePricing) + | "Trade" -> (Some FIX_AvgPxIndicator_Trade) + | "LastTrade" -> (Some FIX_AvgPxIndicator_LastTrade) + | _ -> None + ) +;; + +let string_to_basispxtype_opt (d) = + (match d with + | "ClosingPriceAtMorningSession" -> (Some FIX_BasisPxType_ClosingPriceAtMorningSession) + | "ClosingPrice" -> (Some FIX_BasisPxType_ClosingPrice) + | "CurrentPrice" -> (Some FIX_BasisPxType_CurrentPrice) + | "SQ" -> (Some FIX_BasisPxType_SQ) + | "VWAPThroughADay" -> (Some FIX_BasisPxType_VWAPThroughADay) + | "VWAPThroughAMorningSession" -> (Some FIX_BasisPxType_VWAPThroughAMorningSession) + | "VWAPThroughAnAfternoonSession" -> (Some FIX_BasisPxType_VWAPThroughAnAfternoonSession) + | "VWAPThroughADayExcept" -> (Some FIX_BasisPxType_VWAPThroughADayExcept) + | "VWAPThroughAMorningSessionExcept" -> (Some FIX_BasisPxType_VWAPThroughAMorningSessionExcept) + | "VWAPThroughAnAfternoonSessionExcept" -> (Some FIX_BasisPxType_VWAPThroughAnAfternoonSessionExcept) + | "Strike" -> (Some FIX_BasisPxType_Strike) + | "Open" -> (Some FIX_BasisPxType_Open) + | "Others" -> (Some FIX_BasisPxType_Others) + | _ -> None + ) +;; + +let string_to_biddescriptortype_opt (d) = + (match d with + | "Sector" -> (Some FIX_BidDescriptorType_Sector) + | "Country" -> (Some FIX_BidDescriptorType_Country) + | "Index" -> (Some FIX_BidDescriptorType_Index) + | _ -> None + ) +;; + +let string_to_bidrequesttranstype_opt (d) = + (match d with + | "New" -> (Some FIX_BidRequestTransType_New) + | "Cancel" -> (Some FIX_BidRequestTransType_Cancel) + | _ -> None + ) +;; + +let string_to_bidtradetype_opt (d) = + (match d with + | "RiskTrade" -> (Some FIX_BidTradeType_RiskTrade) + | "VWAPGuarantee" -> (Some FIX_BidTradeType_VWAPGuarantee) + | "Agency" -> (Some FIX_BidTradeType_Agency) + | "GuaranteedClose" -> (Some FIX_BidTradeType_GuaranteedClose) + | _ -> None + ) +;; + +let string_to_bidtype_opt (d) = + (match d with + | "NonDisclosed" -> (Some FIX_BidType_NonDisclosed) + | "Disclosed" -> (Some FIX_BidType_Disclosed) + | "NoBiddingProcess" -> (Some FIX_BidType_NoBiddingProcess) + | _ -> None + ) +;; + +let string_to_bookingtype_opt (d) = + (match d with + | "RegularBooking" -> (Some FIX_BookingType_RegularBooking) + | "CFD" -> (Some FIX_BookingType_CFD) + | "TotalReturnSwap" -> (Some FIX_BookingType_TotalReturnSwap) + | _ -> None + ) +;; + +let string_to_bookingunit_opt (d) = + (match d with + | "EachPartialExecutionIsABookableUnit" -> (Some FIX_BookingUnit_EachPartialExecutionIsABookableUnit) + | "AggregatePartialExecutionsOnThisOrder" -> (Some FIX_BookingUnit_AggregatePartialExecutionsOnThisOrder) + | "AggregateExecutionsForThisSymbol" -> (Some FIX_BookingUnit_AggregateExecutionsForThisSymbol) + | _ -> None + ) +;; + +let string_to_cpprogram_opt (d) = + (match d with + | "Program3a3" -> (Some FIX_CPProgram_Program3a3) + | "Program42" -> (Some FIX_CPProgram_Program42) + | "Other" -> (Some FIX_CPProgram_Other) + | _ -> None + ) +;; + +let string_to_cancellationrights_opt (d) = + (match d with + | "Yes" -> (Some FIX_CancellationRights_Yes) + | "NoExecutionOnly" -> (Some FIX_CancellationRights_NoExecutionOnly) + | "NoWaiverAgreement" -> (Some FIX_CancellationRights_NoWaiverAgreement) + | "NoInstitutional" -> (Some FIX_CancellationRights_NoInstitutional) + | _ -> None + ) +;; + +let string_to_cashmargin_opt (d) = + (match d with + | "Cash" -> (Some FIX_CashMargin_Cash) + | "MarginOpen" -> (Some FIX_CashMargin_MarginOpen) + | "MarginClose" -> (Some FIX_CashMargin_MarginClose) + | _ -> None + ) +;; + +let string_to_clearingfeeindicator_opt (d) = + (match d with + | "CBOEMember" -> (Some FIX_ClearingFeeIndicator_CBOEMember) + | "NonMemberAndCustomer" -> (Some FIX_ClearingFeeIndicator_NonMemberAndCustomer) + | "EquityMemberAndClearingMember" -> (Some FIX_ClearingFeeIndicator_EquityMemberAndClearingMember) + | "FullAndAssociateMember" -> (Some FIX_ClearingFeeIndicator_FullAndAssociateMember) + | "Firms106HAnd106J" -> (Some FIX_ClearingFeeIndicator_Firms106HAnd106J) + | "GIM" -> (Some FIX_ClearingFeeIndicator_GIM) + | "Lessee106FEmployees" -> (Some FIX_ClearingFeeIndicator_Lessee106FEmployees) + | "AllOtherOwnershipTypes" -> (Some FIX_ClearingFeeIndicator_AllOtherOwnershipTypes) + | "FirstYearDelegate" -> (Some FIX_ClearingFeeIndicator_FirstYearDelegate) + | "SecondYearDelegate" -> (Some FIX_ClearingFeeIndicator_SecondYearDelegate) + | "ThirdYearDelegate" -> (Some FIX_ClearingFeeIndicator_ThirdYearDelegate) + | "FourthYearDelegate" -> (Some FIX_ClearingFeeIndicator_FourthYearDelegate) + | "FifthYearDelegate" -> (Some FIX_ClearingFeeIndicator_FifthYearDelegate) + | "SixthYearDelegate" -> (Some FIX_ClearingFeeIndicator_SixthYearDelegate) + | _ -> None + ) +;; + +let string_to_clearinginstruction_opt (d) = + (match d with + | "ProcessNormally" -> (Some FIX_ClearingInstruction_ProcessNormally) + | "ExcludeFromAllNetting" -> (Some FIX_ClearingInstruction_ExcludeFromAllNetting) + | "BilateralNettingOnly" -> (Some FIX_ClearingInstruction_BilateralNettingOnly) + | "ExClearing" -> (Some FIX_ClearingInstruction_ExClearing) + | "SpecialTrade" -> (Some FIX_ClearingInstruction_SpecialTrade) + | "MultilateralNetting" -> (Some FIX_ClearingInstruction_MultilateralNetting) + | "ClearAgainstCentralCounterparty" -> (Some FIX_ClearingInstruction_ClearAgainstCentralCounterparty) + | "ExcludeFromCentralCounterparty" -> (Some FIX_ClearingInstruction_ExcludeFromCentralCounterparty) + | "ManualMode" -> (Some FIX_ClearingInstruction_ManualMode) + | "AutomaticPostingMode" -> (Some FIX_ClearingInstruction_AutomaticPostingMode) + | "AutomaticGiveUpMode" -> (Some FIX_ClearingInstruction_AutomaticGiveUpMode) + | "QualifiedServiceRepresentativeQSR" -> (Some FIX_ClearingInstruction_QualifiedServiceRepresentativeQSR) + | "CustomerTrade" -> (Some FIX_ClearingInstruction_CustomerTrade) + | "SelfClearing" -> (Some FIX_ClearingInstruction_SelfClearing) + | _ -> None + ) +;; + +let string_to_collaction_opt (d) = + (match d with + | "Retain" -> (Some FIX_CollAction_Retain) + | "Add" -> (Some FIX_CollAction_Add) + | "Remove" -> (Some FIX_CollAction_Remove) + | _ -> None + ) +;; + +let string_to_collasgnreason_opt (d) = + (match d with + | "Initial" -> (Some FIX_CollAsgnReason_Initial) + | "Scheduled" -> (Some FIX_CollAsgnReason_Scheduled) + | "TimeWarning" -> (Some FIX_CollAsgnReason_TimeWarning) + | "MarginDeficiency" -> (Some FIX_CollAsgnReason_MarginDeficiency) + | "MarginExcess" -> (Some FIX_CollAsgnReason_MarginExcess) + | "ForwardCollateralDemand" -> (Some FIX_CollAsgnReason_ForwardCollateralDemand) + | "EventOfDefault" -> (Some FIX_CollAsgnReason_EventOfDefault) + | "AdverseTaxEvent" -> (Some FIX_CollAsgnReason_AdverseTaxEvent) + | _ -> None + ) +;; + +let string_to_collasgnrejectreason_opt (d) = + (match d with + | "UnknownDeal" -> (Some FIX_CollAsgnRejectReason_UnknownDeal) + | "UnknownOrInvalidInstrument" -> (Some FIX_CollAsgnRejectReason_UnknownOrInvalidInstrument) + | "UnauthorizedTransaction" -> (Some FIX_CollAsgnRejectReason_UnauthorizedTransaction) + | "InsufficientCollateral" -> (Some FIX_CollAsgnRejectReason_InsufficientCollateral) + | "InvalidTypeOfCollateral" -> (Some FIX_CollAsgnRejectReason_InvalidTypeOfCollateral) + | "ExcessiveSubstitution" -> (Some FIX_CollAsgnRejectReason_ExcessiveSubstitution) + | "Other" -> (Some FIX_CollAsgnRejectReason_Other) + | _ -> None + ) +;; + +let string_to_collasgnresptype_opt (d) = + (match d with + | "Received" -> (Some FIX_CollAsgnRespType_Received) + | "Accepted" -> (Some FIX_CollAsgnRespType_Accepted) + | "Declined" -> (Some FIX_CollAsgnRespType_Declined) + | "Rejected" -> (Some FIX_CollAsgnRespType_Rejected) + | _ -> None + ) +;; + +let string_to_collasgntranstype_opt (d) = + (match d with + | "New" -> (Some FIX_CollAsgnTransType_New) + | "Replace" -> (Some FIX_CollAsgnTransType_Replace) + | "Cancel" -> (Some FIX_CollAsgnTransType_Cancel) + | "Release" -> (Some FIX_CollAsgnTransType_Release) + | "Reverse" -> (Some FIX_CollAsgnTransType_Reverse) + | _ -> None + ) +;; + +let string_to_collinquiryqualifier_opt (d) = + (match d with + | "TradeDate" -> (Some FIX_CollInquiryQualifier_TradeDate) + | "GCInstrument" -> (Some FIX_CollInquiryQualifier_GCInstrument) + | "CollateralInstrument" -> (Some FIX_CollInquiryQualifier_CollateralInstrument) + | "SubstitutionEligible" -> (Some FIX_CollInquiryQualifier_SubstitutionEligible) + | "NotAssigned" -> (Some FIX_CollInquiryQualifier_NotAssigned) + | "PartiallyAssigned" -> (Some FIX_CollInquiryQualifier_PartiallyAssigned) + | "FullyAssigned" -> (Some FIX_CollInquiryQualifier_FullyAssigned) + | "OutstandingTrades" -> (Some FIX_CollInquiryQualifier_OutstandingTrades) + | _ -> None + ) +;; + +let string_to_collinquiryresult_opt (d) = + (match d with + | "Successful" -> (Some FIX_CollInquiryResult_Successful) + | "InvalidOrUnknownInstrument" -> (Some FIX_CollInquiryResult_InvalidOrUnknownInstrument) + | "InvalidOrUnknownCollateralType" -> (Some FIX_CollInquiryResult_InvalidOrUnknownCollateralType) + | "InvalidParties" -> (Some FIX_CollInquiryResult_InvalidParties) + | "InvalidTransportTypeRequested" -> (Some FIX_CollInquiryResult_InvalidTransportTypeRequested) + | "InvalidDestinationRequested" -> (Some FIX_CollInquiryResult_InvalidDestinationRequested) + | "NoCollateralFoundForTheTradeSpecified" -> (Some FIX_CollInquiryResult_NoCollateralFoundForTheTradeSpecified) + | "NoCollateralFoundForTheOrderSpecified" -> (Some FIX_CollInquiryResult_NoCollateralFoundForTheOrderSpecified) + | "CollateralInquiryTypeNotSupported" -> (Some FIX_CollInquiryResult_CollateralInquiryTypeNotSupported) + | "UnauthorizedForCollateralInquiry" -> (Some FIX_CollInquiryResult_UnauthorizedForCollateralInquiry) + | "Other" -> (Some FIX_CollInquiryResult_Other) + | _ -> None + ) +;; + +let string_to_collinquirystatus_opt (d) = + (match d with + | "Accepted" -> (Some FIX_CollInquiryStatus_Accepted) + | "AcceptedWithWarnings" -> (Some FIX_CollInquiryStatus_AcceptedWithWarnings) + | "Completed" -> (Some FIX_CollInquiryStatus_Completed) + | "CompletedWithWarnings" -> (Some FIX_CollInquiryStatus_CompletedWithWarnings) + | "Rejected" -> (Some FIX_CollInquiryStatus_Rejected) + | _ -> None + ) +;; + +let string_to_collstatus_opt (d) = + (match d with + | "Unassigned" -> (Some FIX_CollStatus_Unassigned) + | "PartiallyAssigned" -> (Some FIX_CollStatus_PartiallyAssigned) + | "AssignmentProposed" -> (Some FIX_CollStatus_AssignmentProposed) + | "Assigned" -> (Some FIX_CollStatus_Assigned) + | "Challenged" -> (Some FIX_CollStatus_Challenged) + | _ -> None + ) +;; + +let string_to_commtype_opt (d) = + (match d with + | "PerUnit" -> (Some FIX_CommType_PerUnit) + | "Percent" -> (Some FIX_CommType_Percent) + | "Absolute" -> (Some FIX_CommType_Absolute) + | "PercentageWaivedCashDiscount" -> (Some FIX_CommType_PercentageWaivedCashDiscount) + | "PercentageWaivedEnhancedUnits" -> (Some FIX_CommType_PercentageWaivedEnhancedUnits) + | "PointsPerBondOrContract" -> (Some FIX_CommType_PointsPerBondOrContract) + | _ -> None + ) +;; + +let string_to_confirmrejreason_opt (d) = + (match d with + | "MismatchedAccount" -> (Some FIX_ConfirmRejReason_MismatchedAccount) + | "MissingSettlementInstructions" -> (Some FIX_ConfirmRejReason_MissingSettlementInstructions) + | "Other" -> (Some FIX_ConfirmRejReason_Other) + | _ -> None + ) +;; + +let string_to_confirmstatus_opt (d) = + (match d with + | "Received" -> (Some FIX_ConfirmStatus_Received) + | "MismatchedAccount" -> (Some FIX_ConfirmStatus_MismatchedAccount) + | "MissingSettlementInstructions" -> (Some FIX_ConfirmStatus_MissingSettlementInstructions) + | "Confirmed" -> (Some FIX_ConfirmStatus_Confirmed) + | "RequestRejected" -> (Some FIX_ConfirmStatus_RequestRejected) + | _ -> None + ) +;; + +let string_to_confirmtranstype_opt (d) = + (match d with + | "New" -> (Some FIX_ConfirmTransType_New) + | "Replace" -> (Some FIX_ConfirmTransType_Replace) + | "Cancel" -> (Some FIX_ConfirmTransType_Cancel) + | _ -> None + ) +;; + +let string_to_confirmtype_opt (d) = + (match d with + | "Status" -> (Some FIX_ConfirmType_Status) + | "Confirmation" -> (Some FIX_ConfirmType_Confirmation) + | "ConfirmationRequestRejected" -> (Some FIX_ConfirmType_ConfirmationRequestRejected) + | _ -> None + ) +;; + +let string_to_contamttype_opt (d) = + (match d with + | "CommissionAmount" -> (Some FIX_ContAmtType_CommissionAmount) + | "CommissionPercent" -> (Some FIX_ContAmtType_CommissionPercent) + | "InitialChargeAmount" -> (Some FIX_ContAmtType_InitialChargeAmount) + | "InitialChargePercent" -> (Some FIX_ContAmtType_InitialChargePercent) + | "DiscountAmount" -> (Some FIX_ContAmtType_DiscountAmount) + | "DiscountPercent" -> (Some FIX_ContAmtType_DiscountPercent) + | "DilutionLevyAmount" -> (Some FIX_ContAmtType_DilutionLevyAmount) + | "DilutionLevyPercent" -> (Some FIX_ContAmtType_DilutionLevyPercent) + | "ExitChargeAmount" -> (Some FIX_ContAmtType_ExitChargeAmount) + | "ExitChargePercent" -> (Some FIX_ContAmtType_ExitChargePercent) + | "FundBasedRenewalCommissionPercent" -> (Some FIX_ContAmtType_FundBasedRenewalCommissionPercent) + | "ProjectedFundValue" -> (Some FIX_ContAmtType_ProjectedFundValue) + | "FundBasedRenewalCommissionOnOrder" -> (Some FIX_ContAmtType_FundBasedRenewalCommissionOnOrder) + | "FundBasedRenewalCommissionOnFund" -> (Some FIX_ContAmtType_FundBasedRenewalCommissionOnFund) + | "NetSettlementAmount" -> (Some FIX_ContAmtType_NetSettlementAmount) + | _ -> None + ) +;; + +let string_to_corporateaction_opt (d) = + (match d with + | "ExDividend" -> (Some FIX_CorporateAction_ExDividend) + | "ExDistribution" -> (Some FIX_CorporateAction_ExDistribution) + | "ExRights" -> (Some FIX_CorporateAction_ExRights) + | "New" -> (Some FIX_CorporateAction_New) + | "ExInterest" -> (Some FIX_CorporateAction_ExInterest) + | _ -> None + ) +;; + +let string_to_coveredoruncovered_opt (d) = + (match d with + | "Covered" -> (Some FIX_CoveredOrUncovered_Covered) + | "Uncovered" -> (Some FIX_CoveredOrUncovered_Uncovered) + | _ -> None + ) +;; + +let string_to_crossprioritization_opt (d) = + (match d with + | "FIXNone" -> (Some FIX_CrossPrioritization_FIXNone) + | "BuySideIsPrioritized" -> (Some FIX_CrossPrioritization_BuySideIsPrioritized) + | "SellSideIsPrioritized" -> (Some FIX_CrossPrioritization_SellSideIsPrioritized) + | _ -> None + ) +;; + +let string_to_crosstype_opt (d) = + (match d with + | "CrossAON" -> (Some FIX_CrossType_CrossAON) + | "CrossIOC" -> (Some FIX_CrossType_CrossIOC) + | "CrossOneSide" -> (Some FIX_CrossType_CrossOneSide) + | "CrossSamePrice" -> (Some FIX_CrossType_CrossSamePrice) + | _ -> None + ) +;; + +let string_to_custordercapacity_opt (d) = + (match d with + | "MemberTradingForTheirOwnAccount" -> (Some FIX_CustOrderCapacity_MemberTradingForTheirOwnAccount) + | "ClearingFirmTradingForItsProprietaryAccount" -> (Some FIX_CustOrderCapacity_ClearingFirmTradingForItsProprietaryAccount) + | "MemberTradingForAnotherMember" -> (Some FIX_CustOrderCapacity_MemberTradingForAnotherMember) + | "AllOther" -> (Some FIX_CustOrderCapacity_AllOther) + | _ -> None + ) +;; + +let string_to_cxlrejreason_opt (d) = + (match d with + | "TooLateToCancel" -> (Some FIX_CxlRejReason_TooLateToCancel) + | "UnknownOrder" -> (Some FIX_CxlRejReason_UnknownOrder) + | "BrokerCredit" -> (Some FIX_CxlRejReason_BrokerCredit) + | "OrderAlreadyInPendingStatus" -> (Some FIX_CxlRejReason_OrderAlreadyInPendingStatus) + | "UnableToProcessOrderMassCancelRequest" -> (Some FIX_CxlRejReason_UnableToProcessOrderMassCancelRequest) + | "OrigOrdModTime" -> (Some FIX_CxlRejReason_OrigOrdModTime) + | "DuplicateClOrdID" -> (Some FIX_CxlRejReason_DuplicateClOrdID) + | "Other" -> (Some FIX_CxlRejReason_Other) + | _ -> None + ) +;; + +let string_to_dkreason_opt (d) = + (match d with + | "UnknownSymbol" -> (Some FIX_DKReason_UnknownSymbol) + | "WrongSide" -> (Some FIX_DKReason_WrongSide) + | "QuantityExceedsOrder" -> (Some FIX_DKReason_QuantityExceedsOrder) + | "NoMatchingOrder" -> (Some FIX_DKReason_NoMatchingOrder) + | "PriceExceedsLimit" -> (Some FIX_DKReason_PriceExceedsLimit) + | "CalculationDifference" -> (Some FIX_DKReason_CalculationDifference) + | "Other" -> (Some FIX_DKReason_Other) + | _ -> None + ) +;; + +let string_to_daybookinginst_opt (d) = + (match d with + | "Auto" -> (Some FIX_DayBookingInst_Auto) + | "SpeakWithOrderInitiatorBeforeBooking" -> (Some FIX_DayBookingInst_SpeakWithOrderInitiatorBeforeBooking) + | "Accumulate" -> (Some FIX_DayBookingInst_Accumulate) + | _ -> None + ) +;; + +let string_to_deletereason_opt (d) = + (match d with + | "Cancellation" -> (Some FIX_DeleteReason_Cancellation) + | "Error" -> (Some FIX_DeleteReason_Error) + | _ -> None + ) +;; + +let string_to_deliveryform_opt (d) = + (match d with + | "BookEntry" -> (Some FIX_DeliveryForm_BookEntry) + | "Bearer" -> (Some FIX_DeliveryForm_Bearer) + | _ -> None + ) +;; + +let string_to_deliverytype_opt (d) = + (match d with + | "VersusPayment" -> (Some FIX_DeliveryType_VersusPayment) + | "Free" -> (Some FIX_DeliveryType_Free) + | "TriParty" -> (Some FIX_DeliveryType_TriParty) + | "HoldInCustody" -> (Some FIX_DeliveryType_HoldInCustody) + | _ -> None + ) +;; + +let string_to_discretioninst_opt (d) = + (match d with + | "RelatedToDisplayedPrice" -> (Some FIX_DiscretionInst_RelatedToDisplayedPrice) + | "RelatedToMarketPrice" -> (Some FIX_DiscretionInst_RelatedToMarketPrice) + | "RelatedToPrimaryPrice" -> (Some FIX_DiscretionInst_RelatedToPrimaryPrice) + | "RelatedToLocalPrimaryPrice" -> (Some FIX_DiscretionInst_RelatedToLocalPrimaryPrice) + | "RelatedToMidpointPrice" -> (Some FIX_DiscretionInst_RelatedToMidpointPrice) + | "RelatedToLastTradePrice" -> (Some FIX_DiscretionInst_RelatedToLastTradePrice) + | "RelatedToVWAP" -> (Some FIX_DiscretionInst_RelatedToVWAP) + | _ -> None + ) +;; + +let string_to_discretionlimittype_opt (d) = + (match d with + | "OrBetter" -> (Some FIX_DiscretionLimitType_OrBetter) + | "Strict" -> (Some FIX_DiscretionLimitType_Strict) + | "OrWorse" -> (Some FIX_DiscretionLimitType_OrWorse) + | _ -> None + ) +;; + +let string_to_discretionmovetype_opt (d) = + (match d with + | "Floating" -> (Some FIX_DiscretionMoveType_Floating) + | "Fixed" -> (Some FIX_DiscretionMoveType_Fixed) + | _ -> None + ) +;; + +let string_to_discretionoffsettype_opt (d) = + (match d with + | "Price" -> (Some FIX_DiscretionOffsetType_Price) + | "BasisPoints" -> (Some FIX_DiscretionOffsetType_BasisPoints) + | "Ticks" -> (Some FIX_DiscretionOffsetType_Ticks) + | "PriceTier" -> (Some FIX_DiscretionOffsetType_PriceTier) + | _ -> None + ) +;; + +let string_to_discretionrounddirection_opt (d) = + (match d with + | "MoreAggressive" -> (Some FIX_DiscretionRoundDirection_MoreAggressive) + | "MorePassive" -> (Some FIX_DiscretionRoundDirection_MorePassive) + | _ -> None + ) +;; + +let string_to_discretionscope_opt (d) = + (match d with + | "Local" -> (Some FIX_DiscretionScope_Local) + | "National" -> (Some FIX_DiscretionScope_National) + | "Global" -> (Some FIX_DiscretionScope_Global) + | "NationalExcludingLocal" -> (Some FIX_DiscretionScope_NationalExcludingLocal) + | _ -> None + ) +;; + +let string_to_distribpaymentmethod_opt (d) = + (match d with + | "CREST" -> (Some FIX_DistribPaymentMethod_CREST) + | "NSCC" -> (Some FIX_DistribPaymentMethod_NSCC) + | "Euroclear" -> (Some FIX_DistribPaymentMethod_Euroclear) + | "Clearstream" -> (Some FIX_DistribPaymentMethod_Clearstream) + | "Cheque" -> (Some FIX_DistribPaymentMethod_Cheque) + | "TelegraphicTransfer" -> (Some FIX_DistribPaymentMethod_TelegraphicTransfer) + | "FedWire" -> (Some FIX_DistribPaymentMethod_FedWire) + | "DirectCredit" -> (Some FIX_DistribPaymentMethod_DirectCredit) + | "ACHCredit" -> (Some FIX_DistribPaymentMethod_ACHCredit) + | "BPAY" -> (Some FIX_DistribPaymentMethod_BPAY) + | "HighValueClearingSystemHVACS" -> (Some FIX_DistribPaymentMethod_HighValueClearingSystemHVACS) + | "ReinvestInFund" -> (Some FIX_DistribPaymentMethod_ReinvestInFund) + | _ -> None + ) +;; + +let string_to_dlvyinsttype_opt (d) = + (match d with + | "Securities" -> (Some FIX_DlvyInstType_Securities) + | "Cash" -> (Some FIX_DlvyInstType_Cash) + | _ -> None + ) +;; + +let string_to_duetorelated_opt (d) = + (match d with + | "RelatedToSecurityHalt" -> (Some FIX_DueToRelated_RelatedToSecurityHalt) + | "NotRelatedToSecurityHalt" -> (Some FIX_DueToRelated_NotRelatedToSecurityHalt) + | _ -> None + ) +;; + +let string_to_emailtype_opt (d) = + (match d with + | "New" -> (Some FIX_EmailType_New) + | "Reply" -> (Some FIX_EmailType_Reply) + | "AdminReply" -> (Some FIX_EmailType_AdminReply) + | _ -> None + ) +;; + +let string_to_eventtype_opt (d) = + (match d with + | "Put" -> (Some FIX_EventType_Put) + | "Call" -> (Some FIX_EventType_Call) + | "Tender" -> (Some FIX_EventType_Tender) + | "SinkingFundCall" -> (Some FIX_EventType_SinkingFundCall) + | "Other" -> (Some FIX_EventType_Other) + | _ -> None + ) +;; + +let string_to_exchangeforphysical_opt (d) = + (match d with + | "True" -> (Some FIX_ExchangeForPhysical_True) + | "False" -> (Some FIX_ExchangeForPhysical_False) + | _ -> None + ) +;; + +let string_to_execinst_opt (d) = + (match d with + | "NotHeld" -> (Some FIX_ExecInst_NotHeld) + | "Work" -> (Some FIX_ExecInst_Work) + | "GoAlong" -> (Some FIX_ExecInst_GoAlong) + | "OverTheDay" -> (Some FIX_ExecInst_OverTheDay) + | "Held" -> (Some FIX_ExecInst_Held) + | "ParticipateDoNotInitiate" -> (Some FIX_ExecInst_ParticipateDoNotInitiate) + | "StrictScale" -> (Some FIX_ExecInst_StrictScale) + | "TryToScale" -> (Some FIX_ExecInst_TryToScale) + | "StayOnBidSide" -> (Some FIX_ExecInst_StayOnBidSide) + | "StayOnOfferSide" -> (Some FIX_ExecInst_StayOnOfferSide) + | "NoCross" -> (Some FIX_ExecInst_NoCross) + | "OKToCross" -> (Some FIX_ExecInst_OKToCross) + | "CallFirst" -> (Some FIX_ExecInst_CallFirst) + | "PercentOfVolume" -> (Some FIX_ExecInst_PercentOfVolume) + | "DoNotIncrease" -> (Some FIX_ExecInst_DoNotIncrease) + | "DoNotReduce" -> (Some FIX_ExecInst_DoNotReduce) + | "AllOrNone" -> (Some FIX_ExecInst_AllOrNone) + | "ReinstateOnSystemFailure" -> (Some FIX_ExecInst_ReinstateOnSystemFailure) + | "InstitutionsOnly" -> (Some FIX_ExecInst_InstitutionsOnly) + | "ReinstateOnTradingHalt" -> (Some FIX_ExecInst_ReinstateOnTradingHalt) + | "CancelOnTradingHalt" -> (Some FIX_ExecInst_CancelOnTradingHalt) + | "LastPeg" -> (Some FIX_ExecInst_LastPeg) + | "MidPricePeg" -> (Some FIX_ExecInst_MidPricePeg) + | "NonNegotiable" -> (Some FIX_ExecInst_NonNegotiable) + | "OpeningPeg" -> (Some FIX_ExecInst_OpeningPeg) + | "MarketPeg" -> (Some FIX_ExecInst_MarketPeg) + | "CancelOnSystemFailure" -> (Some FIX_ExecInst_CancelOnSystemFailure) + | "PrimaryPeg" -> (Some FIX_ExecInst_PrimaryPeg) + | "Suspend" -> (Some FIX_ExecInst_Suspend) + | "CustomerDisplayInstruction" -> (Some FIX_ExecInst_CustomerDisplayInstruction) + | "Netting" -> (Some FIX_ExecInst_Netting) + | "PegToVWAP" -> (Some FIX_ExecInst_PegToVWAP) + | "TradeAlong" -> (Some FIX_ExecInst_TradeAlong) + | "TryToStop" -> (Some FIX_ExecInst_TryToStop) + | "CancelIfNotBest" -> (Some FIX_ExecInst_CancelIfNotBest) + | "TrailingStopPeg" -> (Some FIX_ExecInst_TrailingStopPeg) + | "StrictLimit" -> (Some FIX_ExecInst_StrictLimit) + | "IgnorePriceValidityChecks" -> (Some FIX_ExecInst_IgnorePriceValidityChecks) + | "PegToLimitPrice" -> (Some FIX_ExecInst_PegToLimitPrice) + | "WorkToTargetStrategy" -> (Some FIX_ExecInst_WorkToTargetStrategy) + | _ -> None + ) +;; + +let string_to_execpricetype_opt (d) = + (match d with + | "BidPrice" -> (Some FIX_ExecPriceType_BidPrice) + | "CreationPrice" -> (Some FIX_ExecPriceType_CreationPrice) + | "CreationPricePlusAdjustmentPercent" -> (Some FIX_ExecPriceType_CreationPricePlusAdjustmentPercent) + | "CreationPricePlusAdjustmentAmount" -> (Some FIX_ExecPriceType_CreationPricePlusAdjustmentAmount) + | "OfferPrice" -> (Some FIX_ExecPriceType_OfferPrice) + | "OfferPriceMinusAdjustmentPercent" -> (Some FIX_ExecPriceType_OfferPriceMinusAdjustmentPercent) + | "OfferPriceMinusAdjustmentAmount" -> (Some FIX_ExecPriceType_OfferPriceMinusAdjustmentAmount) + | "SinglePrice" -> (Some FIX_ExecPriceType_SinglePrice) + | _ -> None + ) +;; + +let string_to_execrestatementreason_opt (d) = + (match d with + | "GTCorporateAction" -> (Some FIX_ExecRestatementReason_GTCorporateAction) + | "GTRenewal" -> (Some FIX_ExecRestatementReason_GTRenewal) + | "VerbalChange" -> (Some FIX_ExecRestatementReason_VerbalChange) + | "RepricingOfOrder" -> (Some FIX_ExecRestatementReason_RepricingOfOrder) + | "BrokerOption" -> (Some FIX_ExecRestatementReason_BrokerOption) + | "PartialDeclineOfOrderQty" -> (Some FIX_ExecRestatementReason_PartialDeclineOfOrderQty) + | "CancelOnTradingHalt" -> (Some FIX_ExecRestatementReason_CancelOnTradingHalt) + | "CancelOnSystemFailure" -> (Some FIX_ExecRestatementReason_CancelOnSystemFailure) + | "Market" -> (Some FIX_ExecRestatementReason_Market) + | "Canceled" -> (Some FIX_ExecRestatementReason_Canceled) + | "WarehouseRecap" -> (Some FIX_ExecRestatementReason_WarehouseRecap) + | "Other" -> (Some FIX_ExecRestatementReason_Other) + | _ -> None + ) +;; + +let string_to_exectype_opt (d) = + (match d with + | "New" -> (Some FIX_ExecType_New) + | "DoneForDay" -> (Some FIX_ExecType_DoneForDay) + | "Canceled" -> (Some FIX_ExecType_Canceled) + | "Replaced" -> (Some FIX_ExecType_Replaced) + | "PendingCancel" -> (Some FIX_ExecType_PendingCancel) + | "Stopped" -> (Some FIX_ExecType_Stopped) + | "Rejected" -> (Some FIX_ExecType_Rejected) + | "Suspended" -> (Some FIX_ExecType_Suspended) + | "PendingNew" -> (Some FIX_ExecType_PendingNew) + | "Calculated" -> (Some FIX_ExecType_Calculated) + | "Expired" -> (Some FIX_ExecType_Expired) + | "Restated" -> (Some FIX_ExecType_Restated) + | "PendingReplace" -> (Some FIX_ExecType_PendingReplace) + | "Trade" -> (Some FIX_ExecType_Trade) + | "TradeCorrect" -> (Some FIX_ExecType_TradeCorrect) + | "TradeCancel" -> (Some FIX_ExecType_TradeCancel) + | "OrderStatus" -> (Some FIX_ExecType_OrderStatus) + | _ -> None + ) +;; + +let string_to_exercisemethod_opt (d) = + (match d with + | "Automatic" -> (Some FIX_ExerciseMethod_Automatic) + | "Manual" -> (Some FIX_ExerciseMethod_Manual) + | _ -> None + ) +;; + +let string_to_expirationcycle_opt (d) = + (match d with + | "ExpireOnTradingSessionClose" -> (Some FIX_ExpirationCycle_ExpireOnTradingSessionClose) + | "ExpireOnTradingSessionOpen" -> (Some FIX_ExpirationCycle_ExpireOnTradingSessionOpen) + | _ -> None + ) +;; + +let string_to_financialstatus_opt (d) = + (match d with + | "Bankrupt" -> (Some FIX_FinancialStatus_Bankrupt) + | "PendingDelisting" -> (Some FIX_FinancialStatus_PendingDelisting) + | _ -> None + ) +;; + +let string_to_forexreq_opt (d) = + (match d with + | "ExecuteForexAfterSecurityTrade" -> (Some FIX_ForexReq_ExecuteForexAfterSecurityTrade) + | "DoNotExecuteForexAfterSecurityTrade" -> (Some FIX_ForexReq_DoNotExecuteForexAfterSecurityTrade) + | _ -> None + ) +;; + +let string_to_fundrenewwaiv_opt (d) = + (match d with + | "Yes" -> (Some FIX_FundRenewWaiv_Yes) + | "No" -> (Some FIX_FundRenewWaiv_No) + | _ -> None + ) +;; + +let string_to_gtbookinginst_opt (d) = + (match d with + | "BookOutAllTradesOnDayOfExecution" -> (Some FIX_GTBookingInst_BookOutAllTradesOnDayOfExecution) + | "AccumulateUntilFilledOrExpired" -> (Some FIX_GTBookingInst_AccumulateUntilFilledOrExpired) + | "AccumulateUntilVerballyNotifiedOtherwise" -> (Some FIX_GTBookingInst_AccumulateUntilVerballyNotifiedOtherwise) + | _ -> None + ) +;; + +let string_to_haltreason_opt (d) = + (match d with + | "OrderImbalance" -> (Some FIX_HaltReason_OrderImbalance) + | "EquipmentChangeover" -> (Some FIX_HaltReason_EquipmentChangeover) + | "NewsPending" -> (Some FIX_HaltReason_NewsPending) + | "NewsDissemination" -> (Some FIX_HaltReason_NewsDissemination) + | "OrderInflux" -> (Some FIX_HaltReason_OrderInflux) + | "AdditionalInformation" -> (Some FIX_HaltReason_AdditionalInformation) + | _ -> None + ) +;; + +let string_to_handlinst_opt (d) = + (match d with + | "AutomatedExecutionNoIntervention" -> (Some FIX_HandlInst_AutomatedExecutionNoIntervention) + | "AutomatedExecutionInterventionOK" -> (Some FIX_HandlInst_AutomatedExecutionInterventionOK) + | "ManualOrder" -> (Some FIX_HandlInst_ManualOrder) + | _ -> None + ) +;; + +let string_to_ioinaturalflag_opt (d) = + (match d with + | "Natural" -> (Some FIX_IOINaturalFlag_Natural) + | "NotNatural" -> (Some FIX_IOINaturalFlag_NotNatural) + | _ -> None + ) +;; + +let string_to_ioiqltyind_opt (d) = + (match d with + | "Low" -> (Some FIX_IOIQltyInd_Low) + | "Medium" -> (Some FIX_IOIQltyInd_Medium) + | "High" -> (Some FIX_IOIQltyInd_High) + | _ -> None + ) +;; + +let string_to_ioiqty_opt (d) = + (match d with + | "Small" -> (Some FIX_IOIQty_Small) + | "Medium" -> (Some FIX_IOIQty_Medium) + | "Large" -> (Some FIX_IOIQty_Large) + | _ -> None + ) +;; + +let string_to_ioiqualifier_opt (d) = + (match d with + | "AllOrNone" -> (Some FIX_IOIQualifier_AllOrNone) + | "MarketOnClose" -> (Some FIX_IOIQualifier_MarketOnClose) + | "AtTheClose" -> (Some FIX_IOIQualifier_AtTheClose) + | "VWAP" -> (Some FIX_IOIQualifier_VWAP) + | "InTouchWith" -> (Some FIX_IOIQualifier_InTouchWith) + | "Limit" -> (Some FIX_IOIQualifier_Limit) + | "MoreBehind" -> (Some FIX_IOIQualifier_MoreBehind) + | "AtTheOpen" -> (Some FIX_IOIQualifier_AtTheOpen) + | "TakingAPosition" -> (Some FIX_IOIQualifier_TakingAPosition) + | "AtTheMarket" -> (Some FIX_IOIQualifier_AtTheMarket) + | "ReadyToTrade" -> (Some FIX_IOIQualifier_ReadyToTrade) + | "PortfolioShown" -> (Some FIX_IOIQualifier_PortfolioShown) + | "ThroughTheDay" -> (Some FIX_IOIQualifier_ThroughTheDay) + | "Versus" -> (Some FIX_IOIQualifier_Versus) + | "Indication" -> (Some FIX_IOIQualifier_Indication) + | "CrossingOpportunity" -> (Some FIX_IOIQualifier_CrossingOpportunity) + | "AtTheMidpoint" -> (Some FIX_IOIQualifier_AtTheMidpoint) + | "PreOpen" -> (Some FIX_IOIQualifier_PreOpen) + | _ -> None + ) +;; + +let string_to_ioitranstype_opt (d) = + (match d with + | "New" -> (Some FIX_IOITransType_New) + | "Cancel" -> (Some FIX_IOITransType_Cancel) + | "Replace" -> (Some FIX_IOITransType_Replace) + | _ -> None + ) +;; + +let string_to_inviewofcommon_opt (d) = + (match d with + | "HaltWasDueToCommonStockBeingHalted" -> (Some FIX_InViewOfCommon_HaltWasDueToCommonStockBeingHalted) + | "HaltWasNotRelatedToAHaltOfTheCommonStock" -> (Some FIX_InViewOfCommon_HaltWasNotRelatedToAHaltOfTheCommonStock) + | _ -> None + ) +;; + +let string_to_inctaxind_opt (d) = + (match d with + | "Net" -> (Some FIX_IncTaxInd_Net) + | "Gross" -> (Some FIX_IncTaxInd_Gross) + | _ -> None + ) +;; + +let string_to_instrattribtype_opt (d) = + (match d with + | "Flat" -> (Some FIX_InstrAttribType_Flat) + | "ZeroCoupon" -> (Some FIX_InstrAttribType_ZeroCoupon) + | "InterestBearing" -> (Some FIX_InstrAttribType_InterestBearing) + | "NoPeriodicPayments" -> (Some FIX_InstrAttribType_NoPeriodicPayments) + | "VariableRate" -> (Some FIX_InstrAttribType_VariableRate) + | "LessFeeForPut" -> (Some FIX_InstrAttribType_LessFeeForPut) + | "SteppedCoupon" -> (Some FIX_InstrAttribType_SteppedCoupon) + | "CouponPeriod" -> (Some FIX_InstrAttribType_CouponPeriod) + | "When" -> (Some FIX_InstrAttribType_When) + | "OriginalIssueDiscount" -> (Some FIX_InstrAttribType_OriginalIssueDiscount) + | "Callable" -> (Some FIX_InstrAttribType_Callable) + | "EscrowedToMaturity" -> (Some FIX_InstrAttribType_EscrowedToMaturity) + | "EscrowedToRedemptionDate" -> (Some FIX_InstrAttribType_EscrowedToRedemptionDate) + | "PreRefunded" -> (Some FIX_InstrAttribType_PreRefunded) + | "InDefault" -> (Some FIX_InstrAttribType_InDefault) + | "Unrated" -> (Some FIX_InstrAttribType_Unrated) + | "Taxable" -> (Some FIX_InstrAttribType_Taxable) + | "Indexed" -> (Some FIX_InstrAttribType_Indexed) + | "SubjectToAlternativeMinimumTax" -> (Some FIX_InstrAttribType_SubjectToAlternativeMinimumTax) + | "OriginalIssueDiscountPrice" -> (Some FIX_InstrAttribType_OriginalIssueDiscountPrice) + | "CallableBelowMaturityValue" -> (Some FIX_InstrAttribType_CallableBelowMaturityValue) + | "CallableWithoutNotice" -> (Some FIX_InstrAttribType_CallableWithoutNotice) + | "Text" -> (Some FIX_InstrAttribType_Text) + | _ -> None + ) +;; + +let string_to_lastcapacity_opt (d) = + (match d with + | "Agent" -> (Some FIX_LastCapacity_Agent) + | "CrossAsAgent" -> (Some FIX_LastCapacity_CrossAsAgent) + | "CrossAsPrincipal" -> (Some FIX_LastCapacity_CrossAsPrincipal) + | "Principal" -> (Some FIX_LastCapacity_Principal) + | _ -> None + ) +;; + +let string_to_lastfragment_opt (d) = + (match d with + | "LastMessage" -> (Some FIX_LastFragment_LastMessage) + | "NotLastMessage" -> (Some FIX_LastFragment_NotLastMessage) + | _ -> None + ) +;; + +let string_to_lastliquidityind_opt (d) = + (match d with + | "AddedLiquidity" -> (Some FIX_LastLiquidityInd_AddedLiquidity) + | "RemovedLiquidity" -> (Some FIX_LastLiquidityInd_RemovedLiquidity) + | "LiquidityRoutedOut" -> (Some FIX_LastLiquidityInd_LiquidityRoutedOut) + | _ -> None + ) +;; + +let string_to_legswaptype_opt (d) = + (match d with + | "ParForPar" -> (Some FIX_LegSwapType_ParForPar) + | "ModifiedDuration" -> (Some FIX_LegSwapType_ModifiedDuration) + | "Risk" -> (Some FIX_LegSwapType_Risk) + | "Proceeds" -> (Some FIX_LegSwapType_Proceeds) + | _ -> None + ) +;; + +let string_to_legalconfirm_opt (d) = + (match d with + | "LegalConfirm" -> (Some FIX_LegalConfirm_LegalConfirm) + | "DoesNotConsituteALegalConfirm" -> (Some FIX_LegalConfirm_DoesNotConsituteALegalConfirm) + | _ -> None + ) +;; + +let string_to_liquidityindtype_opt (d) = + (match d with + | "FiveDayMovingAverage" -> (Some FIX_LiquidityIndType_FiveDayMovingAverage) + | "TwentyDayMovingAverage" -> (Some FIX_LiquidityIndType_TwentyDayMovingAverage) + | "NormalMarketSize" -> (Some FIX_LiquidityIndType_NormalMarketSize) + | "Other" -> (Some FIX_LiquidityIndType_Other) + | _ -> None + ) +;; + +let string_to_listexecinsttype_opt (d) = + (match d with + | "Immediate" -> (Some FIX_ListExecInstType_Immediate) + | "WaitForInstruction" -> (Some FIX_ListExecInstType_WaitForInstruction) + | "SellDriven" -> (Some FIX_ListExecInstType_SellDriven) + | "BuyDrivenCashTopUp" -> (Some FIX_ListExecInstType_BuyDrivenCashTopUp) + | "BuyDrivenCashWithdraw" -> (Some FIX_ListExecInstType_BuyDrivenCashWithdraw) + | _ -> None + ) +;; + +let string_to_listorderstatus_opt (d) = + (match d with + | "InBiddingProcess" -> (Some FIX_ListOrderStatus_InBiddingProcess) + | "ReceivedForExecution" -> (Some FIX_ListOrderStatus_ReceivedForExecution) + | "Executing" -> (Some FIX_ListOrderStatus_Executing) + | "Cancelling" -> (Some FIX_ListOrderStatus_Cancelling) + | "Alert" -> (Some FIX_ListOrderStatus_Alert) + | "AllDone" -> (Some FIX_ListOrderStatus_AllDone) + | "Reject" -> (Some FIX_ListOrderStatus_Reject) + | _ -> None + ) +;; + +let string_to_liststatustype_opt (d) = + (match d with + | "Ack" -> (Some FIX_ListStatusType_Ack) + | "Response" -> (Some FIX_ListStatusType_Response) + | "Timed" -> (Some FIX_ListStatusType_Timed) + | "ExecStarted" -> (Some FIX_ListStatusType_ExecStarted) + | "AllDone" -> (Some FIX_ListStatusType_AllDone) + | "Alert" -> (Some FIX_ListStatusType_Alert) + | _ -> None + ) +;; + +let string_to_locatereqd_opt (d) = + (match d with + | "Yes" -> (Some FIX_LocateReqd_Yes) + | "No" -> (Some FIX_LocateReqd_No) + | _ -> None + ) +;; + +let string_to_mdentrytype_opt (d) = + (match d with + | "Bid" -> (Some FIX_MDEntryType_Bid) + | "Offer" -> (Some FIX_MDEntryType_Offer) + | "Trade" -> (Some FIX_MDEntryType_Trade) + | "IndexValue" -> (Some FIX_MDEntryType_IndexValue) + | "OpeningPrice" -> (Some FIX_MDEntryType_OpeningPrice) + | "ClosingPrice" -> (Some FIX_MDEntryType_ClosingPrice) + | "SettlementPrice" -> (Some FIX_MDEntryType_SettlementPrice) + | "TradingSessionHighPrice" -> (Some FIX_MDEntryType_TradingSessionHighPrice) + | "TradingSessionLowPrice" -> (Some FIX_MDEntryType_TradingSessionLowPrice) + | "TradingSessionVWAPPrice" -> (Some FIX_MDEntryType_TradingSessionVWAPPrice) + | "Imbalance" -> (Some FIX_MDEntryType_Imbalance) + | "TradeVolume" -> (Some FIX_MDEntryType_TradeVolume) + | "OpenInterest" -> (Some FIX_MDEntryType_OpenInterest) + | _ -> None + ) +;; + +let string_to_mdimplicitdelete_opt (d) = + (match d with + | "Yes" -> (Some FIX_MDImplicitDelete_Yes) + | "No" -> (Some FIX_MDImplicitDelete_No) + | _ -> None + ) +;; + +let string_to_mdreqrejreason_opt (d) = + (match d with + | "UnknownSymbol" -> (Some FIX_MDReqRejReason_UnknownSymbol) + | "DuplicateMDReqID" -> (Some FIX_MDReqRejReason_DuplicateMDReqID) + | "InsufficientBandwidth" -> (Some FIX_MDReqRejReason_InsufficientBandwidth) + | "InsufficientPermissions" -> (Some FIX_MDReqRejReason_InsufficientPermissions) + | "UnsupportedSubscriptionRequestType" -> (Some FIX_MDReqRejReason_UnsupportedSubscriptionRequestType) + | "UnsupportedMarketDepth" -> (Some FIX_MDReqRejReason_UnsupportedMarketDepth) + | "UnsupportedMDUpdateType" -> (Some FIX_MDReqRejReason_UnsupportedMDUpdateType) + | "UnsupportedAggregatedBook" -> (Some FIX_MDReqRejReason_UnsupportedAggregatedBook) + | "UnsupportedMDEntryType" -> (Some FIX_MDReqRejReason_UnsupportedMDEntryType) + | "UnsupportedTradingSessionID" -> (Some FIX_MDReqRejReason_UnsupportedTradingSessionID) + | "UnsupportedScope" -> (Some FIX_MDReqRejReason_UnsupportedScope) + | "UnsupportedOpenCloseSettleFlag" -> (Some FIX_MDReqRejReason_UnsupportedOpenCloseSettleFlag) + | "UnsupportedMDImplicitDelete" -> (Some FIX_MDReqRejReason_UnsupportedMDImplicitDelete) + | _ -> None + ) +;; + +let string_to_mdupdateaction_opt (d) = + (match d with + | "New" -> (Some FIX_MDUpdateAction_New) + | "Change" -> (Some FIX_MDUpdateAction_Change) + | "Delete" -> (Some FIX_MDUpdateAction_Delete) + | _ -> None + ) +;; + +let string_to_mdupdatetype_opt (d) = + (match d with + | "FullRefresh" -> (Some FIX_MDUpdateType_FullRefresh) + | "IncrementalRefresh" -> (Some FIX_MDUpdateType_IncrementalRefresh) + | _ -> None + ) +;; + +let string_to_masscancelrejectreason_opt (d) = + (match d with + | "MassCancelNotSupported" -> (Some FIX_MassCancelRejectReason_MassCancelNotSupported) + | "InvalidOrUnknownSecurity" -> (Some FIX_MassCancelRejectReason_InvalidOrUnknownSecurity) + | "InvalidOrUnkownUnderlyingSecurity" -> (Some FIX_MassCancelRejectReason_InvalidOrUnkownUnderlyingSecurity) + | "InvalidOrUnknownProduct" -> (Some FIX_MassCancelRejectReason_InvalidOrUnknownProduct) + | "InvalidOrUnknownCFICode" -> (Some FIX_MassCancelRejectReason_InvalidOrUnknownCFICode) + | "InvalidOrUnknownSecurityType" -> (Some FIX_MassCancelRejectReason_InvalidOrUnknownSecurityType) + | "InvalidOrUnknownTradingSession" -> (Some FIX_MassCancelRejectReason_InvalidOrUnknownTradingSession) + | "Other" -> (Some FIX_MassCancelRejectReason_Other) + | _ -> None + ) +;; + +let string_to_masscancelrequesttype_opt (d) = + (match d with + | "CancelOrdersForASecurity" -> (Some FIX_MassCancelRequestType_CancelOrdersForASecurity) + | "CancelOrdersForAnUnderlyingSecurity" -> (Some FIX_MassCancelRequestType_CancelOrdersForAnUnderlyingSecurity) + | "CancelOrdersForAProduct" -> (Some FIX_MassCancelRequestType_CancelOrdersForAProduct) + | "CancelOrdersForACFICode" -> (Some FIX_MassCancelRequestType_CancelOrdersForACFICode) + | "CancelOrdersForASecurityType" -> (Some FIX_MassCancelRequestType_CancelOrdersForASecurityType) + | "CancelOrdersForATradingSession" -> (Some FIX_MassCancelRequestType_CancelOrdersForATradingSession) + | "CancelAllOrders" -> (Some FIX_MassCancelRequestType_CancelAllOrders) + | _ -> None + ) +;; + +let string_to_masscancelresponse_opt (d) = + (match d with + | "CancelRequestRejected" -> (Some FIX_MassCancelResponse_CancelRequestRejected) + | "CancelOrdersForASecurity" -> (Some FIX_MassCancelResponse_CancelOrdersForASecurity) + | "CancelOrdersForAnUnderlyingSecurity" -> (Some FIX_MassCancelResponse_CancelOrdersForAnUnderlyingSecurity) + | "CancelOrdersForAProduct" -> (Some FIX_MassCancelResponse_CancelOrdersForAProduct) + | "CancelOrdersForACFICode" -> (Some FIX_MassCancelResponse_CancelOrdersForACFICode) + | "CancelOrdersForASecurityType" -> (Some FIX_MassCancelResponse_CancelOrdersForASecurityType) + | "CancelOrdersForATradingSession" -> (Some FIX_MassCancelResponse_CancelOrdersForATradingSession) + | "CancelAllOrders" -> (Some FIX_MassCancelResponse_CancelAllOrders) + | _ -> None + ) +;; + +let string_to_massstatusreqtype_opt (d) = + (match d with + | "StatusForOrdersForASecurity" -> (Some FIX_MassStatusReqType_StatusForOrdersForASecurity) + | "StatusForOrdersForAnUnderlyingSecurity" -> (Some FIX_MassStatusReqType_StatusForOrdersForAnUnderlyingSecurity) + | "StatusForOrdersForAProduct" -> (Some FIX_MassStatusReqType_StatusForOrdersForAProduct) + | "StatusForOrdersForACFICode" -> (Some FIX_MassStatusReqType_StatusForOrdersForACFICode) + | "StatusForOrdersForASecurityType" -> (Some FIX_MassStatusReqType_StatusForOrdersForASecurityType) + | "StatusForOrdersForATradingSession" -> (Some FIX_MassStatusReqType_StatusForOrdersForATradingSession) + | "StatusForAllOrders" -> (Some FIX_MassStatusReqType_StatusForAllOrders) + | "StatusForOrdersForAPartyID" -> (Some FIX_MassStatusReqType_StatusForOrdersForAPartyID) + | _ -> None + ) +;; + +let string_to_matchstatus_opt (d) = + (match d with + | "Compared" -> (Some FIX_MatchStatus_Compared) + | "Uncompared" -> (Some FIX_MatchStatus_Uncompared) + | "AdvisoryOrAlert" -> (Some FIX_MatchStatus_AdvisoryOrAlert) + | _ -> None + ) +;; + +let string_to_matchtype_opt (d) = + (match d with + | "ExactMatchPlus4BadgesExecTime" -> (Some FIX_MatchType_ExactMatchPlus4BadgesExecTime) + | "ExactMatchPlus4Badges" -> (Some FIX_MatchType_ExactMatchPlus4Badges) + | "ExactMatchPlus2BadgesExecTime" -> (Some FIX_MatchType_ExactMatchPlus2BadgesExecTime) + | "ExactMatchPlus2Badges" -> (Some FIX_MatchType_ExactMatchPlus2Badges) + | "ExactMatchPlusExecTime" -> (Some FIX_MatchType_ExactMatchPlusExecTime) + | "StampedAdvisoriesOrSpecialistAccepts" -> (Some FIX_MatchType_StampedAdvisoriesOrSpecialistAccepts) + | "A1ExactMatchSummarizedQuantity" -> (Some FIX_MatchType_A1ExactMatchSummarizedQuantity) + | "A2ExactMatchSummarizedQuantity" -> (Some FIX_MatchType_A2ExactMatchSummarizedQuantity) + | "A3ExactMatchSummarizedQuantity" -> (Some FIX_MatchType_A3ExactMatchSummarizedQuantity) + | "A4ExactMatchSummarizedQuantity" -> (Some FIX_MatchType_A4ExactMatchSummarizedQuantity) + | "A5ExactMatchSummarizedQuantity" -> (Some FIX_MatchType_A5ExactMatchSummarizedQuantity) + | "ExactMatchMinusBadgesTimes" -> (Some FIX_MatchType_ExactMatchMinusBadgesTimes) + | "SummarizedMatchMinusBadgesTimes" -> (Some FIX_MatchType_SummarizedMatchMinusBadgesTimes) + | "OCSLockedIn" -> (Some FIX_MatchType_OCSLockedIn) + | "ACTAcceptedTrade" -> (Some FIX_MatchType_ACTAcceptedTrade) + | "ACTDefaultTrade" -> (Some FIX_MatchType_ACTDefaultTrade) + | "ACTDefaultAfterM2" -> (Some FIX_MatchType_ACTDefaultAfterM2) + | "ACTM6Match" -> (Some FIX_MatchType_ACTM6Match) + | _ -> None + ) +;; + +let string_to_messageencoding_opt (d) = + (match d with + | "ISO2022JP" -> (Some FIX_MessageEncoding_ISO2022JP) + | "EUCJP" -> (Some FIX_MessageEncoding_EUCJP) + | "ShiftJIS" -> (Some FIX_MessageEncoding_ShiftJIS) + | "UTF8" -> (Some FIX_MessageEncoding_UTF8) + | _ -> None + ) +;; + +let string_to_miscfeebasis_opt (d) = + (match d with + | "Absolute" -> (Some FIX_MiscFeeBasis_Absolute) + | "PerUnit" -> (Some FIX_MiscFeeBasis_PerUnit) + | "Percentage" -> (Some FIX_MiscFeeBasis_Percentage) + | _ -> None + ) +;; + +let string_to_miscfeetype_opt (d) = + (match d with + | "Regulatory" -> (Some FIX_MiscFeeType_Regulatory) + | "Tax" -> (Some FIX_MiscFeeType_Tax) + | "LocalCommission" -> (Some FIX_MiscFeeType_LocalCommission) + | "ExchangeFees" -> (Some FIX_MiscFeeType_ExchangeFees) + | "Stamp" -> (Some FIX_MiscFeeType_Stamp) + | "Levy" -> (Some FIX_MiscFeeType_Levy) + | "Other" -> (Some FIX_MiscFeeType_Other) + | "Markup" -> (Some FIX_MiscFeeType_Markup) + | "ConsumptionTax" -> (Some FIX_MiscFeeType_ConsumptionTax) + | "PerTransaction" -> (Some FIX_MiscFeeType_PerTransaction) + | "Conversion" -> (Some FIX_MiscFeeType_Conversion) + | "Agent" -> (Some FIX_MiscFeeType_Agent) + | _ -> None + ) +;; + +let string_to_moneylaunderingstatus_opt (d) = + (match d with + | "Passed" -> (Some FIX_MoneyLaunderingStatus_Passed) + | "NotChecked" -> (Some FIX_MoneyLaunderingStatus_NotChecked) + | "ExemptBelowLimit" -> (Some FIX_MoneyLaunderingStatus_ExemptBelowLimit) + | "ExemptMoneyType" -> (Some FIX_MoneyLaunderingStatus_ExemptMoneyType) + | "ExemptAuthorised" -> (Some FIX_MoneyLaunderingStatus_ExemptAuthorised) + | _ -> None + ) +;; + +let string_to_msgdirection_opt (d) = + (match d with + | "Send" -> (Some FIX_MsgDirection_Send) + | "Receive" -> (Some FIX_MsgDirection_Receive) + | _ -> None + ) +;; + +let string_to_multilegreportingtype_opt (d) = + (match d with + | "SingleSecurity" -> (Some FIX_MultiLegReportingType_SingleSecurity) + | "IndividualLegOfAMultiLegSecurity" -> (Some FIX_MultiLegReportingType_IndividualLegOfAMultiLegSecurity) + | "MultiLegSecurity" -> (Some FIX_MultiLegReportingType_MultiLegSecurity) + | _ -> None + ) +;; + +let string_to_multilegrpttypereq_opt (d) = + (match d with + | "ReportByMulitlegSecurityOnly" -> (Some FIX_MultiLegRptTypeReq_ReportByMulitlegSecurityOnly) + | "ReportByMultilegSecurityAndInstrumentLegs" -> (Some FIX_MultiLegRptTypeReq_ReportByMultilegSecurityAndInstrumentLegs) + | "ReportByInstrumentLegsOnly" -> (Some FIX_MultiLegRptTypeReq_ReportByInstrumentLegsOnly) + | _ -> None + ) +;; + +let string_to_netgrossind_opt (d) = + (match d with + | "Net" -> (Some FIX_NetGrossInd_Net) + | "Gross" -> (Some FIX_NetGrossInd_Gross) + | _ -> None + ) +;; + +let string_to_networkrequesttype_opt (d) = + (match d with + | "Snapshot" -> (Some FIX_NetworkRequestType_Snapshot) + | "Subscribe" -> (Some FIX_NetworkRequestType_Subscribe) + | "StopSubscribing" -> (Some FIX_NetworkRequestType_StopSubscribing) + | "LevelOfDetail" -> (Some FIX_NetworkRequestType_LevelOfDetail) + | _ -> None + ) +;; + +let string_to_networkstatusresponsetype_opt (d) = + (match d with + | "Full" -> (Some FIX_NetworkStatusResponseType_Full) + | "IncrementalUpdate" -> (Some FIX_NetworkStatusResponseType_IncrementalUpdate) + | _ -> None + ) +;; + +let string_to_notifybrokerofcredit_opt (d) = + (match d with + | "DetailsShouldBeCommunicated" -> (Some FIX_NotifyBrokerOfCredit_DetailsShouldBeCommunicated) + | "DetailsShouldNotBeCommunicated" -> (Some FIX_NotifyBrokerOfCredit_DetailsShouldNotBeCommunicated) + | _ -> None + ) +;; + +let string_to_oddlot_opt (d) = + (match d with + | "TreatAsOddLot" -> (Some FIX_OddLot_TreatAsOddLot) + | "TreatAsRoundLot" -> (Some FIX_OddLot_TreatAsRoundLot) + | _ -> None + ) +;; + +let string_to_openclosesettlflag_opt (d) = + (match d with + | "DailyOpen" -> (Some FIX_OpenCloseSettlFlag_DailyOpen) + | "SessionOpen" -> (Some FIX_OpenCloseSettlFlag_SessionOpen) + | "DeliverySettlementEntry" -> (Some FIX_OpenCloseSettlFlag_DeliverySettlementEntry) + | "ExpectedEntry" -> (Some FIX_OpenCloseSettlFlag_ExpectedEntry) + | "EntryFromPreviousBusinessDay" -> (Some FIX_OpenCloseSettlFlag_EntryFromPreviousBusinessDay) + | "TheoreticalPriceValue" -> (Some FIX_OpenCloseSettlFlag_TheoreticalPriceValue) + | _ -> None + ) +;; + +let string_to_ordrejreason_opt (d) = + (match d with + | "BrokerCredit" -> (Some FIX_OrdRejReason_BrokerCredit) + | "UnknownSymbol" -> (Some FIX_OrdRejReason_UnknownSymbol) + | "ExchangeClosed" -> (Some FIX_OrdRejReason_ExchangeClosed) + | "OrderExceedsLimit" -> (Some FIX_OrdRejReason_OrderExceedsLimit) + | "TooLateToEnter" -> (Some FIX_OrdRejReason_TooLateToEnter) + | "UnknownOrder" -> (Some FIX_OrdRejReason_UnknownOrder) + | "DuplicateOrder" -> (Some FIX_OrdRejReason_DuplicateOrder) + | "DuplicateOfAVerballyCommunicatedOrder" -> (Some FIX_OrdRejReason_DuplicateOfAVerballyCommunicatedOrder) + | "StaleOrder" -> (Some FIX_OrdRejReason_StaleOrder) + | "TradeAlongRequired" -> (Some FIX_OrdRejReason_TradeAlongRequired) + | "InvalidInvestorID" -> (Some FIX_OrdRejReason_InvalidInvestorID) + | "UnsupportedOrderCharacteristic" -> (Some FIX_OrdRejReason_UnsupportedOrderCharacteristic) + | "IncorrectQuantity" -> (Some FIX_OrdRejReason_IncorrectQuantity) + | "IncorrectAllocatedQuantity" -> (Some FIX_OrdRejReason_IncorrectAllocatedQuantity) + | "UnknownAccount" -> (Some FIX_OrdRejReason_UnknownAccount) + | "Other" -> (Some FIX_OrdRejReason_Other) + | _ -> None + ) +;; + +let string_to_ordstatus_opt (d) = + (match d with + | "New" -> (Some FIX_OrdStatus_New) + | "PartiallyFilled" -> (Some FIX_OrdStatus_PartiallyFilled) + | "Filled" -> (Some FIX_OrdStatus_Filled) + | "DoneForDay" -> (Some FIX_OrdStatus_DoneForDay) + | "Canceled" -> (Some FIX_OrdStatus_Canceled) + | "PendingCancel" -> (Some FIX_OrdStatus_PendingCancel) + | "Stopped" -> (Some FIX_OrdStatus_Stopped) + | "Rejected" -> (Some FIX_OrdStatus_Rejected) + | "Suspended" -> (Some FIX_OrdStatus_Suspended) + | "PendingNew" -> (Some FIX_OrdStatus_PendingNew) + | "Calculated" -> (Some FIX_OrdStatus_Calculated) + | "Expired" -> (Some FIX_OrdStatus_Expired) + | "AcceptedForBidding" -> (Some FIX_OrdStatus_AcceptedForBidding) + | "PendingReplace" -> (Some FIX_OrdStatus_PendingReplace) + | "Replaced" -> (Some FIX_OrdStatus_Replaced) + | _ -> None + ) +;; + +let string_to_ordtype_opt (d) = + (match d with + | "Market" -> (Some FIX_OrdType_Market) + | "Limit" -> (Some FIX_OrdType_Limit) + | "Stop" -> (Some FIX_OrdType_Stop) + | "StopLimit" -> (Some FIX_OrdType_StopLimit) + | "WithOrWithout" -> (Some FIX_OrdType_WithOrWithout) + | "LimitOrBetter" -> (Some FIX_OrdType_LimitOrBetter) + | "LimitWithOrWithout" -> (Some FIX_OrdType_LimitWithOrWithout) + | "OnBasis" -> (Some FIX_OrdType_OnBasis) + | "PreviouslyQuoted" -> (Some FIX_OrdType_PreviouslyQuoted) + | "PreviouslyIndicated" -> (Some FIX_OrdType_PreviouslyIndicated) + | "ForexSwap" -> (Some FIX_OrdType_ForexSwap) + | "Funari" -> (Some FIX_OrdType_Funari) + | "MarketIfTouched" -> (Some FIX_OrdType_MarketIfTouched) + | "MarketWithLeftOverAsLimit" -> (Some FIX_OrdType_MarketWithLeftOverAsLimit) + | "PreviousFundValuationPoint" -> (Some FIX_OrdType_PreviousFundValuationPoint) + | "NextFundValuationPoint" -> (Some FIX_OrdType_NextFundValuationPoint) + | "Pegged" -> (Some FIX_OrdType_Pegged) + | _ -> None + ) +;; + +let string_to_ordercapacity_opt (d) = + (match d with + | "Agency" -> (Some FIX_OrderCapacity_Agency) + | "Proprietary" -> (Some FIX_OrderCapacity_Proprietary) + | "Individual" -> (Some FIX_OrderCapacity_Individual) + | "Principal" -> (Some FIX_OrderCapacity_Principal) + | "RisklessPrincipal" -> (Some FIX_OrderCapacity_RisklessPrincipal) + | "AgentForOtherMember" -> (Some FIX_OrderCapacity_AgentForOtherMember) + | _ -> None + ) +;; + +let string_to_orderrestrictions_opt (d) = + (match d with + | "ProgramTrade" -> (Some FIX_OrderRestrictions_ProgramTrade) + | "IndexArbitrage" -> (Some FIX_OrderRestrictions_IndexArbitrage) + | "NonIndexArbitrage" -> (Some FIX_OrderRestrictions_NonIndexArbitrage) + | "CompetingMarketMaker" -> (Some FIX_OrderRestrictions_CompetingMarketMaker) + | "ActingAsMarketMakerOrSpecialistInSecurity" -> (Some FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInSecurity) + | "ActingAsMarketMakerOrSpecialistInUnderlying" -> (Some FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInUnderlying) + | "ForeignEntity" -> (Some FIX_OrderRestrictions_ForeignEntity) + | "ExternalMarketParticipant" -> (Some FIX_OrderRestrictions_ExternalMarketParticipant) + | "ExternalInterConnectedMarketLinkage" -> (Some FIX_OrderRestrictions_ExternalInterConnectedMarketLinkage) + | "RisklessArbitrage" -> (Some FIX_OrderRestrictions_RisklessArbitrage) + | _ -> None + ) +;; + +let string_to_ownertype_opt (d) = + (match d with + | "IndividualInvestor" -> (Some FIX_OwnerType_IndividualInvestor) + | "PublicCompany" -> (Some FIX_OwnerType_PublicCompany) + | "PrivateCompany" -> (Some FIX_OwnerType_PrivateCompany) + | "IndividualTrustee" -> (Some FIX_OwnerType_IndividualTrustee) + | "CompanyTrustee" -> (Some FIX_OwnerType_CompanyTrustee) + | "PensionPlan" -> (Some FIX_OwnerType_PensionPlan) + | "CustodianUnderGiftsToMinorsAct" -> (Some FIX_OwnerType_CustodianUnderGiftsToMinorsAct) + | "Trusts" -> (Some FIX_OwnerType_Trusts) + | "Fiduciaries" -> (Some FIX_OwnerType_Fiduciaries) + | "NetworkingSubAccount" -> (Some FIX_OwnerType_NetworkingSubAccount) + | "NonProfitOrganization" -> (Some FIX_OwnerType_NonProfitOrganization) + | "CorporateBody" -> (Some FIX_OwnerType_CorporateBody) + | "Nominee" -> (Some FIX_OwnerType_Nominee) + | _ -> None + ) +;; + +let string_to_ownershiptype_opt (d) = + (match d with + | "JointInvestors" -> (Some FIX_OwnershipType_JointInvestors) + | "TenantsInCommon" -> (Some FIX_OwnershipType_TenantsInCommon) + | "JointTrustees" -> (Some FIX_OwnershipType_JointTrustees) + | _ -> None + ) +;; + +let string_to_partyidsource_opt (d) = + (match d with + | "BIC" -> (Some FIX_PartyIDSource_BIC) + | "GeneralIdentifier" -> (Some FIX_PartyIDSource_GeneralIdentifier) + | "Proprietary" -> (Some FIX_PartyIDSource_Proprietary) + | "ISOCountryCode" -> (Some FIX_PartyIDSource_ISOCountryCode) + | "SettlementEntityLocation" -> (Some FIX_PartyIDSource_SettlementEntityLocation) + | "MIC" -> (Some FIX_PartyIDSource_MIC) + | "CSDParticipant" -> (Some FIX_PartyIDSource_CSDParticipant) + | "KoreanInvestorID" -> (Some FIX_PartyIDSource_KoreanInvestorID) + | "TaiwaneseForeignInvestorID" -> (Some FIX_PartyIDSource_TaiwaneseForeignInvestorID) + | "TaiwaneseTradingAcct" -> (Some FIX_PartyIDSource_TaiwaneseTradingAcct) + | "MalaysianCentralDepository" -> (Some FIX_PartyIDSource_MalaysianCentralDepository) + | "ChineseInvestorID" -> (Some FIX_PartyIDSource_ChineseInvestorID) + | "UKNationalInsuranceOrPensionNumber" -> (Some FIX_PartyIDSource_UKNationalInsuranceOrPensionNumber) + | "USSocialSecurityNumber" -> (Some FIX_PartyIDSource_USSocialSecurityNumber) + | "USEmployerOrTaxIDNumber" -> (Some FIX_PartyIDSource_USEmployerOrTaxIDNumber) + | "AustralianBusinessNumber" -> (Some FIX_PartyIDSource_AustralianBusinessNumber) + | "AustralianTaxFileNumber" -> (Some FIX_PartyIDSource_AustralianTaxFileNumber) + | "ISITCAcronym" -> (Some FIX_PartyIDSource_ISITCAcronym) + | _ -> None + ) +;; + +let string_to_partyrole_opt (d) = + (match d with + | "ExecutingFirm" -> (Some FIX_PartyRole_ExecutingFirm) + | "BrokerOfCredit" -> (Some FIX_PartyRole_BrokerOfCredit) + | "ClientID" -> (Some FIX_PartyRole_ClientID) + | "ClearingFirm" -> (Some FIX_PartyRole_ClearingFirm) + | "InvestorID" -> (Some FIX_PartyRole_InvestorID) + | "IntroducingFirm" -> (Some FIX_PartyRole_IntroducingFirm) + | "EnteringFirm" -> (Some FIX_PartyRole_EnteringFirm) + | "Locate" -> (Some FIX_PartyRole_Locate) + | "FundManagerClientID" -> (Some FIX_PartyRole_FundManagerClientID) + | "SettlementLocation" -> (Some FIX_PartyRole_SettlementLocation) + | "OrderOriginationTrader" -> (Some FIX_PartyRole_OrderOriginationTrader) + | "ExecutingTrader" -> (Some FIX_PartyRole_ExecutingTrader) + | "OrderOriginationFirm" -> (Some FIX_PartyRole_OrderOriginationFirm) + | "GiveupClearingFirm" -> (Some FIX_PartyRole_GiveupClearingFirm) + | "CorrespondantClearingFirm" -> (Some FIX_PartyRole_CorrespondantClearingFirm) + | "ExecutingSystem" -> (Some FIX_PartyRole_ExecutingSystem) + | "ContraFirm" -> (Some FIX_PartyRole_ContraFirm) + | "ContraClearingFirm" -> (Some FIX_PartyRole_ContraClearingFirm) + | "SponsoringFirm" -> (Some FIX_PartyRole_SponsoringFirm) + | "UnderlyingContraFirm" -> (Some FIX_PartyRole_UnderlyingContraFirm) + | "ClearingOrganization" -> (Some FIX_PartyRole_ClearingOrganization) + | "Exchange" -> (Some FIX_PartyRole_Exchange) + | "CustomerAccount" -> (Some FIX_PartyRole_CustomerAccount) + | "CorrespondentClearingOrganization" -> (Some FIX_PartyRole_CorrespondentClearingOrganization) + | "CorrespondentBroker" -> (Some FIX_PartyRole_CorrespondentBroker) + | "Buyer" -> (Some FIX_PartyRole_Buyer) + | "Custodian" -> (Some FIX_PartyRole_Custodian) + | "Intermediary" -> (Some FIX_PartyRole_Intermediary) + | "Agent" -> (Some FIX_PartyRole_Agent) + | "SubCustodian" -> (Some FIX_PartyRole_SubCustodian) + | "Beneficiary" -> (Some FIX_PartyRole_Beneficiary) + | "InterestedParty" -> (Some FIX_PartyRole_InterestedParty) + | "RegulatoryBody" -> (Some FIX_PartyRole_RegulatoryBody) + | "LiquidityProvider" -> (Some FIX_PartyRole_LiquidityProvider) + | "EnteringTrader" -> (Some FIX_PartyRole_EnteringTrader) + | "ContraTrader" -> (Some FIX_PartyRole_ContraTrader) + | "PositionAccount" -> (Some FIX_PartyRole_PositionAccount) + | _ -> None + ) +;; + +let string_to_partysubidtype_opt (d) = + (match d with + | "Firm" -> (Some FIX_PartySubIDType_Firm) + | "Person" -> (Some FIX_PartySubIDType_Person) + | "System" -> (Some FIX_PartySubIDType_System) + | "Application" -> (Some FIX_PartySubIDType_Application) + | "FullLegalNameOfFirm" -> (Some FIX_PartySubIDType_FullLegalNameOfFirm) + | "PostalAddress" -> (Some FIX_PartySubIDType_PostalAddress) + | "PhoneNumber" -> (Some FIX_PartySubIDType_PhoneNumber) + | "EmailAddress" -> (Some FIX_PartySubIDType_EmailAddress) + | "ContactName" -> (Some FIX_PartySubIDType_ContactName) + | "SecuritiesAccountNumber" -> (Some FIX_PartySubIDType_SecuritiesAccountNumber) + | "RegistrationNumber" -> (Some FIX_PartySubIDType_RegistrationNumber) + | "RegisteredAddressForConfirmation" -> (Some FIX_PartySubIDType_RegisteredAddressForConfirmation) + | "RegulatoryStatus" -> (Some FIX_PartySubIDType_RegulatoryStatus) + | "RegistrationName" -> (Some FIX_PartySubIDType_RegistrationName) + | "CashAccountNumber" -> (Some FIX_PartySubIDType_CashAccountNumber) + | "BIC" -> (Some FIX_PartySubIDType_BIC) + | "CSDParticipantMemberCode" -> (Some FIX_PartySubIDType_CSDParticipantMemberCode) + | "RegisteredAddress" -> (Some FIX_PartySubIDType_RegisteredAddress) + | "FundAccountName" -> (Some FIX_PartySubIDType_FundAccountName) + | "TelexNumber" -> (Some FIX_PartySubIDType_TelexNumber) + | "FaxNumber" -> (Some FIX_PartySubIDType_FaxNumber) + | "SecuritiesAccountName" -> (Some FIX_PartySubIDType_SecuritiesAccountName) + | "CashAccountName" -> (Some FIX_PartySubIDType_CashAccountName) + | "Department" -> (Some FIX_PartySubIDType_Department) + | "LocationDesk" -> (Some FIX_PartySubIDType_LocationDesk) + | "PositionAccountType" -> (Some FIX_PartySubIDType_PositionAccountType) + | _ -> None + ) +;; + +let string_to_paymentmethod_opt (d) = + (match d with + | "CREST" -> (Some FIX_PaymentMethod_CREST) + | "NSCC" -> (Some FIX_PaymentMethod_NSCC) + | "Euroclear" -> (Some FIX_PaymentMethod_Euroclear) + | "Clearstream" -> (Some FIX_PaymentMethod_Clearstream) + | "Cheque" -> (Some FIX_PaymentMethod_Cheque) + | "TelegraphicTransfer" -> (Some FIX_PaymentMethod_TelegraphicTransfer) + | "FedWire" -> (Some FIX_PaymentMethod_FedWire) + | "DebitCard" -> (Some FIX_PaymentMethod_DebitCard) + | "DirectDebit" -> (Some FIX_PaymentMethod_DirectDebit) + | "DirectCredit" -> (Some FIX_PaymentMethod_DirectCredit) + | "CreditCard" -> (Some FIX_PaymentMethod_CreditCard) + | "ACHDebit" -> (Some FIX_PaymentMethod_ACHDebit) + | "ACHCredit" -> (Some FIX_PaymentMethod_ACHCredit) + | "BPAY" -> (Some FIX_PaymentMethod_BPAY) + | "HighValueClearingSystem" -> (Some FIX_PaymentMethod_HighValueClearingSystem) + | _ -> None + ) +;; + +let string_to_peglimittype_opt (d) = + (match d with + | "OrBetter" -> (Some FIX_PegLimitType_OrBetter) + | "Strict" -> (Some FIX_PegLimitType_Strict) + | "OrWorse" -> (Some FIX_PegLimitType_OrWorse) + | _ -> None + ) +;; + +let string_to_pegmovetype_opt (d) = + (match d with + | "Floating" -> (Some FIX_PegMoveType_Floating) + | "Fixed" -> (Some FIX_PegMoveType_Fixed) + | _ -> None + ) +;; + +let string_to_pegoffsettype_opt (d) = + (match d with + | "Price" -> (Some FIX_PegOffsetType_Price) + | "BasisPoints" -> (Some FIX_PegOffsetType_BasisPoints) + | "Ticks" -> (Some FIX_PegOffsetType_Ticks) + | "PriceTier" -> (Some FIX_PegOffsetType_PriceTier) + | _ -> None + ) +;; + +let string_to_pegrounddirection_opt (d) = + (match d with + | "MoreAggressive" -> (Some FIX_PegRoundDirection_MoreAggressive) + | "MorePassive" -> (Some FIX_PegRoundDirection_MorePassive) + | _ -> None + ) +;; + +let string_to_pegscope_opt (d) = + (match d with + | "Local" -> (Some FIX_PegScope_Local) + | "National" -> (Some FIX_PegScope_National) + | "Global" -> (Some FIX_PegScope_Global) + | "NationalExcludingLocal" -> (Some FIX_PegScope_NationalExcludingLocal) + | _ -> None + ) +;; + +let string_to_posamttype_opt (d) = + (match d with + | "FinalMarkToMarketAmount" -> (Some FIX_PosAmtType_FinalMarkToMarketAmount) + | "IncrementalMarkToMarketAmount" -> (Some FIX_PosAmtType_IncrementalMarkToMarketAmount) + | "TradeVariationAmount" -> (Some FIX_PosAmtType_TradeVariationAmount) + | "StartOfDayMarkToMarketAmount" -> (Some FIX_PosAmtType_StartOfDayMarkToMarketAmount) + | "PremiumAmount" -> (Some FIX_PosAmtType_PremiumAmount) + | "CashResidualAmount" -> (Some FIX_PosAmtType_CashResidualAmount) + | "CashAmount" -> (Some FIX_PosAmtType_CashAmount) + | "ValueAdjustedAmount" -> (Some FIX_PosAmtType_ValueAdjustedAmount) + | _ -> None + ) +;; + +let string_to_posmaintaction_opt (d) = + (match d with + | "New" -> (Some FIX_PosMaintAction_New) + | "Replace" -> (Some FIX_PosMaintAction_Replace) + | "Cancel" -> (Some FIX_PosMaintAction_Cancel) + | _ -> None + ) +;; + +let string_to_posmaintresult_opt (d) = + (match d with + | "SuccessfulCompletion" -> (Some FIX_PosMaintResult_SuccessfulCompletion) + | "Rejected" -> (Some FIX_PosMaintResult_Rejected) + | "Other" -> (Some FIX_PosMaintResult_Other) + | _ -> None + ) +;; + +let string_to_posmaintstatus_opt (d) = + (match d with + | "Accepted" -> (Some FIX_PosMaintStatus_Accepted) + | "AcceptedWithWarnings" -> (Some FIX_PosMaintStatus_AcceptedWithWarnings) + | "Rejected" -> (Some FIX_PosMaintStatus_Rejected) + | "Completed" -> (Some FIX_PosMaintStatus_Completed) + | "CompletedWithWarnings" -> (Some FIX_PosMaintStatus_CompletedWithWarnings) + | _ -> None + ) +;; + +let string_to_posqtystatus_opt (d) = + (match d with + | "Submitted" -> (Some FIX_PosQtyStatus_Submitted) + | "Accepted" -> (Some FIX_PosQtyStatus_Accepted) + | "Rejected" -> (Some FIX_PosQtyStatus_Rejected) + | _ -> None + ) +;; + +let string_to_posreqresult_opt (d) = + (match d with + | "ValidRequest" -> (Some FIX_PosReqResult_ValidRequest) + | "InvalidOrUnsupportedRequest" -> (Some FIX_PosReqResult_InvalidOrUnsupportedRequest) + | "NoPositionsFoundThatMatchCriteria" -> (Some FIX_PosReqResult_NoPositionsFoundThatMatchCriteria) + | "NotAuthorizedToRequestPositions" -> (Some FIX_PosReqResult_NotAuthorizedToRequestPositions) + | "RequestForPositionNotSupported" -> (Some FIX_PosReqResult_RequestForPositionNotSupported) + | "Other" -> (Some FIX_PosReqResult_Other) + | _ -> None + ) +;; + +let string_to_posreqstatus_opt (d) = + (match d with + | "Completed" -> (Some FIX_PosReqStatus_Completed) + | "CompletedWithWarnings" -> (Some FIX_PosReqStatus_CompletedWithWarnings) + | "Rejected" -> (Some FIX_PosReqStatus_Rejected) + | _ -> None + ) +;; + +let string_to_posreqtype_opt (d) = + (match d with + | "Positions" -> (Some FIX_PosReqType_Positions) + | "Trades" -> (Some FIX_PosReqType_Trades) + | "Exercises" -> (Some FIX_PosReqType_Exercises) + | "Assignments" -> (Some FIX_PosReqType_Assignments) + | _ -> None + ) +;; + +let string_to_postranstype_opt (d) = + (match d with + | "Exercise" -> (Some FIX_PosTransType_Exercise) + | "DoNotExercise" -> (Some FIX_PosTransType_DoNotExercise) + | "PositionAdjustment" -> (Some FIX_PosTransType_PositionAdjustment) + | "PositionChangeSubmission" -> (Some FIX_PosTransType_PositionChangeSubmission) + | "Pledge" -> (Some FIX_PosTransType_Pledge) + | _ -> None + ) +;; + +let string_to_postype_opt (d) = + (match d with + | "TransactionQuantity" -> (Some FIX_PosType_TransactionQuantity) + | "IntraSpreadQty" -> (Some FIX_PosType_IntraSpreadQty) + | "InterSpreadQty" -> (Some FIX_PosType_InterSpreadQty) + | "EndOfDayQty" -> (Some FIX_PosType_EndOfDayQty) + | "StartOfDayQty" -> (Some FIX_PosType_StartOfDayQty) + | "OptionExerciseQty" -> (Some FIX_PosType_OptionExerciseQty) + | "OptionAssignment" -> (Some FIX_PosType_OptionAssignment) + | "TransactionFromExercise" -> (Some FIX_PosType_TransactionFromExercise) + | "TransactionFromAssignment" -> (Some FIX_PosType_TransactionFromAssignment) + | "PitTradeQty" -> (Some FIX_PosType_PitTradeQty) + | "TransferTradeQty" -> (Some FIX_PosType_TransferTradeQty) + | "ElectronicTradeQty" -> (Some FIX_PosType_ElectronicTradeQty) + | "AllocationTradeQty" -> (Some FIX_PosType_AllocationTradeQty) + | "AdjustmentQty" -> (Some FIX_PosType_AdjustmentQty) + | "AsOfTradeQty" -> (Some FIX_PosType_AsOfTradeQty) + | "DeliveryQty" -> (Some FIX_PosType_DeliveryQty) + | "TotalTransactionQty" -> (Some FIX_PosType_TotalTransactionQty) + | "CrossMarginQty" -> (Some FIX_PosType_CrossMarginQty) + | "IntegralSplit" -> (Some FIX_PosType_IntegralSplit) + | _ -> None + ) +;; + +let string_to_positioneffect_opt (d) = + (match d with + | "Open" -> (Some FIX_PositionEffect_Open) + | "Close" -> (Some FIX_PositionEffect_Close) + | "Rolled" -> (Some FIX_PositionEffect_Rolled) + | "FIFO" -> (Some FIX_PositionEffect_FIFO) + | _ -> None + ) +;; + +let string_to_possdupflag_opt (d) = + (match d with + | "PossibleDuplicate" -> (Some FIX_PossDupFlag_PossibleDuplicate) + | "OriginalTransmission" -> (Some FIX_PossDupFlag_OriginalTransmission) + | _ -> None + ) +;; + +let string_to_possresend_opt (d) = + (match d with + | "PossibleResend" -> (Some FIX_PossResend_PossibleResend) + | "OriginalTransmission" -> (Some FIX_PossResend_OriginalTransmission) + | _ -> None + ) +;; + +let string_to_preallocmethod_opt (d) = + (match d with + | "ProRata" -> (Some FIX_PreallocMethod_ProRata) + | "DoNotProRata" -> (Some FIX_PreallocMethod_DoNotProRata) + | _ -> None + ) +;; + +let string_to_previouslyreported_opt (d) = + (match d with + | "PerviouslyReportedToCounterparty" -> (Some FIX_PreviouslyReported_PerviouslyReportedToCounterparty) + | "NotReportedToCounterparty" -> (Some FIX_PreviouslyReported_NotReportedToCounterparty) + | _ -> None + ) +;; + +let string_to_pricetype_opt (d) = + (match d with + | "Percentage" -> (Some FIX_PriceType_Percentage) + | "PerUnit" -> (Some FIX_PriceType_PerUnit) + | "FixedAmount" -> (Some FIX_PriceType_FixedAmount) + | "Discount" -> (Some FIX_PriceType_Discount) + | "Premium" -> (Some FIX_PriceType_Premium) + | "Spread" -> (Some FIX_PriceType_Spread) + | "TEDPrice" -> (Some FIX_PriceType_TEDPrice) + | "TEDYield" -> (Some FIX_PriceType_TEDYield) + | "Yield" -> (Some FIX_PriceType_Yield) + | "FixedCabinetTradePrice" -> (Some FIX_PriceType_FixedCabinetTradePrice) + | "VariableCabinetTradePrice" -> (Some FIX_PriceType_VariableCabinetTradePrice) + | _ -> None + ) +;; + +let string_to_priorityindicator_opt (d) = + (match d with + | "PriorityUnchanged" -> (Some FIX_PriorityIndicator_PriorityUnchanged) + | "LostPriorityAsResultOfOrderChange" -> (Some FIX_PriorityIndicator_LostPriorityAsResultOfOrderChange) + | _ -> None + ) +;; + +let string_to_processcode_opt (d) = + (match d with + | "Regular" -> (Some FIX_ProcessCode_Regular) + | "SoftDollar" -> (Some FIX_ProcessCode_SoftDollar) + | "StepIn" -> (Some FIX_ProcessCode_StepIn) + | "StepOut" -> (Some FIX_ProcessCode_StepOut) + | "SoftDollarStepIn" -> (Some FIX_ProcessCode_SoftDollarStepIn) + | "SoftDollarStepOut" -> (Some FIX_ProcessCode_SoftDollarStepOut) + | "PlanSponsor" -> (Some FIX_ProcessCode_PlanSponsor) + | _ -> None + ) +;; + +let string_to_product_opt (d) = + (match d with + | "AGENCY" -> (Some FIX_Product_AGENCY) + | "COMMODITY" -> (Some FIX_Product_COMMODITY) + | "CORPORATE" -> (Some FIX_Product_CORPORATE) + | "CURRENCY" -> (Some FIX_Product_CURRENCY) + | "EQUITY" -> (Some FIX_Product_EQUITY) + | "GOVERNMENT" -> (Some FIX_Product_GOVERNMENT) + | "INDEX" -> (Some FIX_Product_INDEX) + | "LOAN" -> (Some FIX_Product_LOAN) + | "MONEYMARKET" -> (Some FIX_Product_MONEYMARKET) + | "MORTGAGE" -> (Some FIX_Product_MORTGAGE) + | "MUNICIPAL" -> (Some FIX_Product_MUNICIPAL) + | "OTHER" -> (Some FIX_Product_OTHER) + | "FINANCING" -> (Some FIX_Product_FINANCING) + | _ -> None + ) +;; + +let string_to_progrptreqs_opt (d) = + (match d with + | "BuySideRequests" -> (Some FIX_ProgRptReqs_BuySideRequests) + | "SellSideSends" -> (Some FIX_ProgRptReqs_SellSideSends) + | "RealTimeExecutionReports" -> (Some FIX_ProgRptReqs_RealTimeExecutionReports) + | _ -> None + ) +;; + +let string_to_publishtrdindicator_opt (d) = + (match d with + | "ReportTrade" -> (Some FIX_PublishTrdIndicator_ReportTrade) + | "DoNotReportTrade" -> (Some FIX_PublishTrdIndicator_DoNotReportTrade) + | _ -> None + ) +;; + +let string_to_putorcall_opt (d) = + (match d with + | "Put" -> (Some FIX_PutOrCall_Put) + | "Call" -> (Some FIX_PutOrCall_Call) + | _ -> None + ) +;; + +let string_to_qtytype_opt (d) = + (match d with + | "Units" -> (Some FIX_QtyType_Units) + | "Contracts" -> (Some FIX_QtyType_Contracts) + | _ -> None + ) +;; + +let string_to_quotecanceltype_opt (d) = + (match d with + | "CancelForOneOrMoreSecurities" -> (Some FIX_QuoteCancelType_CancelForOneOrMoreSecurities) + | "CancelForSecurityType" -> (Some FIX_QuoteCancelType_CancelForSecurityType) + | "CancelForUnderlyingSecurity" -> (Some FIX_QuoteCancelType_CancelForUnderlyingSecurity) + | "CancelAllQuotes" -> (Some FIX_QuoteCancelType_CancelAllQuotes) + | _ -> None + ) +;; + +let string_to_quotecondition_opt (d) = + (match d with + | "Open" -> (Some FIX_QuoteCondition_Open) + | "Closed" -> (Some FIX_QuoteCondition_Closed) + | "ExchangeBest" -> (Some FIX_QuoteCondition_ExchangeBest) + | "ConsolidatedBest" -> (Some FIX_QuoteCondition_ConsolidatedBest) + | "Locked" -> (Some FIX_QuoteCondition_Locked) + | "Crossed" -> (Some FIX_QuoteCondition_Crossed) + | "Depth" -> (Some FIX_QuoteCondition_Depth) + | "FastTrading" -> (Some FIX_QuoteCondition_FastTrading) + | "NonFirm" -> (Some FIX_QuoteCondition_NonFirm) + | _ -> None + ) +;; + +let string_to_quotepricetype_opt (d) = + (match d with + | "Percent" -> (Some FIX_QuotePriceType_Percent) + | "PerShare" -> (Some FIX_QuotePriceType_PerShare) + | "FixedAmount" -> (Some FIX_QuotePriceType_FixedAmount) + | "Discount" -> (Some FIX_QuotePriceType_Discount) + | "Premium" -> (Some FIX_QuotePriceType_Premium) + | "Spread" -> (Some FIX_QuotePriceType_Spread) + | "TEDPrice" -> (Some FIX_QuotePriceType_TEDPrice) + | "TEDYield" -> (Some FIX_QuotePriceType_TEDYield) + | "YieldSpread" -> (Some FIX_QuotePriceType_YieldSpread) + | "Yield" -> (Some FIX_QuotePriceType_Yield) + | _ -> None + ) +;; + +let string_to_quoterejectreason_opt (d) = + (match d with + | "UnknownSymbol" -> (Some FIX_QuoteRejectReason_UnknownSymbol) + | "Exchange" -> (Some FIX_QuoteRejectReason_Exchange) + | "QuoteRequestExceedsLimit" -> (Some FIX_QuoteRejectReason_QuoteRequestExceedsLimit) + | "TooLateToEnter" -> (Some FIX_QuoteRejectReason_TooLateToEnter) + | "UnknownQuote" -> (Some FIX_QuoteRejectReason_UnknownQuote) + | "DuplicateQuote" -> (Some FIX_QuoteRejectReason_DuplicateQuote) + | "InvalidBid" -> (Some FIX_QuoteRejectReason_InvalidBid) + | "InvalidPrice" -> (Some FIX_QuoteRejectReason_InvalidPrice) + | "NotAuthorizedToQuoteSecurity" -> (Some FIX_QuoteRejectReason_NotAuthorizedToQuoteSecurity) + | "Other" -> (Some FIX_QuoteRejectReason_Other) + | _ -> None + ) +;; + +let string_to_quoterequestrejectreason_opt (d) = + (match d with + | "UnknownSymbol" -> (Some FIX_QuoteRequestRejectReason_UnknownSymbol) + | "Exchange" -> (Some FIX_QuoteRequestRejectReason_Exchange) + | "QuoteRequestExceedsLimit" -> (Some FIX_QuoteRequestRejectReason_QuoteRequestExceedsLimit) + | "TooLateToEnter" -> (Some FIX_QuoteRequestRejectReason_TooLateToEnter) + | "InvalidPrice" -> (Some FIX_QuoteRequestRejectReason_InvalidPrice) + | "NotAuthorizedToRequestQuote" -> (Some FIX_QuoteRequestRejectReason_NotAuthorizedToRequestQuote) + | "NoMatchForInquiry" -> (Some FIX_QuoteRequestRejectReason_NoMatchForInquiry) + | "NoMarketForInstrument" -> (Some FIX_QuoteRequestRejectReason_NoMarketForInstrument) + | "NoInventory" -> (Some FIX_QuoteRequestRejectReason_NoInventory) + | "Pass" -> (Some FIX_QuoteRequestRejectReason_Pass) + | "Other" -> (Some FIX_QuoteRequestRejectReason_Other) + | _ -> None + ) +;; + +let string_to_quoterequesttype_opt (d) = + (match d with + | "Manual" -> (Some FIX_QuoteRequestType_Manual) + | "Automatic" -> (Some FIX_QuoteRequestType_Automatic) + | _ -> None + ) +;; + +let string_to_quoteresptype_opt (d) = + (match d with + | "Hit" -> (Some FIX_QuoteRespType_Hit) + | "Counter" -> (Some FIX_QuoteRespType_Counter) + | "Expired" -> (Some FIX_QuoteRespType_Expired) + | "Cover" -> (Some FIX_QuoteRespType_Cover) + | "DoneAway" -> (Some FIX_QuoteRespType_DoneAway) + | "Pass" -> (Some FIX_QuoteRespType_Pass) + | _ -> None + ) +;; + +let string_to_quoteresponselevel_opt (d) = + (match d with + | "NoAcknowledgement" -> (Some FIX_QuoteResponseLevel_NoAcknowledgement) + | "AcknowledgeOnlyNegativeOrErroneousQuotes" -> (Some FIX_QuoteResponseLevel_AcknowledgeOnlyNegativeOrErroneousQuotes) + | "AcknowledgeEachQuoteMessage" -> (Some FIX_QuoteResponseLevel_AcknowledgeEachQuoteMessage) + | _ -> None + ) +;; + +let string_to_quotestatus_opt (d) = + (match d with + | "Accepted" -> (Some FIX_QuoteStatus_Accepted) + | "CancelForSymbol" -> (Some FIX_QuoteStatus_CancelForSymbol) + | "CanceledForSecurityType" -> (Some FIX_QuoteStatus_CanceledForSecurityType) + | "CanceledForUnderlying" -> (Some FIX_QuoteStatus_CanceledForUnderlying) + | "CanceledAll" -> (Some FIX_QuoteStatus_CanceledAll) + | "Rejected" -> (Some FIX_QuoteStatus_Rejected) + | "RemovedFromMarket" -> (Some FIX_QuoteStatus_RemovedFromMarket) + | "Expired" -> (Some FIX_QuoteStatus_Expired) + | "Query" -> (Some FIX_QuoteStatus_Query) + | "QuoteNotFound" -> (Some FIX_QuoteStatus_QuoteNotFound) + | "Pending" -> (Some FIX_QuoteStatus_Pending) + | "Pass" -> (Some FIX_QuoteStatus_Pass) + | "LockedMarketWarning" -> (Some FIX_QuoteStatus_LockedMarketWarning) + | "CrossMarketWarning" -> (Some FIX_QuoteStatus_CrossMarketWarning) + | "CanceledDueToLockMarket" -> (Some FIX_QuoteStatus_CanceledDueToLockMarket) + | "CanceledDueToCrossMarket" -> (Some FIX_QuoteStatus_CanceledDueToCrossMarket) + | _ -> None + ) +;; + +let string_to_quotetype_opt (d) = + (match d with + | "Indicative" -> (Some FIX_QuoteType_Indicative) + | "Tradeable" -> (Some FIX_QuoteType_Tradeable) + | "RestrictedTradeable" -> (Some FIX_QuoteType_RestrictedTradeable) + | "Counter" -> (Some FIX_QuoteType_Counter) + | _ -> None + ) +;; + +let string_to_registrejreasoncode_opt (d) = + (match d with + | "InvalidAccountType" -> (Some FIX_RegistRejReasonCode_InvalidAccountType) + | "InvalidTaxExemptType" -> (Some FIX_RegistRejReasonCode_InvalidTaxExemptType) + | "InvalidOwnershipType" -> (Some FIX_RegistRejReasonCode_InvalidOwnershipType) + | "NoRegDetails" -> (Some FIX_RegistRejReasonCode_NoRegDetails) + | "InvalidRegSeqNo" -> (Some FIX_RegistRejReasonCode_InvalidRegSeqNo) + | "InvalidRegDetails" -> (Some FIX_RegistRejReasonCode_InvalidRegDetails) + | "InvalidMailingDetails" -> (Some FIX_RegistRejReasonCode_InvalidMailingDetails) + | "InvalidMailingInstructions" -> (Some FIX_RegistRejReasonCode_InvalidMailingInstructions) + | "InvalidInvestorID" -> (Some FIX_RegistRejReasonCode_InvalidInvestorID) + | "InvalidInvestorIDSource" -> (Some FIX_RegistRejReasonCode_InvalidInvestorIDSource) + | "InvalidDateOfBirth" -> (Some FIX_RegistRejReasonCode_InvalidDateOfBirth) + | "InvalidCountry" -> (Some FIX_RegistRejReasonCode_InvalidCountry) + | "InvalidDistribInstns" -> (Some FIX_RegistRejReasonCode_InvalidDistribInstns) + | "InvalidPercentage" -> (Some FIX_RegistRejReasonCode_InvalidPercentage) + | "InvalidPaymentMethod" -> (Some FIX_RegistRejReasonCode_InvalidPaymentMethod) + | "InvalidAccountName" -> (Some FIX_RegistRejReasonCode_InvalidAccountName) + | "InvalidAgentCode" -> (Some FIX_RegistRejReasonCode_InvalidAgentCode) + | "InvalidAccountNum" -> (Some FIX_RegistRejReasonCode_InvalidAccountNum) + | "Other" -> (Some FIX_RegistRejReasonCode_Other) + | _ -> None + ) +;; + +let string_to_registstatus_opt (d) = + (match d with + | "Accepted" -> (Some FIX_RegistStatus_Accepted) + | "Rejected" -> (Some FIX_RegistStatus_Rejected) + | "Held" -> (Some FIX_RegistStatus_Held) + | "Reminder" -> (Some FIX_RegistStatus_Reminder) + | _ -> None + ) +;; + +let string_to_registtranstype_opt (d) = + (match d with + | "New" -> (Some FIX_RegistTransType_New) + | "Replace" -> (Some FIX_RegistTransType_Replace) + | "Cancel" -> (Some FIX_RegistTransType_Cancel) + | _ -> None + ) +;; + +let string_to_reporttoexch_opt (d) = + (match d with + | "ReceiverReports" -> (Some FIX_ReportToExch_ReceiverReports) + | "SenderReports" -> (Some FIX_ReportToExch_SenderReports) + | _ -> None + ) +;; + +let string_to_resetseqnumflag_opt (d) = + (match d with + | "Yes" -> (Some FIX_ResetSeqNumFlag_Yes) + | "No" -> (Some FIX_ResetSeqNumFlag_No) + | _ -> None + ) +;; + +let string_to_responsetransporttype_opt (d) = + (match d with + | "Inband" -> (Some FIX_ResponseTransportType_Inband) + | "OutOfBand" -> (Some FIX_ResponseTransportType_OutOfBand) + | _ -> None + ) +;; + +let string_to_roundingdirection_opt (d) = + (match d with + | "RoundToNearest" -> (Some FIX_RoundingDirection_RoundToNearest) + | "RoundDown" -> (Some FIX_RoundingDirection_RoundDown) + | "RoundUp" -> (Some FIX_RoundingDirection_RoundUp) + | _ -> None + ) +;; + +let string_to_routingtype_opt (d) = + (match d with + | "TargetFirm" -> (Some FIX_RoutingType_TargetFirm) + | "TargetList" -> (Some FIX_RoutingType_TargetList) + | "BlockFirm" -> (Some FIX_RoutingType_BlockFirm) + | "BlockList" -> (Some FIX_RoutingType_BlockList) + | _ -> None + ) +;; + +let string_to_scope_opt (d) = + (match d with + | "LocalMarket" -> (Some FIX_Scope_LocalMarket) + | "National" -> (Some FIX_Scope_National) + | "Global" -> (Some FIX_Scope_Global) + | _ -> None + ) +;; + +let string_to_securityidsource_opt (d) = + (match d with + | "CUSIP" -> (Some FIX_SecurityIDSource_CUSIP) + | "SEDOL" -> (Some FIX_SecurityIDSource_SEDOL) + | "QUIK" -> (Some FIX_SecurityIDSource_QUIK) + | "ISINNumber" -> (Some FIX_SecurityIDSource_ISINNumber) + | "RICCode" -> (Some FIX_SecurityIDSource_RICCode) + | "ISOCurrencyCode" -> (Some FIX_SecurityIDSource_ISOCurrencyCode) + | "ISOCountryCode" -> (Some FIX_SecurityIDSource_ISOCountryCode) + | "ExchangeSymbol" -> (Some FIX_SecurityIDSource_ExchangeSymbol) + | "ConsolidatedTapeAssociation" -> (Some FIX_SecurityIDSource_ConsolidatedTapeAssociation) + | "BloombergSymbol" -> (Some FIX_SecurityIDSource_BloombergSymbol) + | "Wertpapier" -> (Some FIX_SecurityIDSource_Wertpapier) + | "Dutch" -> (Some FIX_SecurityIDSource_Dutch) + | "Valoren" -> (Some FIX_SecurityIDSource_Valoren) + | "Sicovam" -> (Some FIX_SecurityIDSource_Sicovam) + | "Belgian" -> (Some FIX_SecurityIDSource_Belgian) + | "Common" -> (Some FIX_SecurityIDSource_Common) + | "ClearingHouse" -> (Some FIX_SecurityIDSource_ClearingHouse) + | "ISDAFpMLSpecification" -> (Some FIX_SecurityIDSource_ISDAFpMLSpecification) + | "OptionPriceReportingAuthority" -> (Some FIX_SecurityIDSource_OptionPriceReportingAuthority) + | _ -> None + ) +;; + +let string_to_securitylistrequesttype_opt (d) = + (match d with + | "Symbol" -> (Some FIX_SecurityListRequestType_Symbol) + | "SecurityTypeAnd" -> (Some FIX_SecurityListRequestType_SecurityTypeAnd) + | "Product" -> (Some FIX_SecurityListRequestType_Product) + | "TradingSessionID" -> (Some FIX_SecurityListRequestType_TradingSessionID) + | "AllSecurities" -> (Some FIX_SecurityListRequestType_AllSecurities) + | _ -> None + ) +;; + +let string_to_securityrequestresult_opt (d) = + (match d with + | "ValidRequest" -> (Some FIX_SecurityRequestResult_ValidRequest) + | "InvalidOrUnsupportedRequest" -> (Some FIX_SecurityRequestResult_InvalidOrUnsupportedRequest) + | "NoInstrumentsFound" -> (Some FIX_SecurityRequestResult_NoInstrumentsFound) + | "NotAuthorizedToRetrieveInstrumentData" -> (Some FIX_SecurityRequestResult_NotAuthorizedToRetrieveInstrumentData) + | "InstrumentDataTemporarilyUnavailable" -> (Some FIX_SecurityRequestResult_InstrumentDataTemporarilyUnavailable) + | "RequestForInstrumentDataNotSupported" -> (Some FIX_SecurityRequestResult_RequestForInstrumentDataNotSupported) + | _ -> None + ) +;; + +let string_to_securityrequesttype_opt (d) = + (match d with + | "RequestSecurityIdentityAndSpecifications" -> (Some FIX_SecurityRequestType_RequestSecurityIdentityAndSpecifications) + | "RequestSecurityIdentityForSpecifications" -> (Some FIX_SecurityRequestType_RequestSecurityIdentityForSpecifications) + | "RequestListSecurityTypes" -> (Some FIX_SecurityRequestType_RequestListSecurityTypes) + | "RequestListSecurities" -> (Some FIX_SecurityRequestType_RequestListSecurities) + | _ -> None + ) +;; + +let string_to_securityresponsetype_opt (d) = + (match d with + | "AcceptAsIs" -> (Some FIX_SecurityResponseType_AcceptAsIs) + | "AcceptWithRevisions" -> (Some FIX_SecurityResponseType_AcceptWithRevisions) + | "RejectSecurityProposal" -> (Some FIX_SecurityResponseType_RejectSecurityProposal) + | "CannotMatchSelectionCriteria" -> (Some FIX_SecurityResponseType_CannotMatchSelectionCriteria) + | _ -> None + ) +;; + +let string_to_securitytradingstatus_opt (d) = + (match d with + | "OpeningDelay" -> (Some FIX_SecurityTradingStatus_OpeningDelay) + | "TradingHalt" -> (Some FIX_SecurityTradingStatus_TradingHalt) + | "Resume" -> (Some FIX_SecurityTradingStatus_Resume) + | "NoOpen" -> (Some FIX_SecurityTradingStatus_NoOpen) + | "PriceIndication" -> (Some FIX_SecurityTradingStatus_PriceIndication) + | "TradingRangeIndication" -> (Some FIX_SecurityTradingStatus_TradingRangeIndication) + | "MarketImbalanceBuy" -> (Some FIX_SecurityTradingStatus_MarketImbalanceBuy) + | "MarketImbalanceSell" -> (Some FIX_SecurityTradingStatus_MarketImbalanceSell) + | "MarketOnCloseImbalanceBuy" -> (Some FIX_SecurityTradingStatus_MarketOnCloseImbalanceBuy) + | "MarketOnCloseImbalanceSell" -> (Some FIX_SecurityTradingStatus_MarketOnCloseImbalanceSell) + | "NoMarketImbalance" -> (Some FIX_SecurityTradingStatus_NoMarketImbalance) + | "NoMarketOnCloseImbalance" -> (Some FIX_SecurityTradingStatus_NoMarketOnCloseImbalance) + | "ITSPreOpening" -> (Some FIX_SecurityTradingStatus_ITSPreOpening) + | "NewPriceIndication" -> (Some FIX_SecurityTradingStatus_NewPriceIndication) + | "TradeDisseminationTime" -> (Some FIX_SecurityTradingStatus_TradeDisseminationTime) + | "ReadyToTrade" -> (Some FIX_SecurityTradingStatus_ReadyToTrade) + | "NotAvailableForTrading" -> (Some FIX_SecurityTradingStatus_NotAvailableForTrading) + | "NotTradedOnThisMarket" -> (Some FIX_SecurityTradingStatus_NotTradedOnThisMarket) + | "UnknownOrInvalid" -> (Some FIX_SecurityTradingStatus_UnknownOrInvalid) + | "PreOpen" -> (Some FIX_SecurityTradingStatus_PreOpen) + | "OpeningRotation" -> (Some FIX_SecurityTradingStatus_OpeningRotation) + | "FastMarket" -> (Some FIX_SecurityTradingStatus_FastMarket) + | _ -> None + ) +;; + +let string_to_securitytype_opt (d) = + (match d with + | "Future" -> (Some FIX_SecurityType_Future) + | "Option" -> (Some FIX_SecurityType_Option) + | "EuroSupranationalCoupons" -> (Some FIX_SecurityType_EuroSupranationalCoupons) + | "FederalAgencyCoupon" -> (Some FIX_SecurityType_FederalAgencyCoupon) + | "FederalAgencyDiscountNote" -> (Some FIX_SecurityType_FederalAgencyDiscountNote) + | "PrivateExportFunding" -> (Some FIX_SecurityType_PrivateExportFunding) + | "USDSupranationalCoupons" -> (Some FIX_SecurityType_USDSupranationalCoupons) + | "CorporateBond" -> (Some FIX_SecurityType_CorporateBond) + | "CorporatePrivatePlacement" -> (Some FIX_SecurityType_CorporatePrivatePlacement) + | "ConvertibleBond" -> (Some FIX_SecurityType_ConvertibleBond) + | "DualCurrency" -> (Some FIX_SecurityType_DualCurrency) + | "EuroCorporateBond" -> (Some FIX_SecurityType_EuroCorporateBond) + | "IndexedLinked" -> (Some FIX_SecurityType_IndexedLinked) + | "StructuredNotes" -> (Some FIX_SecurityType_StructuredNotes) + | "YankeeCorporateBond" -> (Some FIX_SecurityType_YankeeCorporateBond) + | "ForeignExchangeContract" -> (Some FIX_SecurityType_ForeignExchangeContract) + | "CommonStock" -> (Some FIX_SecurityType_CommonStock) + | "PreferredStock" -> (Some FIX_SecurityType_PreferredStock) + | "BradyBond" -> (Some FIX_SecurityType_BradyBond) + | "EuroSovereigns" -> (Some FIX_SecurityType_EuroSovereigns) + | "USTreasuryBond" -> (Some FIX_SecurityType_USTreasuryBond) + | "InterestStripFromAnyBondOrNote" -> (Some FIX_SecurityType_InterestStripFromAnyBondOrNote) + | "TreasuryInflationProtectedSecurities" -> (Some FIX_SecurityType_TreasuryInflationProtectedSecurities) + | "PrincipalStripOfACallableBondOrNote" -> (Some FIX_SecurityType_PrincipalStripOfACallableBondOrNote) + | "PrincipalStripFromANonCallableBondOrNote" -> (Some FIX_SecurityType_PrincipalStripFromANonCallableBondOrNote) + | "USTreasuryNoteOld" -> (Some FIX_SecurityType_USTreasuryNoteOld) + | "USTreasuryBillOld" -> (Some FIX_SecurityType_USTreasuryBillOld) + | "USTreasuryNote" -> (Some FIX_SecurityType_USTreasuryNote) + | "USTreasuryBill" -> (Some FIX_SecurityType_USTreasuryBill) + | "Repurchase" -> (Some FIX_SecurityType_Repurchase) + | "Forward" -> (Some FIX_SecurityType_Forward) + | "BuySellback" -> (Some FIX_SecurityType_BuySellback) + | "SecuritiesLoan" -> (Some FIX_SecurityType_SecuritiesLoan) + | "SecuritiesPledge" -> (Some FIX_SecurityType_SecuritiesPledge) + | "TermLoan" -> (Some FIX_SecurityType_TermLoan) + | "RevolverLoan" -> (Some FIX_SecurityType_RevolverLoan) + | "Revolver" -> (Some FIX_SecurityType_Revolver) + | "BridgeLoan" -> (Some FIX_SecurityType_BridgeLoan) + | "LetterOfCredit" -> (Some FIX_SecurityType_LetterOfCredit) + | "SwingLineFacility" -> (Some FIX_SecurityType_SwingLineFacility) + | "DebtorInPossession" -> (Some FIX_SecurityType_DebtorInPossession) + | "Defaulted" -> (Some FIX_SecurityType_Defaulted) + | "Withdrawn" -> (Some FIX_SecurityType_Withdrawn) + | "Replaced" -> (Some FIX_SecurityType_Replaced) + | "Matured" -> (Some FIX_SecurityType_Matured) + | "Amended" -> (Some FIX_SecurityType_Amended) + | "Retired" -> (Some FIX_SecurityType_Retired) + | "BankersAcceptance" -> (Some FIX_SecurityType_BankersAcceptance) + | "BankNotes" -> (Some FIX_SecurityType_BankNotes) + | "BillOfExchanges" -> (Some FIX_SecurityType_BillOfExchanges) + | "CertificateOfDeposit" -> (Some FIX_SecurityType_CertificateOfDeposit) + | "CallLoans" -> (Some FIX_SecurityType_CallLoans) + | "CommercialPaper" -> (Some FIX_SecurityType_CommercialPaper) + | "DepositNotes" -> (Some FIX_SecurityType_DepositNotes) + | "EuroCertificateOfDeposit" -> (Some FIX_SecurityType_EuroCertificateOfDeposit) + | "EuroCommercialPaper" -> (Some FIX_SecurityType_EuroCommercialPaper) + | "LiquidityNote" -> (Some FIX_SecurityType_LiquidityNote) + | "MediumTermNotes" -> (Some FIX_SecurityType_MediumTermNotes) + | "Overnight" -> (Some FIX_SecurityType_Overnight) + | "PromissoryNote" -> (Some FIX_SecurityType_PromissoryNote) + | "PlazosFijos" -> (Some FIX_SecurityType_PlazosFijos) + | "ShortTermLoanNote" -> (Some FIX_SecurityType_ShortTermLoanNote) + | "TimeDeposit" -> (Some FIX_SecurityType_TimeDeposit) + | "ExtendedCommNote" -> (Some FIX_SecurityType_ExtendedCommNote) + | "YankeeCertificateOfDeposit" -> (Some FIX_SecurityType_YankeeCertificateOfDeposit) + | "AssetBackedSecurities" -> (Some FIX_SecurityType_AssetBackedSecurities) + | "Corp" -> (Some FIX_SecurityType_Corp) + | "CollateralizedMortgageObligation" -> (Some FIX_SecurityType_CollateralizedMortgageObligation) + | "IOETTEMortgage" -> (Some FIX_SecurityType_IOETTEMortgage) + | "MortgageBackedSecurities" -> (Some FIX_SecurityType_MortgageBackedSecurities) + | "MortgageInterestOnly" -> (Some FIX_SecurityType_MortgageInterestOnly) + | "MortgagePrincipalOnly" -> (Some FIX_SecurityType_MortgagePrincipalOnly) + | "MortgagePrivatePlacement" -> (Some FIX_SecurityType_MortgagePrivatePlacement) + | "MiscellaneousPassThrough" -> (Some FIX_SecurityType_MiscellaneousPassThrough) + | "Pfandbriefe" -> (Some FIX_SecurityType_Pfandbriefe) + | "ToBeAnnounced" -> (Some FIX_SecurityType_ToBeAnnounced) + | "OtherAnticipationNotes" -> (Some FIX_SecurityType_OtherAnticipationNotes) + | "CertificateOfObligation" -> (Some FIX_SecurityType_CertificateOfObligation) + | "CertificateOfParticipation" -> (Some FIX_SecurityType_CertificateOfParticipation) + | "GeneralObligationBonds" -> (Some FIX_SecurityType_GeneralObligationBonds) + | "MandatoryTender" -> (Some FIX_SecurityType_MandatoryTender) + | "RevenueAnticipationNote" -> (Some FIX_SecurityType_RevenueAnticipationNote) + | "RevenueBonds" -> (Some FIX_SecurityType_RevenueBonds) + | "SpecialAssessment" -> (Some FIX_SecurityType_SpecialAssessment) + | "SpecialObligation" -> (Some FIX_SecurityType_SpecialObligation) + | "SpecialTax" -> (Some FIX_SecurityType_SpecialTax) + | "TaxAnticipationNote" -> (Some FIX_SecurityType_TaxAnticipationNote) + | "TaxAllocation" -> (Some FIX_SecurityType_TaxAllocation) + | "TaxExemptCommercialPaper" -> (Some FIX_SecurityType_TaxExemptCommercialPaper) + | "TaxRevenueAnticipationNote" -> (Some FIX_SecurityType_TaxRevenueAnticipationNote) + | "VariableRateDemandNote" -> (Some FIX_SecurityType_VariableRateDemandNote) + | "Warrant" -> (Some FIX_SecurityType_Warrant) + | "MutualFund" -> (Some FIX_SecurityType_MutualFund) + | "MultilegInstrument" -> (Some FIX_SecurityType_MultilegInstrument) + | "NoSecurityType" -> (Some FIX_SecurityType_NoSecurityType) + | _ -> None + ) +;; + +let string_to_settlcurrfxratecalc_opt (d) = + (match d with + | "Multiply" -> (Some FIX_SettlCurrFxRateCalc_Multiply) + | "Divide" -> (Some FIX_SettlCurrFxRateCalc_Divide) + | _ -> None + ) +;; + +let string_to_settldeliverytype_opt (d) = + (match d with + | "Versus" -> (Some FIX_SettlDeliveryType_Versus) + | "Free" -> (Some FIX_SettlDeliveryType_Free) + | "TriParty" -> (Some FIX_SettlDeliveryType_TriParty) + | "HoldInCustody" -> (Some FIX_SettlDeliveryType_HoldInCustody) + | _ -> None + ) +;; + +let string_to_settlinstmode_opt (d) = + (match d with + | "StandingInstructionsProvided" -> (Some FIX_SettlInstMode_StandingInstructionsProvided) + | "SpecificOrderForASingleAccount" -> (Some FIX_SettlInstMode_SpecificOrderForASingleAccount) + | "RequestReject" -> (Some FIX_SettlInstMode_RequestReject) + | _ -> None + ) +;; + +let string_to_settlinstreqrejcode_opt (d) = + (match d with + | "UnableToProcessRequest" -> (Some FIX_SettlInstReqRejCode_UnableToProcessRequest) + | "UnknownAccount" -> (Some FIX_SettlInstReqRejCode_UnknownAccount) + | "NoMatchingSettlementInstructionsFound" -> (Some FIX_SettlInstReqRejCode_NoMatchingSettlementInstructionsFound) + | "Other" -> (Some FIX_SettlInstReqRejCode_Other) + | _ -> None + ) +;; + +let string_to_settlinstsource_opt (d) = + (match d with + | "BrokerCredit" -> (Some FIX_SettlInstSource_BrokerCredit) + | "Institution" -> (Some FIX_SettlInstSource_Institution) + | "Investor" -> (Some FIX_SettlInstSource_Investor) + | _ -> None + ) +;; + +let string_to_settlinsttranstype_opt (d) = + (match d with + | "New" -> (Some FIX_SettlInstTransType_New) + | "Cancel" -> (Some FIX_SettlInstTransType_Cancel) + | "Replace" -> (Some FIX_SettlInstTransType_Replace) + | "Restate" -> (Some FIX_SettlInstTransType_Restate) + | _ -> None + ) +;; + +let string_to_settlpricetype_opt (d) = + (match d with + | "Final" -> (Some FIX_SettlPriceType_Final) + | "Theoretical" -> (Some FIX_SettlPriceType_Theoretical) + | _ -> None + ) +;; + +let string_to_settlsessid_opt (d) = + (match d with + | "Intraday" -> (Some FIX_SettlSessID_Intraday) + | "RegularTradingHours" -> (Some FIX_SettlSessID_RegularTradingHours) + | "ElectronicTradingHours" -> (Some FIX_SettlSessID_ElectronicTradingHours) + | _ -> None + ) +;; + +let string_to_settltype_opt (d) = + (match d with + | "Regular" -> (Some FIX_SettlType_Regular) + | "Cash" -> (Some FIX_SettlType_Cash) + | "NextDay" -> (Some FIX_SettlType_NextDay) + | "TPlus2" -> (Some FIX_SettlType_TPlus2) + | "TPlus3" -> (Some FIX_SettlType_TPlus3) + | "TPlus4" -> (Some FIX_SettlType_TPlus4) + | "Future" -> (Some FIX_SettlType_Future) + | "WhenAndIfIssued" -> (Some FIX_SettlType_WhenAndIfIssued) + | "SellersOption" -> (Some FIX_SettlType_SellersOption) + | "TPlus5" -> (Some FIX_SettlType_TPlus5) + | _ -> None + ) +;; + +let string_to_shortsalereason_opt (d) = + (match d with + | "DealerSoldShort" -> (Some FIX_ShortSaleReason_DealerSoldShort) + | "DealerSoldShortExempt" -> (Some FIX_ShortSaleReason_DealerSoldShortExempt) + | "SellingCustomerSoldShort" -> (Some FIX_ShortSaleReason_SellingCustomerSoldShort) + | "SellingCustomerSoldShortExempt" -> (Some FIX_ShortSaleReason_SellingCustomerSoldShortExempt) + | "QualifiedServiceRepresentative" -> (Some FIX_ShortSaleReason_QualifiedServiceRepresentative) + | "QSROrAGUContraSideSoldShortExempt" -> (Some FIX_ShortSaleReason_QSROrAGUContraSideSoldShortExempt) + | _ -> None + ) +;; + +let string_to_side_opt (d) = + (match d with + | "Buy" -> (Some FIX_Side_Buy) + | "Sell" -> (Some FIX_Side_Sell) + | "BuyMinus" -> (Some FIX_Side_BuyMinus) + | "SellPlus" -> (Some FIX_Side_SellPlus) + | "SellShort" -> (Some FIX_Side_SellShort) + | "SellShortExempt" -> (Some FIX_Side_SellShortExempt) + | "Undisclosed" -> (Some FIX_Side_Undisclosed) + | "Cross" -> (Some FIX_Side_Cross) + | "CrossShort" -> (Some FIX_Side_CrossShort) + | "CrossShortExempt" -> (Some FIX_Side_CrossShortExempt) + | "AsDefined" -> (Some FIX_Side_AsDefined) + | "Opposite" -> (Some FIX_Side_Opposite) + | "Subscribe" -> (Some FIX_Side_Subscribe) + | "Redeem" -> (Some FIX_Side_Redeem) + | "Lend" -> (Some FIX_Side_Lend) + | "Borrow" -> (Some FIX_Side_Borrow) + | _ -> None + ) +;; + +let string_to_sidemultilegreportingtype_opt (d) = + (match d with + | "SingleSecurity" -> (Some FIX_SideMultiLegReportingType_SingleSecurity) + | "IndividualLegOfAMultilegSecurity" -> (Some FIX_SideMultiLegReportingType_IndividualLegOfAMultilegSecurity) + | "MultilegSecurity" -> (Some FIX_SideMultiLegReportingType_MultilegSecurity) + | _ -> None + ) +;; + +let string_to_sidevalueind_opt (d) = + (match d with + | "SideValue1" -> (Some FIX_SideValueInd_SideValue1) + | "SideValue2" -> (Some FIX_SideValueInd_SideValue2) + | _ -> None + ) +;; + +let string_to_solicitedflag_opt (d) = + (match d with + | "WasSolicited" -> (Some FIX_SolicitedFlag_WasSolicited) + | "WasNotSolicited" -> (Some FIX_SolicitedFlag_WasNotSolicited) + | _ -> None + ) +;; + +let string_to_standinstdbtype_opt (d) = + (match d with + | "Other" -> (Some FIX_StandInstDbType_Other) + | "DTCSID" -> (Some FIX_StandInstDbType_DTCSID) + | "ThomsonALERT" -> (Some FIX_StandInstDbType_ThomsonALERT) + | "AGlobalCustodian" -> (Some FIX_StandInstDbType_AGlobalCustodian) + | "AccountNet" -> (Some FIX_StandInstDbType_AccountNet) + | _ -> None + ) +;; + +let string_to_statusvalue_opt (d) = + (match d with + | "Connected" -> (Some FIX_StatusValue_Connected) + | "NotConnectedUnexpected" -> (Some FIX_StatusValue_NotConnectedUnexpected) + | "NotConnectedExpected" -> (Some FIX_StatusValue_NotConnectedExpected) + | "InProcess" -> (Some FIX_StatusValue_InProcess) + | _ -> None + ) +;; + +let string_to_stipulationtype_opt (d) = + (match d with + | "AlternativeMinimumTax" -> (Some FIX_StipulationType_AlternativeMinimumTax) + | "AutoReinvestment" -> (Some FIX_StipulationType_AutoReinvestment) + | "BankQualified" -> (Some FIX_StipulationType_BankQualified) + | "BargainConditions" -> (Some FIX_StipulationType_BargainConditions) + | "CouponRange" -> (Some FIX_StipulationType_CouponRange) + | "ISOCurrencyCode" -> (Some FIX_StipulationType_ISOCurrencyCode) + | "CustomStart" -> (Some FIX_StipulationType_CustomStart) + | "Geographics" -> (Some FIX_StipulationType_Geographics) + | "ValuationDiscount" -> (Some FIX_StipulationType_ValuationDiscount) + | "Insured" -> (Some FIX_StipulationType_Insured) + | "IssueDate" -> (Some FIX_StipulationType_IssueDate) + | "Issuer" -> (Some FIX_StipulationType_Issuer) + | "IssueSizeRange" -> (Some FIX_StipulationType_IssueSizeRange) + | "LookbackDays" -> (Some FIX_StipulationType_LookbackDays) + | "ExplicitLotIdentifier" -> (Some FIX_StipulationType_ExplicitLotIdentifier) + | "LotVariance" -> (Some FIX_StipulationType_LotVariance) + | "MaturityYearAndMonth" -> (Some FIX_StipulationType_MaturityYearAndMonth) + | "MaturityRange" -> (Some FIX_StipulationType_MaturityRange) + | "MaximumSubstitutions" -> (Some FIX_StipulationType_MaximumSubstitutions) + | "MinimumQuantity" -> (Some FIX_StipulationType_MinimumQuantity) + | "MinimumIncrement" -> (Some FIX_StipulationType_MinimumIncrement) + | "MinimumDenomination" -> (Some FIX_StipulationType_MinimumDenomination) + | "PaymentFrequency" -> (Some FIX_StipulationType_PaymentFrequency) + | "NumberOfPieces" -> (Some FIX_StipulationType_NumberOfPieces) + | "PoolsMaximum" -> (Some FIX_StipulationType_PoolsMaximum) + | "PoolsPerMillion" -> (Some FIX_StipulationType_PoolsPerMillion) + | "PoolsPerLot" -> (Some FIX_StipulationType_PoolsPerLot) + | "PoolsPerTrade" -> (Some FIX_StipulationType_PoolsPerTrade) + | "PriceRange" -> (Some FIX_StipulationType_PriceRange) + | "PricingFrequency" -> (Some FIX_StipulationType_PricingFrequency) + | "ProductionYear" -> (Some FIX_StipulationType_ProductionYear) + | "CallProtection" -> (Some FIX_StipulationType_CallProtection) + | "Purpose" -> (Some FIX_StipulationType_Purpose) + | "BenchmarkPriceSource" -> (Some FIX_StipulationType_BenchmarkPriceSource) + | "RatingSourceAndRange" -> (Some FIX_StipulationType_RatingSourceAndRange) + | "TypeOfRedemption" -> (Some FIX_StipulationType_TypeOfRedemption) + | "Restricted" -> (Some FIX_StipulationType_Restricted) + | "MarketSector" -> (Some FIX_StipulationType_MarketSector) + | "SecurityTypeIncludedOrExcluded" -> (Some FIX_StipulationType_SecurityTypeIncludedOrExcluded) + | "Structure" -> (Some FIX_StipulationType_Structure) + | "SubstitutionsFrequency" -> (Some FIX_StipulationType_SubstitutionsFrequency) + | "SubstitutionsLeft" -> (Some FIX_StipulationType_SubstitutionsLeft) + | "FreeformText" -> (Some FIX_StipulationType_FreeformText) + | "TradeVariance" -> (Some FIX_StipulationType_TradeVariance) + | "WeightedAverageCoupon" -> (Some FIX_StipulationType_WeightedAverageCoupon) + | "WeightedAverageLifeCoupon" -> (Some FIX_StipulationType_WeightedAverageLifeCoupon) + | "WeightedAverageLoanAge" -> (Some FIX_StipulationType_WeightedAverageLoanAge) + | "WeightedAverageMaturity" -> (Some FIX_StipulationType_WeightedAverageMaturity) + | "WholePool" -> (Some FIX_StipulationType_WholePool) + | "YieldRange" -> (Some FIX_StipulationType_YieldRange) + | _ -> None + ) +;; + +let string_to_subscriptionrequesttype_opt (d) = + (match d with + | "Snapshot" -> (Some FIX_SubscriptionRequestType_Snapshot) + | "SnapshotAndUpdates" -> (Some FIX_SubscriptionRequestType_SnapshotAndUpdates) + | "DisablePreviousSnapshot" -> (Some FIX_SubscriptionRequestType_DisablePreviousSnapshot) + | _ -> None + ) +;; + +let string_to_targetstrategy_opt (d) = + (match d with + | "VWAP" -> (Some FIX_TargetStrategy_VWAP) + | "Participate" -> (Some FIX_TargetStrategy_Participate) + | "MininizeMarketImpact" -> (Some FIX_TargetStrategy_MininizeMarketImpact) + | _ -> None + ) +;; + +let string_to_taxadvantagetype_opt (d) = + (match d with + | "FIXNone" -> (Some FIX_TaxAdvantageType_FIXNone) + | "MaxiISA" -> (Some FIX_TaxAdvantageType_MaxiISA) + | "TESSA" -> (Some FIX_TaxAdvantageType_TESSA) + | "MiniCashISA" -> (Some FIX_TaxAdvantageType_MiniCashISA) + | "MiniStocksAndSharesISA" -> (Some FIX_TaxAdvantageType_MiniStocksAndSharesISA) + | "MiniInsuranceISA" -> (Some FIX_TaxAdvantageType_MiniInsuranceISA) + | "CurrentYearPayment" -> (Some FIX_TaxAdvantageType_CurrentYearPayment) + | "PriorYearPayment" -> (Some FIX_TaxAdvantageType_PriorYearPayment) + | "AssetTransfer" -> (Some FIX_TaxAdvantageType_AssetTransfer) + | "EmployeePriorYear" -> (Some FIX_TaxAdvantageType_EmployeePriorYear) + | "EmployeeCurrentYear" -> (Some FIX_TaxAdvantageType_EmployeeCurrentYear) + | "EmployerPriorYear" -> (Some FIX_TaxAdvantageType_EmployerPriorYear) + | "EmployerCurrentYear" -> (Some FIX_TaxAdvantageType_EmployerCurrentYear) + | "NonFundPrototypeIRA" -> (Some FIX_TaxAdvantageType_NonFundPrototypeIRA) + | "NonFundQualifiedPlan" -> (Some FIX_TaxAdvantageType_NonFundQualifiedPlan) + | "DefinedContributionPlan" -> (Some FIX_TaxAdvantageType_DefinedContributionPlan) + | "IRA" -> (Some FIX_TaxAdvantageType_IRA) + | "IRARollover" -> (Some FIX_TaxAdvantageType_IRARollover) + | "KEOGH" -> (Some FIX_TaxAdvantageType_KEOGH) + | "ProfitSharingPlan" -> (Some FIX_TaxAdvantageType_ProfitSharingPlan) + | "US401K" -> (Some FIX_TaxAdvantageType_US401K) + | "SelfDirectedIRA" -> (Some FIX_TaxAdvantageType_SelfDirectedIRA) + | "US403b" -> (Some FIX_TaxAdvantageType_US403b) + | "US457" -> (Some FIX_TaxAdvantageType_US457) + | "RothIRAPrototype" -> (Some FIX_TaxAdvantageType_RothIRAPrototype) + | "RothIRANonPrototype" -> (Some FIX_TaxAdvantageType_RothIRANonPrototype) + | "RothConversionIRAPrototype" -> (Some FIX_TaxAdvantageType_RothConversionIRAPrototype) + | "RothConversionIRANonPrototype" -> (Some FIX_TaxAdvantageType_RothConversionIRANonPrototype) + | "EducationIRAPrototype" -> (Some FIX_TaxAdvantageType_EducationIRAPrototype) + | "EducationIRANonPrototype" -> (Some FIX_TaxAdvantageType_EducationIRANonPrototype) + | _ -> None + ) +;; + +let string_to_terminationtype_opt (d) = + (match d with + | "Overnight" -> (Some FIX_TerminationType_Overnight) + | "Term" -> (Some FIX_TerminationType_Term) + | "Flexible" -> (Some FIX_TerminationType_Flexible) + | "Open" -> (Some FIX_TerminationType_Open) + | _ -> None + ) +;; + +let string_to_testmessageindicator_opt (d) = + (match d with + | "True" -> (Some FIX_TestMessageIndicator_True) + | "Fales" -> (Some FIX_TestMessageIndicator_Fales) + | _ -> None + ) +;; + +let string_to_tickdirection_opt (d) = + (match d with + | "PlusTick" -> (Some FIX_TickDirection_PlusTick) + | "ZeroPlusTick" -> (Some FIX_TickDirection_ZeroPlusTick) + | "MinusTick" -> (Some FIX_TickDirection_MinusTick) + | "ZeroMinusTick" -> (Some FIX_TickDirection_ZeroMinusTick) + | _ -> None + ) +;; + +let string_to_timeinforce_opt (d) = + (match d with + | "Day" -> (Some FIX_TimeInForce_Day) + | "GoodTillCancel" -> (Some FIX_TimeInForce_GoodTillCancel) + | "AtTheOpening" -> (Some FIX_TimeInForce_AtTheOpening) + | "ImmediateOrCancel" -> (Some FIX_TimeInForce_ImmediateOrCancel) + | "FillOrKill" -> (Some FIX_TimeInForce_FillOrKill) + | "GoodTillCrossing" -> (Some FIX_TimeInForce_GoodTillCrossing) + | "GoodTillDate" -> (Some FIX_TimeInForce_GoodTillDate) + | "AtTheClose" -> (Some FIX_TimeInForce_AtTheClose) + | _ -> None + ) +;; + +let string_to_tradsesmethod_opt (d) = + (match d with + | "Electronic" -> (Some FIX_TradSesMethod_Electronic) + | "OpenOutcry" -> (Some FIX_TradSesMethod_OpenOutcry) + | "TwoParty" -> (Some FIX_TradSesMethod_TwoParty) + | _ -> None + ) +;; + +let string_to_tradsesmode_opt (d) = + (match d with + | "Testing" -> (Some FIX_TradSesMode_Testing) + | "Simulated" -> (Some FIX_TradSesMode_Simulated) + | "Production" -> (Some FIX_TradSesMode_Production) + | _ -> None + ) +;; + +let string_to_tradsesstatus_opt (d) = + (match d with + | "Unknown" -> (Some FIX_TradSesStatus_Unknown) + | "Halted" -> (Some FIX_TradSesStatus_Halted) + | "Open" -> (Some FIX_TradSesStatus_Open) + | "Closed" -> (Some FIX_TradSesStatus_Closed) + | "PreOpen" -> (Some FIX_TradSesStatus_PreOpen) + | "PreClose" -> (Some FIX_TradSesStatus_PreClose) + | "RequestRejected" -> (Some FIX_TradSesStatus_RequestRejected) + | _ -> None + ) +;; + +let string_to_tradsesstatusrejreason_opt (d) = + (match d with + | "UnknownOrInvalidTradingSessionID" -> (Some FIX_TradSesStatusRejReason_UnknownOrInvalidTradingSessionID) + | "Other" -> (Some FIX_TradSesStatusRejReason_Other) + | _ -> None + ) +;; + +let string_to_tradeallocindicator_opt (d) = + (match d with + | "AllocationNotRequired" -> (Some FIX_TradeAllocIndicator_AllocationNotRequired) + | "AllocationRequired" -> (Some FIX_TradeAllocIndicator_AllocationRequired) + | "UseAllocationProvidedWithTheTrade" -> (Some FIX_TradeAllocIndicator_UseAllocationProvidedWithTheTrade) + | _ -> None + ) +;; + +let string_to_tradecondition_opt (d) = + (match d with + | "Cash" -> (Some FIX_TradeCondition_Cash) + | "AveragePriceTrade" -> (Some FIX_TradeCondition_AveragePriceTrade) + | "CashTrade" -> (Some FIX_TradeCondition_CashTrade) + | "NextDay" -> (Some FIX_TradeCondition_NextDay) + | "Opening" -> (Some FIX_TradeCondition_Opening) + | "IntradayTradeDetail" -> (Some FIX_TradeCondition_IntradayTradeDetail) + | "Rule127Trade" -> (Some FIX_TradeCondition_Rule127Trade) + | "Rule155Trade" -> (Some FIX_TradeCondition_Rule155Trade) + | "SoldLast" -> (Some FIX_TradeCondition_SoldLast) + | "NextDayTrade" -> (Some FIX_TradeCondition_NextDayTrade) + | "Opened" -> (Some FIX_TradeCondition_Opened) + | "Seller" -> (Some FIX_TradeCondition_Seller) + | "Sold" -> (Some FIX_TradeCondition_Sold) + | "StoppedStock" -> (Some FIX_TradeCondition_StoppedStock) + | "ImbalanceMoreBuyers" -> (Some FIX_TradeCondition_ImbalanceMoreBuyers) + | "ImbalanceMoreSellers" -> (Some FIX_TradeCondition_ImbalanceMoreSellers) + | "OpeningPrice" -> (Some FIX_TradeCondition_OpeningPrice) + | _ -> None + ) +;; + +let string_to_tradereportrejectreason_opt (d) = + (match d with + | "Successful" -> (Some FIX_TradeReportRejectReason_Successful) + | "InvalidPartyOnformation" -> (Some FIX_TradeReportRejectReason_InvalidPartyOnformation) + | "UnknownInstrument" -> (Some FIX_TradeReportRejectReason_UnknownInstrument) + | "UnauthorizedToReportTrades" -> (Some FIX_TradeReportRejectReason_UnauthorizedToReportTrades) + | "InvalidTradeType" -> (Some FIX_TradeReportRejectReason_InvalidTradeType) + | "Other" -> (Some FIX_TradeReportRejectReason_Other) + | _ -> None + ) +;; + +let string_to_tradereporttype_opt (d) = + (match d with + | "Submit" -> (Some FIX_TradeReportType_Submit) + | "Alleged" -> (Some FIX_TradeReportType_Alleged) + | "Accept" -> (Some FIX_TradeReportType_Accept) + | "Decline" -> (Some FIX_TradeReportType_Decline) + | "Addendum" -> (Some FIX_TradeReportType_Addendum) + | "No" -> (Some FIX_TradeReportType_No) + | "TradeReportCancel" -> (Some FIX_TradeReportType_TradeReportCancel) + | "LockedIn" -> (Some FIX_TradeReportType_LockedIn) + | _ -> None + ) +;; + +let string_to_traderequestresult_opt (d) = + (match d with + | "Successful" -> (Some FIX_TradeRequestResult_Successful) + | "InvalidOrUnknownInstrument" -> (Some FIX_TradeRequestResult_InvalidOrUnknownInstrument) + | "InvalidTypeOfTradeRequested" -> (Some FIX_TradeRequestResult_InvalidTypeOfTradeRequested) + | "InvalidParties" -> (Some FIX_TradeRequestResult_InvalidParties) + | "InvalidTransportTypeRequested" -> (Some FIX_TradeRequestResult_InvalidTransportTypeRequested) + | "InvalidDestinationRequested" -> (Some FIX_TradeRequestResult_InvalidDestinationRequested) + | "TradeRequestTypeNotSupported" -> (Some FIX_TradeRequestResult_TradeRequestTypeNotSupported) + | "NotAuthorized" -> (Some FIX_TradeRequestResult_NotAuthorized) + | "Other" -> (Some FIX_TradeRequestResult_Other) + | _ -> None + ) +;; + +let string_to_traderequeststatus_opt (d) = + (match d with + | "Accepted" -> (Some FIX_TradeRequestStatus_Accepted) + | "Completed" -> (Some FIX_TradeRequestStatus_Completed) + | "Rejected" -> (Some FIX_TradeRequestStatus_Rejected) + | _ -> None + ) +;; + +let string_to_traderequesttype_opt (d) = + (match d with + | "AllTrades" -> (Some FIX_TradeRequestType_AllTrades) + | "MatchedTradesMatchingCriteria" -> (Some FIX_TradeRequestType_MatchedTradesMatchingCriteria) + | "UnmatchedTradesThatMatchCriteria" -> (Some FIX_TradeRequestType_UnmatchedTradesThatMatchCriteria) + | "UnreportedTradesThatMatchCriteria" -> (Some FIX_TradeRequestType_UnreportedTradesThatMatchCriteria) + | "AdvisoriesThatMatchCriteria" -> (Some FIX_TradeRequestType_AdvisoriesThatMatchCriteria) + | _ -> None + ) +;; + +let string_to_tradedflatswitch_opt (d) = + (match d with + | "TradedFlat" -> (Some FIX_TradedFlatSwitch_TradedFlat) + | "NotTradedFlat" -> (Some FIX_TradedFlatSwitch_NotTradedFlat) + | _ -> None + ) +;; + +let string_to_trdregtimestamptype_opt (d) = + (match d with + | "ExecutionTime" -> (Some FIX_TrdRegTimestampType_ExecutionTime) + | "TimeIn" -> (Some FIX_TrdRegTimestampType_TimeIn) + | "TimeOut" -> (Some FIX_TrdRegTimestampType_TimeOut) + | "BrokerReceipt" -> (Some FIX_TrdRegTimestampType_BrokerReceipt) + | "BrokerExecution" -> (Some FIX_TrdRegTimestampType_BrokerExecution) + | _ -> None + ) +;; + +let string_to_trdrptstatus_opt (d) = + (match d with + | "Accepted" -> (Some FIX_TrdRptStatus_Accepted) + | "Rejected" -> (Some FIX_TrdRptStatus_Rejected) + | _ -> None + ) +;; + +let string_to_trdtype_opt (d) = + (match d with + | "RegularTrade" -> (Some FIX_TrdType_RegularTrade) + | "BlockTrade" -> (Some FIX_TrdType_BlockTrade) + | "EFP" -> (Some FIX_TrdType_EFP) + | "Transfer" -> (Some FIX_TrdType_Transfer) + | "LateTrade" -> (Some FIX_TrdType_LateTrade) + | "TTrade" -> (Some FIX_TrdType_TTrade) + | "WeightedAveragePriceTrade" -> (Some FIX_TrdType_WeightedAveragePriceTrade) + | "BunchedTrade" -> (Some FIX_TrdType_BunchedTrade) + | "LateBunchedTrade" -> (Some FIX_TrdType_LateBunchedTrade) + | "PriorReferencePriceTrade" -> (Some FIX_TrdType_PriorReferencePriceTrade) + | "AfterHoursTrade" -> (Some FIX_TrdType_AfterHoursTrade) + | _ -> None + ) +;; + +let string_to_unsolicitedindicator_opt (d) = + (match d with + | "MessageIsBeingSentUnsolicited" -> (Some FIX_UnsolicitedIndicator_MessageIsBeingSentUnsolicited) + | "MessageIsBeingSentAsAResultOfAPriorRequest" -> (Some FIX_UnsolicitedIndicator_MessageIsBeingSentAsAResultOfAPriorRequest) + | _ -> None + ) +;; + +let string_to_urgency_opt (d) = + (match d with + | "Normal" -> (Some FIX_Urgency_Normal) + | "Flash" -> (Some FIX_Urgency_Flash) + | "Background" -> (Some FIX_Urgency_Background) + | _ -> None + ) +;; + +let string_to_userrequesttype_opt (d) = + (match d with + | "LogOnUser" -> (Some FIX_UserRequestType_LogOnUser) + | "LogOffUser" -> (Some FIX_UserRequestType_LogOffUser) + | "ChangePasswordForUser" -> (Some FIX_UserRequestType_ChangePasswordForUser) + | "RequestIndividualUserStatus" -> (Some FIX_UserRequestType_RequestIndividualUserStatus) + | _ -> None + ) +;; + +let string_to_userstatus_opt (d) = + (match d with + | "LoggedIn" -> (Some FIX_UserStatus_LoggedIn) + | "NotLoggedIn" -> (Some FIX_UserStatus_NotLoggedIn) + | "UserNotRecognised" -> (Some FIX_UserStatus_UserNotRecognised) + | "PasswordIncorrect" -> (Some FIX_UserStatus_PasswordIncorrect) + | "PasswordChanged" -> (Some FIX_UserStatus_PasswordChanged) + | "Other" -> (Some FIX_UserStatus_Other) + | _ -> None + ) +;; + +let string_to_workingindicator_opt (d) = + (match d with + | "Working" -> (Some FIX_WorkingIndicator_Working) + | "NotWorking" -> (Some FIX_WorkingIndicator_NotWorking) + | _ -> None + ) +;; + +let string_to_yieldtype_opt (d) = + (match d with + | "AfterTaxYield" -> (Some FIX_YieldType_AfterTaxYield) + | "AnnualYield" -> (Some FIX_YieldType_AnnualYield) + | "YieldAtIssue" -> (Some FIX_YieldType_YieldAtIssue) + | "YieldToAverageMaturity" -> (Some FIX_YieldType_YieldToAverageMaturity) + | "BookYield" -> (Some FIX_YieldType_BookYield) + | "YieldToNextCall" -> (Some FIX_YieldType_YieldToNextCall) + | "YieldChangeSinceClose" -> (Some FIX_YieldType_YieldChangeSinceClose) + | "ClosingYield" -> (Some FIX_YieldType_ClosingYield) + | "CompoundYield" -> (Some FIX_YieldType_CompoundYield) + | "CurrentYield" -> (Some FIX_YieldType_CurrentYield) + | "TrueGrossYield" -> (Some FIX_YieldType_TrueGrossYield) + | "GvntEquivalentYield" -> (Some FIX_YieldType_GvntEquivalentYield) + | "YieldWithInflationAssumption" -> (Some FIX_YieldType_YieldWithInflationAssumption) + | "InverseFloaterBondYield" -> (Some FIX_YieldType_InverseFloaterBondYield) + | "MostRecentClosingYield" -> (Some FIX_YieldType_MostRecentClosingYield) + | "ClosingYieldMostRecentMonth" -> (Some FIX_YieldType_ClosingYieldMostRecentMonth) + | "ClosingYieldMostRecentQuarter" -> (Some FIX_YieldType_ClosingYieldMostRecentQuarter) + | "ClosingYieldMostRecentYear" -> (Some FIX_YieldType_ClosingYieldMostRecentYear) + | "YieldToLongestAverageLife" -> (Some FIX_YieldType_YieldToLongestAverageLife) + | "MarkToMarketYield" -> (Some FIX_YieldType_MarkToMarketYield) + | "YieldToMaturity" -> (Some FIX_YieldType_YieldToMaturity) + | "YieldToNextRefund" -> (Some FIX_YieldType_YieldToNextRefund) + | "OpenAverageYield" -> (Some FIX_YieldType_OpenAverageYield) + | "YieldToNextPut" -> (Some FIX_YieldType_YieldToNextPut) + | "PreviousCloseYield" -> (Some FIX_YieldType_PreviousCloseYield) + | "ProceedsYield" -> (Some FIX_YieldType_ProceedsYield) + | "SemiAnnualYield" -> (Some FIX_YieldType_SemiAnnualYield) + | "YieldToShortestAverageLife" -> (Some FIX_YieldType_YieldToShortestAverageLife) + | "SimpleYield" -> (Some FIX_YieldType_SimpleYield) + | "TaxEquivalentYield" -> (Some FIX_YieldType_TaxEquivalentYield) + | "YieldToTenderDate" -> (Some FIX_YieldType_YieldToTenderDate) + | "TrueYield" -> (Some FIX_YieldType_TrueYield) + | "YieldValueOf132" -> (Some FIX_YieldType_YieldValueOf132) + | "YieldToWorst" -> (Some FIX_YieldType_YieldToWorst) + | _ -> None + ) +;; + +let full_enum_currency_decoder : fix_currency decoder = + string >>= (fun x -> (match string_to_currency_opt x with + | None -> (fail "Unknown enum (Currency) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_country_decoder : fix_country decoder = + string >>= (fun x -> (match string_to_country_opt x with + | None -> (fail "Unknown enum (Country) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_exchange_decoder : fix_exchange decoder = + string >>= (fun x -> (match string_to_exchange_opt x with + | None -> (fail "Unknown enum (Exchange) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_accounttype_decoder : fix_accounttype decoder = + string >>= (fun x -> (match string_to_accounttype_opt x with + | None -> (fail "Unknown enum (AccountType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_acctidsource_decoder : fix_acctidsource decoder = + string >>= (fun x -> (match string_to_acctidsource_opt x with + | None -> (fail "Unknown enum (AcctIDSource) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_adjustment_decoder : fix_adjustment decoder = + string >>= (fun x -> (match string_to_adjustment_opt x with + | None -> (fail "Unknown enum (Adjustment) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_adjustmenttype_decoder : fix_adjustmenttype decoder = + string >>= (fun x -> (match string_to_adjustmenttype_opt x with + | None -> (fail "Unknown enum (AdjustmentType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_advside_decoder : fix_advside decoder = + string >>= (fun x -> (match string_to_advside_opt x with + | None -> (fail "Unknown enum (AdvSide) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_advtranstype_decoder : fix_advtranstype decoder = + string >>= (fun x -> (match string_to_advtranstype_opt x with + | None -> (fail "Unknown enum (AdvTransType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_affirmstatus_decoder : fix_affirmstatus decoder = + string >>= (fun x -> (match string_to_affirmstatus_opt x with + | None -> (fail "Unknown enum (AffirmStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_aggregatedbook_decoder : fix_aggregatedbook decoder = + string >>= (fun x -> (match string_to_aggregatedbook_opt x with + | None -> (fail "Unknown enum (AggregatedBook) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_allocaccounttype_decoder : fix_allocaccounttype decoder = + string >>= (fun x -> (match string_to_allocaccounttype_opt x with + | None -> (fail "Unknown enum (AllocAccountType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_alloccancreplacereason_decoder : fix_alloccancreplacereason decoder = + string >>= (fun x -> (match string_to_alloccancreplacereason_opt x with + | None -> (fail "Unknown enum (AllocCancReplaceReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_allochandlinst_decoder : fix_allochandlinst decoder = + string >>= (fun x -> (match string_to_allochandlinst_opt x with + | None -> (fail "Unknown enum (AllocHandlInst) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_allocintermedreqtype_decoder : fix_allocintermedreqtype decoder = + string >>= (fun x -> (match string_to_allocintermedreqtype_opt x with + | None -> (fail "Unknown enum (AllocIntermedReqType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_alloclinktype_decoder : fix_alloclinktype decoder = + string >>= (fun x -> (match string_to_alloclinktype_opt x with + | None -> (fail "Unknown enum (AllocLinkType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_allocnoorderstype_decoder : fix_allocnoorderstype decoder = + string >>= (fun x -> (match string_to_allocnoorderstype_opt x with + | None -> (fail "Unknown enum (AllocNoOrdersType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_allocrejcode_decoder : fix_allocrejcode decoder = + string >>= (fun x -> (match string_to_allocrejcode_opt x with + | None -> (fail "Unknown enum (AllocRejCode) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_allocreporttype_decoder : fix_allocreporttype decoder = + string >>= (fun x -> (match string_to_allocreporttype_opt x with + | None -> (fail "Unknown enum (AllocReportType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_allocsettlinsttype_decoder : fix_allocsettlinsttype decoder = + string >>= (fun x -> (match string_to_allocsettlinsttype_opt x with + | None -> (fail "Unknown enum (AllocSettlInstType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_allocstatus_decoder : fix_allocstatus decoder = + string >>= (fun x -> (match string_to_allocstatus_opt x with + | None -> (fail "Unknown enum (AllocStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_alloctranstype_decoder : fix_alloctranstype decoder = + string >>= (fun x -> (match string_to_alloctranstype_opt x with + | None -> (fail "Unknown enum (AllocTransType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_alloctype_decoder : fix_alloctype decoder = + string >>= (fun x -> (match string_to_alloctype_opt x with + | None -> (fail "Unknown enum (AllocType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_applqueueaction_decoder : fix_applqueueaction decoder = + string >>= (fun x -> (match string_to_applqueueaction_opt x with + | None -> (fail "Unknown enum (ApplQueueAction) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_applqueueresolution_decoder : fix_applqueueresolution decoder = + string >>= (fun x -> (match string_to_applqueueresolution_opt x with + | None -> (fail "Unknown enum (ApplQueueResolution) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_assignmentmethod_decoder : fix_assignmentmethod decoder = + string >>= (fun x -> (match string_to_assignmentmethod_opt x with + | None -> (fail "Unknown enum (AssignmentMethod) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_avgpxindicator_decoder : fix_avgpxindicator decoder = + string >>= (fun x -> (match string_to_avgpxindicator_opt x with + | None -> (fail "Unknown enum (AvgPxIndicator) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_basispxtype_decoder : fix_basispxtype decoder = + string >>= (fun x -> (match string_to_basispxtype_opt x with + | None -> (fail "Unknown enum (BasisPxType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_biddescriptortype_decoder : fix_biddescriptortype decoder = + string >>= (fun x -> (match string_to_biddescriptortype_opt x with + | None -> (fail "Unknown enum (BidDescriptorType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_bidrequesttranstype_decoder : fix_bidrequesttranstype decoder = + string >>= (fun x -> (match string_to_bidrequesttranstype_opt x with + | None -> (fail "Unknown enum (BidRequestTransType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_bidtradetype_decoder : fix_bidtradetype decoder = + string >>= (fun x -> (match string_to_bidtradetype_opt x with + | None -> (fail "Unknown enum (BidTradeType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_bidtype_decoder : fix_bidtype decoder = + string >>= (fun x -> (match string_to_bidtype_opt x with + | None -> (fail "Unknown enum (BidType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_bookingtype_decoder : fix_bookingtype decoder = + string >>= (fun x -> (match string_to_bookingtype_opt x with + | None -> (fail "Unknown enum (BookingType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_bookingunit_decoder : fix_bookingunit decoder = + string >>= (fun x -> (match string_to_bookingunit_opt x with + | None -> (fail "Unknown enum (BookingUnit) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_cpprogram_decoder : fix_cpprogram decoder = + string >>= (fun x -> (match string_to_cpprogram_opt x with + | None -> (fail "Unknown enum (CPProgram) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_cancellationrights_decoder : fix_cancellationrights decoder = + string >>= (fun x -> (match string_to_cancellationrights_opt x with + | None -> (fail "Unknown enum (CancellationRights) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_cashmargin_decoder : fix_cashmargin decoder = + string >>= (fun x -> (match string_to_cashmargin_opt x with + | None -> (fail "Unknown enum (CashMargin) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_clearingfeeindicator_decoder : fix_clearingfeeindicator decoder = + string >>= (fun x -> (match string_to_clearingfeeindicator_opt x with + | None -> (fail "Unknown enum (ClearingFeeIndicator) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_clearinginstruction_decoder : fix_clearinginstruction decoder = + string >>= (fun x -> (match string_to_clearinginstruction_opt x with + | None -> (fail "Unknown enum (ClearingInstruction) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_collaction_decoder : fix_collaction decoder = + string >>= (fun x -> (match string_to_collaction_opt x with + | None -> (fail "Unknown enum (CollAction) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_collasgnreason_decoder : fix_collasgnreason decoder = + string >>= (fun x -> (match string_to_collasgnreason_opt x with + | None -> (fail "Unknown enum (CollAsgnReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_collasgnrejectreason_decoder : fix_collasgnrejectreason decoder = + string >>= (fun x -> (match string_to_collasgnrejectreason_opt x with + | None -> (fail "Unknown enum (CollAsgnRejectReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_collasgnresptype_decoder : fix_collasgnresptype decoder = + string >>= (fun x -> (match string_to_collasgnresptype_opt x with + | None -> (fail "Unknown enum (CollAsgnRespType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_collasgntranstype_decoder : fix_collasgntranstype decoder = + string >>= (fun x -> (match string_to_collasgntranstype_opt x with + | None -> (fail "Unknown enum (CollAsgnTransType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_collinquiryqualifier_decoder : fix_collinquiryqualifier decoder = + string >>= (fun x -> (match string_to_collinquiryqualifier_opt x with + | None -> (fail "Unknown enum (CollInquiryQualifier) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_collinquiryresult_decoder : fix_collinquiryresult decoder = + string >>= (fun x -> (match string_to_collinquiryresult_opt x with + | None -> (fail "Unknown enum (CollInquiryResult) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_collinquirystatus_decoder : fix_collinquirystatus decoder = + string >>= (fun x -> (match string_to_collinquirystatus_opt x with + | None -> (fail "Unknown enum (CollInquiryStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_collstatus_decoder : fix_collstatus decoder = + string >>= (fun x -> (match string_to_collstatus_opt x with + | None -> (fail "Unknown enum (CollStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_commtype_decoder : fix_commtype decoder = + string >>= (fun x -> (match string_to_commtype_opt x with + | None -> (fail "Unknown enum (CommType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_confirmrejreason_decoder : fix_confirmrejreason decoder = + string >>= (fun x -> (match string_to_confirmrejreason_opt x with + | None -> (fail "Unknown enum (ConfirmRejReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_confirmstatus_decoder : fix_confirmstatus decoder = + string >>= (fun x -> (match string_to_confirmstatus_opt x with + | None -> (fail "Unknown enum (ConfirmStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_confirmtranstype_decoder : fix_confirmtranstype decoder = + string >>= (fun x -> (match string_to_confirmtranstype_opt x with + | None -> (fail "Unknown enum (ConfirmTransType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_confirmtype_decoder : fix_confirmtype decoder = + string >>= (fun x -> (match string_to_confirmtype_opt x with + | None -> (fail "Unknown enum (ConfirmType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_contamttype_decoder : fix_contamttype decoder = + string >>= (fun x -> (match string_to_contamttype_opt x with + | None -> (fail "Unknown enum (ContAmtType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_corporateaction_decoder : fix_corporateaction list decoder = + list (string >>= (fun x -> (match string_to_corporateaction_opt x with + | None -> (fail "Unknown enum (CorporateAction) encoding.") + | Some y -> (succeed y) + ) + )) +;; + +let full_enum_coveredoruncovered_decoder : fix_coveredoruncovered decoder = + string >>= (fun x -> (match string_to_coveredoruncovered_opt x with + | None -> (fail "Unknown enum (CoveredOrUncovered) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_crossprioritization_decoder : fix_crossprioritization decoder = + string >>= (fun x -> (match string_to_crossprioritization_opt x with + | None -> (fail "Unknown enum (CrossPrioritization) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_crosstype_decoder : fix_crosstype decoder = + string >>= (fun x -> (match string_to_crosstype_opt x with + | None -> (fail "Unknown enum (CrossType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_custordercapacity_decoder : fix_custordercapacity decoder = + string >>= (fun x -> (match string_to_custordercapacity_opt x with + | None -> (fail "Unknown enum (CustOrderCapacity) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_cxlrejreason_decoder : fix_cxlrejreason decoder = + string >>= (fun x -> (match string_to_cxlrejreason_opt x with + | None -> (fail "Unknown enum (CxlRejReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_dkreason_decoder : fix_dkreason decoder = + string >>= (fun x -> (match string_to_dkreason_opt x with + | None -> (fail "Unknown enum (DKReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_daybookinginst_decoder : fix_daybookinginst decoder = + string >>= (fun x -> (match string_to_daybookinginst_opt x with + | None -> (fail "Unknown enum (DayBookingInst) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_deletereason_decoder : fix_deletereason decoder = + string >>= (fun x -> (match string_to_deletereason_opt x with + | None -> (fail "Unknown enum (DeleteReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_deliveryform_decoder : fix_deliveryform decoder = + string >>= (fun x -> (match string_to_deliveryform_opt x with + | None -> (fail "Unknown enum (DeliveryForm) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_deliverytype_decoder : fix_deliverytype decoder = + string >>= (fun x -> (match string_to_deliverytype_opt x with + | None -> (fail "Unknown enum (DeliveryType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_discretioninst_decoder : fix_discretioninst decoder = + string >>= (fun x -> (match string_to_discretioninst_opt x with + | None -> (fail "Unknown enum (DiscretionInst) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_discretionlimittype_decoder : fix_discretionlimittype decoder = + string >>= (fun x -> (match string_to_discretionlimittype_opt x with + | None -> (fail "Unknown enum (DiscretionLimitType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_discretionmovetype_decoder : fix_discretionmovetype decoder = + string >>= (fun x -> (match string_to_discretionmovetype_opt x with + | None -> (fail "Unknown enum (DiscretionMoveType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_discretionoffsettype_decoder : fix_discretionoffsettype decoder = + string >>= (fun x -> (match string_to_discretionoffsettype_opt x with + | None -> (fail "Unknown enum (DiscretionOffsetType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_discretionrounddirection_decoder : fix_discretionrounddirection decoder = + string >>= (fun x -> (match string_to_discretionrounddirection_opt x with + | None -> (fail "Unknown enum (DiscretionRoundDirection) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_discretionscope_decoder : fix_discretionscope decoder = + string >>= (fun x -> (match string_to_discretionscope_opt x with + | None -> (fail "Unknown enum (DiscretionScope) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_distribpaymentmethod_decoder : fix_distribpaymentmethod decoder = + string >>= (fun x -> (match string_to_distribpaymentmethod_opt x with + | None -> (fail "Unknown enum (DistribPaymentMethod) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_dlvyinsttype_decoder : fix_dlvyinsttype decoder = + string >>= (fun x -> (match string_to_dlvyinsttype_opt x with + | None -> (fail "Unknown enum (DlvyInstType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_duetorelated_decoder : fix_duetorelated decoder = + string >>= (fun x -> (match string_to_duetorelated_opt x with + | None -> (fail "Unknown enum (DueToRelated) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_emailtype_decoder : fix_emailtype decoder = + string >>= (fun x -> (match string_to_emailtype_opt x with + | None -> (fail "Unknown enum (EmailType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_eventtype_decoder : fix_eventtype decoder = + string >>= (fun x -> (match string_to_eventtype_opt x with + | None -> (fail "Unknown enum (EventType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_exchangeforphysical_decoder : fix_exchangeforphysical decoder = + string >>= (fun x -> (match string_to_exchangeforphysical_opt x with + | None -> (fail "Unknown enum (ExchangeForPhysical) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_execinst_decoder : fix_execinst list decoder = + list (string >>= (fun x -> (match string_to_execinst_opt x with + | None -> (fail "Unknown enum (ExecInst) encoding.") + | Some y -> (succeed y) + ) + )) +;; + +let full_enum_execpricetype_decoder : fix_execpricetype decoder = + string >>= (fun x -> (match string_to_execpricetype_opt x with + | None -> (fail "Unknown enum (ExecPriceType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_execrestatementreason_decoder : fix_execrestatementreason decoder = + string >>= (fun x -> (match string_to_execrestatementreason_opt x with + | None -> (fail "Unknown enum (ExecRestatementReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_exectype_decoder : fix_exectype decoder = + string >>= (fun x -> (match string_to_exectype_opt x with + | None -> (fail "Unknown enum (ExecType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_exercisemethod_decoder : fix_exercisemethod decoder = + string >>= (fun x -> (match string_to_exercisemethod_opt x with + | None -> (fail "Unknown enum (ExerciseMethod) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_expirationcycle_decoder : fix_expirationcycle decoder = + string >>= (fun x -> (match string_to_expirationcycle_opt x with + | None -> (fail "Unknown enum (ExpirationCycle) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_financialstatus_decoder : fix_financialstatus list decoder = + list (string >>= (fun x -> (match string_to_financialstatus_opt x with + | None -> (fail "Unknown enum (FinancialStatus) encoding.") + | Some y -> (succeed y) + ) + )) +;; + +let full_enum_forexreq_decoder : fix_forexreq decoder = + string >>= (fun x -> (match string_to_forexreq_opt x with + | None -> (fail "Unknown enum (ForexReq) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_fundrenewwaiv_decoder : fix_fundrenewwaiv decoder = + string >>= (fun x -> (match string_to_fundrenewwaiv_opt x with + | None -> (fail "Unknown enum (FundRenewWaiv) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_gtbookinginst_decoder : fix_gtbookinginst decoder = + string >>= (fun x -> (match string_to_gtbookinginst_opt x with + | None -> (fail "Unknown enum (GTBookingInst) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_haltreason_decoder : fix_haltreason decoder = + string >>= (fun x -> (match string_to_haltreason_opt x with + | None -> (fail "Unknown enum (HaltReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_handlinst_decoder : fix_handlinst decoder = + string >>= (fun x -> (match string_to_handlinst_opt x with + | None -> (fail "Unknown enum (HandlInst) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_ioinaturalflag_decoder : fix_ioinaturalflag decoder = + string >>= (fun x -> (match string_to_ioinaturalflag_opt x with + | None -> (fail "Unknown enum (IOINaturalFlag) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_ioiqltyind_decoder : fix_ioiqltyind decoder = + string >>= (fun x -> (match string_to_ioiqltyind_opt x with + | None -> (fail "Unknown enum (IOIQltyInd) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_ioiqty_decoder : fix_ioiqty decoder = + string >>= (fun x -> (match string_to_ioiqty_opt x with + | None -> (fail "Unknown enum (IOIQty) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_ioiqualifier_decoder : fix_ioiqualifier decoder = + string >>= (fun x -> (match string_to_ioiqualifier_opt x with + | None -> (fail "Unknown enum (IOIQualifier) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_ioitranstype_decoder : fix_ioitranstype decoder = + string >>= (fun x -> (match string_to_ioitranstype_opt x with + | None -> (fail "Unknown enum (IOITransType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_inviewofcommon_decoder : fix_inviewofcommon decoder = + string >>= (fun x -> (match string_to_inviewofcommon_opt x with + | None -> (fail "Unknown enum (InViewOfCommon) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_inctaxind_decoder : fix_inctaxind decoder = + string >>= (fun x -> (match string_to_inctaxind_opt x with + | None -> (fail "Unknown enum (IncTaxInd) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_instrattribtype_decoder : fix_instrattribtype decoder = + string >>= (fun x -> (match string_to_instrattribtype_opt x with + | None -> (fail "Unknown enum (InstrAttribType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_lastcapacity_decoder : fix_lastcapacity decoder = + string >>= (fun x -> (match string_to_lastcapacity_opt x with + | None -> (fail "Unknown enum (LastCapacity) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_lastfragment_decoder : fix_lastfragment decoder = + string >>= (fun x -> (match string_to_lastfragment_opt x with + | None -> (fail "Unknown enum (LastFragment) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_lastliquidityind_decoder : fix_lastliquidityind decoder = + string >>= (fun x -> (match string_to_lastliquidityind_opt x with + | None -> (fail "Unknown enum (LastLiquidityInd) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_legswaptype_decoder : fix_legswaptype decoder = + string >>= (fun x -> (match string_to_legswaptype_opt x with + | None -> (fail "Unknown enum (LegSwapType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_legalconfirm_decoder : fix_legalconfirm decoder = + string >>= (fun x -> (match string_to_legalconfirm_opt x with + | None -> (fail "Unknown enum (LegalConfirm) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_liquidityindtype_decoder : fix_liquidityindtype decoder = + string >>= (fun x -> (match string_to_liquidityindtype_opt x with + | None -> (fail "Unknown enum (LiquidityIndType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_listexecinsttype_decoder : fix_listexecinsttype decoder = + string >>= (fun x -> (match string_to_listexecinsttype_opt x with + | None -> (fail "Unknown enum (ListExecInstType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_listorderstatus_decoder : fix_listorderstatus decoder = + string >>= (fun x -> (match string_to_listorderstatus_opt x with + | None -> (fail "Unknown enum (ListOrderStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_liststatustype_decoder : fix_liststatustype decoder = + string >>= (fun x -> (match string_to_liststatustype_opt x with + | None -> (fail "Unknown enum (ListStatusType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_locatereqd_decoder : fix_locatereqd decoder = + string >>= (fun x -> (match string_to_locatereqd_opt x with + | None -> (fail "Unknown enum (LocateReqd) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_mdentrytype_decoder : fix_mdentrytype decoder = + string >>= (fun x -> (match string_to_mdentrytype_opt x with + | None -> (fail "Unknown enum (MDEntryType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_mdimplicitdelete_decoder : fix_mdimplicitdelete decoder = + string >>= (fun x -> (match string_to_mdimplicitdelete_opt x with + | None -> (fail "Unknown enum (MDImplicitDelete) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_mdreqrejreason_decoder : fix_mdreqrejreason decoder = + string >>= (fun x -> (match string_to_mdreqrejreason_opt x with + | None -> (fail "Unknown enum (MDReqRejReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_mdupdateaction_decoder : fix_mdupdateaction decoder = + string >>= (fun x -> (match string_to_mdupdateaction_opt x with + | None -> (fail "Unknown enum (MDUpdateAction) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_mdupdatetype_decoder : fix_mdupdatetype decoder = + string >>= (fun x -> (match string_to_mdupdatetype_opt x with + | None -> (fail "Unknown enum (MDUpdateType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_masscancelrejectreason_decoder : fix_masscancelrejectreason decoder = + string >>= (fun x -> (match string_to_masscancelrejectreason_opt x with + | None -> (fail "Unknown enum (MassCancelRejectReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_masscancelrequesttype_decoder : fix_masscancelrequesttype decoder = + string >>= (fun x -> (match string_to_masscancelrequesttype_opt x with + | None -> (fail "Unknown enum (MassCancelRequestType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_masscancelresponse_decoder : fix_masscancelresponse decoder = + string >>= (fun x -> (match string_to_masscancelresponse_opt x with + | None -> (fail "Unknown enum (MassCancelResponse) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_massstatusreqtype_decoder : fix_massstatusreqtype decoder = + string >>= (fun x -> (match string_to_massstatusreqtype_opt x with + | None -> (fail "Unknown enum (MassStatusReqType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_matchstatus_decoder : fix_matchstatus decoder = + string >>= (fun x -> (match string_to_matchstatus_opt x with + | None -> (fail "Unknown enum (MatchStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_matchtype_decoder : fix_matchtype decoder = + string >>= (fun x -> (match string_to_matchtype_opt x with + | None -> (fail "Unknown enum (MatchType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_messageencoding_decoder : fix_messageencoding decoder = + string >>= (fun x -> (match string_to_messageencoding_opt x with + | None -> (fail "Unknown enum (MessageEncoding) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_miscfeebasis_decoder : fix_miscfeebasis decoder = + string >>= (fun x -> (match string_to_miscfeebasis_opt x with + | None -> (fail "Unknown enum (MiscFeeBasis) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_miscfeetype_decoder : fix_miscfeetype decoder = + string >>= (fun x -> (match string_to_miscfeetype_opt x with + | None -> (fail "Unknown enum (MiscFeeType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_moneylaunderingstatus_decoder : fix_moneylaunderingstatus decoder = + string >>= (fun x -> (match string_to_moneylaunderingstatus_opt x with + | None -> (fail "Unknown enum (MoneyLaunderingStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_msgdirection_decoder : fix_msgdirection decoder = + string >>= (fun x -> (match string_to_msgdirection_opt x with + | None -> (fail "Unknown enum (MsgDirection) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_multilegreportingtype_decoder : fix_multilegreportingtype decoder = + string >>= (fun x -> (match string_to_multilegreportingtype_opt x with + | None -> (fail "Unknown enum (MultiLegReportingType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_multilegrpttypereq_decoder : fix_multilegrpttypereq decoder = + string >>= (fun x -> (match string_to_multilegrpttypereq_opt x with + | None -> (fail "Unknown enum (MultiLegRptTypeReq) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_netgrossind_decoder : fix_netgrossind decoder = + string >>= (fun x -> (match string_to_netgrossind_opt x with + | None -> (fail "Unknown enum (NetGrossInd) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_networkrequesttype_decoder : fix_networkrequesttype decoder = + string >>= (fun x -> (match string_to_networkrequesttype_opt x with + | None -> (fail "Unknown enum (NetworkRequestType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_networkstatusresponsetype_decoder : fix_networkstatusresponsetype decoder = + string >>= (fun x -> (match string_to_networkstatusresponsetype_opt x with + | None -> (fail "Unknown enum (NetworkStatusResponseType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_notifybrokerofcredit_decoder : fix_notifybrokerofcredit decoder = + string >>= (fun x -> (match string_to_notifybrokerofcredit_opt x with + | None -> (fail "Unknown enum (NotifyBrokerOfCredit) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_oddlot_decoder : fix_oddlot decoder = + string >>= (fun x -> (match string_to_oddlot_opt x with + | None -> (fail "Unknown enum (OddLot) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_openclosesettlflag_decoder : fix_openclosesettlflag list decoder = + list (string >>= (fun x -> (match string_to_openclosesettlflag_opt x with + | None -> (fail "Unknown enum (OpenCloseSettlFlag) encoding.") + | Some y -> (succeed y) + ) + )) +;; + +let full_enum_ordrejreason_decoder : fix_ordrejreason decoder = + string >>= (fun x -> (match string_to_ordrejreason_opt x with + | None -> (fail "Unknown enum (OrdRejReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_ordstatus_decoder : fix_ordstatus decoder = + string >>= (fun x -> (match string_to_ordstatus_opt x with + | None -> (fail "Unknown enum (OrdStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_ordtype_decoder : fix_ordtype decoder = + string >>= (fun x -> (match string_to_ordtype_opt x with + | None -> (fail "Unknown enum (OrdType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_ordercapacity_decoder : fix_ordercapacity decoder = + string >>= (fun x -> (match string_to_ordercapacity_opt x with + | None -> (fail "Unknown enum (OrderCapacity) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_orderrestrictions_decoder : fix_orderrestrictions list decoder = + list (string >>= (fun x -> (match string_to_orderrestrictions_opt x with + | None -> (fail "Unknown enum (OrderRestrictions) encoding.") + | Some y -> (succeed y) + ) + )) +;; + +let full_enum_ownertype_decoder : fix_ownertype decoder = + string >>= (fun x -> (match string_to_ownertype_opt x with + | None -> (fail "Unknown enum (OwnerType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_ownershiptype_decoder : fix_ownershiptype decoder = + string >>= (fun x -> (match string_to_ownershiptype_opt x with + | None -> (fail "Unknown enum (OwnershipType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_partyidsource_decoder : fix_partyidsource decoder = + string >>= (fun x -> (match string_to_partyidsource_opt x with + | None -> (fail "Unknown enum (PartyIDSource) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_partyrole_decoder : fix_partyrole decoder = + string >>= (fun x -> (match string_to_partyrole_opt x with + | None -> (fail "Unknown enum (PartyRole) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_partysubidtype_decoder : fix_partysubidtype decoder = + string >>= (fun x -> (match string_to_partysubidtype_opt x with + | None -> (fail "Unknown enum (PartySubIDType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_paymentmethod_decoder : fix_paymentmethod decoder = + string >>= (fun x -> (match string_to_paymentmethod_opt x with + | None -> (fail "Unknown enum (PaymentMethod) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_peglimittype_decoder : fix_peglimittype decoder = + string >>= (fun x -> (match string_to_peglimittype_opt x with + | None -> (fail "Unknown enum (PegLimitType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_pegmovetype_decoder : fix_pegmovetype decoder = + string >>= (fun x -> (match string_to_pegmovetype_opt x with + | None -> (fail "Unknown enum (PegMoveType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_pegoffsettype_decoder : fix_pegoffsettype decoder = + string >>= (fun x -> (match string_to_pegoffsettype_opt x with + | None -> (fail "Unknown enum (PegOffsetType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_pegrounddirection_decoder : fix_pegrounddirection decoder = + string >>= (fun x -> (match string_to_pegrounddirection_opt x with + | None -> (fail "Unknown enum (PegRoundDirection) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_pegscope_decoder : fix_pegscope decoder = + string >>= (fun x -> (match string_to_pegscope_opt x with + | None -> (fail "Unknown enum (PegScope) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_posamttype_decoder : fix_posamttype decoder = + string >>= (fun x -> (match string_to_posamttype_opt x with + | None -> (fail "Unknown enum (PosAmtType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_posmaintaction_decoder : fix_posmaintaction decoder = + string >>= (fun x -> (match string_to_posmaintaction_opt x with + | None -> (fail "Unknown enum (PosMaintAction) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_posmaintresult_decoder : fix_posmaintresult decoder = + string >>= (fun x -> (match string_to_posmaintresult_opt x with + | None -> (fail "Unknown enum (PosMaintResult) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_posmaintstatus_decoder : fix_posmaintstatus decoder = + string >>= (fun x -> (match string_to_posmaintstatus_opt x with + | None -> (fail "Unknown enum (PosMaintStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_posqtystatus_decoder : fix_posqtystatus decoder = + string >>= (fun x -> (match string_to_posqtystatus_opt x with + | None -> (fail "Unknown enum (PosQtyStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_posreqresult_decoder : fix_posreqresult decoder = + string >>= (fun x -> (match string_to_posreqresult_opt x with + | None -> (fail "Unknown enum (PosReqResult) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_posreqstatus_decoder : fix_posreqstatus decoder = + string >>= (fun x -> (match string_to_posreqstatus_opt x with + | None -> (fail "Unknown enum (PosReqStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_posreqtype_decoder : fix_posreqtype decoder = + string >>= (fun x -> (match string_to_posreqtype_opt x with + | None -> (fail "Unknown enum (PosReqType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_postranstype_decoder : fix_postranstype decoder = + string >>= (fun x -> (match string_to_postranstype_opt x with + | None -> (fail "Unknown enum (PosTransType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_postype_decoder : fix_postype decoder = + string >>= (fun x -> (match string_to_postype_opt x with + | None -> (fail "Unknown enum (PosType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_positioneffect_decoder : fix_positioneffect decoder = + string >>= (fun x -> (match string_to_positioneffect_opt x with + | None -> (fail "Unknown enum (PositionEffect) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_possdupflag_decoder : fix_possdupflag decoder = + string >>= (fun x -> (match string_to_possdupflag_opt x with + | None -> (fail "Unknown enum (PossDupFlag) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_possresend_decoder : fix_possresend decoder = + string >>= (fun x -> (match string_to_possresend_opt x with + | None -> (fail "Unknown enum (PossResend) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_preallocmethod_decoder : fix_preallocmethod decoder = + string >>= (fun x -> (match string_to_preallocmethod_opt x with + | None -> (fail "Unknown enum (PreallocMethod) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_previouslyreported_decoder : fix_previouslyreported decoder = + string >>= (fun x -> (match string_to_previouslyreported_opt x with + | None -> (fail "Unknown enum (PreviouslyReported) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_pricetype_decoder : fix_pricetype decoder = + string >>= (fun x -> (match string_to_pricetype_opt x with + | None -> (fail "Unknown enum (PriceType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_priorityindicator_decoder : fix_priorityindicator decoder = + string >>= (fun x -> (match string_to_priorityindicator_opt x with + | None -> (fail "Unknown enum (PriorityIndicator) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_processcode_decoder : fix_processcode decoder = + string >>= (fun x -> (match string_to_processcode_opt x with + | None -> (fail "Unknown enum (ProcessCode) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_product_decoder : fix_product decoder = + string >>= (fun x -> (match string_to_product_opt x with + | None -> (fail "Unknown enum (Product) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_progrptreqs_decoder : fix_progrptreqs decoder = + string >>= (fun x -> (match string_to_progrptreqs_opt x with + | None -> (fail "Unknown enum (ProgRptReqs) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_publishtrdindicator_decoder : fix_publishtrdindicator decoder = + string >>= (fun x -> (match string_to_publishtrdindicator_opt x with + | None -> (fail "Unknown enum (PublishTrdIndicator) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_putorcall_decoder : fix_putorcall decoder = + string >>= (fun x -> (match string_to_putorcall_opt x with + | None -> (fail "Unknown enum (PutOrCall) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_qtytype_decoder : fix_qtytype decoder = + string >>= (fun x -> (match string_to_qtytype_opt x with + | None -> (fail "Unknown enum (QtyType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_quotecanceltype_decoder : fix_quotecanceltype decoder = + string >>= (fun x -> (match string_to_quotecanceltype_opt x with + | None -> (fail "Unknown enum (QuoteCancelType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_quotecondition_decoder : fix_quotecondition list decoder = + list (string >>= (fun x -> (match string_to_quotecondition_opt x with + | None -> (fail "Unknown enum (QuoteCondition) encoding.") + | Some y -> (succeed y) + ) + )) +;; + +let full_enum_quotepricetype_decoder : fix_quotepricetype decoder = + string >>= (fun x -> (match string_to_quotepricetype_opt x with + | None -> (fail "Unknown enum (QuotePriceType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_quoterejectreason_decoder : fix_quoterejectreason decoder = + string >>= (fun x -> (match string_to_quoterejectreason_opt x with + | None -> (fail "Unknown enum (QuoteRejectReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_quoterequestrejectreason_decoder : fix_quoterequestrejectreason decoder = + string >>= (fun x -> (match string_to_quoterequestrejectreason_opt x with + | None -> (fail "Unknown enum (QuoteRequestRejectReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_quoterequesttype_decoder : fix_quoterequesttype decoder = + string >>= (fun x -> (match string_to_quoterequesttype_opt x with + | None -> (fail "Unknown enum (QuoteRequestType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_quoteresptype_decoder : fix_quoteresptype decoder = + string >>= (fun x -> (match string_to_quoteresptype_opt x with + | None -> (fail "Unknown enum (QuoteRespType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_quoteresponselevel_decoder : fix_quoteresponselevel decoder = + string >>= (fun x -> (match string_to_quoteresponselevel_opt x with + | None -> (fail "Unknown enum (QuoteResponseLevel) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_quotestatus_decoder : fix_quotestatus decoder = + string >>= (fun x -> (match string_to_quotestatus_opt x with + | None -> (fail "Unknown enum (QuoteStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_quotetype_decoder : fix_quotetype decoder = + string >>= (fun x -> (match string_to_quotetype_opt x with + | None -> (fail "Unknown enum (QuoteType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_registrejreasoncode_decoder : fix_registrejreasoncode decoder = + string >>= (fun x -> (match string_to_registrejreasoncode_opt x with + | None -> (fail "Unknown enum (RegistRejReasonCode) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_registstatus_decoder : fix_registstatus decoder = + string >>= (fun x -> (match string_to_registstatus_opt x with + | None -> (fail "Unknown enum (RegistStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_registtranstype_decoder : fix_registtranstype decoder = + string >>= (fun x -> (match string_to_registtranstype_opt x with + | None -> (fail "Unknown enum (RegistTransType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_reporttoexch_decoder : fix_reporttoexch decoder = + string >>= (fun x -> (match string_to_reporttoexch_opt x with + | None -> (fail "Unknown enum (ReportToExch) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_resetseqnumflag_decoder : fix_resetseqnumflag decoder = + string >>= (fun x -> (match string_to_resetseqnumflag_opt x with + | None -> (fail "Unknown enum (ResetSeqNumFlag) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_responsetransporttype_decoder : fix_responsetransporttype decoder = + string >>= (fun x -> (match string_to_responsetransporttype_opt x with + | None -> (fail "Unknown enum (ResponseTransportType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_roundingdirection_decoder : fix_roundingdirection decoder = + string >>= (fun x -> (match string_to_roundingdirection_opt x with + | None -> (fail "Unknown enum (RoundingDirection) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_routingtype_decoder : fix_routingtype decoder = + string >>= (fun x -> (match string_to_routingtype_opt x with + | None -> (fail "Unknown enum (RoutingType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_scope_decoder : fix_scope list decoder = + list (string >>= (fun x -> (match string_to_scope_opt x with + | None -> (fail "Unknown enum (Scope) encoding.") + | Some y -> (succeed y) + ) + )) +;; + +let full_enum_securityidsource_decoder : fix_securityidsource decoder = + string >>= (fun x -> (match string_to_securityidsource_opt x with + | None -> (fail "Unknown enum (SecurityIDSource) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_securitylistrequesttype_decoder : fix_securitylistrequesttype decoder = + string >>= (fun x -> (match string_to_securitylistrequesttype_opt x with + | None -> (fail "Unknown enum (SecurityListRequestType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_securityrequestresult_decoder : fix_securityrequestresult decoder = + string >>= (fun x -> (match string_to_securityrequestresult_opt x with + | None -> (fail "Unknown enum (SecurityRequestResult) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_securityrequesttype_decoder : fix_securityrequesttype decoder = + string >>= (fun x -> (match string_to_securityrequesttype_opt x with + | None -> (fail "Unknown enum (SecurityRequestType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_securityresponsetype_decoder : fix_securityresponsetype decoder = + string >>= (fun x -> (match string_to_securityresponsetype_opt x with + | None -> (fail "Unknown enum (SecurityResponseType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_securitytradingstatus_decoder : fix_securitytradingstatus decoder = + string >>= (fun x -> (match string_to_securitytradingstatus_opt x with + | None -> (fail "Unknown enum (SecurityTradingStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_securitytype_decoder : fix_securitytype decoder = + string >>= (fun x -> (match string_to_securitytype_opt x with + | None -> (fail "Unknown enum (SecurityType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_settlcurrfxratecalc_decoder : fix_settlcurrfxratecalc decoder = + string >>= (fun x -> (match string_to_settlcurrfxratecalc_opt x with + | None -> (fail "Unknown enum (SettlCurrFxRateCalc) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_settldeliverytype_decoder : fix_settldeliverytype decoder = + string >>= (fun x -> (match string_to_settldeliverytype_opt x with + | None -> (fail "Unknown enum (SettlDeliveryType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_settlinstmode_decoder : fix_settlinstmode decoder = + string >>= (fun x -> (match string_to_settlinstmode_opt x with + | None -> (fail "Unknown enum (SettlInstMode) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_settlinstreqrejcode_decoder : fix_settlinstreqrejcode decoder = + string >>= (fun x -> (match string_to_settlinstreqrejcode_opt x with + | None -> (fail "Unknown enum (SettlInstReqRejCode) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_settlinstsource_decoder : fix_settlinstsource decoder = + string >>= (fun x -> (match string_to_settlinstsource_opt x with + | None -> (fail "Unknown enum (SettlInstSource) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_settlinsttranstype_decoder : fix_settlinsttranstype decoder = + string >>= (fun x -> (match string_to_settlinsttranstype_opt x with + | None -> (fail "Unknown enum (SettlInstTransType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_settlpricetype_decoder : fix_settlpricetype decoder = + string >>= (fun x -> (match string_to_settlpricetype_opt x with + | None -> (fail "Unknown enum (SettlPriceType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_settlsessid_decoder : fix_settlsessid decoder = + string >>= (fun x -> (match string_to_settlsessid_opt x with + | None -> (fail "Unknown enum (SettlSessID) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_settltype_decoder : fix_settltype decoder = + string >>= (fun x -> (match string_to_settltype_opt x with + | None -> (fail "Unknown enum (SettlType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_shortsalereason_decoder : fix_shortsalereason decoder = + string >>= (fun x -> (match string_to_shortsalereason_opt x with + | None -> (fail "Unknown enum (ShortSaleReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_side_decoder : fix_side decoder = + string >>= (fun x -> (match string_to_side_opt x with + | None -> (fail "Unknown enum (Side) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_sidemultilegreportingtype_decoder : fix_sidemultilegreportingtype decoder = + string >>= (fun x -> (match string_to_sidemultilegreportingtype_opt x with + | None -> (fail "Unknown enum (SideMultiLegReportingType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_sidevalueind_decoder : fix_sidevalueind decoder = + string >>= (fun x -> (match string_to_sidevalueind_opt x with + | None -> (fail "Unknown enum (SideValueInd) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_solicitedflag_decoder : fix_solicitedflag decoder = + string >>= (fun x -> (match string_to_solicitedflag_opt x with + | None -> (fail "Unknown enum (SolicitedFlag) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_standinstdbtype_decoder : fix_standinstdbtype decoder = + string >>= (fun x -> (match string_to_standinstdbtype_opt x with + | None -> (fail "Unknown enum (StandInstDbType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_statusvalue_decoder : fix_statusvalue decoder = + string >>= (fun x -> (match string_to_statusvalue_opt x with + | None -> (fail "Unknown enum (StatusValue) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_stipulationtype_decoder : fix_stipulationtype decoder = + string >>= (fun x -> (match string_to_stipulationtype_opt x with + | None -> (fail "Unknown enum (StipulationType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_subscriptionrequesttype_decoder : fix_subscriptionrequesttype decoder = + string >>= (fun x -> (match string_to_subscriptionrequesttype_opt x with + | None -> (fail "Unknown enum (SubscriptionRequestType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_targetstrategy_decoder : fix_targetstrategy decoder = + string >>= (fun x -> (match string_to_targetstrategy_opt x with + | None -> (fail "Unknown enum (TargetStrategy) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_taxadvantagetype_decoder : fix_taxadvantagetype decoder = + string >>= (fun x -> (match string_to_taxadvantagetype_opt x with + | None -> (fail "Unknown enum (TaxAdvantageType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_terminationtype_decoder : fix_terminationtype decoder = + string >>= (fun x -> (match string_to_terminationtype_opt x with + | None -> (fail "Unknown enum (TerminationType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_testmessageindicator_decoder : fix_testmessageindicator decoder = + string >>= (fun x -> (match string_to_testmessageindicator_opt x with + | None -> (fail "Unknown enum (TestMessageIndicator) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_tickdirection_decoder : fix_tickdirection decoder = + string >>= (fun x -> (match string_to_tickdirection_opt x with + | None -> (fail "Unknown enum (TickDirection) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_timeinforce_decoder : fix_timeinforce decoder = + string >>= (fun x -> (match string_to_timeinforce_opt x with + | None -> (fail "Unknown enum (TimeInForce) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_tradsesmethod_decoder : fix_tradsesmethod decoder = + string >>= (fun x -> (match string_to_tradsesmethod_opt x with + | None -> (fail "Unknown enum (TradSesMethod) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_tradsesmode_decoder : fix_tradsesmode decoder = + string >>= (fun x -> (match string_to_tradsesmode_opt x with + | None -> (fail "Unknown enum (TradSesMode) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_tradsesstatus_decoder : fix_tradsesstatus decoder = + string >>= (fun x -> (match string_to_tradsesstatus_opt x with + | None -> (fail "Unknown enum (TradSesStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_tradsesstatusrejreason_decoder : fix_tradsesstatusrejreason decoder = + string >>= (fun x -> (match string_to_tradsesstatusrejreason_opt x with + | None -> (fail "Unknown enum (TradSesStatusRejReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_tradeallocindicator_decoder : fix_tradeallocindicator decoder = + string >>= (fun x -> (match string_to_tradeallocindicator_opt x with + | None -> (fail "Unknown enum (TradeAllocIndicator) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_tradecondition_decoder : fix_tradecondition list decoder = + list (string >>= (fun x -> (match string_to_tradecondition_opt x with + | None -> (fail "Unknown enum (TradeCondition) encoding.") + | Some y -> (succeed y) + ) + )) +;; + +let full_enum_tradereportrejectreason_decoder : fix_tradereportrejectreason decoder = + string >>= (fun x -> (match string_to_tradereportrejectreason_opt x with + | None -> (fail "Unknown enum (TradeReportRejectReason) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_tradereporttype_decoder : fix_tradereporttype decoder = + string >>= (fun x -> (match string_to_tradereporttype_opt x with + | None -> (fail "Unknown enum (TradeReportType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_traderequestresult_decoder : fix_traderequestresult decoder = + string >>= (fun x -> (match string_to_traderequestresult_opt x with + | None -> (fail "Unknown enum (TradeRequestResult) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_traderequeststatus_decoder : fix_traderequeststatus decoder = + string >>= (fun x -> (match string_to_traderequeststatus_opt x with + | None -> (fail "Unknown enum (TradeRequestStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_traderequesttype_decoder : fix_traderequesttype decoder = + string >>= (fun x -> (match string_to_traderequesttype_opt x with + | None -> (fail "Unknown enum (TradeRequestType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_tradedflatswitch_decoder : fix_tradedflatswitch decoder = + string >>= (fun x -> (match string_to_tradedflatswitch_opt x with + | None -> (fail "Unknown enum (TradedFlatSwitch) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_trdregtimestamptype_decoder : fix_trdregtimestamptype decoder = + string >>= (fun x -> (match string_to_trdregtimestamptype_opt x with + | None -> (fail "Unknown enum (TrdRegTimestampType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_trdrptstatus_decoder : fix_trdrptstatus decoder = + string >>= (fun x -> (match string_to_trdrptstatus_opt x with + | None -> (fail "Unknown enum (TrdRptStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_trdtype_decoder : fix_trdtype decoder = + string >>= (fun x -> (match string_to_trdtype_opt x with + | None -> (fail "Unknown enum (TrdType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_unsolicitedindicator_decoder : fix_unsolicitedindicator decoder = + string >>= (fun x -> (match string_to_unsolicitedindicator_opt x with + | None -> (fail "Unknown enum (UnsolicitedIndicator) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_urgency_decoder : fix_urgency decoder = + string >>= (fun x -> (match string_to_urgency_opt x with + | None -> (fail "Unknown enum (Urgency) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_userrequesttype_decoder : fix_userrequesttype decoder = + string >>= (fun x -> (match string_to_userrequesttype_opt x with + | None -> (fail "Unknown enum (UserRequestType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_userstatus_decoder : fix_userstatus decoder = + string >>= (fun x -> (match string_to_userstatus_opt x with + | None -> (fail "Unknown enum (UserStatus) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_workingindicator_decoder : fix_workingindicator decoder = + string >>= (fun x -> (match string_to_workingindicator_opt x with + | None -> (fail "Unknown enum (WorkingIndicator) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let full_enum_yieldtype_decoder : fix_yieldtype decoder = + string >>= (fun x -> (match string_to_yieldtype_opt x with + | None -> (fail "Unknown enum (YieldType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +[@@@logic] diff --git a/src-protocol-exts-pp/full_app_messages_decoder.iml b/src-protocol-exts-pp/full_app_messages_decoder.iml new file mode 100644 index 00000000..95ea176b --- /dev/null +++ b/src-protocol-exts-pp/full_app_messages_decoder.iml @@ -0,0 +1,16 @@ +(* Imandra Inc. copyright 2021 *) +[@@@program] +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode;; +[@@@import "../src-protocol-exts/full_app_messages.iml"] +open Full_app_messages;; + + +let full_app_msg_of_json : full_app_msg_data decoder = + single_field (fun x -> (match x with + | d -> (fail ("Unknown Message ("^d^") in JSON decoding.")) + ) + ) +;; + +[@@@logic] diff --git a/src-protocol-exts-pp/full_app_records_decoder.iml b/src-protocol-exts-pp/full_app_records_decoder.iml new file mode 100644 index 00000000..10f646ca --- /dev/null +++ b/src-protocol-exts-pp/full_app_records_decoder.iml @@ -0,0 +1,5 @@ +(* Imandra Inc. copyright 2021 *) +[@@@program] + + +[@@@logic] diff --git a/src-protocol-exts-pp/full_app_tags_decoder.iml b/src-protocol-exts-pp/full_app_tags_decoder.iml new file mode 100644 index 00000000..83019056 --- /dev/null +++ b/src-protocol-exts-pp/full_app_tags_decoder.iml @@ -0,0 +1,55 @@ +(* Imandra Inc. copyright 2021 *) +[@@@program] +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode;; +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode.Infix;; +[@@@import "../src-protocol-exts/full_app_tags.iml"] +open Full_app_tags;; + + +let full_app_string_to_msg_tag (tag) = + (match tag with + | _ -> None + ) +;; + +let full_app_string_to_field_tag (tag) = + (match tag with + | _ -> None + ) +;; + +let full_app_msg_tag_of_json : full_app_msg_tag decoder = + string >>= (fun x -> (match full_app_string_to_msg_tag x with + | None -> (fail ("Unknown Tag: "^x)) + | Some x -> (succeed x) + ) + ) +;; + +let full_app_msg_tag_opt_of_json : full_app_msg_tag option decoder = + (maybe string) >>= (fun x -> (match x with + | None -> (succeed None) + | Some x -> (succeed (full_app_string_to_msg_tag x)) + ) + ) +;; + +let full_app_field_tag_of_json : full_app_field_tag decoder = + string >>= (fun x -> (match full_app_string_to_field_tag x with + | None -> (fail ("Unknown Tag: "^x)) + | Some x -> (succeed x) + ) + ) +;; + +let full_app_field_tag_opt_of_json : full_app_field_tag option decoder = + (maybe string) >>= (fun x -> (match x with + | None -> (succeed None) + | Some x -> (succeed (full_app_string_to_field_tag x)) + ) + ) +;; + +[@@@logic] diff --git a/src-protocol-exts/full_app_enums.iml b/src-protocol-exts/full_app_enums.iml index 3a7ad026..958a7680 100644 --- a/src-protocol-exts/full_app_enums.iml +++ b/src-protocol-exts/full_app_enums.iml @@ -2616,4 +2616,4 @@ type fix_exchange = | FIX_Exchange_XJAS | FIX_Exchange_XSHG | FIX_Exchange_SHSC -;; +;; \ No newline at end of file diff --git a/src-protocol-pp/full_admin_messages_decoder.iml b/src-protocol-pp/full_admin_messages_decoder.iml index 216b83bc..c7ec27a1 100644 --- a/src-protocol-pp/full_admin_messages_decoder.iml +++ b/src-protocol-pp/full_admin_messages_decoder.iml @@ -22,7 +22,7 @@ let full_msg_heartbeat_decoder : full_msg_heartbeat_data D.decoder = let full_msg_types_inner_rg_decoder : full_msg_types_inner_rg D.decoder = let open D in - field "mtps_ref_msg_type" full_admin_msg_tag_of_json >>= fun mtps_ref_msg_type -> + field "mtps_ref_msg_type" full_app_msg_tag_of_json >>= fun mtps_ref_msg_type -> field "mtps_direction" full_admin_enum_fix_msgdirection_decoder >>= fun mtps_direction -> D.succeed {mtps_ref_msg_type;mtps_direction} ;; From 6c57c422f8f54bbe293021a7cf74ac73b57ca43f Mon Sep 17 00:00:00 2001 From: Ewen Maclean Date: Thu, 8 Apr 2021 16:36:51 +0100 Subject: [PATCH 3/9] wip:regen with simple.ipl to get latest codegen --- src-core-fresh/fresh.iml | 77 +- src-model/src-conversions/dune | 12 +- src-model/src-conversions/enum_converter.iml | 360 +- .../src-conversions/record_converter.iml | 4 +- .../repeating_groups_converter.iml | 353 +- src-model/src-conversions/type_converter.iml | 707 +-- src-model/src-string-factory/dune | 12 +- .../src-string-factory/enum_tag_assoc.iml | 142 +- .../src-string-factory/model_tag_names.iml | 27 +- src-model/src-string-factory/string_assoc.iml | 2 +- .../string_assoc_common.iml | 270 +- .../src-string-factory/string_checks.iml | 228 +- src-model/src-strings-venue/dune | 12 +- .../src-strings-venue/model_enum_names.iml | 290 +- src-model/src-types-pp/dune | 13 +- src-model/src-types-pp/json_to_action.iml | 9 +- src-model/src-types-pp/json_to_enum.iml | 30 +- src-model/src-types-pp/json_to_internal.iml | 70 +- src-model/src-types-pp/json_to_message.iml | 115 +- .../src-types-pp/json_to_model_state.iml | 23 +- src-model/src-types-pp/json_to_model_tag.iml | 29 +- src-model/src-types-pp/json_to_records.iml | 30 +- .../src-types-pp/json_to_repeating_group.iml | 60 +- src-model/src-types-pp/model_actions_json.iml | 14 +- src-model/src-types-pp/model_enums_json.iml | 51 +- .../src-types-pp/model_internals_json.iml | 58 +- .../src-types-pp/model_messages_json.iml | 107 +- src-model/src-types-pp/model_records_json.iml | 34 +- .../model_repeating_groups_json.iml | 38 +- src-model/src-types-pp/model_state_json.iml | 14 +- src-model/src-types-pp/model_tags_json.iml | 39 +- .../src-types-pp/scenario_event_json.iml | 10 +- src-model/src-types/actions.iml | 12 +- src-model/src-types/dune | 12 +- src-model/src-types/model_app_enums.iml | 112 +- src-model/src-types/model_messages.iml | 130 +- src-model/src-types/model_records.iml | 17 +- .../src-types/model_repeating_groups.iml | 122 +- src-model/src-types/model_tags.iml | 19 +- src-model/src-types/state.iml | 81 +- src-model/src/act_checks.iml | 45 +- src-model/src/act_process.iml | 117 +- src-model/src/dune | 12 +- src-model/src/good_functions.iml | 43 +- src-model/src/ipl_functions.iml | 18 +- src-model/src/ipl_loop_util_functions.iml | 3 +- src-model/src/msg_check_fields.iml | 159 +- src-model/src/msg_check_types.iml | 57 +- src-model/src/msg_check_validate.iml | 114 +- src-model/src/msg_defaults.iml | 29 +- src-model/src/msg_process.iml | 163 +- src-model/src/msg_receive.iml | 97 +- src-model/src/msg_reject.iml | 234 +- src-model/src/venue.iml | 52 +- src-protocol-exts-pp/dune | 12 +- src-protocol-exts-pp/encode_app_enums.iml | 2911 +-------- src-protocol-exts-pp/encode_app_messages.iml | 26 +- src-protocol-exts-pp/encode_app_records.iml | 424 +- src-protocol-exts-pp/encode_app_tags.iml | 403 +- src-protocol-exts-pp/encode_utils.iml | 8 +- .../full_app_enums_decoder.iml | 5092 +-------------- src-protocol-exts-pp/full_app_enums_json.iml | 5623 +---------------- .../full_app_messages_decoder.iml | 66 + .../full_app_messages_json.iml | 39 +- .../full_app_records_decoder.iml | 47 + .../full_app_records_json.iml | 841 +-- .../full_app_tags_decoder.iml | 23 +- src-protocol-exts-pp/full_app_tags_json.iml | 383 +- src-protocol-exts-pp/json_generator_utils.iml | 7 +- src-protocol-exts-pp/parse_app_enums.iml | 3224 +--------- src-protocol-exts-pp/parse_app_messages.iml | 450 +- src-protocol-exts-pp/parse_app_records.iml | 2686 +------- src-protocol-exts-pp/parse_app_tags.iml | 380 +- src-protocol-exts/dune | 12 +- src-protocol-exts/full_app_enums.iml | 2488 +------- src-protocol-exts/full_app_messages.iml | 411 +- src-protocol-exts/full_app_records.iml | 2016 +----- src-protocol-exts/full_app_tags.iml | 380 +- .../full_admin_messages_decoder.iml | 161 +- src-protocol-pp/full_message_tags_decoder.iml | 42 + src-protocol-pp/full_message_tags_json.iml | 12 +- vgs/templates/basis_files.iml | 771 ++- vgs/templates/dune | 12 +- vgs/templates/scenario.iml | 84 +- vgs/templates/scenario_type.iml | 5 +- vgs/templates/template.iml | 25 +- vgs/templates/validation_functions.iml | 17 +- 87 files changed, 5868 insertions(+), 28101 deletions(-) create mode 100644 src-protocol-pp/full_message_tags_decoder.iml diff --git a/src-core-fresh/fresh.iml b/src-core-fresh/fresh.iml index 1c834807..df6e0ae6 100644 --- a/src-core-fresh/fresh.iml +++ b/src-core-fresh/fresh.iml @@ -1,37 +1,64 @@ -(** fresh helper functions. *) -(*** - Imandra Inc. - Copyright (c) 2014 - 2020 - fresh.iml -*) -[@@@import "../src-core-time-defaults-pp/time_defaults_current_time.iml"];; -[@@@import "../src-core-utils-pp/current_time.iml"];; -[@@@import "../src-core/numeric.iml"];; -[@@@import "../src-core-time-defaults/time_defaults.iml"];; +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-core/numeric.iml"] +open Numeric;; +[@@@import "../src-core-time-defaults-pp/time_defaults_current_time.iml"] +open Time_defaults_current_time;; -let count_string = ref 0;; + +let fresh_strings_db : ('a, 'a) Hashtbl.t = Hashtbl.create 32i ;; +let count_string = ref 0;; +let fresh_ints_db : ('a, 'a) Hashtbl.t = Hashtbl.create 32i ;; let count_int = ref 0;; -let count_float = ref (Numeric.Float_6 0);; +let fresh_floats_db : ('a, 'a) Hashtbl.t = Hashtbl.create 32i ;; +let count_float = ref (float_Create_6 0);; +let fresh_now_db : ('a, 'a) Hashtbl.t = Hashtbl.create 32i ;; +let count_now = ref (get_current_utctimestamp ());; + -let incr_string () = - count_string := !count_string + 1; - Z.to_string !count_string +let incr_string seed = + match Hashtbl.find fresh_strings_db seed with + | s -> s + | exception Not_found -> + let prev = !count_string in + count_string := prev + 1; + let s = Z.to_string !count_string in + Hashtbl.add fresh_strings_db seed s; + s ;; -let incr_int () = - count_int := !count_int + 1; - !count_int +let incr_int seed = + match Hashtbl.find fresh_ints_db seed with + | i -> i + | exception Not_found -> + let prev = !count_int in + count_int := prev + 1; + let i = !count_int in + Hashtbl.add fresh_ints_db seed i; + i ;; -let incr_float () = - count_float := Numeric.float_Add_6_6 !count_float (Numeric.Float_6 1); - !count_float;; +let incr_float seed = + match Hashtbl.find fresh_floats_db seed with + | f -> f + | exception Not_found -> + let prev = !count_float in + count_float := float_Add_6_6 !count_float (float_Create_6 1); + let f = !count_float in + Hashtbl.add fresh_floats_db seed f; + f +;; -let now_UTCTimestamp () = - Time_defaults_current_time.get_current_utctimestamp () - [@@opaque] [@@logic] +let incr_UTCTimestamp seed = + match Hashtbl.find fresh_now_db seed with + | n -> n + | exception Not_found -> + let prev = !count_now in + count_now := get_current_utctimestamp (); + let n = !count_now in + Hashtbl.add fresh_now_db seed n; + n ;; -[@@@logic] +[@@@logic] diff --git a/src-model/src-conversions/dune b/src-model/src-conversions/dune index 6150ebbf..06934ab5 100644 --- a/src-model/src-conversions/dune +++ b/src-model/src-conversions/dune @@ -1,7 +1,7 @@ (library - (name conversions) - (public_name fix-engine.conversions) - (wrapped false) - (flags - (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) - (libraries imandra-prelude protocol_exts venue_types)) + (name conversions) + (public_name fix-engine.conversions) + (wrapped false) + (flags (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) + (libraries imandra-prelude protocol_exts venue_strings_venue venue_types) +) diff --git a/src-model/src-conversions/enum_converter.iml b/src-model/src-conversions/enum_converter.iml index 33f384c1..44e96f46 100644 --- a/src-model/src-conversions/enum_converter.iml +++ b/src-model/src-conversions/enum_converter.iml @@ -1,5 +1,4 @@ -(* Imandra Inc. copyright 2020 *) -[@@@program] +(* Imandra Inc. copyright 2021 *) [@@@import "../../src-protocol-exts/full_app_enums.iml"] open Full_app_enums;; [@@@import "../src-types/model_app_enums.iml"] @@ -8,86 +7,186 @@ open Model_app_enums;; let convert__full_to_model_Side (f : fix_side) = (match f with - | FIX_Side_Buy -> MOD_FIX_Side_Buy - | FIX_Side_Sell -> MOD_FIX_Side_Sell - | FIX_Side_BuyMinus -> MOD_FIX_Side_BuyMinus - | FIX_Side_SellPlus -> MOD_FIX_Side_SellPlus - | FIX_Side_SellShort -> MOD_FIX_Side_SellShort - | FIX_Side_SellShortExempt -> MOD_FIX_Side_SellShortExempt - | FIX_Side_Undisclosed -> MOD_FIX_Side_Undisclosed - | FIX_Side_Cross -> MOD_FIX_Side_Cross - | FIX_Side_CrossShort -> MOD_FIX_Side_CrossShort - | FIX_Side_CrossShortExempt -> MOD_FIX_Side_CrossShortExempt - | FIX_Side_AsDefined -> MOD_FIX_Side_AsDefined - | FIX_Side_Opposite -> MOD_FIX_Side_Opposite - | FIX_Side_Subscribe -> MOD_FIX_Side_Subscribe - | FIX_Side_Redeem -> MOD_FIX_Side_Redeem - | FIX_Side_Lend -> MOD_FIX_Side_Lend - | FIX_Side_Borrow -> MOD_FIX_Side_Borrow + | FIX_Side_Buy -> (Some MOD_FIX_Side_Buy) + | FIX_Side_Sell -> (Some MOD_FIX_Side_Sell) + | FIX_Side_BuyMinus -> (Some MOD_FIX_Side_BuyMinus) + | FIX_Side_SellPlus -> (Some MOD_FIX_Side_SellPlus) + | FIX_Side_SellShort -> (Some MOD_FIX_Side_SellShort) + | FIX_Side_SellShortExempt -> (Some MOD_FIX_Side_SellShortExempt) + | FIX_Side_Undisclosed -> (Some MOD_FIX_Side_Undisclosed) + | FIX_Side_Cross -> (Some MOD_FIX_Side_Cross) + | FIX_Side_CrossShort -> (Some MOD_FIX_Side_CrossShort) + | FIX_Side_CrossShortExempt -> (Some MOD_FIX_Side_CrossShortExempt) + | FIX_Side_AsDefined -> (Some MOD_FIX_Side_AsDefined) + | FIX_Side_Opposite -> (Some MOD_FIX_Side_Opposite) + | FIX_Side_Subscribe -> (Some MOD_FIX_Side_Subscribe) + | FIX_Side_Redeem -> (Some MOD_FIX_Side_Redeem) + | FIX_Side_Lend -> (Some MOD_FIX_Side_Lend) + | FIX_Side_Borrow -> (Some MOD_FIX_Side_Borrow) + | FIX_INVALID_Side _ -> (None) + ) +;; + +let convert__full_to_model_OrdType (f : fix_ordtype) = + (match f with + | FIX_OrdType_Market -> (Some MOD_FIX_OrdType_Market) + | FIX_OrdType_Limit -> (Some MOD_FIX_OrdType_Limit) + | FIX_OrdType_Stop -> (Some MOD_FIX_OrdType_Stop) + | FIX_OrdType_StopLimit -> (Some MOD_FIX_OrdType_StopLimit) + | FIX_OrdType_WithOrWithout -> (Some MOD_FIX_OrdType_WithOrWithout) + | FIX_OrdType_LimitOrBetter -> (Some MOD_FIX_OrdType_LimitOrBetter) + | FIX_OrdType_LimitWithOrWithout -> (Some MOD_FIX_OrdType_LimitWithOrWithout) + | FIX_OrdType_OnBasis -> (Some MOD_FIX_OrdType_OnBasis) + | FIX_OrdType_PreviouslyQuoted -> (Some MOD_FIX_OrdType_PreviouslyQuoted) + | FIX_OrdType_PreviouslyIndicated -> (Some MOD_FIX_OrdType_PreviouslyIndicated) + | FIX_OrdType_ForexSwap -> (Some MOD_FIX_OrdType_ForexSwap) + | FIX_OrdType_Funari -> (Some MOD_FIX_OrdType_Funari) + | FIX_OrdType_MarketIfTouched -> (Some MOD_FIX_OrdType_MarketIfTouched) + | FIX_OrdType_MarketWithLeftOverAsLimit -> (Some MOD_FIX_OrdType_MarketWithLeftOverAsLimit) + | FIX_OrdType_PreviousFundValuationPoint -> (Some MOD_FIX_OrdType_PreviousFundValuationPoint) + | FIX_OrdType_NextFundValuationPoint -> (Some MOD_FIX_OrdType_NextFundValuationPoint) + | FIX_OrdType_Pegged -> (Some MOD_FIX_OrdType_Pegged) + | FIX_OrdType_StopSpread -> (Some MOD_FIX_OrdType_StopSpread) + | FIX_INVALID_OrdType _ -> (None) + ) +;; + +let convert_inner_full_to_model_ExecInst (f) = + (match f with + | FIX_ExecInst_NotHeld -> (Some MOD_FIX_ExecInst_NotHeld) + | FIX_ExecInst_Work -> (Some MOD_FIX_ExecInst_Work) + | FIX_ExecInst_GoAlong -> (Some MOD_FIX_ExecInst_GoAlong) + | FIX_ExecInst_OverTheDay -> (Some MOD_FIX_ExecInst_OverTheDay) + | FIX_ExecInst_Held -> (Some MOD_FIX_ExecInst_Held) + | FIX_ExecInst_ParticipateDoNotInitiate -> (Some MOD_FIX_ExecInst_ParticipateDoNotInitiate) + | FIX_ExecInst_StrictScale -> (Some MOD_FIX_ExecInst_StrictScale) + | FIX_ExecInst_TryToScale -> (Some MOD_FIX_ExecInst_TryToScale) + | FIX_ExecInst_StayOnBidSide -> (Some MOD_FIX_ExecInst_StayOnBidSide) + | FIX_ExecInst_StayOnOfferSide -> (Some MOD_FIX_ExecInst_StayOnOfferSide) + | FIX_ExecInst_NoCross -> (Some MOD_FIX_ExecInst_NoCross) + | FIX_ExecInst_OKToCross -> (Some MOD_FIX_ExecInst_OKToCross) + | FIX_ExecInst_CallFirst -> (Some MOD_FIX_ExecInst_CallFirst) + | FIX_ExecInst_PercentOfVolume -> (Some MOD_FIX_ExecInst_PercentOfVolume) + | FIX_ExecInst_DoNotIncrease -> (Some MOD_FIX_ExecInst_DoNotIncrease) + | FIX_ExecInst_DoNotReduce -> (Some MOD_FIX_ExecInst_DoNotReduce) + | FIX_ExecInst_AllOrNone -> (Some MOD_FIX_ExecInst_AllOrNone) + | FIX_ExecInst_ReinstateOnSystemFailure -> (Some MOD_FIX_ExecInst_ReinstateOnSystemFailure) + | FIX_ExecInst_InstitutionsOnly -> (Some MOD_FIX_ExecInst_InstitutionsOnly) + | FIX_ExecInst_ReinstateOnTradingHalt -> (Some MOD_FIX_ExecInst_ReinstateOnTradingHalt) + | FIX_ExecInst_CancelOnTradingHalt -> (Some MOD_FIX_ExecInst_CancelOnTradingHalt) + | FIX_ExecInst_LastPeg -> (Some MOD_FIX_ExecInst_LastPeg) + | FIX_ExecInst_MidPricePeg -> (Some MOD_FIX_ExecInst_MidPricePeg) + | FIX_ExecInst_NonNegotiable -> (Some MOD_FIX_ExecInst_NonNegotiable) + | FIX_ExecInst_OpeningPeg -> (Some MOD_FIX_ExecInst_OpeningPeg) + | FIX_ExecInst_MarketPeg -> (Some MOD_FIX_ExecInst_MarketPeg) + | FIX_ExecInst_CancelOnSystemFailure -> (Some MOD_FIX_ExecInst_CancelOnSystemFailure) + | FIX_ExecInst_PrimaryPeg -> (Some MOD_FIX_ExecInst_PrimaryPeg) + | FIX_ExecInst_Suspend -> (Some MOD_FIX_ExecInst_Suspend) + | FIX_ExecInst_CustomerDisplayInstruction -> (Some MOD_FIX_ExecInst_CustomerDisplayInstruction) + | FIX_ExecInst_Netting -> (Some MOD_FIX_ExecInst_Netting) + | FIX_ExecInst_PegToVWAP -> (Some MOD_FIX_ExecInst_PegToVWAP) + | FIX_ExecInst_TradeAlong -> (Some MOD_FIX_ExecInst_TradeAlong) + | FIX_ExecInst_TryToStop -> (Some MOD_FIX_ExecInst_TryToStop) + | FIX_ExecInst_CancelIfNotBest -> (Some MOD_FIX_ExecInst_CancelIfNotBest) + | FIX_ExecInst_TrailingStopPeg -> (Some MOD_FIX_ExecInst_TrailingStopPeg) + | FIX_ExecInst_StrictLimit -> (Some MOD_FIX_ExecInst_StrictLimit) + | FIX_ExecInst_IgnorePriceValidityChecks -> (Some MOD_FIX_ExecInst_IgnorePriceValidityChecks) + | FIX_ExecInst_PegToLimitPrice -> (Some MOD_FIX_ExecInst_PegToLimitPrice) + | FIX_ExecInst_WorkToTargetStrategy -> (Some MOD_FIX_ExecInst_WorkToTargetStrategy) + | FIX_INVALID_ExecInst _ -> (None) + ) +;; + +let rec convert__full_to_model_ExecInst (f) : (model_fix_execinst,bool) Map.t option = + (match f with + | [] -> (Some (Map.const false)) + | h :: t -> let s = convert_inner_full_to_model_ExecInst h + in + (match s with + | None -> (None) + | Some s -> let x = convert__full_to_model_ExecInst t + in + (match x with + | None -> (None) + | Some x -> (Some (Map.add s true x)) + ) + ) ) ;; let convert__full_to_model_ExecType (f : fix_exectype) = (match f with - | FIX_ExecType_New -> MOD_FIX_ExecType_New - | FIX_ExecType_DoneForDay -> MOD_FIX_ExecType_DoneForDay - | FIX_ExecType_Canceled -> MOD_FIX_ExecType_Canceled - | FIX_ExecType_Replaced -> MOD_FIX_ExecType_Replaced - | FIX_ExecType_PendingCancel -> MOD_FIX_ExecType_PendingCancel - | FIX_ExecType_Stopped -> MOD_FIX_ExecType_Stopped - | FIX_ExecType_Rejected -> MOD_FIX_ExecType_Rejected - | FIX_ExecType_Suspended -> MOD_FIX_ExecType_Suspended - | FIX_ExecType_PendingNew -> MOD_FIX_ExecType_PendingNew - | FIX_ExecType_Calculated -> MOD_FIX_ExecType_Calculated - | FIX_ExecType_Expired -> MOD_FIX_ExecType_Expired - | FIX_ExecType_Restated -> MOD_FIX_ExecType_Restated - | FIX_ExecType_PendingReplace -> MOD_FIX_ExecType_PendingReplace - | FIX_ExecType_Trade -> MOD_FIX_ExecType_Trade - | FIX_ExecType_TradeCorrect -> MOD_FIX_ExecType_TradeCorrect - | FIX_ExecType_TradeCancel -> MOD_FIX_ExecType_TradeCancel - | FIX_ExecType_OrderStatus -> MOD_FIX_ExecType_OrderStatus + | FIX_ExecType_New -> (Some MOD_FIX_ExecType_New) + | FIX_ExecType_DoneForDay -> (Some MOD_FIX_ExecType_DoneForDay) + | FIX_ExecType_Canceled -> (Some MOD_FIX_ExecType_Canceled) + | FIX_ExecType_Replaced -> (Some MOD_FIX_ExecType_Replaced) + | FIX_ExecType_PendingCancel -> (Some MOD_FIX_ExecType_PendingCancel) + | FIX_ExecType_Stopped -> (Some MOD_FIX_ExecType_Stopped) + | FIX_ExecType_Rejected -> (Some MOD_FIX_ExecType_Rejected) + | FIX_ExecType_Suspended -> (Some MOD_FIX_ExecType_Suspended) + | FIX_ExecType_PendingNew -> (Some MOD_FIX_ExecType_PendingNew) + | FIX_ExecType_Calculated -> (Some MOD_FIX_ExecType_Calculated) + | FIX_ExecType_Expired -> (Some MOD_FIX_ExecType_Expired) + | FIX_ExecType_Restated -> (Some MOD_FIX_ExecType_Restated) + | FIX_ExecType_PendingReplace -> (Some MOD_FIX_ExecType_PendingReplace) + | FIX_ExecType_Trade -> (Some MOD_FIX_ExecType_Trade) + | FIX_ExecType_TradeCorrect -> (Some MOD_FIX_ExecType_TradeCorrect) + | FIX_ExecType_TradeCancel -> (Some MOD_FIX_ExecType_TradeCancel) + | FIX_ExecType_OrderStatus -> (Some MOD_FIX_ExecType_OrderStatus) + | FIX_INVALID_ExecType _ -> (None) ) ;; let convert__full_to_model_OrdStatus (f : fix_ordstatus) = (match f with - | FIX_OrdStatus_New -> MOD_FIX_OrdStatus_New - | FIX_OrdStatus_PartiallyFilled -> MOD_FIX_OrdStatus_PartiallyFilled - | FIX_OrdStatus_Filled -> MOD_FIX_OrdStatus_Filled - | FIX_OrdStatus_DoneForDay -> MOD_FIX_OrdStatus_DoneForDay - | FIX_OrdStatus_Canceled -> MOD_FIX_OrdStatus_Canceled - | FIX_OrdStatus_PendingCancel -> MOD_FIX_OrdStatus_PendingCancel - | FIX_OrdStatus_Stopped -> MOD_FIX_OrdStatus_Stopped - | FIX_OrdStatus_Rejected -> MOD_FIX_OrdStatus_Rejected - | FIX_OrdStatus_Suspended -> MOD_FIX_OrdStatus_Suspended - | FIX_OrdStatus_PendingNew -> MOD_FIX_OrdStatus_PendingNew - | FIX_OrdStatus_Calculated -> MOD_FIX_OrdStatus_Calculated - | FIX_OrdStatus_Expired -> MOD_FIX_OrdStatus_Expired - | FIX_OrdStatus_AcceptedForBidding -> MOD_FIX_OrdStatus_AcceptedForBidding - | FIX_OrdStatus_PendingReplace -> MOD_FIX_OrdStatus_PendingReplace - | FIX_OrdStatus_Replaced -> MOD_FIX_OrdStatus_Replaced + | FIX_OrdStatus_New -> (Some MOD_FIX_OrdStatus_New) + | FIX_OrdStatus_PartiallyFilled -> (Some MOD_FIX_OrdStatus_PartiallyFilled) + | FIX_OrdStatus_Filled -> (Some MOD_FIX_OrdStatus_Filled) + | FIX_OrdStatus_DoneForDay -> (Some MOD_FIX_OrdStatus_DoneForDay) + | FIX_OrdStatus_Canceled -> (Some MOD_FIX_OrdStatus_Canceled) + | FIX_OrdStatus_PendingCancel -> (Some MOD_FIX_OrdStatus_PendingCancel) + | FIX_OrdStatus_Stopped -> (Some MOD_FIX_OrdStatus_Stopped) + | FIX_OrdStatus_Rejected -> (Some MOD_FIX_OrdStatus_Rejected) + | FIX_OrdStatus_Suspended -> (Some MOD_FIX_OrdStatus_Suspended) + | FIX_OrdStatus_PendingNew -> (Some MOD_FIX_OrdStatus_PendingNew) + | FIX_OrdStatus_Calculated -> (Some MOD_FIX_OrdStatus_Calculated) + | FIX_OrdStatus_Expired -> (Some MOD_FIX_OrdStatus_Expired) + | FIX_OrdStatus_AcceptedForBidding -> (Some MOD_FIX_OrdStatus_AcceptedForBidding) + | FIX_OrdStatus_PendingReplace -> (Some MOD_FIX_OrdStatus_PendingReplace) + | FIX_OrdStatus_Replaced -> (Some MOD_FIX_OrdStatus_Replaced) + | FIX_INVALID_OrdStatus _ -> (None) ) ;; -let convert__full_to_model_OrdType (f : fix_ordtype) = +let convert__full_to_model_PartySubIDType (f : fix_partysubidtype) = (match f with - | FIX_OrdType_Market -> MOD_FIX_OrdType_Market - | FIX_OrdType_Limit -> MOD_FIX_OrdType_Limit - | FIX_OrdType_Stop -> MOD_FIX_OrdType_Stop - | FIX_OrdType_StopLimit -> MOD_FIX_OrdType_StopLimit - | FIX_OrdType_WithOrWithout -> MOD_FIX_OrdType_WithOrWithout - | FIX_OrdType_LimitOrBetter -> MOD_FIX_OrdType_LimitOrBetter - | FIX_OrdType_LimitWithOrWithout -> MOD_FIX_OrdType_LimitWithOrWithout - | FIX_OrdType_OnBasis -> MOD_FIX_OrdType_OnBasis - | FIX_OrdType_PreviouslyQuoted -> MOD_FIX_OrdType_PreviouslyQuoted - | FIX_OrdType_PreviouslyIndicated -> MOD_FIX_OrdType_PreviouslyIndicated - | FIX_OrdType_ForexSwap -> MOD_FIX_OrdType_ForexSwap - | FIX_OrdType_Funari -> MOD_FIX_OrdType_Funari - | FIX_OrdType_MarketIfTouched -> MOD_FIX_OrdType_MarketIfTouched - | FIX_OrdType_MarketWithLeftOverAsLimit -> MOD_FIX_OrdType_MarketWithLeftOverAsLimit - | FIX_OrdType_PreviousFundValuationPoint -> MOD_FIX_OrdType_PreviousFundValuationPoint - | FIX_OrdType_NextFundValuationPoint -> MOD_FIX_OrdType_NextFundValuationPoint - | FIX_OrdType_Pegged -> MOD_FIX_OrdType_Pegged + | FIX_PartySubIDType_Firm -> (Some MOD_FIX_PartySubIDType_Firm) + | FIX_PartySubIDType_Person -> (Some MOD_FIX_PartySubIDType_Person) + | FIX_PartySubIDType_System -> (Some MOD_FIX_PartySubIDType_System) + | FIX_PartySubIDType_Application -> (Some MOD_FIX_PartySubIDType_Application) + | FIX_PartySubIDType_FullLegalNameOfFirm -> (Some MOD_FIX_PartySubIDType_FullLegalNameOfFirm) + | FIX_PartySubIDType_PostalAddress -> (Some MOD_FIX_PartySubIDType_PostalAddress) + | FIX_PartySubIDType_PhoneNumber -> (Some MOD_FIX_PartySubIDType_PhoneNumber) + | FIX_PartySubIDType_EmailAddress -> (Some MOD_FIX_PartySubIDType_EmailAddress) + | FIX_PartySubIDType_ContactName -> (Some MOD_FIX_PartySubIDType_ContactName) + | FIX_PartySubIDType_SecuritiesAccountNumber -> (Some MOD_FIX_PartySubIDType_SecuritiesAccountNumber) + | FIX_PartySubIDType_RegistrationNumber -> (Some MOD_FIX_PartySubIDType_RegistrationNumber) + | FIX_PartySubIDType_RegisteredAddressForConfirmation -> (Some MOD_FIX_PartySubIDType_RegisteredAddressForConfirmation) + | FIX_PartySubIDType_RegulatoryStatus -> (Some MOD_FIX_PartySubIDType_RegulatoryStatus) + | FIX_PartySubIDType_RegistrationName -> (Some MOD_FIX_PartySubIDType_RegistrationName) + | FIX_PartySubIDType_CashAccountNumber -> (Some MOD_FIX_PartySubIDType_CashAccountNumber) + | FIX_PartySubIDType_BIC -> (Some MOD_FIX_PartySubIDType_BIC) + | FIX_PartySubIDType_CSDParticipantMemberCode -> (Some MOD_FIX_PartySubIDType_CSDParticipantMemberCode) + | FIX_PartySubIDType_RegisteredAddress -> (Some MOD_FIX_PartySubIDType_RegisteredAddress) + | FIX_PartySubIDType_FundAccountName -> (Some MOD_FIX_PartySubIDType_FundAccountName) + | FIX_PartySubIDType_TelexNumber -> (Some MOD_FIX_PartySubIDType_TelexNumber) + | FIX_PartySubIDType_FaxNumber -> (Some MOD_FIX_PartySubIDType_FaxNumber) + | FIX_PartySubIDType_SecuritiesAccountName -> (Some MOD_FIX_PartySubIDType_SecuritiesAccountName) + | FIX_PartySubIDType_CashAccountName -> (Some MOD_FIX_PartySubIDType_CashAccountName) + | FIX_PartySubIDType_Department -> (Some MOD_FIX_PartySubIDType_Department) + | FIX_PartySubIDType_LocationDesk -> (Some MOD_FIX_PartySubIDType_LocationDesk) + | FIX_PartySubIDType_PositionAccountType -> (Some MOD_FIX_PartySubIDType_PositionAccountType) + | FIX_INVALID_PartySubIDType _ -> (None) ) ;; @@ -112,6 +211,85 @@ let convert__model_to_full_Side (f : model_fix_side) = ) ;; +let convert__model_to_full_OrdType (f : model_fix_ordtype) = + (match f with + | MOD_FIX_OrdType_Market -> FIX_OrdType_Market + | MOD_FIX_OrdType_Limit -> FIX_OrdType_Limit + | MOD_FIX_OrdType_Stop -> FIX_OrdType_Stop + | MOD_FIX_OrdType_StopLimit -> FIX_OrdType_StopLimit + | MOD_FIX_OrdType_WithOrWithout -> FIX_OrdType_WithOrWithout + | MOD_FIX_OrdType_LimitOrBetter -> FIX_OrdType_LimitOrBetter + | MOD_FIX_OrdType_LimitWithOrWithout -> FIX_OrdType_LimitWithOrWithout + | MOD_FIX_OrdType_OnBasis -> FIX_OrdType_OnBasis + | MOD_FIX_OrdType_PreviouslyQuoted -> FIX_OrdType_PreviouslyQuoted + | MOD_FIX_OrdType_PreviouslyIndicated -> FIX_OrdType_PreviouslyIndicated + | MOD_FIX_OrdType_ForexSwap -> FIX_OrdType_ForexSwap + | MOD_FIX_OrdType_Funari -> FIX_OrdType_Funari + | MOD_FIX_OrdType_MarketIfTouched -> FIX_OrdType_MarketIfTouched + | MOD_FIX_OrdType_MarketWithLeftOverAsLimit -> FIX_OrdType_MarketWithLeftOverAsLimit + | MOD_FIX_OrdType_PreviousFundValuationPoint -> FIX_OrdType_PreviousFundValuationPoint + | MOD_FIX_OrdType_NextFundValuationPoint -> FIX_OrdType_NextFundValuationPoint + | MOD_FIX_OrdType_Pegged -> FIX_OrdType_Pegged + | MOD_FIX_OrdType_StopSpread -> FIX_OrdType_StopSpread + ) +;; + +let convert_inner_model_to_full_ExecInst (f : model_fix_execinst) = + (match f with + | MOD_FIX_ExecInst_NotHeld -> FIX_ExecInst_NotHeld + | MOD_FIX_ExecInst_Work -> FIX_ExecInst_Work + | MOD_FIX_ExecInst_GoAlong -> FIX_ExecInst_GoAlong + | MOD_FIX_ExecInst_OverTheDay -> FIX_ExecInst_OverTheDay + | MOD_FIX_ExecInst_Held -> FIX_ExecInst_Held + | MOD_FIX_ExecInst_ParticipateDoNotInitiate -> FIX_ExecInst_ParticipateDoNotInitiate + | MOD_FIX_ExecInst_StrictScale -> FIX_ExecInst_StrictScale + | MOD_FIX_ExecInst_TryToScale -> FIX_ExecInst_TryToScale + | MOD_FIX_ExecInst_StayOnBidSide -> FIX_ExecInst_StayOnBidSide + | MOD_FIX_ExecInst_StayOnOfferSide -> FIX_ExecInst_StayOnOfferSide + | MOD_FIX_ExecInst_NoCross -> FIX_ExecInst_NoCross + | MOD_FIX_ExecInst_OKToCross -> FIX_ExecInst_OKToCross + | MOD_FIX_ExecInst_CallFirst -> FIX_ExecInst_CallFirst + | MOD_FIX_ExecInst_PercentOfVolume -> FIX_ExecInst_PercentOfVolume + | MOD_FIX_ExecInst_DoNotIncrease -> FIX_ExecInst_DoNotIncrease + | MOD_FIX_ExecInst_DoNotReduce -> FIX_ExecInst_DoNotReduce + | MOD_FIX_ExecInst_AllOrNone -> FIX_ExecInst_AllOrNone + | MOD_FIX_ExecInst_ReinstateOnSystemFailure -> FIX_ExecInst_ReinstateOnSystemFailure + | MOD_FIX_ExecInst_InstitutionsOnly -> FIX_ExecInst_InstitutionsOnly + | MOD_FIX_ExecInst_ReinstateOnTradingHalt -> FIX_ExecInst_ReinstateOnTradingHalt + | MOD_FIX_ExecInst_CancelOnTradingHalt -> FIX_ExecInst_CancelOnTradingHalt + | MOD_FIX_ExecInst_LastPeg -> FIX_ExecInst_LastPeg + | MOD_FIX_ExecInst_MidPricePeg -> FIX_ExecInst_MidPricePeg + | MOD_FIX_ExecInst_NonNegotiable -> FIX_ExecInst_NonNegotiable + | MOD_FIX_ExecInst_OpeningPeg -> FIX_ExecInst_OpeningPeg + | MOD_FIX_ExecInst_MarketPeg -> FIX_ExecInst_MarketPeg + | MOD_FIX_ExecInst_CancelOnSystemFailure -> FIX_ExecInst_CancelOnSystemFailure + | MOD_FIX_ExecInst_PrimaryPeg -> FIX_ExecInst_PrimaryPeg + | MOD_FIX_ExecInst_Suspend -> FIX_ExecInst_Suspend + | MOD_FIX_ExecInst_CustomerDisplayInstruction -> FIX_ExecInst_CustomerDisplayInstruction + | MOD_FIX_ExecInst_Netting -> FIX_ExecInst_Netting + | MOD_FIX_ExecInst_PegToVWAP -> FIX_ExecInst_PegToVWAP + | MOD_FIX_ExecInst_TradeAlong -> FIX_ExecInst_TradeAlong + | MOD_FIX_ExecInst_TryToStop -> FIX_ExecInst_TryToStop + | MOD_FIX_ExecInst_CancelIfNotBest -> FIX_ExecInst_CancelIfNotBest + | MOD_FIX_ExecInst_TrailingStopPeg -> FIX_ExecInst_TrailingStopPeg + | MOD_FIX_ExecInst_StrictLimit -> FIX_ExecInst_StrictLimit + | MOD_FIX_ExecInst_IgnorePriceValidityChecks -> FIX_ExecInst_IgnorePriceValidityChecks + | MOD_FIX_ExecInst_PegToLimitPrice -> FIX_ExecInst_PegToLimitPrice + | MOD_FIX_ExecInst_WorkToTargetStrategy -> FIX_ExecInst_WorkToTargetStrategy + ) +;; + +let rec convert__model_to_full_ExecInst (f) (x) = + (match x with + | [] -> [] + | h :: t -> ((if (Map.get h f) then + ((convert_inner_model_to_full_ExecInst h) :: (convert__model_to_full_ExecInst f t)) + else + (convert__model_to_full_ExecInst f t)) + ) + ) +;; + let convert__model_to_full_ExecType (f : model_fix_exectype) = (match f with | MOD_FIX_ExecType_New -> FIX_ExecType_New @@ -154,26 +332,34 @@ let convert__model_to_full_OrdStatus (f : model_fix_ordstatus) = ) ;; -let convert__model_to_full_OrdType (f : model_fix_ordtype) = +let convert__model_to_full_PartySubIDType (f : model_fix_partysubidtype) = (match f with - | MOD_FIX_OrdType_Market -> FIX_OrdType_Market - | MOD_FIX_OrdType_Limit -> FIX_OrdType_Limit - | MOD_FIX_OrdType_Stop -> FIX_OrdType_Stop - | MOD_FIX_OrdType_StopLimit -> FIX_OrdType_StopLimit - | MOD_FIX_OrdType_WithOrWithout -> FIX_OrdType_WithOrWithout - | MOD_FIX_OrdType_LimitOrBetter -> FIX_OrdType_LimitOrBetter - | MOD_FIX_OrdType_LimitWithOrWithout -> FIX_OrdType_LimitWithOrWithout - | MOD_FIX_OrdType_OnBasis -> FIX_OrdType_OnBasis - | MOD_FIX_OrdType_PreviouslyQuoted -> FIX_OrdType_PreviouslyQuoted - | MOD_FIX_OrdType_PreviouslyIndicated -> FIX_OrdType_PreviouslyIndicated - | MOD_FIX_OrdType_ForexSwap -> FIX_OrdType_ForexSwap - | MOD_FIX_OrdType_Funari -> FIX_OrdType_Funari - | MOD_FIX_OrdType_MarketIfTouched -> FIX_OrdType_MarketIfTouched - | MOD_FIX_OrdType_MarketWithLeftOverAsLimit -> FIX_OrdType_MarketWithLeftOverAsLimit - | MOD_FIX_OrdType_PreviousFundValuationPoint -> FIX_OrdType_PreviousFundValuationPoint - | MOD_FIX_OrdType_NextFundValuationPoint -> FIX_OrdType_NextFundValuationPoint - | MOD_FIX_OrdType_Pegged -> FIX_OrdType_Pegged + | MOD_FIX_PartySubIDType_Firm -> FIX_PartySubIDType_Firm + | MOD_FIX_PartySubIDType_Person -> FIX_PartySubIDType_Person + | MOD_FIX_PartySubIDType_System -> FIX_PartySubIDType_System + | MOD_FIX_PartySubIDType_Application -> FIX_PartySubIDType_Application + | MOD_FIX_PartySubIDType_FullLegalNameOfFirm -> FIX_PartySubIDType_FullLegalNameOfFirm + | MOD_FIX_PartySubIDType_PostalAddress -> FIX_PartySubIDType_PostalAddress + | MOD_FIX_PartySubIDType_PhoneNumber -> FIX_PartySubIDType_PhoneNumber + | MOD_FIX_PartySubIDType_EmailAddress -> FIX_PartySubIDType_EmailAddress + | MOD_FIX_PartySubIDType_ContactName -> FIX_PartySubIDType_ContactName + | MOD_FIX_PartySubIDType_SecuritiesAccountNumber -> FIX_PartySubIDType_SecuritiesAccountNumber + | MOD_FIX_PartySubIDType_RegistrationNumber -> FIX_PartySubIDType_RegistrationNumber + | MOD_FIX_PartySubIDType_RegisteredAddressForConfirmation -> FIX_PartySubIDType_RegisteredAddressForConfirmation + | MOD_FIX_PartySubIDType_RegulatoryStatus -> FIX_PartySubIDType_RegulatoryStatus + | MOD_FIX_PartySubIDType_RegistrationName -> FIX_PartySubIDType_RegistrationName + | MOD_FIX_PartySubIDType_CashAccountNumber -> FIX_PartySubIDType_CashAccountNumber + | MOD_FIX_PartySubIDType_BIC -> FIX_PartySubIDType_BIC + | MOD_FIX_PartySubIDType_CSDParticipantMemberCode -> FIX_PartySubIDType_CSDParticipantMemberCode + | MOD_FIX_PartySubIDType_RegisteredAddress -> FIX_PartySubIDType_RegisteredAddress + | MOD_FIX_PartySubIDType_FundAccountName -> FIX_PartySubIDType_FundAccountName + | MOD_FIX_PartySubIDType_TelexNumber -> FIX_PartySubIDType_TelexNumber + | MOD_FIX_PartySubIDType_FaxNumber -> FIX_PartySubIDType_FaxNumber + | MOD_FIX_PartySubIDType_SecuritiesAccountName -> FIX_PartySubIDType_SecuritiesAccountName + | MOD_FIX_PartySubIDType_CashAccountName -> FIX_PartySubIDType_CashAccountName + | MOD_FIX_PartySubIDType_Department -> FIX_PartySubIDType_Department + | MOD_FIX_PartySubIDType_LocationDesk -> FIX_PartySubIDType_LocationDesk + | MOD_FIX_PartySubIDType_PositionAccountType -> FIX_PartySubIDType_PositionAccountType ) ;; -[@@@logic] diff --git a/src-model/src-conversions/record_converter.iml b/src-model/src-conversions/record_converter.iml index 532e5080..b9564f5e 100644 --- a/src-model/src-conversions/record_converter.iml +++ b/src-model/src-conversions/record_converter.iml @@ -1,5 +1,3 @@ -(* Imandra Inc. copyright 2020 *) -[@@@program] +(* Imandra Inc. copyright 2021 *) -[@@@logic] diff --git a/src-model/src-conversions/repeating_groups_converter.iml b/src-model/src-conversions/repeating_groups_converter.iml index d7f7cdbc..1f6463de 100644 --- a/src-model/src-conversions/repeating_groups_converter.iml +++ b/src-model/src-conversions/repeating_groups_converter.iml @@ -1,13 +1,34 @@ -(* Imandra Inc. copyright 2020 *) -[@@@program] +(* Imandra Inc. copyright 2021 *) +[@@@import "../../src-protocol-exts/full_app_records.iml"] +open Full_app_records;; +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; [@@@import "../src-types/model_tags.iml"] open Model_tags;; -exception Ipl_rg_exception -type rg_reject_type = - | RG_Failure of m_field_tag - | RG_Success +type rg_reject_type_ptyssubgrp = + | Rg_success_ptyssubgrp of model_fix_rec_ptyssubgrp + | Rg_missing_field_failure_ptyssubgrp of (m_field_tag*repeating_group_defs) + | Rg_invalid_enum_failure_ptyssubgrp of (m_field_tag*repeating_group_defs) +;; + +type rg_reject_type_parties = + | Rg_success_parties of model_fix_rec_parties + | Rg_missing_field_failure_parties of (m_field_tag*repeating_group_defs) + | Rg_invalid_enum_failure_parties of (m_field_tag*repeating_group_defs) +;; + +type rg_reject_inner_type_ptyssubgrp = + | Rg_inner_missing_field_failure_ptyssubgrp of (m_field_tag*repeating_group_defs) + | Rg_inner_invalid_enum_failure_ptyssubgrp of (m_field_tag*repeating_group_defs) + | Rg_inner_success_ptyssubgrp of model_fix_inner_ptyssubgrp +;; + +type rg_reject_inner_type_parties = + | Rg_inner_missing_field_failure_parties of (m_field_tag*repeating_group_defs) + | Rg_inner_invalid_enum_failure_parties of (m_field_tag*repeating_group_defs) + | Rg_inner_success_parties of model_fix_inner_parties ;; let rec cap_length (d) (x) (h) = @@ -17,4 +38,322 @@ let rec cap_length (d) (x) (h) = ) ;; -[@@@logic] +let rec map_convert__model_to_full_RG_PtysSubGrp (d) (x) = + (match d with + | [] -> [] + | h :: t -> ((convert__model_to_full_RG_PtysSubGrp h x) :: (map_convert__model_to_full_RG_PtysSubGrp t x)) + ) and +convert__model_to_full_RG_PtysSubGrp (rec_in : model_fix_inner_ptyssubgrp) (len : int) = + { + f_PtysSubGrp_PartySubID = rec_in.mod_f_PtysSubGrp_PartySubID; + f_PtysSubGrp_NoPartySubIDs = Some len + } + [@@macro] and +convert__model_to_full_PtysSubGrp (rec_in : model_fix_rec_ptyssubgrp) = + let d = [] + in + let d = (match rec_in.rg_PtysSubGrp_element_0 with + | None -> d + | Some x -> (x :: d) + ) + in + let d = (match rec_in.rg_PtysSubGrp_element_1 with + | None -> d + | Some x -> (x :: d) + ) + in + let d = (match rec_in.rg_PtysSubGrp_element_2 with + | None -> d + | Some x -> (x :: d) + ) + in + let d = (match rec_in.rg_PtysSubGrp_element_3 with + | None -> d + | Some x -> (x :: d) + ) + in + let d = (match rec_in.rg_PtysSubGrp_element_4 with + | None -> d + | Some x -> (x :: d) + ) + in + map_convert__model_to_full_RG_PtysSubGrp d (cap_length d 0 5) +;; + +let rec convert__full_to_model_PtysSubGrp (rec_in : fix_rg_ptyssubgrp) = + let block4 = None + in + let block3 = None + in + let block2 = None + in + let block1 = None + in + let block0 = None + in + let t = rec_in + in + (match t with + | [] -> (Rg_success_ptyssubgrp { + rg_PtysSubGrp_element_4 = block4; + rg_PtysSubGrp_element_3 = block3; + rg_PtysSubGrp_element_2 = block2; + rg_PtysSubGrp_element_1 = block1; + rg_PtysSubGrp_element_0 = block0 + }) + | h :: t -> ((match convert__full_to_model_RG_PtysSubGrp h with + | Rg_inner_success_ptyssubgrp x -> let block0 = Some x + in + (match t with + | [] -> (Rg_success_ptyssubgrp { + rg_PtysSubGrp_element_4 = block4; + rg_PtysSubGrp_element_3 = block3; + rg_PtysSubGrp_element_2 = block2; + rg_PtysSubGrp_element_1 = block1; + rg_PtysSubGrp_element_0 = block0 + }) + | h :: t -> ((match convert__full_to_model_RG_PtysSubGrp h with + | Rg_inner_success_ptyssubgrp x -> let block1 = Some x + in + (match t with + | [] -> (Rg_success_ptyssubgrp { + rg_PtysSubGrp_element_4 = block4; + rg_PtysSubGrp_element_3 = block3; + rg_PtysSubGrp_element_2 = block2; + rg_PtysSubGrp_element_1 = block1; + rg_PtysSubGrp_element_0 = block0 + }) + | h :: t -> ((match convert__full_to_model_RG_PtysSubGrp h with + | Rg_inner_success_ptyssubgrp x -> let block2 = Some x + in + (match t with + | [] -> (Rg_success_ptyssubgrp { + rg_PtysSubGrp_element_4 = block4; + rg_PtysSubGrp_element_3 = block3; + rg_PtysSubGrp_element_2 = block2; + rg_PtysSubGrp_element_1 = block1; + rg_PtysSubGrp_element_0 = block0 + }) + | h :: t -> ((match convert__full_to_model_RG_PtysSubGrp h with + | Rg_inner_success_ptyssubgrp x -> let block3 = Some x + in + (match t with + | [] -> (Rg_success_ptyssubgrp { + rg_PtysSubGrp_element_4 = block4; + rg_PtysSubGrp_element_3 = block3; + rg_PtysSubGrp_element_2 = block2; + rg_PtysSubGrp_element_1 = block1; + rg_PtysSubGrp_element_0 = block0 + }) + | h :: t -> ((match convert__full_to_model_RG_PtysSubGrp h with + | Rg_inner_success_ptyssubgrp x -> let block4 = Some x + in + Rg_success_ptyssubgrp { + rg_PtysSubGrp_element_4 = block4; + rg_PtysSubGrp_element_3 = block3; + rg_PtysSubGrp_element_2 = block2; + rg_PtysSubGrp_element_1 = block1; + rg_PtysSubGrp_element_0 = block0 + } + | Rg_inner_invalid_enum_failure_ptyssubgrp x -> (Rg_invalid_enum_failure_ptyssubgrp (x)) + | Rg_inner_missing_field_failure_ptyssubgrp x -> (Rg_missing_field_failure_ptyssubgrp (x)) + ) + ) + ) + | Rg_inner_invalid_enum_failure_ptyssubgrp x -> (Rg_invalid_enum_failure_ptyssubgrp (x)) + | Rg_inner_missing_field_failure_ptyssubgrp x -> (Rg_missing_field_failure_ptyssubgrp (x)) + ) + ) + ) + | Rg_inner_invalid_enum_failure_ptyssubgrp x -> (Rg_invalid_enum_failure_ptyssubgrp (x)) + | Rg_inner_missing_field_failure_ptyssubgrp x -> (Rg_missing_field_failure_ptyssubgrp (x)) + ) + ) + ) + | Rg_inner_invalid_enum_failure_ptyssubgrp x -> (Rg_invalid_enum_failure_ptyssubgrp (x)) + | Rg_inner_missing_field_failure_ptyssubgrp x -> (Rg_missing_field_failure_ptyssubgrp (x)) + ) + ) + ) + | Rg_inner_invalid_enum_failure_ptyssubgrp x -> (Rg_invalid_enum_failure_ptyssubgrp (x)) + | Rg_inner_missing_field_failure_ptyssubgrp x -> (Rg_missing_field_failure_ptyssubgrp (x)) + ) + ) + ) and +convert__full_to_model_RG_PtysSubGrp (rec_in : fix_rg_inner_ptyssubgrp) = + let c_mod_f_PtysSubGrp_PartySubID = rec_in.f_PtysSubGrp_PartySubID + in + Rg_inner_success_ptyssubgrp { + mod_f_PtysSubGrp_PartySubID = c_mod_f_PtysSubGrp_PartySubID + } + [@@macro] +;; + +let rec map_convert__model_to_full_RG_Parties (d) (x) = + (match d with + | [] -> [] + | h :: t -> ((convert__model_to_full_RG_Parties h x) :: (map_convert__model_to_full_RG_Parties t x)) + ) and +convert__model_to_full_RG_Parties (rec_in : model_fix_inner_parties) (len : int) = + { + f_Parties_PartyID = Some rec_in.mod_f_Parties_PartyID; + f_Parties_PartyIndex = Some rec_in.mod_f_Parties_PartyIndex; + f_Parties_PtysSubGrp = convert__model_to_full_PtysSubGrp rec_in.mod_f_Parties_PtysSubGrp; + f_Parties_NoPartyIDs = Some len + } + [@@macro] and +convert__model_to_full_Parties (rec_in : model_fix_rec_parties) = + let d = [] + in + let d = (match rec_in.rg_Parties_element_0 with + | None -> d + | Some x -> (x :: d) + ) + in + let d = (match rec_in.rg_Parties_element_1 with + | None -> d + | Some x -> (x :: d) + ) + in + let d = (match rec_in.rg_Parties_element_2 with + | None -> d + | Some x -> (x :: d) + ) + in + let d = (match rec_in.rg_Parties_element_3 with + | None -> d + | Some x -> (x :: d) + ) + in + let d = (match rec_in.rg_Parties_element_4 with + | None -> d + | Some x -> (x :: d) + ) + in + map_convert__model_to_full_RG_Parties d (cap_length d 0 5) +;; + +let rec convert__full_to_model_Parties (rec_in : fix_rg_parties) = + let block4 = None + in + let block3 = None + in + let block2 = None + in + let block1 = None + in + let block0 = None + in + let t = rec_in + in + (match t with + | [] -> (Rg_success_parties { + rg_Parties_element_4 = block4; + rg_Parties_element_3 = block3; + rg_Parties_element_2 = block2; + rg_Parties_element_1 = block1; + rg_Parties_element_0 = block0 + }) + | h :: t -> ((match convert__full_to_model_RG_Parties h with + | Rg_inner_success_parties x -> let block0 = Some x + in + (match t with + | [] -> (Rg_success_parties { + rg_Parties_element_4 = block4; + rg_Parties_element_3 = block3; + rg_Parties_element_2 = block2; + rg_Parties_element_1 = block1; + rg_Parties_element_0 = block0 + }) + | h :: t -> ((match convert__full_to_model_RG_Parties h with + | Rg_inner_success_parties x -> let block1 = Some x + in + (match t with + | [] -> (Rg_success_parties { + rg_Parties_element_4 = block4; + rg_Parties_element_3 = block3; + rg_Parties_element_2 = block2; + rg_Parties_element_1 = block1; + rg_Parties_element_0 = block0 + }) + | h :: t -> ((match convert__full_to_model_RG_Parties h with + | Rg_inner_success_parties x -> let block2 = Some x + in + (match t with + | [] -> (Rg_success_parties { + rg_Parties_element_4 = block4; + rg_Parties_element_3 = block3; + rg_Parties_element_2 = block2; + rg_Parties_element_1 = block1; + rg_Parties_element_0 = block0 + }) + | h :: t -> ((match convert__full_to_model_RG_Parties h with + | Rg_inner_success_parties x -> let block3 = Some x + in + (match t with + | [] -> (Rg_success_parties { + rg_Parties_element_4 = block4; + rg_Parties_element_3 = block3; + rg_Parties_element_2 = block2; + rg_Parties_element_1 = block1; + rg_Parties_element_0 = block0 + }) + | h :: t -> ((match convert__full_to_model_RG_Parties h with + | Rg_inner_success_parties x -> let block4 = Some x + in + Rg_success_parties { + rg_Parties_element_4 = block4; + rg_Parties_element_3 = block3; + rg_Parties_element_2 = block2; + rg_Parties_element_1 = block1; + rg_Parties_element_0 = block0 + } + | Rg_inner_invalid_enum_failure_parties x -> (Rg_invalid_enum_failure_parties (x)) + | Rg_inner_missing_field_failure_parties x -> (Rg_missing_field_failure_parties (x)) + ) + ) + ) + | Rg_inner_invalid_enum_failure_parties x -> (Rg_invalid_enum_failure_parties (x)) + | Rg_inner_missing_field_failure_parties x -> (Rg_missing_field_failure_parties (x)) + ) + ) + ) + | Rg_inner_invalid_enum_failure_parties x -> (Rg_invalid_enum_failure_parties (x)) + | Rg_inner_missing_field_failure_parties x -> (Rg_missing_field_failure_parties (x)) + ) + ) + ) + | Rg_inner_invalid_enum_failure_parties x -> (Rg_invalid_enum_failure_parties (x)) + | Rg_inner_missing_field_failure_parties x -> (Rg_missing_field_failure_parties (x)) + ) + ) + ) + | Rg_inner_invalid_enum_failure_parties x -> (Rg_invalid_enum_failure_parties (x)) + | Rg_inner_missing_field_failure_parties x -> (Rg_missing_field_failure_parties (x)) + ) + ) + ) and +convert__full_to_model_RG_Parties (rec_in : fix_rg_inner_parties) = + (match convert__full_to_model_PtysSubGrp rec_in.f_Parties_PtysSubGrp with + | Rg_success_ptyssubgrp x -> let c_mod_f_Parties_PtysSubGrp = x + in + (match rec_in.f_Parties_PartyIndex with + | Some x -> let c_mod_f_Parties_PartyIndex = x + in + (match rec_in.f_Parties_PartyID with + | Some x -> let c_mod_f_Parties_PartyID = x + in + Rg_inner_success_parties { + mod_f_Parties_PartyID = c_mod_f_Parties_PartyID; + mod_f_Parties_PartyIndex = c_mod_f_Parties_PartyIndex; + mod_f_Parties_PtysSubGrp = c_mod_f_Parties_PtysSubGrp + } + | None -> (Rg_inner_missing_field_failure_parties (M_Field_PartyID_Tag,MOD_FIX_Repeating_Group_Parties)) + ) + | None -> (Rg_inner_missing_field_failure_parties (M_Field_PartyIndex_Tag,MOD_FIX_Repeating_Group_Parties)) + ) + | Rg_invalid_enum_failure_ptyssubgrp x -> (Rg_inner_invalid_enum_failure_parties x) + | Rg_missing_field_failure_ptyssubgrp x -> (Rg_inner_missing_field_failure_parties x) + ) +;; + diff --git a/src-model/src-conversions/type_converter.iml b/src-model/src-conversions/type_converter.iml index 30fc5ad8..811f0ba7 100644 --- a/src-model/src-conversions/type_converter.iml +++ b/src-model/src-conversions/type_converter.iml @@ -1,502 +1,323 @@ -(* Imandra Inc. copyright 2020 *) -[@@@program] +(* Imandra Inc. copyright 2021 *) [@@@import "enum_converter.iml"] open Enum_converter;; [@@@import "../../src-protocol-exts/full_app_messages.iml"] open Full_app_messages;; [@@@import "../../src-protocol-exts/full_app_records.iml"] open Full_app_records;; +[@@@import "../src-strings-venue/model_enum_names.iml"] +open Model_enum_names;; [@@@import "../src-types/model_messages.iml"] open Model_messages;; [@@@import "../src-types/model_tags.iml"] open Model_tags;; +[@@@import "repeating_groups_converter.iml"] +open Repeating_groups_converter;; -let convert__full_to_model_ExecutionReport (msg : full_fix_executionreport_data) = - FIX_TL_None - [@@macro] -;; - let convert__full_to_model_NewOrderSingle (msg : full_fix_newordersingle_data) = - (match msg.f_NewOrderSingle_Instrument.f_Instrument_Symbol with - | None -> (FIX_TL_Req_Field_Missing { - field_missing_data_msg = M_Msg_NewOrderSingle_Tag; - field_missing_data_field = M_Field_Symbol_Tag + (match convert__full_to_model_Parties msg.f_NewOrderSingle_Parties with + | Rg_missing_field_failure_parties x -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_NewOrderSingle_Tag; + field_missing_or_invalid_data_field = fst x; + repeating_group_origin = Some (snd x) }) - | Some m_f_Instrument_Symbol -> let c_mod_f_NewOrderSingle_Instrument_Symbol = m_f_Instrument_Symbol + | Rg_invalid_enum_failure_parties x -> (FIX_TL_Req_Field_Invalid { + field_missing_of_invalid_data_msg = M_Msg_NewOrderSingle_Tag; + field_missing_or_invalid_data_field = fst x; + repeating_group_origin = Some (snd x) + }) + | Rg_success_parties x -> let c_mod_f_NewOrderSingle_Parties = x + in + let c_mod_f_NewOrderSingle_ExecInst = (match msg.f_NewOrderSingle_ExecInst with + | None -> None + | Some d -> (Some (convert__full_to_model_ExecInst d)) + ) in - (match msg.f_NewOrderSingle_OrdType with - | None -> (FIX_TL_Req_Field_Missing { - field_missing_data_msg = M_Msg_NewOrderSingle_Tag; - field_missing_data_field = M_Field_OrdType_Tag + (if ((=) c_mod_f_NewOrderSingle_ExecInst (Some (None))) then + (FIX_TL_Req_Field_Invalid { + field_missing_of_invalid_data_msg = M_Msg_NewOrderSingle_Tag; + field_missing_or_invalid_data_field = M_Field_ExecInst_Tag; + repeating_group_origin = None }) - | Some m_f_NewOrderSingle_OrdType -> let c_mod_f_NewOrderSingle_OrdType = m_f_NewOrderSingle_OrdType + else + let c_mod_f_NewOrderSingle_ExecInst = (match c_mod_f_NewOrderSingle_ExecInst with + | Some Some x -> (Some x) + | _ -> (None) + ) + in + let c_mod_f_NewOrderSingle_Account = msg.f_NewOrderSingle_Account in - (match msg.f_NewOrderSingle_TransactTime with + let c_mod_f_NewOrderSingle_Price = msg.f_NewOrderSingle_Price + in + let c_mod_f_NewOrderSingle_SpreadProportion = msg.f_NewOrderSingle_SpreadProportion + in + (match msg.f_NewOrderSingle_OrderQtyData.f_OrderQtyData_OrderQty with | None -> (FIX_TL_Req_Field_Missing { - field_missing_data_msg = M_Msg_NewOrderSingle_Tag; - field_missing_data_field = M_Field_TransactTime_Tag + field_missing_of_invalid_data_msg = M_Msg_NewOrderSingle_Tag; + field_missing_or_invalid_data_field = M_Field_OrderQty_Tag; + repeating_group_origin = None }) - | Some m_f_NewOrderSingle_TransactTime -> let c_mod_f_NewOrderSingle_TransactTime = m_f_NewOrderSingle_TransactTime + | Some m_f_OrderQtyData_OrderQty -> let c_mod_f_NewOrderSingle_OrderQtyData_OrderQty = m_f_OrderQtyData_OrderQty in - (match msg.f_NewOrderSingle_Side with + (match msg.f_NewOrderSingle_OrdType with | None -> (FIX_TL_Req_Field_Missing { - field_missing_data_msg = M_Msg_NewOrderSingle_Tag; - field_missing_data_field = M_Field_Side_Tag + field_missing_of_invalid_data_msg = M_Msg_NewOrderSingle_Tag; + field_missing_or_invalid_data_field = M_Field_OrdType_Tag; + repeating_group_origin = None }) - | Some m_f_NewOrderSingle_Side -> let c_mod_f_NewOrderSingle_Side = m_f_NewOrderSingle_Side + | Some m_f_NewOrderSingle_OrdType -> let c_mod_f_NewOrderSingle_OrdType = convert__full_to_model_OrdType m_f_NewOrderSingle_OrdType in - (match msg.f_NewOrderSingle_ClOrdID with + (match c_mod_f_NewOrderSingle_OrdType with + | None -> (FIX_TL_Req_Field_Invalid { + field_missing_of_invalid_data_msg = M_Msg_NewOrderSingle_Tag; + field_missing_or_invalid_data_field = M_Field_OrdType_Tag; + repeating_group_origin = None + }) + | Some c_mod_f_NewOrderSingle_OrdType -> ((match msg.f_NewOrderSingle_TransactTime with + | None -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_NewOrderSingle_Tag; + field_missing_or_invalid_data_field = M_Field_TransactTime_Tag; + repeating_group_origin = None + }) + | Some m_f_NewOrderSingle_TransactTime -> let c_mod_f_NewOrderSingle_TransactTime = m_f_NewOrderSingle_TransactTime + in + (match msg.f_NewOrderSingle_Side with + | None -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_NewOrderSingle_Tag; + field_missing_or_invalid_data_field = M_Field_Side_Tag; + repeating_group_origin = None + }) + | Some m_f_NewOrderSingle_Side -> let c_mod_f_NewOrderSingle_Side = convert__full_to_model_Side m_f_NewOrderSingle_Side + in + (match c_mod_f_NewOrderSingle_Side with + | None -> (FIX_TL_Req_Field_Invalid { + field_missing_of_invalid_data_msg = M_Msg_NewOrderSingle_Tag; + field_missing_or_invalid_data_field = M_Field_Side_Tag; + repeating_group_origin = None + }) + | Some c_mod_f_NewOrderSingle_Side -> let c_mod_f_NewOrderSingle_ClOrdID = msg.f_NewOrderSingle_ClOrdID + in + let fix_msg_data = { + mod_def_opt_f_NewOrderSingle_ClOrdID = c_mod_f_NewOrderSingle_ClOrdID; + mod_def_opt_f_NewOrderSingle_Side = c_mod_f_NewOrderSingle_Side; + mod_def_opt_f_NewOrderSingle_TransactTime = c_mod_f_NewOrderSingle_TransactTime; + mod_def_opt_f_NewOrderSingle_OrdType = c_mod_f_NewOrderSingle_OrdType; + mod_def_opt_f_NewOrderSingle_OrderQtyData_OrderQty = c_mod_f_NewOrderSingle_OrderQtyData_OrderQty; + mod_def_opt_f_NewOrderSingle_SpreadProportion = c_mod_f_NewOrderSingle_SpreadProportion; + mod_def_opt_f_NewOrderSingle_Price = c_mod_f_NewOrderSingle_Price; + mod_def_opt_f_NewOrderSingle_Account = c_mod_f_NewOrderSingle_Account; + mod_def_opt_f_NewOrderSingle_ExecInst = c_mod_f_NewOrderSingle_ExecInst; + mod_def_opt_f_NewOrderSingle_Parties = c_mod_f_NewOrderSingle_Parties + } + in + FIX_TL_Normal (FIX_Msg_Def_Opt_NewOrderSingle fix_msg_data) + ) + ) + ) + ) + ) + ) + ) + ) + ) +;; + +let convert__full_to_model_ExecutionReport (msg : full_fix_executionreport_data) = + (match msg.f_ExecutionReport_ExecInst with + | None -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_ExecInst_Tag; + repeating_group_origin = None + }) + | Some m_f_ExecutionReport_ExecInst -> let c_mod_f_ExecutionReport_ExecInst = convert__full_to_model_ExecInst m_f_ExecutionReport_ExecInst + in + (match c_mod_f_ExecutionReport_ExecInst with + | None -> (FIX_TL_Req_Field_Invalid { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_ExecInst_Tag; + repeating_group_origin = None + }) + | Some c_mod_f_ExecutionReport_ExecInst -> ((match convert__full_to_model_Parties msg.f_ExecutionReport_Parties with + | Rg_missing_field_failure_parties x -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = fst x; + repeating_group_origin = Some (snd x) + }) + | Rg_invalid_enum_failure_parties x -> (FIX_TL_Req_Field_Invalid { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = fst x; + repeating_group_origin = Some (snd x) + }) + | Rg_success_parties x -> let c_mod_f_ExecutionReport_Parties = x + in + let c_mod_f_ExecutionReport_Text = msg.f_ExecutionReport_Text + in + (match msg.f_ExecutionReport_CumQty with + | None -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_CumQty_Tag; + repeating_group_origin = None + }) + | Some m_f_ExecutionReport_CumQty -> let c_mod_f_ExecutionReport_CumQty = m_f_ExecutionReport_CumQty + in + (match msg.f_ExecutionReport_LeavesQty with | None -> (FIX_TL_Req_Field_Missing { - field_missing_data_msg = M_Msg_NewOrderSingle_Tag; - field_missing_data_field = M_Field_ClOrdID_Tag + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_LeavesQty_Tag; + repeating_group_origin = None }) - | Some m_f_NewOrderSingle_ClOrdID -> let c_mod_f_NewOrderSingle_ClOrdID = m_f_NewOrderSingle_ClOrdID - in - let fix_msg_data = { - mod_f_NewOrderSingle_ClOrdID = c_mod_f_NewOrderSingle_ClOrdID; - mod_f_NewOrderSingle_Side = convert__full_to_model_Side c_mod_f_NewOrderSingle_Side; - mod_f_NewOrderSingle_TransactTime = c_mod_f_NewOrderSingle_TransactTime; - mod_f_NewOrderSingle_OrdType = convert__full_to_model_OrdType c_mod_f_NewOrderSingle_OrdType; - mod_f_NewOrderSingle_Instrument_Symbol = c_mod_f_NewOrderSingle_Instrument_Symbol - } + | Some m_f_ExecutionReport_LeavesQty -> let c_mod_f_ExecutionReport_LeavesQty = m_f_ExecutionReport_LeavesQty in - FIX_TL_Normal (FIX_Msg_NewOrderSingle fix_msg_data) + (match msg.f_ExecutionReport_OrderQtyData.f_OrderQtyData_OrderQty with + | None -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_OrderQty_Tag; + repeating_group_origin = None + }) + | Some m_f_OrderQtyData_OrderQty -> let c_mod_f_ExecutionReport_OrderQtyData_OrderQty = m_f_OrderQtyData_OrderQty + in + (match msg.f_ExecutionReport_Side with + | None -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_Side_Tag; + repeating_group_origin = None + }) + | Some m_f_ExecutionReport_Side -> let c_mod_f_ExecutionReport_Side = convert__full_to_model_Side m_f_ExecutionReport_Side + in + (match c_mod_f_ExecutionReport_Side with + | None -> (FIX_TL_Req_Field_Invalid { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_Side_Tag; + repeating_group_origin = None + }) + | Some c_mod_f_ExecutionReport_Side -> ((match msg.f_ExecutionReport_OrdStatus with + | None -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_OrdStatus_Tag; + repeating_group_origin = None + }) + | Some m_f_ExecutionReport_OrdStatus -> let c_mod_f_ExecutionReport_OrdStatus = convert__full_to_model_OrdStatus m_f_ExecutionReport_OrdStatus + in + (match c_mod_f_ExecutionReport_OrdStatus with + | None -> (FIX_TL_Req_Field_Invalid { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_OrdStatus_Tag; + repeating_group_origin = None + }) + | Some c_mod_f_ExecutionReport_OrdStatus -> ((match msg.f_ExecutionReport_ExecType with + | None -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_ExecType_Tag; + repeating_group_origin = None + }) + | Some m_f_ExecutionReport_ExecType -> let c_mod_f_ExecutionReport_ExecType = convert__full_to_model_ExecType m_f_ExecutionReport_ExecType + in + (match c_mod_f_ExecutionReport_ExecType with + | None -> (FIX_TL_Req_Field_Invalid { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_ExecType_Tag; + repeating_group_origin = None + }) + | Some c_mod_f_ExecutionReport_ExecType -> ((match msg.f_ExecutionReport_ExecID with + | None -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_ExecID_Tag; + repeating_group_origin = None + }) + | Some m_f_ExecutionReport_ExecID -> let c_mod_f_ExecutionReport_ExecID = m_f_ExecutionReport_ExecID + in + (match msg.f_ExecutionReport_OrderID with + | None -> (FIX_TL_Req_Field_Missing { + field_missing_of_invalid_data_msg = M_Msg_ExecutionReport_Tag; + field_missing_or_invalid_data_field = M_Field_OrderID_Tag; + repeating_group_origin = None + }) + | Some m_f_ExecutionReport_OrderID -> let c_mod_f_ExecutionReport_OrderID = m_f_ExecutionReport_OrderID + in + let fix_msg_data = { + mod_def_opt_f_ExecutionReport_OrderID = c_mod_f_ExecutionReport_OrderID; + mod_def_opt_f_ExecutionReport_ExecID = c_mod_f_ExecutionReport_ExecID; + mod_def_opt_f_ExecutionReport_ExecType = c_mod_f_ExecutionReport_ExecType; + mod_def_opt_f_ExecutionReport_OrdStatus = c_mod_f_ExecutionReport_OrdStatus; + mod_def_opt_f_ExecutionReport_Side = c_mod_f_ExecutionReport_Side; + mod_def_opt_f_ExecutionReport_OrderQtyData_OrderQty = c_mod_f_ExecutionReport_OrderQtyData_OrderQty; + mod_def_opt_f_ExecutionReport_LeavesQty = c_mod_f_ExecutionReport_LeavesQty; + mod_def_opt_f_ExecutionReport_CumQty = c_mod_f_ExecutionReport_CumQty; + mod_def_opt_f_ExecutionReport_Text = c_mod_f_ExecutionReport_Text; + mod_def_opt_f_ExecutionReport_Parties = c_mod_f_ExecutionReport_Parties; + mod_def_opt_f_ExecutionReport_ExecInst = c_mod_f_ExecutionReport_ExecInst + } + in + FIX_TL_Normal (FIX_Msg_Def_Opt_ExecutionReport fix_msg_data) + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) ) ) ) + ) ) ) ;; -let convert_full_to_model_fix (msg : full_app_msg_data) = +let convert_full_to_model_fix (msg : full_app_msg_data) = (match msg with - | FIX_Full_Msg_ExecutionReport msg_data -> (convert__full_to_model_ExecutionReport msg_data) | FIX_Full_Msg_NewOrderSingle msg_data -> (convert__full_to_model_NewOrderSingle msg_data) + | FIX_Full_Msg_ExecutionReport msg_data -> (convert__full_to_model_ExecutionReport msg_data) ) ;; +let convert__model_to_full_NewOrderSingle (msg : mod_newordersingle_data) = + FIX_Full_Msg_NewOrderSingle { + f_NewOrderSingle_ClOrdID = msg.mod_f_NewOrderSingle_ClOrdID; + f_NewOrderSingle_Parties = convert__model_to_full_Parties msg.mod_f_NewOrderSingle_Parties; + f_NewOrderSingle_Account = msg.mod_f_NewOrderSingle_Account; + f_NewOrderSingle_ExecInst = Some (convert__model_to_full_ExecInst msg.mod_f_NewOrderSingle_ExecInst list_model_vals_ExecInst); + f_NewOrderSingle_Side = Some (convert__model_to_full_Side msg.mod_f_NewOrderSingle_Side); + f_NewOrderSingle_TransactTime = Some msg.mod_f_NewOrderSingle_TransactTime; + f_NewOrderSingle_OrderQtyData = { + f_OrderQtyData_OrderQty = Some msg.mod_f_NewOrderSingle_OrderQtyData_OrderQty + }; + f_NewOrderSingle_OrdType = Some (convert__model_to_full_OrdType msg.mod_f_NewOrderSingle_OrdType); + f_NewOrderSingle_Price = msg.mod_f_NewOrderSingle_Price; + f_NewOrderSingle_SpreadProportion = msg.mod_f_NewOrderSingle_SpreadProportion + } + [@@macro] +;; + let convert__model_to_full_ExecutionReport (msg : mod_executionreport_data) = FIX_Full_Msg_ExecutionReport { f_ExecutionReport_OrderID = Some msg.mod_f_ExecutionReport_OrderID; - f_ExecutionReport_SecondaryOrderID = None; - f_ExecutionReport_SecondaryClOrdID = None; - f_ExecutionReport_SecondaryExecID = None; - f_ExecutionReport_ClOrdID = Some msg.mod_f_ExecutionReport_ClOrdID; - f_ExecutionReport_OrigClOrdID = None; - f_ExecutionReport_ClOrdLinkID = None; - f_ExecutionReport_QuoteRespID = None; - f_ExecutionReport_OrdStatusReqID = None; - f_ExecutionReport_MassStatusReqID = None; - f_ExecutionReport_TotNumReports = None; - f_ExecutionReport_LastRptRequested = None; - f_ExecutionReport_Parties = []; - f_ExecutionReport_TradeOriginationDate = None; - f_ExecutionReport_ContraGrp = []; - f_ExecutionReport_ListID = None; - f_ExecutionReport_CrossID = None; - f_ExecutionReport_OrigCrossID = None; - f_ExecutionReport_CrossType = None; + f_ExecutionReport_Parties = convert__model_to_full_Parties msg.mod_f_ExecutionReport_Parties; f_ExecutionReport_ExecID = Some msg.mod_f_ExecutionReport_ExecID; - f_ExecutionReport_ExecRefID = None; f_ExecutionReport_ExecType = Some (convert__model_to_full_ExecType msg.mod_f_ExecutionReport_ExecType); f_ExecutionReport_OrdStatus = Some (convert__model_to_full_OrdStatus msg.mod_f_ExecutionReport_OrdStatus); - f_ExecutionReport_WorkingIndicator = None; - f_ExecutionReport_OrdRejReason = None; - f_ExecutionReport_ExecRestatementReason = None; - f_ExecutionReport_Account = None; - f_ExecutionReport_AcctIDSource = None; - f_ExecutionReport_AccountType = None; - f_ExecutionReport_DayBookingInst = None; - f_ExecutionReport_BookingUnit = None; - f_ExecutionReport_PreallocMethod = None; - f_ExecutionReport_SettlType = None; - f_ExecutionReport_SettlDate = None; - f_ExecutionReport_CashMargin = None; - f_ExecutionReport_ClearingFeeIndicator = None; - f_ExecutionReport_Instrument = { - f_Instrument_Symbol = Some msg.mod_f_ExecutionReport_Instrument_Symbol; - f_Instrument_SymbolSfx = None; - f_Instrument_SecurityID = None; - f_Instrument_SecurityIDSource = None; - f_Instrument_SecAltIDGrp = []; - f_Instrument_Product = None; - f_Instrument_CFICode = None; - f_Instrument_SecurityType = None; - f_Instrument_SecuritySubType = None; - f_Instrument_MaturityMonthYear = None; - f_Instrument_MaturityDate = None; - f_Instrument_CouponPaymentDate = None; - f_Instrument_IssueDate = None; - f_Instrument_RepoCollateralSecurityType = None; - f_Instrument_RepurchaseTerm = None; - f_Instrument_RepurchaseRate = None; - f_Instrument_Factor = None; - f_Instrument_CreditRating = None; - f_Instrument_InstrRegistry = None; - f_Instrument_CountryOfIssue = None; - f_Instrument_StateOrProvinceOfIssue = None; - f_Instrument_LocaleOfIssue = None; - f_Instrument_RedemptionDate = None; - f_Instrument_StrikePrice = None; - f_Instrument_StrikeCurrency = None; - f_Instrument_OptAttribute = None; - f_Instrument_ContractMultiplier = None; - f_Instrument_CouponRate = None; - f_Instrument_SecurityExchange = None; - f_Instrument_Issuer = None; - f_Instrument_EncodedIssuerLen = None; - f_Instrument_EncodedIssuer = None; - f_Instrument_SecurityDesc = None; - f_Instrument_EncodedSecurityDescLen = None; - f_Instrument_EncodedSecurityDesc = None; - f_Instrument_Pool = None; - f_Instrument_ContractSettlMonth = None; - f_Instrument_CPProgram = None; - f_Instrument_CPRegType = None; - f_Instrument_EvntGrp = []; - f_Instrument_DatedDate = None; - f_Instrument_InterestAccrualDate = None - }; - f_ExecutionReport_FinancingDetails = { - f_FinancingDetails_AgreementDesc = None; - f_FinancingDetails_AgreementID = None; - f_FinancingDetails_AgreementDate = None; - f_FinancingDetails_AgreementCurrency = None; - f_FinancingDetails_TerminationType = None; - f_FinancingDetails_StartDate = None; - f_FinancingDetails_EndDate = None; - f_FinancingDetails_DeliveryType = None; - f_FinancingDetails_MarginRatio = None - }; - f_ExecutionReport_UndInstrmtGrp = []; f_ExecutionReport_Side = Some (convert__model_to_full_Side msg.mod_f_ExecutionReport_Side); - f_ExecutionReport_Stipulations = []; - f_ExecutionReport_QtyType = None; f_ExecutionReport_OrderQtyData = { - f_OrderQtyData_OrderQty = None; - f_OrderQtyData_CashOrderQty = None; - f_OrderQtyData_OrderPercent = None; - f_OrderQtyData_RoundingDirection = None; - f_OrderQtyData_RoundingModulus = None - }; - f_ExecutionReport_OrdType = None; - f_ExecutionReport_PriceType = None; - f_ExecutionReport_Price = None; - f_ExecutionReport_StopPx = None; - f_ExecutionReport_PegInstructions = { - f_PegInstructions_PegOffsetValue = None; - f_PegInstructions_PegMoveType = None; - f_PegInstructions_PegOffsetType = None; - f_PegInstructions_PegLimitType = None; - f_PegInstructions_PegRoundDirection = None; - f_PegInstructions_PegScope = None + f_OrderQtyData_OrderQty = Some msg.mod_f_ExecutionReport_OrderQtyData_OrderQty }; - f_ExecutionReport_DiscretionInstructions = { - f_DiscretionInstructions_DiscretionInst = None; - f_DiscretionInstructions_DiscretionOffsetValue = None; - f_DiscretionInstructions_DiscretionMoveType = None; - f_DiscretionInstructions_DiscretionOffsetType = None; - f_DiscretionInstructions_DiscretionLimitType = None; - f_DiscretionInstructions_DiscretionRoundDirection = None; - f_DiscretionInstructions_DiscretionScope = None - }; - f_ExecutionReport_PeggedPrice = None; - f_ExecutionReport_DiscretionPrice = None; - f_ExecutionReport_TargetStrategy = None; - f_ExecutionReport_TargetStrategyParameters = None; - f_ExecutionReport_ParticipationRate = None; - f_ExecutionReport_TargetStrategyPerformance = None; - f_ExecutionReport_Currency = None; - f_ExecutionReport_ComplianceID = None; - f_ExecutionReport_SolicitedFlag = None; - f_ExecutionReport_TimeInForce = None; - f_ExecutionReport_EffectiveTime = None; - f_ExecutionReport_ExpireDate = None; - f_ExecutionReport_ExpireTime = None; - f_ExecutionReport_ExecInst = None; - f_ExecutionReport_OrderCapacity = None; - f_ExecutionReport_OrderRestrictions = None; - f_ExecutionReport_CustOrderCapacity = None; - f_ExecutionReport_LastQty = None; - f_ExecutionReport_UnderlyingLastQty = None; - f_ExecutionReport_LastPx = None; - f_ExecutionReport_UnderlyingLastPx = None; - f_ExecutionReport_LastParPx = None; - f_ExecutionReport_LastSpotRate = None; - f_ExecutionReport_LastForwardPoints = None; - f_ExecutionReport_LastMkt = None; - f_ExecutionReport_TradingSessionID = None; - f_ExecutionReport_TradingSessionSubID = None; - f_ExecutionReport_TimeBracket = None; - f_ExecutionReport_LastCapacity = None; + f_ExecutionReport_ExecInst = Some (convert__model_to_full_ExecInst msg.mod_f_ExecutionReport_ExecInst list_model_vals_ExecInst); f_ExecutionReport_LeavesQty = Some msg.mod_f_ExecutionReport_LeavesQty; f_ExecutionReport_CumQty = Some msg.mod_f_ExecutionReport_CumQty; - f_ExecutionReport_AvgPx = Some msg.mod_f_ExecutionReport_AvgPx; - f_ExecutionReport_DayOrderQty = None; - f_ExecutionReport_DayCumQty = None; - f_ExecutionReport_DayAvgPx = None; - f_ExecutionReport_GTBookingInst = None; - f_ExecutionReport_TradeDate = None; - f_ExecutionReport_TransactTime = None; - f_ExecutionReport_ReportToExch = None; - f_ExecutionReport_CommissionData = { - f_CommissionData_Commission = None; - f_CommissionData_CommType = None; - f_CommissionData_CommCurrency = None; - f_CommissionData_FundRenewWaiv = None - }; - f_ExecutionReport_SpreadOrBenchmarkCurveData = { - f_SpreadOrBenchmarkCurveData_Spread = None; - f_SpreadOrBenchmarkCurveData_BenchmarkCurveCurrency = None; - f_SpreadOrBenchmarkCurveData_BenchmarkCurveName = None; - f_SpreadOrBenchmarkCurveData_BenchmarkCurvePoint = None; - f_SpreadOrBenchmarkCurveData_BenchmarkPrice = None; - f_SpreadOrBenchmarkCurveData_BenchmarkPriceType = None; - f_SpreadOrBenchmarkCurveData_BenchmarkSecurityID = None; - f_SpreadOrBenchmarkCurveData_BenchmarkSecurityIDSource = None - }; - f_ExecutionReport_YieldData = { - f_YieldData_YieldType = None; - f_YieldData_Yield = None; - f_YieldData_YieldCalcDate = None; - f_YieldData_YieldRedemptionDate = None; - f_YieldData_YieldRedemptionPrice = None; - f_YieldData_YieldRedemptionPriceType = None - }; - f_ExecutionReport_GrossTradeAmt = None; - f_ExecutionReport_NumDaysInterest = None; - f_ExecutionReport_ExDate = None; - f_ExecutionReport_AccruedInterestRate = None; - f_ExecutionReport_AccruedInterestAmt = None; - f_ExecutionReport_InterestAtMaturity = None; - f_ExecutionReport_EndAccruedInterestAmt = None; - f_ExecutionReport_StartCash = None; - f_ExecutionReport_EndCash = None; - f_ExecutionReport_TradedFlatSwitch = None; - f_ExecutionReport_BasisFeatureDate = None; - f_ExecutionReport_BasisFeaturePrice = None; - f_ExecutionReport_Concession = None; - f_ExecutionReport_TotalTakedown = None; - f_ExecutionReport_NetMoney = None; - f_ExecutionReport_SettlCurrAmt = None; - f_ExecutionReport_SettlCurrency = None; - f_ExecutionReport_SettlCurrFxRate = None; - f_ExecutionReport_SettlCurrFxRateCalc = None; - f_ExecutionReport_HandlInst = None; - f_ExecutionReport_MinQty = None; - f_ExecutionReport_MaxFloor = None; - f_ExecutionReport_PositionEffect = None; - f_ExecutionReport_MaxShow = None; - f_ExecutionReport_BookingType = None; - f_ExecutionReport_Text = msg.mod_f_ExecutionReport_Text; - f_ExecutionReport_EncodedTextLen = None; - f_ExecutionReport_EncodedText = None; - f_ExecutionReport_SettlDate2 = None; - f_ExecutionReport_OrderQty2 = None; - f_ExecutionReport_LastForwardPoints2 = None; - f_ExecutionReport_MultiLegReportingType = None; - f_ExecutionReport_CancellationRights = None; - f_ExecutionReport_MoneyLaunderingStatus = None; - f_ExecutionReport_RegistID = None; - f_ExecutionReport_Designation = None; - f_ExecutionReport_TransBkdTime = None; - f_ExecutionReport_ExecValuationPoint = None; - f_ExecutionReport_ExecPriceType = None; - f_ExecutionReport_ExecPriceAdjustment = None; - f_ExecutionReport_PriorityIndicator = None; - f_ExecutionReport_PriceImprovement = None; - f_ExecutionReport_LastLiquidityInd = None; - f_ExecutionReport_ContAmtGrp = []; - f_ExecutionReport_InstrmtLegExecGrp = []; - f_ExecutionReport_CopyMsgIndicator = None; - f_ExecutionReport_MiscFeesGrp = [] - } - [@@macro] -;; - -let convert__model_to_full_NewOrderSingle (msg : mod_newordersingle_data) = - FIX_Full_Msg_NewOrderSingle { - f_NewOrderSingle_ClOrdID = Some msg.mod_f_NewOrderSingle_ClOrdID; - f_NewOrderSingle_SecondaryClOrdID = None; - f_NewOrderSingle_ClOrdLinkID = None; - f_NewOrderSingle_Parties = []; - f_NewOrderSingle_TradeOriginationDate = None; - f_NewOrderSingle_TradeDate = None; - f_NewOrderSingle_Account = None; - f_NewOrderSingle_AcctIDSource = None; - f_NewOrderSingle_AccountType = None; - f_NewOrderSingle_DayBookingInst = None; - f_NewOrderSingle_BookingUnit = None; - f_NewOrderSingle_PreallocMethod = None; - f_NewOrderSingle_AllocID = None; - f_NewOrderSingle_PreAllocGrp = []; - f_NewOrderSingle_SettlType = None; - f_NewOrderSingle_SettlDate = None; - f_NewOrderSingle_CashMargin = None; - f_NewOrderSingle_ClearingFeeIndicator = None; - f_NewOrderSingle_HandlInst = None; - f_NewOrderSingle_ExecInst = None; - f_NewOrderSingle_MinQty = None; - f_NewOrderSingle_MaxFloor = None; - f_NewOrderSingle_ExDestination = None; - f_NewOrderSingle_TrdgSesGrp = []; - f_NewOrderSingle_ProcessCode = None; - f_NewOrderSingle_Instrument = { - f_Instrument_Symbol = Some msg.mod_f_NewOrderSingle_Instrument_Symbol; - f_Instrument_SymbolSfx = None; - f_Instrument_SecurityID = None; - f_Instrument_SecurityIDSource = None; - f_Instrument_SecAltIDGrp = []; - f_Instrument_Product = None; - f_Instrument_CFICode = None; - f_Instrument_SecurityType = None; - f_Instrument_SecuritySubType = None; - f_Instrument_MaturityMonthYear = None; - f_Instrument_MaturityDate = None; - f_Instrument_CouponPaymentDate = None; - f_Instrument_IssueDate = None; - f_Instrument_RepoCollateralSecurityType = None; - f_Instrument_RepurchaseTerm = None; - f_Instrument_RepurchaseRate = None; - f_Instrument_Factor = None; - f_Instrument_CreditRating = None; - f_Instrument_InstrRegistry = None; - f_Instrument_CountryOfIssue = None; - f_Instrument_StateOrProvinceOfIssue = None; - f_Instrument_LocaleOfIssue = None; - f_Instrument_RedemptionDate = None; - f_Instrument_StrikePrice = None; - f_Instrument_StrikeCurrency = None; - f_Instrument_OptAttribute = None; - f_Instrument_ContractMultiplier = None; - f_Instrument_CouponRate = None; - f_Instrument_SecurityExchange = None; - f_Instrument_Issuer = None; - f_Instrument_EncodedIssuerLen = None; - f_Instrument_EncodedIssuer = None; - f_Instrument_SecurityDesc = None; - f_Instrument_EncodedSecurityDescLen = None; - f_Instrument_EncodedSecurityDesc = None; - f_Instrument_Pool = None; - f_Instrument_ContractSettlMonth = None; - f_Instrument_CPProgram = None; - f_Instrument_CPRegType = None; - f_Instrument_EvntGrp = []; - f_Instrument_DatedDate = None; - f_Instrument_InterestAccrualDate = None - }; - f_NewOrderSingle_FinancingDetails = { - f_FinancingDetails_AgreementDesc = None; - f_FinancingDetails_AgreementID = None; - f_FinancingDetails_AgreementDate = None; - f_FinancingDetails_AgreementCurrency = None; - f_FinancingDetails_TerminationType = None; - f_FinancingDetails_StartDate = None; - f_FinancingDetails_EndDate = None; - f_FinancingDetails_DeliveryType = None; - f_FinancingDetails_MarginRatio = None - }; - f_NewOrderSingle_UndInstrmtGrp = []; - f_NewOrderSingle_PrevClosePx = None; - f_NewOrderSingle_Side = Some (convert__model_to_full_Side msg.mod_f_NewOrderSingle_Side); - f_NewOrderSingle_LocateReqd = None; - f_NewOrderSingle_TransactTime = Some msg.mod_f_NewOrderSingle_TransactTime; - f_NewOrderSingle_Stipulations = []; - f_NewOrderSingle_QtyType = None; - f_NewOrderSingle_OrderQtyData = { - f_OrderQtyData_OrderQty = None; - f_OrderQtyData_CashOrderQty = None; - f_OrderQtyData_OrderPercent = None; - f_OrderQtyData_RoundingDirection = None; - f_OrderQtyData_RoundingModulus = None - }; - f_NewOrderSingle_OrdType = Some (convert__model_to_full_OrdType msg.mod_f_NewOrderSingle_OrdType); - f_NewOrderSingle_PriceType = None; - f_NewOrderSingle_Price = None; - f_NewOrderSingle_StopPx = None; - f_NewOrderSingle_SpreadOrBenchmarkCurveData = { - f_SpreadOrBenchmarkCurveData_Spread = None; - f_SpreadOrBenchmarkCurveData_BenchmarkCurveCurrency = None; - f_SpreadOrBenchmarkCurveData_BenchmarkCurveName = None; - f_SpreadOrBenchmarkCurveData_BenchmarkCurvePoint = None; - f_SpreadOrBenchmarkCurveData_BenchmarkPrice = None; - f_SpreadOrBenchmarkCurveData_BenchmarkPriceType = None; - f_SpreadOrBenchmarkCurveData_BenchmarkSecurityID = None; - f_SpreadOrBenchmarkCurveData_BenchmarkSecurityIDSource = None - }; - f_NewOrderSingle_YieldData = { - f_YieldData_YieldType = None; - f_YieldData_Yield = None; - f_YieldData_YieldCalcDate = None; - f_YieldData_YieldRedemptionDate = None; - f_YieldData_YieldRedemptionPrice = None; - f_YieldData_YieldRedemptionPriceType = None - }; - f_NewOrderSingle_Currency = None; - f_NewOrderSingle_ComplianceID = None; - f_NewOrderSingle_SolicitedFlag = None; - f_NewOrderSingle_IOIID = None; - f_NewOrderSingle_QuoteID = None; - f_NewOrderSingle_TimeInForce = None; - f_NewOrderSingle_EffectiveTime = None; - f_NewOrderSingle_ExpireDate = None; - f_NewOrderSingle_ExpireTime = None; - f_NewOrderSingle_GTBookingInst = None; - f_NewOrderSingle_CommissionData = { - f_CommissionData_Commission = None; - f_CommissionData_CommType = None; - f_CommissionData_CommCurrency = None; - f_CommissionData_FundRenewWaiv = None - }; - f_NewOrderSingle_OrderCapacity = None; - f_NewOrderSingle_OrderRestrictions = None; - f_NewOrderSingle_CustOrderCapacity = None; - f_NewOrderSingle_ForexReq = None; - f_NewOrderSingle_SettlCurrency = None; - f_NewOrderSingle_BookingType = None; - f_NewOrderSingle_Text = None; - f_NewOrderSingle_EncodedTextLen = None; - f_NewOrderSingle_EncodedText = None; - f_NewOrderSingle_SettlDate2 = None; - f_NewOrderSingle_OrderQty2 = None; - f_NewOrderSingle_Price2 = None; - f_NewOrderSingle_PositionEffect = None; - f_NewOrderSingle_CoveredOrUncovered = None; - f_NewOrderSingle_MaxShow = None; - f_NewOrderSingle_PegInstructions = { - f_PegInstructions_PegOffsetValue = None; - f_PegInstructions_PegMoveType = None; - f_PegInstructions_PegOffsetType = None; - f_PegInstructions_PegLimitType = None; - f_PegInstructions_PegRoundDirection = None; - f_PegInstructions_PegScope = None - }; - f_NewOrderSingle_DiscretionInstructions = { - f_DiscretionInstructions_DiscretionInst = None; - f_DiscretionInstructions_DiscretionOffsetValue = None; - f_DiscretionInstructions_DiscretionMoveType = None; - f_DiscretionInstructions_DiscretionOffsetType = None; - f_DiscretionInstructions_DiscretionLimitType = None; - f_DiscretionInstructions_DiscretionRoundDirection = None; - f_DiscretionInstructions_DiscretionScope = None - }; - f_NewOrderSingle_TargetStrategy = None; - f_NewOrderSingle_TargetStrategyParameters = None; - f_NewOrderSingle_ParticipationRate = None; - f_NewOrderSingle_CancellationRights = None; - f_NewOrderSingle_MoneyLaunderingStatus = None; - f_NewOrderSingle_RegistID = None; - f_NewOrderSingle_Designation = None + f_ExecutionReport_Text = msg.mod_f_ExecutionReport_Text } [@@macro] ;; let convert_model_to_full_fix (msg : model_msg) = (match msg with - | FIX_Msg_ExecutionReport msg_data -> (convert__model_to_full_ExecutionReport msg_data) | FIX_Msg_NewOrderSingle msg_data -> (convert__model_to_full_NewOrderSingle msg_data) + | FIX_Msg_ExecutionReport msg_data -> (convert__model_to_full_ExecutionReport msg_data) ) ;; -[@@@logic] diff --git a/src-model/src-string-factory/dune b/src-model/src-string-factory/dune index 20bd030b..b7a2f6e7 100644 --- a/src-model/src-string-factory/dune +++ b/src-model/src-string-factory/dune @@ -1,7 +1,7 @@ (library - (name string_factory) - (public_name fix-engine.string_factory) - (wrapped false) - (flags - (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) - (libraries imandra-prelude venue_types)) + (name string_factory) + (public_name fix-engine.string_factory) + (wrapped false) + (flags (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) + (libraries imandra-prelude venue_types) +) diff --git a/src-model/src-string-factory/enum_tag_assoc.iml b/src-model/src-string-factory/enum_tag_assoc.iml index 2366be68..d3c388ca 100644 --- a/src-model/src-string-factory/enum_tag_assoc.iml +++ b/src-model/src-string-factory/enum_tag_assoc.iml @@ -1,7 +1,145 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] -let case_tag_pairs = ("Side.Buy","1") :: (("Side.Sell","2") :: (("Side.BuyMinus","3") :: (("Side.SellPlus","4") :: (("Side.SellShort","5") :: (("Side.SellShortExempt","6") :: (("Side.Undisclosed","7") :: (("Side.Cross","8") :: (("Side.CrossShort","9") :: (("Side.CrossShortExempt","A") :: (("Side.AsDefined","B") :: (("Side.Opposite","C") :: (("Side.Subscribe","D") :: (("Side.Redeem","E") :: (("Side.Lend","F") :: (("Side.Borrow","G") :: (("ExecType.New","0") :: (("ExecType.DoneForDay","3") :: (("ExecType.Canceled","4") :: (("ExecType.Replaced","5") :: (("ExecType.PendingCancel","6") :: (("ExecType.Stopped","7") :: (("ExecType.Rejected","8") :: (("ExecType.Suspended","9") :: (("ExecType.PendingNew","A") :: (("ExecType.Calculated","B") :: (("ExecType.Expired","C") :: (("ExecType.Restated","D") :: (("ExecType.PendingReplace","E") :: (("ExecType.Trade","F") :: (("ExecType.TradeCorrect","G") :: (("ExecType.TradeCancel","H") :: (("ExecType.OrderStatus","I") :: (("OrdStatus.New","0") :: (("OrdStatus.PartiallyFilled","1") :: (("OrdStatus.Filled","2") :: (("OrdStatus.DoneForDay","3") :: (("OrdStatus.Canceled","4") :: (("OrdStatus.PendingCancel","6") :: (("OrdStatus.Stopped","7") :: (("OrdStatus.Rejected","8") :: (("OrdStatus.Suspended","9") :: (("OrdStatus.PendingNew","A") :: (("OrdStatus.Calculated","B") :: (("OrdStatus.Expired","C") :: (("OrdStatus.AcceptedForBidding","D") :: (("OrdStatus.PendingReplace","E") :: (("OrdStatus.Replaced","5") :: (("OrdType.Market","1") :: (("OrdType.Limit","2") :: (("OrdType.Stop","3") :: (("OrdType.StopLimit","4") :: (("OrdType.WithOrWithout","6") :: (("OrdType.LimitOrBetter","7") :: (("OrdType.LimitWithOrWithout","8") :: (("OrdType.OnBasis","9") :: (("OrdType.PreviouslyQuoted","D") :: (("OrdType.PreviouslyIndicated","E") :: (("OrdType.ForexSwap","G") :: (("OrdType.Funari","I") :: (("OrdType.MarketIfTouched","J") :: (("OrdType.MarketWithLeftOverAsLimit","K") :: (("OrdType.PreviousFundValuationPoint","L") :: (("OrdType.NextFundValuationPoint","M") :: (("OrdType.Pegged","P") :: [])))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) [@@macro];; +let case_tag_pairs = [(("Side.Buy","1")); +(("Side.Sell","2")); +(("Side.BuyMinus","3")); +(("Side.SellPlus","4")); +(("Side.SellShort","5")); +(("Side.SellShortExempt","6")); +(("Side.Undisclosed","7")); +(("Side.Cross","8")); +(("Side.CrossShort","9")); +(("Side.CrossShortExempt","A")); +(("Side.AsDefined","B")); +(("Side.Opposite","C")); +(("Side.Subscribe","D")); +(("Side.Redeem","E")); +(("Side.Lend","F")); +(("Side.Borrow","G")); +(("OrdType.Market","1")); +(("OrdType.Limit","2")); +(("OrdType.Stop","3")); +(("OrdType.StopLimit","4")); +(("OrdType.WithOrWithout","6")); +(("OrdType.LimitOrBetter","7")); +(("OrdType.LimitWithOrWithout","8")); +(("OrdType.OnBasis","9")); +(("OrdType.PreviouslyQuoted","D")); +(("OrdType.PreviouslyIndicated","E")); +(("OrdType.ForexSwap","G")); +(("OrdType.Funari","I")); +(("OrdType.MarketIfTouched","J")); +(("OrdType.MarketWithLeftOverAsLimit","K")); +(("OrdType.PreviousFundValuationPoint","L")); +(("OrdType.NextFundValuationPoint","M")); +(("OrdType.Pegged","P")); +(("OrdType.StopSpread","s")); +(("ExecInst.NotHeld","1")); +(("ExecInst.Work","2")); +(("ExecInst.GoAlong","3")); +(("ExecInst.OverTheDay","4")); +(("ExecInst.Held","5")); +(("ExecInst.ParticipateDoNotInitiate","6")); +(("ExecInst.StrictScale","7")); +(("ExecInst.TryToScale","8")); +(("ExecInst.StayOnBidSide","9")); +(("ExecInst.StayOnOfferSide","0")); +(("ExecInst.NoCross","A")); +(("ExecInst.OKToCross","B")); +(("ExecInst.CallFirst","C")); +(("ExecInst.PercentOfVolume","D")); +(("ExecInst.DoNotIncrease","E")); +(("ExecInst.DoNotReduce","F")); +(("ExecInst.AllOrNone","G")); +(("ExecInst.ReinstateOnSystemFailure","H")); +(("ExecInst.InstitutionsOnly","I")); +(("ExecInst.ReinstateOnTradingHalt","J")); +(("ExecInst.CancelOnTradingHalt","K")); +(("ExecInst.LastPeg","L")); +(("ExecInst.MidPricePeg","M")); +(("ExecInst.NonNegotiable","N")); +(("ExecInst.OpeningPeg","O")); +(("ExecInst.MarketPeg","P")); +(("ExecInst.CancelOnSystemFailure","Q")); +(("ExecInst.PrimaryPeg","R")); +(("ExecInst.Suspend","S")); +(("ExecInst.CustomerDisplayInstruction","U")); +(("ExecInst.Netting","V")); +(("ExecInst.PegToVWAP","W")); +(("ExecInst.TradeAlong","X")); +(("ExecInst.TryToStop","Y")); +(("ExecInst.CancelIfNotBest","Z")); +(("ExecInst.TrailingStopPeg","a")); +(("ExecInst.StrictLimit","b")); +(("ExecInst.IgnorePriceValidityChecks","c")); +(("ExecInst.PegToLimitPrice","d")); +(("ExecInst.WorkToTargetStrategy","e")); +(("ExecType.New","0")); +(("ExecType.DoneForDay","3")); +(("ExecType.Canceled","4")); +(("ExecType.Replaced","5")); +(("ExecType.PendingCancel","6")); +(("ExecType.Stopped","7")); +(("ExecType.Rejected","8")); +(("ExecType.Suspended","9")); +(("ExecType.PendingNew","A")); +(("ExecType.Calculated","B")); +(("ExecType.Expired","C")); +(("ExecType.Restated","D")); +(("ExecType.PendingReplace","E")); +(("ExecType.Trade","F")); +(("ExecType.TradeCorrect","G")); +(("ExecType.TradeCancel","H")); +(("ExecType.OrderStatus","I")); +(("OrdStatus.New","0")); +(("OrdStatus.PartiallyFilled","1")); +(("OrdStatus.Filled","2")); +(("OrdStatus.DoneForDay","3")); +(("OrdStatus.Canceled","4")); +(("OrdStatus.PendingCancel","6")); +(("OrdStatus.Stopped","7")); +(("OrdStatus.Rejected","8")); +(("OrdStatus.Suspended","9")); +(("OrdStatus.PendingNew","A")); +(("OrdStatus.Calculated","B")); +(("OrdStatus.Expired","C")); +(("OrdStatus.AcceptedForBidding","D")); +(("OrdStatus.PendingReplace","E")); +(("OrdStatus.Replaced","5")); +(("PartySubIDType.Firm","1")); +(("PartySubIDType.Person","2")); +(("PartySubIDType.System","3")); +(("PartySubIDType.Application","4")); +(("PartySubIDType.FullLegalNameOfFirm","5")); +(("PartySubIDType.PostalAddress","6")); +(("PartySubIDType.PhoneNumber","7")); +(("PartySubIDType.EmailAddress","8")); +(("PartySubIDType.ContactName","9")); +(("PartySubIDType.SecuritiesAccountNumber","10")); +(("PartySubIDType.RegistrationNumber","11")); +(("PartySubIDType.RegisteredAddressForConfirmation","12")); +(("PartySubIDType.RegulatoryStatus","13")); +(("PartySubIDType.RegistrationName","14")); +(("PartySubIDType.CashAccountNumber","15")); +(("PartySubIDType.BIC","16")); +(("PartySubIDType.CSDParticipantMemberCode","17")); +(("PartySubIDType.RegisteredAddress","18")); +(("PartySubIDType.FundAccountName","19")); +(("PartySubIDType.TelexNumber","20")); +(("PartySubIDType.FaxNumber","21")); +(("PartySubIDType.SecuritiesAccountName","22")); +(("PartySubIDType.CashAccountName","23")); +(("PartySubIDType.Department","24")); +(("PartySubIDType.LocationDesk","25")); +(("PartySubIDType.PositionAccountType","26"))] ;; + +let separator_char (x) = + (match x with + | "ExecInst" -> " " + | _ -> " " + ) +;; [@@@logic] diff --git a/src-model/src-string-factory/model_tag_names.iml b/src-model/src-string-factory/model_tag_names.iml index 83c4f6e0..e0c8d9c0 100644 --- a/src-model/src-string-factory/model_tag_names.iml +++ b/src-model/src-string-factory/model_tag_names.iml @@ -1,5 +1,7 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; [@@@import "../src-types/model_tags.iml"] open Model_tags;; @@ -7,17 +9,34 @@ open Model_tags;; let tag_to_message (x) = (match x with | "D" -> (Some M_Msg_NewOrderSingle_Tag) + | "8" -> (Some M_Msg_ExecutionReport_Tag) + | _ -> None + ) +;; + +let tag_to_rg (x) = + (match x with + | "PtysSubGrp" -> (Some MOD_FIX_Repeating_Group_PtysSubGrp) + | "Parties" -> (Some MOD_FIX_Repeating_Group_Parties) | _ -> None ) ;; let tag_to_field (x) = (match x with - | "55" -> (Some M_Field_Symbol_Tag) - | "60" -> (Some M_Field_TransactTime_Tag) | "54" -> (Some M_Field_Side_Tag) - | "11" -> (Some M_Field_ClOrdID_Tag) + | "60" -> (Some M_Field_TransactTime_Tag) | "40" -> (Some M_Field_OrdType_Tag) + | "38" -> (Some M_Field_OrderQty_Tag) + | "18" -> (Some M_Field_ExecInst_Tag) + | "448" -> (Some M_Field_PartyID_Tag) + | "10002" -> (Some M_Field_PartyIndex_Tag) + | "37" -> (Some M_Field_OrderID_Tag) + | "17" -> (Some M_Field_ExecID_Tag) + | "150" -> (Some M_Field_ExecType_Tag) + | "39" -> (Some M_Field_OrdStatus_Tag) + | "151" -> (Some M_Field_LeavesQty_Tag) + | "14" -> (Some M_Field_CumQty_Tag) | _ -> None ) ;; diff --git a/src-model/src-string-factory/string_assoc.iml b/src-model/src-string-factory/string_assoc.iml index d87658fd..cdb71e6d 100644 --- a/src-model/src-string-factory/string_assoc.iml +++ b/src-model/src-string-factory/string_assoc.iml @@ -1,4 +1,4 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@import "string_assoc_common.iml"] open String_assoc_common;; diff --git a/src-model/src-string-factory/string_assoc_common.iml b/src-model/src-string-factory/string_assoc_common.iml index 5cb1076b..848acfb9 100644 --- a/src-model/src-string-factory/string_assoc_common.iml +++ b/src-model/src-string-factory/string_assoc_common.iml @@ -1,7 +1,273 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] -let string_pairs = ("Model_messages.mod_executionreport_data","ExecutionReport") :: (("Model_messages.mod_newordersingle_data","NewOrderSingle") :: (("Model_messages.FIX_Msg_ExecutionReport","ExecutionReport") :: (("Model_messages.FIX_Msg_NewOrderSingle","NewOrderSingle") :: (("Model_messages.mod_f_ExecutionReport_ClOrdID","ClOrdID") :: (("Model_messages.mod_f_ExecutionReport_OrderID","OrderID") :: (("Model_messages.mod_f_ExecutionReport_ExecID","ExecID") :: (("Model_messages.mod_f_ExecutionReport_ExecType","ExecType") :: (("Model_messages.mod_f_ExecutionReport_AvgPx","AvgPx") :: (("Model_messages.mod_f_ExecutionReport_Side","Side") :: (("Model_messages.mod_f_ExecutionReport_LeavesQty","LeavesQty") :: (("Model_messages.mod_f_ExecutionReport_CumQty","CumQty") :: (("Model_messages.mod_f_ExecutionReport_OrdStatus","OrdStatus") :: (("Model_messages.mod_f_ExecutionReport_Instrument_Symbol","Instrument.Symbol") :: (("Model_messages.mod_f_ExecutionReport_Text","Text") :: (("Model_messages.mod_f_NewOrderSingle_ClOrdID","ClOrdID") :: (("Model_messages.mod_f_NewOrderSingle_Side","Side") :: (("Model_messages.mod_f_NewOrderSingle_TransactTime","TransactTime") :: (("Model_messages.mod_f_NewOrderSingle_OrdType","OrdType") :: (("Model_messages.mod_f_NewOrderSingle_Instrument_Symbol","Instrument.Symbol") :: (("Model_app_enums.model_fix_side","Side") :: (("Model_app_enums.model_fix_exectype","ExecType") :: (("Model_app_enums.model_fix_ordstatus","OrdStatus") :: (("Model_app_enums.model_fix_ordtype","OrdType") :: (("Model_app_enums.MOD_FIX_Side_Buy","Side.Buy") :: (("Model_app_enums.MOD_FIX_Side_Sell","Side.Sell") :: (("Model_app_enums.MOD_FIX_Side_BuyMinus","Side.BuyMinus") :: (("Model_app_enums.MOD_FIX_Side_SellPlus","Side.SellPlus") :: (("Model_app_enums.MOD_FIX_Side_SellShort","Side.SellShort") :: (("Model_app_enums.MOD_FIX_Side_SellShortExempt","Side.SellShortExempt") :: (("Model_app_enums.MOD_FIX_Side_Undisclosed","Side.Undisclosed") :: (("Model_app_enums.MOD_FIX_Side_Cross","Side.Cross") :: (("Model_app_enums.MOD_FIX_Side_CrossShort","Side.CrossShort") :: (("Model_app_enums.MOD_FIX_Side_CrossShortExempt","Side.CrossShortExempt") :: (("Model_app_enums.MOD_FIX_Side_AsDefined","Side.AsDefined") :: (("Model_app_enums.MOD_FIX_Side_Opposite","Side.Opposite") :: (("Model_app_enums.MOD_FIX_Side_Subscribe","Side.Subscribe") :: (("Model_app_enums.MOD_FIX_Side_Redeem","Side.Redeem") :: (("Model_app_enums.MOD_FIX_Side_Lend","Side.Lend") :: (("Model_app_enums.MOD_FIX_Side_Borrow","Side.Borrow") :: (("Model_app_enums.MOD_FIX_ExecType_New","ExecType.New") :: (("Model_app_enums.MOD_FIX_ExecType_DoneForDay","ExecType.DoneForDay") :: (("Model_app_enums.MOD_FIX_ExecType_Canceled","ExecType.Canceled") :: (("Model_app_enums.MOD_FIX_ExecType_Replaced","ExecType.Replaced") :: (("Model_app_enums.MOD_FIX_ExecType_PendingCancel","ExecType.PendingCancel") :: (("Model_app_enums.MOD_FIX_ExecType_Stopped","ExecType.Stopped") :: (("Model_app_enums.MOD_FIX_ExecType_Rejected","ExecType.Rejected") :: (("Model_app_enums.MOD_FIX_ExecType_Suspended","ExecType.Suspended") :: (("Model_app_enums.MOD_FIX_ExecType_PendingNew","ExecType.PendingNew") :: (("Model_app_enums.MOD_FIX_ExecType_Calculated","ExecType.Calculated") :: (("Model_app_enums.MOD_FIX_ExecType_Expired","ExecType.Expired") :: (("Model_app_enums.MOD_FIX_ExecType_Restated","ExecType.Restated") :: (("Model_app_enums.MOD_FIX_ExecType_PendingReplace","ExecType.PendingReplace") :: (("Model_app_enums.MOD_FIX_ExecType_Trade","ExecType.Trade") :: (("Model_app_enums.MOD_FIX_ExecType_TradeCorrect","ExecType.TradeCorrect") :: (("Model_app_enums.MOD_FIX_ExecType_TradeCancel","ExecType.TradeCancel") :: (("Model_app_enums.MOD_FIX_ExecType_OrderStatus","ExecType.OrderStatus") :: (("Model_app_enums.MOD_FIX_OrdStatus_New","OrdStatus.New") :: (("Model_app_enums.MOD_FIX_OrdStatus_PartiallyFilled","OrdStatus.PartiallyFilled") :: (("Model_app_enums.MOD_FIX_OrdStatus_Filled","OrdStatus.Filled") :: (("Model_app_enums.MOD_FIX_OrdStatus_DoneForDay","OrdStatus.DoneForDay") :: (("Model_app_enums.MOD_FIX_OrdStatus_Canceled","OrdStatus.Canceled") :: (("Model_app_enums.MOD_FIX_OrdStatus_PendingCancel","OrdStatus.PendingCancel") :: (("Model_app_enums.MOD_FIX_OrdStatus_Stopped","OrdStatus.Stopped") :: (("Model_app_enums.MOD_FIX_OrdStatus_Rejected","OrdStatus.Rejected") :: (("Model_app_enums.MOD_FIX_OrdStatus_Suspended","OrdStatus.Suspended") :: (("Model_app_enums.MOD_FIX_OrdStatus_PendingNew","OrdStatus.PendingNew") :: (("Model_app_enums.MOD_FIX_OrdStatus_Calculated","OrdStatus.Calculated") :: (("Model_app_enums.MOD_FIX_OrdStatus_Expired","OrdStatus.Expired") :: (("Model_app_enums.MOD_FIX_OrdStatus_AcceptedForBidding","OrdStatus.AcceptedForBidding") :: (("Model_app_enums.MOD_FIX_OrdStatus_PendingReplace","OrdStatus.PendingReplace") :: (("Model_app_enums.MOD_FIX_OrdStatus_Replaced","OrdStatus.Replaced") :: (("Model_app_enums.MOD_FIX_OrdType_Market","OrdType.Market") :: (("Model_app_enums.MOD_FIX_OrdType_Limit","OrdType.Limit") :: (("Model_app_enums.MOD_FIX_OrdType_Stop","OrdType.Stop") :: (("Model_app_enums.MOD_FIX_OrdType_StopLimit","OrdType.StopLimit") :: (("Model_app_enums.MOD_FIX_OrdType_WithOrWithout","OrdType.WithOrWithout") :: (("Model_app_enums.MOD_FIX_OrdType_LimitOrBetter","OrdType.LimitOrBetter") :: (("Model_app_enums.MOD_FIX_OrdType_LimitWithOrWithout","OrdType.LimitWithOrWithout") :: (("Model_app_enums.MOD_FIX_OrdType_OnBasis","OrdType.OnBasis") :: (("Model_app_enums.MOD_FIX_OrdType_PreviouslyQuoted","OrdType.PreviouslyQuoted") :: (("Model_app_enums.MOD_FIX_OrdType_PreviouslyIndicated","OrdType.PreviouslyIndicated") :: (("Model_app_enums.MOD_FIX_OrdType_ForexSwap","OrdType.ForexSwap") :: (("Model_app_enums.MOD_FIX_OrdType_Funari","OrdType.Funari") :: (("Model_app_enums.MOD_FIX_OrdType_MarketIfTouched","OrdType.MarketIfTouched") :: (("Model_app_enums.MOD_FIX_OrdType_MarketWithLeftOverAsLimit","OrdType.MarketWithLeftOverAsLimit") :: (("Model_app_enums.MOD_FIX_OrdType_PreviousFundValuationPoint","OrdType.PreviousFundValuationPoint") :: (("Model_app_enums.MOD_FIX_OrdType_NextFundValuationPoint","OrdType.NextFundValuationPoint") :: (("Model_app_enums.MOD_FIX_OrdType_Pegged","OrdType.Pegged") :: (("Model_tags.M_Field_ClOrdID_Tag","ClOrdID") :: (("Model_tags.M_Field_OrderID_Tag","OrderID") :: (("Model_tags.M_Field_ExecID_Tag","ExecID") :: (("Model_tags.M_Field_ExecType_Tag","ExecType") :: (("Model_tags.M_Field_AvgPx_Tag","AvgPx") :: (("Model_tags.M_Field_Side_Tag","Side") :: (("Model_tags.M_Field_LeavesQty_Tag","LeavesQty") :: (("Model_tags.M_Field_CumQty_Tag","CumQty") :: (("Model_tags.M_Field_OrdStatus_Tag","OrdStatus") :: (("Model_tags.M_Field_Symbol_Tag","Symbol") :: (("Model_tags.M_Field_Text_Tag","Text") :: (("Model_tags.M_Msg_ExecutionReport_Tag","ExecutionReport") :: (("Model_tags.M_Field_ClOrdID_Tag","ClOrdID") :: (("Model_tags.M_Field_Side_Tag","Side") :: (("Model_tags.M_Field_TransactTime_Tag","TransactTime") :: (("Model_tags.M_Field_OrdType_Tag","OrdType") :: (("Model_tags.M_Field_Symbol_Tag","Symbol") :: (("Model_tags.M_Msg_NewOrderSingle_Tag","NewOrderSingle") :: [])))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) [@@macro];; +let string_pairs = [(("Actions.FIX_Action_fill","fill")); +(("Actions.FIX_Action_bookState","bookState")); +(("Model_records.m_action_fix_fill","fill")); +(("Model_records.m_action_fix_bookstate","bookState")); +(("Model_messages.mod_newordersingle_data","NewOrderSingle")); +(("Model_messages.mod_executionreport_data","ExecutionReport")); +(("Model_messages.mod_newordersingle_data","NewOrderSingle")); +(("Model_messages.mod_executionreport_data","ExecutionReport")); +(("Model_messages.mod_newordersingle_defopt_data","NewOrderSingle")); +(("Model_messages.mod_executionreport_defopt_data","ExecutionReport")); +(("State.fix_internal_state","state")); +(("State.fix_internal_fresh_state'","fresh_state'")); +(("f_internal_state","state")); +(("f_internal_fresh_state'","fresh_state'")); +(("Model_messages.FIX_Msg_NewOrderSingle","NewOrderSingle")); +(("Model_messages.FIX_Msg_ExecutionReport","ExecutionReport")); +(("Model_messages.FIX_Msg_Def_Opt_NewOrderSingle","NewOrderSingle")); +(("Model_messages.FIX_Msg_Def_Opt_ExecutionReport","ExecutionReport")); +(("Model_records.m_action_fix_bookstate","bookState")); +(("Model_records.m_action_fix_fill","fill")); +(("Model_repeating_groups.model_fix_rec_ptyssubgrp","PtysSubGrp")); +(("Model_repeating_groups.rg_PtysSubGrp_element_0","0")); +(("Model_repeating_groups.rg_PtysSubGrp_element_1","1")); +(("Model_repeating_groups.rg_PtysSubGrp_element_2","2")); +(("Model_repeating_groups.rg_PtysSubGrp_element_3","3")); +(("Model_repeating_groups.rg_PtysSubGrp_element_4","4")); +(("Model_repeating_groups.model_fix_rec_parties","Parties")); +(("Model_repeating_groups.rg_Parties_element_0","0")); +(("Model_repeating_groups.rg_Parties_element_1","1")); +(("Model_repeating_groups.rg_Parties_element_2","2")); +(("Model_repeating_groups.rg_Parties_element_3","3")); +(("Model_repeating_groups.rg_Parties_element_4","4")); +(("Model_records.mod_f_fill_fill_price","fill_price")); +(("Model_records.mod_f_fill_fill_qty","fill_qty")); +(("Model_records.mod_f_bookState_bestBid","bestBid")); +(("Model_records.mod_f_bookState_bestAsk","bestAsk")); +(("Model_records.mod_f_bookState_bestBid","bestBid")); +(("Model_records.mod_f_bookState_bestAsk","bestAsk")); +(("Model_records.mod_f_fill_fill_price","fill_price")); +(("Model_records.mod_f_fill_fill_qty","fill_qty")); +(("Ipl_functions.model_func_fresh_string'","fresh_string'")); +(("Model_messages.mod_f_NewOrderSingle_ClOrdID","ClOrdID")); +(("Model_messages.mod_f_NewOrderSingle_Side","Side")); +(("Model_messages.mod_f_NewOrderSingle_TransactTime","TransactTime")); +(("Model_messages.mod_f_NewOrderSingle_OrdType","OrdType")); +(("Model_messages.mod_f_NewOrderSingle_OrderQtyData_OrderQty","OrderQtyData.OrderQty")); +(("Model_messages.mod_f_NewOrderSingle_SpreadProportion","SpreadProportion")); +(("Model_messages.mod_f_NewOrderSingle_Price","Price")); +(("Model_messages.mod_f_NewOrderSingle_Account","Account")); +(("Model_messages.mod_f_NewOrderSingle_ExecInst","ExecInst")); +(("Model_messages.mod_f_NewOrderSingle_Parties","Parties")); +(("Model_messages.mod_f_ExecutionReport_OrderID","OrderID")); +(("Model_messages.mod_f_ExecutionReport_ExecID","ExecID")); +(("Model_messages.mod_f_ExecutionReport_ExecType","ExecType")); +(("Model_messages.mod_f_ExecutionReport_OrdStatus","OrdStatus")); +(("Model_messages.mod_f_ExecutionReport_Side","Side")); +(("Model_messages.mod_f_ExecutionReport_OrderQtyData_OrderQty","OrderQtyData.OrderQty")); +(("Model_messages.mod_f_ExecutionReport_LeavesQty","LeavesQty")); +(("Model_messages.mod_f_ExecutionReport_CumQty","CumQty")); +(("Model_messages.mod_f_ExecutionReport_Text","Text")); +(("Model_messages.mod_f_ExecutionReport_Parties","Parties")); +(("Model_messages.mod_f_ExecutionReport_ExecInst","ExecInst")); +(("Model_messages.mod_def_opt_f_NewOrderSingle_ClOrdID","ClOrdID")); +(("Model_messages.mod_def_opt_f_NewOrderSingle_Side","Side")); +(("Model_messages.mod_def_opt_f_NewOrderSingle_TransactTime","TransactTime")); +(("Model_messages.mod_def_opt_f_NewOrderSingle_OrdType","OrdType")); +(("Model_messages.mod_def_opt_f_NewOrderSingle_OrderQtyData_OrderQty","OrderQtyData.OrderQty")); +(("Model_messages.mod_def_opt_f_NewOrderSingle_SpreadProportion","SpreadProportion")); +(("Model_messages.mod_def_opt_f_NewOrderSingle_Price","Price")); +(("Model_messages.mod_def_opt_f_NewOrderSingle_Account","Account")); +(("Model_messages.mod_def_opt_f_NewOrderSingle_ExecInst","ExecInst")); +(("Model_messages.mod_def_opt_f_NewOrderSingle_Parties","Parties")); +(("Model_messages.mod_def_opt_f_ExecutionReport_OrderID","OrderID")); +(("Model_messages.mod_def_opt_f_ExecutionReport_ExecID","ExecID")); +(("Model_messages.mod_def_opt_f_ExecutionReport_ExecType","ExecType")); +(("Model_messages.mod_def_opt_f_ExecutionReport_OrdStatus","OrdStatus")); +(("Model_messages.mod_def_opt_f_ExecutionReport_Side","Side")); +(("Model_messages.mod_def_opt_f_ExecutionReport_OrderQtyData_OrderQty","OrderQtyData.OrderQty")); +(("Model_messages.mod_def_opt_f_ExecutionReport_LeavesQty","LeavesQty")); +(("Model_messages.mod_def_opt_f_ExecutionReport_CumQty","CumQty")); +(("Model_messages.mod_def_opt_f_ExecutionReport_Text","Text")); +(("Model_messages.mod_def_opt_f_ExecutionReport_Parties","Parties")); +(("Model_messages.mod_def_opt_f_ExecutionReport_ExecInst","ExecInst")); +(("State.mod_f_internal_state_live_order","state.live_order")); +(("State.mod_f_internal_state_AvgPx","state.AvgPx")); +(("State.mod_f_internal_state_bestBid","state.bestBid")); +(("State.mod_f_internal_state_bestAsk","state.bestAsk")); +(("State.mod_f_internal_fresh_state'_seed_string","fresh_state'.seed_string")); +(("State.mod_f_internal_state_Side","state.Side")); +(("State.mod_f_internal_state_Price","state.Price")); +(("State.mod_f_internal_state_OrderQtyData_OrderQty","state.OrderQtyData.OrderQty")); +(("State.mod_f_internal_state_OrdStatus","state.OrdStatus")); +(("State.mod_f_internal_state_OrdType","state.OrdType")); +(("State.mod_f_internal_state_LeavesQty","state.LeavesQty")); +(("State.mod_f_internal_state_CumQty","state.CumQty")); +(("State.mod_f_internal_state_SpreadProportion","state.SpreadProportion")); +(("State.mod_f_internal_state_Parties","state.Parties")); +(("State.mod_f_internal_state_ExecInst","state.ExecInst")); +(("State.mod_f_internal_state_OrderID","state.OrderID")); +(("State.mod_f_internal_state_ExecType","state.ExecType")); +(("Model_repeating_groups.mod_f_PtysSubGrp_NoPartySubIDs","NoPartySubIDs")); +(("Model_repeating_groups.mod_f_PtysSubGrp_PartySubID","PartySubID")); +(("Model_repeating_groups.mod_f_Parties_NoPartyIDs","NoPartyIDs")); +(("Model_repeating_groups.mod_f_Parties_PartyID","PartyID")); +(("mod_f_Parties_PartyIndex","PartyIndex")); +(("Model_repeating_groups.mod_f_Parties_PtysSubGrp","PtysSubGrp")); +(("Model_app_enums.model_fix_side","Side")); +(("Model_app_enums.model_fix_ordtype","OrdType")); +(("Model_app_enums.model_fix_execinst","ExecInst")); +(("Model_app_enums.model_fix_exectype","ExecType")); +(("Model_app_enums.model_fix_ordstatus","OrdStatus")); +(("Model_app_enums.model_fix_partysubidtype","PartySubIDType")); +(("Model_app_enums.MOD_FIX_Side_Buy","Side.Buy")); +(("Model_app_enums.MOD_FIX_Side_Sell","Side.Sell")); +(("Model_app_enums.MOD_FIX_Side_BuyMinus","Side.BuyMinus")); +(("Model_app_enums.MOD_FIX_Side_SellPlus","Side.SellPlus")); +(("Model_app_enums.MOD_FIX_Side_SellShort","Side.SellShort")); +(("Model_app_enums.MOD_FIX_Side_SellShortExempt","Side.SellShortExempt")); +(("Model_app_enums.MOD_FIX_Side_Undisclosed","Side.Undisclosed")); +(("Model_app_enums.MOD_FIX_Side_Cross","Side.Cross")); +(("Model_app_enums.MOD_FIX_Side_CrossShort","Side.CrossShort")); +(("Model_app_enums.MOD_FIX_Side_CrossShortExempt","Side.CrossShortExempt")); +(("Model_app_enums.MOD_FIX_Side_AsDefined","Side.AsDefined")); +(("Model_app_enums.MOD_FIX_Side_Opposite","Side.Opposite")); +(("Model_app_enums.MOD_FIX_Side_Subscribe","Side.Subscribe")); +(("Model_app_enums.MOD_FIX_Side_Redeem","Side.Redeem")); +(("Model_app_enums.MOD_FIX_Side_Lend","Side.Lend")); +(("Model_app_enums.MOD_FIX_Side_Borrow","Side.Borrow")); +(("Model_app_enums.MOD_FIX_OrdType_Market","OrdType.Market")); +(("Model_app_enums.MOD_FIX_OrdType_Limit","OrdType.Limit")); +(("Model_app_enums.MOD_FIX_OrdType_Stop","OrdType.Stop")); +(("Model_app_enums.MOD_FIX_OrdType_StopLimit","OrdType.StopLimit")); +(("Model_app_enums.MOD_FIX_OrdType_WithOrWithout","OrdType.WithOrWithout")); +(("Model_app_enums.MOD_FIX_OrdType_LimitOrBetter","OrdType.LimitOrBetter")); +(("Model_app_enums.MOD_FIX_OrdType_LimitWithOrWithout","OrdType.LimitWithOrWithout")); +(("Model_app_enums.MOD_FIX_OrdType_OnBasis","OrdType.OnBasis")); +(("Model_app_enums.MOD_FIX_OrdType_PreviouslyQuoted","OrdType.PreviouslyQuoted")); +(("Model_app_enums.MOD_FIX_OrdType_PreviouslyIndicated","OrdType.PreviouslyIndicated")); +(("Model_app_enums.MOD_FIX_OrdType_ForexSwap","OrdType.ForexSwap")); +(("Model_app_enums.MOD_FIX_OrdType_Funari","OrdType.Funari")); +(("Model_app_enums.MOD_FIX_OrdType_MarketIfTouched","OrdType.MarketIfTouched")); +(("Model_app_enums.MOD_FIX_OrdType_MarketWithLeftOverAsLimit","OrdType.MarketWithLeftOverAsLimit")); +(("Model_app_enums.MOD_FIX_OrdType_PreviousFundValuationPoint","OrdType.PreviousFundValuationPoint")); +(("Model_app_enums.MOD_FIX_OrdType_NextFundValuationPoint","OrdType.NextFundValuationPoint")); +(("Model_app_enums.MOD_FIX_OrdType_Pegged","OrdType.Pegged")); +(("Model_app_enums.MOD_FIX_OrdType_StopSpread","OrdType.StopSpread")); +(("Model_app_enums.MOD_FIX_ExecInst_NotHeld","ExecInst.NotHeld")); +(("Model_app_enums.MOD_FIX_ExecInst_Work","ExecInst.Work")); +(("Model_app_enums.MOD_FIX_ExecInst_GoAlong","ExecInst.GoAlong")); +(("Model_app_enums.MOD_FIX_ExecInst_OverTheDay","ExecInst.OverTheDay")); +(("Model_app_enums.MOD_FIX_ExecInst_Held","ExecInst.Held")); +(("Model_app_enums.MOD_FIX_ExecInst_ParticipateDoNotInitiate","ExecInst.ParticipateDoNotInitiate")); +(("Model_app_enums.MOD_FIX_ExecInst_StrictScale","ExecInst.StrictScale")); +(("Model_app_enums.MOD_FIX_ExecInst_TryToScale","ExecInst.TryToScale")); +(("Model_app_enums.MOD_FIX_ExecInst_StayOnBidSide","ExecInst.StayOnBidSide")); +(("Model_app_enums.MOD_FIX_ExecInst_StayOnOfferSide","ExecInst.StayOnOfferSide")); +(("Model_app_enums.MOD_FIX_ExecInst_NoCross","ExecInst.NoCross")); +(("Model_app_enums.MOD_FIX_ExecInst_OKToCross","ExecInst.OKToCross")); +(("Model_app_enums.MOD_FIX_ExecInst_CallFirst","ExecInst.CallFirst")); +(("Model_app_enums.MOD_FIX_ExecInst_PercentOfVolume","ExecInst.PercentOfVolume")); +(("Model_app_enums.MOD_FIX_ExecInst_DoNotIncrease","ExecInst.DoNotIncrease")); +(("Model_app_enums.MOD_FIX_ExecInst_DoNotReduce","ExecInst.DoNotReduce")); +(("Model_app_enums.MOD_FIX_ExecInst_AllOrNone","ExecInst.AllOrNone")); +(("Model_app_enums.MOD_FIX_ExecInst_ReinstateOnSystemFailure","ExecInst.ReinstateOnSystemFailure")); +(("Model_app_enums.MOD_FIX_ExecInst_InstitutionsOnly","ExecInst.InstitutionsOnly")); +(("Model_app_enums.MOD_FIX_ExecInst_ReinstateOnTradingHalt","ExecInst.ReinstateOnTradingHalt")); +(("Model_app_enums.MOD_FIX_ExecInst_CancelOnTradingHalt","ExecInst.CancelOnTradingHalt")); +(("Model_app_enums.MOD_FIX_ExecInst_LastPeg","ExecInst.LastPeg")); +(("Model_app_enums.MOD_FIX_ExecInst_MidPricePeg","ExecInst.MidPricePeg")); +(("Model_app_enums.MOD_FIX_ExecInst_NonNegotiable","ExecInst.NonNegotiable")); +(("Model_app_enums.MOD_FIX_ExecInst_OpeningPeg","ExecInst.OpeningPeg")); +(("Model_app_enums.MOD_FIX_ExecInst_MarketPeg","ExecInst.MarketPeg")); +(("Model_app_enums.MOD_FIX_ExecInst_CancelOnSystemFailure","ExecInst.CancelOnSystemFailure")); +(("Model_app_enums.MOD_FIX_ExecInst_PrimaryPeg","ExecInst.PrimaryPeg")); +(("Model_app_enums.MOD_FIX_ExecInst_Suspend","ExecInst.Suspend")); +(("Model_app_enums.MOD_FIX_ExecInst_CustomerDisplayInstruction","ExecInst.CustomerDisplayInstruction")); +(("Model_app_enums.MOD_FIX_ExecInst_Netting","ExecInst.Netting")); +(("Model_app_enums.MOD_FIX_ExecInst_PegToVWAP","ExecInst.PegToVWAP")); +(("Model_app_enums.MOD_FIX_ExecInst_TradeAlong","ExecInst.TradeAlong")); +(("Model_app_enums.MOD_FIX_ExecInst_TryToStop","ExecInst.TryToStop")); +(("Model_app_enums.MOD_FIX_ExecInst_CancelIfNotBest","ExecInst.CancelIfNotBest")); +(("Model_app_enums.MOD_FIX_ExecInst_TrailingStopPeg","ExecInst.TrailingStopPeg")); +(("Model_app_enums.MOD_FIX_ExecInst_StrictLimit","ExecInst.StrictLimit")); +(("Model_app_enums.MOD_FIX_ExecInst_IgnorePriceValidityChecks","ExecInst.IgnorePriceValidityChecks")); +(("Model_app_enums.MOD_FIX_ExecInst_PegToLimitPrice","ExecInst.PegToLimitPrice")); +(("Model_app_enums.MOD_FIX_ExecInst_WorkToTargetStrategy","ExecInst.WorkToTargetStrategy")); +(("Model_app_enums.MOD_FIX_ExecType_New","ExecType.New")); +(("Model_app_enums.MOD_FIX_ExecType_DoneForDay","ExecType.DoneForDay")); +(("Model_app_enums.MOD_FIX_ExecType_Canceled","ExecType.Canceled")); +(("Model_app_enums.MOD_FIX_ExecType_Replaced","ExecType.Replaced")); +(("Model_app_enums.MOD_FIX_ExecType_PendingCancel","ExecType.PendingCancel")); +(("Model_app_enums.MOD_FIX_ExecType_Stopped","ExecType.Stopped")); +(("Model_app_enums.MOD_FIX_ExecType_Rejected","ExecType.Rejected")); +(("Model_app_enums.MOD_FIX_ExecType_Suspended","ExecType.Suspended")); +(("Model_app_enums.MOD_FIX_ExecType_PendingNew","ExecType.PendingNew")); +(("Model_app_enums.MOD_FIX_ExecType_Calculated","ExecType.Calculated")); +(("Model_app_enums.MOD_FIX_ExecType_Expired","ExecType.Expired")); +(("Model_app_enums.MOD_FIX_ExecType_Restated","ExecType.Restated")); +(("Model_app_enums.MOD_FIX_ExecType_PendingReplace","ExecType.PendingReplace")); +(("Model_app_enums.MOD_FIX_ExecType_Trade","ExecType.Trade")); +(("Model_app_enums.MOD_FIX_ExecType_TradeCorrect","ExecType.TradeCorrect")); +(("Model_app_enums.MOD_FIX_ExecType_TradeCancel","ExecType.TradeCancel")); +(("Model_app_enums.MOD_FIX_ExecType_OrderStatus","ExecType.OrderStatus")); +(("Model_app_enums.MOD_FIX_OrdStatus_New","OrdStatus.New")); +(("Model_app_enums.MOD_FIX_OrdStatus_PartiallyFilled","OrdStatus.PartiallyFilled")); +(("Model_app_enums.MOD_FIX_OrdStatus_Filled","OrdStatus.Filled")); +(("Model_app_enums.MOD_FIX_OrdStatus_DoneForDay","OrdStatus.DoneForDay")); +(("Model_app_enums.MOD_FIX_OrdStatus_Canceled","OrdStatus.Canceled")); +(("Model_app_enums.MOD_FIX_OrdStatus_PendingCancel","OrdStatus.PendingCancel")); +(("Model_app_enums.MOD_FIX_OrdStatus_Stopped","OrdStatus.Stopped")); +(("Model_app_enums.MOD_FIX_OrdStatus_Rejected","OrdStatus.Rejected")); +(("Model_app_enums.MOD_FIX_OrdStatus_Suspended","OrdStatus.Suspended")); +(("Model_app_enums.MOD_FIX_OrdStatus_PendingNew","OrdStatus.PendingNew")); +(("Model_app_enums.MOD_FIX_OrdStatus_Calculated","OrdStatus.Calculated")); +(("Model_app_enums.MOD_FIX_OrdStatus_Expired","OrdStatus.Expired")); +(("Model_app_enums.MOD_FIX_OrdStatus_AcceptedForBidding","OrdStatus.AcceptedForBidding")); +(("Model_app_enums.MOD_FIX_OrdStatus_PendingReplace","OrdStatus.PendingReplace")); +(("Model_app_enums.MOD_FIX_OrdStatus_Replaced","OrdStatus.Replaced")); +(("Model_app_enums.MOD_FIX_PartySubIDType_Firm","PartySubIDType.Firm")); +(("Model_app_enums.MOD_FIX_PartySubIDType_Person","PartySubIDType.Person")); +(("Model_app_enums.MOD_FIX_PartySubIDType_System","PartySubIDType.System")); +(("Model_app_enums.MOD_FIX_PartySubIDType_Application","PartySubIDType.Application")); +(("Model_app_enums.MOD_FIX_PartySubIDType_FullLegalNameOfFirm","PartySubIDType.FullLegalNameOfFirm")); +(("Model_app_enums.MOD_FIX_PartySubIDType_PostalAddress","PartySubIDType.PostalAddress")); +(("Model_app_enums.MOD_FIX_PartySubIDType_PhoneNumber","PartySubIDType.PhoneNumber")); +(("Model_app_enums.MOD_FIX_PartySubIDType_EmailAddress","PartySubIDType.EmailAddress")); +(("Model_app_enums.MOD_FIX_PartySubIDType_ContactName","PartySubIDType.ContactName")); +(("Model_app_enums.MOD_FIX_PartySubIDType_SecuritiesAccountNumber","PartySubIDType.SecuritiesAccountNumber")); +(("Model_app_enums.MOD_FIX_PartySubIDType_RegistrationNumber","PartySubIDType.RegistrationNumber")); +(("Model_app_enums.MOD_FIX_PartySubIDType_RegisteredAddressForConfirmation","PartySubIDType.RegisteredAddressForConfirmation")); +(("Model_app_enums.MOD_FIX_PartySubIDType_RegulatoryStatus","PartySubIDType.RegulatoryStatus")); +(("Model_app_enums.MOD_FIX_PartySubIDType_RegistrationName","PartySubIDType.RegistrationName")); +(("Model_app_enums.MOD_FIX_PartySubIDType_CashAccountNumber","PartySubIDType.CashAccountNumber")); +(("Model_app_enums.MOD_FIX_PartySubIDType_BIC","PartySubIDType.BIC")); +(("Model_app_enums.MOD_FIX_PartySubIDType_CSDParticipantMemberCode","PartySubIDType.CSDParticipantMemberCode")); +(("Model_app_enums.MOD_FIX_PartySubIDType_RegisteredAddress","PartySubIDType.RegisteredAddress")); +(("Model_app_enums.MOD_FIX_PartySubIDType_FundAccountName","PartySubIDType.FundAccountName")); +(("Model_app_enums.MOD_FIX_PartySubIDType_TelexNumber","PartySubIDType.TelexNumber")); +(("Model_app_enums.MOD_FIX_PartySubIDType_FaxNumber","PartySubIDType.FaxNumber")); +(("Model_app_enums.MOD_FIX_PartySubIDType_SecuritiesAccountName","PartySubIDType.SecuritiesAccountName")); +(("Model_app_enums.MOD_FIX_PartySubIDType_CashAccountName","PartySubIDType.CashAccountName")); +(("Model_app_enums.MOD_FIX_PartySubIDType_Department","PartySubIDType.Department")); +(("Model_app_enums.MOD_FIX_PartySubIDType_LocationDesk","PartySubIDType.LocationDesk")); +(("Model_app_enums.MOD_FIX_PartySubIDType_PositionAccountType","PartySubIDType.PositionAccountType")); +(("Model_tags.M_Field_ClOrdID_Tag","ClOrdID")); +(("Model_tags.M_Field_Side_Tag","Side")); +(("Model_tags.M_Field_TransactTime_Tag","TransactTime")); +(("Model_tags.M_Field_OrdType_Tag","OrdType")); +(("Model_tags.M_Field_OrderQty_Tag","OrderQty")); +(("Model_tags.M_Field_SpreadProportion_Tag","SpreadProportion")); +(("Model_tags.M_Field_Price_Tag","Price")); +(("Model_tags.M_Field_Account_Tag","Account")); +(("Model_tags.M_Field_ExecInst_Tag","ExecInst")); +(("Model_tags.M_Field_Parties_Tag","Parties")); +(("Model_tags.M_Msg_NewOrderSingle_Tag","NewOrderSingle")); +(("Model_tags.M_Field_OrderID_Tag","OrderID")); +(("Model_tags.M_Field_ExecID_Tag","ExecID")); +(("Model_tags.M_Field_ExecType_Tag","ExecType")); +(("Model_tags.M_Field_OrdStatus_Tag","OrdStatus")); +(("Model_tags.M_Field_Side_Tag","Side")); +(("Model_tags.M_Field_OrderQty_Tag","OrderQty")); +(("Model_tags.M_Field_LeavesQty_Tag","LeavesQty")); +(("Model_tags.M_Field_CumQty_Tag","CumQty")); +(("Model_tags.M_Field_Text_Tag","Text")); +(("Model_tags.M_Field_Parties_Tag","Parties")); +(("Model_tags.M_Field_ExecInst_Tag","ExecInst")); +(("Model_tags.M_Msg_ExecutionReport_Tag","ExecutionReport"))] ;; [@@@logic] diff --git a/src-model/src-string-factory/string_checks.iml b/src-model/src-string-factory/string_checks.iml index 95791ddf..8da3aeb0 100644 --- a/src-model/src-string-factory/string_checks.iml +++ b/src-model/src-string-factory/string_checks.iml @@ -1,122 +1,156 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-types/actions.iml"] +open Actions;; [@@@import "../src-types/model_messages.iml"] open Model_messages;; let isAction (str : string) = (match str with + | "Actions.FIX_Action_fill" -> true + | "Actions.FIX_Action_bookState" -> true | _ -> false ) - [@@macro] ;; let isActionData (str : string) = (match str with + | "Model_records.m_action_fix_fill" -> true + | "Model_records.m_action_fix_bookstate" -> true | _ -> false ) - [@@macro] ;; let isActionField (str : string) = (match str with + | "Model_records.mod_f_fill_fill_price" -> true + | "Model_records.mod_f_fill_fill_qty" -> true + | "Model_records.mod_f_bookState_bestBid" -> true + | "Model_records.mod_f_bookState_bestAsk" -> true | _ -> false ) - [@@macro] ;; let isModelFieldTag (str : string) = (match str with | "Model_tags.M_Field_ClOrdID_Tag" -> true + | "Model_tags.M_Field_Side_Tag" -> true + | "Model_tags.M_Field_TransactTime_Tag" -> true + | "Model_tags.M_Field_OrdType_Tag" -> true + | "Model_tags.M_Field_OrderQty_Tag" -> true + | "Model_tags.M_Field_SpreadProportion_Tag" -> true + | "Model_tags.M_Field_Price_Tag" -> true + | "Model_tags.M_Field_Account_Tag" -> true + | "Model_tags.M_Field_ExecInst_Tag" -> true + | "Model_tags.M_Field_Parties_Tag" -> true | "Model_tags.M_Field_OrderID_Tag" -> true | "Model_tags.M_Field_ExecID_Tag" -> true | "Model_tags.M_Field_ExecType_Tag" -> true - | "Model_tags.M_Field_AvgPx_Tag" -> true - | "Model_tags.M_Field_Side_Tag" -> true + | "Model_tags.M_Field_OrdStatus_Tag" -> true | "Model_tags.M_Field_LeavesQty_Tag" -> true | "Model_tags.M_Field_CumQty_Tag" -> true - | "Model_tags.M_Field_OrdStatus_Tag" -> true - | "Model_tags.M_Field_Symbol_Tag" -> true | "Model_tags.M_Field_Text_Tag" -> true - | "Model_tags.M_Field_TransactTime_Tag" -> true - | "Model_tags.M_Field_OrdType_Tag" -> true | _ -> false ) ;; let isModelMessageTag (str : string) = (match str with - | "Model_tags.M_Msg_ExecutionReport_Tag" -> true | "Model_tags.M_Msg_NewOrderSingle_Tag" -> true + | "Model_tags.M_Msg_ExecutionReport_Tag" -> true | _ -> false ) ;; let isMessageField (str : string) = (match str with - | "Model_messages.mod_f_ExecutionReport_ClOrdID" -> true + | "Model_messages.mod_f_NewOrderSingle_ClOrdID" -> true + | "Model_messages.mod_f_NewOrderSingle_Side" -> true + | "Model_messages.mod_f_NewOrderSingle_TransactTime" -> true + | "Model_messages.mod_f_NewOrderSingle_OrdType" -> true + | "Model_messages.mod_f_NewOrderSingle_OrderQtyData_OrderQty" -> true + | "Model_messages.mod_f_NewOrderSingle_SpreadProportion" -> true + | "Model_messages.mod_f_NewOrderSingle_Price" -> true + | "Model_messages.mod_f_NewOrderSingle_Account" -> true + | "Model_messages.mod_f_NewOrderSingle_ExecInst" -> true + | "Model_messages.mod_f_NewOrderSingle_Parties" -> true | "Model_messages.mod_f_ExecutionReport_OrderID" -> true | "Model_messages.mod_f_ExecutionReport_ExecID" -> true | "Model_messages.mod_f_ExecutionReport_ExecType" -> true - | "Model_messages.mod_f_ExecutionReport_AvgPx" -> true + | "Model_messages.mod_f_ExecutionReport_OrdStatus" -> true | "Model_messages.mod_f_ExecutionReport_Side" -> true + | "Model_messages.mod_f_ExecutionReport_OrderQtyData_OrderQty" -> true | "Model_messages.mod_f_ExecutionReport_LeavesQty" -> true | "Model_messages.mod_f_ExecutionReport_CumQty" -> true - | "Model_messages.mod_f_ExecutionReport_OrdStatus" -> true - | "Model_messages.mod_f_ExecutionReport_Instrument_Symbol" -> true | "Model_messages.mod_f_ExecutionReport_Text" -> true - | "Model_messages.mod_f_NewOrderSingle_ClOrdID" -> true - | "Model_messages.mod_f_NewOrderSingle_Side" -> true - | "Model_messages.mod_f_NewOrderSingle_TransactTime" -> true - | "Model_messages.mod_f_NewOrderSingle_OrdType" -> true - | "Model_messages.mod_f_NewOrderSingle_Instrument_Symbol" -> true + | "Model_messages.mod_f_ExecutionReport_Parties" -> true + | "Model_messages.mod_f_ExecutionReport_ExecInst" -> true | _ -> false ) ;; let isMessage (str : string) = (match str with - | "Model_messages.FIX_Msg_ExecutionReport" -> true | "Model_messages.FIX_Msg_NewOrderSingle" -> true + | "Model_messages.FIX_Msg_ExecutionReport" -> true | _ -> false ) ;; let isMessageData (str : string) = (match str with - | "Model_messages.mod_executionreport_data" -> true | "Model_messages.mod_newordersingle_data" -> true + | "Model_messages.mod_executionreport_data" -> true | _ -> false ) ;; let isInternal (str : string) = (match str with + | "State.f_internal_state" -> true + | "State.f_internal_fresh_state'" -> true | _ -> false ) - [@@macro] ;; let isInternalField (str : string) = (match str with + | "State.f_internal_state_live_order" -> true + | "State.f_internal_state_AvgPx" -> true + | "State.f_internal_state_bestBid" -> true + | "State.f_internal_state_bestAsk" -> true + | "State.f_internal_fresh_state'_seed_string" -> true | _ -> false ) - [@@macro] ;; let isAssignableField (str : string) = (match str with + | "State.f_internal_state_Side" -> true + | "State.f_internal_state_Price" -> true + | "State.f_internal_state_OrderQtyData" -> true + | "State.f_internal_state_OrdStatus" -> true + | "State.f_internal_state_OrdType" -> true + | "State.f_internal_state_LeavesQty" -> true + | "State.f_internal_state_CumQty" -> true + | "State.f_internal_state_SpreadProportion" -> true + | "State.f_internal_state_Parties" -> true + | "State.f_internal_state_ExecInst" -> true + | "State.f_internal_state_OrderID" -> true + | "State.f_internal_state_ExecType" -> true | _ -> false ) - [@@macro] ;; let isEnum (str : string) = (match str with | "Model_app_enums.model_fix_side" -> true + | "Model_app_enums.model_fix_ordtype" -> true + | "Model_app_enums.model_fix_execinst" -> true | "Model_app_enums.model_fix_exectype" -> true | "Model_app_enums.model_fix_ordstatus" -> true - | "Model_app_enums.model_fix_ordtype" -> true + | "Model_app_enums.model_fix_partysubidtype" -> true | _ -> false ) ;; @@ -139,6 +173,64 @@ let isEnumCase (str : string) = | "Model_app_enums.MOD_FIX_Side_Redeem" -> true | "Model_app_enums.MOD_FIX_Side_Lend" -> true | "Model_app_enums.MOD_FIX_Side_Borrow" -> true + | "Model_app_enums.MOD_FIX_OrdType_Market" -> true + | "Model_app_enums.MOD_FIX_OrdType_Limit" -> true + | "Model_app_enums.MOD_FIX_OrdType_Stop" -> true + | "Model_app_enums.MOD_FIX_OrdType_StopLimit" -> true + | "Model_app_enums.MOD_FIX_OrdType_WithOrWithout" -> true + | "Model_app_enums.MOD_FIX_OrdType_LimitOrBetter" -> true + | "Model_app_enums.MOD_FIX_OrdType_LimitWithOrWithout" -> true + | "Model_app_enums.MOD_FIX_OrdType_OnBasis" -> true + | "Model_app_enums.MOD_FIX_OrdType_PreviouslyQuoted" -> true + | "Model_app_enums.MOD_FIX_OrdType_PreviouslyIndicated" -> true + | "Model_app_enums.MOD_FIX_OrdType_ForexSwap" -> true + | "Model_app_enums.MOD_FIX_OrdType_Funari" -> true + | "Model_app_enums.MOD_FIX_OrdType_MarketIfTouched" -> true + | "Model_app_enums.MOD_FIX_OrdType_MarketWithLeftOverAsLimit" -> true + | "Model_app_enums.MOD_FIX_OrdType_PreviousFundValuationPoint" -> true + | "Model_app_enums.MOD_FIX_OrdType_NextFundValuationPoint" -> true + | "Model_app_enums.MOD_FIX_OrdType_Pegged" -> true + | "Model_app_enums.MOD_FIX_OrdType_StopSpread" -> true + | "Model_app_enums.MOD_FIX_ExecInst_NotHeld" -> true + | "Model_app_enums.MOD_FIX_ExecInst_Work" -> true + | "Model_app_enums.MOD_FIX_ExecInst_GoAlong" -> true + | "Model_app_enums.MOD_FIX_ExecInst_OverTheDay" -> true + | "Model_app_enums.MOD_FIX_ExecInst_Held" -> true + | "Model_app_enums.MOD_FIX_ExecInst_ParticipateDoNotInitiate" -> true + | "Model_app_enums.MOD_FIX_ExecInst_StrictScale" -> true + | "Model_app_enums.MOD_FIX_ExecInst_TryToScale" -> true + | "Model_app_enums.MOD_FIX_ExecInst_StayOnBidSide" -> true + | "Model_app_enums.MOD_FIX_ExecInst_StayOnOfferSide" -> true + | "Model_app_enums.MOD_FIX_ExecInst_NoCross" -> true + | "Model_app_enums.MOD_FIX_ExecInst_OKToCross" -> true + | "Model_app_enums.MOD_FIX_ExecInst_CallFirst" -> true + | "Model_app_enums.MOD_FIX_ExecInst_PercentOfVolume" -> true + | "Model_app_enums.MOD_FIX_ExecInst_DoNotIncrease" -> true + | "Model_app_enums.MOD_FIX_ExecInst_DoNotReduce" -> true + | "Model_app_enums.MOD_FIX_ExecInst_AllOrNone" -> true + | "Model_app_enums.MOD_FIX_ExecInst_ReinstateOnSystemFailure" -> true + | "Model_app_enums.MOD_FIX_ExecInst_InstitutionsOnly" -> true + | "Model_app_enums.MOD_FIX_ExecInst_ReinstateOnTradingHalt" -> true + | "Model_app_enums.MOD_FIX_ExecInst_CancelOnTradingHalt" -> true + | "Model_app_enums.MOD_FIX_ExecInst_LastPeg" -> true + | "Model_app_enums.MOD_FIX_ExecInst_MidPricePeg" -> true + | "Model_app_enums.MOD_FIX_ExecInst_NonNegotiable" -> true + | "Model_app_enums.MOD_FIX_ExecInst_OpeningPeg" -> true + | "Model_app_enums.MOD_FIX_ExecInst_MarketPeg" -> true + | "Model_app_enums.MOD_FIX_ExecInst_CancelOnSystemFailure" -> true + | "Model_app_enums.MOD_FIX_ExecInst_PrimaryPeg" -> true + | "Model_app_enums.MOD_FIX_ExecInst_Suspend" -> true + | "Model_app_enums.MOD_FIX_ExecInst_CustomerDisplayInstruction" -> true + | "Model_app_enums.MOD_FIX_ExecInst_Netting" -> true + | "Model_app_enums.MOD_FIX_ExecInst_PegToVWAP" -> true + | "Model_app_enums.MOD_FIX_ExecInst_TradeAlong" -> true + | "Model_app_enums.MOD_FIX_ExecInst_TryToStop" -> true + | "Model_app_enums.MOD_FIX_ExecInst_CancelIfNotBest" -> true + | "Model_app_enums.MOD_FIX_ExecInst_TrailingStopPeg" -> true + | "Model_app_enums.MOD_FIX_ExecInst_StrictLimit" -> true + | "Model_app_enums.MOD_FIX_ExecInst_IgnorePriceValidityChecks" -> true + | "Model_app_enums.MOD_FIX_ExecInst_PegToLimitPrice" -> true + | "Model_app_enums.MOD_FIX_ExecInst_WorkToTargetStrategy" -> true | "Model_app_enums.MOD_FIX_ExecType_New" -> true | "Model_app_enums.MOD_FIX_ExecType_DoneForDay" -> true | "Model_app_enums.MOD_FIX_ExecType_Canceled" -> true @@ -171,57 +263,70 @@ let isEnumCase (str : string) = | "Model_app_enums.MOD_FIX_OrdStatus_AcceptedForBidding" -> true | "Model_app_enums.MOD_FIX_OrdStatus_PendingReplace" -> true | "Model_app_enums.MOD_FIX_OrdStatus_Replaced" -> true - | "Model_app_enums.MOD_FIX_OrdType_Market" -> true - | "Model_app_enums.MOD_FIX_OrdType_Limit" -> true - | "Model_app_enums.MOD_FIX_OrdType_Stop" -> true - | "Model_app_enums.MOD_FIX_OrdType_StopLimit" -> true - | "Model_app_enums.MOD_FIX_OrdType_WithOrWithout" -> true - | "Model_app_enums.MOD_FIX_OrdType_LimitOrBetter" -> true - | "Model_app_enums.MOD_FIX_OrdType_LimitWithOrWithout" -> true - | "Model_app_enums.MOD_FIX_OrdType_OnBasis" -> true - | "Model_app_enums.MOD_FIX_OrdType_PreviouslyQuoted" -> true - | "Model_app_enums.MOD_FIX_OrdType_PreviouslyIndicated" -> true - | "Model_app_enums.MOD_FIX_OrdType_ForexSwap" -> true - | "Model_app_enums.MOD_FIX_OrdType_Funari" -> true - | "Model_app_enums.MOD_FIX_OrdType_MarketIfTouched" -> true - | "Model_app_enums.MOD_FIX_OrdType_MarketWithLeftOverAsLimit" -> true - | "Model_app_enums.MOD_FIX_OrdType_PreviousFundValuationPoint" -> true - | "Model_app_enums.MOD_FIX_OrdType_NextFundValuationPoint" -> true - | "Model_app_enums.MOD_FIX_OrdType_Pegged" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_Firm" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_Person" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_System" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_Application" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_FullLegalNameOfFirm" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_PostalAddress" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_PhoneNumber" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_EmailAddress" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_ContactName" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_SecuritiesAccountNumber" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_RegistrationNumber" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_RegisteredAddressForConfirmation" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_RegulatoryStatus" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_RegistrationName" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_CashAccountNumber" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_BIC" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_CSDParticipantMemberCode" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_RegisteredAddress" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_FundAccountName" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_TelexNumber" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_FaxNumber" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_SecuritiesAccountName" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_CashAccountName" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_Department" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_LocationDesk" -> true + | "Model_app_enums.MOD_FIX_PartySubIDType_PositionAccountType" -> true | _ -> false ) ;; let isRepeatingGroup (str : string) = (match str with + | "Model_repeating_groups.model_fix_rec_ptyssubgrp" -> true + | "Model_repeating_groups.model_fix_rec_parties" -> true | _ -> false ) - [@@macro] ;; let name_of_action (x) = - "" - [@@macro] + (match x with + | FIX_Action_fill _ -> "Action:fill" + | FIX_Action_bookState _ -> "Action:bookState" + | _ -> "" + ) ;; let name_of_model_msg (x) = (match x with - | FIX_Msg_ExecutionReport _ -> "ExecutionReport" - | FIX_Msg_NewOrderSingle _ -> "NewOrderSingle" + | FIX_Msg_Def_Opt_NewOrderSingle _ -> "NewOrderSingle" + | FIX_Msg_Def_Opt_ExecutionReport _ -> "ExecutionReport" ) ;; let fix_code_of_model_msg (m) = (match m with - | FIX_Msg_ExecutionReport _ -> "8" - | FIX_Msg_NewOrderSingle _ -> "D" + | FIX_Msg_Def_Opt_NewOrderSingle _ -> "D" + | FIX_Msg_Def_Opt_ExecutionReport _ -> "8" ) ;; let fix_code_of_model_msg_name (m) = (match m with - | "ExecutionReport" -> (Some "8") | "NewOrderSingle" -> (Some "D") + | "ExecutionReport" -> (Some "8") | _ -> None ) ;; @@ -230,9 +335,30 @@ let name_of_msg (x) = (match x with | FIX_TL_Normal d -> ((^) "Msg:" (name_of_model_msg d)) | FIX_TL_Req_Field_Missing _ -> "Msg:Field_missing" + | FIX_TL_Req_Field_Invalid _ -> "Msg:Field_invalid" | FIX_TL_PossibleResend _ -> "Msg:Possible_resend" | FIX_TL_None -> "Msg:None" ) ;; +let is_msgfield_optional (x) (y) = + (match x with + | "NewOrderSingle" -> ((match y with + | "ClOrdID" -> true + | "SpreadProportion" -> true + | "Price" -> true + | "Account" -> true + | "ExecInst" -> true + | _ -> false + ) + ) + | "ExecutionReport" -> ((match y with + | "Text" -> true + | _ -> false + ) + ) + | _ -> false + ) +;; + [@@@logic] diff --git a/src-model/src-strings-venue/dune b/src-model/src-strings-venue/dune index 719d16c1..4c1f4495 100644 --- a/src-model/src-strings-venue/dune +++ b/src-model/src-strings-venue/dune @@ -1,7 +1,7 @@ (library - (name venue_strings_venue) - (public_name fix-engine.venue_strings_venue) - (wrapped false) - (flags - (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) - (libraries imandra-prelude venue_types)) + (name venue_strings_venue) + (public_name fix-engine.venue_strings_venue) + (wrapped false) + (flags (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) + (libraries imandra-prelude venue_types) +) diff --git a/src-model/src-strings-venue/model_enum_names.iml b/src-model/src-strings-venue/model_enum_names.iml index 40687808..3fbe3d3a 100644 --- a/src-model/src-strings-venue/model_enum_names.iml +++ b/src-model/src-strings-venue/model_enum_names.iml @@ -1,8 +1,15 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@import "../src-types/model_app_enums.iml"] open Model_app_enums;; +let mod_bool_to_string (x) = + (if x then + "Y" + else + "N") +;; + let mod_side_to_string (d) = (match d with | MOD_FIX_Side_Buy -> "Buy" @@ -24,6 +31,126 @@ let mod_side_to_string (d) = ) ;; +let mod_ordtype_to_string (d) = + (match d with + | MOD_FIX_OrdType_Market -> "Market" + | MOD_FIX_OrdType_Limit -> "Limit" + | MOD_FIX_OrdType_Stop -> "Stop" + | MOD_FIX_OrdType_StopLimit -> "StopLimit" + | MOD_FIX_OrdType_WithOrWithout -> "WithOrWithout" + | MOD_FIX_OrdType_LimitOrBetter -> "LimitOrBetter" + | MOD_FIX_OrdType_LimitWithOrWithout -> "LimitWithOrWithout" + | MOD_FIX_OrdType_OnBasis -> "OnBasis" + | MOD_FIX_OrdType_PreviouslyQuoted -> "PreviouslyQuoted" + | MOD_FIX_OrdType_PreviouslyIndicated -> "PreviouslyIndicated" + | MOD_FIX_OrdType_ForexSwap -> "ForexSwap" + | MOD_FIX_OrdType_Funari -> "Funari" + | MOD_FIX_OrdType_MarketIfTouched -> "MarketIfTouched" + | MOD_FIX_OrdType_MarketWithLeftOverAsLimit -> "MarketWithLeftOverAsLimit" + | MOD_FIX_OrdType_PreviousFundValuationPoint -> "PreviousFundValuationPoint" + | MOD_FIX_OrdType_NextFundValuationPoint -> "NextFundValuationPoint" + | MOD_FIX_OrdType_Pegged -> "Pegged" + | MOD_FIX_OrdType_StopSpread -> "StopSpread" + ) +;; + +let mod_execinst_to_string (d) = + (match d with + | MOD_FIX_ExecInst_NotHeld -> "NotHeld" + | MOD_FIX_ExecInst_Work -> "Work" + | MOD_FIX_ExecInst_GoAlong -> "GoAlong" + | MOD_FIX_ExecInst_OverTheDay -> "OverTheDay" + | MOD_FIX_ExecInst_Held -> "Held" + | MOD_FIX_ExecInst_ParticipateDoNotInitiate -> "ParticipateDoNotInitiate" + | MOD_FIX_ExecInst_StrictScale -> "StrictScale" + | MOD_FIX_ExecInst_TryToScale -> "TryToScale" + | MOD_FIX_ExecInst_StayOnBidSide -> "StayOnBidSide" + | MOD_FIX_ExecInst_StayOnOfferSide -> "StayOnOfferSide" + | MOD_FIX_ExecInst_NoCross -> "NoCross" + | MOD_FIX_ExecInst_OKToCross -> "OKToCross" + | MOD_FIX_ExecInst_CallFirst -> "CallFirst" + | MOD_FIX_ExecInst_PercentOfVolume -> "PercentOfVolume" + | MOD_FIX_ExecInst_DoNotIncrease -> "DoNotIncrease" + | MOD_FIX_ExecInst_DoNotReduce -> "DoNotReduce" + | MOD_FIX_ExecInst_AllOrNone -> "AllOrNone" + | MOD_FIX_ExecInst_ReinstateOnSystemFailure -> "ReinstateOnSystemFailure" + | MOD_FIX_ExecInst_InstitutionsOnly -> "InstitutionsOnly" + | MOD_FIX_ExecInst_ReinstateOnTradingHalt -> "ReinstateOnTradingHalt" + | MOD_FIX_ExecInst_CancelOnTradingHalt -> "CancelOnTradingHalt" + | MOD_FIX_ExecInst_LastPeg -> "LastPeg" + | MOD_FIX_ExecInst_MidPricePeg -> "MidPricePeg" + | MOD_FIX_ExecInst_NonNegotiable -> "NonNegotiable" + | MOD_FIX_ExecInst_OpeningPeg -> "OpeningPeg" + | MOD_FIX_ExecInst_MarketPeg -> "MarketPeg" + | MOD_FIX_ExecInst_CancelOnSystemFailure -> "CancelOnSystemFailure" + | MOD_FIX_ExecInst_PrimaryPeg -> "PrimaryPeg" + | MOD_FIX_ExecInst_Suspend -> "Suspend" + | MOD_FIX_ExecInst_CustomerDisplayInstruction -> "CustomerDisplayInstruction" + | MOD_FIX_ExecInst_Netting -> "Netting" + | MOD_FIX_ExecInst_PegToVWAP -> "PegToVWAP" + | MOD_FIX_ExecInst_TradeAlong -> "TradeAlong" + | MOD_FIX_ExecInst_TryToStop -> "TryToStop" + | MOD_FIX_ExecInst_CancelIfNotBest -> "CancelIfNotBest" + | MOD_FIX_ExecInst_TrailingStopPeg -> "TrailingStopPeg" + | MOD_FIX_ExecInst_StrictLimit -> "StrictLimit" + | MOD_FIX_ExecInst_IgnorePriceValidityChecks -> "IgnorePriceValidityChecks" + | MOD_FIX_ExecInst_PegToLimitPrice -> "PegToLimitPrice" + | MOD_FIX_ExecInst_WorkToTargetStrategy -> "WorkToTargetStrategy" + ) +;; + +let list_model_vals_ExecInst = [(MOD_FIX_ExecInst_NotHeld); +(MOD_FIX_ExecInst_Work); +(MOD_FIX_ExecInst_GoAlong); +(MOD_FIX_ExecInst_OverTheDay); +(MOD_FIX_ExecInst_Held); +(MOD_FIX_ExecInst_ParticipateDoNotInitiate); +(MOD_FIX_ExecInst_StrictScale); +(MOD_FIX_ExecInst_TryToScale); +(MOD_FIX_ExecInst_StayOnBidSide); +(MOD_FIX_ExecInst_StayOnOfferSide); +(MOD_FIX_ExecInst_NoCross); +(MOD_FIX_ExecInst_OKToCross); +(MOD_FIX_ExecInst_CallFirst); +(MOD_FIX_ExecInst_PercentOfVolume); +(MOD_FIX_ExecInst_DoNotIncrease); +(MOD_FIX_ExecInst_DoNotReduce); +(MOD_FIX_ExecInst_AllOrNone); +(MOD_FIX_ExecInst_ReinstateOnSystemFailure); +(MOD_FIX_ExecInst_InstitutionsOnly); +(MOD_FIX_ExecInst_ReinstateOnTradingHalt); +(MOD_FIX_ExecInst_CancelOnTradingHalt); +(MOD_FIX_ExecInst_LastPeg); +(MOD_FIX_ExecInst_MidPricePeg); +(MOD_FIX_ExecInst_NonNegotiable); +(MOD_FIX_ExecInst_OpeningPeg); +(MOD_FIX_ExecInst_MarketPeg); +(MOD_FIX_ExecInst_CancelOnSystemFailure); +(MOD_FIX_ExecInst_PrimaryPeg); +(MOD_FIX_ExecInst_Suspend); +(MOD_FIX_ExecInst_CustomerDisplayInstruction); +(MOD_FIX_ExecInst_Netting); +(MOD_FIX_ExecInst_PegToVWAP); +(MOD_FIX_ExecInst_TradeAlong); +(MOD_FIX_ExecInst_TryToStop); +(MOD_FIX_ExecInst_CancelIfNotBest); +(MOD_FIX_ExecInst_TrailingStopPeg); +(MOD_FIX_ExecInst_StrictLimit); +(MOD_FIX_ExecInst_IgnorePriceValidityChecks); +(MOD_FIX_ExecInst_PegToLimitPrice); +(MOD_FIX_ExecInst_WorkToTargetStrategy)] [@@macro];; + +let rec get_model_enum_vals_ExecInst (f) (x) = + (match x with + | [] -> [] + | h :: t -> ((if (Map.get h f) then + (h :: (get_model_enum_vals_ExecInst f t)) + else + (get_model_enum_vals_ExecInst f t)) + ) + ) +;; + let mod_exectype_to_string (d) = (match d with | MOD_FIX_ExecType_New -> "New" @@ -66,25 +193,34 @@ let mod_ordstatus_to_string (d) = ) ;; -let mod_ordtype_to_string (d) = +let mod_partysubidtype_to_string (d) = (match d with - | MOD_FIX_OrdType_Market -> "Market" - | MOD_FIX_OrdType_Limit -> "Limit" - | MOD_FIX_OrdType_Stop -> "Stop" - | MOD_FIX_OrdType_StopLimit -> "StopLimit" - | MOD_FIX_OrdType_WithOrWithout -> "WithOrWithout" - | MOD_FIX_OrdType_LimitOrBetter -> "LimitOrBetter" - | MOD_FIX_OrdType_LimitWithOrWithout -> "LimitWithOrWithout" - | MOD_FIX_OrdType_OnBasis -> "OnBasis" - | MOD_FIX_OrdType_PreviouslyQuoted -> "PreviouslyQuoted" - | MOD_FIX_OrdType_PreviouslyIndicated -> "PreviouslyIndicated" - | MOD_FIX_OrdType_ForexSwap -> "ForexSwap" - | MOD_FIX_OrdType_Funari -> "Funari" - | MOD_FIX_OrdType_MarketIfTouched -> "MarketIfTouched" - | MOD_FIX_OrdType_MarketWithLeftOverAsLimit -> "MarketWithLeftOverAsLimit" - | MOD_FIX_OrdType_PreviousFundValuationPoint -> "PreviousFundValuationPoint" - | MOD_FIX_OrdType_NextFundValuationPoint -> "NextFundValuationPoint" - | MOD_FIX_OrdType_Pegged -> "Pegged" + | MOD_FIX_PartySubIDType_Firm -> "Firm" + | MOD_FIX_PartySubIDType_Person -> "Person" + | MOD_FIX_PartySubIDType_System -> "System" + | MOD_FIX_PartySubIDType_Application -> "Application" + | MOD_FIX_PartySubIDType_FullLegalNameOfFirm -> "FullLegalNameOfFirm" + | MOD_FIX_PartySubIDType_PostalAddress -> "PostalAddress" + | MOD_FIX_PartySubIDType_PhoneNumber -> "PhoneNumber" + | MOD_FIX_PartySubIDType_EmailAddress -> "EmailAddress" + | MOD_FIX_PartySubIDType_ContactName -> "ContactName" + | MOD_FIX_PartySubIDType_SecuritiesAccountNumber -> "SecuritiesAccountNumber" + | MOD_FIX_PartySubIDType_RegistrationNumber -> "RegistrationNumber" + | MOD_FIX_PartySubIDType_RegisteredAddressForConfirmation -> "RegisteredAddressForConfirmation" + | MOD_FIX_PartySubIDType_RegulatoryStatus -> "RegulatoryStatus" + | MOD_FIX_PartySubIDType_RegistrationName -> "RegistrationName" + | MOD_FIX_PartySubIDType_CashAccountNumber -> "CashAccountNumber" + | MOD_FIX_PartySubIDType_BIC -> "BIC" + | MOD_FIX_PartySubIDType_CSDParticipantMemberCode -> "CSDParticipantMemberCode" + | MOD_FIX_PartySubIDType_RegisteredAddress -> "RegisteredAddress" + | MOD_FIX_PartySubIDType_FundAccountName -> "FundAccountName" + | MOD_FIX_PartySubIDType_TelexNumber -> "TelexNumber" + | MOD_FIX_PartySubIDType_FaxNumber -> "FaxNumber" + | MOD_FIX_PartySubIDType_SecuritiesAccountName -> "SecuritiesAccountName" + | MOD_FIX_PartySubIDType_CashAccountName -> "CashAccountName" + | MOD_FIX_PartySubIDType_Department -> "Department" + | MOD_FIX_PartySubIDType_LocationDesk -> "LocationDesk" + | MOD_FIX_PartySubIDType_PositionAccountType -> "PositionAccountType" ) ;; @@ -110,6 +246,76 @@ let string_to_mod_side_opt (d) = ) ;; +let string_to_mod_ordtype_opt (d) = + (match d with + | "Market" -> (Some (MOD_FIX_OrdType_Market)) + | "Limit" -> (Some (MOD_FIX_OrdType_Limit)) + | "Stop" -> (Some (MOD_FIX_OrdType_Stop)) + | "StopLimit" -> (Some (MOD_FIX_OrdType_StopLimit)) + | "WithOrWithout" -> (Some (MOD_FIX_OrdType_WithOrWithout)) + | "LimitOrBetter" -> (Some (MOD_FIX_OrdType_LimitOrBetter)) + | "LimitWithOrWithout" -> (Some (MOD_FIX_OrdType_LimitWithOrWithout)) + | "OnBasis" -> (Some (MOD_FIX_OrdType_OnBasis)) + | "PreviouslyQuoted" -> (Some (MOD_FIX_OrdType_PreviouslyQuoted)) + | "PreviouslyIndicated" -> (Some (MOD_FIX_OrdType_PreviouslyIndicated)) + | "ForexSwap" -> (Some (MOD_FIX_OrdType_ForexSwap)) + | "Funari" -> (Some (MOD_FIX_OrdType_Funari)) + | "MarketIfTouched" -> (Some (MOD_FIX_OrdType_MarketIfTouched)) + | "MarketWithLeftOverAsLimit" -> (Some (MOD_FIX_OrdType_MarketWithLeftOverAsLimit)) + | "PreviousFundValuationPoint" -> (Some (MOD_FIX_OrdType_PreviousFundValuationPoint)) + | "NextFundValuationPoint" -> (Some (MOD_FIX_OrdType_NextFundValuationPoint)) + | "Pegged" -> (Some (MOD_FIX_OrdType_Pegged)) + | "StopSpread" -> (Some (MOD_FIX_OrdType_StopSpread)) + | _ -> (None) + ) +;; + +let string_to_mod_execinst_opt (d) = + (match d with + | "NotHeld" -> (Some (MOD_FIX_ExecInst_NotHeld)) + | "Work" -> (Some (MOD_FIX_ExecInst_Work)) + | "GoAlong" -> (Some (MOD_FIX_ExecInst_GoAlong)) + | "OverTheDay" -> (Some (MOD_FIX_ExecInst_OverTheDay)) + | "Held" -> (Some (MOD_FIX_ExecInst_Held)) + | "ParticipateDoNotInitiate" -> (Some (MOD_FIX_ExecInst_ParticipateDoNotInitiate)) + | "StrictScale" -> (Some (MOD_FIX_ExecInst_StrictScale)) + | "TryToScale" -> (Some (MOD_FIX_ExecInst_TryToScale)) + | "StayOnBidSide" -> (Some (MOD_FIX_ExecInst_StayOnBidSide)) + | "StayOnOfferSide" -> (Some (MOD_FIX_ExecInst_StayOnOfferSide)) + | "NoCross" -> (Some (MOD_FIX_ExecInst_NoCross)) + | "OKToCross" -> (Some (MOD_FIX_ExecInst_OKToCross)) + | "CallFirst" -> (Some (MOD_FIX_ExecInst_CallFirst)) + | "PercentOfVolume" -> (Some (MOD_FIX_ExecInst_PercentOfVolume)) + | "DoNotIncrease" -> (Some (MOD_FIX_ExecInst_DoNotIncrease)) + | "DoNotReduce" -> (Some (MOD_FIX_ExecInst_DoNotReduce)) + | "AllOrNone" -> (Some (MOD_FIX_ExecInst_AllOrNone)) + | "ReinstateOnSystemFailure" -> (Some (MOD_FIX_ExecInst_ReinstateOnSystemFailure)) + | "InstitutionsOnly" -> (Some (MOD_FIX_ExecInst_InstitutionsOnly)) + | "ReinstateOnTradingHalt" -> (Some (MOD_FIX_ExecInst_ReinstateOnTradingHalt)) + | "CancelOnTradingHalt" -> (Some (MOD_FIX_ExecInst_CancelOnTradingHalt)) + | "LastPeg" -> (Some (MOD_FIX_ExecInst_LastPeg)) + | "MidPricePeg" -> (Some (MOD_FIX_ExecInst_MidPricePeg)) + | "NonNegotiable" -> (Some (MOD_FIX_ExecInst_NonNegotiable)) + | "OpeningPeg" -> (Some (MOD_FIX_ExecInst_OpeningPeg)) + | "MarketPeg" -> (Some (MOD_FIX_ExecInst_MarketPeg)) + | "CancelOnSystemFailure" -> (Some (MOD_FIX_ExecInst_CancelOnSystemFailure)) + | "PrimaryPeg" -> (Some (MOD_FIX_ExecInst_PrimaryPeg)) + | "Suspend" -> (Some (MOD_FIX_ExecInst_Suspend)) + | "CustomerDisplayInstruction" -> (Some (MOD_FIX_ExecInst_CustomerDisplayInstruction)) + | "Netting" -> (Some (MOD_FIX_ExecInst_Netting)) + | "PegToVWAP" -> (Some (MOD_FIX_ExecInst_PegToVWAP)) + | "TradeAlong" -> (Some (MOD_FIX_ExecInst_TradeAlong)) + | "TryToStop" -> (Some (MOD_FIX_ExecInst_TryToStop)) + | "CancelIfNotBest" -> (Some (MOD_FIX_ExecInst_CancelIfNotBest)) + | "TrailingStopPeg" -> (Some (MOD_FIX_ExecInst_TrailingStopPeg)) + | "StrictLimit" -> (Some (MOD_FIX_ExecInst_StrictLimit)) + | "IgnorePriceValidityChecks" -> (Some (MOD_FIX_ExecInst_IgnorePriceValidityChecks)) + | "PegToLimitPrice" -> (Some (MOD_FIX_ExecInst_PegToLimitPrice)) + | "WorkToTargetStrategy" -> (Some (MOD_FIX_ExecInst_WorkToTargetStrategy)) + | _ -> (None) + ) +;; + let string_to_mod_exectype_opt (d) = (match d with | "New" -> (Some (MOD_FIX_ExecType_New)) @@ -154,25 +360,35 @@ let string_to_mod_ordstatus_opt (d) = ) ;; -let string_to_mod_ordtype_opt (d) = +let string_to_mod_partysubidtype_opt (d) = (match d with - | "Market" -> (Some (MOD_FIX_OrdType_Market)) - | "Limit" -> (Some (MOD_FIX_OrdType_Limit)) - | "Stop" -> (Some (MOD_FIX_OrdType_Stop)) - | "StopLimit" -> (Some (MOD_FIX_OrdType_StopLimit)) - | "WithOrWithout" -> (Some (MOD_FIX_OrdType_WithOrWithout)) - | "LimitOrBetter" -> (Some (MOD_FIX_OrdType_LimitOrBetter)) - | "LimitWithOrWithout" -> (Some (MOD_FIX_OrdType_LimitWithOrWithout)) - | "OnBasis" -> (Some (MOD_FIX_OrdType_OnBasis)) - | "PreviouslyQuoted" -> (Some (MOD_FIX_OrdType_PreviouslyQuoted)) - | "PreviouslyIndicated" -> (Some (MOD_FIX_OrdType_PreviouslyIndicated)) - | "ForexSwap" -> (Some (MOD_FIX_OrdType_ForexSwap)) - | "Funari" -> (Some (MOD_FIX_OrdType_Funari)) - | "MarketIfTouched" -> (Some (MOD_FIX_OrdType_MarketIfTouched)) - | "MarketWithLeftOverAsLimit" -> (Some (MOD_FIX_OrdType_MarketWithLeftOverAsLimit)) - | "PreviousFundValuationPoint" -> (Some (MOD_FIX_OrdType_PreviousFundValuationPoint)) - | "NextFundValuationPoint" -> (Some (MOD_FIX_OrdType_NextFundValuationPoint)) - | "Pegged" -> (Some (MOD_FIX_OrdType_Pegged)) + | "Firm" -> (Some (MOD_FIX_PartySubIDType_Firm)) + | "Person" -> (Some (MOD_FIX_PartySubIDType_Person)) + | "System" -> (Some (MOD_FIX_PartySubIDType_System)) + | "Application" -> (Some (MOD_FIX_PartySubIDType_Application)) + | "FullLegalNameOfFirm" -> (Some (MOD_FIX_PartySubIDType_FullLegalNameOfFirm)) + | "PostalAddress" -> (Some (MOD_FIX_PartySubIDType_PostalAddress)) + | "PhoneNumber" -> (Some (MOD_FIX_PartySubIDType_PhoneNumber)) + | "EmailAddress" -> (Some (MOD_FIX_PartySubIDType_EmailAddress)) + | "ContactName" -> (Some (MOD_FIX_PartySubIDType_ContactName)) + | "SecuritiesAccountNumber" -> (Some (MOD_FIX_PartySubIDType_SecuritiesAccountNumber)) + | "RegistrationNumber" -> (Some (MOD_FIX_PartySubIDType_RegistrationNumber)) + | "RegisteredAddressForConfirmation" -> (Some (MOD_FIX_PartySubIDType_RegisteredAddressForConfirmation)) + | "RegulatoryStatus" -> (Some (MOD_FIX_PartySubIDType_RegulatoryStatus)) + | "RegistrationName" -> (Some (MOD_FIX_PartySubIDType_RegistrationName)) + | "CashAccountNumber" -> (Some (MOD_FIX_PartySubIDType_CashAccountNumber)) + | "BIC" -> (Some (MOD_FIX_PartySubIDType_BIC)) + | "CSDParticipantMemberCode" -> (Some (MOD_FIX_PartySubIDType_CSDParticipantMemberCode)) + | "RegisteredAddress" -> (Some (MOD_FIX_PartySubIDType_RegisteredAddress)) + | "FundAccountName" -> (Some (MOD_FIX_PartySubIDType_FundAccountName)) + | "TelexNumber" -> (Some (MOD_FIX_PartySubIDType_TelexNumber)) + | "FaxNumber" -> (Some (MOD_FIX_PartySubIDType_FaxNumber)) + | "SecuritiesAccountName" -> (Some (MOD_FIX_PartySubIDType_SecuritiesAccountName)) + | "CashAccountName" -> (Some (MOD_FIX_PartySubIDType_CashAccountName)) + | "Department" -> (Some (MOD_FIX_PartySubIDType_Department)) + | "LocationDesk" -> (Some (MOD_FIX_PartySubIDType_LocationDesk)) + | "PositionAccountType" -> (Some (MOD_FIX_PartySubIDType_PositionAccountType)) | _ -> (None) ) ;; + diff --git a/src-model/src-types-pp/dune b/src-model/src-types-pp/dune index ee936555..763589cd 100644 --- a/src-model/src-types-pp/dune +++ b/src-model/src-types-pp/dune @@ -1,8 +1,7 @@ (library - (name types_pp) - (public_name fix-engine.types_pp) - (wrapped false) - (flags - (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) - (libraries imandra-prelude decoders-yojson core_pp protocol_exts_pp - string_factory templates venue_strings_venue venue_types)) + (name types_pp) + (public_name fix-engine.types_pp) + (wrapped false) + (flags (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) + (libraries imandra-prelude decoders-yojson core core_pp core_time_defaults protocol_exts_pp string_factory templates venue_strings_venue venue_types yojson) +) diff --git a/src-model/src-types-pp/json_to_action.iml b/src-model/src-types-pp/json_to_action.iml index c797bc3e..4c4a6e1e 100644 --- a/src-model/src-types-pp/json_to_action.iml +++ b/src-model/src-types-pp/json_to_action.iml @@ -1,4 +1,4 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@import "../src-types/actions.iml"] open Actions;; @@ -6,14 +6,19 @@ open Actions;; open Decoders_yojson.Basic.Decode;; [@@@require "decoders-yojson"] open Decoders_yojson.Basic.Decode.Infix;; +[@@@import "json_to_records.iml"] +open Json_to_records;; let fix_action_decoder : fix_action decoder = (field "tag" string) >>= (fun x -> (match x with + | "fill" -> ((field "data" mod_action_fill_decoder) >>= (fun y -> succeed (FIX_Action_fill y) + )) + | "bookState" -> ((field "data" mod_action_bookstate_decoder) >>= (fun y -> succeed (FIX_Action_bookState y) + )) | d -> (fail ("Unknown Action ("^d^") in JSON decoding.")) ) ) - [@@macro] ;; [@@@logic] diff --git a/src-model/src-types-pp/json_to_enum.iml b/src-model/src-types-pp/json_to_enum.iml index 18eca0d5..19125bee 100644 --- a/src-model/src-types-pp/json_to_enum.iml +++ b/src-model/src-types-pp/json_to_enum.iml @@ -1,4 +1,4 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@require "decoders-yojson"] open Decoders_yojson.Basic.Decode;; @@ -16,7 +16,24 @@ let mod_enum_side_decoder : model_fix_side decoder = | Some y -> (succeed y) ) ) - [@@macro] +;; + +let mod_enum_ordtype_decoder : model_fix_ordtype decoder = + string >>= (fun x -> (match string_to_mod_ordtype_opt x with + | None -> (fail "Unknown enum (OrdType) encoding.") + | Some y -> (succeed y) + ) + ) +;; + +let mod_enum_execinst_decoder : (model_fix_execinst,bool) Map.t decoder = + (list (string >>= (fun x -> (match string_to_mod_execinst_opt x with + | None -> (fail "Unknown enum (ExecInst) encoding.") + | Some y -> (succeed y) + ) + ))) >>= (fun m -> succeed (Map.of_list ~default:false (List.map (fun a -> (a,true) + ) m)) + ) ;; let mod_enum_exectype_decoder : model_fix_exectype decoder = @@ -25,7 +42,6 @@ let mod_enum_exectype_decoder : model_fix_exectype decoder = | Some y -> (succeed y) ) ) - [@@macro] ;; let mod_enum_ordstatus_decoder : model_fix_ordstatus decoder = @@ -34,16 +50,14 @@ let mod_enum_ordstatus_decoder : model_fix_ordstatus decoder = | Some y -> (succeed y) ) ) - [@@macro] ;; -let mod_enum_ordtype_decoder : model_fix_ordtype decoder = - string >>= (fun x -> (match string_to_mod_ordtype_opt x with - | None -> (fail "Unknown enum (OrdType) encoding.") +let mod_enum_partysubidtype_decoder : model_fix_partysubidtype decoder = + string >>= (fun x -> (match string_to_mod_partysubidtype_opt x with + | None -> (fail "Unknown enum (PartySubIDType) encoding.") | Some y -> (succeed y) ) ) - [@@macro] ;; [@@@logic] diff --git a/src-model/src-types-pp/json_to_internal.iml b/src-model/src-types-pp/json_to_internal.iml index 532e5080..4f83227c 100644 --- a/src-model/src-types-pp/json_to_internal.iml +++ b/src-model/src-types-pp/json_to_internal.iml @@ -1,5 +1,73 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../../src-core-pp/base_types_json.iml"] +open Base_types_json;; +[@@@import "../../src-core/datetime.iml"] +open Datetime;; +[@@@import "../../src-core-pp/datetime_json.iml"] +open Datetime_json;; +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode;; +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode.Infix;; +[@@@import "json_to_enum.iml"] +open Json_to_enum;; +[@@@import "json_to_repeating_group.iml"] +open Json_to_repeating_group;; +[@@@import "../src-types/model_app_enums.iml"] +open Model_app_enums;; +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; +[@@@import "../../src-core/numeric.iml"] +open Numeric;; +[@@@import "../src-types/state.iml"] +open State;; +[@@@import "../../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; +let internal_state_decoder : fix_internal_state decoder = + (field "state.ExecType" mod_enum_exectype_decoder) >>= (fun mod_f_internal_state_ExecType -> (field "state.OrderID" string_decoder) >>= (fun mod_f_internal_state_OrderID -> (field "state.ExecInst" mod_enum_execinst_decoder) >>= (fun mod_f_internal_state_ExecInst -> (field "state.Parties" mod_rg_parties_decoder) >>= (fun mod_f_internal_state_Parties -> (maybe (field "state.SpreadProportion" float_decoder)) >>= (fun mod_f_internal_state_SpreadProportion -> (field "state.CumQty" float_6_decoder) >>= (fun mod_f_internal_state_CumQty -> (field "state.LeavesQty" float_6_decoder) >>= (fun mod_f_internal_state_LeavesQty -> (field "state.OrdType" mod_enum_ordtype_decoder) >>= (fun mod_f_internal_state_OrdType -> (field "state.OrdStatus" mod_enum_ordstatus_decoder) >>= (fun mod_f_internal_state_OrdStatus -> (field "state.OrderQtyData.OrderQty" float_6_decoder) >>= (fun mod_f_internal_state_OrderQtyData_OrderQty -> (maybe (field "state.Price" float_2_decoder)) >>= (fun mod_f_internal_state_Price -> (field "state.Side" mod_enum_side_decoder) >>= (fun mod_f_internal_state_Side -> (field "state.bestAsk" float_2_decoder) >>= (fun mod_f_internal_state_bestAsk -> (field "state.bestBid" float_2_decoder) >>= (fun mod_f_internal_state_bestBid -> (field "state.AvgPx" float_decoder) >>= (fun mod_f_internal_state_AvgPx -> (field "state.live_order" bool_decoder) >>= (fun mod_f_internal_state_live_order -> succeed { + mod_f_internal_state_live_order = mod_f_internal_state_live_order; + mod_f_internal_state_AvgPx = mod_f_internal_state_AvgPx; + mod_f_internal_state_bestBid = mod_f_internal_state_bestBid; + mod_f_internal_state_bestAsk = mod_f_internal_state_bestAsk; + mod_f_internal_state_Side = mod_f_internal_state_Side; + mod_f_internal_state_Price = mod_f_internal_state_Price; + mod_f_internal_state_OrderQtyData_OrderQty = mod_f_internal_state_OrderQtyData_OrderQty; + mod_f_internal_state_OrdStatus = mod_f_internal_state_OrdStatus; + mod_f_internal_state_OrdType = mod_f_internal_state_OrdType; + mod_f_internal_state_LeavesQty = mod_f_internal_state_LeavesQty; + mod_f_internal_state_CumQty = mod_f_internal_state_CumQty; + mod_f_internal_state_SpreadProportion = mod_f_internal_state_SpreadProportion; + mod_f_internal_state_Parties = mod_f_internal_state_Parties; + mod_f_internal_state_ExecInst = mod_f_internal_state_ExecInst; + mod_f_internal_state_OrderID = mod_f_internal_state_OrderID; + mod_f_internal_state_ExecType = mod_f_internal_state_ExecType + } + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) +;; + +let internal_fresh_state'_decoder : fix_internal_fresh_state' decoder = + (field "fresh_state'.seed_string" string_decoder) >>= (fun mod_f_internal_fresh_state'_seed_string -> succeed { + mod_f_internal_fresh_state'_seed_string = mod_f_internal_fresh_state'_seed_string + } + ) +;; + [@@@logic] diff --git a/src-model/src-types-pp/json_to_message.iml b/src-model/src-types-pp/json_to_message.iml index d08701a5..c5551a92 100644 --- a/src-model/src-types-pp/json_to_message.iml +++ b/src-model/src-types-pp/json_to_message.iml @@ -1,4 +1,4 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@import "../../src-core-pp/base_types_json.iml"] open Base_types_json;; @@ -12,23 +12,75 @@ open Decoders_yojson.Basic.Decode.Infix;; open Json_to_enum;; [@@@import "json_to_model_tag.iml"] open Json_to_model_tag;; +[@@@import "json_to_repeating_group.iml"] +open Json_to_repeating_group;; [@@@import "../src-types/model_messages.iml"] open Model_messages;; +let mod_message_newordersingle_decoder : mod_newordersingle_data decoder = + (field "Parties" mod_rg_parties_decoder) >>= (fun mod_f_NewOrderSingle_Parties -> (field "ExecInst" mod_enum_execinst_decoder) >>= (fun mod_f_NewOrderSingle_ExecInst -> (maybe (field "Account" string_decoder)) >>= (fun mod_f_NewOrderSingle_Account -> (maybe (field "Price" float_2_decoder)) >>= (fun mod_f_NewOrderSingle_Price -> (maybe (field "SpreadProportion" float_decoder)) >>= (fun mod_f_NewOrderSingle_SpreadProportion -> (field "OrderQtyData.OrderQty" float_6_decoder) >>= (fun mod_f_NewOrderSingle_OrderQtyData_OrderQty -> (field "OrdType" mod_enum_ordtype_decoder) >>= (fun mod_f_NewOrderSingle_OrdType -> (field "TransactTime" utctimestamp_milli_decoder) >>= (fun mod_f_NewOrderSingle_TransactTime -> (field "Side" mod_enum_side_decoder) >>= (fun mod_f_NewOrderSingle_Side -> (maybe (field "ClOrdID" string_decoder)) >>= (fun mod_f_NewOrderSingle_ClOrdID -> succeed { + mod_f_NewOrderSingle_ClOrdID = mod_f_NewOrderSingle_ClOrdID; + mod_f_NewOrderSingle_Side = mod_f_NewOrderSingle_Side; + mod_f_NewOrderSingle_TransactTime = mod_f_NewOrderSingle_TransactTime; + mod_f_NewOrderSingle_OrdType = mod_f_NewOrderSingle_OrdType; + mod_f_NewOrderSingle_OrderQtyData_OrderQty = mod_f_NewOrderSingle_OrderQtyData_OrderQty; + mod_f_NewOrderSingle_SpreadProportion = mod_f_NewOrderSingle_SpreadProportion; + mod_f_NewOrderSingle_Price = mod_f_NewOrderSingle_Price; + mod_f_NewOrderSingle_Account = mod_f_NewOrderSingle_Account; + mod_f_NewOrderSingle_ExecInst = mod_f_NewOrderSingle_ExecInst; + mod_f_NewOrderSingle_Parties = mod_f_NewOrderSingle_Parties + } + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) +;; + +let mod_message_newordersingle_opt_def_decoder : mod_newordersingle_defopt_data decoder = + (field "Parties" mod_rg_parties_decoder) >>= (fun mod_def_opt_f_NewOrderSingle_Parties -> (maybe (field "ExecInst" mod_enum_execinst_decoder)) >>= (fun mod_def_opt_f_NewOrderSingle_ExecInst -> (maybe (field "Account" string_decoder)) >>= (fun mod_def_opt_f_NewOrderSingle_Account -> (maybe (field "Price" float_2_decoder)) >>= (fun mod_def_opt_f_NewOrderSingle_Price -> (maybe (field "SpreadProportion" float_decoder)) >>= (fun mod_def_opt_f_NewOrderSingle_SpreadProportion -> (field "OrderQtyData.OrderQty" float_6_decoder) >>= (fun mod_def_opt_f_NewOrderSingle_OrderQtyData_OrderQty -> (field "OrdType" mod_enum_ordtype_decoder) >>= (fun mod_def_opt_f_NewOrderSingle_OrdType -> (field "TransactTime" utctimestamp_milli_decoder) >>= (fun mod_def_opt_f_NewOrderSingle_TransactTime -> (field "Side" mod_enum_side_decoder) >>= (fun mod_def_opt_f_NewOrderSingle_Side -> (maybe (field "ClOrdID" string_decoder)) >>= (fun mod_def_opt_f_NewOrderSingle_ClOrdID -> succeed { + mod_def_opt_f_NewOrderSingle_ClOrdID = mod_def_opt_f_NewOrderSingle_ClOrdID; + mod_def_opt_f_NewOrderSingle_Side = mod_def_opt_f_NewOrderSingle_Side; + mod_def_opt_f_NewOrderSingle_TransactTime = mod_def_opt_f_NewOrderSingle_TransactTime; + mod_def_opt_f_NewOrderSingle_OrdType = mod_def_opt_f_NewOrderSingle_OrdType; + mod_def_opt_f_NewOrderSingle_OrderQtyData_OrderQty = mod_def_opt_f_NewOrderSingle_OrderQtyData_OrderQty; + mod_def_opt_f_NewOrderSingle_SpreadProportion = mod_def_opt_f_NewOrderSingle_SpreadProportion; + mod_def_opt_f_NewOrderSingle_Price = mod_def_opt_f_NewOrderSingle_Price; + mod_def_opt_f_NewOrderSingle_Account = mod_def_opt_f_NewOrderSingle_Account; + mod_def_opt_f_NewOrderSingle_ExecInst = mod_def_opt_f_NewOrderSingle_ExecInst; + mod_def_opt_f_NewOrderSingle_Parties = mod_def_opt_f_NewOrderSingle_Parties + } + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) +;; + let mod_message_executionreport_decoder : mod_executionreport_data decoder = - (maybe (field "Text" string_decoder)) >>= (fun mod_f_ExecutionReport_Text -> (field "Instrument.Symbol" string_decoder) >>= (fun mod_f_ExecutionReport_Instrument_Symbol -> (field "OrdStatus" mod_enum_ordstatus_decoder) >>= (fun mod_f_ExecutionReport_OrdStatus -> (field "CumQty" float_6_decoder) >>= (fun mod_f_ExecutionReport_CumQty -> (field "LeavesQty" float_6_decoder) >>= (fun mod_f_ExecutionReport_LeavesQty -> (field "Side" mod_enum_side_decoder) >>= (fun mod_f_ExecutionReport_Side -> (field "AvgPx" float_6_decoder) >>= (fun mod_f_ExecutionReport_AvgPx -> (field "ExecType" mod_enum_exectype_decoder) >>= (fun mod_f_ExecutionReport_ExecType -> (field "ExecID" string_decoder) >>= (fun mod_f_ExecutionReport_ExecID -> (field "OrderID" string_decoder) >>= (fun mod_f_ExecutionReport_OrderID -> (field "ClOrdID" string_decoder) >>= (fun mod_f_ExecutionReport_ClOrdID -> succeed { - mod_f_ExecutionReport_ClOrdID = mod_f_ExecutionReport_ClOrdID; + (field "ExecInst" mod_enum_execinst_decoder) >>= (fun mod_f_ExecutionReport_ExecInst -> (field "Parties" mod_rg_parties_decoder) >>= (fun mod_f_ExecutionReport_Parties -> (maybe (field "Text" string_decoder)) >>= (fun mod_f_ExecutionReport_Text -> (field "CumQty" float_6_decoder) >>= (fun mod_f_ExecutionReport_CumQty -> (field "LeavesQty" float_6_decoder) >>= (fun mod_f_ExecutionReport_LeavesQty -> (field "OrderQtyData.OrderQty" float_6_decoder) >>= (fun mod_f_ExecutionReport_OrderQtyData_OrderQty -> (field "Side" mod_enum_side_decoder) >>= (fun mod_f_ExecutionReport_Side -> (field "OrdStatus" mod_enum_ordstatus_decoder) >>= (fun mod_f_ExecutionReport_OrdStatus -> (field "ExecType" mod_enum_exectype_decoder) >>= (fun mod_f_ExecutionReport_ExecType -> (field "ExecID" string_decoder) >>= (fun mod_f_ExecutionReport_ExecID -> (field "OrderID" string_decoder) >>= (fun mod_f_ExecutionReport_OrderID -> succeed { mod_f_ExecutionReport_OrderID = mod_f_ExecutionReport_OrderID; mod_f_ExecutionReport_ExecID = mod_f_ExecutionReport_ExecID; mod_f_ExecutionReport_ExecType = mod_f_ExecutionReport_ExecType; - mod_f_ExecutionReport_AvgPx = mod_f_ExecutionReport_AvgPx; + mod_f_ExecutionReport_OrdStatus = mod_f_ExecutionReport_OrdStatus; mod_f_ExecutionReport_Side = mod_f_ExecutionReport_Side; + mod_f_ExecutionReport_OrderQtyData_OrderQty = mod_f_ExecutionReport_OrderQtyData_OrderQty; mod_f_ExecutionReport_LeavesQty = mod_f_ExecutionReport_LeavesQty; mod_f_ExecutionReport_CumQty = mod_f_ExecutionReport_CumQty; - mod_f_ExecutionReport_OrdStatus = mod_f_ExecutionReport_OrdStatus; - mod_f_ExecutionReport_Instrument_Symbol = mod_f_ExecutionReport_Instrument_Symbol; - mod_f_ExecutionReport_Text = mod_f_ExecutionReport_Text + mod_f_ExecutionReport_Text = mod_f_ExecutionReport_Text; + mod_f_ExecutionReport_Parties = mod_f_ExecutionReport_Parties; + mod_f_ExecutionReport_ExecInst = mod_f_ExecutionReport_ExecInst } ) ) @@ -41,49 +93,70 @@ let mod_message_executionreport_decoder : mod_executionreport_data decoder = ) ) ) - [@@macro] ;; -let mod_message_newordersingle_decoder : mod_newordersingle_data decoder = - (field "Instrument.Symbol" string_decoder) >>= (fun mod_f_NewOrderSingle_Instrument_Symbol -> (field "OrdType" mod_enum_ordtype_decoder) >>= (fun mod_f_NewOrderSingle_OrdType -> (field "TransactTime" utctimestamp_milli_decoder) >>= (fun mod_f_NewOrderSingle_TransactTime -> (field "Side" mod_enum_side_decoder) >>= (fun mod_f_NewOrderSingle_Side -> (field "ClOrdID" string_decoder) >>= (fun mod_f_NewOrderSingle_ClOrdID -> succeed { - mod_f_NewOrderSingle_ClOrdID = mod_f_NewOrderSingle_ClOrdID; - mod_f_NewOrderSingle_Side = mod_f_NewOrderSingle_Side; - mod_f_NewOrderSingle_TransactTime = mod_f_NewOrderSingle_TransactTime; - mod_f_NewOrderSingle_OrdType = mod_f_NewOrderSingle_OrdType; - mod_f_NewOrderSingle_Instrument_Symbol = mod_f_NewOrderSingle_Instrument_Symbol +let mod_message_executionreport_opt_def_decoder : mod_executionreport_defopt_data decoder = + (field "ExecInst" mod_enum_execinst_decoder) >>= (fun mod_def_opt_f_ExecutionReport_ExecInst -> (field "Parties" mod_rg_parties_decoder) >>= (fun mod_def_opt_f_ExecutionReport_Parties -> (maybe (field "Text" string_decoder)) >>= (fun mod_def_opt_f_ExecutionReport_Text -> (field "CumQty" float_6_decoder) >>= (fun mod_def_opt_f_ExecutionReport_CumQty -> (field "LeavesQty" float_6_decoder) >>= (fun mod_def_opt_f_ExecutionReport_LeavesQty -> (field "OrderQtyData.OrderQty" float_6_decoder) >>= (fun mod_def_opt_f_ExecutionReport_OrderQtyData_OrderQty -> (field "Side" mod_enum_side_decoder) >>= (fun mod_def_opt_f_ExecutionReport_Side -> (field "OrdStatus" mod_enum_ordstatus_decoder) >>= (fun mod_def_opt_f_ExecutionReport_OrdStatus -> (field "ExecType" mod_enum_exectype_decoder) >>= (fun mod_def_opt_f_ExecutionReport_ExecType -> (field "ExecID" string_decoder) >>= (fun mod_def_opt_f_ExecutionReport_ExecID -> (field "OrderID" string_decoder) >>= (fun mod_def_opt_f_ExecutionReport_OrderID -> succeed { + mod_def_opt_f_ExecutionReport_OrderID = mod_def_opt_f_ExecutionReport_OrderID; + mod_def_opt_f_ExecutionReport_ExecID = mod_def_opt_f_ExecutionReport_ExecID; + mod_def_opt_f_ExecutionReport_ExecType = mod_def_opt_f_ExecutionReport_ExecType; + mod_def_opt_f_ExecutionReport_OrdStatus = mod_def_opt_f_ExecutionReport_OrdStatus; + mod_def_opt_f_ExecutionReport_Side = mod_def_opt_f_ExecutionReport_Side; + mod_def_opt_f_ExecutionReport_OrderQtyData_OrderQty = mod_def_opt_f_ExecutionReport_OrderQtyData_OrderQty; + mod_def_opt_f_ExecutionReport_LeavesQty = mod_def_opt_f_ExecutionReport_LeavesQty; + mod_def_opt_f_ExecutionReport_CumQty = mod_def_opt_f_ExecutionReport_CumQty; + mod_def_opt_f_ExecutionReport_Text = mod_def_opt_f_ExecutionReport_Text; + mod_def_opt_f_ExecutionReport_Parties = mod_def_opt_f_ExecutionReport_Parties; + mod_def_opt_f_ExecutionReport_ExecInst = mod_def_opt_f_ExecutionReport_ExecInst } ) ) ) ) ) - [@@macro] + ) + ) + ) + ) + ) + ) ;; let model_message_decoder : model_msg decoder = (field "tag" string) >>= (fun x -> (match x with + | "D" -> ((field "data" mod_message_newordersingle_decoder) >>= (fun y -> succeed (FIX_Msg_NewOrderSingle y) + )) | "8" -> ((field "data" mod_message_executionreport_decoder) >>= (fun y -> succeed (FIX_Msg_ExecutionReport y) )) - | "D" -> ((field "data" mod_message_newordersingle_decoder) >>= (fun y -> succeed (FIX_Msg_NewOrderSingle y) + | d -> (fail ("Unknown Message ("^d^") in JSON decoding.")) + ) + ) +;; + +let model_message_decoder_opt_def : model_msg_opt_def decoder = + (field "tag" string) >>= (fun x -> (match x with + | "D" -> ((field "data" mod_message_newordersingle_opt_def_decoder) >>= (fun y -> succeed (FIX_Msg_Def_Opt_NewOrderSingle y) + )) + | "8" -> ((field "data" mod_message_executionreport_opt_def_decoder) >>= (fun y -> succeed (FIX_Msg_Def_Opt_ExecutionReport y) )) | d -> (fail ("Unknown Message ("^d^") in JSON decoding.")) ) ) - [@@macro] ;; let top_level_message_decoder : model_top_level_msg decoder = (field "top_level_msg" string) >>= (fun f -> (match f with - | "FIX_TL_Normal" -> ((field "data" model_message_decoder) >>= (fun x -> succeed (FIX_TL_Normal x) + | "FIX_TL_Normal" -> ((field "data" model_message_decoder_opt_def) >>= (fun x -> succeed (FIX_TL_Normal x) )) | "FIX_TL_Req_Field_Missing" -> ((field "data" field_missing_data_decoder) >>= (fun x -> succeed (FIX_TL_Req_Field_Missing x) )) - | "FIX_TL_PossibleResend" -> ((field "data" model_message_decoder) >>= (fun x -> succeed (FIX_TL_PossibleResend x) + | "FIX_TL_Req_Field_Invalid" -> ((field "data" field_missing_data_decoder) >>= (fun x -> succeed (FIX_TL_Req_Field_Invalid x) + )) + | "FIX_TL_PossibleResend" -> ((field "data" model_message_decoder_opt_def) >>= (fun x -> succeed (FIX_TL_PossibleResend x) )) | _ -> (succeed FIX_TL_None) ) ) - [@@macro] ;; [@@@logic] diff --git a/src-model/src-types-pp/json_to_model_state.iml b/src-model/src-types-pp/json_to_model_state.iml index db5bbf7b..d40ca868 100644 --- a/src-model/src-types-pp/json_to_model_state.iml +++ b/src-model/src-types-pp/json_to_model_state.iml @@ -1,4 +1,4 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@require "decoders-yojson"] open Decoders_yojson.Basic.Decode;; @@ -6,6 +6,8 @@ open Decoders_yojson.Basic.Decode;; open Decoders_yojson.Basic.Decode.Infix;; [@@@import "json_to_action.iml"] open Json_to_action;; +[@@@import "json_to_internal.iml"] +open Json_to_internal;; [@@@import "json_to_message.iml"] open Json_to_message;; [@@@import "../src-types/model_messages.iml"] @@ -15,18 +17,17 @@ open State;; let outgoing_decoder = - (field "outgoing_msg_counter" int) >>= (fun c -> (field "outgoing_msg_msg" model_message_decoder) >>= (fun m -> succeed { - outgoing_msg_counter = Z.of_int c; + (field "outgoing_msg_counter" string) >>= (fun c -> (field "outgoing_msg_msg" model_message_decoder) >>= (fun m -> succeed { + outgoing_msg_counter = Z.of_string c; outgoing_msg_msg = m } ) ) - [@@macro] ;; let state_info_decoder = - (field "state_event_counter" int) >>= (fun c -> (maybe (field "state_event_reject_text" string)) >>= (fun m -> succeed { - state_event_counter = Z.of_int c; + (field "state_event_counter" string) >>= (fun c -> (maybe (field "state_event_reject_text" string)) >>= (fun m -> succeed { + state_event_counter = Z.of_string c; state_event_reject_text = (match m with | None -> None | Some x -> (Some x) @@ -34,18 +35,19 @@ let state_info_decoder = } ) ) - [@@macro] ;; let model_state_decoder : model_state decoder = - (field "incoming_action" (nullable fix_action_decoder)) >>= (fun incoming_action -> (field "event_counter" int) >>= (fun event_counter -> (field "incoming_msg" (nullable top_level_message_decoder)) >>= (fun incoming_msg -> (field "outgoing_msgs" (list outgoing_decoder)) >>= (fun outgoing_msgs -> (field "event_info" (list state_info_decoder)) >>= (fun event_info -> succeed { + (field "fresh_state'" internal_fresh_state'_decoder) >>= (fun f_internal_fresh_state' -> (field "state" internal_state_decoder) >>= (fun f_internal_state -> (field "incoming_action" (nullable fix_action_decoder)) >>= (fun incoming_action -> (field "event_counter" string) >>= (fun event_counter -> (field "incoming_msg" (nullable top_level_message_decoder)) >>= (fun incoming_msg -> (field "outgoing_msgs" (list outgoing_decoder)) >>= (fun outgoing_msgs -> (field "event_info" (list state_info_decoder)) >>= (fun event_info -> succeed { + f_internal_state = f_internal_state; + f_internal_fresh_state' = f_internal_fresh_state'; incoming_action = incoming_action; incoming_msg = (match incoming_msg with | None -> FIX_TL_None | Some x -> x ); outgoing_msgs = outgoing_msgs; - event_counter = Z.of_int event_counter; + event_counter = Z.of_string event_counter; event_info = event_info } ) @@ -53,7 +55,8 @@ let model_state_decoder : model_state decoder = ) ) ) - [@@macro] + ) + ) ;; [@@@logic] diff --git a/src-model/src-types-pp/json_to_model_tag.iml b/src-model/src-types-pp/json_to_model_tag.iml index babc7fe0..28e9837d 100644 --- a/src-model/src-types-pp/json_to_model_tag.iml +++ b/src-model/src-types-pp/json_to_model_tag.iml @@ -1,4 +1,4 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@require "decoders-yojson"] open Decoders_yojson.Basic.Decode;; @@ -6,6 +6,8 @@ open Decoders_yojson.Basic.Decode;; open Decoders_yojson.Basic.Decode.Infix;; [@@@import "../src-types/model_messages.iml"] open Model_messages;; +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; [@@@import "../src-string-factory/model_tag_names.iml"] open Model_tag_names;; [@@@import "../src-types/model_tags.iml"] @@ -18,7 +20,6 @@ let message_tag_decoder : m_msg_tag decoder = | Some y -> (succeed y) ) ) - [@@macro] ;; let field_tag_decoder : m_field_tag decoder = @@ -27,17 +28,29 @@ let field_tag_decoder : m_field_tag decoder = | Some y -> (succeed y) ) ) - [@@macro] ;; -let field_missing_data_decoder : field_missing_data decoder = - (field "m_msg_tag" message_tag_decoder) >>= (fun msg -> (field "m_field_tag" field_tag_decoder) >>= (fun f -> succeed { - field_missing_data_field = f; - field_missing_data_msg = msg +let rg_tag_decoder : repeating_group_defs option decoder = + (maybe string) >>= (fun x -> (match x with + | None -> (succeed (None)) + | Some x -> ((match tag_to_rg x with + | None -> (succeed (None)) + | Some y -> (succeed (Some y)) + ) + ) + ) + ) +;; + +let field_missing_data_decoder : field_missing_or_invalid_data decoder = + (field "m_msg_tag" message_tag_decoder) >>= (fun msg -> (field "m_field_tag" field_tag_decoder) >>= (fun f -> (field "repeating_group_defs" rg_tag_decoder) >>= (fun s -> succeed { + field_missing_or_invalid_data_field = f; + field_missing_of_invalid_data_msg = msg; + repeating_group_origin = s } ) ) - [@@macro] + ) ;; [@@@logic] diff --git a/src-model/src-types-pp/json_to_records.iml b/src-model/src-types-pp/json_to_records.iml index 532e5080..37abaf9c 100644 --- a/src-model/src-types-pp/json_to_records.iml +++ b/src-model/src-types-pp/json_to_records.iml @@ -1,5 +1,33 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../../src-core-pp/base_types_json.iml"] +open Base_types_json;; +[@@@import "../../src-core-pp/datetime_json.iml"] +open Datetime_json;; +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode;; +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode.Infix;; +[@@@import "../src-types/model_records.iml"] +open Model_records;; +let mod_action_bookstate_decoder : m_action_fix_bookstate decoder = + (field "bestAsk" float_2_decoder) >>= (fun mod_f_bookState_bestAsk -> (field "bestBid" float_2_decoder) >>= (fun mod_f_bookState_bestBid -> succeed { + mod_f_bookState_bestBid = mod_f_bookState_bestBid; + mod_f_bookState_bestAsk = mod_f_bookState_bestAsk + } + ) + ) +;; + +let mod_action_fill_decoder : m_action_fix_fill decoder = + (field "fill_qty" float_6_decoder) >>= (fun mod_f_fill_fill_qty -> (field "fill_price" float_2_decoder) >>= (fun mod_f_fill_fill_price -> succeed { + mod_f_fill_fill_price = mod_f_fill_fill_price; + mod_f_fill_fill_qty = mod_f_fill_fill_qty + } + ) + ) +;; + [@@@logic] diff --git a/src-model/src-types-pp/json_to_repeating_group.iml b/src-model/src-types-pp/json_to_repeating_group.iml index 532e5080..a2905704 100644 --- a/src-model/src-types-pp/json_to_repeating_group.iml +++ b/src-model/src-types-pp/json_to_repeating_group.iml @@ -1,5 +1,63 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../../src-core-pp/base_types_json.iml"] +open Base_types_json;; +[@@@import "../../src-core-pp/datetime_json.iml"] +open Datetime_json;; +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode;; +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode.Infix;; +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; +let ptyssubgrp_rg_decoder : model_fix_inner_ptyssubgrp decoder = + (maybe (field "PartySubID" string_decoder)) >>= (fun mod_f_PtysSubGrp_PartySubID -> succeed { + mod_f_PtysSubGrp_PartySubID = mod_f_PtysSubGrp_PartySubID + } + ) +;; + +let mod_rg_ptyssubgrp_decoder : model_fix_rec_ptyssubgrp decoder = + (maybe (field "4" ptyssubgrp_rg_decoder)) >>= (fun rg_PtysSubGrp_element_4 -> (maybe (field "3" ptyssubgrp_rg_decoder)) >>= (fun rg_PtysSubGrp_element_3 -> (maybe (field "2" ptyssubgrp_rg_decoder)) >>= (fun rg_PtysSubGrp_element_2 -> (maybe (field "1" ptyssubgrp_rg_decoder)) >>= (fun rg_PtysSubGrp_element_1 -> (maybe (field "0" ptyssubgrp_rg_decoder)) >>= (fun rg_PtysSubGrp_element_0 -> succeed { + rg_PtysSubGrp_element_0 = rg_PtysSubGrp_element_0; + rg_PtysSubGrp_element_1 = rg_PtysSubGrp_element_1; + rg_PtysSubGrp_element_2 = rg_PtysSubGrp_element_2; + rg_PtysSubGrp_element_3 = rg_PtysSubGrp_element_3; + rg_PtysSubGrp_element_4 = rg_PtysSubGrp_element_4 + } + ) + ) + ) + ) + ) +;; + +let parties_rg_decoder : model_fix_inner_parties decoder = + (field "PtysSubGrp" mod_rg_ptyssubgrp_decoder) >>= (fun mod_f_Parties_PtysSubGrp -> (field "PartyIndex" int_decoder) >>= (fun mod_f_Parties_PartyIndex -> (field "PartyID" string_decoder) >>= (fun mod_f_Parties_PartyID -> succeed { + mod_f_Parties_PartyID = mod_f_Parties_PartyID; + mod_f_Parties_PartyIndex = mod_f_Parties_PartyIndex; + mod_f_Parties_PtysSubGrp = mod_f_Parties_PtysSubGrp + } + ) + ) + ) +;; + +let mod_rg_parties_decoder : model_fix_rec_parties decoder = + (maybe (field "4" parties_rg_decoder)) >>= (fun rg_Parties_element_4 -> (maybe (field "3" parties_rg_decoder)) >>= (fun rg_Parties_element_3 -> (maybe (field "2" parties_rg_decoder)) >>= (fun rg_Parties_element_2 -> (maybe (field "1" parties_rg_decoder)) >>= (fun rg_Parties_element_1 -> (maybe (field "0" parties_rg_decoder)) >>= (fun rg_Parties_element_0 -> succeed { + rg_Parties_element_0 = rg_Parties_element_0; + rg_Parties_element_1 = rg_Parties_element_1; + rg_Parties_element_2 = rg_Parties_element_2; + rg_Parties_element_3 = rg_Parties_element_3; + rg_Parties_element_4 = rg_Parties_element_4 + } + ) + ) + ) + ) + ) +;; + [@@@logic] diff --git a/src-model/src-types-pp/model_actions_json.iml b/src-model/src-types-pp/model_actions_json.iml index 6b7ecdc1..94054a6b 100644 --- a/src-model/src-types-pp/model_actions_json.iml +++ b/src-model/src-types-pp/model_actions_json.iml @@ -1,12 +1,18 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-types/actions.iml"] +open Actions;; +[@@@import "model_records_json.iml"] +open Model_records_json;; +[@@@require "yojson"] +open Yojson.Basic;; -let json_of_fix_action (x) = +let json_of_fix_action (x) : json = (match x with - | _ -> `Null + | FIX_Action_fill x -> (`Assoc (("tag",`String "fill") :: (("data",mod_act_fill_to_json x) :: []))) + | FIX_Action_bookState x -> (`Assoc (("tag",`String "bookState") :: (("data",mod_act_bookstate_to_json x) :: []))) ) - [@@macro] ;; [@@@logic] diff --git a/src-model/src-types-pp/model_enums_json.iml b/src-model/src-types-pp/model_enums_json.iml index f417e112..004c6bde 100644 --- a/src-model/src-types-pp/model_enums_json.iml +++ b/src-model/src-types-pp/model_enums_json.iml @@ -1,54 +1,75 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@import "../src-strings-venue/model_enum_names.iml"] open Model_enum_names;; +[@@@require "yojson"] +open Yojson.Basic;; -let mod_side_to_json (d) = +let mod_side_to_json (d) : json = `String (mod_side_to_string d) - [@@macro] ;; -let mod_exectype_to_json (d) = +let mod_ordtype_to_json (d) : json = + `String (mod_ordtype_to_string d) +;; + +let mod_execinst_to_json (d) : json = + `List (List.map (fun x -> `String (mod_execinst_to_string x) + ) (get_model_enum_vals_ExecInst d list_model_vals_ExecInst)) +;; + +let mod_exectype_to_json (d) : json = `String (mod_exectype_to_string d) - [@@macro] ;; -let mod_ordstatus_to_json (d) = +let mod_ordstatus_to_json (d) : json = `String (mod_ordstatus_to_string d) - [@@macro] ;; -let mod_ordtype_to_json (d) = - `String (mod_ordtype_to_string d) - [@@macro] +let mod_partysubidtype_to_json (d) : json = + `String (mod_partysubidtype_to_string d) ;; -let mod_side_opt_to_json (d) = +let mod_side_opt_to_json (d) : json = (match d with | None -> (`Null) | Some d -> (mod_side_to_json d) ) ;; -let mod_exectype_opt_to_json (d) = +let mod_ordtype_opt_to_json (d) : json = + (match d with + | None -> (`Null) + | Some d -> (mod_ordtype_to_json d) + ) +;; + +let mod_execinst_opt_to_json (d) : json = + (match d with + | None -> (`Null) + | Some d -> (mod_execinst_to_json d) + ) +;; + +let mod_exectype_opt_to_json (d) : json = (match d with | None -> (`Null) | Some d -> (mod_exectype_to_json d) ) ;; -let mod_ordstatus_opt_to_json (d) = +let mod_ordstatus_opt_to_json (d) : json = (match d with | None -> (`Null) | Some d -> (mod_ordstatus_to_json d) ) ;; -let mod_ordtype_opt_to_json (d) = +let mod_partysubidtype_opt_to_json (d) : json = (match d with | None -> (`Null) - | Some d -> (mod_ordtype_to_json d) + | Some d -> (mod_partysubidtype_to_json d) ) ;; diff --git a/src-model/src-types-pp/model_internals_json.iml b/src-model/src-types-pp/model_internals_json.iml index 8f5f44b0..4913e3e9 100644 --- a/src-model/src-types-pp/model_internals_json.iml +++ b/src-model/src-types-pp/model_internals_json.iml @@ -1,12 +1,64 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../../src-core-pp/base_types_json.iml"] +open Base_types_json;; +[@@@import "../../src-core/datetime.iml"] +open Datetime;; +[@@@import "../../src-core-pp/datetime_json.iml"] +open Datetime_json;; +[@@@import "../../src-protocol-exts-pp/json_generator_utils.iml"] +open Json_generator_utils;; +[@@@import "../src-types/model_app_enums.iml"] +open Model_app_enums;; +[@@@import "model_enums_json.iml"] +open Model_enums_json;; +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; +[@@@import "model_repeating_groups_json.iml"] +open Model_repeating_groups_json;; +[@@@import "../../src-core/numeric.iml"] +open Numeric;; [@@@import "../src-types/state.iml"] open State;; +[@@@import "../../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; +[@@@require "yojson"] +open Yojson.Basic;; +let mod_internal_state_to_json (x) : json = + assoc_filter_nulls ([(("state.live_order",bool_to_json x.mod_f_internal_state_live_order)); + (("state.AvgPx",float_to_json x.mod_f_internal_state_AvgPx)); + (("state.bestBid",float_2_to_json x.mod_f_internal_state_bestBid)); + (("state.bestAsk",float_2_to_json x.mod_f_internal_state_bestAsk)); + (("state.Side",mod_side_to_json x.mod_f_internal_state_Side)); + (("state.Price",(match x.mod_f_internal_state_Price with + | None -> `Null + | Some x -> (float_2_to_json x) + ) + )); + (("state.OrderQtyData.OrderQty",float_6_to_json x.mod_f_internal_state_OrderQtyData_OrderQty)); + (("state.OrdStatus",mod_ordstatus_to_json x.mod_f_internal_state_OrdStatus)); + (("state.OrdType",mod_ordtype_to_json x.mod_f_internal_state_OrdType)); + (("state.LeavesQty",float_6_to_json x.mod_f_internal_state_LeavesQty)); + (("state.CumQty",float_6_to_json x.mod_f_internal_state_CumQty)); + (("state.SpreadProportion",(match x.mod_f_internal_state_SpreadProportion with + | None -> `Null + | Some x -> (float_to_json x) + ) + )); + (("state.Parties",mod_parties_to_json x.mod_f_internal_state_Parties)); + (("state.ExecInst",mod_execinst_to_json x.mod_f_internal_state_ExecInst)); + (("state.OrderID",string_to_json x.mod_f_internal_state_OrderID)); + (("state.ExecType",mod_exectype_to_json x.mod_f_internal_state_ExecType))]) +;; + +let mod_internal_fresh_state'_to_json (x) : json = + assoc_filter_nulls ([(("fresh_state'.seed_string",string_to_json x.mod_f_internal_fresh_state'_seed_string))]) +;; + let json_of_fix_internals (x : internal_states_types) = - `Assoc [] - [@@macro] + `Assoc (("fresh_state'",mod_internal_fresh_state'_to_json x.int_el_fresh_state') :: (("state",mod_internal_state_to_json x.int_el_state) :: [])) ;; [@@@logic] diff --git a/src-model/src-types-pp/model_messages_json.iml b/src-model/src-types-pp/model_messages_json.iml index 20877b76..a7ea1788 100644 --- a/src-model/src-types-pp/model_messages_json.iml +++ b/src-model/src-types-pp/model_messages_json.iml @@ -1,4 +1,4 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@import "../../src-core-pp/base_types_json.iml"] open Base_types_json;; @@ -10,35 +10,114 @@ open Json_generator_utils;; open Model_enums_json;; [@@@import "../src-types/model_messages.iml"] open Model_messages;; +[@@@import "model_repeating_groups_json.iml"] +open Model_repeating_groups_json;; [@@@import "model_tags_json.iml"] open Model_tags_json;; +[@@@require "yojson"] +open Yojson.Basic;; -let mod_executionreport_to_json (x) = - assoc_filter_nulls (("ClOrdID",string_to_json x.mod_f_ExecutionReport_ClOrdID) :: (("OrderID",string_to_json x.mod_f_ExecutionReport_OrderID) :: (("ExecID",string_to_json x.mod_f_ExecutionReport_ExecID) :: (("ExecType",mod_exectype_to_json x.mod_f_ExecutionReport_ExecType) :: (("AvgPx",float_6_to_json x.mod_f_ExecutionReport_AvgPx) :: (("Side",mod_side_to_json x.mod_f_ExecutionReport_Side) :: (("LeavesQty",float_6_to_json x.mod_f_ExecutionReport_LeavesQty) :: (("CumQty",float_6_to_json x.mod_f_ExecutionReport_CumQty) :: (("OrdStatus",mod_ordstatus_to_json x.mod_f_ExecutionReport_OrdStatus) :: (("Instrument.Symbol",string_to_json x.mod_f_ExecutionReport_Instrument_Symbol) :: (("Text",(match x.mod_f_ExecutionReport_Text with +let mod_newordersingle_opt_def_to_json (x) : json = + assoc_filter_nulls ([(("ClOrdID",(match x.mod_def_opt_f_NewOrderSingle_ClOrdID with | None -> `Null | Some x -> (string_to_json x) ) - ) :: []))))))))))) + ));(("Side",mod_side_to_json x.mod_def_opt_f_NewOrderSingle_Side));(("TransactTime",utctimestamp_milli_to_json x.mod_def_opt_f_NewOrderSingle_TransactTime));(("OrdType",mod_ordtype_to_json x.mod_def_opt_f_NewOrderSingle_OrdType));(("OrderQtyData.OrderQty",float_6_to_json x.mod_def_opt_f_NewOrderSingle_OrderQtyData_OrderQty));(("SpreadProportion",(match x.mod_def_opt_f_NewOrderSingle_SpreadProportion with + | None -> `Null + | Some x -> (float_to_json x) + ) + ));(("Price",(match x.mod_def_opt_f_NewOrderSingle_Price with + | None -> `Null + | Some x -> (float_2_to_json x) + ) + ));(("Account",(match x.mod_def_opt_f_NewOrderSingle_Account with + | None -> `Null + | Some x -> (string_to_json x) + ) + ));(("ExecInst",(match x.mod_def_opt_f_NewOrderSingle_ExecInst with + | None -> `Null + | Some x -> (mod_execinst_to_json x) + ) + ));(("Parties",mod_parties_to_json x.mod_def_opt_f_NewOrderSingle_Parties))]) ;; -let mod_newordersingle_to_json (x) = - assoc_filter_nulls (("ClOrdID",string_to_json x.mod_f_NewOrderSingle_ClOrdID) :: (("Side",mod_side_to_json x.mod_f_NewOrderSingle_Side) :: (("TransactTime",utctimestamp_milli_to_json x.mod_f_NewOrderSingle_TransactTime) :: (("OrdType",mod_ordtype_to_json x.mod_f_NewOrderSingle_OrdType) :: (("Instrument.Symbol",string_to_json x.mod_f_NewOrderSingle_Instrument_Symbol) :: []))))) - [@@macro] +let mod_newordersingle_to_json (x) : json = + assoc_filter_nulls ([(("ClOrdID",(match x.mod_f_NewOrderSingle_ClOrdID with + | None -> `Null + | Some x -> (string_to_json x) + ) + ));(("Side",mod_side_to_json x.mod_f_NewOrderSingle_Side));(("TransactTime",utctimestamp_milli_to_json x.mod_f_NewOrderSingle_TransactTime));(("OrdType",mod_ordtype_to_json x.mod_f_NewOrderSingle_OrdType));(("OrderQtyData.OrderQty",float_6_to_json x.mod_f_NewOrderSingle_OrderQtyData_OrderQty));(("SpreadProportion",(match x.mod_f_NewOrderSingle_SpreadProportion with + | None -> `Null + | Some x -> (float_to_json x) + ) + ));(("Price",(match x.mod_f_NewOrderSingle_Price with + | None -> `Null + | Some x -> (float_2_to_json x) + ) + ));(("Account",(match x.mod_f_NewOrderSingle_Account with + | None -> `Null + | Some x -> (string_to_json x) + ) + ));(("ExecInst",mod_execinst_to_json x.mod_f_NewOrderSingle_ExecInst));(("Parties",mod_parties_to_json x.mod_f_NewOrderSingle_Parties))]) +;; + +let mod_executionreport_opt_def_to_json (x) : json = + assoc_filter_nulls ([(("OrderID",string_to_json x.mod_def_opt_f_ExecutionReport_OrderID)); + (("ExecID",string_to_json x.mod_def_opt_f_ExecutionReport_ExecID)); + (("ExecType",mod_exectype_to_json x.mod_def_opt_f_ExecutionReport_ExecType)); + (("OrdStatus",mod_ordstatus_to_json x.mod_def_opt_f_ExecutionReport_OrdStatus)); + (("Side",mod_side_to_json x.mod_def_opt_f_ExecutionReport_Side)); + (("OrderQtyData.OrderQty",float_6_to_json x.mod_def_opt_f_ExecutionReport_OrderQtyData_OrderQty)); + (("LeavesQty",float_6_to_json x.mod_def_opt_f_ExecutionReport_LeavesQty)); + (("CumQty",float_6_to_json x.mod_def_opt_f_ExecutionReport_CumQty)); + (("Text",(match x.mod_def_opt_f_ExecutionReport_Text with + | None -> `Null + | Some x -> (string_to_json x) + ) + )); + (("Parties",mod_parties_to_json x.mod_def_opt_f_ExecutionReport_Parties)); + (("ExecInst",mod_execinst_to_json x.mod_def_opt_f_ExecutionReport_ExecInst))]) +;; + +let mod_executionreport_to_json (x) : json = + assoc_filter_nulls ([(("OrderID",string_to_json x.mod_f_ExecutionReport_OrderID)); + (("ExecID",string_to_json x.mod_f_ExecutionReport_ExecID)); + (("ExecType",mod_exectype_to_json x.mod_f_ExecutionReport_ExecType)); + (("OrdStatus",mod_ordstatus_to_json x.mod_f_ExecutionReport_OrdStatus)); + (("Side",mod_side_to_json x.mod_f_ExecutionReport_Side)); + (("OrderQtyData.OrderQty",float_6_to_json x.mod_f_ExecutionReport_OrderQtyData_OrderQty)); + (("LeavesQty",float_6_to_json x.mod_f_ExecutionReport_LeavesQty)); + (("CumQty",float_6_to_json x.mod_f_ExecutionReport_CumQty)); + (("Text",(match x.mod_f_ExecutionReport_Text with + | None -> `Null + | Some x -> (string_to_json x) + ) + )); + (("Parties",mod_parties_to_json x.mod_f_ExecutionReport_Parties)); + (("ExecInst",mod_execinst_to_json x.mod_f_ExecutionReport_ExecInst))]) +;; + +let json_of_model_msg (x) : json = + (match x with + | FIX_Msg_NewOrderSingle x -> (`Assoc ([(("tag",`String "D"));(("data",mod_newordersingle_to_json x))])) + | FIX_Msg_ExecutionReport x -> (`Assoc ([(("tag",`String "8"));(("data",mod_executionreport_to_json x))])) + ) ;; -let json_of_model_msg (x) = +let json_of_model_msg_opt_def (x) : json = (match x with - | FIX_Msg_ExecutionReport x -> (`Assoc (("tag",`String "8") :: (("data",mod_executionreport_to_json x) :: []))) - | FIX_Msg_NewOrderSingle x -> (`Assoc (("tag",`String "D") :: (("data",mod_newordersingle_to_json x) :: []))) + | FIX_Msg_Def_Opt_NewOrderSingle x -> (`Assoc ([(("tag",`String "D"));(("data",mod_newordersingle_opt_def_to_json x))])) + | FIX_Msg_Def_Opt_ExecutionReport x -> (`Assoc ([(("tag",`String "8"));(("data",mod_executionreport_opt_def_to_json x))])) ) ;; -let json_of_top_level_msg (x) = +let json_of_top_level_msg (x) : json = (match x with - | FIX_TL_Normal x -> (`Assoc (("top_level_msg",`String "FIX_TL_Normal") :: (("data",json_of_model_msg x) :: []))) - | FIX_TL_Req_Field_Missing x -> (`Assoc (("top_level_msg",`String "FIX_TL_Req_Field_Missing") :: (("data",json_of_req_field_missing x) :: []))) - | FIX_TL_PossibleResend x -> (`Assoc (("top_level_msg",`String "FIX_TL_PossibleResend") :: (("data",json_of_model_msg x) :: []))) + | FIX_TL_Normal x -> (`Assoc ([(("top_level_msg",`String "FIX_TL_Normal"));(("data",json_of_model_msg_opt_def x))])) + | FIX_TL_Req_Field_Missing x -> (`Assoc ([(("top_level_msg",`String "FIX_TL_Req_Field_Missing"));(("data",json_of_req_field_missing x))])) + | FIX_TL_Req_Field_Invalid x -> (`Assoc ([(("top_level_msg",`String "FIX_TL_Req_Field_Invalid"));(("data",json_of_req_field_missing x))])) + | FIX_TL_PossibleResend x -> (`Assoc ([(("top_level_msg",`String "FIX_TL_PossibleResend"));(("data",json_of_model_msg_opt_def x))])) | FIX_TL_None -> `Null ) ;; diff --git a/src-model/src-types-pp/model_records_json.iml b/src-model/src-types-pp/model_records_json.iml index 532e5080..c4978abc 100644 --- a/src-model/src-types-pp/model_records_json.iml +++ b/src-model/src-types-pp/model_records_json.iml @@ -1,5 +1,37 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../../src-core-pp/base_types_json.iml"] +open Base_types_json;; +[@@@import "../../src-core-pp/datetime_json.iml"] +open Datetime_json;; +[@@@import "../../src-protocol-exts-pp/json_generator_utils.iml"] +open Json_generator_utils;; +[@@@import "../src-types/model_records.iml"] +open Model_records;; +[@@@require "yojson"] +open Yojson.Basic;; +let mod_act_bookstate_opt_to_json (y) : json = + (match y with + | None -> `Null + | Some x -> (assoc_filter_nulls ([(("bestBid",float_2_to_json x.mod_f_bookState_bestBid));(("bestAsk",float_2_to_json x.mod_f_bookState_bestAsk))])) + ) +;; + +let mod_act_bookstate_to_json (x) : json = + assoc_filter_nulls ([(("bestBid",float_2_to_json x.mod_f_bookState_bestBid));(("bestAsk",float_2_to_json x.mod_f_bookState_bestAsk))]) +;; + +let mod_act_fill_opt_to_json (y) : json = + (match y with + | None -> `Null + | Some x -> (assoc_filter_nulls ([(("fill_price",float_2_to_json x.mod_f_fill_fill_price));(("fill_qty",float_6_to_json x.mod_f_fill_fill_qty))])) + ) +;; + +let mod_act_fill_to_json (x) : json = + assoc_filter_nulls ([(("fill_price",float_2_to_json x.mod_f_fill_fill_price));(("fill_qty",float_6_to_json x.mod_f_fill_fill_qty))]) +;; + [@@@logic] diff --git a/src-model/src-types-pp/model_repeating_groups_json.iml b/src-model/src-types-pp/model_repeating_groups_json.iml index 532e5080..5ede5fdc 100644 --- a/src-model/src-types-pp/model_repeating_groups_json.iml +++ b/src-model/src-types-pp/model_repeating_groups_json.iml @@ -1,5 +1,41 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../../src-core-pp/base_types_json.iml"] +open Base_types_json;; +[@@@import "../../src-core-pp/datetime_json.iml"] +open Datetime_json;; +[@@@import "../../src-protocol-exts-pp/json_generator_utils.iml"] +open Json_generator_utils;; +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; +[@@@require "yojson"] +open Yojson.Basic;; +let model_PtysSubGrp_rg_to_json (x) : json = + (match x with + | None -> `Null + | Some x -> (assoc_filter_nulls ([(("PartySubID",(match x.mod_f_PtysSubGrp_PartySubID with + | None -> `Null + | Some x -> (string_to_json x) + ) + ))])) + ) +;; + +let mod_ptyssubgrp_to_json (d) = + assoc_filter_nulls ([(("4",model_PtysSubGrp_rg_to_json d.rg_PtysSubGrp_element_4));(("3",model_PtysSubGrp_rg_to_json d.rg_PtysSubGrp_element_3));(("2",model_PtysSubGrp_rg_to_json d.rg_PtysSubGrp_element_2));(("1",model_PtysSubGrp_rg_to_json d.rg_PtysSubGrp_element_1));(("0",model_PtysSubGrp_rg_to_json d.rg_PtysSubGrp_element_0))]) +;; + +let model_Parties_rg_to_json (x) : json = + (match x with + | None -> `Null + | Some x -> (assoc_filter_nulls ([(("PartyID",string_to_json x.mod_f_Parties_PartyID));(("PartyIndex",int_to_json x.mod_f_Parties_PartyIndex));(("PtysSubGrp",mod_ptyssubgrp_to_json x.mod_f_Parties_PtysSubGrp))])) + ) +;; + +let mod_parties_to_json (d) = + assoc_filter_nulls ([(("4",model_Parties_rg_to_json d.rg_Parties_element_4));(("3",model_Parties_rg_to_json d.rg_Parties_element_3));(("2",model_Parties_rg_to_json d.rg_Parties_element_2));(("1",model_Parties_rg_to_json d.rg_Parties_element_1));(("0",model_Parties_rg_to_json d.rg_Parties_element_0))]) +;; + [@@@logic] diff --git a/src-model/src-types-pp/model_state_json.iml b/src-model/src-types-pp/model_state_json.iml index 4fb4ab1d..8206f7dd 100644 --- a/src-model/src-types-pp/model_state_json.iml +++ b/src-model/src-types-pp/model_state_json.iml @@ -1,7 +1,9 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@import "model_actions_json.iml"] open Model_actions_json;; +[@@@import "model_internals_json.iml"] +open Model_internals_json;; [@@@import "model_messages_json.iml"] open Model_messages_json;; [@@@import "../src-types/state.iml"] @@ -9,17 +11,17 @@ open State;; let model_state_to_json (m_state) = - `Assoc (("incoming_action",(match m_state.incoming_action with + `Assoc ([(("incoming_action",(match m_state.incoming_action with | None -> `Null | Some x -> (json_of_fix_action x) ) - ) :: (("incoming_msg",json_of_top_level_msg m_state.incoming_msg) :: (("outgoing_msgs",`List (List.map (fun x -> `Assoc (("outgoing_msg_counter",`Int (Z.to_int x.outgoing_msg_counter)) :: (("outgoing_msg_msg",json_of_model_msg x.outgoing_msg_msg) :: [])) - ) m_state.outgoing_msgs)) :: (("event_counter",`Int (Z.to_int m_state.event_counter)) :: (("event_info",`List (List.map (fun x -> `Assoc (("state_event_counter",`Int (Z.to_int x.state_event_counter)) :: (("state_event_reject_text",(match x.state_event_reject_text with + ));(("incoming_msg",json_of_top_level_msg m_state.incoming_msg));(("outgoing_msgs",`List (List.map (fun x -> `Assoc ([(("outgoing_msg_counter",`String (Z.to_string x.outgoing_msg_counter)));(("outgoing_msg_msg",json_of_model_msg x.outgoing_msg_msg))]) + ) m_state.outgoing_msgs)));(("state",mod_internal_state_to_json m_state.f_internal_state));(("fresh_state'",mod_internal_fresh_state'_to_json m_state.f_internal_fresh_state'));(("event_counter",`String (Z.to_string m_state.event_counter)));(("event_info",`List (List.map (fun x -> `Assoc ([(("state_event_counter",`String (Z.to_string x.state_event_counter)));(("state_event_reject_text",(match x.state_event_reject_text with | None -> `Null | Some y -> (`String y) ) - ) :: [])) - ) m_state.event_info)) :: []))))) + ))]) + ) m_state.event_info)))]) ;; [@@@logic] diff --git a/src-model/src-types-pp/model_tags_json.iml b/src-model/src-types-pp/model_tags_json.iml index a51502b9..fe6d5a6a 100644 --- a/src-model/src-types-pp/model_tags_json.iml +++ b/src-model/src-types-pp/model_tags_json.iml @@ -1,31 +1,50 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@import "../src-types/model_messages.iml"] open Model_messages;; +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; [@@@import "../src-types/model_tags.iml"] open Model_tags;; +[@@@require "yojson"] +open Yojson.Basic;; -let json_of_model_msg_tag (msg : m_msg_tag) = +let json_of_model_msg_tag (msg : m_msg_tag) : json = (match msg with - | M_Msg_ExecutionReport_Tag -> (`String "8") | M_Msg_NewOrderSingle_Tag -> (`String "D") + | M_Msg_ExecutionReport_Tag -> (`String "8") ) ;; -let json_of_model_field_tag (x : m_field_tag) = +let json_of_model_field_tag (x : m_field_tag) : json = (match x with - | M_Field_Symbol_Tag -> (`String "55") - | M_Field_TransactTime_Tag -> (`String "60") | M_Field_Side_Tag -> (`String "54") - | M_Field_ClOrdID_Tag -> (`String "11") + | M_Field_TransactTime_Tag -> (`String "60") | M_Field_OrdType_Tag -> (`String "40") + | M_Field_OrderQty_Tag -> (`String "38") + | M_Field_ExecInst_Tag -> (`String "18") + | M_Field_PartyID_Tag -> (`String "448") + | M_Field_PartyIndex_Tag -> (`String "10002") + | M_Field_OrderID_Tag -> (`String "37") + | M_Field_ExecID_Tag -> (`String "17") + | M_Field_ExecType_Tag -> (`String "150") + | M_Field_OrdStatus_Tag -> (`String "39") + | M_Field_LeavesQty_Tag -> (`String "151") + | M_Field_CumQty_Tag -> (`String "14") + ) +;; + +let json_of_model_rg (x : repeating_group_defs option) : json = + (match x with + | Some MOD_FIX_Repeating_Group_PtysSubGrp -> (`String "PtysSubGrp") + | Some MOD_FIX_Repeating_Group_Parties -> (`String "Parties") + | _ -> `Null ) ;; -let json_of_req_field_missing (x : field_missing_data) = - `Assoc (("m_msg_tag",json_of_model_msg_tag x.field_missing_data_msg) :: (("m_field_tag",json_of_model_field_tag x.field_missing_data_field) :: [])) - [@@macro] +let json_of_req_field_missing (x : field_missing_or_invalid_data) : json = + `Assoc ([(("m_msg_tag",json_of_model_msg_tag x.field_missing_of_invalid_data_msg));(("m_field_tag",json_of_model_field_tag x.field_missing_or_invalid_data_field));(("repeating_group_defs",json_of_model_rg x.repeating_group_origin))]) ;; [@@@logic] diff --git a/src-model/src-types-pp/scenario_event_json.iml b/src-model/src-types-pp/scenario_event_json.iml index 8295ed8a..c160a7de 100644 --- a/src-model/src-types-pp/scenario_event_json.iml +++ b/src-model/src-types-pp/scenario_event_json.iml @@ -1,4 +1,4 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@import "model_actions_json.iml"] open Model_actions_json;; @@ -6,12 +6,14 @@ open Model_actions_json;; open Model_messages_json;; [@@@import "../../vgs/templates/scenario_type.iml"] open Scenario_type;; +[@@@require "yojson"] +open Yojson.Basic;; -let json_of_scenario_event (x) = +let json_of_scenario_event (x) : json = (match x with - | Action x -> (`Assoc (("action",json_of_fix_action x) :: [])) - | Message x -> (`Assoc (("message",json_of_model_msg x) :: [])) + | Action x -> (`Assoc ([(("action",json_of_fix_action x))])) + | Message x -> (`Assoc ([(("message",json_of_model_msg_opt_def x))])) ) ;; diff --git a/src-model/src-types/actions.iml b/src-model/src-types/actions.iml index 16948b78..75726b5d 100644 --- a/src-model/src-types/actions.iml +++ b/src-model/src-types/actions.iml @@ -1,6 +1,14 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "model_records.iml"] +open Model_records;; type fix_action = - | EmptyAction + | FIX_Action_fill of m_action_fix_fill + | FIX_Action_bookState of m_action_fix_bookstate ;; + +type fix_model_record = + | EmptyRecords +;; + diff --git a/src-model/src-types/dune b/src-model/src-types/dune index 90e89d49..474f2286 100644 --- a/src-model/src-types/dune +++ b/src-model/src-types/dune @@ -1,7 +1,7 @@ (library - (name venue_types) - (public_name fix-engine.venue_types) - (wrapped false) - (flags - (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) - (libraries imandra-prelude core core_time_defaults)) + (name venue_types) + (public_name fix-engine.venue_types) + (wrapped false) + (flags (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) + (libraries imandra-prelude core core_time_defaults) +) diff --git a/src-model/src-types/model_app_enums.iml b/src-model/src-types/model_app_enums.iml index 9e3b34ed..3678ac6b 100644 --- a/src-model/src-types/model_app_enums.iml +++ b/src-model/src-types/model_app_enums.iml @@ -1,4 +1,4 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) type model_fix_side = @@ -20,6 +20,70 @@ type model_fix_side = | MOD_FIX_Side_Borrow ;; +type model_fix_ordtype = + | MOD_FIX_OrdType_Market + | MOD_FIX_OrdType_Limit + | MOD_FIX_OrdType_Stop + | MOD_FIX_OrdType_StopLimit + | MOD_FIX_OrdType_WithOrWithout + | MOD_FIX_OrdType_LimitOrBetter + | MOD_FIX_OrdType_LimitWithOrWithout + | MOD_FIX_OrdType_OnBasis + | MOD_FIX_OrdType_PreviouslyQuoted + | MOD_FIX_OrdType_PreviouslyIndicated + | MOD_FIX_OrdType_ForexSwap + | MOD_FIX_OrdType_Funari + | MOD_FIX_OrdType_MarketIfTouched + | MOD_FIX_OrdType_MarketWithLeftOverAsLimit + | MOD_FIX_OrdType_PreviousFundValuationPoint + | MOD_FIX_OrdType_NextFundValuationPoint + | MOD_FIX_OrdType_Pegged + | MOD_FIX_OrdType_StopSpread +;; + +type model_fix_execinst = + | MOD_FIX_ExecInst_NotHeld + | MOD_FIX_ExecInst_Work + | MOD_FIX_ExecInst_GoAlong + | MOD_FIX_ExecInst_OverTheDay + | MOD_FIX_ExecInst_Held + | MOD_FIX_ExecInst_ParticipateDoNotInitiate + | MOD_FIX_ExecInst_StrictScale + | MOD_FIX_ExecInst_TryToScale + | MOD_FIX_ExecInst_StayOnBidSide + | MOD_FIX_ExecInst_StayOnOfferSide + | MOD_FIX_ExecInst_NoCross + | MOD_FIX_ExecInst_OKToCross + | MOD_FIX_ExecInst_CallFirst + | MOD_FIX_ExecInst_PercentOfVolume + | MOD_FIX_ExecInst_DoNotIncrease + | MOD_FIX_ExecInst_DoNotReduce + | MOD_FIX_ExecInst_AllOrNone + | MOD_FIX_ExecInst_ReinstateOnSystemFailure + | MOD_FIX_ExecInst_InstitutionsOnly + | MOD_FIX_ExecInst_ReinstateOnTradingHalt + | MOD_FIX_ExecInst_CancelOnTradingHalt + | MOD_FIX_ExecInst_LastPeg + | MOD_FIX_ExecInst_MidPricePeg + | MOD_FIX_ExecInst_NonNegotiable + | MOD_FIX_ExecInst_OpeningPeg + | MOD_FIX_ExecInst_MarketPeg + | MOD_FIX_ExecInst_CancelOnSystemFailure + | MOD_FIX_ExecInst_PrimaryPeg + | MOD_FIX_ExecInst_Suspend + | MOD_FIX_ExecInst_CustomerDisplayInstruction + | MOD_FIX_ExecInst_Netting + | MOD_FIX_ExecInst_PegToVWAP + | MOD_FIX_ExecInst_TradeAlong + | MOD_FIX_ExecInst_TryToStop + | MOD_FIX_ExecInst_CancelIfNotBest + | MOD_FIX_ExecInst_TrailingStopPeg + | MOD_FIX_ExecInst_StrictLimit + | MOD_FIX_ExecInst_IgnorePriceValidityChecks + | MOD_FIX_ExecInst_PegToLimitPrice + | MOD_FIX_ExecInst_WorkToTargetStrategy +;; + type model_fix_exectype = | MOD_FIX_ExecType_New | MOD_FIX_ExecType_DoneForDay @@ -58,22 +122,32 @@ type model_fix_ordstatus = | MOD_FIX_OrdStatus_Replaced ;; -type model_fix_ordtype = - | MOD_FIX_OrdType_Market - | MOD_FIX_OrdType_Limit - | MOD_FIX_OrdType_Stop - | MOD_FIX_OrdType_StopLimit - | MOD_FIX_OrdType_WithOrWithout - | MOD_FIX_OrdType_LimitOrBetter - | MOD_FIX_OrdType_LimitWithOrWithout - | MOD_FIX_OrdType_OnBasis - | MOD_FIX_OrdType_PreviouslyQuoted - | MOD_FIX_OrdType_PreviouslyIndicated - | MOD_FIX_OrdType_ForexSwap - | MOD_FIX_OrdType_Funari - | MOD_FIX_OrdType_MarketIfTouched - | MOD_FIX_OrdType_MarketWithLeftOverAsLimit - | MOD_FIX_OrdType_PreviousFundValuationPoint - | MOD_FIX_OrdType_NextFundValuationPoint - | MOD_FIX_OrdType_Pegged +type model_fix_partysubidtype = + | MOD_FIX_PartySubIDType_Firm + | MOD_FIX_PartySubIDType_Person + | MOD_FIX_PartySubIDType_System + | MOD_FIX_PartySubIDType_Application + | MOD_FIX_PartySubIDType_FullLegalNameOfFirm + | MOD_FIX_PartySubIDType_PostalAddress + | MOD_FIX_PartySubIDType_PhoneNumber + | MOD_FIX_PartySubIDType_EmailAddress + | MOD_FIX_PartySubIDType_ContactName + | MOD_FIX_PartySubIDType_SecuritiesAccountNumber + | MOD_FIX_PartySubIDType_RegistrationNumber + | MOD_FIX_PartySubIDType_RegisteredAddressForConfirmation + | MOD_FIX_PartySubIDType_RegulatoryStatus + | MOD_FIX_PartySubIDType_RegistrationName + | MOD_FIX_PartySubIDType_CashAccountNumber + | MOD_FIX_PartySubIDType_BIC + | MOD_FIX_PartySubIDType_CSDParticipantMemberCode + | MOD_FIX_PartySubIDType_RegisteredAddress + | MOD_FIX_PartySubIDType_FundAccountName + | MOD_FIX_PartySubIDType_TelexNumber + | MOD_FIX_PartySubIDType_FaxNumber + | MOD_FIX_PartySubIDType_SecuritiesAccountName + | MOD_FIX_PartySubIDType_CashAccountName + | MOD_FIX_PartySubIDType_Department + | MOD_FIX_PartySubIDType_LocationDesk + | MOD_FIX_PartySubIDType_PositionAccountType ;; + diff --git a/src-model/src-types/model_messages.iml b/src-model/src-types/model_messages.iml index 136d020f..fdc11f63 100644 --- a/src-model/src-types/model_messages.iml +++ b/src-model/src-types/model_messages.iml @@ -1,8 +1,10 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@import "../../src-core/datetime.iml"] open Datetime;; [@@@import "model_app_enums.iml"] open Model_app_enums;; +[@@@import "model_repeating_groups.iml"] +open Model_repeating_groups;; [@@@import "model_tags.iml"] open Model_tags;; [@@@import "../../src-core/numeric.iml"] @@ -11,64 +13,130 @@ open Numeric;; open Time_defaults;; +type mod_newordersingle_defopt_data = { +(** Unique identifier of the order as assigned by institution or by the intermediary (CIV term, not a hub/service bureau) with closest association with the investor.*) + mod_def_opt_f_NewOrderSingle_ClOrdID : string option; + mod_def_opt_f_NewOrderSingle_Side : model_fix_side; +(** Time this order request was initiated/released by the trader, trading system, or intermediary.*) + mod_def_opt_f_NewOrderSingle_TransactTime : fix_utctimestamp_milli; + mod_def_opt_f_NewOrderSingle_OrdType : model_fix_ordtype; +(** One of CashOrderQty, OrderQty, or (for CIV only) OrderPercent is required. Note that unless otherwise specified, only one of CashOrderQty, OrderQty, or OrderPercent should be specified.*) + mod_def_opt_f_NewOrderSingle_OrderQtyData_OrderQty : fix_float_6; + mod_def_opt_f_NewOrderSingle_SpreadProportion : fix_float option; +(** Required for limit OrdTypes. For F/X orders, should be the "all-in" rate (spot rate adjusted for forward points). Can be used to specify a limit price for a pegged order, previously indicated, etc.*) + mod_def_opt_f_NewOrderSingle_Price : fix_float_2 option; + mod_def_opt_f_NewOrderSingle_Account : string option; +(** Can contain multiple instructions, space delimited. If OrdType=P, exactly one of the following values (ExecInst = L, R, M, P, O, T, W, a, d) must be specified.*) + mod_def_opt_f_NewOrderSingle_ExecInst : (model_fix_execinst,bool) Map.t option; +(** Insert here the set of "Parties" (firm identification) fields defined in "Common Components of Application Messages"*) + mod_def_opt_f_NewOrderSingle_Parties : model_fix_rec_parties +} +;; + +type mod_newordersingle_data = { +(** Unique identifier of the order as assigned by institution or by the intermediary (CIV term, not a hub/service bureau) with closest association with the investor.*) + mod_f_NewOrderSingle_ClOrdID : string option; + mod_f_NewOrderSingle_Side : model_fix_side; +(** Time this order request was initiated/released by the trader, trading system, or intermediary.*) + mod_f_NewOrderSingle_TransactTime : fix_utctimestamp_milli; + mod_f_NewOrderSingle_OrdType : model_fix_ordtype; +(** One of CashOrderQty, OrderQty, or (for CIV only) OrderPercent is required. Note that unless otherwise specified, only one of CashOrderQty, OrderQty, or OrderPercent should be specified.*) + mod_f_NewOrderSingle_OrderQtyData_OrderQty : fix_float_6; + mod_f_NewOrderSingle_SpreadProportion : fix_float option; +(** Required for limit OrdTypes. For F/X orders, should be the "all-in" rate (spot rate adjusted for forward points). Can be used to specify a limit price for a pegged order, previously indicated, etc.*) + mod_f_NewOrderSingle_Price : fix_float_2 option; + mod_f_NewOrderSingle_Account : string option; +(** Can contain multiple instructions, space delimited. If OrdType=P, exactly one of the following values (ExecInst = L, R, M, P, O, T, W, a, d) must be specified.*) + mod_f_NewOrderSingle_ExecInst : (model_fix_execinst,bool) Map.t; +(** Insert here the set of "Parties" (firm identification) fields defined in "Common Components of Application Messages"*) + mod_f_NewOrderSingle_Parties : model_fix_rec_parties +} +;; + +type mod_executionreport_defopt_data = { +(** OrderID is required to be unique for each chain of orders.*) + mod_def_opt_f_ExecutionReport_OrderID : string; +(** Unique identifier of execution message as assigned by sell-side (broker, exchange, ECN) (will be 0 (zero) forExecType=I (Order Status)).*) + mod_def_opt_f_ExecutionReport_ExecID : string; +(** Describes the purpose of the execution report.*) + mod_def_opt_f_ExecutionReport_ExecType : model_fix_exectype; +(** Describes the current state of a CHAIN of orders, same scope as OrderQty, CumQty, LeavesQty, and AvgPx*) + mod_def_opt_f_ExecutionReport_OrdStatus : model_fix_ordstatus; + mod_def_opt_f_ExecutionReport_Side : model_fix_side; +(** One of CashOrderQty, OrderQty, or (for CIV only) OrderPercent is required. Note that unless otherwise specified, only one of CashOrderQty, OrderQty, or OrderPercent should be specified.*) + mod_def_opt_f_ExecutionReport_OrderQtyData_OrderQty : fix_float_6; +(** Quantity open for further execution. If the OrdStatus is Canceled, DoneForTheDay, Expired, Calculated, or Rejected (in which case the order is no longer active) then LeavesQty could be 0, otherwise LeavesQty = OrderQty - CumQty.*) + mod_def_opt_f_ExecutionReport_LeavesQty : fix_float_6; +(** Currently executed quantity for chain of orders.*) + mod_def_opt_f_ExecutionReport_CumQty : fix_float_6; + mod_def_opt_f_ExecutionReport_Text : string option; +(** Insert here the set of "Parties" (firm identification) fields defined in "Common Components of Application Messages"*) + mod_def_opt_f_ExecutionReport_Parties : model_fix_rec_parties; +(** Can contain multiple instructions, space delimited.*) + mod_def_opt_f_ExecutionReport_ExecInst : (model_fix_execinst,bool) Map.t +} +;; + type mod_executionreport_data = { -(** Required for executions against electronically submitted orders which were assigned an ID by the institution or intermediary. Not required for orders manually entered by the broker or fund manager (for CIV orders).*) - mod_f_ExecutionReport_ClOrdID : string; (** OrderID is required to be unique for each chain of orders.*) mod_f_ExecutionReport_OrderID : string; (** Unique identifier of execution message as assigned by sell-side (broker, exchange, ECN) (will be 0 (zero) forExecType=I (Order Status)).*) mod_f_ExecutionReport_ExecID : string; (** Describes the purpose of the execution report.*) mod_f_ExecutionReport_ExecType : model_fix_exectype; - mod_f_ExecutionReport_AvgPx : fix_float_6; +(** Describes the current state of a CHAIN of orders, same scope as OrderQty, CumQty, LeavesQty, and AvgPx*) + mod_f_ExecutionReport_OrdStatus : model_fix_ordstatus; mod_f_ExecutionReport_Side : model_fix_side; +(** One of CashOrderQty, OrderQty, or (for CIV only) OrderPercent is required. Note that unless otherwise specified, only one of CashOrderQty, OrderQty, or OrderPercent should be specified.*) + mod_f_ExecutionReport_OrderQtyData_OrderQty : fix_float_6; (** Quantity open for further execution. If the OrdStatus is Canceled, DoneForTheDay, Expired, Calculated, or Rejected (in which case the order is no longer active) then LeavesQty could be 0, otherwise LeavesQty = OrderQty - CumQty.*) mod_f_ExecutionReport_LeavesQty : fix_float_6; (** Currently executed quantity for chain of orders.*) mod_f_ExecutionReport_CumQty : fix_float_6; -(** Describes the current state of a CHAIN of orders, same scope as OrderQty, CumQty, LeavesQty, and AvgPx*) - mod_f_ExecutionReport_OrdStatus : model_fix_ordstatus; -(** Common, "human understood" representation of the security. SecurityID value can be specified if no symbol exists (e.g. non-exchange traded Collective Investment Vehicles) - Use "[N/A]" for products which do not have a symbol.*) - mod_f_ExecutionReport_Instrument_Symbol : string; - mod_f_ExecutionReport_Text : string option -} -;; - -type mod_newordersingle_data = { -(** Unique identifier of the order as assigned by institution or by the intermediary (CIV term, not a hub/service bureau) with closest association with the investor.*) - mod_f_NewOrderSingle_ClOrdID : string; - mod_f_NewOrderSingle_Side : model_fix_side; -(** Time this order request was initiated/released by the trader, trading system, or intermediary.*) - mod_f_NewOrderSingle_TransactTime : fix_utctimestamp_milli; - mod_f_NewOrderSingle_OrdType : model_fix_ordtype; -(** Common, "human understood" representation of the security. SecurityID value can be specified if no symbol exists (e.g. non-exchange traded Collective Investment Vehicles) - Use "[N/A]" for products which do not have a symbol.*) - mod_f_NewOrderSingle_Instrument_Symbol : string + mod_f_ExecutionReport_Text : string option; +(** Insert here the set of "Parties" (firm identification) fields defined in "Common Components of Application Messages"*) + mod_f_ExecutionReport_Parties : model_fix_rec_parties; +(** Can contain multiple instructions, space delimited.*) + mod_f_ExecutionReport_ExecInst : (model_fix_execinst,bool) Map.t } ;; type model_msg = - | FIX_Msg_ExecutionReport of mod_executionreport_data | FIX_Msg_NewOrderSingle of mod_newordersingle_data + | FIX_Msg_ExecutionReport of mod_executionreport_data +;; + +type model_msg_opt_def = + | FIX_Msg_Def_Opt_NewOrderSingle of mod_newordersingle_defopt_data + | FIX_Msg_Def_Opt_ExecutionReport of mod_executionreport_defopt_data +;; + +let is_msg_opt_def_inbound (msg : model_msg_opt_def) = + (match msg with + | FIX_Msg_Def_Opt_NewOrderSingle _ -> true + | FIX_Msg_Def_Opt_ExecutionReport _ -> false + ) ;; let is_msg_inbound (msg : model_msg) = (match msg with - | FIX_Msg_ExecutionReport _ -> false | FIX_Msg_NewOrderSingle _ -> true + | FIX_Msg_ExecutionReport _ -> false ) ;; -type field_missing_data = { - field_missing_data_field : m_field_tag; - field_missing_data_msg : m_msg_tag +type field_missing_or_invalid_data = { + field_missing_or_invalid_data_field : m_field_tag; + field_missing_of_invalid_data_msg : m_msg_tag; + repeating_group_origin : repeating_group_defs option } ;; type model_top_level_msg = - | FIX_TL_Normal of model_msg - | FIX_TL_Req_Field_Missing of field_missing_data - | FIX_TL_PossibleResend of model_msg + | FIX_TL_Normal of model_msg_opt_def + | FIX_TL_Req_Field_Missing of field_missing_or_invalid_data + | FIX_TL_Req_Field_Invalid of field_missing_or_invalid_data + | FIX_TL_PossibleResend of model_msg_opt_def | FIX_TL_None ;; + diff --git a/src-model/src-types/model_records.iml b/src-model/src-types/model_records.iml index 39d1ce2a..d4d4d5e7 100644 --- a/src-model/src-types/model_records.iml +++ b/src-model/src-types/model_records.iml @@ -1,2 +1,17 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "../../src-core/numeric.iml"] +open Numeric;; + + +type m_action_fix_bookstate = { + mod_f_bookState_bestBid : fix_float_2; + mod_f_bookState_bestAsk : fix_float_2 +} +;; + +type m_action_fix_fill = { + mod_f_fill_fill_price : fix_float_2; + mod_f_fill_fill_qty : fix_float_6 +} +;; diff --git a/src-model/src-types/model_repeating_groups.iml b/src-model/src-types/model_repeating_groups.iml index 39d1ce2a..db15ef68 100644 --- a/src-model/src-types/model_repeating_groups.iml +++ b/src-model/src-types/model_repeating_groups.iml @@ -1,2 +1,122 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "../../src-core/datetime.iml"] +open Datetime;; +[@@@import "../../src-core/numeric.iml"] +open Numeric;; +[@@@import "../../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; + + +type model_fix_inner_ptyssubgrp = { + mod_f_PtysSubGrp_PartySubID : string option +} +;; + +type model_fix_rec_ptyssubgrp = { + rg_PtysSubGrp_element_0 : model_fix_inner_ptyssubgrp option; + rg_PtysSubGrp_element_1 : model_fix_inner_ptyssubgrp option; + rg_PtysSubGrp_element_2 : model_fix_inner_ptyssubgrp option; + rg_PtysSubGrp_element_3 : model_fix_inner_ptyssubgrp option; + rg_PtysSubGrp_element_4 : model_fix_inner_ptyssubgrp option +} +;; + +type model_fix_inner_parties = { + mod_f_Parties_PartyID : string; + mod_f_Parties_PartyIndex : int; + mod_f_Parties_PtysSubGrp : model_fix_rec_ptyssubgrp +} +;; + +type model_fix_rec_parties = { + rg_Parties_element_0 : model_fix_inner_parties option; + rg_Parties_element_1 : model_fix_inner_parties option; + rg_Parties_element_2 : model_fix_inner_parties option; + rg_Parties_element_3 : model_fix_inner_parties option; + rg_Parties_element_4 : model_fix_inner_parties option +} +;; + +let rg_count_ptyssubgrp (x : model_fix_rec_ptyssubgrp) : int option = + let y = 0 + in + let y = (+) ((match x.rg_PtysSubGrp_element_4 with + | None -> 0 + | Some _ -> 1 + ) + ) y + in + let y = (+) ((match x.rg_PtysSubGrp_element_3 with + | None -> 0 + | Some _ -> 1 + ) + ) y + in + let y = (+) ((match x.rg_PtysSubGrp_element_2 with + | None -> 0 + | Some _ -> 1 + ) + ) y + in + let y = (+) ((match x.rg_PtysSubGrp_element_1 with + | None -> 0 + | Some _ -> 1 + ) + ) y + in + let y = (+) ((match x.rg_PtysSubGrp_element_0 with + | None -> 0 + | Some _ -> 1 + ) + ) y + in + (if ((=) y 0) then + None + else + (Some y)) +;; + +let rg_count_parties (x : model_fix_rec_parties) : int option = + let y = 0 + in + let y = (+) ((match x.rg_Parties_element_4 with + | None -> 0 + | Some _ -> 1 + ) + ) y + in + let y = (+) ((match x.rg_Parties_element_3 with + | None -> 0 + | Some _ -> 1 + ) + ) y + in + let y = (+) ((match x.rg_Parties_element_2 with + | None -> 0 + | Some _ -> 1 + ) + ) y + in + let y = (+) ((match x.rg_Parties_element_1 with + | None -> 0 + | Some _ -> 1 + ) + ) y + in + let y = (+) ((match x.rg_Parties_element_0 with + | None -> 0 + | Some _ -> 1 + ) + ) y + in + (if ((=) y 0) then + None + else + (Some y)) +;; + +type repeating_group_defs = + | MOD_FIX_Repeating_Group_PtysSubGrp + | MOD_FIX_Repeating_Group_Parties +;; diff --git a/src-model/src-types/model_tags.iml b/src-model/src-types/model_tags.iml index 78896c8e..02c21033 100644 --- a/src-model/src-types/model_tags.iml +++ b/src-model/src-types/model_tags.iml @@ -1,15 +1,24 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) type m_field_tag = - | M_Field_Symbol_Tag - | M_Field_TransactTime_Tag | M_Field_Side_Tag - | M_Field_ClOrdID_Tag + | M_Field_TransactTime_Tag | M_Field_OrdType_Tag + | M_Field_OrderQty_Tag + | M_Field_ExecInst_Tag + | M_Field_PartyID_Tag + | M_Field_PartyIndex_Tag + | M_Field_OrderID_Tag + | M_Field_ExecID_Tag + | M_Field_ExecType_Tag + | M_Field_OrdStatus_Tag + | M_Field_LeavesQty_Tag + | M_Field_CumQty_Tag ;; type m_msg_tag = - | M_Msg_ExecutionReport_Tag | M_Msg_NewOrderSingle_Tag + | M_Msg_ExecutionReport_Tag ;; + diff --git a/src-model/src-types/state.iml b/src-model/src-types/state.iml index 590c9029..44db702f 100644 --- a/src-model/src-types/state.iml +++ b/src-model/src-types/state.iml @@ -1,10 +1,74 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@import "actions.iml"] open Actions;; +[@@@import "../../src-core/datetime.iml"] +open Datetime;; +[@@@import "model_app_enums.iml"] +open Model_app_enums;; [@@@import "model_messages.iml"] open Model_messages;; +[@@@import "model_repeating_groups.iml"] +open Model_repeating_groups;; +[@@@import "../../src-core/numeric.iml"] +open Numeric;; +[@@@import "../../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; +type fix_internal_state = { + mod_f_internal_state_live_order : bool; + mod_f_internal_state_AvgPx : fix_float; + mod_f_internal_state_bestBid : fix_float_2; + mod_f_internal_state_bestAsk : fix_float_2; + mod_f_internal_state_Side : model_fix_side; + mod_f_internal_state_Price : fix_float_2 option; + mod_f_internal_state_OrderQtyData_OrderQty : fix_float_6; + mod_f_internal_state_OrdStatus : model_fix_ordstatus; + mod_f_internal_state_OrdType : model_fix_ordtype; + mod_f_internal_state_LeavesQty : fix_float_6; + mod_f_internal_state_CumQty : fix_float_6; + mod_f_internal_state_SpreadProportion : fix_float option; + mod_f_internal_state_Parties : model_fix_rec_parties; + mod_f_internal_state_ExecInst : (model_fix_execinst,bool) Map.t; + mod_f_internal_state_OrderID : string; + mod_f_internal_state_ExecType : model_fix_exectype +} +;; + +type fix_internal_fresh_state' = { + mod_f_internal_fresh_state'_seed_string : string +} +;; + +let init_fix_internal_state = { + mod_f_internal_state_live_order = false; + mod_f_internal_state_AvgPx = float_Create_6 (0); + mod_f_internal_state_bestBid = float_Convert_6_2 (float_Create_6 (0)); + mod_f_internal_state_bestAsk = float_Convert_6_2 (float_Create_6 (0)); + mod_f_internal_state_Side = MOD_FIX_Side_Buy; + mod_f_internal_state_Price = None; + mod_f_internal_state_OrderQtyData_OrderQty = float_Create_6 (0); + mod_f_internal_state_OrdStatus = MOD_FIX_OrdStatus_PendingNew; + mod_f_internal_state_OrdType = MOD_FIX_OrdType_Market; + mod_f_internal_state_LeavesQty = float_Create_6 (0); + mod_f_internal_state_CumQty = float_Create_6 (0); + mod_f_internal_state_SpreadProportion = None; + mod_f_internal_state_Parties = { + rg_Parties_element_0 = None; + rg_Parties_element_1 = None; + rg_Parties_element_2 = None; + rg_Parties_element_3 = None; + rg_Parties_element_4 = None + }; + mod_f_internal_state_ExecInst = Map.const false; + mod_f_internal_state_OrderID = "0"; + mod_f_internal_state_ExecType = MOD_FIX_ExecType_PendingNew +} [@@macro];; + +let init_fix_internal_fresh_state' = { + mod_f_internal_fresh_state'_seed_string = "0" +} [@@macro];; + type state_event_info = { state_event_counter : int; state_event_reject_text : string option @@ -18,6 +82,8 @@ type outgoing_msg_record = { ;; type model_state = { + f_internal_state : fix_internal_state; + f_internal_fresh_state' : fix_internal_fresh_state'; incoming_action : fix_action option; outgoing_msgs : outgoing_msg_record list; incoming_msg : model_top_level_msg; @@ -27,6 +93,8 @@ type model_state = { ;; let init_model_state = { + f_internal_state = init_fix_internal_state; + f_internal_fresh_state' = init_fix_internal_fresh_state'; incoming_action = None; outgoing_msgs = []; incoming_msg = FIX_TL_None; @@ -44,10 +112,17 @@ let send_msg (msg : model_msg) (m_state : model_state) = [@@macro] ;; -type internal_states_types = int list +type internal_states_types = { + int_el_state : fix_internal_state; + int_el_fresh_state' : fix_internal_fresh_state' +} ;; let get_internal_states_types (m_state : model_state) : internal_states_types = - [] + { + int_el_state = m_state.f_internal_state; + int_el_fresh_state' = m_state.f_internal_fresh_state' + } [@@macro] ;; + diff --git a/src-model/src/act_checks.iml b/src-model/src/act_checks.iml index d008c17e..78cf586e 100644 --- a/src-model/src/act_checks.iml +++ b/src-model/src/act_checks.iml @@ -1,13 +1,52 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@import "../src-types/actions.iml"] open Actions;; +[@@@import "../../src-core/datetime.iml"] +open Datetime;; +[@@@import "../src-types/model_app_enums.iml"] +open Model_app_enums;; +[@@@import "../src-types/model_records.iml"] +open Model_records;; +[@@@import "../../src-core/numeric.iml"] +open Numeric;; [@@@import "../src-types/state.iml"] open State;; +[@@@import "../../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; +let is_valid_action_fill (action_data : m_action_fix_fill) (m_state : model_state) = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + (&&) ((==>) ((<>) local_internal_state.mod_f_internal_state_OrdType MOD_FIX_OrdType_Market) ((match local_internal_state.mod_f_internal_state_Price with + | Some cap_p -> ((if ((=) local_internal_state.mod_f_internal_state_Side MOD_FIX_Side_Buy) then + (float_LessThanEqual_2_2 action_data.mod_f_fill_fill_price cap_p) + else + (float_GreaterThanEqual_2_2 action_data.mod_f_fill_fill_price cap_p)) + ) + | None -> true + ) + )) ((&&) ((if ((=) local_internal_state.mod_f_internal_state_Side MOD_FIX_Side_Buy) then + (float_GreaterThanEqual_2_2 action_data.mod_f_fill_fill_price local_internal_state.mod_f_internal_state_bestAsk) + else + (float_LessThanEqual_2_2 action_data.mod_f_fill_fill_price local_internal_state.mod_f_internal_state_bestBid)) + ) ((&&) (float_GreaterThan_2_6 action_data.mod_f_fill_fill_price (float_Create_6 (0))) ((&&) (float_LessThanEqual_6_6 action_data.mod_f_fill_fill_qty local_internal_state.mod_f_internal_state_LeavesQty) ((&&) (float_GreaterThan_6_6 action_data.mod_f_fill_fill_qty (float_Create_6 (0))) ((&&) ((<>) local_internal_state.mod_f_internal_state_OrdStatus MOD_FIX_OrdStatus_PendingNew) true))))) +;; + +let is_valid_action_bookState (action_data : m_action_fix_bookstate) (m_state : model_state) = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + (&&) ((&&) ((&&) (float_GreaterThan_2_2 action_data.mod_f_bookState_bestAsk action_data.mod_f_bookState_bestBid) (float_GreaterThan_2_6 action_data.mod_f_bookState_bestBid (float_Create_6 (0)))) (float_GreaterThan_2_6 action_data.mod_f_bookState_bestAsk (float_Create_6 (0)))) true +;; + let is_action_valid (action : fix_action) (m_state : model_state) = (match action with - | _ -> true + | FIX_Action_fill d -> (is_valid_action_fill d m_state) + | FIX_Action_bookState d -> (is_valid_action_bookState d m_state) ) - [@@macro] ;; + diff --git a/src-model/src/act_process.iml b/src-model/src/act_process.iml index ef46b04b..dabe0395 100644 --- a/src-model/src/act_process.iml +++ b/src-model/src/act_process.iml @@ -1,8 +1,123 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@import "act_checks.iml"] open Act_checks;; [@@@import "../src-types/actions.iml"] open Actions;; +[@@@import "../../src-core/datetime.iml"] +open Datetime;; +[@@@import "ipl_functions.iml"] +open Ipl_functions;; +[@@@import "../src-types/model_app_enums.iml"] +open Model_app_enums;; +[@@@import "../src-types/model_messages.iml"] +open Model_messages;; +[@@@import "../src-types/model_records.iml"] +open Model_records;; +[@@@import "../../src-core/numeric.iml"] +open Numeric;; [@@@import "../src-types/state.iml"] open State;; +[@@@import "../../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; + + +let receive_action_fill (m_state : model_state) (action_data : m_action_fix_fill) = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + let local_internal_state = { local_internal_state with + mod_f_internal_state_LeavesQty = float_Sub_6_6 local_internal_state.mod_f_internal_state_LeavesQty action_data.mod_f_fill_fill_qty; + mod_f_internal_state_AvgPx = float_Div_6_6 (float_Add_6_6 (float_Mult_6_6 local_internal_state.mod_f_internal_state_AvgPx local_internal_state.mod_f_internal_state_CumQty) (float_Mult_6_2 action_data.mod_f_fill_fill_qty action_data.mod_f_fill_fill_price)) (float_Add_6_6 action_data.mod_f_fill_fill_qty local_internal_state.mod_f_internal_state_CumQty); + mod_f_internal_state_CumQty = float_Add_6_6 local_internal_state.mod_f_internal_state_CumQty action_data.mod_f_fill_fill_qty + } + in + let (local_internal_state) = (if ((=) local_internal_state.mod_f_internal_state_LeavesQty (float_Create_6 (0))) then + let local_internal_state = { local_internal_state with + mod_f_internal_state_OrdStatus = MOD_FIX_OrdStatus_Filled + } + in + let local_internal_state = { local_internal_state with + mod_f_internal_state_ExecType = MOD_FIX_ExecType_Trade + } + in + (local_internal_state) + else + let local_internal_state = { local_internal_state with + mod_f_internal_state_OrdStatus = MOD_FIX_OrdStatus_PartiallyFilled + } + in + let local_internal_state = { local_internal_state with + mod_f_internal_state_ExecType = MOD_FIX_ExecType_Trade + } + in + (local_internal_state) + ) + in + let local_internal_fresh_state' = { local_internal_fresh_state' with + mod_f_internal_fresh_state'_seed_string = model_func_fresh_string' local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + } + in + let local_0fresh = local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + in + let msg_data_inner = { + mod_f_ExecutionReport_CumQty = local_internal_state.mod_f_internal_state_CumQty; + mod_f_ExecutionReport_ExecID = local_0fresh; + mod_f_ExecutionReport_ExecInst = local_internal_state.mod_f_internal_state_ExecInst; + mod_f_ExecutionReport_ExecType = local_internal_state.mod_f_internal_state_ExecType; + mod_f_ExecutionReport_LeavesQty = local_internal_state.mod_f_internal_state_LeavesQty; + mod_f_ExecutionReport_OrdStatus = local_internal_state.mod_f_internal_state_OrdStatus; + mod_f_ExecutionReport_OrderID = local_internal_state.mod_f_internal_state_OrderID; + mod_f_ExecutionReport_OrderQtyData_OrderQty = local_internal_state.mod_f_internal_state_OrderQtyData_OrderQty; + mod_f_ExecutionReport_Parties = local_internal_state.mod_f_internal_state_Parties; + mod_f_ExecutionReport_Side = local_internal_state.mod_f_internal_state_Side; + mod_f_ExecutionReport_Text = None + } + in + let m_state = send_msg (FIX_Msg_ExecutionReport msg_data_inner) m_state + in + { m_state with + f_internal_state = local_internal_state; + f_internal_fresh_state' = local_internal_fresh_state' + } +;; + +let receive_action_bookState (m_state : model_state) (action_data : m_action_fix_bookstate) = + let local_internal_state = m_state.f_internal_state + in + let local_internal_state = { local_internal_state with + mod_f_internal_state_bestBid = action_data.mod_f_bookState_bestBid; + mod_f_internal_state_bestAsk = action_data.mod_f_bookState_bestAsk + } + in + let local_spread = float_Convert_2_6 (float_Div_2_2 (float_Sub_2_2 local_internal_state.mod_f_internal_state_bestAsk local_internal_state.mod_f_internal_state_bestBid) local_internal_state.mod_f_internal_state_bestAsk) + in + let (local_internal_state) = (if ((&&) ((match local_internal_state.mod_f_internal_state_SpreadProportion with + | Some cap_x -> (float_GreaterThanEqual_6_6 cap_x local_spread) + | None -> false + ) + ) ((=) local_internal_state.mod_f_internal_state_OrdStatus MOD_FIX_OrdStatus_PendingNew)) then + let local_internal_state = { local_internal_state with + mod_f_internal_state_OrdStatus = MOD_FIX_OrdStatus_New + } + in + (local_internal_state) + else + (local_internal_state)) + in + { m_state with + f_internal_state = local_internal_state + } +;; + +let receive_action (m_state : model_state) (action : fix_action) = + (if (is_action_valid action m_state) then + ((match action with + | FIX_Action_fill d -> (receive_action_fill m_state d) + | FIX_Action_bookState d -> (receive_action_bookState m_state d) + ) + ) + else + m_state) +;; diff --git a/src-model/src/dune b/src-model/src/dune index 83882a58..d35a6358 100644 --- a/src-model/src/dune +++ b/src-model/src/dune @@ -1,7 +1,7 @@ (library - (name venue) - (public_name fix-engine.venue) - (wrapped false) - (flags - (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) - (libraries imandra-prelude core venue_types)) + (name venue) + (public_name fix-engine.venue) + (wrapped false) + (flags (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) + (libraries imandra-prelude core core_fresh core_time_defaults venue_helper_functions venue_types) +) diff --git a/src-model/src/good_functions.iml b/src-model/src/good_functions.iml index 697c217e..49b77c4c 100644 --- a/src-model/src/good_functions.iml +++ b/src-model/src/good_functions.iml @@ -1,7 +1,46 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) let good_string (x) = - (&&) ((<>) x "Field Symbol of Message NewOrderSingle is missing.") ((&&) ((<>) x "Field OrdType of Message NewOrderSingle is missing.") ((&&) ((<>) x "Field TransactTime of Message NewOrderSingle is missing.") ((&&) ((<>) x "Field Side of Message NewOrderSingle is missing.") ((<>) x "Field ClOrdID of Message NewOrderSingle is missing.")))) + (&&) ((<>) x "Field ExecInst in Message ExecutionReport has an unrecognised tag value.") ((&&) ((<>) x "Field ExecInst in Message ExecutionReport is missing.") ((&&) ((<>) x "Field PartyIndex in Message ExecutionReport, within repeating group Parties, is missing.") ((&&) ((<>) x "Field PartyID in Message ExecutionReport, within repeating group Parties, is missing.") ((&&) ((<>) x "Field CumQty in Message ExecutionReport is missing.") ((&&) ((<>) x "Field LeavesQty in Message ExecutionReport is missing.") ((&&) ((<>) x "Field OrderQty in Message ExecutionReport is missing.") ((&&) ((<>) x "Field Side in Message ExecutionReport has an unrecognised tag value.") ((&&) ((<>) x "Field Side in Message ExecutionReport is missing.") ((&&) ((<>) x "Field OrdStatus in Message ExecutionReport has an unrecognised tag value.") ((&&) ((<>) x "Field OrdStatus in Message ExecutionReport is missing.") ((&&) ((<>) x "Field ExecType in Message ExecutionReport has an unrecognised tag value.") ((&&) ((<>) x "Field ExecType in Message ExecutionReport is missing.") ((&&) ((<>) x "Field ExecID in Message ExecutionReport is missing.") ((&&) ((<>) x "Field OrderID in Message ExecutionReport is missing.") ((&&) ((<>) x "Message NewOrderSingle violates the constraint \"\n case(this.Parties.PtysSubGrp.PartySubID)\n {None:true}\n {Some x : this.Parties.PartyID != x}\"") ((&&) ((<>) x "Message NewOrderSingle violates the constraint \"\n this.OrdType != OrdType.Market ==>\n (case this.Price\n {Some price: price > 0.0}\n {None: false}\n )\"") ((&&) ((<>) x "Message NewOrderSingle violates the constraint \"\n this.OrdType == StopSpread <==>\n present(this.SpreadProportion)\"") ((&&) ((<>) x "Message NewOrderSingle violates the constraint \"\n (this.OrdType == OrdType.Market <==> !present(this.Price)) &&\n (this.OrdType == OrdType.Limit ==> present(this.Price)) &&\n (this.OrdType == OrdType.StopSpread ==> present(this.Price))\"") ((&&) ((<>) x "Field PartyIndex in Message NewOrderSingle, within repeating group Parties, is missing.") ((&&) ((<>) x "Field PartyID in Message NewOrderSingle, within repeating group Parties, is missing.") ((&&) ((<>) x "Field Parties of Message NewOrderSingle violates the constraint: \" it.PartyID != \"N/A\"\"") ((&&) ((<>) x "Field Parties of Message NewOrderSingle violates the constraint: \" it.PartyIndex > 0 && it.PartyIndex < 100\"") ((&&) ((<>) x "Field ExecInst in Message NewOrderSingle has an unrecognised tag value.") ((&&) ((<>) x "Field SpreadProportion of Message NewOrderSingle violates the constraint: \" case(it){None:true}{Some x: x>0.0 && x<=1.0}\"") ((&&) ((<>) x "Field OrderQty in Message NewOrderSingle is missing.") ((&&) ((<>) x "Field OrdType in Message NewOrderSingle has an unrecognised tag value.") ((&&) ((<>) x "Field OrdType in Message NewOrderSingle is missing.") ((&&) ((<>) x "Field OrdType of Message NewOrderSingle violates the constraint: \" it in [ OrdType.Limit, OrdType.Market, StopSpread ]\"") ((&&) ((<>) x "Field TransactTime in Message NewOrderSingle is missing.") ((&&) ((<>) x "Field Side in Message NewOrderSingle has an unrecognised tag value.") ((&&) ((<>) x "Field Side in Message NewOrderSingle is missing.") ((<>) x "Field ClOrdID of Message NewOrderSingle violates the constraint: \" it != (Some \"N/A\")\"")))))))))))))))))))))))))))))))) [@@macro] ;; + +let exclude_string_list () = + [("N/A"); + ("Field ExecInst in Message ExecutionReport has an unrecognised tag value."); + ("Field ExecInst in Message ExecutionReport is missing."); + ("Field PartyIndex in Message ExecutionReport, within repeating group Parties, is missing."); + ("Field PartyID in Message ExecutionReport, within repeating group Parties, is missing."); + ("Field CumQty in Message ExecutionReport is missing."); + ("Field LeavesQty in Message ExecutionReport is missing."); + ("Field OrderQty in Message ExecutionReport is missing."); + ("Field Side in Message ExecutionReport has an unrecognised tag value."); + ("Field Side in Message ExecutionReport is missing."); + ("Field OrdStatus in Message ExecutionReport has an unrecognised tag value."); + ("Field OrdStatus in Message ExecutionReport is missing."); + ("Field ExecType in Message ExecutionReport has an unrecognised tag value."); + ("Field ExecType in Message ExecutionReport is missing."); + ("Field ExecID in Message ExecutionReport is missing."); + ("Field OrderID in Message ExecutionReport is missing."); + ("Message NewOrderSingle violates the constraint \"\n case(this.Parties.PtysSubGrp.PartySubID)\n {None:true}\n {Some x : this.Parties.PartyID != x}\""); + ("Message NewOrderSingle violates the constraint \"\n this.OrdType != OrdType.Market ==>\n (case this.Price\n {Some price: price > 0.0}\n {None: false}\n )\""); + ("Message NewOrderSingle violates the constraint \"\n this.OrdType == StopSpread <==>\n present(this.SpreadProportion)\""); + ("Message NewOrderSingle violates the constraint \"\n (this.OrdType == OrdType.Market <==> !present(this.Price)) &&\n (this.OrdType == OrdType.Limit ==> present(this.Price)) &&\n (this.OrdType == OrdType.StopSpread ==> present(this.Price))\""); + ("Field PartyIndex in Message NewOrderSingle, within repeating group Parties, is missing."); + ("Field PartyID in Message NewOrderSingle, within repeating group Parties, is missing."); + ("Field Parties of Message NewOrderSingle violates the constraint: \" it.PartyID != \"N/A\"\""); + ("Field Parties of Message NewOrderSingle violates the constraint: \" it.PartyIndex > 0 && it.PartyIndex < 100\""); + ("Field ExecInst in Message NewOrderSingle has an unrecognised tag value."); + ("Field SpreadProportion of Message NewOrderSingle violates the constraint: \" case(it){None:true}{Some x: x>0.0 && x<=1.0}\""); + ("Field OrderQty in Message NewOrderSingle is missing."); + ("Field OrdType in Message NewOrderSingle has an unrecognised tag value."); + ("Field OrdType in Message NewOrderSingle is missing."); + ("Field OrdType of Message NewOrderSingle violates the constraint: \" it in [ OrdType.Limit, OrdType.Market, StopSpread ]\""); + ("Field TransactTime in Message NewOrderSingle is missing."); + ("Field Side in Message NewOrderSingle has an unrecognised tag value."); + ("Field Side in Message NewOrderSingle is missing."); + ("Field ClOrdID of Message NewOrderSingle violates the constraint: \" it != (Some \"N/A\")\"")] + [@@macro] +;; + diff --git a/src-model/src/ipl_functions.iml b/src-model/src/ipl_functions.iml index 39d1ce2a..3c66061d 100644 --- a/src-model/src/ipl_functions.iml +++ b/src-model/src/ipl_functions.iml @@ -1,2 +1,18 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "../../src-core/datetime.iml"] +open Datetime;; +[@@@import "../../src-core-fresh/fresh.iml"] +open Fresh;; +[@@@import "../../src-core/numeric.iml"] +open Numeric;; +[@@@import "../../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; + + +let model_func_fresh_string' (arg_seed : string) : string = + let return_ret_var = "0" + in + incr_string arg_seed + [@@opaque] +;; diff --git a/src-model/src/ipl_loop_util_functions.iml b/src-model/src/ipl_loop_util_functions.iml index 6b4054d8..d128e96d 100644 --- a/src-model/src/ipl_loop_util_functions.iml +++ b/src-model/src/ipl_loop_util_functions.iml @@ -1,4 +1,4 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) type ('a) loop_result = { @@ -49,3 +49,4 @@ let rec loop_enum (f) (from) (acc) = (loop_enum f t new_acc)) ) ;; + diff --git a/src-model/src/msg_check_fields.iml b/src-model/src/msg_check_fields.iml index 0d6c994e..f68c92c8 100644 --- a/src-model/src/msg_check_fields.iml +++ b/src-model/src/msg_check_fields.iml @@ -1,18 +1,167 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "../../src-core/datetime.iml"] +open Datetime;; +[@@@import "ipl_rg_functions.iml"] +open Ipl_rg_functions;; +[@@@import "../src-types/model_app_enums.iml"] +open Model_app_enums;; [@@@import "../src-types/model_messages.iml"] open Model_messages;; +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; [@@@import "msg_check_types.iml"] open Msg_check_types;; +[@@@import "../../src-core/numeric.iml"] +open Numeric;; [@@@import "../src-types/state.iml"] open State;; +[@@@import "../../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; -let check_fields_ExecutionReport (msg_data : mod_executionreport_data) (m_state : model_state) = - fields_are_good - [@@macro] +let check_field_mod_f_NewOrderSingle_ClOrdID_inner0 (msg_data : mod_newordersingle_data) (local_internal_state : fix_internal_state) (local_internal_fresh_state' : fix_internal_fresh_state') = + (if ((<>) msg_data.mod_f_NewOrderSingle_ClOrdID (Some "N/A")) then + fields_good_defrej + else + (is_fields_invalid_defrej { + mod_builtin_rejectInfo_text = "Field ClOrdID of Message NewOrderSingle violates the constraint: \" it != (Some \"N/A\")\""; + mod_builtin_rejectInfo_field = Some "ClOrdID" + })) +;; + +let check_field_mod_f_NewOrderSingle_ClOrdID_outer (msg_data : mod_newordersingle_data) (local_internal_state : fix_internal_state) (local_internal_fresh_state' : fix_internal_fresh_state') = + let check_field_mod_f_NewOrderSingle_ClOrdID_inner0_result = check_field_mod_f_NewOrderSingle_ClOrdID_inner0 msg_data local_internal_state local_internal_fresh_state' + in + (if check_field_mod_f_NewOrderSingle_ClOrdID_inner0_result.field_invalid_defrej then + check_field_mod_f_NewOrderSingle_ClOrdID_inner0_result + else + fields_good_defrej) +;; + +let check_field_mod_f_NewOrderSingle_ClOrdID (msg_data : mod_newordersingle_data) (m_state : model_state) = + check_field_mod_f_NewOrderSingle_ClOrdID_outer msg_data m_state.f_internal_state m_state.f_internal_fresh_state' +;; + +let check_field_mod_f_NewOrderSingle_OrdType_inner0 (msg_data : mod_newordersingle_data) (local_internal_state : fix_internal_state) (local_internal_fresh_state' : fix_internal_fresh_state') = + (if (List.mem msg_data.mod_f_NewOrderSingle_OrdType ([(MOD_FIX_OrdType_Limit);(MOD_FIX_OrdType_Market);(MOD_FIX_OrdType_StopSpread)])) then + fields_good_defrej + else + (is_fields_invalid_defrej { + mod_builtin_rejectInfo_text = "Field OrdType of Message NewOrderSingle violates the constraint: \" it in [ OrdType.Limit, OrdType.Market, StopSpread ]\""; + mod_builtin_rejectInfo_field = Some "OrdType" + })) +;; + +let check_field_mod_f_NewOrderSingle_OrdType_outer (msg_data : mod_newordersingle_data) (local_internal_state : fix_internal_state) (local_internal_fresh_state' : fix_internal_fresh_state') = + let check_field_mod_f_NewOrderSingle_OrdType_inner0_result = check_field_mod_f_NewOrderSingle_OrdType_inner0 msg_data local_internal_state local_internal_fresh_state' + in + (if check_field_mod_f_NewOrderSingle_OrdType_inner0_result.field_invalid_defrej then + check_field_mod_f_NewOrderSingle_OrdType_inner0_result + else + fields_good_defrej) +;; + +let check_field_mod_f_NewOrderSingle_OrdType (msg_data : mod_newordersingle_data) (m_state : model_state) = + check_field_mod_f_NewOrderSingle_OrdType_outer msg_data m_state.f_internal_state m_state.f_internal_fresh_state' +;; + +let check_field_mod_f_NewOrderSingle_SpreadProportion_inner0 (msg_data : mod_newordersingle_data) (local_internal_state : fix_internal_state) (local_internal_fresh_state' : fix_internal_fresh_state') = + (if ((match msg_data.mod_f_NewOrderSingle_SpreadProportion with + | Some cap_x -> ((&&) (float_GreaterThan_6_6 cap_x (float_Create_6 (0))) (float_LessThanEqual_6_6 cap_x (float_Create_6 (1000000)))) + | None -> true + ) + ) then + fields_good_defrej + else + (is_fields_invalid_defrej { + mod_builtin_rejectInfo_text = "Field SpreadProportion of Message NewOrderSingle violates the constraint: \" case(it){None:true}{Some x: x>0.0 && x<=1.0}\""; + mod_builtin_rejectInfo_field = Some "SpreadProportion" + })) +;; + +let check_field_mod_f_NewOrderSingle_SpreadProportion_outer (msg_data : mod_newordersingle_data) (local_internal_state : fix_internal_state) (local_internal_fresh_state' : fix_internal_fresh_state') = + let check_field_mod_f_NewOrderSingle_SpreadProportion_inner0_result = check_field_mod_f_NewOrderSingle_SpreadProportion_inner0 msg_data local_internal_state local_internal_fresh_state' + in + (if check_field_mod_f_NewOrderSingle_SpreadProportion_inner0_result.field_invalid_defrej then + check_field_mod_f_NewOrderSingle_SpreadProportion_inner0_result + else + fields_good_defrej) +;; + +let check_field_mod_f_NewOrderSingle_SpreadProportion (msg_data : mod_newordersingle_data) (m_state : model_state) = + check_field_mod_f_NewOrderSingle_SpreadProportion_outer msg_data m_state.f_internal_state m_state.f_internal_fresh_state' +;; + +let check_field_mod_f_NewOrderSingle_Parties_inner0 (msg_data : mod_newordersingle_data) (local_internal_state : fix_internal_state) (local_internal_fresh_state' : fix_internal_fresh_state') = + (if (rg_forall_fun_Parties msg_data.mod_f_NewOrderSingle_Parties (fun lambda_e_Parties -> (&&) ((>) lambda_e_Parties.mod_f_Parties_PartyIndex 0) ((<) lambda_e_Parties.mod_f_Parties_PartyIndex 100) + ) true) then + fields_good_defrej + else + (is_fields_invalid_defrej { + mod_builtin_rejectInfo_text = "Field Parties of Message NewOrderSingle violates the constraint: \" it.PartyIndex > 0 && it.PartyIndex < 100\""; + mod_builtin_rejectInfo_field = Some "Parties" + })) +;; + +let check_field_mod_f_NewOrderSingle_Parties_inner1 (msg_data : mod_newordersingle_data) (local_internal_state : fix_internal_state) (local_internal_fresh_state' : fix_internal_fresh_state') = + (if (rg_forall_fun_Parties msg_data.mod_f_NewOrderSingle_Parties (fun lambda_e_Parties -> (<>) lambda_e_Parties.mod_f_Parties_PartyID "N/A" + ) true) then + fields_good_defrej + else + (is_fields_invalid_defrej { + mod_builtin_rejectInfo_text = "Field Parties of Message NewOrderSingle violates the constraint: \" it.PartyID != \"N/A\"\""; + mod_builtin_rejectInfo_field = Some "Parties" + })) +;; + +let check_field_mod_f_NewOrderSingle_Parties_outer (msg_data : mod_newordersingle_data) (local_internal_state : fix_internal_state) (local_internal_fresh_state' : fix_internal_fresh_state') = + let check_field_mod_f_NewOrderSingle_Parties_inner1_result = check_field_mod_f_NewOrderSingle_Parties_inner1 msg_data local_internal_state local_internal_fresh_state' + in + (if check_field_mod_f_NewOrderSingle_Parties_inner1_result.field_invalid_defrej then + check_field_mod_f_NewOrderSingle_Parties_inner1_result + else + let check_field_mod_f_NewOrderSingle_Parties_inner0_result = check_field_mod_f_NewOrderSingle_Parties_inner0 msg_data local_internal_state local_internal_fresh_state' + in + (if check_field_mod_f_NewOrderSingle_Parties_inner0_result.field_invalid_defrej then + check_field_mod_f_NewOrderSingle_Parties_inner0_result + else + fields_good_defrej) + ) +;; + +let check_field_mod_f_NewOrderSingle_Parties (msg_data : mod_newordersingle_data) (m_state : model_state) = + check_field_mod_f_NewOrderSingle_Parties_outer msg_data m_state.f_internal_state m_state.f_internal_fresh_state' ;; let check_fields_NewOrderSingle (msg_data : mod_newordersingle_data) (m_state : model_state) = - fields_are_good + let mod_f_NewOrderSingle_Parties_result = check_field_mod_f_NewOrderSingle_Parties msg_data m_state + in + (if mod_f_NewOrderSingle_Parties_result.field_invalid_defrej then + mod_f_NewOrderSingle_Parties_result + else + let mod_f_NewOrderSingle_SpreadProportion_result = check_field_mod_f_NewOrderSingle_SpreadProportion msg_data m_state + in + (if mod_f_NewOrderSingle_SpreadProportion_result.field_invalid_defrej then + mod_f_NewOrderSingle_SpreadProportion_result + else + let mod_f_NewOrderSingle_OrdType_result = check_field_mod_f_NewOrderSingle_OrdType msg_data m_state + in + (if mod_f_NewOrderSingle_OrdType_result.field_invalid_defrej then + mod_f_NewOrderSingle_OrdType_result + else + let mod_f_NewOrderSingle_ClOrdID_result = check_field_mod_f_NewOrderSingle_ClOrdID msg_data m_state + in + (if mod_f_NewOrderSingle_ClOrdID_result.field_invalid_defrej then + mod_f_NewOrderSingle_ClOrdID_result + else + fields_good_defrej) + ) + ) + ) +;; + +let check_fields_ExecutionReport (msg_data : mod_executionreport_data) (m_state : model_state) = + fields_good_defrej [@@macro] ;; + diff --git a/src-model/src/msg_check_types.iml b/src-model/src/msg_check_types.iml index c6939129..0b0daa78 100644 --- a/src-model/src/msg_check_types.iml +++ b/src-model/src/msg_check_types.iml @@ -1,40 +1,59 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "../../src-core/datetime.iml"] +open Datetime;; +[@@@import "../../src-core/numeric.iml"] +open Numeric;; +[@@@import "../../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; -type field_state = { - is_invalid : bool; - field_text : string +type reject_info_defrej = { + mod_builtin_rejectInfo_text : string; + mod_builtin_rejectInfo_field : string option } ;; -let fields_are_good = { - is_invalid = false; - field_text = "" +type field_state_defrej = { + field_invalid_defrej : bool; + field_reject_info_defrej : reject_info_defrej +} +;; + +let fields_good_defrej = { + field_invalid_defrej = false; + field_reject_info_defrej = { + mod_builtin_rejectInfo_text = "0"; + mod_builtin_rejectInfo_field = None + } } [@@macro];; -let field_invalid (text : string) = +let is_fields_invalid_defrej (rej_info : reject_info_defrej) = { - is_invalid = true; - field_text = text + field_invalid_defrej = true; + field_reject_info_defrej = rej_info } [@@macro] ;; -type validate_reject = { - validate_invalid : bool; - validate_text : string +type validate_reject_defrej = { + validate_invalid_defrej : bool; + validate_reject_info_defrej : reject_info_defrej } ;; -let no_invalid_validates = { - validate_invalid = false; - validate_text = "" +let no_invalid_validates_defrej = { + validate_invalid_defrej = false; + validate_reject_info_defrej = { + mod_builtin_rejectInfo_text = "0"; + mod_builtin_rejectInfo_field = None + } } [@@macro];; -let make_cond (cond_result : bool) (text : string) = +let make_cond_defrej (cond_result : bool) (rej_info : reject_info_defrej) = { - validate_invalid = not cond_result; - validate_text = text + validate_invalid_defrej = not cond_result; + validate_reject_info_defrej = rej_info } [@@macro] ;; + diff --git a/src-model/src/msg_check_validate.iml b/src-model/src/msg_check_validate.iml index 5fa816b9..32f6a0ba 100644 --- a/src-model/src/msg_check_validate.iml +++ b/src-model/src/msg_check_validate.iml @@ -1,18 +1,122 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "../../src-core/datetime.iml"] +open Datetime;; +[@@@import "ipl_rg_functions.iml"] +open Ipl_rg_functions;; +[@@@import "../src-types/model_app_enums.iml"] +open Model_app_enums;; [@@@import "../src-types/model_messages.iml"] open Model_messages;; +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; [@@@import "msg_check_types.iml"] open Msg_check_types;; +[@@@import "../../src-core/numeric.iml"] +open Numeric;; [@@@import "../src-types/state.iml"] open State;; +[@@@import "../../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; -let check_validate_ExecutionReport (msg_data : mod_executionreport_data) (m_state : model_state) = - no_invalid_validates - [@@macro] +let validate_NewOrderSingle_0 (msg_data : mod_newordersingle_data) (m_state : model_state) = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + make_cond_defrej ((&&) ((&&) ((<==>) ((=) msg_data.mod_f_NewOrderSingle_OrdType MOD_FIX_OrdType_Market) (not ((match msg_data.mod_f_NewOrderSingle_Price with + | Some _ -> true + | None -> false + ) + ))) ((==>) ((=) msg_data.mod_f_NewOrderSingle_OrdType MOD_FIX_OrdType_Limit) ((match msg_data.mod_f_NewOrderSingle_Price with + | Some _ -> true + | None -> false + ) + ))) ((==>) ((=) msg_data.mod_f_NewOrderSingle_OrdType MOD_FIX_OrdType_StopSpread) ((match msg_data.mod_f_NewOrderSingle_Price with + | Some _ -> true + | None -> false + ) + ))) { + mod_builtin_rejectInfo_text = "Message NewOrderSingle violates the constraint \"\n (this.OrdType == OrdType.Market <==> !present(this.Price)) &&\n (this.OrdType == OrdType.Limit ==> present(this.Price)) &&\n (this.OrdType == OrdType.StopSpread ==> present(this.Price))\""; + mod_builtin_rejectInfo_field = None + } +;; + +let validate_NewOrderSingle_1 (msg_data : mod_newordersingle_data) (m_state : model_state) = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + make_cond_defrej ((<==>) ((=) msg_data.mod_f_NewOrderSingle_OrdType MOD_FIX_OrdType_StopSpread) ((match msg_data.mod_f_NewOrderSingle_SpreadProportion with + | Some _ -> true + | None -> false + ) + )) { + mod_builtin_rejectInfo_text = "Message NewOrderSingle violates the constraint \"\n this.OrdType == StopSpread <==>\n present(this.SpreadProportion)\""; + mod_builtin_rejectInfo_field = None + } +;; + +let validate_NewOrderSingle_2 (msg_data : mod_newordersingle_data) (m_state : model_state) = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + make_cond_defrej ((==>) ((<>) msg_data.mod_f_NewOrderSingle_OrdType MOD_FIX_OrdType_Market) ((match msg_data.mod_f_NewOrderSingle_Price with + | Some cap_price -> (float_GreaterThan_2_6 cap_price (float_Create_6 (0))) + | None -> false + ) + )) { + mod_builtin_rejectInfo_text = "Message NewOrderSingle violates the constraint \"\n this.OrdType != OrdType.Market ==>\n (case this.Price\n {Some price: price > 0.0}\n {None: false}\n )\""; + mod_builtin_rejectInfo_field = None + } +;; + +let validate_NewOrderSingle_3 (msg_data : mod_newordersingle_data) (m_state : model_state) = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + make_cond_defrej (rg_forall_fun_Parties msg_data.mod_f_NewOrderSingle_Parties (fun lambda_e_Parties -> rg_forall_fun_PtysSubGrp lambda_e_Parties.mod_f_Parties_PtysSubGrp (fun lambda_e_PtysSubGrp -> (match lambda_e_PtysSubGrp.mod_f_PtysSubGrp_PartySubID with + | Some cap_x -> ((<>) lambda_e_Parties.mod_f_Parties_PartyID cap_x) + | None -> true + ) + ) true + ) true) { + mod_builtin_rejectInfo_text = "Message NewOrderSingle violates the constraint \"\n case(this.Parties.PtysSubGrp.PartySubID)\n {None:true}\n {Some x : this.Parties.PartyID != x}\""; + mod_builtin_rejectInfo_field = None + } ;; let check_validate_NewOrderSingle (msg_data : mod_newordersingle_data) (m_state : model_state) = - no_invalid_validates + let cust_rest3 = validate_NewOrderSingle_3 msg_data m_state + in + (if cust_rest3.validate_invalid_defrej then + cust_rest3 + else + let cust_rest2 = validate_NewOrderSingle_2 msg_data m_state + in + (if cust_rest2.validate_invalid_defrej then + cust_rest2 + else + let cust_rest1 = validate_NewOrderSingle_1 msg_data m_state + in + (if cust_rest1.validate_invalid_defrej then + cust_rest1 + else + let cust_rest0 = validate_NewOrderSingle_0 msg_data m_state + in + (if cust_rest0.validate_invalid_defrej then + cust_rest0 + else + no_invalid_validates_defrej) + ) + ) + ) +;; + +let check_validate_ExecutionReport (msg_data : mod_executionreport_data) (m_state : model_state) = + no_invalid_validates_defrej [@@macro] ;; + diff --git a/src-model/src/msg_defaults.iml b/src-model/src/msg_defaults.iml index c2a36c4f..a96050a0 100644 --- a/src-model/src/msg_defaults.iml +++ b/src-model/src/msg_defaults.iml @@ -1,16 +1,23 @@ -(* Imandra Inc. copyright 2020 *) -[@@@import "../src-types/model_messages.iml"] -open Model_messages;; -[@@@import "../src-types/state.iml"] -open State;; +(* Imandra Inc. copyright 2021 *) +[@@@import "../src-types/model_app_enums.iml"] +open Model_app_enums;; -let assign_defaults_ExecutionReport (msg_data : mod_executionreport_data) (m_state : model_state) = - msg_data +let model_func_default_ExecInst_NewOrderSingle (() : unit) : model_fix_execinst Set.t = + let return_ret_var = Map.const false + in + let return_loop_return_flag = false + in + let (return_ret_var,return_loop_return_flag) = ((let local_set_var:model_fix_execinst Set.t = Map.const false + in + let local_set_var = Map.add MOD_FIX_ExecInst_AllOrNone true local_set_var + in + let local_set_var = Map.add MOD_FIX_ExecInst_Held true local_set_var + in + local_set_var + ),true) + in + return_ret_var [@@macro] ;; -let assign_defaults_NewOrderSingle (msg_data : mod_newordersingle_data) (m_state : model_state) = - msg_data - [@@macro] -;; diff --git a/src-model/src/msg_process.iml b/src-model/src/msg_process.iml index bed33ed5..ea8d8468 100644 --- a/src-model/src/msg_process.iml +++ b/src-model/src/msg_process.iml @@ -1,4 +1,6 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "../src-helper-functions/ambiguous_default_funcs.iml"] +open Ambiguous_default_funcs;; [@@@import "../src-types/model_messages.iml"] open Model_messages;; [@@@import "msg_check_fields.iml"] @@ -17,26 +19,116 @@ open Msg_reject;; open State;; -let process_NewOrderSingle (m_state : model_state) (msg_data : mod_newordersingle_data) = - let msg_data = assign_defaults_NewOrderSingle msg_data m_state +let inner_convert_NewOrderSingle (m_state : model_state) (msg_data : mod_newordersingle_defopt_data) : mod_newordersingle_data = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + let c_mod_f_NewOrderSingle_Parties = msg_data.mod_def_opt_f_NewOrderSingle_Parties + in + let c_mod_f_NewOrderSingle_Account = msg_data.mod_def_opt_f_NewOrderSingle_Account + in + let c_mod_f_NewOrderSingle_Price = msg_data.mod_def_opt_f_NewOrderSingle_Price + in + let c_mod_f_NewOrderSingle_SpreadProportion = msg_data.mod_def_opt_f_NewOrderSingle_SpreadProportion + in + let c_mod_f_NewOrderSingle_OrderQtyData_OrderQty = msg_data.mod_def_opt_f_NewOrderSingle_OrderQtyData_OrderQty + in + let c_mod_f_NewOrderSingle_OrdType = msg_data.mod_def_opt_f_NewOrderSingle_OrdType + in + let c_mod_f_NewOrderSingle_TransactTime = msg_data.mod_def_opt_f_NewOrderSingle_TransactTime + in + let c_mod_f_NewOrderSingle_Side = msg_data.mod_def_opt_f_NewOrderSingle_Side + in + let c_mod_f_NewOrderSingle_ClOrdID = msg_data.mod_def_opt_f_NewOrderSingle_ClOrdID + in + let c_mod_f_NewOrderSingle_ExecInst = let y = model_func_default_ExecInst_NewOrderSingle () + in + amb_func_execinst_set y msg_data.mod_def_opt_f_NewOrderSingle_ExecInst + in + { + mod_f_NewOrderSingle_ClOrdID = c_mod_f_NewOrderSingle_ClOrdID; + mod_f_NewOrderSingle_Side = c_mod_f_NewOrderSingle_Side; + mod_f_NewOrderSingle_TransactTime = c_mod_f_NewOrderSingle_TransactTime; + mod_f_NewOrderSingle_OrdType = c_mod_f_NewOrderSingle_OrdType; + mod_f_NewOrderSingle_OrderQtyData_OrderQty = c_mod_f_NewOrderSingle_OrderQtyData_OrderQty; + mod_f_NewOrderSingle_SpreadProportion = c_mod_f_NewOrderSingle_SpreadProportion; + mod_f_NewOrderSingle_Price = c_mod_f_NewOrderSingle_Price; + mod_f_NewOrderSingle_Account = c_mod_f_NewOrderSingle_Account; + mod_f_NewOrderSingle_ExecInst = c_mod_f_NewOrderSingle_ExecInst; + mod_f_NewOrderSingle_Parties = c_mod_f_NewOrderSingle_Parties + } + [@@macro] +;; + +let inner_convert_ExecutionReport (m_state : model_state) (msg_data : mod_executionreport_defopt_data) : mod_executionreport_data = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' in + let local_internal_state = m_state.f_internal_state + in + let c_mod_f_ExecutionReport_ExecInst = msg_data.mod_def_opt_f_ExecutionReport_ExecInst + in + let c_mod_f_ExecutionReport_Parties = msg_data.mod_def_opt_f_ExecutionReport_Parties + in + let c_mod_f_ExecutionReport_Text = msg_data.mod_def_opt_f_ExecutionReport_Text + in + let c_mod_f_ExecutionReport_CumQty = msg_data.mod_def_opt_f_ExecutionReport_CumQty + in + let c_mod_f_ExecutionReport_LeavesQty = msg_data.mod_def_opt_f_ExecutionReport_LeavesQty + in + let c_mod_f_ExecutionReport_OrderQtyData_OrderQty = msg_data.mod_def_opt_f_ExecutionReport_OrderQtyData_OrderQty + in + let c_mod_f_ExecutionReport_Side = msg_data.mod_def_opt_f_ExecutionReport_Side + in + let c_mod_f_ExecutionReport_OrdStatus = msg_data.mod_def_opt_f_ExecutionReport_OrdStatus + in + let c_mod_f_ExecutionReport_ExecType = msg_data.mod_def_opt_f_ExecutionReport_ExecType + in + let c_mod_f_ExecutionReport_ExecID = msg_data.mod_def_opt_f_ExecutionReport_ExecID + in + let c_mod_f_ExecutionReport_OrderID = msg_data.mod_def_opt_f_ExecutionReport_OrderID + in + { + mod_f_ExecutionReport_OrderID = c_mod_f_ExecutionReport_OrderID; + mod_f_ExecutionReport_ExecID = c_mod_f_ExecutionReport_ExecID; + mod_f_ExecutionReport_ExecType = c_mod_f_ExecutionReport_ExecType; + mod_f_ExecutionReport_OrdStatus = c_mod_f_ExecutionReport_OrdStatus; + mod_f_ExecutionReport_Side = c_mod_f_ExecutionReport_Side; + mod_f_ExecutionReport_OrderQtyData_OrderQty = c_mod_f_ExecutionReport_OrderQtyData_OrderQty; + mod_f_ExecutionReport_LeavesQty = c_mod_f_ExecutionReport_LeavesQty; + mod_f_ExecutionReport_CumQty = c_mod_f_ExecutionReport_CumQty; + mod_f_ExecutionReport_Text = c_mod_f_ExecutionReport_Text; + mod_f_ExecutionReport_Parties = c_mod_f_ExecutionReport_Parties; + mod_f_ExecutionReport_ExecInst = c_mod_f_ExecutionReport_ExecInst + } + [@@macro] +;; + +let convert_inner (m_state : model_state) (msg : model_msg_opt_def) : model_msg = + (match msg with + | FIX_Msg_Def_Opt_NewOrderSingle msg_data -> (FIX_Msg_NewOrderSingle (inner_convert_NewOrderSingle m_state msg_data)) + | FIX_Msg_Def_Opt_ExecutionReport msg_data -> (FIX_Msg_ExecutionReport (inner_convert_ExecutionReport m_state msg_data)) + ) +;; + +let process_NewOrderSingle (m_state : model_state) (msg_data : mod_newordersingle_data) = let field_check = check_fields_NewOrderSingle msg_data m_state in - (if field_check.is_invalid then - { (reject_NewOrderSingle_invalidfield m_state msg_data field_check.field_text) with + (if field_check.field_invalid_defrej then + { (reject_NewOrderSingle_invalidfield m_state msg_data field_check.field_reject_info_defrej) with event_info = { state_event_counter = m_state.event_counter; - state_event_reject_text = Some field_check.field_text + state_event_reject_text = Some field_check.field_reject_info_defrej.mod_builtin_rejectInfo_text } :: m_state.event_info } else let custom_reject = check_validate_NewOrderSingle msg_data m_state in - (if custom_reject.validate_invalid then - { (reject_NewOrderSingle_invalid m_state msg_data custom_reject.validate_text) with + (if custom_reject.validate_invalid_defrej then + { (reject_NewOrderSingle_invalid m_state msg_data custom_reject.validate_reject_info_defrej) with event_info = { state_event_counter = m_state.event_counter; - state_event_reject_text = Some custom_reject.validate_text + state_event_reject_text = Some custom_reject.validate_reject_info_defrej.mod_builtin_rejectInfo_text } :: m_state.event_info } else @@ -44,40 +136,73 @@ let process_NewOrderSingle (m_state : model_state) (msg_data : mod_newordersingl ) ;; +let process_ExecutionReport (m_state : model_state) (msg_data : mod_executionreport_data) = + let field_check = check_fields_ExecutionReport msg_data m_state + in + (if field_check.field_invalid_defrej then + { (reject_ExecutionReport_invalidfield m_state msg_data field_check.field_reject_info_defrej) with + event_info = { + state_event_counter = m_state.event_counter; + state_event_reject_text = Some field_check.field_reject_info_defrej.mod_builtin_rejectInfo_text + } :: m_state.event_info + } + else + let custom_reject = check_validate_ExecutionReport msg_data m_state + in + (if custom_reject.validate_invalid_defrej then + { (reject_ExecutionReport_invalid m_state msg_data custom_reject.validate_reject_info_defrej) with + event_info = { + state_event_counter = m_state.event_counter; + state_event_reject_text = Some custom_reject.validate_reject_info_defrej.mod_builtin_rejectInfo_text + } :: m_state.event_info + } + else + (receive_message_ExecutionReport m_state msg_data)) + ) +;; + let process_msg (m_state : model_state) (msg : model_top_level_msg) = (match msg with | FIX_TL_Req_Field_Missing d -> (reject_field_missing m_state d) + | FIX_TL_Req_Field_Invalid d -> (reject_field_enum_invalid m_state d) | FIX_TL_Normal d -> ((match d with - | FIX_Msg_NewOrderSingle m_data -> (process_NewOrderSingle m_state m_data) + | FIX_Msg_Def_Opt_NewOrderSingle m_data -> let m_data = inner_convert_NewOrderSingle m_state m_data + in + process_NewOrderSingle m_state m_data + | FIX_Msg_Def_Opt_ExecutionReport m_data -> let m_data = inner_convert_ExecutionReport m_state m_data + in + process_ExecutionReport m_state m_data | _ -> m_state ) ) - | FIX_TL_PossibleResend d -> m_state + | FIX_TL_PossibleResend _ -> m_state | FIX_TL_None -> m_state ) ;; -let msg_ExecutionReport_valid (msg_data : mod_executionreport_data) (m_state : model_state) = - let fields_result = check_fields_ExecutionReport msg_data m_state +let msg_NewOrderSingle_valid (msg_data : mod_newordersingle_data) (m_state : model_state) = + let fields_result = check_fields_NewOrderSingle msg_data m_state in - let validate_result = check_validate_ExecutionReport msg_data m_state + let validate_result = check_validate_NewOrderSingle msg_data m_state in - (&&) (not fields_result.is_invalid) (not validate_result.validate_invalid) + (&&) (not fields_result.field_invalid_defrej) (not validate_result.validate_invalid_defrej) [@@macro] ;; -let msg_NewOrderSingle_valid (msg_data : mod_newordersingle_data) (m_state : model_state) = - let fields_result = check_fields_NewOrderSingle msg_data m_state +let msg_ExecutionReport_valid (msg_data : mod_executionreport_data) (m_state : model_state) = + let fields_result = check_fields_ExecutionReport msg_data m_state in - let validate_result = check_validate_NewOrderSingle msg_data m_state + let validate_result = check_validate_ExecutionReport msg_data m_state in - (&&) (not fields_result.is_invalid) (not validate_result.validate_invalid) + (&&) (not fields_result.field_invalid_defrej) (not validate_result.validate_invalid_defrej) [@@macro] ;; let is_message_valid (msg : model_msg) (m_state : model_state) = (match msg with | FIX_Msg_NewOrderSingle d -> (msg_NewOrderSingle_valid d m_state) + | FIX_Msg_ExecutionReport d -> (msg_ExecutionReport_valid d m_state) | _ -> true ) ;; + diff --git a/src-model/src/msg_receive.iml b/src-model/src/msg_receive.iml index 63ceea90..9c18445a 100644 --- a/src-model/src/msg_receive.iml +++ b/src-model/src/msg_receive.iml @@ -1,4 +1,8 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "../../src-core/datetime.iml"] +open Datetime;; +[@@@import "ipl_functions.iml"] +open Ipl_functions;; [@@@import "../src-types/model_app_enums.iml"] open Model_app_enums;; [@@@import "../src-types/model_messages.iml"] @@ -7,25 +11,96 @@ open Model_messages;; open Numeric;; [@@@import "../src-types/state.iml"] open State;; +[@@@import "../../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; let receive_message_NewOrderSingle (m_state : model_state) (msg_data : mod_newordersingle_data) = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + let local_internal_state = { local_internal_state with + mod_f_internal_state_live_order = true; + mod_f_internal_state_LeavesQty = msg_data.mod_f_NewOrderSingle_OrderQtyData_OrderQty + } + in + let local_internal_fresh_state' = { local_internal_fresh_state' with + mod_f_internal_fresh_state'_seed_string = model_func_fresh_string' local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + } + in + let local_1fresh = local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + in + let local_internal_state = { local_internal_state with + mod_f_internal_state_OrderID = local_1fresh; + mod_f_internal_state_ExecType = MOD_FIX_ExecType_New; + mod_f_internal_state_ExecInst = msg_data.mod_f_NewOrderSingle_ExecInst; + mod_f_internal_state_OrdType = msg_data.mod_f_NewOrderSingle_OrdType; + mod_f_internal_state_OrderQtyData_OrderQty = msg_data.mod_f_NewOrderSingle_OrderQtyData_OrderQty; + mod_f_internal_state_Parties = msg_data.mod_f_NewOrderSingle_Parties; + mod_f_internal_state_Price = msg_data.mod_f_NewOrderSingle_Price; + mod_f_internal_state_Side = msg_data.mod_f_NewOrderSingle_Side; + mod_f_internal_state_SpreadProportion = msg_data.mod_f_NewOrderSingle_SpreadProportion + } + in + let (local_internal_state) = (if ((=) msg_data.mod_f_NewOrderSingle_OrdType MOD_FIX_OrdType_StopSpread) then + let (local_internal_state) = (match msg_data.mod_f_NewOrderSingle_SpreadProportion with + | Some cap_x -> let (local_internal_state) = (if (not (float_Equal_2_6 local_internal_state.mod_f_internal_state_bestAsk (float_Create_6 (0)))) then + let (local_internal_state) = (if (float_GreaterThanEqual_6_2 cap_x (float_Div_2_2 (float_Sub_2_2 local_internal_state.mod_f_internal_state_bestAsk local_internal_state.mod_f_internal_state_bestBid) local_internal_state.mod_f_internal_state_bestAsk)) then + let local_internal_state = { local_internal_state with + mod_f_internal_state_OrdStatus = MOD_FIX_OrdStatus_New + } + in + let local_internal_state = { local_internal_state with + mod_f_internal_state_ExecType = MOD_FIX_ExecType_New + } + in + (local_internal_state) + else + (local_internal_state)) + in + (local_internal_state) + else + (local_internal_state)) + in + (local_internal_state) + | None -> (local_internal_state) + ) + in + (local_internal_state) + else + (local_internal_state)) + in + let local_internal_fresh_state' = { local_internal_fresh_state' with + mod_f_internal_fresh_state'_seed_string = model_func_fresh_string' local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + } + in + let local_2fresh = local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + in let msg_data_inner = { - mod_f_ExecutionReport_AvgPx = float_Create_6 0; - mod_f_ExecutionReport_ClOrdID = msg_data.mod_f_NewOrderSingle_ClOrdID; - mod_f_ExecutionReport_CumQty = float_Create_6 0; - mod_f_ExecutionReport_ExecID = "Test"; - mod_f_ExecutionReport_ExecType = MOD_FIX_ExecType_Calculated; - mod_f_ExecutionReport_Instrument_Symbol = msg_data.mod_f_NewOrderSingle_Instrument_Symbol; - mod_f_ExecutionReport_LeavesQty = float_Create_6 0; - mod_f_ExecutionReport_OrdStatus = MOD_FIX_OrdStatus_New; - mod_f_ExecutionReport_OrderID = msg_data.mod_f_NewOrderSingle_ClOrdID; - mod_f_ExecutionReport_Side = msg_data.mod_f_NewOrderSingle_Side; + mod_f_ExecutionReport_CumQty = local_internal_state.mod_f_internal_state_CumQty; + mod_f_ExecutionReport_ExecID = local_2fresh; + mod_f_ExecutionReport_ExecInst = local_internal_state.mod_f_internal_state_ExecInst; + mod_f_ExecutionReport_ExecType = local_internal_state.mod_f_internal_state_ExecType; + mod_f_ExecutionReport_LeavesQty = local_internal_state.mod_f_internal_state_LeavesQty; + mod_f_ExecutionReport_OrdStatus = local_internal_state.mod_f_internal_state_OrdStatus; + mod_f_ExecutionReport_OrderID = local_internal_state.mod_f_internal_state_OrderID; + mod_f_ExecutionReport_OrderQtyData_OrderQty = local_internal_state.mod_f_internal_state_OrderQtyData_OrderQty; + mod_f_ExecutionReport_Parties = local_internal_state.mod_f_internal_state_Parties; + mod_f_ExecutionReport_Side = local_internal_state.mod_f_internal_state_Side; mod_f_ExecutionReport_Text = None } in let m_state = send_msg (FIX_Msg_ExecutionReport msg_data_inner) m_state in + { m_state with + f_internal_state = local_internal_state; + f_internal_fresh_state' = local_internal_fresh_state' + } +;; + +let receive_message_ExecutionReport (m_state : model_state) (msg_data : mod_executionreport_data) = m_state [@@macro] ;; + diff --git a/src-model/src/msg_reject.iml b/src-model/src/msg_reject.iml index 26239f12..65ab315b 100644 --- a/src-model/src/msg_reject.iml +++ b/src-model/src/msg_reject.iml @@ -1,111 +1,237 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "ipl_functions.iml"] +open Ipl_functions;; [@@@import "../src-types/model_app_enums.iml"] open Model_app_enums;; [@@@import "../src-types/model_messages.iml"] open Model_messages;; +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; [@@@import "../src-types/model_tags.iml"] open Model_tags;; -[@@@import "../../src-core/numeric.iml"] -open Numeric;; +[@@@import "msg_check_types.iml"] +open Msg_check_types;; [@@@import "../src-types/state.iml"] open State;; -let reject_NewOrderSingle_missingfield (m_state : model_state) (reject_text : string) = +let reject_NewOrderSingle_missingfield (m_state : model_state) (rej_info : reject_info_defrej) = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + let local_internal_state = { local_internal_state with + mod_f_internal_state_ExecType = MOD_FIX_ExecType_Rejected; + mod_f_internal_state_OrdStatus = MOD_FIX_OrdStatus_Rejected + } + in + let local_internal_fresh_state' = { local_internal_fresh_state' with + mod_f_internal_fresh_state'_seed_string = model_func_fresh_string' local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + } + in + let local_3fresh = local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + in let msg_data_inner = { - mod_f_ExecutionReport_AvgPx = float_Create_6 0; - mod_f_ExecutionReport_ClOrdID = "None"; - mod_f_ExecutionReport_CumQty = float_Create_6 0; - mod_f_ExecutionReport_ExecID = "Test"; - mod_f_ExecutionReport_ExecType = MOD_FIX_ExecType_Calculated; - mod_f_ExecutionReport_Instrument_Symbol = "None"; - mod_f_ExecutionReport_LeavesQty = float_Create_6 0; - mod_f_ExecutionReport_OrdStatus = MOD_FIX_OrdStatus_New; - mod_f_ExecutionReport_OrderID = "None"; - mod_f_ExecutionReport_Side = MOD_FIX_Side_Buy; - mod_f_ExecutionReport_Text = Some reject_text + mod_f_ExecutionReport_CumQty = local_internal_state.mod_f_internal_state_CumQty; + mod_f_ExecutionReport_ExecID = local_3fresh; + mod_f_ExecutionReport_ExecInst = local_internal_state.mod_f_internal_state_ExecInst; + mod_f_ExecutionReport_ExecType = local_internal_state.mod_f_internal_state_ExecType; + mod_f_ExecutionReport_LeavesQty = local_internal_state.mod_f_internal_state_LeavesQty; + mod_f_ExecutionReport_OrdStatus = local_internal_state.mod_f_internal_state_OrdStatus; + mod_f_ExecutionReport_OrderID = local_internal_state.mod_f_internal_state_OrderID; + mod_f_ExecutionReport_OrderQtyData_OrderQty = local_internal_state.mod_f_internal_state_OrderQtyData_OrderQty; + mod_f_ExecutionReport_Parties = local_internal_state.mod_f_internal_state_Parties; + mod_f_ExecutionReport_Side = local_internal_state.mod_f_internal_state_Side; + mod_f_ExecutionReport_Text = Some rej_info.mod_builtin_rejectInfo_text } in let m_state = send_msg (FIX_Msg_ExecutionReport msg_data_inner) m_state in - m_state + { m_state with + f_internal_state = local_internal_state; + f_internal_fresh_state' = local_internal_fresh_state' + } [@@macro] ;; -let reject_NewOrderSingle_invalidfield (m_state : model_state) (msg_data : mod_newordersingle_data) (reject_text : string) = +let reject_NewOrderSingle_invalidfield (m_state : model_state) (msg_data : mod_newordersingle_data) (rej_info : reject_info_defrej) = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + let local_internal_state = { local_internal_state with + mod_f_internal_state_ExecType = MOD_FIX_ExecType_Rejected; + mod_f_internal_state_OrdStatus = MOD_FIX_OrdStatus_Rejected + } + in + let local_internal_fresh_state' = { local_internal_fresh_state' with + mod_f_internal_fresh_state'_seed_string = model_func_fresh_string' local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + } + in + let local_4fresh = local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + in let msg_data_inner = { - mod_f_ExecutionReport_AvgPx = float_Create_6 0; - mod_f_ExecutionReport_ClOrdID = msg_data.mod_f_NewOrderSingle_ClOrdID; - mod_f_ExecutionReport_CumQty = float_Create_6 0; - mod_f_ExecutionReport_ExecID = "Test"; - mod_f_ExecutionReport_ExecType = MOD_FIX_ExecType_Calculated; - mod_f_ExecutionReport_Instrument_Symbol = msg_data.mod_f_NewOrderSingle_Instrument_Symbol; - mod_f_ExecutionReport_LeavesQty = float_Create_6 0; - mod_f_ExecutionReport_OrdStatus = MOD_FIX_OrdStatus_New; - mod_f_ExecutionReport_OrderID = msg_data.mod_f_NewOrderSingle_ClOrdID; - mod_f_ExecutionReport_Side = MOD_FIX_Side_Buy; - mod_f_ExecutionReport_Text = Some reject_text + mod_f_ExecutionReport_CumQty = local_internal_state.mod_f_internal_state_CumQty; + mod_f_ExecutionReport_ExecID = local_4fresh; + mod_f_ExecutionReport_ExecInst = local_internal_state.mod_f_internal_state_ExecInst; + mod_f_ExecutionReport_ExecType = local_internal_state.mod_f_internal_state_ExecType; + mod_f_ExecutionReport_LeavesQty = local_internal_state.mod_f_internal_state_LeavesQty; + mod_f_ExecutionReport_OrdStatus = local_internal_state.mod_f_internal_state_OrdStatus; + mod_f_ExecutionReport_OrderID = local_internal_state.mod_f_internal_state_OrderID; + mod_f_ExecutionReport_OrderQtyData_OrderQty = local_internal_state.mod_f_internal_state_OrderQtyData_OrderQty; + mod_f_ExecutionReport_Parties = local_internal_state.mod_f_internal_state_Parties; + mod_f_ExecutionReport_Side = local_internal_state.mod_f_internal_state_Side; + mod_f_ExecutionReport_Text = Some rej_info.mod_builtin_rejectInfo_text } in let m_state = send_msg (FIX_Msg_ExecutionReport msg_data_inner) m_state in - m_state + { m_state with + f_internal_state = local_internal_state; + f_internal_fresh_state' = local_internal_fresh_state' + } [@@macro] ;; -let reject_NewOrderSingle_invalid (m_state : model_state) (msg_data : mod_newordersingle_data) (reject_text : string) = +let reject_NewOrderSingle_invalid (m_state : model_state) (msg_data : mod_newordersingle_data) (rej_info : reject_info_defrej) = + let local_internal_fresh_state' = m_state.f_internal_fresh_state' + in + let local_internal_state = m_state.f_internal_state + in + let local_internal_state = { local_internal_state with + mod_f_internal_state_ExecType = MOD_FIX_ExecType_Rejected; + mod_f_internal_state_OrdStatus = MOD_FIX_OrdStatus_Rejected + } + in + let local_internal_fresh_state' = { local_internal_fresh_state' with + mod_f_internal_fresh_state'_seed_string = model_func_fresh_string' local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + } + in + let local_4fresh = local_internal_fresh_state'.mod_f_internal_fresh_state'_seed_string + in let msg_data_inner = { - mod_f_ExecutionReport_AvgPx = float_Create_6 0; - mod_f_ExecutionReport_ClOrdID = msg_data.mod_f_NewOrderSingle_ClOrdID; - mod_f_ExecutionReport_CumQty = float_Create_6 0; - mod_f_ExecutionReport_ExecID = "Test"; - mod_f_ExecutionReport_ExecType = MOD_FIX_ExecType_Calculated; - mod_f_ExecutionReport_Instrument_Symbol = "None"; - mod_f_ExecutionReport_LeavesQty = float_Create_6 0; - mod_f_ExecutionReport_OrdStatus = MOD_FIX_OrdStatus_New; - mod_f_ExecutionReport_OrderID = msg_data.mod_f_NewOrderSingle_ClOrdID; - mod_f_ExecutionReport_Side = MOD_FIX_Side_Buy; - mod_f_ExecutionReport_Text = Some reject_text + mod_f_ExecutionReport_CumQty = local_internal_state.mod_f_internal_state_CumQty; + mod_f_ExecutionReport_ExecID = local_4fresh; + mod_f_ExecutionReport_ExecInst = local_internal_state.mod_f_internal_state_ExecInst; + mod_f_ExecutionReport_ExecType = local_internal_state.mod_f_internal_state_ExecType; + mod_f_ExecutionReport_LeavesQty = local_internal_state.mod_f_internal_state_LeavesQty; + mod_f_ExecutionReport_OrdStatus = local_internal_state.mod_f_internal_state_OrdStatus; + mod_f_ExecutionReport_OrderID = local_internal_state.mod_f_internal_state_OrderID; + mod_f_ExecutionReport_OrderQtyData_OrderQty = local_internal_state.mod_f_internal_state_OrderQtyData_OrderQty; + mod_f_ExecutionReport_Parties = local_internal_state.mod_f_internal_state_Parties; + mod_f_ExecutionReport_Side = local_internal_state.mod_f_internal_state_Side; + mod_f_ExecutionReport_Text = Some rej_info.mod_builtin_rejectInfo_text } in let m_state = send_msg (FIX_Msg_ExecutionReport msg_data_inner) m_state in + { m_state with + f_internal_state = local_internal_state; + f_internal_fresh_state' = local_internal_fresh_state' + } + [@@macro] +;; + +let reject_ExecutionReport_invalidfield (m_state : model_state) (msg_data : mod_executionreport_data) (rej_info : reject_info_defrej) = m_state [@@macro] ;; -let reject_field_missing (m_state : model_state) (missing_info : field_missing_data) = - (match (missing_info.field_missing_data_msg,missing_info.field_missing_data_field) with - | (M_Msg_NewOrderSingle_Tag,M_Field_ClOrdID_Tag) -> { (reject_NewOrderSingle_missingfield m_state "Field ClOrdID of Message NewOrderSingle is missing.") with +let reject_ExecutionReport_invalid (m_state : model_state) (msg_data : mod_executionreport_data) (rej_info : reject_info_defrej) = + m_state + [@@macro] +;; + +let reject_field_missing (m_state : model_state) (missing_info : field_missing_or_invalid_data) = + (match (missing_info.field_missing_of_invalid_data_msg,missing_info.field_missing_or_invalid_data_field,missing_info.repeating_group_origin) with + | (M_Msg_NewOrderSingle_Tag,M_Field_Side_Tag,None) -> { (reject_NewOrderSingle_missingfield m_state { + mod_builtin_rejectInfo_text = "Field Side in Message NewOrderSingle is missing."; + mod_builtin_rejectInfo_field = Some "Side" + }) with + event_info = { + state_event_counter = m_state.event_counter; + state_event_reject_text = Some "Field Side in Message NewOrderSingle is missing." + } :: m_state.event_info + } + | (M_Msg_NewOrderSingle_Tag,M_Field_TransactTime_Tag,None) -> { (reject_NewOrderSingle_missingfield m_state { + mod_builtin_rejectInfo_text = "Field TransactTime in Message NewOrderSingle is missing."; + mod_builtin_rejectInfo_field = Some "TransactTime" + }) with + event_info = { + state_event_counter = m_state.event_counter; + state_event_reject_text = Some "Field TransactTime in Message NewOrderSingle is missing." + } :: m_state.event_info + } + | (M_Msg_NewOrderSingle_Tag,M_Field_OrdType_Tag,None) -> { (reject_NewOrderSingle_missingfield m_state { + mod_builtin_rejectInfo_text = "Field OrdType in Message NewOrderSingle is missing."; + mod_builtin_rejectInfo_field = Some "OrdType" + }) with event_info = { state_event_counter = m_state.event_counter; - state_event_reject_text = Some "Field ClOrdID of Message NewOrderSingle is missing." + state_event_reject_text = Some "Field OrdType in Message NewOrderSingle is missing." } :: m_state.event_info } - | (M_Msg_NewOrderSingle_Tag,M_Field_Side_Tag) -> { (reject_NewOrderSingle_missingfield m_state "Field Side of Message NewOrderSingle is missing.") with + | (M_Msg_NewOrderSingle_Tag,M_Field_OrderQty_Tag,None) -> { (reject_NewOrderSingle_missingfield m_state { + mod_builtin_rejectInfo_text = "Field OrderQty in Message NewOrderSingle is missing."; + mod_builtin_rejectInfo_field = Some "OrderQty" + }) with event_info = { state_event_counter = m_state.event_counter; - state_event_reject_text = Some "Field Side of Message NewOrderSingle is missing." + state_event_reject_text = Some "Field OrderQty in Message NewOrderSingle is missing." } :: m_state.event_info } - | (M_Msg_NewOrderSingle_Tag,M_Field_TransactTime_Tag) -> { (reject_NewOrderSingle_missingfield m_state "Field TransactTime of Message NewOrderSingle is missing.") with + | (M_Msg_NewOrderSingle_Tag,M_Field_PartyID_Tag,Some MOD_FIX_Repeating_Group_Parties) -> { (reject_NewOrderSingle_missingfield m_state { + mod_builtin_rejectInfo_text = "Field PartyID in Message NewOrderSingle, within repeating group Parties, is missing."; + mod_builtin_rejectInfo_field = Some "PartyID" + }) with event_info = { state_event_counter = m_state.event_counter; - state_event_reject_text = Some "Field TransactTime of Message NewOrderSingle is missing." + state_event_reject_text = Some "Field PartyID in Message NewOrderSingle, within repeating group Parties, is missing." } :: m_state.event_info } - | (M_Msg_NewOrderSingle_Tag,M_Field_OrdType_Tag) -> { (reject_NewOrderSingle_missingfield m_state "Field OrdType of Message NewOrderSingle is missing.") with + | (M_Msg_NewOrderSingle_Tag,M_Field_PartyIndex_Tag,Some MOD_FIX_Repeating_Group_Parties) -> { (reject_NewOrderSingle_missingfield m_state { + mod_builtin_rejectInfo_text = "Field PartyIndex in Message NewOrderSingle, within repeating group Parties, is missing."; + mod_builtin_rejectInfo_field = Some "PartyIndex" + }) with event_info = { state_event_counter = m_state.event_counter; - state_event_reject_text = Some "Field OrdType of Message NewOrderSingle is missing." + state_event_reject_text = Some "Field PartyIndex in Message NewOrderSingle, within repeating group Parties, is missing." } :: m_state.event_info } - | (M_Msg_NewOrderSingle_Tag,M_Field_Symbol_Tag) -> { (reject_NewOrderSingle_missingfield m_state "Field Symbol of Message NewOrderSingle is missing.") with + | (_,_,_) -> m_state + ) +;; + +let reject_field_enum_invalid (m_state : model_state) (missing_info : field_missing_or_invalid_data) = + (match (missing_info.field_missing_of_invalid_data_msg,missing_info.field_missing_or_invalid_data_field,missing_info.repeating_group_origin) with + | (M_Msg_NewOrderSingle_Tag,M_Field_Side_Tag,None) -> { (reject_NewOrderSingle_missingfield m_state { + mod_builtin_rejectInfo_text = "Field Side in Message NewOrderSingle has an unrecognised tag value."; + mod_builtin_rejectInfo_field = Some "Side" + }) with event_info = { state_event_counter = m_state.event_counter; - state_event_reject_text = Some "Field Symbol of Message NewOrderSingle is missing." + state_event_reject_text = Some "Field Side in Message NewOrderSingle has an unrecognised tag value." } :: m_state.event_info } - | (_,_) -> m_state + | (M_Msg_NewOrderSingle_Tag,M_Field_OrdType_Tag,None) -> { (reject_NewOrderSingle_missingfield m_state { + mod_builtin_rejectInfo_text = "Field OrdType in Message NewOrderSingle has an unrecognised tag value."; + mod_builtin_rejectInfo_field = Some "OrdType" + }) with + event_info = { + state_event_counter = m_state.event_counter; + state_event_reject_text = Some "Field OrdType in Message NewOrderSingle has an unrecognised tag value." + } :: m_state.event_info + } + | (M_Msg_NewOrderSingle_Tag,M_Field_ExecInst_Tag,None) -> { (reject_NewOrderSingle_missingfield m_state { + mod_builtin_rejectInfo_text = "Field ExecInst in Message NewOrderSingle has an unrecognised tag value."; + mod_builtin_rejectInfo_field = Some "ExecInst" + }) with + event_info = { + state_event_counter = m_state.event_counter; + state_event_reject_text = Some "Field ExecInst in Message NewOrderSingle has an unrecognised tag value." + } :: m_state.event_info + } + | (_,_,_) -> m_state ) ;; + diff --git a/src-model/src/venue.iml b/src-model/src/venue.iml index 414d3824..85606485 100644 --- a/src-model/src/venue.iml +++ b/src-model/src/venue.iml @@ -1,6 +1,12 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "act_checks.iml"] +open Act_checks;; +[@@@import "act_process.iml"] +open Act_process;; [@@@import "../src-types/model_messages.iml"] open Model_messages;; +[@@@import "msg_minimal_invalid.iml"] +open Msg_minimal_invalid;; [@@@import "msg_process.iml"] open Msg_process;; [@@@import "../src-types/state.iml"] @@ -8,13 +14,49 @@ open State;; let one_step (m_state : model_state) = - (match m_state.incoming_msg with - | FIX_TL_None -> m_state - | msg -> let s' = process_msg m_state msg + (match m_state.incoming_action with + | Some act -> let s' = receive_action m_state act in { s' with - incoming_msg = FIX_TL_None; + incoming_action = None; event_counter = (+) m_state.event_counter 1 } + | None -> ((match m_state.incoming_msg with + | FIX_TL_None -> m_state + | msg -> let s' = process_msg m_state msg + in + { s' with + incoming_msg = FIX_TL_None; + event_counter = (+) m_state.event_counter 1 + } + ) + ) ) ;; + +let is_valid (m_state : model_state) : bool = + (match m_state.incoming_action with + | Some act -> (is_action_valid act m_state) + | None -> ((match m_state.incoming_msg with + | FIX_TL_Normal msg -> let msg = convert_inner m_state msg + in + is_message_valid msg m_state + | _ -> false + ) + ) + ) +;; + +let is_minimal_invalid (m_state : model_state) : bool = + (match m_state.incoming_action with + | Some act -> (is_action_valid act m_state) + | None -> ((match m_state.incoming_msg with + | FIX_TL_Normal msg -> let msg = convert_inner m_state msg + in + is_message_minimal_invalid msg m_state + | _ -> false + ) + ) + ) +;; + diff --git a/src-protocol-exts-pp/dune b/src-protocol-exts-pp/dune index a7bfb058..34892574 100644 --- a/src-protocol-exts-pp/dune +++ b/src-protocol-exts-pp/dune @@ -1,7 +1,7 @@ (library - (name protocol_exts_pp) - (public_name fix-engine.protocol_exts_pp) - (wrapped false) - (flags - (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) - (libraries imandra-prelude core_pp protocol_exts yojson)) + (name protocol_exts_pp) + (public_name fix-engine.protocol_exts_pp) + (wrapped false) + (flags (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) + (libraries imandra-prelude decoders-yojson core core_pp protocol_exts yojson) +) diff --git a/src-protocol-exts-pp/encode_app_enums.iml b/src-protocol-exts-pp/encode_app_enums.iml index bb24f6d8..fd842d57 100644 --- a/src-protocol-exts-pp/encode_app_enums.iml +++ b/src-protocol-exts-pp/encode_app_enums.iml @@ -1,760 +1,12 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "../src-protocol-exts/full_app_enums.iml"] -[@@@import "../src-core-pp/parser_utils.iml"] +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-protocol-exts/full_app_enums.iml"] open Full_app_enums;; +[@@@import "../src-core-pp/parser_utils.iml"] open Parser_utils.Parser;; -let encode_week (d) = - (match d with - | FIX_week_noweek -> "noweek" - | FIX_week_w1 -> "w1" - | FIX_week_w2 -> "w2" - | FIX_week_w3 -> "w3" - | FIX_week_w4 -> "w4" - | FIX_week_w5 -> "w5" - ) -;; - -let encode_AccountType (d) = - (match d with - | FIX_AccountType_CarriedCustomerSide -> "1" - | FIX_AccountType_CarriedNonCustomerSide -> "2" - | FIX_AccountType_HouseTrader -> "3" - | FIX_AccountType_FloorTrader -> "4" - | FIX_AccountType_CarriedNonCustomerSideCrossMargined -> "6" - | FIX_AccountType_HouseTraderCrossMargined -> "7" - | FIX_AccountType_JointBackOfficeAccount -> "8" - ) -;; - -let encode_AcctIDSource (d) = - (match d with - | FIX_AcctIDSource_BIC -> "1" - | FIX_AcctIDSource_SIDCode -> "2" - | FIX_AcctIDSource_TFM -> "3" - | FIX_AcctIDSource_OMGEO -> "4" - | FIX_AcctIDSource_DTCCCode -> "5" - | FIX_AcctIDSource_Other -> "99" - ) -;; - -let encode_Adjustment (d) = - (match d with - | FIX_Adjustment_Cancel -> "1" - | FIX_Adjustment_Error -> "2" - | FIX_Adjustment_Correction -> "3" - ) -;; - -let encode_AdjustmentType (d) = - (match d with - | FIX_AdjustmentType_ProcessRequestAsMarginDisposition -> "0" - | FIX_AdjustmentType_DeltaPlus -> "1" - | FIX_AdjustmentType_DeltaMinus -> "2" - | FIX_AdjustmentType_Final -> "3" - ) -;; - -let encode_AdvSide (d) = - (match d with - | FIX_AdvSide_Buy -> "B" - | FIX_AdvSide_Sell -> "S" - | FIX_AdvSide_Cross -> "X" - | FIX_AdvSide_Trade -> "T" - ) -;; - -let encode_AdvTransType (d) = - (match d with - | FIX_AdvTransType_New -> "N" - | FIX_AdvTransType_Cancel -> "C" - | FIX_AdvTransType_Replace -> "R" - ) -;; - -let encode_AffirmStatus (d) = - (match d with - | FIX_AffirmStatus_Received -> "1" - | FIX_AffirmStatus_ConfirmRejected -> "2" - | FIX_AffirmStatus_Affirmed -> "3" - ) -;; - -let encode_AggregatedBook (d) = - (match d with - | FIX_AggregatedBook_BookEntriesToBeAggregated -> "Y" - | FIX_AggregatedBook_BookEntriesShouldNotBeAggregated -> "N" - ) -;; - -let encode_AllocAccountType (d) = - (match d with - | FIX_AllocAccountType_CarriedCustomerSide -> "1" - | FIX_AllocAccountType_CarriedNonCustomerSide -> "2" - | FIX_AllocAccountType_HouseTrader -> "3" - | FIX_AllocAccountType_FloorTrader -> "4" - | FIX_AllocAccountType_CarriedNonCustomerSideCrossMargined -> "6" - | FIX_AllocAccountType_HouseTraderCrossMargined -> "7" - | FIX_AllocAccountType_JointBackOfficeAccount -> "8" - ) -;; - -let encode_AllocCancReplaceReason (d) = - (match d with - | FIX_AllocCancReplaceReason_OriginalDetailsIncomplete -> "1" - | FIX_AllocCancReplaceReason_ChangeInUnderlyingOrderDetails -> "2" - | FIX_AllocCancReplaceReason_Other -> "99" - ) -;; - -let encode_AllocHandlInst (d) = - (match d with - | FIX_AllocHandlInst_Match -> "1" - | FIX_AllocHandlInst_Forward -> "2" - | FIX_AllocHandlInst_ForwardAndMatch -> "3" - ) -;; - -let encode_AllocIntermedReqType (d) = - (match d with - | FIX_AllocIntermedReqType_PendingAccept -> "1" - | FIX_AllocIntermedReqType_PendingRelease -> "2" - | FIX_AllocIntermedReqType_PendingReversal -> "3" - | FIX_AllocIntermedReqType_Accept -> "4" - | FIX_AllocIntermedReqType_BlockLevelReject -> "5" - | FIX_AllocIntermedReqType_AccountLevelReject -> "6" - ) -;; - -let encode_AllocLinkType (d) = - (match d with - | FIX_AllocLinkType_FXNetting -> "0" - | FIX_AllocLinkType_FXSwap -> "1" - ) -;; - -let encode_AllocNoOrdersType (d) = - (match d with - | FIX_AllocNoOrdersType_NotSpecified -> "0" - | FIX_AllocNoOrdersType_ExplicitListProvided -> "1" - ) -;; - -let encode_AllocRejCode (d) = - (match d with - | FIX_AllocRejCode_UnknownAccount -> "0" - | FIX_AllocRejCode_IncorrectQuantity -> "1" - | FIX_AllocRejCode_IncorrectAveragegPrice -> "2" - | FIX_AllocRejCode_UnknownExecutingBrokerMnemonic -> "3" - | FIX_AllocRejCode_CommissionDifference -> "4" - | FIX_AllocRejCode_UnknownOrderID -> "5" - | FIX_AllocRejCode_UnknownListID -> "6" - | FIX_AllocRejCode_OtherSeeText -> "7" - | FIX_AllocRejCode_IncorrectAllocatedQuantity -> "8" - | FIX_AllocRejCode_CalculationDifference -> "9" - | FIX_AllocRejCode_UnknownOrStaleExecID -> "10" - | FIX_AllocRejCode_MismatchedData -> "11" - | FIX_AllocRejCode_UnknownClOrdID -> "12" - | FIX_AllocRejCode_WarehouseRequestRejected -> "13" - ) -;; - -let encode_AllocReportType (d) = - (match d with - | FIX_AllocReportType_SellsideCalculatedUsingPreliminary -> "3" - | FIX_AllocReportType_SellsideCalculatedWithoutPreliminary -> "4" - | FIX_AllocReportType_WarehouseRecap -> "5" - | FIX_AllocReportType_RequestToIntermediary -> "8" - ) -;; - -let encode_AllocSettlInstType (d) = - (match d with - | FIX_AllocSettlInstType_UseDefaultInstructions -> "0" - | FIX_AllocSettlInstType_DeriveFromParametersProvided -> "1" - | FIX_AllocSettlInstType_FullDetailsProvided -> "2" - | FIX_AllocSettlInstType_SSIDBIDsProvided -> "3" - | FIX_AllocSettlInstType_PhoneForInstructions -> "4" - ) -;; - -let encode_AllocStatus (d) = - (match d with - | FIX_AllocStatus_Accepted -> "0" - | FIX_AllocStatus_BlockLevelReject -> "1" - | FIX_AllocStatus_AccountLevelReject -> "2" - | FIX_AllocStatus_Received -> "3" - | FIX_AllocStatus_Incomplete -> "4" - | FIX_AllocStatus_RejectedByIntermediary -> "5" - ) -;; - -let encode_AllocTransType (d) = - (match d with - | FIX_AllocTransType_New -> "0" - | FIX_AllocTransType_Replace -> "1" - | FIX_AllocTransType_Cancel -> "2" - ) -;; - -let encode_AllocType (d) = - (match d with - | FIX_AllocType_Calculated -> "1" - | FIX_AllocType_Preliminary -> "2" - | FIX_AllocType_ReadyToBook -> "5" - | FIX_AllocType_WarehouseInstruction -> "7" - | FIX_AllocType_RequestToIntermediary -> "8" - ) -;; - -let encode_ApplQueueAction (d) = - (match d with - | FIX_ApplQueueAction_NoActionTaken -> "0" - | FIX_ApplQueueAction_QueueFlushed -> "1" - | FIX_ApplQueueAction_OverlayLast -> "2" - | FIX_ApplQueueAction_EndSession -> "3" - ) -;; - -let encode_ApplQueueResolution (d) = - (match d with - | FIX_ApplQueueResolution_NoActionTaken -> "0" - | FIX_ApplQueueResolution_QueueFlushed -> "1" - | FIX_ApplQueueResolution_OverlayLast -> "2" - | FIX_ApplQueueResolution_EndSession -> "3" - ) -;; - -let encode_AssignmentMethod (d) = - (match d with - | FIX_AssignmentMethod_Random -> "R" - | FIX_AssignmentMethod_ProRata -> "P" - ) -;; - -let encode_AvgPxIndicator (d) = - (match d with - | FIX_AvgPxIndicator_NoAveragePricing -> "0" - | FIX_AvgPxIndicator_Trade -> "1" - | FIX_AvgPxIndicator_LastTrade -> "2" - ) -;; - -let encode_BasisPxType (d) = - (match d with - | FIX_BasisPxType_ClosingPriceAtMorningSession -> "2" - | FIX_BasisPxType_ClosingPrice -> "3" - | FIX_BasisPxType_CurrentPrice -> "4" - | FIX_BasisPxType_SQ -> "5" - | FIX_BasisPxType_VWAPThroughADay -> "6" - | FIX_BasisPxType_VWAPThroughAMorningSession -> "7" - | FIX_BasisPxType_VWAPThroughAnAfternoonSession -> "8" - | FIX_BasisPxType_VWAPThroughADayExcept -> "9" - | FIX_BasisPxType_VWAPThroughAMorningSessionExcept -> "A" - | FIX_BasisPxType_VWAPThroughAnAfternoonSessionExcept -> "B" - | FIX_BasisPxType_Strike -> "C" - | FIX_BasisPxType_Open -> "D" - | FIX_BasisPxType_Others -> "Z" - ) -;; - -let encode_BidDescriptorType (d) = - (match d with - | FIX_BidDescriptorType_Sector -> "1" - | FIX_BidDescriptorType_Country -> "2" - | FIX_BidDescriptorType_Index -> "3" - ) -;; - -let encode_BidRequestTransType (d) = - (match d with - | FIX_BidRequestTransType_New -> "N" - | FIX_BidRequestTransType_Cancel -> "C" - ) -;; - -let encode_BidTradeType (d) = - (match d with - | FIX_BidTradeType_RiskTrade -> "R" - | FIX_BidTradeType_VWAPGuarantee -> "G" - | FIX_BidTradeType_Agency -> "A" - | FIX_BidTradeType_GuaranteedClose -> "J" - ) -;; - -let encode_BidType (d) = - (match d with - | FIX_BidType_NonDisclosed -> "1" - | FIX_BidType_Disclosed -> "2" - | FIX_BidType_NoBiddingProcess -> "3" - ) -;; - -let encode_BookingType (d) = - (match d with - | FIX_BookingType_RegularBooking -> "0" - | FIX_BookingType_CFD -> "1" - | FIX_BookingType_TotalReturnSwap -> "2" - ) -;; - -let encode_BookingUnit (d) = - (match d with - | FIX_BookingUnit_EachPartialExecutionIsABookableUnit -> "0" - | FIX_BookingUnit_AggregatePartialExecutionsOnThisOrder -> "1" - | FIX_BookingUnit_AggregateExecutionsForThisSymbol -> "2" - ) -;; - -let encode_CPProgram (d) = - (match d with - | FIX_CPProgram_Program3a3 -> "1" - | FIX_CPProgram_Program42 -> "2" - | FIX_CPProgram_Other -> "99" - ) -;; - -let encode_CancellationRights (d) = - (match d with - | FIX_CancellationRights_Yes -> "Y" - | FIX_CancellationRights_NoExecutionOnly -> "N" - | FIX_CancellationRights_NoWaiverAgreement -> "M" - | FIX_CancellationRights_NoInstitutional -> "O" - ) -;; - -let encode_CashMargin (d) = - (match d with - | FIX_CashMargin_Cash -> "1" - | FIX_CashMargin_MarginOpen -> "2" - | FIX_CashMargin_MarginClose -> "3" - ) -;; - -let encode_ClearingFeeIndicator (d) = - (match d with - | FIX_ClearingFeeIndicator_CBOEMember -> "B" - | FIX_ClearingFeeIndicator_NonMemberAndCustomer -> "C" - | FIX_ClearingFeeIndicator_EquityMemberAndClearingMember -> "E" - | FIX_ClearingFeeIndicator_FullAndAssociateMember -> "F" - | FIX_ClearingFeeIndicator_Firms106HAnd106J -> "H" - | FIX_ClearingFeeIndicator_GIM -> "I" - | FIX_ClearingFeeIndicator_Lessee106FEmployees -> "L" - | FIX_ClearingFeeIndicator_AllOtherOwnershipTypes -> "M" - | FIX_ClearingFeeIndicator_FirstYearDelegate -> "1" - | FIX_ClearingFeeIndicator_SecondYearDelegate -> "2" - | FIX_ClearingFeeIndicator_ThirdYearDelegate -> "3" - | FIX_ClearingFeeIndicator_FourthYearDelegate -> "4" - | FIX_ClearingFeeIndicator_FifthYearDelegate -> "5" - | FIX_ClearingFeeIndicator_SixthYearDelegate -> "9" - ) -;; - -let encode_ClearingInstruction (d) = - (match d with - | FIX_ClearingInstruction_ProcessNormally -> "0" - | FIX_ClearingInstruction_ExcludeFromAllNetting -> "1" - | FIX_ClearingInstruction_BilateralNettingOnly -> "2" - | FIX_ClearingInstruction_ExClearing -> "3" - | FIX_ClearingInstruction_SpecialTrade -> "4" - | FIX_ClearingInstruction_MultilateralNetting -> "5" - | FIX_ClearingInstruction_ClearAgainstCentralCounterparty -> "6" - | FIX_ClearingInstruction_ExcludeFromCentralCounterparty -> "7" - | FIX_ClearingInstruction_ManualMode -> "8" - | FIX_ClearingInstruction_AutomaticPostingMode -> "9" - | FIX_ClearingInstruction_AutomaticGiveUpMode -> "10" - | FIX_ClearingInstruction_QualifiedServiceRepresentativeQSR -> "11" - | FIX_ClearingInstruction_CustomerTrade -> "12" - | FIX_ClearingInstruction_SelfClearing -> "13" - ) -;; - -let encode_CollAction (d) = - (match d with - | FIX_CollAction_Retain -> "0" - | FIX_CollAction_Add -> "1" - | FIX_CollAction_Remove -> "2" - ) -;; - -let encode_CollAsgnReason (d) = - (match d with - | FIX_CollAsgnReason_Initial -> "0" - | FIX_CollAsgnReason_Scheduled -> "1" - | FIX_CollAsgnReason_TimeWarning -> "2" - | FIX_CollAsgnReason_MarginDeficiency -> "3" - | FIX_CollAsgnReason_MarginExcess -> "4" - | FIX_CollAsgnReason_ForwardCollateralDemand -> "5" - | FIX_CollAsgnReason_EventOfDefault -> "6" - | FIX_CollAsgnReason_AdverseTaxEvent -> "7" - ) -;; - -let encode_CollAsgnRejectReason (d) = - (match d with - | FIX_CollAsgnRejectReason_UnknownDeal -> "0" - | FIX_CollAsgnRejectReason_UnknownOrInvalidInstrument -> "1" - | FIX_CollAsgnRejectReason_UnauthorizedTransaction -> "2" - | FIX_CollAsgnRejectReason_InsufficientCollateral -> "3" - | FIX_CollAsgnRejectReason_InvalidTypeOfCollateral -> "4" - | FIX_CollAsgnRejectReason_ExcessiveSubstitution -> "5" - | FIX_CollAsgnRejectReason_Other -> "99" - ) -;; - -let encode_CollAsgnRespType (d) = - (match d with - | FIX_CollAsgnRespType_Received -> "0" - | FIX_CollAsgnRespType_Accepted -> "1" - | FIX_CollAsgnRespType_Declined -> "2" - | FIX_CollAsgnRespType_Rejected -> "3" - ) -;; - -let encode_CollAsgnTransType (d) = - (match d with - | FIX_CollAsgnTransType_New -> "0" - | FIX_CollAsgnTransType_Replace -> "1" - | FIX_CollAsgnTransType_Cancel -> "2" - | FIX_CollAsgnTransType_Release -> "3" - | FIX_CollAsgnTransType_Reverse -> "4" - ) -;; - -let encode_CollInquiryQualifier (d) = - (match d with - | FIX_CollInquiryQualifier_TradeDate -> "0" - | FIX_CollInquiryQualifier_GCInstrument -> "1" - | FIX_CollInquiryQualifier_CollateralInstrument -> "2" - | FIX_CollInquiryQualifier_SubstitutionEligible -> "3" - | FIX_CollInquiryQualifier_NotAssigned -> "4" - | FIX_CollInquiryQualifier_PartiallyAssigned -> "5" - | FIX_CollInquiryQualifier_FullyAssigned -> "6" - | FIX_CollInquiryQualifier_OutstandingTrades -> "7" - ) -;; - -let encode_CollInquiryResult (d) = - (match d with - | FIX_CollInquiryResult_Successful -> "0" - | FIX_CollInquiryResult_InvalidOrUnknownInstrument -> "1" - | FIX_CollInquiryResult_InvalidOrUnknownCollateralType -> "2" - | FIX_CollInquiryResult_InvalidParties -> "3" - | FIX_CollInquiryResult_InvalidTransportTypeRequested -> "4" - | FIX_CollInquiryResult_InvalidDestinationRequested -> "5" - | FIX_CollInquiryResult_NoCollateralFoundForTheTradeSpecified -> "6" - | FIX_CollInquiryResult_NoCollateralFoundForTheOrderSpecified -> "7" - | FIX_CollInquiryResult_CollateralInquiryTypeNotSupported -> "8" - | FIX_CollInquiryResult_UnauthorizedForCollateralInquiry -> "9" - | FIX_CollInquiryResult_Other -> "99" - ) -;; - -let encode_CollInquiryStatus (d) = - (match d with - | FIX_CollInquiryStatus_Accepted -> "0" - | FIX_CollInquiryStatus_AcceptedWithWarnings -> "1" - | FIX_CollInquiryStatus_Completed -> "2" - | FIX_CollInquiryStatus_CompletedWithWarnings -> "3" - | FIX_CollInquiryStatus_Rejected -> "4" - ) -;; - -let encode_CollStatus (d) = - (match d with - | FIX_CollStatus_Unassigned -> "0" - | FIX_CollStatus_PartiallyAssigned -> "1" - | FIX_CollStatus_AssignmentProposed -> "2" - | FIX_CollStatus_Assigned -> "3" - | FIX_CollStatus_Challenged -> "4" - ) -;; - -let encode_CommType (d) = - (match d with - | FIX_CommType_PerUnit -> "1" - | FIX_CommType_Percent -> "2" - | FIX_CommType_Absolute -> "3" - | FIX_CommType_PercentageWaivedCashDiscount -> "4" - | FIX_CommType_PercentageWaivedEnhancedUnits -> "5" - | FIX_CommType_PointsPerBondOrContract -> "6" - ) -;; - -let encode_ConfirmRejReason (d) = - (match d with - | FIX_ConfirmRejReason_MismatchedAccount -> "1" - | FIX_ConfirmRejReason_MissingSettlementInstructions -> "2" - | FIX_ConfirmRejReason_Other -> "99" - ) -;; - -let encode_ConfirmStatus (d) = - (match d with - | FIX_ConfirmStatus_Received -> "1" - | FIX_ConfirmStatus_MismatchedAccount -> "2" - | FIX_ConfirmStatus_MissingSettlementInstructions -> "3" - | FIX_ConfirmStatus_Confirmed -> "4" - | FIX_ConfirmStatus_RequestRejected -> "5" - ) -;; - -let encode_ConfirmTransType (d) = - (match d with - | FIX_ConfirmTransType_New -> "0" - | FIX_ConfirmTransType_Replace -> "1" - | FIX_ConfirmTransType_Cancel -> "2" - ) -;; - -let encode_ConfirmType (d) = - (match d with - | FIX_ConfirmType_Status -> "1" - | FIX_ConfirmType_Confirmation -> "2" - | FIX_ConfirmType_ConfirmationRequestRejected -> "3" - ) -;; - -let encode_ContAmtType (d) = - (match d with - | FIX_ContAmtType_CommissionAmount -> "1" - | FIX_ContAmtType_CommissionPercent -> "2" - | FIX_ContAmtType_InitialChargeAmount -> "3" - | FIX_ContAmtType_InitialChargePercent -> "4" - | FIX_ContAmtType_DiscountAmount -> "5" - | FIX_ContAmtType_DiscountPercent -> "6" - | FIX_ContAmtType_DilutionLevyAmount -> "7" - | FIX_ContAmtType_DilutionLevyPercent -> "8" - | FIX_ContAmtType_ExitChargeAmount -> "9" - | FIX_ContAmtType_ExitChargePercent -> "10" - | FIX_ContAmtType_FundBasedRenewalCommissionPercent -> "11" - | FIX_ContAmtType_ProjectedFundValue -> "12" - | FIX_ContAmtType_FundBasedRenewalCommissionOnOrder -> "13" - | FIX_ContAmtType_FundBasedRenewalCommissionOnFund -> "14" - | FIX_ContAmtType_NetSettlementAmount -> "15" - ) -;; - -let enncode_inner_CorporateAction (d) = - (match d with - | FIX_CorporateAction_ExDividend -> "A" - | FIX_CorporateAction_ExDistribution -> "B" - | FIX_CorporateAction_ExRights -> "C" - | FIX_CorporateAction_New -> "D" - | FIX_CorporateAction_ExInterest -> "E" - ) -;; - -let encode_CorporateAction (d) = - list_to_split (List.map enncode_inner_CorporateAction d) ' ' -;; - -let encode_CoveredOrUncovered (d) = - (match d with - | FIX_CoveredOrUncovered_Covered -> "0" - | FIX_CoveredOrUncovered_Uncovered -> "1" - ) -;; - -let encode_CrossPrioritization (d) = - (match d with - | FIX_CrossPrioritization_FIXNone -> "0" - | FIX_CrossPrioritization_BuySideIsPrioritized -> "1" - | FIX_CrossPrioritization_SellSideIsPrioritized -> "2" - ) -;; - -let encode_CrossType (d) = - (match d with - | FIX_CrossType_CrossAON -> "1" - | FIX_CrossType_CrossIOC -> "2" - | FIX_CrossType_CrossOneSide -> "3" - | FIX_CrossType_CrossSamePrice -> "4" - ) -;; - -let encode_CustOrderCapacity (d) = - (match d with - | FIX_CustOrderCapacity_MemberTradingForTheirOwnAccount -> "1" - | FIX_CustOrderCapacity_ClearingFirmTradingForItsProprietaryAccount -> "2" - | FIX_CustOrderCapacity_MemberTradingForAnotherMember -> "3" - | FIX_CustOrderCapacity_AllOther -> "4" - ) -;; - -let encode_CxlRejReason (d) = - (match d with - | FIX_CxlRejReason_TooLateToCancel -> "0" - | FIX_CxlRejReason_UnknownOrder -> "1" - | FIX_CxlRejReason_BrokerCredit -> "2" - | FIX_CxlRejReason_OrderAlreadyInPendingStatus -> "3" - | FIX_CxlRejReason_UnableToProcessOrderMassCancelRequest -> "4" - | FIX_CxlRejReason_OrigOrdModTime -> "5" - | FIX_CxlRejReason_DuplicateClOrdID -> "6" - | FIX_CxlRejReason_Other -> "99" - ) -;; - -let encode_CxlRejResponseTo (d) = - (match d with - | FIX_CxlRejResponseTo_OrderCancelRequest -> "1" - | FIX_CxlRejResponseTo_OrderCancel -> "2" - ) -;; - -let encode_DKReason (d) = - (match d with - | FIX_DKReason_UnknownSymbol -> "A" - | FIX_DKReason_WrongSide -> "B" - | FIX_DKReason_QuantityExceedsOrder -> "C" - | FIX_DKReason_NoMatchingOrder -> "D" - | FIX_DKReason_PriceExceedsLimit -> "E" - | FIX_DKReason_CalculationDifference -> "F" - | FIX_DKReason_Other -> "Z" - ) -;; - -let encode_DayBookingInst (d) = - (match d with - | FIX_DayBookingInst_Auto -> "0" - | FIX_DayBookingInst_SpeakWithOrderInitiatorBeforeBooking -> "1" - | FIX_DayBookingInst_Accumulate -> "2" - ) -;; - -let encode_DeleteReason (d) = - (match d with - | FIX_DeleteReason_Cancellation -> "0" - | FIX_DeleteReason_Error -> "1" - ) -;; -let encode_DeliveryForm (d) = - (match d with - | FIX_DeliveryForm_BookEntry -> "1" - | FIX_DeliveryForm_Bearer -> "2" - ) -;; - -let encode_DeliveryType (d) = - (match d with - | FIX_DeliveryType_VersusPayment -> "0" - | FIX_DeliveryType_Free -> "1" - | FIX_DeliveryType_TriParty -> "2" - | FIX_DeliveryType_HoldInCustody -> "3" - ) -;; - -let encode_DiscretionInst (d) = - (match d with - | FIX_DiscretionInst_RelatedToDisplayedPrice -> "0" - | FIX_DiscretionInst_RelatedToMarketPrice -> "1" - | FIX_DiscretionInst_RelatedToPrimaryPrice -> "2" - | FIX_DiscretionInst_RelatedToLocalPrimaryPrice -> "3" - | FIX_DiscretionInst_RelatedToMidpointPrice -> "4" - | FIX_DiscretionInst_RelatedToLastTradePrice -> "5" - | FIX_DiscretionInst_RelatedToVWAP -> "6" - ) -;; - -let encode_DiscretionLimitType (d) = - (match d with - | FIX_DiscretionLimitType_OrBetter -> "0" - | FIX_DiscretionLimitType_Strict -> "1" - | FIX_DiscretionLimitType_OrWorse -> "2" - ) -;; - -let encode_DiscretionMoveType (d) = - (match d with - | FIX_DiscretionMoveType_Floating -> "0" - | FIX_DiscretionMoveType_Fixed -> "1" - ) -;; - -let encode_DiscretionOffsetType (d) = - (match d with - | FIX_DiscretionOffsetType_Price -> "0" - | FIX_DiscretionOffsetType_BasisPoints -> "1" - | FIX_DiscretionOffsetType_Ticks -> "2" - | FIX_DiscretionOffsetType_PriceTier -> "3" - ) -;; - -let encode_DiscretionRoundDirection (d) = - (match d with - | FIX_DiscretionRoundDirection_MoreAggressive -> "1" - | FIX_DiscretionRoundDirection_MorePassive -> "2" - ) -;; - -let encode_DiscretionScope (d) = - (match d with - | FIX_DiscretionScope_Local -> "1" - | FIX_DiscretionScope_National -> "2" - | FIX_DiscretionScope_Global -> "3" - | FIX_DiscretionScope_NationalExcludingLocal -> "4" - ) -;; - -let encode_DistribPaymentMethod (d) = - (match d with - | FIX_DistribPaymentMethod_CREST -> "1" - | FIX_DistribPaymentMethod_NSCC -> "2" - | FIX_DistribPaymentMethod_Euroclear -> "3" - | FIX_DistribPaymentMethod_Clearstream -> "4" - | FIX_DistribPaymentMethod_Cheque -> "5" - | FIX_DistribPaymentMethod_TelegraphicTransfer -> "6" - | FIX_DistribPaymentMethod_FedWire -> "7" - | FIX_DistribPaymentMethod_DirectCredit -> "8" - | FIX_DistribPaymentMethod_ACHCredit -> "9" - | FIX_DistribPaymentMethod_BPAY -> "10" - | FIX_DistribPaymentMethod_HighValueClearingSystemHVACS -> "11" - | FIX_DistribPaymentMethod_ReinvestInFund -> "12" - ) -;; - -let encode_DlvyInstType (d) = - (match d with - | FIX_DlvyInstType_Securities -> "S" - | FIX_DlvyInstType_Cash -> "C" - ) -;; - -let encode_DueToRelated (d) = - (match d with - | FIX_DueToRelated_RelatedToSecurityHalt -> "Y" - | FIX_DueToRelated_NotRelatedToSecurityHalt -> "N" - ) -;; - -let encode_EmailType (d) = - (match d with - | FIX_EmailType_New -> "0" - | FIX_EmailType_Reply -> "1" - | FIX_EmailType_AdminReply -> "2" - ) -;; - -let encode_EventType (d) = - (match d with - | FIX_EventType_Put -> "1" - | FIX_EventType_Call -> "2" - | FIX_EventType_Tender -> "3" - | FIX_EventType_SinkingFundCall -> "4" - | FIX_EventType_Other -> "99" - ) -;; - -let encode_ExchangeForPhysical (d) = - (match d with - | FIX_ExchangeForPhysical_True -> "Y" - | FIX_ExchangeForPhysical_False -> "N" - ) -;; - -let enncode_inner_ExecInst (d) = +let encode_inner_ExecInst (d) = (match d with | FIX_ExecInst_NotHeld -> "1" | FIX_ExecInst_Work -> "2" @@ -771,1608 +23,136 @@ let enncode_inner_ExecInst (d) = | FIX_ExecInst_CallFirst -> "C" | FIX_ExecInst_PercentOfVolume -> "D" | FIX_ExecInst_DoNotIncrease -> "E" - | FIX_ExecInst_DoNotReduce -> "F" - | FIX_ExecInst_AllOrNone -> "G" - | FIX_ExecInst_ReinstateOnSystemFailure -> "H" - | FIX_ExecInst_InstitutionsOnly -> "I" - | FIX_ExecInst_ReinstateOnTradingHalt -> "J" - | FIX_ExecInst_CancelOnTradingHalt -> "K" - | FIX_ExecInst_LastPeg -> "L" - | FIX_ExecInst_MidPricePeg -> "M" - | FIX_ExecInst_NonNegotiable -> "N" - | FIX_ExecInst_OpeningPeg -> "O" - | FIX_ExecInst_MarketPeg -> "P" - | FIX_ExecInst_CancelOnSystemFailure -> "Q" - | FIX_ExecInst_PrimaryPeg -> "R" - | FIX_ExecInst_Suspend -> "S" - | FIX_ExecInst_CustomerDisplayInstruction -> "U" - | FIX_ExecInst_Netting -> "V" - | FIX_ExecInst_PegToVWAP -> "W" - | FIX_ExecInst_TradeAlong -> "X" - | FIX_ExecInst_TryToStop -> "Y" - | FIX_ExecInst_CancelIfNotBest -> "Z" - | FIX_ExecInst_TrailingStopPeg -> "a" - | FIX_ExecInst_StrictLimit -> "b" - | FIX_ExecInst_IgnorePriceValidityChecks -> "c" - | FIX_ExecInst_PegToLimitPrice -> "d" - | FIX_ExecInst_WorkToTargetStrategy -> "e" - ) -;; - -let encode_ExecInst (d) = - list_to_split (List.map enncode_inner_ExecInst d) ' ' -;; - -let encode_ExecPriceType (d) = - (match d with - | FIX_ExecPriceType_BidPrice -> "B" - | FIX_ExecPriceType_CreationPrice -> "C" - | FIX_ExecPriceType_CreationPricePlusAdjustmentPercent -> "D" - | FIX_ExecPriceType_CreationPricePlusAdjustmentAmount -> "E" - | FIX_ExecPriceType_OfferPrice -> "O" - | FIX_ExecPriceType_OfferPriceMinusAdjustmentPercent -> "P" - | FIX_ExecPriceType_OfferPriceMinusAdjustmentAmount -> "Q" - | FIX_ExecPriceType_SinglePrice -> "S" - ) -;; - -let encode_ExecRestatementReason (d) = - (match d with - | FIX_ExecRestatementReason_GTCorporateAction -> "0" - | FIX_ExecRestatementReason_GTRenewal -> "1" - | FIX_ExecRestatementReason_VerbalChange -> "2" - | FIX_ExecRestatementReason_RepricingOfOrder -> "3" - | FIX_ExecRestatementReason_BrokerOption -> "4" - | FIX_ExecRestatementReason_PartialDeclineOfOrderQty -> "5" - | FIX_ExecRestatementReason_CancelOnTradingHalt -> "6" - | FIX_ExecRestatementReason_CancelOnSystemFailure -> "7" - | FIX_ExecRestatementReason_Market -> "8" - | FIX_ExecRestatementReason_Canceled -> "9" - | FIX_ExecRestatementReason_WarehouseRecap -> "10" - | FIX_ExecRestatementReason_Other -> "99" - ) -;; - -let encode_ExecType (d) = - (match d with - | FIX_ExecType_New -> "0" - | FIX_ExecType_DoneForDay -> "3" - | FIX_ExecType_Canceled -> "4" - | FIX_ExecType_Replaced -> "5" - | FIX_ExecType_PendingCancel -> "6" - | FIX_ExecType_Stopped -> "7" - | FIX_ExecType_Rejected -> "8" - | FIX_ExecType_Suspended -> "9" - | FIX_ExecType_PendingNew -> "A" - | FIX_ExecType_Calculated -> "B" - | FIX_ExecType_Expired -> "C" - | FIX_ExecType_Restated -> "D" - | FIX_ExecType_PendingReplace -> "E" - | FIX_ExecType_Trade -> "F" - | FIX_ExecType_TradeCorrect -> "G" - | FIX_ExecType_TradeCancel -> "H" - | FIX_ExecType_OrderStatus -> "I" - ) -;; - -let encode_ExerciseMethod (d) = - (match d with - | FIX_ExerciseMethod_Automatic -> "A" - | FIX_ExerciseMethod_Manual -> "M" - ) -;; - -let encode_ExpirationCycle (d) = - (match d with - | FIX_ExpirationCycle_ExpireOnTradingSessionClose -> "0" - | FIX_ExpirationCycle_ExpireOnTradingSessionOpen -> "1" - ) -;; - -let enncode_inner_FinancialStatus (d) = - (match d with - | FIX_FinancialStatus_Bankrupt -> "1" - | FIX_FinancialStatus_PendingDelisting -> "2" - ) -;; - -let encode_FinancialStatus (d) = - list_to_split (List.map enncode_inner_FinancialStatus d) ' ' -;; - -let encode_ForexReq (d) = - (match d with - | FIX_ForexReq_ExecuteForexAfterSecurityTrade -> "Y" - | FIX_ForexReq_DoNotExecuteForexAfterSecurityTrade -> "N" - ) -;; - -let encode_FundRenewWaiv (d) = - (match d with - | FIX_FundRenewWaiv_Yes -> "Y" - | FIX_FundRenewWaiv_No -> "N" - ) -;; - -let encode_GTBookingInst (d) = - (match d with - | FIX_GTBookingInst_BookOutAllTradesOnDayOfExecution -> "0" - | FIX_GTBookingInst_AccumulateUntilFilledOrExpired -> "1" - | FIX_GTBookingInst_AccumulateUntilVerballyNotifiedOtherwise -> "2" - ) -;; - -let encode_HaltReason (d) = - (match d with - | FIX_HaltReason_OrderImbalance -> "I" - | FIX_HaltReason_EquipmentChangeover -> "X" - | FIX_HaltReason_NewsPending -> "P" - | FIX_HaltReason_NewsDissemination -> "D" - | FIX_HaltReason_OrderInflux -> "E" - | FIX_HaltReason_AdditionalInformation -> "M" - ) -;; - -let encode_HandlInst (d) = - (match d with - | FIX_HandlInst_AutomatedExecutionNoIntervention -> "1" - | FIX_HandlInst_AutomatedExecutionInterventionOK -> "2" - | FIX_HandlInst_ManualOrder -> "3" - ) -;; - -let encode_IOINaturalFlag (d) = - (match d with - | FIX_IOINaturalFlag_Natural -> "Y" - | FIX_IOINaturalFlag_NotNatural -> "N" - ) -;; - -let encode_IOIQltyInd (d) = - (match d with - | FIX_IOIQltyInd_Low -> "L" - | FIX_IOIQltyInd_Medium -> "M" - | FIX_IOIQltyInd_High -> "H" - ) -;; - -let encode_IOIQty (d) = - (match d with - | FIX_IOIQty_Small -> "S" - | FIX_IOIQty_Medium -> "M" - | FIX_IOIQty_Large -> "L" - ) -;; - -let encode_IOIQualifier (d) = - (match d with - | FIX_IOIQualifier_AllOrNone -> "A" - | FIX_IOIQualifier_MarketOnClose -> "B" - | FIX_IOIQualifier_AtTheClose -> "C" - | FIX_IOIQualifier_VWAP -> "D" - | FIX_IOIQualifier_InTouchWith -> "I" - | FIX_IOIQualifier_Limit -> "L" - | FIX_IOIQualifier_MoreBehind -> "M" - | FIX_IOIQualifier_AtTheOpen -> "O" - | FIX_IOIQualifier_TakingAPosition -> "P" - | FIX_IOIQualifier_AtTheMarket -> "Q" - | FIX_IOIQualifier_ReadyToTrade -> "R" - | FIX_IOIQualifier_PortfolioShown -> "S" - | FIX_IOIQualifier_ThroughTheDay -> "T" - | FIX_IOIQualifier_Versus -> "V" - | FIX_IOIQualifier_Indication -> "W" - | FIX_IOIQualifier_CrossingOpportunity -> "X" - | FIX_IOIQualifier_AtTheMidpoint -> "Y" - | FIX_IOIQualifier_PreOpen -> "Z" - ) -;; - -let encode_IOITransType (d) = - (match d with - | FIX_IOITransType_New -> "N" - | FIX_IOITransType_Cancel -> "C" - | FIX_IOITransType_Replace -> "R" - ) -;; - -let encode_InViewOfCommon (d) = - (match d with - | FIX_InViewOfCommon_HaltWasDueToCommonStockBeingHalted -> "Y" - | FIX_InViewOfCommon_HaltWasNotRelatedToAHaltOfTheCommonStock -> "N" - ) -;; - -let encode_IncTaxInd (d) = - (match d with - | FIX_IncTaxInd_Net -> "1" - | FIX_IncTaxInd_Gross -> "2" - ) -;; - -let encode_InstrAttribType (d) = - (match d with - | FIX_InstrAttribType_Flat -> "1" - | FIX_InstrAttribType_ZeroCoupon -> "2" - | FIX_InstrAttribType_InterestBearing -> "3" - | FIX_InstrAttribType_NoPeriodicPayments -> "4" - | FIX_InstrAttribType_VariableRate -> "5" - | FIX_InstrAttribType_LessFeeForPut -> "6" - | FIX_InstrAttribType_SteppedCoupon -> "7" - | FIX_InstrAttribType_CouponPeriod -> "8" - | FIX_InstrAttribType_When -> "9" - | FIX_InstrAttribType_OriginalIssueDiscount -> "10" - | FIX_InstrAttribType_Callable -> "11" - | FIX_InstrAttribType_EscrowedToMaturity -> "12" - | FIX_InstrAttribType_EscrowedToRedemptionDate -> "13" - | FIX_InstrAttribType_PreRefunded -> "14" - | FIX_InstrAttribType_InDefault -> "15" - | FIX_InstrAttribType_Unrated -> "16" - | FIX_InstrAttribType_Taxable -> "17" - | FIX_InstrAttribType_Indexed -> "18" - | FIX_InstrAttribType_SubjectToAlternativeMinimumTax -> "19" - | FIX_InstrAttribType_OriginalIssueDiscountPrice -> "20" - | FIX_InstrAttribType_CallableBelowMaturityValue -> "21" - | FIX_InstrAttribType_CallableWithoutNotice -> "22" - | FIX_InstrAttribType_Text -> "99" - ) -;; - -let encode_LastCapacity (d) = - (match d with - | FIX_LastCapacity_Agent -> "1" - | FIX_LastCapacity_CrossAsAgent -> "2" - | FIX_LastCapacity_CrossAsPrincipal -> "3" - | FIX_LastCapacity_Principal -> "4" - ) -;; - -let encode_LastFragment (d) = - (match d with - | FIX_LastFragment_LastMessage -> "Y" - | FIX_LastFragment_NotLastMessage -> "N" - ) -;; - -let encode_LastLiquidityInd (d) = - (match d with - | FIX_LastLiquidityInd_AddedLiquidity -> "1" - | FIX_LastLiquidityInd_RemovedLiquidity -> "2" - | FIX_LastLiquidityInd_LiquidityRoutedOut -> "3" - ) -;; - -let encode_LegSwapType (d) = - (match d with - | FIX_LegSwapType_ParForPar -> "1" - | FIX_LegSwapType_ModifiedDuration -> "2" - | FIX_LegSwapType_Risk -> "4" - | FIX_LegSwapType_Proceeds -> "5" - ) -;; - -let encode_LegalConfirm (d) = - (match d with - | FIX_LegalConfirm_LegalConfirm -> "Y" - | FIX_LegalConfirm_DoesNotConsituteALegalConfirm -> "N" - ) -;; - -let encode_LiquidityIndType (d) = - (match d with - | FIX_LiquidityIndType_FiveDayMovingAverage -> "1" - | FIX_LiquidityIndType_TwentyDayMovingAverage -> "2" - | FIX_LiquidityIndType_NormalMarketSize -> "3" - | FIX_LiquidityIndType_Other -> "4" - ) -;; - -let encode_ListExecInstType (d) = - (match d with - | FIX_ListExecInstType_Immediate -> "1" - | FIX_ListExecInstType_WaitForInstruction -> "2" - | FIX_ListExecInstType_SellDriven -> "3" - | FIX_ListExecInstType_BuyDrivenCashTopUp -> "4" - | FIX_ListExecInstType_BuyDrivenCashWithdraw -> "5" - ) -;; - -let encode_ListOrderStatus (d) = - (match d with - | FIX_ListOrderStatus_InBiddingProcess -> "1" - | FIX_ListOrderStatus_ReceivedForExecution -> "2" - | FIX_ListOrderStatus_Executing -> "3" - | FIX_ListOrderStatus_Cancelling -> "4" - | FIX_ListOrderStatus_Alert -> "5" - | FIX_ListOrderStatus_AllDone -> "6" - | FIX_ListOrderStatus_Reject -> "7" - ) -;; - -let encode_ListStatusType (d) = - (match d with - | FIX_ListStatusType_Ack -> "1" - | FIX_ListStatusType_Response -> "2" - | FIX_ListStatusType_Timed -> "3" - | FIX_ListStatusType_ExecStarted -> "4" - | FIX_ListStatusType_AllDone -> "5" - | FIX_ListStatusType_Alert -> "6" - ) -;; - -let encode_LocateReqd (d) = - (match d with - | FIX_LocateReqd_Yes -> "Y" - | FIX_LocateReqd_No -> "N" - ) -;; - -let encode_MDEntryType (d) = - (match d with - | FIX_MDEntryType_Bid -> "0" - | FIX_MDEntryType_Offer -> "1" - | FIX_MDEntryType_Trade -> "2" - | FIX_MDEntryType_IndexValue -> "3" - | FIX_MDEntryType_OpeningPrice -> "4" - | FIX_MDEntryType_ClosingPrice -> "5" - | FIX_MDEntryType_SettlementPrice -> "6" - | FIX_MDEntryType_TradingSessionHighPrice -> "7" - | FIX_MDEntryType_TradingSessionLowPrice -> "8" - | FIX_MDEntryType_TradingSessionVWAPPrice -> "9" - | FIX_MDEntryType_Imbalance -> "A" - | FIX_MDEntryType_TradeVolume -> "B" - | FIX_MDEntryType_OpenInterest -> "C" - ) -;; - -let encode_MDImplicitDelete (d) = - (match d with - | FIX_MDImplicitDelete_Yes -> "Y" - | FIX_MDImplicitDelete_No -> "N" - ) -;; - -let encode_MDReqRejReason (d) = - (match d with - | FIX_MDReqRejReason_UnknownSymbol -> "0" - | FIX_MDReqRejReason_DuplicateMDReqID -> "1" - | FIX_MDReqRejReason_InsufficientBandwidth -> "2" - | FIX_MDReqRejReason_InsufficientPermissions -> "3" - | FIX_MDReqRejReason_UnsupportedSubscriptionRequestType -> "4" - | FIX_MDReqRejReason_UnsupportedMarketDepth -> "5" - | FIX_MDReqRejReason_UnsupportedMDUpdateType -> "6" - | FIX_MDReqRejReason_UnsupportedAggregatedBook -> "7" - | FIX_MDReqRejReason_UnsupportedMDEntryType -> "8" - | FIX_MDReqRejReason_UnsupportedTradingSessionID -> "9" - | FIX_MDReqRejReason_UnsupportedScope -> "A" - | FIX_MDReqRejReason_UnsupportedOpenCloseSettleFlag -> "B" - | FIX_MDReqRejReason_UnsupportedMDImplicitDelete -> "C" - ) -;; - -let encode_MDUpdateAction (d) = - (match d with - | FIX_MDUpdateAction_New -> "0" - | FIX_MDUpdateAction_Change -> "1" - | FIX_MDUpdateAction_Delete -> "2" - ) -;; - -let encode_MDUpdateType (d) = - (match d with - | FIX_MDUpdateType_FullRefresh -> "0" - | FIX_MDUpdateType_IncrementalRefresh -> "1" - ) -;; - -let encode_MassCancelRejectReason (d) = - (match d with - | FIX_MassCancelRejectReason_MassCancelNotSupported -> "0" - | FIX_MassCancelRejectReason_InvalidOrUnknownSecurity -> "1" - | FIX_MassCancelRejectReason_InvalidOrUnkownUnderlyingSecurity -> "2" - | FIX_MassCancelRejectReason_InvalidOrUnknownProduct -> "3" - | FIX_MassCancelRejectReason_InvalidOrUnknownCFICode -> "4" - | FIX_MassCancelRejectReason_InvalidOrUnknownSecurityType -> "5" - | FIX_MassCancelRejectReason_InvalidOrUnknownTradingSession -> "6" - | FIX_MassCancelRejectReason_Other -> "99" - ) -;; - -let encode_MassCancelRequestType (d) = - (match d with - | FIX_MassCancelRequestType_CancelOrdersForASecurity -> "1" - | FIX_MassCancelRequestType_CancelOrdersForAnUnderlyingSecurity -> "2" - | FIX_MassCancelRequestType_CancelOrdersForAProduct -> "3" - | FIX_MassCancelRequestType_CancelOrdersForACFICode -> "4" - | FIX_MassCancelRequestType_CancelOrdersForASecurityType -> "5" - | FIX_MassCancelRequestType_CancelOrdersForATradingSession -> "6" - | FIX_MassCancelRequestType_CancelAllOrders -> "7" - ) -;; - -let encode_MassCancelResponse (d) = - (match d with - | FIX_MassCancelResponse_CancelRequestRejected -> "0" - | FIX_MassCancelResponse_CancelOrdersForASecurity -> "1" - | FIX_MassCancelResponse_CancelOrdersForAnUnderlyingSecurity -> "2" - | FIX_MassCancelResponse_CancelOrdersForAProduct -> "3" - | FIX_MassCancelResponse_CancelOrdersForACFICode -> "4" - | FIX_MassCancelResponse_CancelOrdersForASecurityType -> "5" - | FIX_MassCancelResponse_CancelOrdersForATradingSession -> "6" - | FIX_MassCancelResponse_CancelAllOrders -> "7" - ) -;; - -let encode_MassStatusReqType (d) = - (match d with - | FIX_MassStatusReqType_StatusForOrdersForASecurity -> "1" - | FIX_MassStatusReqType_StatusForOrdersForAnUnderlyingSecurity -> "2" - | FIX_MassStatusReqType_StatusForOrdersForAProduct -> "3" - | FIX_MassStatusReqType_StatusForOrdersForACFICode -> "4" - | FIX_MassStatusReqType_StatusForOrdersForASecurityType -> "5" - | FIX_MassStatusReqType_StatusForOrdersForATradingSession -> "6" - | FIX_MassStatusReqType_StatusForAllOrders -> "7" - | FIX_MassStatusReqType_StatusForOrdersForAPartyID -> "8" - ) -;; - -let encode_MatchStatus (d) = - (match d with - | FIX_MatchStatus_Compared -> "0" - | FIX_MatchStatus_Uncompared -> "1" - | FIX_MatchStatus_AdvisoryOrAlert -> "2" - ) -;; - -let encode_MatchType (d) = - (match d with - | FIX_MatchType_ExactMatchPlus4BadgesExecTime -> "A1" - | FIX_MatchType_ExactMatchPlus4Badges -> "A2" - | FIX_MatchType_ExactMatchPlus2BadgesExecTime -> "A3" - | FIX_MatchType_ExactMatchPlus2Badges -> "A4" - | FIX_MatchType_ExactMatchPlusExecTime -> "A5" - | FIX_MatchType_StampedAdvisoriesOrSpecialistAccepts -> "AQ" - | FIX_MatchType_A1ExactMatchSummarizedQuantity -> "S1" - | FIX_MatchType_A2ExactMatchSummarizedQuantity -> "S2" - | FIX_MatchType_A3ExactMatchSummarizedQuantity -> "S3" - | FIX_MatchType_A4ExactMatchSummarizedQuantity -> "S4" - | FIX_MatchType_A5ExactMatchSummarizedQuantity -> "S5" - | FIX_MatchType_ExactMatchMinusBadgesTimes -> "M1" - | FIX_MatchType_SummarizedMatchMinusBadgesTimes -> "M2" - | FIX_MatchType_OCSLockedIn -> "MT" - | FIX_MatchType_ACTAcceptedTrade -> "M3" - | FIX_MatchType_ACTDefaultTrade -> "M4" - | FIX_MatchType_ACTDefaultAfterM2 -> "M5" - | FIX_MatchType_ACTM6Match -> "M6" - ) -;; - -let encode_MessageEncoding (d) = - (match d with - | FIX_MessageEncoding_ISO2022JP -> "ISO-2022-JP" - | FIX_MessageEncoding_EUCJP -> "EUC-JP" - | FIX_MessageEncoding_ShiftJIS -> "Shift_JIS" - | FIX_MessageEncoding_UTF8 -> "UTF-8" - ) -;; - -let encode_MiscFeeBasis (d) = - (match d with - | FIX_MiscFeeBasis_Absolute -> "0" - | FIX_MiscFeeBasis_PerUnit -> "1" - | FIX_MiscFeeBasis_Percentage -> "2" - ) -;; - -let encode_MiscFeeType (d) = - (match d with - | FIX_MiscFeeType_Regulatory -> "1" - | FIX_MiscFeeType_Tax -> "2" - | FIX_MiscFeeType_LocalCommission -> "3" - | FIX_MiscFeeType_ExchangeFees -> "4" - | FIX_MiscFeeType_Stamp -> "5" - | FIX_MiscFeeType_Levy -> "6" - | FIX_MiscFeeType_Other -> "7" - | FIX_MiscFeeType_Markup -> "8" - | FIX_MiscFeeType_ConsumptionTax -> "9" - | FIX_MiscFeeType_PerTransaction -> "10" - | FIX_MiscFeeType_Conversion -> "11" - | FIX_MiscFeeType_Agent -> "12" - ) -;; - -let encode_MoneyLaunderingStatus (d) = - (match d with - | FIX_MoneyLaunderingStatus_Passed -> "Y" - | FIX_MoneyLaunderingStatus_NotChecked -> "N" - | FIX_MoneyLaunderingStatus_ExemptBelowLimit -> "1" - | FIX_MoneyLaunderingStatus_ExemptMoneyType -> "2" - | FIX_MoneyLaunderingStatus_ExemptAuthorised -> "3" - ) -;; - -let encode_MsgDirection (d) = - (match d with - | FIX_MsgDirection_Send -> "S" - | FIX_MsgDirection_Receive -> "R" - ) -;; - -let encode_MultiLegReportingType (d) = - (match d with - | FIX_MultiLegReportingType_SingleSecurity -> "1" - | FIX_MultiLegReportingType_IndividualLegOfAMultiLegSecurity -> "2" - | FIX_MultiLegReportingType_MultiLegSecurity -> "3" - ) -;; - -let encode_MultiLegRptTypeReq (d) = - (match d with - | FIX_MultiLegRptTypeReq_ReportByMulitlegSecurityOnly -> "0" - | FIX_MultiLegRptTypeReq_ReportByMultilegSecurityAndInstrumentLegs -> "1" - | FIX_MultiLegRptTypeReq_ReportByInstrumentLegsOnly -> "2" - ) -;; - -let encode_NetGrossInd (d) = - (match d with - | FIX_NetGrossInd_Net -> "1" - | FIX_NetGrossInd_Gross -> "2" - ) -;; - -let encode_NetworkRequestType (d) = - (match d with - | FIX_NetworkRequestType_Snapshot -> "1" - | FIX_NetworkRequestType_Subscribe -> "2" - | FIX_NetworkRequestType_StopSubscribing -> "4" - | FIX_NetworkRequestType_LevelOfDetail -> "8" - ) -;; - -let encode_NetworkStatusResponseType (d) = - (match d with - | FIX_NetworkStatusResponseType_Full -> "1" - | FIX_NetworkStatusResponseType_IncrementalUpdate -> "2" - ) -;; - -let encode_NoSides (d) = - (match d with - | FIX_NoSides_OneSide -> "1" - | FIX_NoSides_BothSides -> "2" - ) -;; - -let encode_NotifyBrokerOfCredit (d) = - (match d with - | FIX_NotifyBrokerOfCredit_DetailsShouldBeCommunicated -> "Y" - | FIX_NotifyBrokerOfCredit_DetailsShouldNotBeCommunicated -> "N" - ) -;; - -let encode_OddLot (d) = - (match d with - | FIX_OddLot_TreatAsOddLot -> "Y" - | FIX_OddLot_TreatAsRoundLot -> "N" - ) -;; - -let enncode_inner_OpenCloseSettlFlag (d) = - (match d with - | FIX_OpenCloseSettlFlag_DailyOpen -> "0" - | FIX_OpenCloseSettlFlag_SessionOpen -> "1" - | FIX_OpenCloseSettlFlag_DeliverySettlementEntry -> "2" - | FIX_OpenCloseSettlFlag_ExpectedEntry -> "3" - | FIX_OpenCloseSettlFlag_EntryFromPreviousBusinessDay -> "4" - | FIX_OpenCloseSettlFlag_TheoreticalPriceValue -> "5" - ) -;; - -let encode_OpenCloseSettlFlag (d) = - list_to_split (List.map enncode_inner_OpenCloseSettlFlag d) ' ' -;; - -let encode_OrdRejReason (d) = - (match d with - | FIX_OrdRejReason_BrokerCredit -> "0" - | FIX_OrdRejReason_UnknownSymbol -> "1" - | FIX_OrdRejReason_ExchangeClosed -> "2" - | FIX_OrdRejReason_OrderExceedsLimit -> "3" - | FIX_OrdRejReason_TooLateToEnter -> "4" - | FIX_OrdRejReason_UnknownOrder -> "5" - | FIX_OrdRejReason_DuplicateOrder -> "6" - | FIX_OrdRejReason_DuplicateOfAVerballyCommunicatedOrder -> "7" - | FIX_OrdRejReason_StaleOrder -> "8" - | FIX_OrdRejReason_TradeAlongRequired -> "9" - | FIX_OrdRejReason_InvalidInvestorID -> "10" - | FIX_OrdRejReason_UnsupportedOrderCharacteristic -> "11" - | FIX_OrdRejReason_IncorrectQuantity -> "13" - | FIX_OrdRejReason_IncorrectAllocatedQuantity -> "14" - | FIX_OrdRejReason_UnknownAccount -> "15" - | FIX_OrdRejReason_Other -> "99" - ) -;; - -let encode_OrdStatus (d) = - (match d with - | FIX_OrdStatus_New -> "0" - | FIX_OrdStatus_PartiallyFilled -> "1" - | FIX_OrdStatus_Filled -> "2" - | FIX_OrdStatus_DoneForDay -> "3" - | FIX_OrdStatus_Canceled -> "4" - | FIX_OrdStatus_PendingCancel -> "6" - | FIX_OrdStatus_Stopped -> "7" - | FIX_OrdStatus_Rejected -> "8" - | FIX_OrdStatus_Suspended -> "9" - | FIX_OrdStatus_PendingNew -> "A" - | FIX_OrdStatus_Calculated -> "B" - | FIX_OrdStatus_Expired -> "C" - | FIX_OrdStatus_AcceptedForBidding -> "D" - | FIX_OrdStatus_PendingReplace -> "E" - | FIX_OrdStatus_Replaced -> "5" - ) -;; - -let encode_OrdType (d) = - (match d with - | FIX_OrdType_Market -> "1" - | FIX_OrdType_Limit -> "2" - | FIX_OrdType_Stop -> "3" - | FIX_OrdType_StopLimit -> "4" - | FIX_OrdType_WithOrWithout -> "6" - | FIX_OrdType_LimitOrBetter -> "7" - | FIX_OrdType_LimitWithOrWithout -> "8" - | FIX_OrdType_OnBasis -> "9" - | FIX_OrdType_PreviouslyQuoted -> "D" - | FIX_OrdType_PreviouslyIndicated -> "E" - | FIX_OrdType_ForexSwap -> "G" - | FIX_OrdType_Funari -> "I" - | FIX_OrdType_MarketIfTouched -> "J" - | FIX_OrdType_MarketWithLeftOverAsLimit -> "K" - | FIX_OrdType_PreviousFundValuationPoint -> "L" - | FIX_OrdType_NextFundValuationPoint -> "M" - | FIX_OrdType_Pegged -> "P" - ) -;; - -let encode_OrderCapacity (d) = - (match d with - | FIX_OrderCapacity_Agency -> "A" - | FIX_OrderCapacity_Proprietary -> "G" - | FIX_OrderCapacity_Individual -> "I" - | FIX_OrderCapacity_Principal -> "P" - | FIX_OrderCapacity_RisklessPrincipal -> "R" - | FIX_OrderCapacity_AgentForOtherMember -> "W" - ) -;; - -let enncode_inner_OrderRestrictions (d) = - (match d with - | FIX_OrderRestrictions_ProgramTrade -> "1" - | FIX_OrderRestrictions_IndexArbitrage -> "2" - | FIX_OrderRestrictions_NonIndexArbitrage -> "3" - | FIX_OrderRestrictions_CompetingMarketMaker -> "4" - | FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInSecurity -> "5" - | FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInUnderlying -> "6" - | FIX_OrderRestrictions_ForeignEntity -> "7" - | FIX_OrderRestrictions_ExternalMarketParticipant -> "8" - | FIX_OrderRestrictions_ExternalInterConnectedMarketLinkage -> "9" - | FIX_OrderRestrictions_RisklessArbitrage -> "A" - ) -;; - -let encode_OrderRestrictions (d) = - list_to_split (List.map enncode_inner_OrderRestrictions d) ' ' -;; - -let encode_OwnerType (d) = - (match d with - | FIX_OwnerType_IndividualInvestor -> "1" - | FIX_OwnerType_PublicCompany -> "2" - | FIX_OwnerType_PrivateCompany -> "3" - | FIX_OwnerType_IndividualTrustee -> "4" - | FIX_OwnerType_CompanyTrustee -> "5" - | FIX_OwnerType_PensionPlan -> "6" - | FIX_OwnerType_CustodianUnderGiftsToMinorsAct -> "7" - | FIX_OwnerType_Trusts -> "8" - | FIX_OwnerType_Fiduciaries -> "9" - | FIX_OwnerType_NetworkingSubAccount -> "10" - | FIX_OwnerType_NonProfitOrganization -> "11" - | FIX_OwnerType_CorporateBody -> "12" - | FIX_OwnerType_Nominee -> "13" - ) -;; - -let encode_OwnershipType (d) = - (match d with - | FIX_OwnershipType_JointInvestors -> "J" - | FIX_OwnershipType_TenantsInCommon -> "T" - | FIX_OwnershipType_JointTrustees -> "2" - ) -;; - -let encode_PartyIDSource (d) = - (match d with - | FIX_PartyIDSource_BIC -> "B" - | FIX_PartyIDSource_GeneralIdentifier -> "C" - | FIX_PartyIDSource_Proprietary -> "D" - | FIX_PartyIDSource_ISOCountryCode -> "E" - | FIX_PartyIDSource_SettlementEntityLocation -> "F" - | FIX_PartyIDSource_MIC -> "G" - | FIX_PartyIDSource_CSDParticipant -> "H" - | FIX_PartyIDSource_KoreanInvestorID -> "1" - | FIX_PartyIDSource_TaiwaneseForeignInvestorID -> "2" - | FIX_PartyIDSource_TaiwaneseTradingAcct -> "3" - | FIX_PartyIDSource_MalaysianCentralDepository -> "4" - | FIX_PartyIDSource_ChineseInvestorID -> "5" - | FIX_PartyIDSource_UKNationalInsuranceOrPensionNumber -> "6" - | FIX_PartyIDSource_USSocialSecurityNumber -> "7" - | FIX_PartyIDSource_USEmployerOrTaxIDNumber -> "8" - | FIX_PartyIDSource_AustralianBusinessNumber -> "9" - | FIX_PartyIDSource_AustralianTaxFileNumber -> "A" - | FIX_PartyIDSource_ISITCAcronym -> "I" - ) -;; - -let encode_PartyRole (d) = - (match d with - | FIX_PartyRole_ExecutingFirm -> "1" - | FIX_PartyRole_BrokerOfCredit -> "2" - | FIX_PartyRole_ClientID -> "3" - | FIX_PartyRole_ClearingFirm -> "4" - | FIX_PartyRole_InvestorID -> "5" - | FIX_PartyRole_IntroducingFirm -> "6" - | FIX_PartyRole_EnteringFirm -> "7" - | FIX_PartyRole_Locate -> "8" - | FIX_PartyRole_FundManagerClientID -> "9" - | FIX_PartyRole_SettlementLocation -> "10" - | FIX_PartyRole_OrderOriginationTrader -> "11" - | FIX_PartyRole_ExecutingTrader -> "12" - | FIX_PartyRole_OrderOriginationFirm -> "13" - | FIX_PartyRole_GiveupClearingFirm -> "14" - | FIX_PartyRole_CorrespondantClearingFirm -> "15" - | FIX_PartyRole_ExecutingSystem -> "16" - | FIX_PartyRole_ContraFirm -> "17" - | FIX_PartyRole_ContraClearingFirm -> "18" - | FIX_PartyRole_SponsoringFirm -> "19" - | FIX_PartyRole_UnderlyingContraFirm -> "20" - | FIX_PartyRole_ClearingOrganization -> "21" - | FIX_PartyRole_Exchange -> "22" - | FIX_PartyRole_CustomerAccount -> "24" - | FIX_PartyRole_CorrespondentClearingOrganization -> "25" - | FIX_PartyRole_CorrespondentBroker -> "26" - | FIX_PartyRole_Buyer -> "27" - | FIX_PartyRole_Custodian -> "28" - | FIX_PartyRole_Intermediary -> "29" - | FIX_PartyRole_Agent -> "30" - | FIX_PartyRole_SubCustodian -> "31" - | FIX_PartyRole_Beneficiary -> "32" - | FIX_PartyRole_InterestedParty -> "33" - | FIX_PartyRole_RegulatoryBody -> "34" - | FIX_PartyRole_LiquidityProvider -> "35" - | FIX_PartyRole_EnteringTrader -> "36" - | FIX_PartyRole_ContraTrader -> "37" - | FIX_PartyRole_PositionAccount -> "38" - ) -;; - -let encode_PartySubIDType (d) = - (match d with - | FIX_PartySubIDType_Firm -> "1" - | FIX_PartySubIDType_Person -> "2" - | FIX_PartySubIDType_System -> "3" - | FIX_PartySubIDType_Application -> "4" - | FIX_PartySubIDType_FullLegalNameOfFirm -> "5" - | FIX_PartySubIDType_PostalAddress -> "6" - | FIX_PartySubIDType_PhoneNumber -> "7" - | FIX_PartySubIDType_EmailAddress -> "8" - | FIX_PartySubIDType_ContactName -> "9" - | FIX_PartySubIDType_SecuritiesAccountNumber -> "10" - | FIX_PartySubIDType_RegistrationNumber -> "11" - | FIX_PartySubIDType_RegisteredAddressForConfirmation -> "12" - | FIX_PartySubIDType_RegulatoryStatus -> "13" - | FIX_PartySubIDType_RegistrationName -> "14" - | FIX_PartySubIDType_CashAccountNumber -> "15" - | FIX_PartySubIDType_BIC -> "16" - | FIX_PartySubIDType_CSDParticipantMemberCode -> "17" - | FIX_PartySubIDType_RegisteredAddress -> "18" - | FIX_PartySubIDType_FundAccountName -> "19" - | FIX_PartySubIDType_TelexNumber -> "20" - | FIX_PartySubIDType_FaxNumber -> "21" - | FIX_PartySubIDType_SecuritiesAccountName -> "22" - | FIX_PartySubIDType_CashAccountName -> "23" - | FIX_PartySubIDType_Department -> "24" - | FIX_PartySubIDType_LocationDesk -> "25" - | FIX_PartySubIDType_PositionAccountType -> "26" - ) -;; - -let encode_PaymentMethod (d) = - (match d with - | FIX_PaymentMethod_CREST -> "1" - | FIX_PaymentMethod_NSCC -> "2" - | FIX_PaymentMethod_Euroclear -> "3" - | FIX_PaymentMethod_Clearstream -> "4" - | FIX_PaymentMethod_Cheque -> "5" - | FIX_PaymentMethod_TelegraphicTransfer -> "6" - | FIX_PaymentMethod_FedWire -> "7" - | FIX_PaymentMethod_DebitCard -> "8" - | FIX_PaymentMethod_DirectDebit -> "9" - | FIX_PaymentMethod_DirectCredit -> "10" - | FIX_PaymentMethod_CreditCard -> "11" - | FIX_PaymentMethod_ACHDebit -> "12" - | FIX_PaymentMethod_ACHCredit -> "13" - | FIX_PaymentMethod_BPAY -> "14" - | FIX_PaymentMethod_HighValueClearingSystem -> "15" - ) -;; - -let encode_PegLimitType (d) = - (match d with - | FIX_PegLimitType_OrBetter -> "0" - | FIX_PegLimitType_Strict -> "1" - | FIX_PegLimitType_OrWorse -> "2" - ) -;; - -let encode_PegMoveType (d) = - (match d with - | FIX_PegMoveType_Floating -> "0" - | FIX_PegMoveType_Fixed -> "1" - ) -;; - -let encode_PegOffsetType (d) = - (match d with - | FIX_PegOffsetType_Price -> "0" - | FIX_PegOffsetType_BasisPoints -> "1" - | FIX_PegOffsetType_Ticks -> "2" - | FIX_PegOffsetType_PriceTier -> "3" - ) -;; - -let encode_PegRoundDirection (d) = - (match d with - | FIX_PegRoundDirection_MoreAggressive -> "1" - | FIX_PegRoundDirection_MorePassive -> "2" - ) -;; - -let encode_PegScope (d) = - (match d with - | FIX_PegScope_Local -> "1" - | FIX_PegScope_National -> "2" - | FIX_PegScope_Global -> "3" - | FIX_PegScope_NationalExcludingLocal -> "4" - ) -;; - -let encode_PosAmtType (d) = - (match d with - | FIX_PosAmtType_FinalMarkToMarketAmount -> "FMTM" - | FIX_PosAmtType_IncrementalMarkToMarketAmount -> "IMTM" - | FIX_PosAmtType_TradeVariationAmount -> "TVAR" - | FIX_PosAmtType_StartOfDayMarkToMarketAmount -> "SMTM" - | FIX_PosAmtType_PremiumAmount -> "PREM" - | FIX_PosAmtType_CashResidualAmount -> "CRES" - | FIX_PosAmtType_CashAmount -> "CASH" - | FIX_PosAmtType_ValueAdjustedAmount -> "VADJ" - ) -;; - -let encode_PosMaintAction (d) = - (match d with - | FIX_PosMaintAction_New -> "1" - | FIX_PosMaintAction_Replace -> "2" - | FIX_PosMaintAction_Cancel -> "3" - ) -;; - -let encode_PosMaintResult (d) = - (match d with - | FIX_PosMaintResult_SuccessfulCompletion -> "0" - | FIX_PosMaintResult_Rejected -> "1" - | FIX_PosMaintResult_Other -> "99" - ) -;; - -let encode_PosMaintStatus (d) = - (match d with - | FIX_PosMaintStatus_Accepted -> "0" - | FIX_PosMaintStatus_AcceptedWithWarnings -> "1" - | FIX_PosMaintStatus_Rejected -> "2" - | FIX_PosMaintStatus_Completed -> "3" - | FIX_PosMaintStatus_CompletedWithWarnings -> "4" - ) -;; - -let encode_PosQtyStatus (d) = - (match d with - | FIX_PosQtyStatus_Submitted -> "0" - | FIX_PosQtyStatus_Accepted -> "1" - | FIX_PosQtyStatus_Rejected -> "2" - ) -;; - -let encode_PosReqResult (d) = - (match d with - | FIX_PosReqResult_ValidRequest -> "0" - | FIX_PosReqResult_InvalidOrUnsupportedRequest -> "1" - | FIX_PosReqResult_NoPositionsFoundThatMatchCriteria -> "2" - | FIX_PosReqResult_NotAuthorizedToRequestPositions -> "3" - | FIX_PosReqResult_RequestForPositionNotSupported -> "4" - | FIX_PosReqResult_Other -> "99" - ) -;; - -let encode_PosReqStatus (d) = - (match d with - | FIX_PosReqStatus_Completed -> "0" - | FIX_PosReqStatus_CompletedWithWarnings -> "1" - | FIX_PosReqStatus_Rejected -> "2" - ) -;; - -let encode_PosReqType (d) = - (match d with - | FIX_PosReqType_Positions -> "0" - | FIX_PosReqType_Trades -> "1" - | FIX_PosReqType_Exercises -> "2" - | FIX_PosReqType_Assignments -> "3" - ) -;; - -let encode_PosTransType (d) = - (match d with - | FIX_PosTransType_Exercise -> "1" - | FIX_PosTransType_DoNotExercise -> "2" - | FIX_PosTransType_PositionAdjustment -> "3" - | FIX_PosTransType_PositionChangeSubmission -> "4" - | FIX_PosTransType_Pledge -> "5" - ) -;; - -let encode_PosType (d) = - (match d with - | FIX_PosType_TransactionQuantity -> "TQ" - | FIX_PosType_IntraSpreadQty -> "IAS" - | FIX_PosType_InterSpreadQty -> "IES" - | FIX_PosType_EndOfDayQty -> "FIN" - | FIX_PosType_StartOfDayQty -> "SOD" - | FIX_PosType_OptionExerciseQty -> "EX" - | FIX_PosType_OptionAssignment -> "AS" - | FIX_PosType_TransactionFromExercise -> "TX" - | FIX_PosType_TransactionFromAssignment -> "TA" - | FIX_PosType_PitTradeQty -> "PIT" - | FIX_PosType_TransferTradeQty -> "TRF" - | FIX_PosType_ElectronicTradeQty -> "ETR" - | FIX_PosType_AllocationTradeQty -> "ALC" - | FIX_PosType_AdjustmentQty -> "PA" - | FIX_PosType_AsOfTradeQty -> "ASF" - | FIX_PosType_DeliveryQty -> "DLV" - | FIX_PosType_TotalTransactionQty -> "TOT" - | FIX_PosType_CrossMarginQty -> "XM" - | FIX_PosType_IntegralSplit -> "SPL" - ) -;; - -let encode_PositionEffect (d) = - (match d with - | FIX_PositionEffect_Open -> "O" - | FIX_PositionEffect_Close -> "C" - | FIX_PositionEffect_Rolled -> "R" - | FIX_PositionEffect_FIFO -> "F" - ) -;; - -let encode_PossDupFlag (d) = - (match d with - | FIX_PossDupFlag_PossibleDuplicate -> "Y" - | FIX_PossDupFlag_OriginalTransmission -> "N" - ) -;; - -let encode_PossResend (d) = - (match d with - | FIX_PossResend_PossibleResend -> "Y" - | FIX_PossResend_OriginalTransmission -> "N" - ) -;; - -let encode_PreallocMethod (d) = - (match d with - | FIX_PreallocMethod_ProRata -> "0" - | FIX_PreallocMethod_DoNotProRata -> "1" - ) -;; - -let encode_PreviouslyReported (d) = - (match d with - | FIX_PreviouslyReported_PerviouslyReportedToCounterparty -> "Y" - | FIX_PreviouslyReported_NotReportedToCounterparty -> "N" - ) -;; - -let encode_PriceType (d) = - (match d with - | FIX_PriceType_Percentage -> "1" - | FIX_PriceType_PerUnit -> "2" - | FIX_PriceType_FixedAmount -> "3" - | FIX_PriceType_Discount -> "4" - | FIX_PriceType_Premium -> "5" - | FIX_PriceType_Spread -> "6" - | FIX_PriceType_TEDPrice -> "7" - | FIX_PriceType_TEDYield -> "8" - | FIX_PriceType_Yield -> "9" - | FIX_PriceType_FixedCabinetTradePrice -> "10" - | FIX_PriceType_VariableCabinetTradePrice -> "11" - ) -;; - -let encode_PriorityIndicator (d) = - (match d with - | FIX_PriorityIndicator_PriorityUnchanged -> "0" - | FIX_PriorityIndicator_LostPriorityAsResultOfOrderChange -> "1" - ) -;; - -let encode_ProcessCode (d) = - (match d with - | FIX_ProcessCode_Regular -> "0" - | FIX_ProcessCode_SoftDollar -> "1" - | FIX_ProcessCode_StepIn -> "2" - | FIX_ProcessCode_StepOut -> "3" - | FIX_ProcessCode_SoftDollarStepIn -> "4" - | FIX_ProcessCode_SoftDollarStepOut -> "5" - | FIX_ProcessCode_PlanSponsor -> "6" - ) -;; - -let encode_Product (d) = - (match d with - | FIX_Product_AGENCY -> "1" - | FIX_Product_COMMODITY -> "2" - | FIX_Product_CORPORATE -> "3" - | FIX_Product_CURRENCY -> "4" - | FIX_Product_EQUITY -> "5" - | FIX_Product_GOVERNMENT -> "6" - | FIX_Product_INDEX -> "7" - | FIX_Product_LOAN -> "8" - | FIX_Product_MONEYMARKET -> "9" - | FIX_Product_MORTGAGE -> "10" - | FIX_Product_MUNICIPAL -> "11" - | FIX_Product_OTHER -> "12" - | FIX_Product_FINANCING -> "13" - ) -;; - -let encode_ProgRptReqs (d) = - (match d with - | FIX_ProgRptReqs_BuySideRequests -> "1" - | FIX_ProgRptReqs_SellSideSends -> "2" - | FIX_ProgRptReqs_RealTimeExecutionReports -> "3" - ) -;; - -let encode_PublishTrdIndicator (d) = - (match d with - | FIX_PublishTrdIndicator_ReportTrade -> "Y" - | FIX_PublishTrdIndicator_DoNotReportTrade -> "N" - ) -;; - -let encode_PutOrCall (d) = - (match d with - | FIX_PutOrCall_Put -> "0" - | FIX_PutOrCall_Call -> "1" - ) -;; - -let encode_QtyType (d) = - (match d with - | FIX_QtyType_Units -> "0" - | FIX_QtyType_Contracts -> "1" - ) -;; - -let encode_QuoteCancelType (d) = - (match d with - | FIX_QuoteCancelType_CancelForOneOrMoreSecurities -> "1" - | FIX_QuoteCancelType_CancelForSecurityType -> "2" - | FIX_QuoteCancelType_CancelForUnderlyingSecurity -> "3" - | FIX_QuoteCancelType_CancelAllQuotes -> "4" - ) -;; - -let enncode_inner_QuoteCondition (d) = - (match d with - | FIX_QuoteCondition_Open -> "A" - | FIX_QuoteCondition_Closed -> "B" - | FIX_QuoteCondition_ExchangeBest -> "C" - | FIX_QuoteCondition_ConsolidatedBest -> "D" - | FIX_QuoteCondition_Locked -> "E" - | FIX_QuoteCondition_Crossed -> "F" - | FIX_QuoteCondition_Depth -> "G" - | FIX_QuoteCondition_FastTrading -> "H" - | FIX_QuoteCondition_NonFirm -> "I" - ) -;; - -let encode_QuoteCondition (d) = - list_to_split (List.map enncode_inner_QuoteCondition d) ' ' -;; - -let encode_QuotePriceType (d) = - (match d with - | FIX_QuotePriceType_Percent -> "1" - | FIX_QuotePriceType_PerShare -> "2" - | FIX_QuotePriceType_FixedAmount -> "3" - | FIX_QuotePriceType_Discount -> "4" - | FIX_QuotePriceType_Premium -> "5" - | FIX_QuotePriceType_Spread -> "6" - | FIX_QuotePriceType_TEDPrice -> "7" - | FIX_QuotePriceType_TEDYield -> "8" - | FIX_QuotePriceType_YieldSpread -> "9" - | FIX_QuotePriceType_Yield -> "10" - ) -;; - -let encode_QuoteRejectReason (d) = - (match d with - | FIX_QuoteRejectReason_UnknownSymbol -> "1" - | FIX_QuoteRejectReason_Exchange -> "2" - | FIX_QuoteRejectReason_QuoteRequestExceedsLimit -> "3" - | FIX_QuoteRejectReason_TooLateToEnter -> "4" - | FIX_QuoteRejectReason_UnknownQuote -> "5" - | FIX_QuoteRejectReason_DuplicateQuote -> "6" - | FIX_QuoteRejectReason_InvalidBid -> "7" - | FIX_QuoteRejectReason_InvalidPrice -> "8" - | FIX_QuoteRejectReason_NotAuthorizedToQuoteSecurity -> "9" - | FIX_QuoteRejectReason_Other -> "99" - ) -;; - -let encode_QuoteRequestRejectReason (d) = - (match d with - | FIX_QuoteRequestRejectReason_UnknownSymbol -> "1" - | FIX_QuoteRequestRejectReason_Exchange -> "2" - | FIX_QuoteRequestRejectReason_QuoteRequestExceedsLimit -> "3" - | FIX_QuoteRequestRejectReason_TooLateToEnter -> "4" - | FIX_QuoteRequestRejectReason_InvalidPrice -> "5" - | FIX_QuoteRequestRejectReason_NotAuthorizedToRequestQuote -> "6" - | FIX_QuoteRequestRejectReason_NoMatchForInquiry -> "7" - | FIX_QuoteRequestRejectReason_NoMarketForInstrument -> "8" - | FIX_QuoteRequestRejectReason_NoInventory -> "9" - | FIX_QuoteRequestRejectReason_Pass -> "10" - | FIX_QuoteRequestRejectReason_Other -> "99" - ) -;; - -let encode_QuoteRequestType (d) = - (match d with - | FIX_QuoteRequestType_Manual -> "1" - | FIX_QuoteRequestType_Automatic -> "2" - ) -;; - -let encode_QuoteRespType (d) = - (match d with - | FIX_QuoteRespType_Hit -> "1" - | FIX_QuoteRespType_Counter -> "2" - | FIX_QuoteRespType_Expired -> "3" - | FIX_QuoteRespType_Cover -> "4" - | FIX_QuoteRespType_DoneAway -> "5" - | FIX_QuoteRespType_Pass -> "6" - ) -;; - -let encode_QuoteResponseLevel (d) = - (match d with - | FIX_QuoteResponseLevel_NoAcknowledgement -> "0" - | FIX_QuoteResponseLevel_AcknowledgeOnlyNegativeOrErroneousQuotes -> "1" - | FIX_QuoteResponseLevel_AcknowledgeEachQuoteMessage -> "2" - ) -;; - -let encode_QuoteStatus (d) = - (match d with - | FIX_QuoteStatus_Accepted -> "0" - | FIX_QuoteStatus_CancelForSymbol -> "1" - | FIX_QuoteStatus_CanceledForSecurityType -> "2" - | FIX_QuoteStatus_CanceledForUnderlying -> "3" - | FIX_QuoteStatus_CanceledAll -> "4" - | FIX_QuoteStatus_Rejected -> "5" - | FIX_QuoteStatus_RemovedFromMarket -> "6" - | FIX_QuoteStatus_Expired -> "7" - | FIX_QuoteStatus_Query -> "8" - | FIX_QuoteStatus_QuoteNotFound -> "9" - | FIX_QuoteStatus_Pending -> "10" - | FIX_QuoteStatus_Pass -> "11" - | FIX_QuoteStatus_LockedMarketWarning -> "12" - | FIX_QuoteStatus_CrossMarketWarning -> "13" - | FIX_QuoteStatus_CanceledDueToLockMarket -> "14" - | FIX_QuoteStatus_CanceledDueToCrossMarket -> "15" - ) -;; - -let encode_QuoteType (d) = - (match d with - | FIX_QuoteType_Indicative -> "0" - | FIX_QuoteType_Tradeable -> "1" - | FIX_QuoteType_RestrictedTradeable -> "2" - | FIX_QuoteType_Counter -> "3" - ) -;; - -let encode_RegistRejReasonCode (d) = - (match d with - | FIX_RegistRejReasonCode_InvalidAccountType -> "1" - | FIX_RegistRejReasonCode_InvalidTaxExemptType -> "2" - | FIX_RegistRejReasonCode_InvalidOwnershipType -> "3" - | FIX_RegistRejReasonCode_NoRegDetails -> "4" - | FIX_RegistRejReasonCode_InvalidRegSeqNo -> "5" - | FIX_RegistRejReasonCode_InvalidRegDetails -> "6" - | FIX_RegistRejReasonCode_InvalidMailingDetails -> "7" - | FIX_RegistRejReasonCode_InvalidMailingInstructions -> "8" - | FIX_RegistRejReasonCode_InvalidInvestorID -> "9" - | FIX_RegistRejReasonCode_InvalidInvestorIDSource -> "10" - | FIX_RegistRejReasonCode_InvalidDateOfBirth -> "11" - | FIX_RegistRejReasonCode_InvalidCountry -> "12" - | FIX_RegistRejReasonCode_InvalidDistribInstns -> "13" - | FIX_RegistRejReasonCode_InvalidPercentage -> "14" - | FIX_RegistRejReasonCode_InvalidPaymentMethod -> "15" - | FIX_RegistRejReasonCode_InvalidAccountName -> "16" - | FIX_RegistRejReasonCode_InvalidAgentCode -> "17" - | FIX_RegistRejReasonCode_InvalidAccountNum -> "18" - | FIX_RegistRejReasonCode_Other -> "99" - ) -;; - -let encode_RegistStatus (d) = - (match d with - | FIX_RegistStatus_Accepted -> "A" - | FIX_RegistStatus_Rejected -> "R" - | FIX_RegistStatus_Held -> "H" - | FIX_RegistStatus_Reminder -> "N" - ) -;; - -let encode_RegistTransType (d) = - (match d with - | FIX_RegistTransType_New -> "0" - | FIX_RegistTransType_Replace -> "1" - | FIX_RegistTransType_Cancel -> "2" - ) -;; - -let encode_ReportToExch (d) = - (match d with - | FIX_ReportToExch_ReceiverReports -> "Y" - | FIX_ReportToExch_SenderReports -> "N" - ) -;; - -let encode_ResetSeqNumFlag (d) = - (match d with - | FIX_ResetSeqNumFlag_Yes -> "Y" - | FIX_ResetSeqNumFlag_No -> "N" - ) -;; - -let encode_ResponseTransportType (d) = - (match d with - | FIX_ResponseTransportType_Inband -> "0" - | FIX_ResponseTransportType_OutOfBand -> "1" - ) -;; - -let encode_RoundingDirection (d) = - (match d with - | FIX_RoundingDirection_RoundToNearest -> "0" - | FIX_RoundingDirection_RoundDown -> "1" - | FIX_RoundingDirection_RoundUp -> "2" - ) -;; - -let encode_RoutingType (d) = - (match d with - | FIX_RoutingType_TargetFirm -> "1" - | FIX_RoutingType_TargetList -> "2" - | FIX_RoutingType_BlockFirm -> "3" - | FIX_RoutingType_BlockList -> "4" - ) -;; - -let enncode_inner_Scope (d) = - (match d with - | FIX_Scope_LocalMarket -> "1" - | FIX_Scope_National -> "2" - | FIX_Scope_Global -> "3" - ) -;; - -let encode_Scope (d) = - list_to_split (List.map enncode_inner_Scope d) ' ' -;; - -let encode_SecurityIDSource (d) = - (match d with - | FIX_SecurityIDSource_CUSIP -> "1" - | FIX_SecurityIDSource_SEDOL -> "2" - | FIX_SecurityIDSource_QUIK -> "3" - | FIX_SecurityIDSource_ISINNumber -> "4" - | FIX_SecurityIDSource_RICCode -> "5" - | FIX_SecurityIDSource_ISOCurrencyCode -> "6" - | FIX_SecurityIDSource_ISOCountryCode -> "7" - | FIX_SecurityIDSource_ExchangeSymbol -> "8" - | FIX_SecurityIDSource_ConsolidatedTapeAssociation -> "9" - | FIX_SecurityIDSource_BloombergSymbol -> "A" - | FIX_SecurityIDSource_Wertpapier -> "B" - | FIX_SecurityIDSource_Dutch -> "C" - | FIX_SecurityIDSource_Valoren -> "D" - | FIX_SecurityIDSource_Sicovam -> "E" - | FIX_SecurityIDSource_Belgian -> "F" - | FIX_SecurityIDSource_Common -> "G" - | FIX_SecurityIDSource_ClearingHouse -> "H" - | FIX_SecurityIDSource_ISDAFpMLSpecification -> "I" - | FIX_SecurityIDSource_OptionPriceReportingAuthority -> "J" - ) -;; - -let encode_SecurityListRequestType (d) = - (match d with - | FIX_SecurityListRequestType_Symbol -> "0" - | FIX_SecurityListRequestType_SecurityTypeAnd -> "1" - | FIX_SecurityListRequestType_Product -> "2" - | FIX_SecurityListRequestType_TradingSessionID -> "3" - | FIX_SecurityListRequestType_AllSecurities -> "4" - ) -;; - -let encode_SecurityRequestResult (d) = - (match d with - | FIX_SecurityRequestResult_ValidRequest -> "0" - | FIX_SecurityRequestResult_InvalidOrUnsupportedRequest -> "1" - | FIX_SecurityRequestResult_NoInstrumentsFound -> "2" - | FIX_SecurityRequestResult_NotAuthorizedToRetrieveInstrumentData -> "3" - | FIX_SecurityRequestResult_InstrumentDataTemporarilyUnavailable -> "4" - | FIX_SecurityRequestResult_RequestForInstrumentDataNotSupported -> "5" - ) -;; - -let encode_SecurityRequestType (d) = - (match d with - | FIX_SecurityRequestType_RequestSecurityIdentityAndSpecifications -> "0" - | FIX_SecurityRequestType_RequestSecurityIdentityForSpecifications -> "1" - | FIX_SecurityRequestType_RequestListSecurityTypes -> "2" - | FIX_SecurityRequestType_RequestListSecurities -> "3" - ) -;; - -let encode_SecurityResponseType (d) = - (match d with - | FIX_SecurityResponseType_AcceptAsIs -> "1" - | FIX_SecurityResponseType_AcceptWithRevisions -> "2" - | FIX_SecurityResponseType_RejectSecurityProposal -> "5" - | FIX_SecurityResponseType_CannotMatchSelectionCriteria -> "6" - ) -;; - -let encode_SecurityTradingStatus (d) = - (match d with - | FIX_SecurityTradingStatus_OpeningDelay -> "1" - | FIX_SecurityTradingStatus_TradingHalt -> "2" - | FIX_SecurityTradingStatus_Resume -> "3" - | FIX_SecurityTradingStatus_NoOpen -> "4" - | FIX_SecurityTradingStatus_PriceIndication -> "5" - | FIX_SecurityTradingStatus_TradingRangeIndication -> "6" - | FIX_SecurityTradingStatus_MarketImbalanceBuy -> "7" - | FIX_SecurityTradingStatus_MarketImbalanceSell -> "8" - | FIX_SecurityTradingStatus_MarketOnCloseImbalanceBuy -> "9" - | FIX_SecurityTradingStatus_MarketOnCloseImbalanceSell -> "10" - | FIX_SecurityTradingStatus_NoMarketImbalance -> "12" - | FIX_SecurityTradingStatus_NoMarketOnCloseImbalance -> "13" - | FIX_SecurityTradingStatus_ITSPreOpening -> "14" - | FIX_SecurityTradingStatus_NewPriceIndication -> "15" - | FIX_SecurityTradingStatus_TradeDisseminationTime -> "16" - | FIX_SecurityTradingStatus_ReadyToTrade -> "17" - | FIX_SecurityTradingStatus_NotAvailableForTrading -> "18" - | FIX_SecurityTradingStatus_NotTradedOnThisMarket -> "19" - | FIX_SecurityTradingStatus_UnknownOrInvalid -> "20" - | FIX_SecurityTradingStatus_PreOpen -> "21" - | FIX_SecurityTradingStatus_OpeningRotation -> "22" - | FIX_SecurityTradingStatus_FastMarket -> "23" - ) -;; - -let encode_SecurityType (d) = - (match d with - | FIX_SecurityType_Future -> "FUT" - | FIX_SecurityType_Option -> "OPT" - | FIX_SecurityType_EuroSupranationalCoupons -> "EUSUPRA" - | FIX_SecurityType_FederalAgencyCoupon -> "FAC" - | FIX_SecurityType_FederalAgencyDiscountNote -> "FADN" - | FIX_SecurityType_PrivateExportFunding -> "PEF" - | FIX_SecurityType_USDSupranationalCoupons -> "SUPRA" - | FIX_SecurityType_CorporateBond -> "CORP" - | FIX_SecurityType_CorporatePrivatePlacement -> "CPP" - | FIX_SecurityType_ConvertibleBond -> "CB" - | FIX_SecurityType_DualCurrency -> "DUAL" - | FIX_SecurityType_EuroCorporateBond -> "EUCORP" - | FIX_SecurityType_IndexedLinked -> "XLINKD" - | FIX_SecurityType_StructuredNotes -> "STRUCT" - | FIX_SecurityType_YankeeCorporateBond -> "YANK" - | FIX_SecurityType_ForeignExchangeContract -> "FOR" - | FIX_SecurityType_CommonStock -> "CS" - | FIX_SecurityType_PreferredStock -> "PS" - | FIX_SecurityType_BradyBond -> "BRADY" - | FIX_SecurityType_EuroSovereigns -> "EUSOV" - | FIX_SecurityType_USTreasuryBond -> "TBOND" - | FIX_SecurityType_InterestStripFromAnyBondOrNote -> "TINT" - | FIX_SecurityType_TreasuryInflationProtectedSecurities -> "TIPS" - | FIX_SecurityType_PrincipalStripOfACallableBondOrNote -> "TCAL" - | FIX_SecurityType_PrincipalStripFromANonCallableBondOrNote -> "TPRN" - | FIX_SecurityType_USTreasuryNoteOld -> "UST" - | FIX_SecurityType_USTreasuryBillOld -> "USTB" - | FIX_SecurityType_USTreasuryNote -> "TNOTE" - | FIX_SecurityType_USTreasuryBill -> "TBILL" - | FIX_SecurityType_Repurchase -> "REPO" - | FIX_SecurityType_Forward -> "FORWARD" - | FIX_SecurityType_BuySellback -> "BUYSELL" - | FIX_SecurityType_SecuritiesLoan -> "SECLOAN" - | FIX_SecurityType_SecuritiesPledge -> "SECPLEDGE" - | FIX_SecurityType_TermLoan -> "TERM" - | FIX_SecurityType_RevolverLoan -> "RVLV" - | FIX_SecurityType_Revolver -> "RVLVTRM" - | FIX_SecurityType_BridgeLoan -> "BRIDGE" - | FIX_SecurityType_LetterOfCredit -> "LOFC" - | FIX_SecurityType_SwingLineFacility -> "SWING" - | FIX_SecurityType_DebtorInPossession -> "DINP" - | FIX_SecurityType_Defaulted -> "DEFLTED" - | FIX_SecurityType_Withdrawn -> "WITHDRN" - | FIX_SecurityType_Replaced -> "REPLACD" - | FIX_SecurityType_Matured -> "MATURED" - | FIX_SecurityType_Amended -> "AMENDED" - | FIX_SecurityType_Retired -> "RETIRED" - | FIX_SecurityType_BankersAcceptance -> "BA" - | FIX_SecurityType_BankNotes -> "BN" - | FIX_SecurityType_BillOfExchanges -> "BOX" - | FIX_SecurityType_CertificateOfDeposit -> "CD" - | FIX_SecurityType_CallLoans -> "CL" - | FIX_SecurityType_CommercialPaper -> "CP" - | FIX_SecurityType_DepositNotes -> "DN" - | FIX_SecurityType_EuroCertificateOfDeposit -> "EUCD" - | FIX_SecurityType_EuroCommercialPaper -> "EUCP" - | FIX_SecurityType_LiquidityNote -> "LQN" - | FIX_SecurityType_MediumTermNotes -> "MTN" - | FIX_SecurityType_Overnight -> "ONITE" - | FIX_SecurityType_PromissoryNote -> "PN" - | FIX_SecurityType_PlazosFijos -> "PZFJ" - | FIX_SecurityType_ShortTermLoanNote -> "STN" - | FIX_SecurityType_TimeDeposit -> "TD" - | FIX_SecurityType_ExtendedCommNote -> "XCN" - | FIX_SecurityType_YankeeCertificateOfDeposit -> "YCD" - | FIX_SecurityType_AssetBackedSecurities -> "ABS" - | FIX_SecurityType_Corp -> "CMBS" - | FIX_SecurityType_CollateralizedMortgageObligation -> "CMO" - | FIX_SecurityType_IOETTEMortgage -> "IET" - | FIX_SecurityType_MortgageBackedSecurities -> "MBS" - | FIX_SecurityType_MortgageInterestOnly -> "MIO" - | FIX_SecurityType_MortgagePrincipalOnly -> "MPO" - | FIX_SecurityType_MortgagePrivatePlacement -> "MPP" - | FIX_SecurityType_MiscellaneousPassThrough -> "MPT" - | FIX_SecurityType_Pfandbriefe -> "PFAND" - | FIX_SecurityType_ToBeAnnounced -> "TBA" - | FIX_SecurityType_OtherAnticipationNotes -> "AN" - | FIX_SecurityType_CertificateOfObligation -> "COFO" - | FIX_SecurityType_CertificateOfParticipation -> "COFP" - | FIX_SecurityType_GeneralObligationBonds -> "GO" - | FIX_SecurityType_MandatoryTender -> "MT" - | FIX_SecurityType_RevenueAnticipationNote -> "RAN" - | FIX_SecurityType_RevenueBonds -> "REV" - | FIX_SecurityType_SpecialAssessment -> "SPCLA" - | FIX_SecurityType_SpecialObligation -> "SPCLO" - | FIX_SecurityType_SpecialTax -> "SPCLT" - | FIX_SecurityType_TaxAnticipationNote -> "TAN" - | FIX_SecurityType_TaxAllocation -> "TAXA" - | FIX_SecurityType_TaxExemptCommercialPaper -> "TECP" - | FIX_SecurityType_TaxRevenueAnticipationNote -> "TRAN" - | FIX_SecurityType_VariableRateDemandNote -> "VRDN" - | FIX_SecurityType_Warrant -> "WAR" - | FIX_SecurityType_MutualFund -> "MF" - | FIX_SecurityType_MultilegInstrument -> "MLEG" - | FIX_SecurityType_NoSecurityType -> "NONE" - ) -;; - -let encode_SettlCurrFxRateCalc (d) = - (match d with - | FIX_SettlCurrFxRateCalc_Multiply -> "M" - | FIX_SettlCurrFxRateCalc_Divide -> "D" - ) -;; - -let encode_SettlDeliveryType (d) = - (match d with - | FIX_SettlDeliveryType_Versus -> "0" - | FIX_SettlDeliveryType_Free -> "1" - | FIX_SettlDeliveryType_TriParty -> "2" - | FIX_SettlDeliveryType_HoldInCustody -> "3" - ) -;; - -let encode_SettlInstMode (d) = - (match d with - | FIX_SettlInstMode_StandingInstructionsProvided -> "1" - | FIX_SettlInstMode_SpecificOrderForASingleAccount -> "4" - | FIX_SettlInstMode_RequestReject -> "5" - ) -;; - -let encode_SettlInstReqRejCode (d) = - (match d with - | FIX_SettlInstReqRejCode_UnableToProcessRequest -> "0" - | FIX_SettlInstReqRejCode_UnknownAccount -> "1" - | FIX_SettlInstReqRejCode_NoMatchingSettlementInstructionsFound -> "2" - | FIX_SettlInstReqRejCode_Other -> "99" - ) -;; - -let encode_SettlInstSource (d) = - (match d with - | FIX_SettlInstSource_BrokerCredit -> "1" - | FIX_SettlInstSource_Institution -> "2" - | FIX_SettlInstSource_Investor -> "3" + | FIX_ExecInst_DoNotReduce -> "F" + | FIX_ExecInst_AllOrNone -> "G" + | FIX_ExecInst_ReinstateOnSystemFailure -> "H" + | FIX_ExecInst_InstitutionsOnly -> "I" + | FIX_ExecInst_ReinstateOnTradingHalt -> "J" + | FIX_ExecInst_CancelOnTradingHalt -> "K" + | FIX_ExecInst_LastPeg -> "L" + | FIX_ExecInst_MidPricePeg -> "M" + | FIX_ExecInst_NonNegotiable -> "N" + | FIX_ExecInst_OpeningPeg -> "O" + | FIX_ExecInst_MarketPeg -> "P" + | FIX_ExecInst_CancelOnSystemFailure -> "Q" + | FIX_ExecInst_PrimaryPeg -> "R" + | FIX_ExecInst_Suspend -> "S" + | FIX_ExecInst_CustomerDisplayInstruction -> "U" + | FIX_ExecInst_Netting -> "V" + | FIX_ExecInst_PegToVWAP -> "W" + | FIX_ExecInst_TradeAlong -> "X" + | FIX_ExecInst_TryToStop -> "Y" + | FIX_ExecInst_CancelIfNotBest -> "Z" + | FIX_ExecInst_TrailingStopPeg -> "a" + | FIX_ExecInst_StrictLimit -> "b" + | FIX_ExecInst_IgnorePriceValidityChecks -> "c" + | FIX_ExecInst_PegToLimitPrice -> "d" + | FIX_ExecInst_WorkToTargetStrategy -> "e" + | FIX_INVALID_ExecInst s -> s ) ;; -let encode_SettlInstTransType (d) = - (match d with - | FIX_SettlInstTransType_New -> "N" - | FIX_SettlInstTransType_Cancel -> "C" - | FIX_SettlInstTransType_Replace -> "R" - | FIX_SettlInstTransType_Restate -> "T" - ) +let encode_ExecInst (d) = + list_to_split (List.map encode_inner_ExecInst d) ' ' ;; -let encode_SettlPriceType (d) = +let encode_ExecType (d) = (match d with - | FIX_SettlPriceType_Final -> "1" - | FIX_SettlPriceType_Theoretical -> "2" + | FIX_ExecType_New -> "0" + | FIX_ExecType_DoneForDay -> "3" + | FIX_ExecType_Canceled -> "4" + | FIX_ExecType_Replaced -> "5" + | FIX_ExecType_PendingCancel -> "6" + | FIX_ExecType_Stopped -> "7" + | FIX_ExecType_Rejected -> "8" + | FIX_ExecType_Suspended -> "9" + | FIX_ExecType_PendingNew -> "A" + | FIX_ExecType_Calculated -> "B" + | FIX_ExecType_Expired -> "C" + | FIX_ExecType_Restated -> "D" + | FIX_ExecType_PendingReplace -> "E" + | FIX_ExecType_Trade -> "F" + | FIX_ExecType_TradeCorrect -> "G" + | FIX_ExecType_TradeCancel -> "H" + | FIX_ExecType_OrderStatus -> "I" + | FIX_INVALID_ExecType s -> s ) ;; -let encode_SettlSessID (d) = +let encode_OrdStatus (d) = (match d with - | FIX_SettlSessID_Intraday -> "ITD" - | FIX_SettlSessID_RegularTradingHours -> "RTH" - | FIX_SettlSessID_ElectronicTradingHours -> "ETH" + | FIX_OrdStatus_New -> "0" + | FIX_OrdStatus_PartiallyFilled -> "1" + | FIX_OrdStatus_Filled -> "2" + | FIX_OrdStatus_DoneForDay -> "3" + | FIX_OrdStatus_Canceled -> "4" + | FIX_OrdStatus_PendingCancel -> "6" + | FIX_OrdStatus_Stopped -> "7" + | FIX_OrdStatus_Rejected -> "8" + | FIX_OrdStatus_Suspended -> "9" + | FIX_OrdStatus_PendingNew -> "A" + | FIX_OrdStatus_Calculated -> "B" + | FIX_OrdStatus_Expired -> "C" + | FIX_OrdStatus_AcceptedForBidding -> "D" + | FIX_OrdStatus_PendingReplace -> "E" + | FIX_OrdStatus_Replaced -> "5" + | FIX_INVALID_OrdStatus s -> s ) ;; -let encode_SettlType (d) = +let encode_OrdType (d) = (match d with - | FIX_SettlType_Regular -> "0" - | FIX_SettlType_Cash -> "1" - | FIX_SettlType_NextDay -> "2" - | FIX_SettlType_TPlus2 -> "3" - | FIX_SettlType_TPlus3 -> "4" - | FIX_SettlType_TPlus4 -> "5" - | FIX_SettlType_Future -> "6" - | FIX_SettlType_WhenAndIfIssued -> "7" - | FIX_SettlType_SellersOption -> "8" - | FIX_SettlType_TPlus5 -> "9" + | FIX_OrdType_Market -> "1" + | FIX_OrdType_Limit -> "2" + | FIX_OrdType_Stop -> "3" + | FIX_OrdType_StopLimit -> "4" + | FIX_OrdType_WithOrWithout -> "6" + | FIX_OrdType_LimitOrBetter -> "7" + | FIX_OrdType_LimitWithOrWithout -> "8" + | FIX_OrdType_OnBasis -> "9" + | FIX_OrdType_PreviouslyQuoted -> "D" + | FIX_OrdType_PreviouslyIndicated -> "E" + | FIX_OrdType_ForexSwap -> "G" + | FIX_OrdType_Funari -> "I" + | FIX_OrdType_MarketIfTouched -> "J" + | FIX_OrdType_MarketWithLeftOverAsLimit -> "K" + | FIX_OrdType_PreviousFundValuationPoint -> "L" + | FIX_OrdType_NextFundValuationPoint -> "M" + | FIX_OrdType_Pegged -> "P" + | FIX_OrdType_StopSpread -> "s" + | FIX_INVALID_OrdType s -> s ) ;; -let encode_ShortSaleReason (d) = +let encode_PartySubIDType (d) = (match d with - | FIX_ShortSaleReason_DealerSoldShort -> "0" - | FIX_ShortSaleReason_DealerSoldShortExempt -> "1" - | FIX_ShortSaleReason_SellingCustomerSoldShort -> "2" - | FIX_ShortSaleReason_SellingCustomerSoldShortExempt -> "3" - | FIX_ShortSaleReason_QualifiedServiceRepresentative -> "4" - | FIX_ShortSaleReason_QSROrAGUContraSideSoldShortExempt -> "5" + | FIX_PartySubIDType_Firm -> "1" + | FIX_PartySubIDType_Person -> "2" + | FIX_PartySubIDType_System -> "3" + | FIX_PartySubIDType_Application -> "4" + | FIX_PartySubIDType_FullLegalNameOfFirm -> "5" + | FIX_PartySubIDType_PostalAddress -> "6" + | FIX_PartySubIDType_PhoneNumber -> "7" + | FIX_PartySubIDType_EmailAddress -> "8" + | FIX_PartySubIDType_ContactName -> "9" + | FIX_PartySubIDType_SecuritiesAccountNumber -> "10" + | FIX_PartySubIDType_RegistrationNumber -> "11" + | FIX_PartySubIDType_RegisteredAddressForConfirmation -> "12" + | FIX_PartySubIDType_RegulatoryStatus -> "13" + | FIX_PartySubIDType_RegistrationName -> "14" + | FIX_PartySubIDType_CashAccountNumber -> "15" + | FIX_PartySubIDType_BIC -> "16" + | FIX_PartySubIDType_CSDParticipantMemberCode -> "17" + | FIX_PartySubIDType_RegisteredAddress -> "18" + | FIX_PartySubIDType_FundAccountName -> "19" + | FIX_PartySubIDType_TelexNumber -> "20" + | FIX_PartySubIDType_FaxNumber -> "21" + | FIX_PartySubIDType_SecuritiesAccountName -> "22" + | FIX_PartySubIDType_CashAccountName -> "23" + | FIX_PartySubIDType_Department -> "24" + | FIX_PartySubIDType_LocationDesk -> "25" + | FIX_PartySubIDType_PositionAccountType -> "26" + | FIX_INVALID_PartySubIDType s -> s ) ;; @@ -2394,465 +174,8 @@ let encode_Side (d) = | FIX_Side_Redeem -> "E" | FIX_Side_Lend -> "F" | FIX_Side_Borrow -> "G" + | FIX_INVALID_Side s -> s ) ;; -let encode_SideMultiLegReportingType (d) = - (match d with - | FIX_SideMultiLegReportingType_SingleSecurity -> "1" - | FIX_SideMultiLegReportingType_IndividualLegOfAMultilegSecurity -> "2" - | FIX_SideMultiLegReportingType_MultilegSecurity -> "3" - ) -;; - -let encode_SideValueInd (d) = - (match d with - | FIX_SideValueInd_SideValue1 -> "1" - | FIX_SideValueInd_SideValue2 -> "2" - ) -;; - -let encode_SolicitedFlag (d) = - (match d with - | FIX_SolicitedFlag_WasSolicited -> "Y" - | FIX_SolicitedFlag_WasNotSolicited -> "N" - ) -;; - -let encode_StandInstDbType (d) = - (match d with - | FIX_StandInstDbType_Other -> "0" - | FIX_StandInstDbType_DTCSID -> "1" - | FIX_StandInstDbType_ThomsonALERT -> "2" - | FIX_StandInstDbType_AGlobalCustodian -> "3" - | FIX_StandInstDbType_AccountNet -> "4" - ) -;; - -let encode_StatusValue (d) = - (match d with - | FIX_StatusValue_Connected -> "1" - | FIX_StatusValue_NotConnectedUnexpected -> "2" - | FIX_StatusValue_NotConnectedExpected -> "3" - | FIX_StatusValue_InProcess -> "4" - ) -;; - -let encode_StipulationType (d) = - (match d with - | FIX_StipulationType_AlternativeMinimumTax -> "AMT" - | FIX_StipulationType_AutoReinvestment -> "AUTOREINV" - | FIX_StipulationType_BankQualified -> "BANKQUAL" - | FIX_StipulationType_BargainConditions -> "BGNCON" - | FIX_StipulationType_CouponRange -> "COUPON" - | FIX_StipulationType_ISOCurrencyCode -> "CURRENCY" - | FIX_StipulationType_CustomStart -> "CUSTOMDATE" - | FIX_StipulationType_Geographics -> "GEOG" - | FIX_StipulationType_ValuationDiscount -> "HAIRCUT" - | FIX_StipulationType_Insured -> "INSURED" - | FIX_StipulationType_IssueDate -> "ISSUE" - | FIX_StipulationType_Issuer -> "ISSUER" - | FIX_StipulationType_IssueSizeRange -> "ISSUESIZE" - | FIX_StipulationType_LookbackDays -> "LOOKBACK" - | FIX_StipulationType_ExplicitLotIdentifier -> "LOT" - | FIX_StipulationType_LotVariance -> "LOTVAR" - | FIX_StipulationType_MaturityYearAndMonth -> "MAT" - | FIX_StipulationType_MaturityRange -> "MATURITY" - | FIX_StipulationType_MaximumSubstitutions -> "MAXSUBS" - | FIX_StipulationType_MinimumQuantity -> "MINQTY" - | FIX_StipulationType_MinimumIncrement -> "MININCR" - | FIX_StipulationType_MinimumDenomination -> "MINDNOM" - | FIX_StipulationType_PaymentFrequency -> "PAYFREQ" - | FIX_StipulationType_NumberOfPieces -> "PIECES" - | FIX_StipulationType_PoolsMaximum -> "PMAX" - | FIX_StipulationType_PoolsPerMillion -> "PPM" - | FIX_StipulationType_PoolsPerLot -> "PPL" - | FIX_StipulationType_PoolsPerTrade -> "PPT" - | FIX_StipulationType_PriceRange -> "PRICE" - | FIX_StipulationType_PricingFrequency -> "PRICEFREQ" - | FIX_StipulationType_ProductionYear -> "PROD" - | FIX_StipulationType_CallProtection -> "PROTECT" - | FIX_StipulationType_Purpose -> "PURPOSE" - | FIX_StipulationType_BenchmarkPriceSource -> "PXSOURCE" - | FIX_StipulationType_RatingSourceAndRange -> "RATING" - | FIX_StipulationType_TypeOfRedemption -> "REDEMPTION" - | FIX_StipulationType_Restricted -> "RESTRICTED" - | FIX_StipulationType_MarketSector -> "SECTOR" - | FIX_StipulationType_SecurityTypeIncludedOrExcluded -> "SECTYPE" - | FIX_StipulationType_Structure -> "STRUCT" - | FIX_StipulationType_SubstitutionsFrequency -> "SUBSFREQ" - | FIX_StipulationType_SubstitutionsLeft -> "SUBSLEFT" - | FIX_StipulationType_FreeformText -> "TEXT" - | FIX_StipulationType_TradeVariance -> "TRDVAR" - | FIX_StipulationType_WeightedAverageCoupon -> "WAC" - | FIX_StipulationType_WeightedAverageLifeCoupon -> "WAL" - | FIX_StipulationType_WeightedAverageLoanAge -> "WALA" - | FIX_StipulationType_WeightedAverageMaturity -> "WAM" - | FIX_StipulationType_WholePool -> "WHOLE" - | FIX_StipulationType_YieldRange -> "YIELD" - ) -;; - -let encode_SubscriptionRequestType (d) = - (match d with - | FIX_SubscriptionRequestType_Snapshot -> "0" - | FIX_SubscriptionRequestType_SnapshotAndUpdates -> "1" - | FIX_SubscriptionRequestType_DisablePreviousSnapshot -> "2" - ) -;; - -let encode_TargetStrategy (d) = - (match d with - | FIX_TargetStrategy_VWAP -> "1" - | FIX_TargetStrategy_Participate -> "2" - | FIX_TargetStrategy_MininizeMarketImpact -> "3" - ) -;; - -let encode_TaxAdvantageType (d) = - (match d with - | FIX_TaxAdvantageType_FIXNone -> "0" - | FIX_TaxAdvantageType_MaxiISA -> "1" - | FIX_TaxAdvantageType_TESSA -> "2" - | FIX_TaxAdvantageType_MiniCashISA -> "3" - | FIX_TaxAdvantageType_MiniStocksAndSharesISA -> "4" - | FIX_TaxAdvantageType_MiniInsuranceISA -> "5" - | FIX_TaxAdvantageType_CurrentYearPayment -> "6" - | FIX_TaxAdvantageType_PriorYearPayment -> "7" - | FIX_TaxAdvantageType_AssetTransfer -> "8" - | FIX_TaxAdvantageType_EmployeePriorYear -> "9" - | FIX_TaxAdvantageType_EmployeeCurrentYear -> "10" - | FIX_TaxAdvantageType_EmployerPriorYear -> "11" - | FIX_TaxAdvantageType_EmployerCurrentYear -> "12" - | FIX_TaxAdvantageType_NonFundPrototypeIRA -> "13" - | FIX_TaxAdvantageType_NonFundQualifiedPlan -> "14" - | FIX_TaxAdvantageType_DefinedContributionPlan -> "15" - | FIX_TaxAdvantageType_IRA -> "16" - | FIX_TaxAdvantageType_IRARollover -> "17" - | FIX_TaxAdvantageType_KEOGH -> "18" - | FIX_TaxAdvantageType_ProfitSharingPlan -> "19" - | FIX_TaxAdvantageType_US401K -> "20" - | FIX_TaxAdvantageType_SelfDirectedIRA -> "21" - | FIX_TaxAdvantageType_US403b -> "22" - | FIX_TaxAdvantageType_US457 -> "23" - | FIX_TaxAdvantageType_RothIRAPrototype -> "24" - | FIX_TaxAdvantageType_RothIRANonPrototype -> "25" - | FIX_TaxAdvantageType_RothConversionIRAPrototype -> "26" - | FIX_TaxAdvantageType_RothConversionIRANonPrototype -> "27" - | FIX_TaxAdvantageType_EducationIRAPrototype -> "28" - | FIX_TaxAdvantageType_EducationIRANonPrototype -> "29" - ) -;; - -let encode_TerminationType (d) = - (match d with - | FIX_TerminationType_Overnight -> "1" - | FIX_TerminationType_Term -> "2" - | FIX_TerminationType_Flexible -> "3" - | FIX_TerminationType_Open -> "4" - ) -;; - -let encode_TestMessageIndicator (d) = - (match d with - | FIX_TestMessageIndicator_True -> "Y" - | FIX_TestMessageIndicator_Fales -> "N" - ) -;; - -let encode_TickDirection (d) = - (match d with - | FIX_TickDirection_PlusTick -> "0" - | FIX_TickDirection_ZeroPlusTick -> "1" - | FIX_TickDirection_MinusTick -> "2" - | FIX_TickDirection_ZeroMinusTick -> "3" - ) -;; - -let encode_TimeInForce (d) = - (match d with - | FIX_TimeInForce_Day -> "0" - | FIX_TimeInForce_GoodTillCancel -> "1" - | FIX_TimeInForce_AtTheOpening -> "2" - | FIX_TimeInForce_ImmediateOrCancel -> "3" - | FIX_TimeInForce_FillOrKill -> "4" - | FIX_TimeInForce_GoodTillCrossing -> "5" - | FIX_TimeInForce_GoodTillDate -> "6" - | FIX_TimeInForce_AtTheClose -> "7" - ) -;; - -let encode_TradSesMethod (d) = - (match d with - | FIX_TradSesMethod_Electronic -> "1" - | FIX_TradSesMethod_OpenOutcry -> "2" - | FIX_TradSesMethod_TwoParty -> "3" - ) -;; - -let encode_TradSesMode (d) = - (match d with - | FIX_TradSesMode_Testing -> "1" - | FIX_TradSesMode_Simulated -> "2" - | FIX_TradSesMode_Production -> "3" - ) -;; - -let encode_TradSesStatus (d) = - (match d with - | FIX_TradSesStatus_Unknown -> "0" - | FIX_TradSesStatus_Halted -> "1" - | FIX_TradSesStatus_Open -> "2" - | FIX_TradSesStatus_Closed -> "3" - | FIX_TradSesStatus_PreOpen -> "4" - | FIX_TradSesStatus_PreClose -> "5" - | FIX_TradSesStatus_RequestRejected -> "6" - ) -;; - -let encode_TradSesStatusRejReason (d) = - (match d with - | FIX_TradSesStatusRejReason_UnknownOrInvalidTradingSessionID -> "1" - | FIX_TradSesStatusRejReason_Other -> "99" - ) -;; - -let encode_TradeAllocIndicator (d) = - (match d with - | FIX_TradeAllocIndicator_AllocationNotRequired -> "0" - | FIX_TradeAllocIndicator_AllocationRequired -> "1" - | FIX_TradeAllocIndicator_UseAllocationProvidedWithTheTrade -> "2" - ) -;; - -let enncode_inner_TradeCondition (d) = - (match d with - | FIX_TradeCondition_Cash -> "A" - | FIX_TradeCondition_AveragePriceTrade -> "B" - | FIX_TradeCondition_CashTrade -> "C" - | FIX_TradeCondition_NextDay -> "D" - | FIX_TradeCondition_Opening -> "E" - | FIX_TradeCondition_IntradayTradeDetail -> "F" - | FIX_TradeCondition_Rule127Trade -> "G" - | FIX_TradeCondition_Rule155Trade -> "H" - | FIX_TradeCondition_SoldLast -> "I" - | FIX_TradeCondition_NextDayTrade -> "J" - | FIX_TradeCondition_Opened -> "K" - | FIX_TradeCondition_Seller -> "L" - | FIX_TradeCondition_Sold -> "M" - | FIX_TradeCondition_StoppedStock -> "N" - | FIX_TradeCondition_ImbalanceMoreBuyers -> "P" - | FIX_TradeCondition_ImbalanceMoreSellers -> "Q" - | FIX_TradeCondition_OpeningPrice -> "R" - ) -;; - -let encode_TradeCondition (d) = - list_to_split (List.map enncode_inner_TradeCondition d) ' ' -;; - -let encode_TradeReportRejectReason (d) = - (match d with - | FIX_TradeReportRejectReason_Successful -> "0" - | FIX_TradeReportRejectReason_InvalidPartyOnformation -> "1" - | FIX_TradeReportRejectReason_UnknownInstrument -> "2" - | FIX_TradeReportRejectReason_UnauthorizedToReportTrades -> "3" - | FIX_TradeReportRejectReason_InvalidTradeType -> "4" - | FIX_TradeReportRejectReason_Other -> "99" - ) -;; - -let encode_TradeReportType (d) = - (match d with - | FIX_TradeReportType_Submit -> "0" - | FIX_TradeReportType_Alleged -> "1" - | FIX_TradeReportType_Accept -> "2" - | FIX_TradeReportType_Decline -> "3" - | FIX_TradeReportType_Addendum -> "4" - | FIX_TradeReportType_No -> "5" - | FIX_TradeReportType_TradeReportCancel -> "6" - | FIX_TradeReportType_LockedIn -> "7" - ) -;; - -let encode_TradeRequestResult (d) = - (match d with - | FIX_TradeRequestResult_Successful -> "0" - | FIX_TradeRequestResult_InvalidOrUnknownInstrument -> "1" - | FIX_TradeRequestResult_InvalidTypeOfTradeRequested -> "2" - | FIX_TradeRequestResult_InvalidParties -> "3" - | FIX_TradeRequestResult_InvalidTransportTypeRequested -> "4" - | FIX_TradeRequestResult_InvalidDestinationRequested -> "5" - | FIX_TradeRequestResult_TradeRequestTypeNotSupported -> "8" - | FIX_TradeRequestResult_NotAuthorized -> "9" - | FIX_TradeRequestResult_Other -> "99" - ) -;; - -let encode_TradeRequestStatus (d) = - (match d with - | FIX_TradeRequestStatus_Accepted -> "0" - | FIX_TradeRequestStatus_Completed -> "1" - | FIX_TradeRequestStatus_Rejected -> "2" - ) -;; - -let encode_TradeRequestType (d) = - (match d with - | FIX_TradeRequestType_AllTrades -> "0" - | FIX_TradeRequestType_MatchedTradesMatchingCriteria -> "1" - | FIX_TradeRequestType_UnmatchedTradesThatMatchCriteria -> "2" - | FIX_TradeRequestType_UnreportedTradesThatMatchCriteria -> "3" - | FIX_TradeRequestType_AdvisoriesThatMatchCriteria -> "4" - ) -;; - -let encode_TradedFlatSwitch (d) = - (match d with - | FIX_TradedFlatSwitch_TradedFlat -> "Y" - | FIX_TradedFlatSwitch_NotTradedFlat -> "N" - ) -;; - -let encode_TrdRegTimestampType (d) = - (match d with - | FIX_TrdRegTimestampType_ExecutionTime -> "1" - | FIX_TrdRegTimestampType_TimeIn -> "2" - | FIX_TrdRegTimestampType_TimeOut -> "3" - | FIX_TrdRegTimestampType_BrokerReceipt -> "4" - | FIX_TrdRegTimestampType_BrokerExecution -> "5" - ) -;; - -let encode_TrdRptStatus (d) = - (match d with - | FIX_TrdRptStatus_Accepted -> "0" - | FIX_TrdRptStatus_Rejected -> "1" - ) -;; - -let encode_TrdType (d) = - (match d with - | FIX_TrdType_RegularTrade -> "0" - | FIX_TrdType_BlockTrade -> "1" - | FIX_TrdType_EFP -> "2" - | FIX_TrdType_Transfer -> "3" - | FIX_TrdType_LateTrade -> "4" - | FIX_TrdType_TTrade -> "5" - | FIX_TrdType_WeightedAveragePriceTrade -> "6" - | FIX_TrdType_BunchedTrade -> "7" - | FIX_TrdType_LateBunchedTrade -> "8" - | FIX_TrdType_PriorReferencePriceTrade -> "9" - | FIX_TrdType_AfterHoursTrade -> "10" - ) -;; - -let encode_UnsolicitedIndicator (d) = - (match d with - | FIX_UnsolicitedIndicator_MessageIsBeingSentUnsolicited -> "Y" - | FIX_UnsolicitedIndicator_MessageIsBeingSentAsAResultOfAPriorRequest -> "N" - ) -;; - -let encode_Urgency (d) = - (match d with - | FIX_Urgency_Normal -> "0" - | FIX_Urgency_Flash -> "1" - | FIX_Urgency_Background -> "2" - ) -;; - -let encode_UserRequestType (d) = - (match d with - | FIX_UserRequestType_LogOnUser -> "1" - | FIX_UserRequestType_LogOffUser -> "2" - | FIX_UserRequestType_ChangePasswordForUser -> "3" - | FIX_UserRequestType_RequestIndividualUserStatus -> "4" - ) -;; - -let encode_UserStatus (d) = - (match d with - | FIX_UserStatus_LoggedIn -> "1" - | FIX_UserStatus_NotLoggedIn -> "2" - | FIX_UserStatus_UserNotRecognised -> "3" - | FIX_UserStatus_PasswordIncorrect -> "4" - | FIX_UserStatus_PasswordChanged -> "5" - | FIX_UserStatus_Other -> "6" - ) -;; - -let encode_WorkingIndicator (d) = - (match d with - | FIX_WorkingIndicator_Working -> "Y" - | FIX_WorkingIndicator_NotWorking -> "N" - ) -;; - -let encode_YieldType (d) = - (match d with - | FIX_YieldType_AfterTaxYield -> "AFTERTAX" - | FIX_YieldType_AnnualYield -> "ANNUAL" - | FIX_YieldType_YieldAtIssue -> "ATISSUE" - | FIX_YieldType_YieldToAverageMaturity -> "AVGMATURITY" - | FIX_YieldType_BookYield -> "BOOK" - | FIX_YieldType_YieldToNextCall -> "CALL" - | FIX_YieldType_YieldChangeSinceClose -> "CHANGE" - | FIX_YieldType_ClosingYield -> "CLOSE" - | FIX_YieldType_CompoundYield -> "COMPOUND" - | FIX_YieldType_CurrentYield -> "CURRENT" - | FIX_YieldType_TrueGrossYield -> "GROSS" - | FIX_YieldType_GvntEquivalentYield -> "GOVTEQUIV" - | FIX_YieldType_YieldWithInflationAssumption -> "INFLATION" - | FIX_YieldType_InverseFloaterBondYield -> "INVERSEFLOATER" - | FIX_YieldType_MostRecentClosingYield -> "LASTCLOSE" - | FIX_YieldType_ClosingYieldMostRecentMonth -> "LASTMONTH" - | FIX_YieldType_ClosingYieldMostRecentQuarter -> "LASTQUARTER" - | FIX_YieldType_ClosingYieldMostRecentYear -> "LASTYEAR" - | FIX_YieldType_YieldToLongestAverageLife -> "LONGAVGLIFE" - | FIX_YieldType_MarkToMarketYield -> "MARK" - | FIX_YieldType_YieldToMaturity -> "MATURITY" - | FIX_YieldType_YieldToNextRefund -> "NEXTREFUND" - | FIX_YieldType_OpenAverageYield -> "OPENAVG" - | FIX_YieldType_YieldToNextPut -> "PUT" - | FIX_YieldType_PreviousCloseYield -> "PREVCLOSE" - | FIX_YieldType_ProceedsYield -> "PROCEEDS" - | FIX_YieldType_SemiAnnualYield -> "SEMIANNUAL" - | FIX_YieldType_YieldToShortestAverageLife -> "SHORTAVGLIFE" - | FIX_YieldType_SimpleYield -> "SIMPLE" - | FIX_YieldType_TaxEquivalentYield -> "TAXEQUIV" - | FIX_YieldType_YieldToTenderDate -> "TENDER" - | FIX_YieldType_TrueYield -> "TRUE" - | FIX_YieldType_YieldValueOf132 -> "VALUE1/32" - | FIX_YieldType_YieldToWorst -> "WORST" - ) -;; - -let encode_Currency (d) = - (match d with - | FIX_Currency_EUR -> "EUR" - | FIX_Currency_GBP -> "GBP" - | FIX_Currency_USD -> "USD" - | FIX_Currency_CHF -> "CHF" - ) -;; - -let encode_Country (d) = - (match d with - | FIX_Country_DE -> "DE" - | FIX_Country_GB -> "GB" - | FIX_Country_US -> "US" - ) -;; - -let encode_Exchange (d) = - (match d with - | FIX_Exchange_XLON -> "XLON" - | FIX_Exchange_XNYS -> "XNYS" - | FIX_Exchange_XNAS -> "XNAS" - | FIX_Exchange_XJAS -> "XJAS" - | FIX_Exchange_XSHG -> "XSHG" - | FIX_Exchange_SHSC -> "SHSC" - ) -;; [@@@logic] diff --git a/src-protocol-exts-pp/encode_app_messages.iml b/src-protocol-exts-pp/encode_app_messages.iml index 1a4148fb..ce640a34 100644 --- a/src-protocol-exts-pp/encode_app_messages.iml +++ b/src-protocol-exts-pp/encode_app_messages.iml @@ -1,30 +1,32 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "encode_app_enums.iml"] -[@@@import "encode_app_records.iml"] -[@@@import "../src-core-pp/encode_base_types.iml"] -[@@@import "../src-core-pp/encode_datetime.iml"] -[@@@import "encode_utils.iml"] -[@@@import "../src-protocol-exts/full_app_messages.iml"] +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "encode_app_enums.iml"] open Encode_app_enums;; +[@@@import "encode_app_records.iml"] open Encode_app_records;; +[@@@import "../src-core-pp/encode_base_types.iml"] open Encode_base_types;; +[@@@import "../src-core-pp/encode_datetime.iml"] open Encode_datetime;; +[@@@import "encode_utils.iml"] open Encode_utils;; +[@@@import "../src-protocol-exts/full_app_messages.iml"] open Full_app_messages;; -let encode_ExecutionReport (msg) = - (@) (encode_YieldData msg.f_ExecutionReport_YieldData) ((@) (encode_SpreadOrBenchmarkCurveData msg.f_ExecutionReport_SpreadOrBenchmarkCurveData) ((@) (encode_CommissionData msg.f_ExecutionReport_CommissionData) ((@) (encode_DiscretionInstructions msg.f_ExecutionReport_DiscretionInstructions) ((@) (encode_PegInstructions msg.f_ExecutionReport_PegInstructions) ((@) (encode_OrderQtyData msg.f_ExecutionReport_OrderQtyData) ((@) (encode_FinancingDetails msg.f_ExecutionReport_FinancingDetails) ((@) (encode_Instrument msg.f_ExecutionReport_Instrument) ((@) (("37",enc_opt encode_string msg.f_ExecutionReport_OrderID) :: (("198",enc_opt encode_string msg.f_ExecutionReport_SecondaryOrderID) :: (("526",enc_opt encode_string msg.f_ExecutionReport_SecondaryClOrdID) :: (("527",enc_opt encode_string msg.f_ExecutionReport_SecondaryExecID) :: (("11",enc_opt encode_string msg.f_ExecutionReport_ClOrdID) :: (("41",enc_opt encode_string msg.f_ExecutionReport_OrigClOrdID) :: (("583",enc_opt encode_string msg.f_ExecutionReport_ClOrdLinkID) :: (("693",enc_opt encode_string msg.f_ExecutionReport_QuoteRespID) :: (("790",enc_opt encode_string msg.f_ExecutionReport_OrdStatusReqID) :: (("584",enc_opt encode_string msg.f_ExecutionReport_MassStatusReqID) :: (("911",enc_opt encode_int msg.f_ExecutionReport_TotNumReports) :: (("912",enc_opt encode_bool msg.f_ExecutionReport_LastRptRequested) :: (("229",enc_opt encode_LocalMktDate msg.f_ExecutionReport_TradeOriginationDate) :: (("66",enc_opt encode_string msg.f_ExecutionReport_ListID) :: (("548",enc_opt encode_string msg.f_ExecutionReport_CrossID) :: (("551",enc_opt encode_string msg.f_ExecutionReport_OrigCrossID) :: (("549",enc_opt encode_CrossType msg.f_ExecutionReport_CrossType) :: (("17",enc_opt encode_string msg.f_ExecutionReport_ExecID) :: (("19",enc_opt encode_string msg.f_ExecutionReport_ExecRefID) :: (("150",enc_opt encode_ExecType msg.f_ExecutionReport_ExecType) :: (("39",enc_opt encode_OrdStatus msg.f_ExecutionReport_OrdStatus) :: (("636",enc_opt encode_WorkingIndicator msg.f_ExecutionReport_WorkingIndicator) :: (("103",enc_opt encode_OrdRejReason msg.f_ExecutionReport_OrdRejReason) :: (("378",enc_opt encode_ExecRestatementReason msg.f_ExecutionReport_ExecRestatementReason) :: (("1",enc_opt encode_string msg.f_ExecutionReport_Account) :: (("660",enc_opt encode_AcctIDSource msg.f_ExecutionReport_AcctIDSource) :: (("581",enc_opt encode_AccountType msg.f_ExecutionReport_AccountType) :: (("589",enc_opt encode_DayBookingInst msg.f_ExecutionReport_DayBookingInst) :: (("590",enc_opt encode_BookingUnit msg.f_ExecutionReport_BookingUnit) :: (("591",enc_opt encode_PreallocMethod msg.f_ExecutionReport_PreallocMethod) :: (("63",enc_opt encode_SettlType msg.f_ExecutionReport_SettlType) :: (("64",enc_opt encode_LocalMktDate msg.f_ExecutionReport_SettlDate) :: (("544",enc_opt encode_CashMargin msg.f_ExecutionReport_CashMargin) :: (("635",enc_opt encode_ClearingFeeIndicator msg.f_ExecutionReport_ClearingFeeIndicator) :: (("54",enc_opt encode_Side msg.f_ExecutionReport_Side) :: (("854",enc_opt encode_QtyType msg.f_ExecutionReport_QtyType) :: (("40",enc_opt encode_OrdType msg.f_ExecutionReport_OrdType) :: (("423",enc_opt encode_PriceType msg.f_ExecutionReport_PriceType) :: (("44",enc_opt encode_float_6 msg.f_ExecutionReport_Price) :: (("99",enc_opt encode_float_6 msg.f_ExecutionReport_StopPx) :: (("839",enc_opt encode_float_6 msg.f_ExecutionReport_PeggedPrice) :: (("845",enc_opt encode_float_6 msg.f_ExecutionReport_DiscretionPrice) :: (("847",enc_opt encode_TargetStrategy msg.f_ExecutionReport_TargetStrategy) :: (("848",enc_opt encode_string msg.f_ExecutionReport_TargetStrategyParameters) :: (("849",enc_opt encode_float_6 msg.f_ExecutionReport_ParticipationRate) :: (("850",enc_opt encode_float msg.f_ExecutionReport_TargetStrategyPerformance) :: (("15",enc_opt encode_Currency msg.f_ExecutionReport_Currency) :: (("376",enc_opt encode_string msg.f_ExecutionReport_ComplianceID) :: (("377",enc_opt encode_SolicitedFlag msg.f_ExecutionReport_SolicitedFlag) :: (("59",enc_opt encode_TimeInForce msg.f_ExecutionReport_TimeInForce) :: (("168",enc_opt encode_UTCTimestamp_milli msg.f_ExecutionReport_EffectiveTime) :: (("432",enc_opt encode_LocalMktDate msg.f_ExecutionReport_ExpireDate) :: (("126",enc_opt encode_UTCTimestamp_milli msg.f_ExecutionReport_ExpireTime) :: (("18",enc_opt encode_ExecInst msg.f_ExecutionReport_ExecInst) :: (("528",enc_opt encode_OrderCapacity msg.f_ExecutionReport_OrderCapacity) :: (("529",enc_opt encode_OrderRestrictions msg.f_ExecutionReport_OrderRestrictions) :: (("582",enc_opt encode_CustOrderCapacity msg.f_ExecutionReport_CustOrderCapacity) :: (("32",enc_opt encode_float_6 msg.f_ExecutionReport_LastQty) :: (("652",enc_opt encode_float_6 msg.f_ExecutionReport_UnderlyingLastQty) :: (("31",enc_opt encode_float_6 msg.f_ExecutionReport_LastPx) :: (("651",enc_opt encode_float_6 msg.f_ExecutionReport_UnderlyingLastPx) :: (("669",enc_opt encode_float_6 msg.f_ExecutionReport_LastParPx) :: (("194",enc_opt encode_float_6 msg.f_ExecutionReport_LastSpotRate) :: (("195",enc_opt encode_float_6 msg.f_ExecutionReport_LastForwardPoints) :: (("30",enc_opt encode_Exchange msg.f_ExecutionReport_LastMkt) :: (("336",enc_opt encode_string msg.f_ExecutionReport_TradingSessionID) :: (("625",enc_opt encode_string msg.f_ExecutionReport_TradingSessionSubID) :: (("943",enc_opt encode_string msg.f_ExecutionReport_TimeBracket) :: (("29",enc_opt encode_LastCapacity msg.f_ExecutionReport_LastCapacity) :: (("151",enc_opt encode_float_6 msg.f_ExecutionReport_LeavesQty) :: (("14",enc_opt encode_float_6 msg.f_ExecutionReport_CumQty) :: (("6",enc_opt encode_float_6 msg.f_ExecutionReport_AvgPx) :: (("424",enc_opt encode_float_6 msg.f_ExecutionReport_DayOrderQty) :: (("425",enc_opt encode_float_6 msg.f_ExecutionReport_DayCumQty) :: (("426",enc_opt encode_float_6 msg.f_ExecutionReport_DayAvgPx) :: (("427",enc_opt encode_GTBookingInst msg.f_ExecutionReport_GTBookingInst) :: (("75",enc_opt encode_LocalMktDate msg.f_ExecutionReport_TradeDate) :: (("60",enc_opt encode_UTCTimestamp_milli msg.f_ExecutionReport_TransactTime) :: (("113",enc_opt encode_ReportToExch msg.f_ExecutionReport_ReportToExch) :: (("381",enc_opt encode_float_6 msg.f_ExecutionReport_GrossTradeAmt) :: (("157",enc_opt encode_int msg.f_ExecutionReport_NumDaysInterest) :: (("230",enc_opt encode_LocalMktDate msg.f_ExecutionReport_ExDate) :: (("158",enc_opt encode_float_6 msg.f_ExecutionReport_AccruedInterestRate) :: (("159",enc_opt encode_float_6 msg.f_ExecutionReport_AccruedInterestAmt) :: (("738",enc_opt encode_float_6 msg.f_ExecutionReport_InterestAtMaturity) :: (("920",enc_opt encode_float_6 msg.f_ExecutionReport_EndAccruedInterestAmt) :: (("921",enc_opt encode_float_6 msg.f_ExecutionReport_StartCash) :: (("922",enc_opt encode_float_6 msg.f_ExecutionReport_EndCash) :: (("258",enc_opt encode_TradedFlatSwitch msg.f_ExecutionReport_TradedFlatSwitch) :: (("259",enc_opt encode_LocalMktDate msg.f_ExecutionReport_BasisFeatureDate) :: (("260",enc_opt encode_float_6 msg.f_ExecutionReport_BasisFeaturePrice) :: (("238",enc_opt encode_float_6 msg.f_ExecutionReport_Concession) :: (("237",enc_opt encode_float_6 msg.f_ExecutionReport_TotalTakedown) :: (("118",enc_opt encode_float_6 msg.f_ExecutionReport_NetMoney) :: (("119",enc_opt encode_float_6 msg.f_ExecutionReport_SettlCurrAmt) :: (("120",enc_opt encode_Currency msg.f_ExecutionReport_SettlCurrency) :: (("155",enc_opt encode_float msg.f_ExecutionReport_SettlCurrFxRate) :: (("156",enc_opt encode_SettlCurrFxRateCalc msg.f_ExecutionReport_SettlCurrFxRateCalc) :: (("21",enc_opt encode_HandlInst msg.f_ExecutionReport_HandlInst) :: (("110",enc_opt encode_float_6 msg.f_ExecutionReport_MinQty) :: (("111",enc_opt encode_float_6 msg.f_ExecutionReport_MaxFloor) :: (("77",enc_opt encode_PositionEffect msg.f_ExecutionReport_PositionEffect) :: (("210",enc_opt encode_float_6 msg.f_ExecutionReport_MaxShow) :: (("775",enc_opt encode_BookingType msg.f_ExecutionReport_BookingType) :: (("58",enc_opt encode_string msg.f_ExecutionReport_Text) :: (("354",enc_opt encode_int msg.f_ExecutionReport_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_ExecutionReport_EncodedText) :: (("193",enc_opt encode_LocalMktDate msg.f_ExecutionReport_SettlDate2) :: (("192",enc_opt encode_float_6 msg.f_ExecutionReport_OrderQty2) :: (("641",enc_opt encode_float_6 msg.f_ExecutionReport_LastForwardPoints2) :: (("442",enc_opt encode_MultiLegReportingType msg.f_ExecutionReport_MultiLegReportingType) :: (("480",enc_opt encode_CancellationRights msg.f_ExecutionReport_CancellationRights) :: (("481",enc_opt encode_MoneyLaunderingStatus msg.f_ExecutionReport_MoneyLaunderingStatus) :: (("513",enc_opt encode_string msg.f_ExecutionReport_RegistID) :: (("494",enc_opt encode_string msg.f_ExecutionReport_Designation) :: (("483",enc_opt encode_UTCTimestamp_milli msg.f_ExecutionReport_TransBkdTime) :: (("515",enc_opt encode_UTCTimestamp_milli msg.f_ExecutionReport_ExecValuationPoint) :: (("484",enc_opt encode_ExecPriceType msg.f_ExecutionReport_ExecPriceType) :: (("485",enc_opt encode_float msg.f_ExecutionReport_ExecPriceAdjustment) :: (("638",enc_opt encode_PriorityIndicator msg.f_ExecutionReport_PriorityIndicator) :: (("639",enc_opt encode_float_6 msg.f_ExecutionReport_PriceImprovement) :: (("851",enc_opt encode_LastLiquidityInd msg.f_ExecutionReport_LastLiquidityInd) :: (("797",enc_opt encode_bool msg.f_ExecutionReport_CopyMsgIndicator) :: []))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) ((@) (enc_repeat encode_MiscFeesGrp "136" msg.f_ExecutionReport_MiscFeesGrp) ((@) (enc_repeat encode_InstrmtLegExecGrp "555" msg.f_ExecutionReport_InstrmtLegExecGrp) ((@) (enc_repeat encode_ContAmtGrp "518" msg.f_ExecutionReport_ContAmtGrp) ((@) (enc_repeat encode_Stipulations "232" msg.f_ExecutionReport_Stipulations) ((@) (enc_repeat encode_UndInstrmtGrp "711" msg.f_ExecutionReport_UndInstrmtGrp) ((@) (enc_repeat encode_ContraGrp "382" msg.f_ExecutionReport_ContraGrp) ((@) (enc_repeat encode_Parties "453" msg.f_ExecutionReport_Parties) []))))))))))))))) -;; let encode_NewOrderSingle (msg) = - (@) (encode_DiscretionInstructions msg.f_NewOrderSingle_DiscretionInstructions) ((@) (encode_PegInstructions msg.f_NewOrderSingle_PegInstructions) ((@) (encode_CommissionData msg.f_NewOrderSingle_CommissionData) ((@) (encode_YieldData msg.f_NewOrderSingle_YieldData) ((@) (encode_SpreadOrBenchmarkCurveData msg.f_NewOrderSingle_SpreadOrBenchmarkCurveData) ((@) (encode_OrderQtyData msg.f_NewOrderSingle_OrderQtyData) ((@) (encode_FinancingDetails msg.f_NewOrderSingle_FinancingDetails) ((@) (encode_Instrument msg.f_NewOrderSingle_Instrument) ((@) (("11",enc_opt encode_string msg.f_NewOrderSingle_ClOrdID) :: (("526",enc_opt encode_string msg.f_NewOrderSingle_SecondaryClOrdID) :: (("583",enc_opt encode_string msg.f_NewOrderSingle_ClOrdLinkID) :: (("229",enc_opt encode_LocalMktDate msg.f_NewOrderSingle_TradeOriginationDate) :: (("75",enc_opt encode_LocalMktDate msg.f_NewOrderSingle_TradeDate) :: (("1",enc_opt encode_string msg.f_NewOrderSingle_Account) :: (("660",enc_opt encode_AcctIDSource msg.f_NewOrderSingle_AcctIDSource) :: (("581",enc_opt encode_AccountType msg.f_NewOrderSingle_AccountType) :: (("589",enc_opt encode_DayBookingInst msg.f_NewOrderSingle_DayBookingInst) :: (("590",enc_opt encode_BookingUnit msg.f_NewOrderSingle_BookingUnit) :: (("591",enc_opt encode_PreallocMethod msg.f_NewOrderSingle_PreallocMethod) :: (("70",enc_opt encode_string msg.f_NewOrderSingle_AllocID) :: (("63",enc_opt encode_SettlType msg.f_NewOrderSingle_SettlType) :: (("64",enc_opt encode_LocalMktDate msg.f_NewOrderSingle_SettlDate) :: (("544",enc_opt encode_CashMargin msg.f_NewOrderSingle_CashMargin) :: (("635",enc_opt encode_ClearingFeeIndicator msg.f_NewOrderSingle_ClearingFeeIndicator) :: (("21",enc_opt encode_HandlInst msg.f_NewOrderSingle_HandlInst) :: (("18",enc_opt encode_ExecInst msg.f_NewOrderSingle_ExecInst) :: (("110",enc_opt encode_float_6 msg.f_NewOrderSingle_MinQty) :: (("111",enc_opt encode_float_6 msg.f_NewOrderSingle_MaxFloor) :: (("100",enc_opt encode_Exchange msg.f_NewOrderSingle_ExDestination) :: (("81",enc_opt encode_ProcessCode msg.f_NewOrderSingle_ProcessCode) :: (("140",enc_opt encode_float_6 msg.f_NewOrderSingle_PrevClosePx) :: (("54",enc_opt encode_Side msg.f_NewOrderSingle_Side) :: (("114",enc_opt encode_LocateReqd msg.f_NewOrderSingle_LocateReqd) :: (("60",enc_opt encode_UTCTimestamp_milli msg.f_NewOrderSingle_TransactTime) :: (("854",enc_opt encode_QtyType msg.f_NewOrderSingle_QtyType) :: (("40",enc_opt encode_OrdType msg.f_NewOrderSingle_OrdType) :: (("423",enc_opt encode_PriceType msg.f_NewOrderSingle_PriceType) :: (("44",enc_opt encode_float_6 msg.f_NewOrderSingle_Price) :: (("99",enc_opt encode_float_6 msg.f_NewOrderSingle_StopPx) :: (("15",enc_opt encode_Currency msg.f_NewOrderSingle_Currency) :: (("376",enc_opt encode_string msg.f_NewOrderSingle_ComplianceID) :: (("377",enc_opt encode_SolicitedFlag msg.f_NewOrderSingle_SolicitedFlag) :: (("23",enc_opt encode_string msg.f_NewOrderSingle_IOIID) :: (("117",enc_opt encode_string msg.f_NewOrderSingle_QuoteID) :: (("59",enc_opt encode_TimeInForce msg.f_NewOrderSingle_TimeInForce) :: (("168",enc_opt encode_UTCTimestamp_milli msg.f_NewOrderSingle_EffectiveTime) :: (("432",enc_opt encode_LocalMktDate msg.f_NewOrderSingle_ExpireDate) :: (("126",enc_opt encode_UTCTimestamp_milli msg.f_NewOrderSingle_ExpireTime) :: (("427",enc_opt encode_GTBookingInst msg.f_NewOrderSingle_GTBookingInst) :: (("528",enc_opt encode_OrderCapacity msg.f_NewOrderSingle_OrderCapacity) :: (("529",enc_opt encode_OrderRestrictions msg.f_NewOrderSingle_OrderRestrictions) :: (("582",enc_opt encode_CustOrderCapacity msg.f_NewOrderSingle_CustOrderCapacity) :: (("121",enc_opt encode_ForexReq msg.f_NewOrderSingle_ForexReq) :: (("120",enc_opt encode_Currency msg.f_NewOrderSingle_SettlCurrency) :: (("775",enc_opt encode_BookingType msg.f_NewOrderSingle_BookingType) :: (("58",enc_opt encode_string msg.f_NewOrderSingle_Text) :: (("354",enc_opt encode_int msg.f_NewOrderSingle_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_NewOrderSingle_EncodedText) :: (("193",enc_opt encode_LocalMktDate msg.f_NewOrderSingle_SettlDate2) :: (("192",enc_opt encode_float_6 msg.f_NewOrderSingle_OrderQty2) :: (("640",enc_opt encode_float_6 msg.f_NewOrderSingle_Price2) :: (("77",enc_opt encode_PositionEffect msg.f_NewOrderSingle_PositionEffect) :: (("203",enc_opt encode_CoveredOrUncovered msg.f_NewOrderSingle_CoveredOrUncovered) :: (("210",enc_opt encode_float_6 msg.f_NewOrderSingle_MaxShow) :: (("847",enc_opt encode_TargetStrategy msg.f_NewOrderSingle_TargetStrategy) :: (("848",enc_opt encode_string msg.f_NewOrderSingle_TargetStrategyParameters) :: (("849",enc_opt encode_float_6 msg.f_NewOrderSingle_ParticipationRate) :: (("480",enc_opt encode_CancellationRights msg.f_NewOrderSingle_CancellationRights) :: (("481",enc_opt encode_MoneyLaunderingStatus msg.f_NewOrderSingle_MoneyLaunderingStatus) :: (("513",enc_opt encode_string msg.f_NewOrderSingle_RegistID) :: (("494",enc_opt encode_string msg.f_NewOrderSingle_Designation) :: []))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) ((@) (enc_repeat encode_Stipulations "232" msg.f_NewOrderSingle_Stipulations) ((@) (enc_repeat encode_UndInstrmtGrp "711" msg.f_NewOrderSingle_UndInstrmtGrp) ((@) (enc_repeat encode_TrdgSesGrp "386" msg.f_NewOrderSingle_TrdgSesGrp) ((@) (enc_repeat encode_PreAllocGrp "78" msg.f_NewOrderSingle_PreAllocGrp) ((@) (enc_repeat encode_Parties "453" msg.f_NewOrderSingle_Parties) []))))))))))))) + (@) (encode_OrderQtyData msg.f_NewOrderSingle_OrderQtyData) ((@) ([(("11",enc_opt encode_string msg.f_NewOrderSingle_ClOrdID));(("1",enc_opt encode_string msg.f_NewOrderSingle_Account));(("18",enc_opt encode_ExecInst msg.f_NewOrderSingle_ExecInst));(("54",enc_opt encode_Side msg.f_NewOrderSingle_Side));(("60",enc_opt encode_UTCTimestamp_milli msg.f_NewOrderSingle_TransactTime));(("40",enc_opt encode_OrdType msg.f_NewOrderSingle_OrdType));(("44",enc_opt encode_float_2 msg.f_NewOrderSingle_Price));(("10001",enc_opt encode_float msg.f_NewOrderSingle_SpreadProportion))]) ((@) (enc_repeat encode_Parties "453" msg.f_NewOrderSingle_Parties) [])) +;; + +let encode_ExecutionReport (msg) = + (@) (encode_OrderQtyData msg.f_ExecutionReport_OrderQtyData) ((@) ([(("37",enc_opt encode_string msg.f_ExecutionReport_OrderID));(("17",enc_opt encode_string msg.f_ExecutionReport_ExecID));(("150",enc_opt encode_ExecType msg.f_ExecutionReport_ExecType));(("39",enc_opt encode_OrdStatus msg.f_ExecutionReport_OrdStatus));(("54",enc_opt encode_Side msg.f_ExecutionReport_Side));(("18",enc_opt encode_ExecInst msg.f_ExecutionReport_ExecInst));(("151",enc_opt encode_float_6 msg.f_ExecutionReport_LeavesQty));(("14",enc_opt encode_float_6 msg.f_ExecutionReport_CumQty));(("58",enc_opt encode_string msg.f_ExecutionReport_Text))]) ((@) (enc_repeat encode_Parties "453" msg.f_ExecutionReport_Parties) [])) ;; let encode_app_msg_data (msg) = (match msg with - | FIX_Full_Msg_ExecutionReport msg -> (encode_ExecutionReport msg) | FIX_Full_Msg_NewOrderSingle msg -> (encode_NewOrderSingle msg) + | FIX_Full_Msg_ExecutionReport msg -> (encode_ExecutionReport msg) ) ;; + [@@@logic] diff --git a/src-protocol-exts-pp/encode_app_records.iml b/src-protocol-exts-pp/encode_app_records.iml index f2ec6bb9..1c540987 100644 --- a/src-protocol-exts-pp/encode_app_records.iml +++ b/src-protocol-exts-pp/encode_app_records.iml @@ -1,433 +1,25 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "encode_app_enums.iml"] -[@@@import "../src-core-pp/encode_base_types.iml"] -[@@@import "../src-core-pp/encode_datetime.iml"] -[@@@import "encode_utils.iml"] -[@@@import "../src-protocol-exts/full_app_records.iml"] +(* Imandra Inc. copyright 2021 *) [@@@program] -open Encode_app_enums;; +[@@@import "../src-core-pp/encode_base_types.iml"] open Encode_base_types;; +[@@@import "../src-core-pp/encode_datetime.iml"] open Encode_datetime;; +[@@@import "encode_utils.iml"] open Encode_utils;; +[@@@import "../src-protocol-exts/full_app_records.iml"] open Full_app_records;; -let encode_LogonMsgTypes (msg) = - (@) (("372",enc_opt encode_string msg.f_LogonMsgTypes_RefMsgType) :: (("385",enc_opt encode_MsgDirection msg.f_LogonMsgTypes_MsgDirection) :: [])) [] -;; - -let encode_MDReqGrp (msg) = - (@) (("269",enc_opt encode_MDEntryType msg.f_MDReqGrp_MDEntryType) :: []) [] -;; - -let encode_UnderlyingStipulations (msg) = - (@) (("888",enc_opt encode_string msg.f_UnderlyingStipulations_UnderlyingStipType) :: (("889",enc_opt encode_string msg.f_UnderlyingStipulations_UnderlyingStipValue) :: [])) [] -;; - -let encode_EvntGrp (msg) = - (@) (("865",enc_opt encode_EventType msg.f_EvntGrp_EventType) :: (("866",enc_opt encode_LocalMktDate msg.f_EvntGrp_EventDate) :: (("867",enc_opt encode_float_6 msg.f_EvntGrp_EventPx) :: (("868",enc_opt encode_string msg.f_EvntGrp_EventText) :: [])))) [] -;; - -let encode_MDFullGrp (msg) = - (@) (("269",enc_opt encode_MDEntryType msg.f_MDFullGrp_MDEntryType) :: (("270",enc_opt encode_float_6 msg.f_MDFullGrp_MDEntryPx) :: (("15",enc_opt encode_Currency msg.f_MDFullGrp_Currency) :: (("271",enc_opt encode_float_6 msg.f_MDFullGrp_MDEntrySize) :: (("272",enc_opt encode_UTCDateOnly msg.f_MDFullGrp_MDEntryDate) :: (("273",enc_opt encode_UTCTimeOnly_milli msg.f_MDFullGrp_MDEntryTime) :: (("274",enc_opt encode_TickDirection msg.f_MDFullGrp_TickDirection) :: (("275",enc_opt encode_Exchange msg.f_MDFullGrp_MDMkt) :: (("336",enc_opt encode_string msg.f_MDFullGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_MDFullGrp_TradingSessionSubID) :: (("276",enc_opt encode_QuoteCondition msg.f_MDFullGrp_QuoteCondition) :: (("277",enc_opt encode_TradeCondition msg.f_MDFullGrp_TradeCondition) :: (("282",enc_opt encode_string msg.f_MDFullGrp_MDEntryOriginator) :: (("283",enc_opt encode_string msg.f_MDFullGrp_LocationID) :: (("284",enc_opt encode_string msg.f_MDFullGrp_DeskID) :: (("286",enc_opt encode_OpenCloseSettlFlag msg.f_MDFullGrp_OpenCloseSettlFlag) :: (("59",enc_opt encode_TimeInForce msg.f_MDFullGrp_TimeInForce) :: (("432",enc_opt encode_LocalMktDate msg.f_MDFullGrp_ExpireDate) :: (("126",enc_opt encode_UTCTimestamp_milli msg.f_MDFullGrp_ExpireTime) :: (("110",enc_opt encode_float_6 msg.f_MDFullGrp_MinQty) :: (("18",enc_opt encode_ExecInst msg.f_MDFullGrp_ExecInst) :: (("287",enc_opt encode_int msg.f_MDFullGrp_SellerDays) :: (("37",enc_opt encode_string msg.f_MDFullGrp_OrderID) :: (("299",enc_opt encode_string msg.f_MDFullGrp_QuoteEntryID) :: (("288",enc_opt encode_string msg.f_MDFullGrp_MDEntryBuyer) :: (("289",enc_opt encode_string msg.f_MDFullGrp_MDEntrySeller) :: (("346",enc_opt encode_int msg.f_MDFullGrp_NumberOfOrders) :: (("290",enc_opt encode_int msg.f_MDFullGrp_MDEntryPositionNo) :: (("546",enc_opt encode_Scope msg.f_MDFullGrp_Scope) :: (("811",enc_opt encode_float msg.f_MDFullGrp_PriceDelta) :: (("58",enc_opt encode_string msg.f_MDFullGrp_Text) :: (("354",enc_opt encode_int msg.f_MDFullGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_MDFullGrp_EncodedText) :: []))))))))))))))))))))))))))))))))) [] -;; - -let encode_UndSecAltIDGrp (msg) = - (@) (("458",enc_opt encode_string msg.f_UndSecAltIDGrp_UnderlyingSecurityAltID) :: (("459",enc_opt encode_string msg.f_UndSecAltIDGrp_UnderlyingSecurityAltIDSource) :: [])) [] -;; - -let encode_LinesOfTextGrp (msg) = - (@) (("58",enc_opt encode_string msg.f_LinesOfTextGrp_Text) :: (("354",enc_opt encode_int msg.f_LinesOfTextGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_LinesOfTextGrp_EncodedText) :: []))) [] -;; - -let encode_LegSecAltIDGrp (msg) = - (@) (("605",enc_opt encode_string msg.f_LegSecAltIDGrp_LegSecurityAltID) :: (("606",enc_opt encode_string msg.f_LegSecAltIDGrp_LegSecurityAltIDSource) :: [])) [] -;; - -let encode_SpreadOrBenchmarkCurveData (msg) = - (@) (("218",enc_opt encode_float_6 msg.f_SpreadOrBenchmarkCurveData_Spread) :: (("220",enc_opt encode_Currency msg.f_SpreadOrBenchmarkCurveData_BenchmarkCurveCurrency) :: (("221",enc_opt encode_string msg.f_SpreadOrBenchmarkCurveData_BenchmarkCurveName) :: (("222",enc_opt encode_string msg.f_SpreadOrBenchmarkCurveData_BenchmarkCurvePoint) :: (("662",enc_opt encode_float_6 msg.f_SpreadOrBenchmarkCurveData_BenchmarkPrice) :: (("663",enc_opt encode_int msg.f_SpreadOrBenchmarkCurveData_BenchmarkPriceType) :: (("699",enc_opt encode_string msg.f_SpreadOrBenchmarkCurveData_BenchmarkSecurityID) :: (("761",enc_opt encode_string msg.f_SpreadOrBenchmarkCurveData_BenchmarkSecurityIDSource) :: [])))))))) [] -;; - -let encode_MiscFeesGrp (msg) = - (@) (("137",enc_opt encode_float_6 msg.f_MiscFeesGrp_MiscFeeAmt) :: (("138",enc_opt encode_Currency msg.f_MiscFeesGrp_MiscFeeCurr) :: (("139",enc_opt encode_MiscFeeType msg.f_MiscFeesGrp_MiscFeeType) :: (("891",enc_opt encode_MiscFeeBasis msg.f_MiscFeesGrp_MiscFeeBasis) :: [])))) [] -;; - -let encode_TrdgSesGrp (msg) = - (@) (("336",enc_opt encode_string msg.f_TrdgSesGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_TrdgSesGrp_TradingSessionSubID) :: [])) [] -;; - -let encode_ContraGrp (msg) = - (@) (("375",enc_opt encode_string msg.f_ContraGrp_ContraBroker) :: (("337",enc_opt encode_string msg.f_ContraGrp_ContraTrader) :: (("437",enc_opt encode_float_6 msg.f_ContraGrp_ContraTradeQty) :: (("438",enc_opt encode_UTCTimestamp_milli msg.f_ContraGrp_ContraTradeTime) :: (("655",enc_opt encode_string msg.f_ContraGrp_ContraLegRefID) :: []))))) [] -;; - -let encode_BidCompReqGrp (msg) = - (@) (("66",enc_opt encode_string msg.f_BidCompReqGrp_ListID) :: (("54",enc_opt encode_Side msg.f_BidCompReqGrp_Side) :: (("336",enc_opt encode_string msg.f_BidCompReqGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_BidCompReqGrp_TradingSessionSubID) :: (("430",enc_opt encode_NetGrossInd msg.f_BidCompReqGrp_NetGrossInd) :: (("63",enc_opt encode_SettlType msg.f_BidCompReqGrp_SettlType) :: (("64",enc_opt encode_LocalMktDate msg.f_BidCompReqGrp_SettlDate) :: (("1",enc_opt encode_string msg.f_BidCompReqGrp_Account) :: (("660",enc_opt encode_AcctIDSource msg.f_BidCompReqGrp_AcctIDSource) :: []))))))))) [] -;; - -let encode_ContAmtGrp (msg) = - (@) (("519",enc_opt encode_ContAmtType msg.f_ContAmtGrp_ContAmtType) :: (("520",enc_opt encode_float msg.f_ContAmtGrp_ContAmtValue) :: (("521",enc_opt encode_Currency msg.f_ContAmtGrp_ContAmtCurr) :: []))) [] -;; - -let encode_CollInqQualGrp (msg) = - (@) (("896",enc_opt encode_CollInquiryQualifier msg.f_CollInqQualGrp_CollInquiryQualifier) :: []) [] -;; - -let encode_ExecsGrp (msg) = - (@) (("17",enc_opt encode_string msg.f_ExecsGrp_ExecID) :: []) [] -;; - -let encode_AllocAckGrp (msg) = - (@) (("79",enc_opt encode_string msg.f_AllocAckGrp_AllocAccount) :: (("661",enc_opt encode_int msg.f_AllocAckGrp_AllocAcctIDSource) :: (("366",enc_opt encode_float_6 msg.f_AllocAckGrp_AllocPrice) :: (("467",enc_opt encode_string msg.f_AllocAckGrp_IndividualAllocID) :: (("776",enc_opt encode_int msg.f_AllocAckGrp_IndividualAllocRejCode) :: (("161",enc_opt encode_string msg.f_AllocAckGrp_AllocText) :: (("360",enc_opt encode_int msg.f_AllocAckGrp_EncodedAllocTextLen) :: (("361",enc_opt encode_string msg.f_AllocAckGrp_EncodedAllocText) :: [])))))))) [] -;; - -let encode_DiscretionInstructions (msg) = - (@) (("388",enc_opt encode_DiscretionInst msg.f_DiscretionInstructions_DiscretionInst) :: (("389",enc_opt encode_float msg.f_DiscretionInstructions_DiscretionOffsetValue) :: (("841",enc_opt encode_DiscretionMoveType msg.f_DiscretionInstructions_DiscretionMoveType) :: (("842",enc_opt encode_DiscretionOffsetType msg.f_DiscretionInstructions_DiscretionOffsetType) :: (("843",enc_opt encode_DiscretionLimitType msg.f_DiscretionInstructions_DiscretionLimitType) :: (("844",enc_opt encode_DiscretionRoundDirection msg.f_DiscretionInstructions_DiscretionRoundDirection) :: (("846",enc_opt encode_DiscretionScope msg.f_DiscretionInstructions_DiscretionScope) :: []))))))) [] -;; - -let encode_PositionAmountData (msg) = - (@) (("707",enc_opt encode_PosAmtType msg.f_PositionAmountData_PosAmtType) :: (("708",enc_opt encode_float_6 msg.f_PositionAmountData_PosAmt) :: [])) [] -;; - -let encode_MDRjctGrp (msg) = - (@) (("817",enc_opt encode_string msg.f_MDRjctGrp_AltMDSourceID) :: []) [] -;; - -let encode_AttrbGrp (msg) = - (@) (("871",enc_opt encode_InstrAttribType msg.f_AttrbGrp_InstrAttribType) :: (("872",enc_opt encode_string msg.f_AttrbGrp_InstrAttribValue) :: [])) [] -;; - -let encode_TrdRegTimestamps (msg) = - (@) (("769",enc_opt encode_UTCTimestamp_milli msg.f_TrdRegTimestamps_TrdRegTimestamp) :: (("770",enc_opt encode_TrdRegTimestampType msg.f_TrdRegTimestamps_TrdRegTimestampType) :: (("771",enc_opt encode_string msg.f_TrdRegTimestamps_TrdRegTimestampOrigin) :: []))) [] -;; - -let encode_RoutingGrp (msg) = - (@) (("216",enc_opt encode_RoutingType msg.f_RoutingGrp_RoutingType) :: (("217",enc_opt encode_string msg.f_RoutingGrp_RoutingID) :: [])) [] -;; - -let encode_CpctyConfGrp (msg) = - (@) (("528",enc_opt encode_OrderCapacity msg.f_CpctyConfGrp_OrderCapacity) :: (("529",enc_opt encode_OrderRestrictions msg.f_CpctyConfGrp_OrderRestrictions) :: (("863",enc_opt encode_float_6 msg.f_CpctyConfGrp_OrderCapacityQty) :: []))) [] -;; - -let encode_YieldData (msg) = - (@) (("235",enc_opt encode_YieldType msg.f_YieldData_YieldType) :: (("236",enc_opt encode_float_6 msg.f_YieldData_Yield) :: (("701",enc_opt encode_LocalMktDate msg.f_YieldData_YieldCalcDate) :: (("696",enc_opt encode_LocalMktDate msg.f_YieldData_YieldRedemptionDate) :: (("697",enc_opt encode_float_6 msg.f_YieldData_YieldRedemptionPrice) :: (("698",enc_opt encode_int msg.f_YieldData_YieldRedemptionPriceType) :: [])))))) [] -;; - -let encode_CompIDStatGrp (msg) = - (@) (("930",enc_opt encode_string msg.f_CompIDStatGrp_RefCompID) :: (("931",enc_opt encode_string msg.f_CompIDStatGrp_RefSubID) :: (("283",enc_opt encode_string msg.f_CompIDStatGrp_LocationID) :: (("284",enc_opt encode_string msg.f_CompIDStatGrp_DeskID) :: (("928",enc_opt encode_StatusValue msg.f_CompIDStatGrp_StatusValue) :: (("929",enc_opt encode_string msg.f_CompIDStatGrp_StatusText) :: [])))))) [] -;; - -let encode_NstdPtys3SubGrp (msg) = - (@) (("953",enc_opt encode_string msg.f_NstdPtys3SubGrp_Nested3PartySubID) :: (("954",enc_opt encode_int msg.f_NstdPtys3SubGrp_Nested3PartySubIDType) :: [])) [] -;; - -let encode_ClrInstGrp (msg) = - (@) (("577",enc_opt encode_ClearingInstruction msg.f_ClrInstGrp_ClearingInstruction) :: []) [] -;; - -let encode_NstdPtys2SubGrp (msg) = - (@) (("760",enc_opt encode_string msg.f_NstdPtys2SubGrp_Nested2PartySubID) :: (("807",enc_opt encode_int msg.f_NstdPtys2SubGrp_Nested2PartySubIDType) :: [])) [] -;; - -let encode_AffectedOrdGrp (msg) = - (@) (("41",enc_opt encode_string msg.f_AffectedOrdGrp_OrigClOrdID) :: (("535",enc_opt encode_string msg.f_AffectedOrdGrp_AffectedOrderID) :: (("536",enc_opt encode_string msg.f_AffectedOrdGrp_AffectedSecondaryOrderID) :: []))) [] -;; - -let encode_FinancingDetails (msg) = - (@) (("913",enc_opt encode_string msg.f_FinancingDetails_AgreementDesc) :: (("914",enc_opt encode_string msg.f_FinancingDetails_AgreementID) :: (("915",enc_opt encode_LocalMktDate msg.f_FinancingDetails_AgreementDate) :: (("918",enc_opt encode_Currency msg.f_FinancingDetails_AgreementCurrency) :: (("788",enc_opt encode_TerminationType msg.f_FinancingDetails_TerminationType) :: (("916",enc_opt encode_LocalMktDate msg.f_FinancingDetails_StartDate) :: (("917",enc_opt encode_LocalMktDate msg.f_FinancingDetails_EndDate) :: (("919",enc_opt encode_DeliveryType msg.f_FinancingDetails_DeliveryType) :: (("898",enc_opt encode_float_6 msg.f_FinancingDetails_MarginRatio) :: []))))))))) [] -;; - -let encode_TrdCapDtGrp (msg) = - (@) (("75",enc_opt encode_LocalMktDate msg.f_TrdCapDtGrp_TradeDate) :: (("60",enc_opt encode_UTCTimestamp_milli msg.f_TrdCapDtGrp_TransactTime) :: [])) [] -;; let encode_OrderQtyData (msg) = - (@) (("38",enc_opt encode_float_6 msg.f_OrderQtyData_OrderQty) :: (("152",enc_opt encode_float_6 msg.f_OrderQtyData_CashOrderQty) :: (("516",enc_opt encode_float_6 msg.f_OrderQtyData_OrderPercent) :: (("468",enc_opt encode_RoundingDirection msg.f_OrderQtyData_RoundingDirection) :: (("469",enc_opt encode_float msg.f_OrderQtyData_RoundingModulus) :: []))))) [] -;; - -let encode_TrdCollGrp (msg) = - (@) (("571",enc_opt encode_string msg.f_TrdCollGrp_TradeReportID) :: (("818",enc_opt encode_string msg.f_TrdCollGrp_SecondaryTradeReportID) :: [])) [] -;; - -let encode_PegInstructions (msg) = - (@) (("211",enc_opt encode_float msg.f_PegInstructions_PegOffsetValue) :: (("835",enc_opt encode_PegMoveType msg.f_PegInstructions_PegMoveType) :: (("836",enc_opt encode_PegOffsetType msg.f_PegInstructions_PegOffsetType) :: (("837",enc_opt encode_PegLimitType msg.f_PegInstructions_PegLimitType) :: (("838",enc_opt encode_PegRoundDirection msg.f_PegInstructions_PegRoundDirection) :: (("840",enc_opt encode_PegScope msg.f_PegInstructions_PegScope) :: [])))))) [] -;; - -let encode_interval (msg) = - (@) (("",enc_opt encode_UTCTimestamp_milli msg.f_interval_start_time) :: (("",enc_opt encode_Duration msg.f_interval_duration) :: [])) [] -;; - -let encode_RgstDistInstGrp (msg) = - (@) (("477",enc_opt encode_DistribPaymentMethod msg.f_RgstDistInstGrp_DistribPaymentMethod) :: (("512",enc_opt encode_float_6 msg.f_RgstDistInstGrp_DistribPercentage) :: (("478",enc_opt encode_Currency msg.f_RgstDistInstGrp_CashDistribCurr) :: (("498",enc_opt encode_string msg.f_RgstDistInstGrp_CashDistribAgentName) :: (("499",enc_opt encode_string msg.f_RgstDistInstGrp_CashDistribAgentCode) :: (("500",enc_opt encode_string msg.f_RgstDistInstGrp_CashDistribAgentAcctNumber) :: (("501",enc_opt encode_string msg.f_RgstDistInstGrp_CashDistribPayRef) :: (("502",enc_opt encode_string msg.f_RgstDistInstGrp_CashDistribAgentAcctName) :: [])))))))) [] -;; - -let encode_ExecCollGrp (msg) = - (@) (("17",enc_opt encode_string msg.f_ExecCollGrp_ExecID) :: []) [] -;; - -let encode_CompIDReqGrp (msg) = - (@) (("930",enc_opt encode_string msg.f_CompIDReqGrp_RefCompID) :: (("931",enc_opt encode_string msg.f_CompIDReqGrp_RefSubID) :: (("283",enc_opt encode_string msg.f_CompIDReqGrp_LocationID) :: (("284",enc_opt encode_string msg.f_CompIDReqGrp_DeskID) :: [])))) [] -;; - -let encode_NstdPtysSubGrp (msg) = - (@) (("545",enc_opt encode_string msg.f_NstdPtysSubGrp_NestedPartySubID) :: (("805",enc_opt encode_int msg.f_NstdPtysSubGrp_NestedPartySubIDType) :: [])) [] -;; - -let encode_Stipulations (msg) = - (@) (("233",enc_opt encode_StipulationType msg.f_Stipulations_StipulationType) :: (("234",enc_opt encode_string msg.f_Stipulations_StipulationValue) :: [])) [] -;; - -let encode_IOIQualGrp (msg) = - (@) (("104",enc_opt encode_IOIQualifier msg.f_IOIQualGrp_IOIQualifier) :: []) [] -;; - -let encode_LegBenchmarkCurveData (msg) = - (@) (("676",enc_opt encode_Currency msg.f_LegBenchmarkCurveData_LegBenchmarkCurveCurrency) :: (("677",enc_opt encode_string msg.f_LegBenchmarkCurveData_LegBenchmarkCurveName) :: (("678",enc_opt encode_string msg.f_LegBenchmarkCurveData_LegBenchmarkCurvePoint) :: (("679",enc_opt encode_float_6 msg.f_LegBenchmarkCurveData_LegBenchmarkPrice) :: (("680",enc_opt encode_int msg.f_LegBenchmarkCurveData_LegBenchmarkPriceType) :: []))))) [] -;; - -let encode_ExecAllocGrp (msg) = - (@) (("32",enc_opt encode_float_6 msg.f_ExecAllocGrp_LastQty) :: (("17",enc_opt encode_string msg.f_ExecAllocGrp_ExecID) :: (("527",enc_opt encode_string msg.f_ExecAllocGrp_SecondaryExecID) :: (("31",enc_opt encode_float_6 msg.f_ExecAllocGrp_LastPx) :: (("669",enc_opt encode_float_6 msg.f_ExecAllocGrp_LastParPx) :: (("29",enc_opt encode_LastCapacity msg.f_ExecAllocGrp_LastCapacity) :: [])))))) [] -;; - -let encode_CommissionData (msg) = - (@) (("12",enc_opt encode_float_6 msg.f_CommissionData_Commission) :: (("13",enc_opt encode_CommType msg.f_CommissionData_CommType) :: (("479",enc_opt encode_Currency msg.f_CommissionData_CommCurrency) :: (("497",enc_opt encode_FundRenewWaiv msg.f_CommissionData_FundRenewWaiv) :: [])))) [] + (@) ([(("38",enc_opt encode_float_6 msg.f_OrderQtyData_OrderQty))]) [] ;; let encode_PtysSubGrp (msg) = - (@) (("523",enc_opt encode_string msg.f_PtysSubGrp_PartySubID) :: (("803",enc_opt encode_PartySubIDType msg.f_PtysSubGrp_PartySubIDType) :: [])) [] -;; - -let encode_SettlPtysSubGrp (msg) = - (@) (("785",enc_opt encode_string msg.f_SettlPtysSubGrp_SettlPartySubID) :: (("786",enc_opt encode_int msg.f_SettlPtysSubGrp_SettlPartySubIDType) :: [])) [] -;; - -let encode_SecTypesGrp (msg) = - (@) (("167",enc_opt encode_SecurityType msg.f_SecTypesGrp_SecurityType) :: (("762",enc_opt encode_string msg.f_SecTypesGrp_SecuritySubType) :: (("460",enc_opt encode_Product msg.f_SecTypesGrp_Product) :: (("461",enc_opt encode_string msg.f_SecTypesGrp_CFICode) :: [])))) [] -;; - -let encode_QuotQualGrp (msg) = - (@) (("695",enc_opt encode_char msg.f_QuotQualGrp_QuoteQualifier) :: []) [] -;; - -let encode_BidDescReqGrp (msg) = - (@) (("399",enc_opt encode_BidDescriptorType msg.f_BidDescReqGrp_BidDescriptorType) :: (("400",enc_opt encode_string msg.f_BidDescReqGrp_BidDescriptor) :: (("401",enc_opt encode_SideValueInd msg.f_BidDescReqGrp_SideValueInd) :: (("404",enc_opt encode_float_6 msg.f_BidDescReqGrp_LiquidityValue) :: (("441",enc_opt encode_int msg.f_BidDescReqGrp_LiquidityNumSecurities) :: (("402",enc_opt encode_float_6 msg.f_BidDescReqGrp_LiquidityPctLow) :: (("403",enc_opt encode_float_6 msg.f_BidDescReqGrp_LiquidityPctHigh) :: (("405",enc_opt encode_float_6 msg.f_BidDescReqGrp_EFPTrackingError) :: (("406",enc_opt encode_float_6 msg.f_BidDescReqGrp_FairValue) :: (("407",enc_opt encode_float_6 msg.f_BidDescReqGrp_OutsideIndexPct) :: (("408",enc_opt encode_float_6 msg.f_BidDescReqGrp_ValueOfFutures) :: []))))))))))) [] -;; - -let encode_SecAltIDGrp (msg) = - (@) (("455",enc_opt encode_string msg.f_SecAltIDGrp_SecurityAltID) :: (("456",enc_opt encode_string msg.f_SecAltIDGrp_SecurityAltIDSource) :: [])) [] -;; - -let encode_OrdListStatGrp (msg) = - (@) (("11",enc_opt encode_string msg.f_OrdListStatGrp_ClOrdID) :: (("526",enc_opt encode_string msg.f_OrdListStatGrp_SecondaryClOrdID) :: (("14",enc_opt encode_float_6 msg.f_OrdListStatGrp_CumQty) :: (("39",enc_opt encode_OrdStatus msg.f_OrdListStatGrp_OrdStatus) :: (("636",enc_opt encode_WorkingIndicator msg.f_OrdListStatGrp_WorkingIndicator) :: (("151",enc_opt encode_float_6 msg.f_OrdListStatGrp_LeavesQty) :: (("84",enc_opt encode_float_6 msg.f_OrdListStatGrp_CxlQty) :: (("6",enc_opt encode_float_6 msg.f_OrdListStatGrp_AvgPx) :: (("103",enc_opt encode_OrdRejReason msg.f_OrdListStatGrp_OrdRejReason) :: (("58",enc_opt encode_string msg.f_OrdListStatGrp_Text) :: (("354",enc_opt encode_int msg.f_OrdListStatGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_OrdListStatGrp_EncodedText) :: [])))))))))))) [] -;; - -let encode_LegStipulations (msg) = - (@) (("688",enc_opt encode_string msg.f_LegStipulations_LegStipulationType) :: (("689",enc_opt encode_string msg.f_LegStipulations_LegStipulationValue) :: [])) [] -;; - -let encode_SettlParties (msg) = - (@) (("782",enc_opt encode_string msg.f_SettlParties_SettlPartyID) :: (("783",enc_opt encode_char msg.f_SettlParties_SettlPartyIDSource) :: (("784",enc_opt encode_int msg.f_SettlParties_SettlPartyRole) :: []))) ((@) (enc_repeat encode_SettlPtysSubGrp "801" msg.f_SettlParties_SettlPtysSubGrp) []) + (@) ([(("523",enc_opt encode_string msg.f_PtysSubGrp_PartySubID))]) [] ;; let encode_Parties (msg) = - (@) (("448",enc_opt encode_string msg.f_Parties_PartyID) :: (("447",enc_opt encode_PartyIDSource msg.f_Parties_PartyIDSource) :: (("452",enc_opt encode_PartyRole msg.f_Parties_PartyRole) :: []))) ((@) (enc_repeat encode_PtysSubGrp "802" msg.f_Parties_PtysSubGrp) []) -;; - -let encode_BidCompRspGrp (msg) = - (@) (encode_CommissionData msg.f_BidCompRspGrp_CommissionData) ((@) (("66",enc_opt encode_string msg.f_BidCompRspGrp_ListID) :: (("421",enc_opt encode_Country msg.f_BidCompRspGrp_Country) :: (("54",enc_opt encode_Side msg.f_BidCompRspGrp_Side) :: (("44",enc_opt encode_float_6 msg.f_BidCompRspGrp_Price) :: (("423",enc_opt encode_PriceType msg.f_BidCompRspGrp_PriceType) :: (("406",enc_opt encode_float_6 msg.f_BidCompRspGrp_FairValue) :: (("430",enc_opt encode_NetGrossInd msg.f_BidCompRspGrp_NetGrossInd) :: (("63",enc_opt encode_SettlType msg.f_BidCompRspGrp_SettlType) :: (("64",enc_opt encode_LocalMktDate msg.f_BidCompRspGrp_SettlDate) :: (("336",enc_opt encode_string msg.f_BidCompRspGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_BidCompRspGrp_TradingSessionSubID) :: (("58",enc_opt encode_string msg.f_BidCompRspGrp_Text) :: (("354",enc_opt encode_int msg.f_BidCompRspGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_BidCompRspGrp_EncodedText) :: [])))))))))))))) []) -;; - -let encode_NestedParties (msg) = - (@) (("524",enc_opt encode_string msg.f_NestedParties_NestedPartyID) :: (("525",enc_opt encode_char msg.f_NestedParties_NestedPartyIDSource) :: (("538",enc_opt encode_int msg.f_NestedParties_NestedPartyRole) :: []))) ((@) (enc_repeat encode_NstdPtysSubGrp "804" msg.f_NestedParties_NstdPtysSubGrp) []) -;; - -let encode_NestedParties2 (msg) = - (@) (("757",enc_opt encode_string msg.f_NestedParties2_Nested2PartyID) :: (("758",enc_opt encode_char msg.f_NestedParties2_Nested2PartyIDSource) :: (("759",enc_opt encode_int msg.f_NestedParties2_Nested2PartyRole) :: []))) ((@) (enc_repeat encode_NstdPtys2SubGrp "806" msg.f_NestedParties2_NstdPtys2SubGrp) []) -;; - -let encode_NestedParties3 (msg) = - (@) (("949",enc_opt encode_string msg.f_NestedParties3_Nested3PartyID) :: (("950",enc_opt encode_char msg.f_NestedParties3_Nested3PartyIDSource) :: (("951",enc_opt encode_int msg.f_NestedParties3_Nested3PartyRole) :: []))) ((@) (enc_repeat encode_NstdPtys3SubGrp "952" msg.f_NestedParties3_NstdPtys3SubGrp) []) + (@) ([(("448",enc_opt encode_string msg.f_Parties_PartyID));(("10002",enc_opt encode_int msg.f_Parties_PartyIndex))]) ((@) (enc_repeat encode_PtysSubGrp "802" msg.f_Parties_PtysSubGrp) []) ;; -let encode_InstrumentExtension (msg) = - (@) (("668",enc_opt encode_DeliveryForm msg.f_InstrumentExtension_DeliveryForm) :: (("869",enc_opt encode_float_6 msg.f_InstrumentExtension_PctAtRisk) :: [])) ((@) (enc_repeat encode_AttrbGrp "870" msg.f_InstrumentExtension_AttrbGrp) []) -;; - -let encode_InstrumentLeg (msg) = - (@) (("600",enc_opt encode_string msg.f_InstrumentLeg_LegSymbol) :: (("601",enc_opt encode_string msg.f_InstrumentLeg_LegSymbolSfx) :: (("602",enc_opt encode_string msg.f_InstrumentLeg_LegSecurityID) :: (("603",enc_opt encode_string msg.f_InstrumentLeg_LegSecurityIDSource) :: (("607",enc_opt encode_int msg.f_InstrumentLeg_LegProduct) :: (("608",enc_opt encode_string msg.f_InstrumentLeg_LegCFICode) :: (("609",enc_opt encode_string msg.f_InstrumentLeg_LegSecurityType) :: (("764",enc_opt encode_string msg.f_InstrumentLeg_LegSecuritySubType) :: (("610",enc_opt encode_MonthYear msg.f_InstrumentLeg_LegMaturityMonthYear) :: (("611",enc_opt encode_LocalMktDate msg.f_InstrumentLeg_LegMaturityDate) :: (("248",enc_opt encode_LocalMktDate msg.f_InstrumentLeg_LegCouponPaymentDate) :: (("249",enc_opt encode_LocalMktDate msg.f_InstrumentLeg_LegIssueDate) :: (("250",enc_opt encode_string msg.f_InstrumentLeg_LegRepoCollateralSecurityType) :: (("251",enc_opt encode_int msg.f_InstrumentLeg_LegRepurchaseTerm) :: (("252",enc_opt encode_float_6 msg.f_InstrumentLeg_LegRepurchaseRate) :: (("253",enc_opt encode_float msg.f_InstrumentLeg_LegFactor) :: (("257",enc_opt encode_string msg.f_InstrumentLeg_LegCreditRating) :: (("599",enc_opt encode_string msg.f_InstrumentLeg_LegInstrRegistry) :: (("596",enc_opt encode_Country msg.f_InstrumentLeg_LegCountryOfIssue) :: (("597",enc_opt encode_string msg.f_InstrumentLeg_LegStateOrProvinceOfIssue) :: (("598",enc_opt encode_string msg.f_InstrumentLeg_LegLocaleOfIssue) :: (("254",enc_opt encode_LocalMktDate msg.f_InstrumentLeg_LegRedemptionDate) :: (("612",enc_opt encode_float_6 msg.f_InstrumentLeg_LegStrikePrice) :: (("942",enc_opt encode_Currency msg.f_InstrumentLeg_LegStrikeCurrency) :: (("613",enc_opt encode_char msg.f_InstrumentLeg_LegOptAttribute) :: (("614",enc_opt encode_float msg.f_InstrumentLeg_LegContractMultiplier) :: (("615",enc_opt encode_float_6 msg.f_InstrumentLeg_LegCouponRate) :: (("616",enc_opt encode_Exchange msg.f_InstrumentLeg_LegSecurityExchange) :: (("617",enc_opt encode_string msg.f_InstrumentLeg_LegIssuer) :: (("618",enc_opt encode_int msg.f_InstrumentLeg_EncodedLegIssuerLen) :: (("619",enc_opt encode_string msg.f_InstrumentLeg_EncodedLegIssuer) :: (("620",enc_opt encode_string msg.f_InstrumentLeg_LegSecurityDesc) :: (("621",enc_opt encode_int msg.f_InstrumentLeg_EncodedLegSecurityDescLen) :: (("622",enc_opt encode_string msg.f_InstrumentLeg_EncodedLegSecurityDesc) :: (("623",enc_opt encode_float msg.f_InstrumentLeg_LegRatioQty) :: (("624",enc_opt encode_char msg.f_InstrumentLeg_LegSide) :: (("556",enc_opt encode_Currency msg.f_InstrumentLeg_LegCurrency) :: (("740",enc_opt encode_string msg.f_InstrumentLeg_LegPool) :: (("739",enc_opt encode_LocalMktDate msg.f_InstrumentLeg_LegDatedDate) :: (("955",enc_opt encode_MonthYear msg.f_InstrumentLeg_LegContractSettlMonth) :: (("956",enc_opt encode_LocalMktDate msg.f_InstrumentLeg_LegInterestAccrualDate) :: []))))))))))))))))))))))))))))))))))))))))) ((@) (enc_repeat encode_LegSecAltIDGrp "604" msg.f_InstrumentLeg_LegSecAltIDGrp) []) -;; - -let encode_Instrument (msg) = - (@) (("55",enc_opt encode_string msg.f_Instrument_Symbol) :: (("65",enc_opt encode_string msg.f_Instrument_SymbolSfx) :: (("48",enc_opt encode_string msg.f_Instrument_SecurityID) :: (("22",enc_opt encode_SecurityIDSource msg.f_Instrument_SecurityIDSource) :: (("460",enc_opt encode_Product msg.f_Instrument_Product) :: (("461",enc_opt encode_string msg.f_Instrument_CFICode) :: (("167",enc_opt encode_SecurityType msg.f_Instrument_SecurityType) :: (("762",enc_opt encode_string msg.f_Instrument_SecuritySubType) :: (("200",enc_opt encode_MonthYear msg.f_Instrument_MaturityMonthYear) :: (("541",enc_opt encode_LocalMktDate msg.f_Instrument_MaturityDate) :: (("224",enc_opt encode_LocalMktDate msg.f_Instrument_CouponPaymentDate) :: (("225",enc_opt encode_LocalMktDate msg.f_Instrument_IssueDate) :: (("239",enc_opt encode_string msg.f_Instrument_RepoCollateralSecurityType) :: (("226",enc_opt encode_int msg.f_Instrument_RepurchaseTerm) :: (("227",enc_opt encode_float_6 msg.f_Instrument_RepurchaseRate) :: (("228",enc_opt encode_float msg.f_Instrument_Factor) :: (("255",enc_opt encode_string msg.f_Instrument_CreditRating) :: (("543",enc_opt encode_string msg.f_Instrument_InstrRegistry) :: (("470",enc_opt encode_Country msg.f_Instrument_CountryOfIssue) :: (("471",enc_opt encode_string msg.f_Instrument_StateOrProvinceOfIssue) :: (("472",enc_opt encode_string msg.f_Instrument_LocaleOfIssue) :: (("240",enc_opt encode_LocalMktDate msg.f_Instrument_RedemptionDate) :: (("202",enc_opt encode_float_6 msg.f_Instrument_StrikePrice) :: (("947",enc_opt encode_Currency msg.f_Instrument_StrikeCurrency) :: (("206",enc_opt encode_char msg.f_Instrument_OptAttribute) :: (("231",enc_opt encode_float msg.f_Instrument_ContractMultiplier) :: (("223",enc_opt encode_float_6 msg.f_Instrument_CouponRate) :: (("207",enc_opt encode_Exchange msg.f_Instrument_SecurityExchange) :: (("106",enc_opt encode_string msg.f_Instrument_Issuer) :: (("348",enc_opt encode_int msg.f_Instrument_EncodedIssuerLen) :: (("349",enc_opt encode_string msg.f_Instrument_EncodedIssuer) :: (("107",enc_opt encode_string msg.f_Instrument_SecurityDesc) :: (("350",enc_opt encode_int msg.f_Instrument_EncodedSecurityDescLen) :: (("351",enc_opt encode_string msg.f_Instrument_EncodedSecurityDesc) :: (("691",enc_opt encode_string msg.f_Instrument_Pool) :: (("667",enc_opt encode_MonthYear msg.f_Instrument_ContractSettlMonth) :: (("875",enc_opt encode_CPProgram msg.f_Instrument_CPProgram) :: (("876",enc_opt encode_string msg.f_Instrument_CPRegType) :: (("873",enc_opt encode_LocalMktDate msg.f_Instrument_DatedDate) :: (("874",enc_opt encode_LocalMktDate msg.f_Instrument_InterestAccrualDate) :: [])))))))))))))))))))))))))))))))))))))))) ((@) (enc_repeat encode_EvntGrp "864" msg.f_Instrument_EvntGrp) ((@) (enc_repeat encode_SecAltIDGrp "454" msg.f_Instrument_SecAltIDGrp) [])) -;; - -let encode_UnderlyingInstrument (msg) = - (@) (("311",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingSymbol) :: (("312",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingSymbolSfx) :: (("309",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingSecurityID) :: (("305",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingSecurityIDSource) :: (("462",enc_opt encode_int msg.f_UnderlyingInstrument_UnderlyingProduct) :: (("463",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingCFICode) :: (("310",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingSecurityType) :: (("763",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingSecuritySubType) :: (("313",enc_opt encode_MonthYear msg.f_UnderlyingInstrument_UnderlyingMaturityMonthYear) :: (("542",enc_opt encode_LocalMktDate msg.f_UnderlyingInstrument_UnderlyingMaturityDate) :: (("241",enc_opt encode_LocalMktDate msg.f_UnderlyingInstrument_UnderlyingCouponPaymentDate) :: (("242",enc_opt encode_LocalMktDate msg.f_UnderlyingInstrument_UnderlyingIssueDate) :: (("243",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingRepoCollateralSecurityType) :: (("244",enc_opt encode_int msg.f_UnderlyingInstrument_UnderlyingRepurchaseTerm) :: (("245",enc_opt encode_float_6 msg.f_UnderlyingInstrument_UnderlyingRepurchaseRate) :: (("246",enc_opt encode_float msg.f_UnderlyingInstrument_UnderlyingFactor) :: (("256",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingCreditRating) :: (("595",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingInstrRegistry) :: (("592",enc_opt encode_Country msg.f_UnderlyingInstrument_UnderlyingCountryOfIssue) :: (("593",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingStateOrProvinceOfIssue) :: (("594",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingLocaleOfIssue) :: (("247",enc_opt encode_LocalMktDate msg.f_UnderlyingInstrument_UnderlyingRedemptionDate) :: (("316",enc_opt encode_float_6 msg.f_UnderlyingInstrument_UnderlyingStrikePrice) :: (("941",enc_opt encode_Currency msg.f_UnderlyingInstrument_UnderlyingStrikeCurrency) :: (("317",enc_opt encode_char msg.f_UnderlyingInstrument_UnderlyingOptAttribute) :: (("436",enc_opt encode_float msg.f_UnderlyingInstrument_UnderlyingContractMultiplier) :: (("435",enc_opt encode_float_6 msg.f_UnderlyingInstrument_UnderlyingCouponRate) :: (("308",enc_opt encode_Exchange msg.f_UnderlyingInstrument_UnderlyingSecurityExchange) :: (("306",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingIssuer) :: (("362",enc_opt encode_int msg.f_UnderlyingInstrument_EncodedUnderlyingIssuerLen) :: (("363",enc_opt encode_string msg.f_UnderlyingInstrument_EncodedUnderlyingIssuer) :: (("307",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingSecurityDesc) :: (("364",enc_opt encode_int msg.f_UnderlyingInstrument_EncodedUnderlyingSecurityDescLen) :: (("365",enc_opt encode_string msg.f_UnderlyingInstrument_EncodedUnderlyingSecurityDesc) :: (("877",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingCPProgram) :: (("878",enc_opt encode_string msg.f_UnderlyingInstrument_UnderlyingCPRegType) :: (("318",enc_opt encode_Currency msg.f_UnderlyingInstrument_UnderlyingCurrency) :: (("879",enc_opt encode_float_6 msg.f_UnderlyingInstrument_UnderlyingQty) :: (("810",enc_opt encode_float_6 msg.f_UnderlyingInstrument_UnderlyingPx) :: (("882",enc_opt encode_float_6 msg.f_UnderlyingInstrument_UnderlyingDirtyPrice) :: (("883",enc_opt encode_float_6 msg.f_UnderlyingInstrument_UnderlyingEndPrice) :: (("884",enc_opt encode_float_6 msg.f_UnderlyingInstrument_UnderlyingStartValue) :: (("885",enc_opt encode_float_6 msg.f_UnderlyingInstrument_UnderlyingCurrentValue) :: (("886",enc_opt encode_float_6 msg.f_UnderlyingInstrument_UnderlyingEndValue) :: [])))))))))))))))))))))))))))))))))))))))))))) ((@) (enc_repeat encode_UnderlyingStipulations "887" msg.f_UnderlyingInstrument_UnderlyingStipulations) ((@) (enc_repeat encode_UndSecAltIDGrp "457" msg.f_UnderlyingInstrument_UndSecAltIDGrp) [])) -;; - -let encode_UndInstrmtCollGrp (msg) = - (@) (encode_UnderlyingInstrument msg.f_UndInstrmtCollGrp_UnderlyingInstrument) ((@) (("944",enc_opt encode_CollAction msg.f_UndInstrmtCollGrp_CollAction) :: []) []) -;; - -let encode_PosUndInstrmtGrp (msg) = - (@) (encode_UnderlyingInstrument msg.f_PosUndInstrmtGrp_UnderlyingInstrument) ((@) (("732",enc_opt encode_float_6 msg.f_PosUndInstrmtGrp_UnderlyingSettlPrice) :: (("733",enc_opt encode_int msg.f_PosUndInstrmtGrp_UnderlyingSettlPriceType) :: [])) []) -;; - -let encode_UndInstrmtGrp (msg) = - (@) (encode_UnderlyingInstrument msg.f_UndInstrmtGrp_UnderlyingInstrument) ((@) [] []) -;; - -let encode_UndInstrmtStrkPxGrp (msg) = - (@) (encode_UnderlyingInstrument msg.f_UndInstrmtStrkPxGrp_UnderlyingInstrument) ((@) (("140",enc_opt encode_float_6 msg.f_UndInstrmtStrkPxGrp_PrevClosePx) :: (("11",enc_opt encode_string msg.f_UndInstrmtStrkPxGrp_ClOrdID) :: (("526",enc_opt encode_string msg.f_UndInstrmtStrkPxGrp_SecondaryClOrdID) :: (("54",enc_opt encode_Side msg.f_UndInstrmtStrkPxGrp_Side) :: (("44",enc_opt encode_float_6 msg.f_UndInstrmtStrkPxGrp_Price) :: (("15",enc_opt encode_Currency msg.f_UndInstrmtStrkPxGrp_Currency) :: (("58",enc_opt encode_string msg.f_UndInstrmtStrkPxGrp_Text) :: (("354",enc_opt encode_int msg.f_UndInstrmtStrkPxGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_UndInstrmtStrkPxGrp_EncodedText) :: []))))))))) []) -;; - -let encode_InstrmtGrp (msg) = - (@) (encode_Instrument msg.f_InstrmtGrp_Instrument) ((@) [] []) -;; - -let encode_InstrmtStrkPxGrp (msg) = - (@) (encode_Instrument msg.f_InstrmtStrkPxGrp_Instrument) ((@) [] []) -;; - -let encode_InstrmtLegSecListGrp (msg) = - (@) (encode_LegBenchmarkCurveData msg.f_InstrmtLegSecListGrp_LegBenchmarkCurveData) ((@) (encode_InstrumentLeg msg.f_InstrmtLegSecListGrp_InstrumentLeg) ((@) (("690",enc_opt encode_LegSwapType msg.f_InstrmtLegSecListGrp_LegSwapType) :: (("587",enc_opt encode_char msg.f_InstrmtLegSecListGrp_LegSettlType) :: [])) ((@) (enc_repeat encode_LegStipulations "683" msg.f_InstrmtLegSecListGrp_LegStipulations) []))) -;; - -let encode_InstrmtLegGrp (msg) = - (@) (encode_InstrumentLeg msg.f_InstrmtLegGrp_InstrumentLeg) ((@) [] []) -;; - -let encode_InstrmtLegIOIGrp (msg) = - (@) (encode_InstrumentLeg msg.f_InstrmtLegIOIGrp_InstrumentLeg) ((@) (("682",enc_opt encode_string msg.f_InstrmtLegIOIGrp_LegIOIQty) :: []) ((@) (enc_repeat encode_LegStipulations "683" msg.f_InstrmtLegIOIGrp_LegStipulations) [])) -;; - -let encode_PreAllocMlegGrp (msg) = - (@) (("79",enc_opt encode_string msg.f_PreAllocMlegGrp_AllocAccount) :: (("661",enc_opt encode_int msg.f_PreAllocMlegGrp_AllocAcctIDSource) :: (("736",enc_opt encode_Currency msg.f_PreAllocMlegGrp_AllocSettlCurrency) :: (("467",enc_opt encode_string msg.f_PreAllocMlegGrp_IndividualAllocID) :: (("80",enc_opt encode_float_6 msg.f_PreAllocMlegGrp_AllocQty) :: []))))) ((@) (enc_repeat encode_NestedParties3 "948" msg.f_PreAllocMlegGrp_NestedParties3) []) -;; - -let encode_TrdAllocGrp (msg) = - (@) (("79",enc_opt encode_string msg.f_TrdAllocGrp_AllocAccount) :: (("661",enc_opt encode_int msg.f_TrdAllocGrp_AllocAcctIDSource) :: (("736",enc_opt encode_Currency msg.f_TrdAllocGrp_AllocSettlCurrency) :: (("467",enc_opt encode_string msg.f_TrdAllocGrp_IndividualAllocID) :: (("80",enc_opt encode_float_6 msg.f_TrdAllocGrp_AllocQty) :: []))))) ((@) (enc_repeat encode_NestedParties2 "756" msg.f_TrdAllocGrp_NestedParties2) []) -;; - -let encode_LegPreAllocGrp (msg) = - (@) (("671",enc_opt encode_string msg.f_LegPreAllocGrp_LegAllocAccount) :: (("672",enc_opt encode_string msg.f_LegPreAllocGrp_LegIndividualAllocID) :: (("673",enc_opt encode_float_6 msg.f_LegPreAllocGrp_LegAllocQty) :: (("674",enc_opt encode_string msg.f_LegPreAllocGrp_LegAllocAcctIDSource) :: (("675",enc_opt encode_Currency msg.f_LegPreAllocGrp_LegSettlCurrency) :: []))))) ((@) (enc_repeat encode_NestedParties2 "756" msg.f_LegPreAllocGrp_NestedParties2) []) -;; - -let encode_OrdAllocGrp (msg) = - (@) (("11",enc_opt encode_string msg.f_OrdAllocGrp_ClOrdID) :: (("37",enc_opt encode_string msg.f_OrdAllocGrp_OrderID) :: (("198",enc_opt encode_string msg.f_OrdAllocGrp_SecondaryOrderID) :: (("526",enc_opt encode_string msg.f_OrdAllocGrp_SecondaryClOrdID) :: (("66",enc_opt encode_string msg.f_OrdAllocGrp_ListID) :: (("38",enc_opt encode_float_6 msg.f_OrdAllocGrp_OrderQty) :: (("799",enc_opt encode_float_6 msg.f_OrdAllocGrp_OrderAvgPx) :: (("800",enc_opt encode_float_6 msg.f_OrdAllocGrp_OrderBookingQty) :: [])))))))) ((@) (enc_repeat encode_NestedParties2 "756" msg.f_OrdAllocGrp_NestedParties2) []) -;; - -let encode_LegQuotStatGrp (msg) = - (@) (encode_InstrumentLeg msg.f_LegQuotStatGrp_InstrumentLeg) ((@) (("687",enc_opt encode_float_6 msg.f_LegQuotStatGrp_LegQty) :: (("690",enc_opt encode_LegSwapType msg.f_LegQuotStatGrp_LegSwapType) :: (("587",enc_opt encode_char msg.f_LegQuotStatGrp_LegSettlType) :: (("588",enc_opt encode_LocalMktDate msg.f_LegQuotStatGrp_LegSettlDate) :: [])))) ((@) (enc_repeat encode_NestedParties "539" msg.f_LegQuotStatGrp_NestedParties) ((@) (enc_repeat encode_LegStipulations "683" msg.f_LegQuotStatGrp_LegStipulations) []))) -;; - -let encode_PreAllocGrp (msg) = - (@) (("79",enc_opt encode_string msg.f_PreAllocGrp_AllocAccount) :: (("661",enc_opt encode_int msg.f_PreAllocGrp_AllocAcctIDSource) :: (("736",enc_opt encode_Currency msg.f_PreAllocGrp_AllocSettlCurrency) :: (("467",enc_opt encode_string msg.f_PreAllocGrp_IndividualAllocID) :: (("80",enc_opt encode_float_6 msg.f_PreAllocGrp_AllocQty) :: []))))) ((@) (enc_repeat encode_NestedParties "539" msg.f_PreAllocGrp_NestedParties) []) -;; - -let encode_RgstDtlsGrp (msg) = - (@) (("509",enc_opt encode_string msg.f_RgstDtlsGrp_RegistDtls) :: (("511",enc_opt encode_string msg.f_RgstDtlsGrp_RegistEmail) :: (("474",enc_opt encode_string msg.f_RgstDtlsGrp_MailingDtls) :: (("482",enc_opt encode_string msg.f_RgstDtlsGrp_MailingInst) :: (("522",enc_opt encode_OwnerType msg.f_RgstDtlsGrp_OwnerType) :: (("486",enc_opt encode_LocalMktDate msg.f_RgstDtlsGrp_DateOfBirth) :: (("475",enc_opt encode_Country msg.f_RgstDtlsGrp_InvestorCountryOfResidence) :: []))))))) ((@) (enc_repeat encode_NestedParties "539" msg.f_RgstDtlsGrp_NestedParties) []) -;; - -let encode_InstrmtLegExecGrp (msg) = - (@) (encode_InstrumentLeg msg.f_InstrmtLegExecGrp_InstrumentLeg) ((@) (("687",enc_opt encode_float_6 msg.f_InstrmtLegExecGrp_LegQty) :: (("690",enc_opt encode_LegSwapType msg.f_InstrmtLegExecGrp_LegSwapType) :: (("564",enc_opt encode_char msg.f_InstrmtLegExecGrp_LegPositionEffect) :: (("565",enc_opt encode_int msg.f_InstrmtLegExecGrp_LegCoveredOrUncovered) :: (("654",enc_opt encode_string msg.f_InstrmtLegExecGrp_LegRefID) :: (("566",enc_opt encode_float_6 msg.f_InstrmtLegExecGrp_LegPrice) :: (("587",enc_opt encode_char msg.f_InstrmtLegExecGrp_LegSettlType) :: (("588",enc_opt encode_LocalMktDate msg.f_InstrmtLegExecGrp_LegSettlDate) :: (("637",enc_opt encode_float_6 msg.f_InstrmtLegExecGrp_LegLastPx) :: []))))))))) ((@) (enc_repeat encode_NestedParties "539" msg.f_InstrmtLegExecGrp_NestedParties) ((@) (enc_repeat encode_LegStipulations "683" msg.f_InstrmtLegExecGrp_LegStipulations) []))) -;; - -let encode_LegQuotGrp (msg) = - (@) (encode_LegBenchmarkCurveData msg.f_LegQuotGrp_LegBenchmarkCurveData) ((@) (encode_InstrumentLeg msg.f_LegQuotGrp_InstrumentLeg) ((@) (("687",enc_opt encode_float_6 msg.f_LegQuotGrp_LegQty) :: (("690",enc_opt encode_LegSwapType msg.f_LegQuotGrp_LegSwapType) :: (("587",enc_opt encode_char msg.f_LegQuotGrp_LegSettlType) :: (("588",enc_opt encode_LocalMktDate msg.f_LegQuotGrp_LegSettlDate) :: (("686",enc_opt encode_int msg.f_LegQuotGrp_LegPriceType) :: (("681",enc_opt encode_float_6 msg.f_LegQuotGrp_LegBidPx) :: (("684",enc_opt encode_float_6 msg.f_LegQuotGrp_LegOfferPx) :: []))))))) ((@) (enc_repeat encode_NestedParties "539" msg.f_LegQuotGrp_NestedParties) ((@) (enc_repeat encode_LegStipulations "683" msg.f_LegQuotGrp_LegStipulations) [])))) -;; - -let encode_QuotReqLegsGrp (msg) = - (@) (encode_LegBenchmarkCurveData msg.f_QuotReqLegsGrp_LegBenchmarkCurveData) ((@) (encode_InstrumentLeg msg.f_QuotReqLegsGrp_InstrumentLeg) ((@) (("687",enc_opt encode_float_6 msg.f_QuotReqLegsGrp_LegQty) :: (("690",enc_opt encode_LegSwapType msg.f_QuotReqLegsGrp_LegSwapType) :: (("587",enc_opt encode_char msg.f_QuotReqLegsGrp_LegSettlType) :: (("588",enc_opt encode_LocalMktDate msg.f_QuotReqLegsGrp_LegSettlDate) :: [])))) ((@) (enc_repeat encode_NestedParties "539" msg.f_QuotReqLegsGrp_NestedParties) ((@) (enc_repeat encode_LegStipulations "683" msg.f_QuotReqLegsGrp_LegStipulations) [])))) -;; - -let encode_PositionQty (msg) = - (@) (("703",enc_opt encode_PosType msg.f_PositionQty_PosType) :: (("704",enc_opt encode_float_6 msg.f_PositionQty_LongQty) :: (("705",enc_opt encode_float_6 msg.f_PositionQty_ShortQty) :: (("706",enc_opt encode_PosQtyStatus msg.f_PositionQty_PosQtyStatus) :: [])))) ((@) (enc_repeat encode_NestedParties "539" msg.f_PositionQty_NestedParties) []) -;; - -let encode_TrdInstrmtLegGrp (msg) = - (@) (encode_InstrumentLeg msg.f_TrdInstrmtLegGrp_InstrumentLeg) ((@) (("687",enc_opt encode_float_6 msg.f_TrdInstrmtLegGrp_LegQty) :: (("690",enc_opt encode_LegSwapType msg.f_TrdInstrmtLegGrp_LegSwapType) :: (("564",enc_opt encode_char msg.f_TrdInstrmtLegGrp_LegPositionEffect) :: (("565",enc_opt encode_int msg.f_TrdInstrmtLegGrp_LegCoveredOrUncovered) :: (("654",enc_opt encode_string msg.f_TrdInstrmtLegGrp_LegRefID) :: (("566",enc_opt encode_float_6 msg.f_TrdInstrmtLegGrp_LegPrice) :: (("587",enc_opt encode_char msg.f_TrdInstrmtLegGrp_LegSettlType) :: (("588",enc_opt encode_LocalMktDate msg.f_TrdInstrmtLegGrp_LegSettlDate) :: (("637",enc_opt encode_float_6 msg.f_TrdInstrmtLegGrp_LegLastPx) :: []))))))))) ((@) (enc_repeat encode_NestedParties "539" msg.f_TrdInstrmtLegGrp_NestedParties) ((@) (enc_repeat encode_LegStipulations "683" msg.f_TrdInstrmtLegGrp_LegStipulations) []))) -;; - -let encode_SideCrossOrdCxlGrp (msg) = - (@) (encode_OrderQtyData msg.f_SideCrossOrdCxlGrp_OrderQtyData) ((@) (("54",enc_opt encode_Side msg.f_SideCrossOrdCxlGrp_Side) :: (("41",enc_opt encode_string msg.f_SideCrossOrdCxlGrp_OrigClOrdID) :: (("11",enc_opt encode_string msg.f_SideCrossOrdCxlGrp_ClOrdID) :: (("526",enc_opt encode_string msg.f_SideCrossOrdCxlGrp_SecondaryClOrdID) :: (("583",enc_opt encode_string msg.f_SideCrossOrdCxlGrp_ClOrdLinkID) :: (("586",enc_opt encode_UTCTimestamp_milli msg.f_SideCrossOrdCxlGrp_OrigOrdModTime) :: (("229",enc_opt encode_LocalMktDate msg.f_SideCrossOrdCxlGrp_TradeOriginationDate) :: (("75",enc_opt encode_LocalMktDate msg.f_SideCrossOrdCxlGrp_TradeDate) :: (("376",enc_opt encode_string msg.f_SideCrossOrdCxlGrp_ComplianceID) :: (("58",enc_opt encode_string msg.f_SideCrossOrdCxlGrp_Text) :: (("354",enc_opt encode_int msg.f_SideCrossOrdCxlGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_SideCrossOrdCxlGrp_EncodedText) :: [])))))))))))) ((@) (enc_repeat encode_Parties "453" msg.f_SideCrossOrdCxlGrp_Parties) [])) -;; - -let encode_DlvyInstGrp (msg) = - (@) (("165",enc_opt encode_SettlInstSource msg.f_DlvyInstGrp_SettlInstSource) :: (("787",enc_opt encode_DlvyInstType msg.f_DlvyInstGrp_DlvyInstType) :: [])) ((@) (enc_repeat encode_SettlParties "781" msg.f_DlvyInstGrp_SettlParties) []) -;; - -let encode_SettlInstructionsData (msg) = - (@) (("172",enc_opt encode_SettlDeliveryType msg.f_SettlInstructionsData_SettlDeliveryType) :: (("169",enc_opt encode_StandInstDbType msg.f_SettlInstructionsData_StandInstDbType) :: (("170",enc_opt encode_string msg.f_SettlInstructionsData_StandInstDbName) :: (("171",enc_opt encode_string msg.f_SettlInstructionsData_StandInstDbID) :: [])))) ((@) (enc_repeat encode_DlvyInstGrp "85" msg.f_SettlInstructionsData_DlvyInstGrp) []) -;; - -let encode_SideCrossOrdModGrp (msg) = - (@) (encode_CommissionData msg.f_SideCrossOrdModGrp_CommissionData) ((@) (encode_OrderQtyData msg.f_SideCrossOrdModGrp_OrderQtyData) ((@) (("54",enc_opt encode_Side msg.f_SideCrossOrdModGrp_Side) :: (("11",enc_opt encode_string msg.f_SideCrossOrdModGrp_ClOrdID) :: (("526",enc_opt encode_string msg.f_SideCrossOrdModGrp_SecondaryClOrdID) :: (("583",enc_opt encode_string msg.f_SideCrossOrdModGrp_ClOrdLinkID) :: (("229",enc_opt encode_LocalMktDate msg.f_SideCrossOrdModGrp_TradeOriginationDate) :: (("75",enc_opt encode_LocalMktDate msg.f_SideCrossOrdModGrp_TradeDate) :: (("1",enc_opt encode_string msg.f_SideCrossOrdModGrp_Account) :: (("660",enc_opt encode_AcctIDSource msg.f_SideCrossOrdModGrp_AcctIDSource) :: (("581",enc_opt encode_AccountType msg.f_SideCrossOrdModGrp_AccountType) :: (("589",enc_opt encode_DayBookingInst msg.f_SideCrossOrdModGrp_DayBookingInst) :: (("590",enc_opt encode_BookingUnit msg.f_SideCrossOrdModGrp_BookingUnit) :: (("591",enc_opt encode_PreallocMethod msg.f_SideCrossOrdModGrp_PreallocMethod) :: (("70",enc_opt encode_string msg.f_SideCrossOrdModGrp_AllocID) :: (("854",enc_opt encode_QtyType msg.f_SideCrossOrdModGrp_QtyType) :: (("528",enc_opt encode_OrderCapacity msg.f_SideCrossOrdModGrp_OrderCapacity) :: (("529",enc_opt encode_OrderRestrictions msg.f_SideCrossOrdModGrp_OrderRestrictions) :: (("582",enc_opt encode_CustOrderCapacity msg.f_SideCrossOrdModGrp_CustOrderCapacity) :: (("121",enc_opt encode_ForexReq msg.f_SideCrossOrdModGrp_ForexReq) :: (("120",enc_opt encode_Currency msg.f_SideCrossOrdModGrp_SettlCurrency) :: (("775",enc_opt encode_BookingType msg.f_SideCrossOrdModGrp_BookingType) :: (("58",enc_opt encode_string msg.f_SideCrossOrdModGrp_Text) :: (("354",enc_opt encode_int msg.f_SideCrossOrdModGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_SideCrossOrdModGrp_EncodedText) :: (("77",enc_opt encode_PositionEffect msg.f_SideCrossOrdModGrp_PositionEffect) :: (("203",enc_opt encode_CoveredOrUncovered msg.f_SideCrossOrdModGrp_CoveredOrUncovered) :: (("544",enc_opt encode_CashMargin msg.f_SideCrossOrdModGrp_CashMargin) :: (("635",enc_opt encode_ClearingFeeIndicator msg.f_SideCrossOrdModGrp_ClearingFeeIndicator) :: (("377",enc_opt encode_SolicitedFlag msg.f_SideCrossOrdModGrp_SolicitedFlag) :: (("659",enc_opt encode_string msg.f_SideCrossOrdModGrp_SideComplianceID) :: []))))))))))))))))))))))))))))) ((@) (enc_repeat encode_PreAllocGrp "78" msg.f_SideCrossOrdModGrp_PreAllocGrp) ((@) (enc_repeat encode_Parties "453" msg.f_SideCrossOrdModGrp_Parties) [])))) -;; - -let encode_LegOrdGrp (msg) = - (@) (encode_InstrumentLeg msg.f_LegOrdGrp_InstrumentLeg) ((@) (("687",enc_opt encode_float_6 msg.f_LegOrdGrp_LegQty) :: (("690",enc_opt encode_LegSwapType msg.f_LegOrdGrp_LegSwapType) :: (("564",enc_opt encode_char msg.f_LegOrdGrp_LegPositionEffect) :: (("565",enc_opt encode_int msg.f_LegOrdGrp_LegCoveredOrUncovered) :: (("654",enc_opt encode_string msg.f_LegOrdGrp_LegRefID) :: (("566",enc_opt encode_float_6 msg.f_LegOrdGrp_LegPrice) :: (("587",enc_opt encode_char msg.f_LegOrdGrp_LegSettlType) :: (("588",enc_opt encode_LocalMktDate msg.f_LegOrdGrp_LegSettlDate) :: [])))))))) ((@) (enc_repeat encode_NestedParties "539" msg.f_LegOrdGrp_NestedParties) ((@) (enc_repeat encode_LegPreAllocGrp "670" msg.f_LegOrdGrp_LegPreAllocGrp) ((@) (enc_repeat encode_LegStipulations "683" msg.f_LegOrdGrp_LegStipulations) [])))) -;; - -let encode_TrdCapRptSideGrp (msg) = - (@) (encode_CommissionData msg.f_TrdCapRptSideGrp_CommissionData) ((@) (("54",enc_opt encode_Side msg.f_TrdCapRptSideGrp_Side) :: (("37",enc_opt encode_string msg.f_TrdCapRptSideGrp_OrderID) :: (("198",enc_opt encode_string msg.f_TrdCapRptSideGrp_SecondaryOrderID) :: (("11",enc_opt encode_string msg.f_TrdCapRptSideGrp_ClOrdID) :: (("526",enc_opt encode_string msg.f_TrdCapRptSideGrp_SecondaryClOrdID) :: (("66",enc_opt encode_string msg.f_TrdCapRptSideGrp_ListID) :: (("1",enc_opt encode_string msg.f_TrdCapRptSideGrp_Account) :: (("660",enc_opt encode_AcctIDSource msg.f_TrdCapRptSideGrp_AcctIDSource) :: (("581",enc_opt encode_AccountType msg.f_TrdCapRptSideGrp_AccountType) :: (("81",enc_opt encode_ProcessCode msg.f_TrdCapRptSideGrp_ProcessCode) :: (("575",enc_opt encode_OddLot msg.f_TrdCapRptSideGrp_OddLot) :: (("578",enc_opt encode_string msg.f_TrdCapRptSideGrp_TradeInputSource) :: (("579",enc_opt encode_string msg.f_TrdCapRptSideGrp_TradeInputDevice) :: (("821",enc_opt encode_string msg.f_TrdCapRptSideGrp_OrderInputDevice) :: (("15",enc_opt encode_Currency msg.f_TrdCapRptSideGrp_Currency) :: (("376",enc_opt encode_string msg.f_TrdCapRptSideGrp_ComplianceID) :: (("377",enc_opt encode_SolicitedFlag msg.f_TrdCapRptSideGrp_SolicitedFlag) :: (("528",enc_opt encode_OrderCapacity msg.f_TrdCapRptSideGrp_OrderCapacity) :: (("529",enc_opt encode_OrderRestrictions msg.f_TrdCapRptSideGrp_OrderRestrictions) :: (("582",enc_opt encode_CustOrderCapacity msg.f_TrdCapRptSideGrp_CustOrderCapacity) :: (("40",enc_opt encode_OrdType msg.f_TrdCapRptSideGrp_OrdType) :: (("18",enc_opt encode_ExecInst msg.f_TrdCapRptSideGrp_ExecInst) :: (("483",enc_opt encode_UTCTimestamp_milli msg.f_TrdCapRptSideGrp_TransBkdTime) :: (("336",enc_opt encode_string msg.f_TrdCapRptSideGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_TrdCapRptSideGrp_TradingSessionSubID) :: (("943",enc_opt encode_string msg.f_TrdCapRptSideGrp_TimeBracket) :: (("381",enc_opt encode_float_6 msg.f_TrdCapRptSideGrp_GrossTradeAmt) :: (("157",enc_opt encode_int msg.f_TrdCapRptSideGrp_NumDaysInterest) :: (("230",enc_opt encode_LocalMktDate msg.f_TrdCapRptSideGrp_ExDate) :: (("158",enc_opt encode_float_6 msg.f_TrdCapRptSideGrp_AccruedInterestRate) :: (("159",enc_opt encode_float_6 msg.f_TrdCapRptSideGrp_AccruedInterestAmt) :: (("738",enc_opt encode_float_6 msg.f_TrdCapRptSideGrp_InterestAtMaturity) :: (("920",enc_opt encode_float_6 msg.f_TrdCapRptSideGrp_EndAccruedInterestAmt) :: (("921",enc_opt encode_float_6 msg.f_TrdCapRptSideGrp_StartCash) :: (("922",enc_opt encode_float_6 msg.f_TrdCapRptSideGrp_EndCash) :: (("238",enc_opt encode_float_6 msg.f_TrdCapRptSideGrp_Concession) :: (("237",enc_opt encode_float_6 msg.f_TrdCapRptSideGrp_TotalTakedown) :: (("118",enc_opt encode_float_6 msg.f_TrdCapRptSideGrp_NetMoney) :: (("119",enc_opt encode_float_6 msg.f_TrdCapRptSideGrp_SettlCurrAmt) :: (("120",enc_opt encode_Currency msg.f_TrdCapRptSideGrp_SettlCurrency) :: (("155",enc_opt encode_float msg.f_TrdCapRptSideGrp_SettlCurrFxRate) :: (("156",enc_opt encode_SettlCurrFxRateCalc msg.f_TrdCapRptSideGrp_SettlCurrFxRateCalc) :: (("77",enc_opt encode_PositionEffect msg.f_TrdCapRptSideGrp_PositionEffect) :: (("58",enc_opt encode_string msg.f_TrdCapRptSideGrp_Text) :: (("354",enc_opt encode_int msg.f_TrdCapRptSideGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_TrdCapRptSideGrp_EncodedText) :: (("752",enc_opt encode_SideMultiLegReportingType msg.f_TrdCapRptSideGrp_SideMultiLegReportingType) :: (("825",enc_opt encode_string msg.f_TrdCapRptSideGrp_ExchangeRule) :: (("826",enc_opt encode_TradeAllocIndicator msg.f_TrdCapRptSideGrp_TradeAllocIndicator) :: (("591",enc_opt encode_PreallocMethod msg.f_TrdCapRptSideGrp_PreallocMethod) :: (("70",enc_opt encode_string msg.f_TrdCapRptSideGrp_AllocID) :: []))))))))))))))))))))))))))))))))))))))))))))))))))) ((@) (enc_repeat encode_TrdAllocGrp "78" msg.f_TrdCapRptSideGrp_TrdAllocGrp) ((@) (enc_repeat encode_MiscFeesGrp "136" msg.f_TrdCapRptSideGrp_MiscFeesGrp) ((@) (enc_repeat encode_Stipulations "232" msg.f_TrdCapRptSideGrp_Stipulations) ((@) (enc_repeat encode_ContAmtGrp "518" msg.f_TrdCapRptSideGrp_ContAmtGrp) ((@) (enc_repeat encode_ClrInstGrp "576" msg.f_TrdCapRptSideGrp_ClrInstGrp) ((@) (enc_repeat encode_Parties "453" msg.f_TrdCapRptSideGrp_Parties) []))))))) -;; - -let encode_RelSymDerivSecGrp (msg) = - (@) (encode_InstrumentExtension msg.f_RelSymDerivSecGrp_InstrumentExtension) ((@) (encode_Instrument msg.f_RelSymDerivSecGrp_Instrument) ((@) (("15",enc_opt encode_Currency msg.f_RelSymDerivSecGrp_Currency) :: (("827",enc_opt encode_ExpirationCycle msg.f_RelSymDerivSecGrp_ExpirationCycle) :: (("336",enc_opt encode_string msg.f_RelSymDerivSecGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_RelSymDerivSecGrp_TradingSessionSubID) :: (("58",enc_opt encode_string msg.f_RelSymDerivSecGrp_Text) :: (("354",enc_opt encode_int msg.f_RelSymDerivSecGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_RelSymDerivSecGrp_EncodedText) :: []))))))) ((@) (enc_repeat encode_InstrmtLegGrp "555" msg.f_RelSymDerivSecGrp_InstrmtLegGrp) []))) -;; - -let encode_QuotEntryGrp (msg) = - (@) (encode_Instrument msg.f_QuotEntryGrp_Instrument) ((@) (("299",enc_opt encode_string msg.f_QuotEntryGrp_QuoteEntryID) :: (("132",enc_opt encode_float_6 msg.f_QuotEntryGrp_BidPx) :: (("133",enc_opt encode_float_6 msg.f_QuotEntryGrp_OfferPx) :: (("134",enc_opt encode_float_6 msg.f_QuotEntryGrp_BidSize) :: (("135",enc_opt encode_float_6 msg.f_QuotEntryGrp_OfferSize) :: (("62",enc_opt encode_UTCTimestamp_milli msg.f_QuotEntryGrp_ValidUntilTime) :: (("188",enc_opt encode_float_6 msg.f_QuotEntryGrp_BidSpotRate) :: (("190",enc_opt encode_float_6 msg.f_QuotEntryGrp_OfferSpotRate) :: (("189",enc_opt encode_float_6 msg.f_QuotEntryGrp_BidForwardPoints) :: (("191",enc_opt encode_float_6 msg.f_QuotEntryGrp_OfferForwardPoints) :: (("631",enc_opt encode_float_6 msg.f_QuotEntryGrp_MidPx) :: (("632",enc_opt encode_float_6 msg.f_QuotEntryGrp_BidYield) :: (("633",enc_opt encode_float_6 msg.f_QuotEntryGrp_MidYield) :: (("634",enc_opt encode_float_6 msg.f_QuotEntryGrp_OfferYield) :: (("60",enc_opt encode_UTCTimestamp_milli msg.f_QuotEntryGrp_TransactTime) :: (("336",enc_opt encode_string msg.f_QuotEntryGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_QuotEntryGrp_TradingSessionSubID) :: (("64",enc_opt encode_LocalMktDate msg.f_QuotEntryGrp_SettlDate) :: (("40",enc_opt encode_OrdType msg.f_QuotEntryGrp_OrdType) :: (("193",enc_opt encode_LocalMktDate msg.f_QuotEntryGrp_SettlDate2) :: (("192",enc_opt encode_float_6 msg.f_QuotEntryGrp_OrderQty2) :: (("642",enc_opt encode_float_6 msg.f_QuotEntryGrp_BidForwardPoints2) :: (("643",enc_opt encode_float_6 msg.f_QuotEntryGrp_OfferForwardPoints2) :: (("15",enc_opt encode_Currency msg.f_QuotEntryGrp_Currency) :: [])))))))))))))))))))))))) ((@) (enc_repeat encode_InstrmtLegGrp "555" msg.f_QuotEntryGrp_InstrmtLegGrp) [])) -;; - -let encode_QuotEntryAckGrp (msg) = - (@) (encode_Instrument msg.f_QuotEntryAckGrp_Instrument) ((@) (("299",enc_opt encode_string msg.f_QuotEntryAckGrp_QuoteEntryID) :: (("132",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_BidPx) :: (("133",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_OfferPx) :: (("134",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_BidSize) :: (("135",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_OfferSize) :: (("62",enc_opt encode_UTCTimestamp_milli msg.f_QuotEntryAckGrp_ValidUntilTime) :: (("188",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_BidSpotRate) :: (("190",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_OfferSpotRate) :: (("189",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_BidForwardPoints) :: (("191",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_OfferForwardPoints) :: (("631",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_MidPx) :: (("632",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_BidYield) :: (("633",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_MidYield) :: (("634",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_OfferYield) :: (("60",enc_opt encode_UTCTimestamp_milli msg.f_QuotEntryAckGrp_TransactTime) :: (("336",enc_opt encode_string msg.f_QuotEntryAckGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_QuotEntryAckGrp_TradingSessionSubID) :: (("64",enc_opt encode_LocalMktDate msg.f_QuotEntryAckGrp_SettlDate) :: (("40",enc_opt encode_OrdType msg.f_QuotEntryAckGrp_OrdType) :: (("193",enc_opt encode_LocalMktDate msg.f_QuotEntryAckGrp_SettlDate2) :: (("192",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_OrderQty2) :: (("642",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_BidForwardPoints2) :: (("643",enc_opt encode_float_6 msg.f_QuotEntryAckGrp_OfferForwardPoints2) :: (("15",enc_opt encode_Currency msg.f_QuotEntryAckGrp_Currency) :: (("368",enc_opt encode_int msg.f_QuotEntryAckGrp_QuoteEntryRejectReason) :: []))))))))))))))))))))))))) ((@) (enc_repeat encode_InstrmtLegGrp "555" msg.f_QuotEntryAckGrp_InstrmtLegGrp) [])) -;; - -let encode_ListOrdGrp (msg) = - (@) (encode_DiscretionInstructions msg.f_ListOrdGrp_DiscretionInstructions) ((@) (encode_PegInstructions msg.f_ListOrdGrp_PegInstructions) ((@) (encode_CommissionData msg.f_ListOrdGrp_CommissionData) ((@) (encode_YieldData msg.f_ListOrdGrp_YieldData) ((@) (encode_SpreadOrBenchmarkCurveData msg.f_ListOrdGrp_SpreadOrBenchmarkCurveData) ((@) (encode_OrderQtyData msg.f_ListOrdGrp_OrderQtyData) ((@) (encode_Instrument msg.f_ListOrdGrp_Instrument) ((@) (("11",enc_opt encode_string msg.f_ListOrdGrp_ClOrdID) :: (("526",enc_opt encode_string msg.f_ListOrdGrp_SecondaryClOrdID) :: (("67",enc_opt encode_int msg.f_ListOrdGrp_ListSeqNo) :: (("583",enc_opt encode_string msg.f_ListOrdGrp_ClOrdLinkID) :: (("160",enc_opt encode_SettlInstMode msg.f_ListOrdGrp_SettlInstMode) :: (("229",enc_opt encode_LocalMktDate msg.f_ListOrdGrp_TradeOriginationDate) :: (("75",enc_opt encode_LocalMktDate msg.f_ListOrdGrp_TradeDate) :: (("1",enc_opt encode_string msg.f_ListOrdGrp_Account) :: (("660",enc_opt encode_AcctIDSource msg.f_ListOrdGrp_AcctIDSource) :: (("581",enc_opt encode_AccountType msg.f_ListOrdGrp_AccountType) :: (("589",enc_opt encode_DayBookingInst msg.f_ListOrdGrp_DayBookingInst) :: (("590",enc_opt encode_BookingUnit msg.f_ListOrdGrp_BookingUnit) :: (("70",enc_opt encode_string msg.f_ListOrdGrp_AllocID) :: (("591",enc_opt encode_PreallocMethod msg.f_ListOrdGrp_PreallocMethod) :: (("63",enc_opt encode_SettlType msg.f_ListOrdGrp_SettlType) :: (("64",enc_opt encode_LocalMktDate msg.f_ListOrdGrp_SettlDate) :: (("544",enc_opt encode_CashMargin msg.f_ListOrdGrp_CashMargin) :: (("635",enc_opt encode_ClearingFeeIndicator msg.f_ListOrdGrp_ClearingFeeIndicator) :: (("21",enc_opt encode_HandlInst msg.f_ListOrdGrp_HandlInst) :: (("18",enc_opt encode_ExecInst msg.f_ListOrdGrp_ExecInst) :: (("110",enc_opt encode_float_6 msg.f_ListOrdGrp_MinQty) :: (("111",enc_opt encode_float_6 msg.f_ListOrdGrp_MaxFloor) :: (("100",enc_opt encode_Exchange msg.f_ListOrdGrp_ExDestination) :: (("81",enc_opt encode_ProcessCode msg.f_ListOrdGrp_ProcessCode) :: (("140",enc_opt encode_float_6 msg.f_ListOrdGrp_PrevClosePx) :: (("54",enc_opt encode_Side msg.f_ListOrdGrp_Side) :: (("401",enc_opt encode_SideValueInd msg.f_ListOrdGrp_SideValueInd) :: (("114",enc_opt encode_LocateReqd msg.f_ListOrdGrp_LocateReqd) :: (("60",enc_opt encode_UTCTimestamp_milli msg.f_ListOrdGrp_TransactTime) :: (("854",enc_opt encode_QtyType msg.f_ListOrdGrp_QtyType) :: (("40",enc_opt encode_OrdType msg.f_ListOrdGrp_OrdType) :: (("423",enc_opt encode_PriceType msg.f_ListOrdGrp_PriceType) :: (("44",enc_opt encode_float_6 msg.f_ListOrdGrp_Price) :: (("99",enc_opt encode_float_6 msg.f_ListOrdGrp_StopPx) :: (("15",enc_opt encode_Currency msg.f_ListOrdGrp_Currency) :: (("376",enc_opt encode_string msg.f_ListOrdGrp_ComplianceID) :: (("377",enc_opt encode_SolicitedFlag msg.f_ListOrdGrp_SolicitedFlag) :: (("23",enc_opt encode_string msg.f_ListOrdGrp_IOIID) :: (("117",enc_opt encode_string msg.f_ListOrdGrp_QuoteID) :: (("59",enc_opt encode_TimeInForce msg.f_ListOrdGrp_TimeInForce) :: (("168",enc_opt encode_UTCTimestamp_milli msg.f_ListOrdGrp_EffectiveTime) :: (("432",enc_opt encode_LocalMktDate msg.f_ListOrdGrp_ExpireDate) :: (("126",enc_opt encode_UTCTimestamp_milli msg.f_ListOrdGrp_ExpireTime) :: (("427",enc_opt encode_GTBookingInst msg.f_ListOrdGrp_GTBookingInst) :: (("528",enc_opt encode_OrderCapacity msg.f_ListOrdGrp_OrderCapacity) :: (("529",enc_opt encode_OrderRestrictions msg.f_ListOrdGrp_OrderRestrictions) :: (("582",enc_opt encode_CustOrderCapacity msg.f_ListOrdGrp_CustOrderCapacity) :: (("121",enc_opt encode_ForexReq msg.f_ListOrdGrp_ForexReq) :: (("120",enc_opt encode_Currency msg.f_ListOrdGrp_SettlCurrency) :: (("775",enc_opt encode_BookingType msg.f_ListOrdGrp_BookingType) :: (("58",enc_opt encode_string msg.f_ListOrdGrp_Text) :: (("354",enc_opt encode_int msg.f_ListOrdGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_ListOrdGrp_EncodedText) :: (("193",enc_opt encode_LocalMktDate msg.f_ListOrdGrp_SettlDate2) :: (("192",enc_opt encode_float_6 msg.f_ListOrdGrp_OrderQty2) :: (("640",enc_opt encode_float_6 msg.f_ListOrdGrp_Price2) :: (("77",enc_opt encode_PositionEffect msg.f_ListOrdGrp_PositionEffect) :: (("203",enc_opt encode_CoveredOrUncovered msg.f_ListOrdGrp_CoveredOrUncovered) :: (("210",enc_opt encode_float_6 msg.f_ListOrdGrp_MaxShow) :: (("847",enc_opt encode_TargetStrategy msg.f_ListOrdGrp_TargetStrategy) :: (("848",enc_opt encode_string msg.f_ListOrdGrp_TargetStrategyParameters) :: (("849",enc_opt encode_float_6 msg.f_ListOrdGrp_ParticipationRate) :: (("494",enc_opt encode_string msg.f_ListOrdGrp_Designation) :: []))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) ((@) (enc_repeat encode_Stipulations "232" msg.f_ListOrdGrp_Stipulations) ((@) (enc_repeat encode_UndInstrmtGrp "711" msg.f_ListOrdGrp_UndInstrmtGrp) ((@) (enc_repeat encode_TrdgSesGrp "386" msg.f_ListOrdGrp_TrdgSesGrp) ((@) (enc_repeat encode_PreAllocGrp "78" msg.f_ListOrdGrp_PreAllocGrp) ((@) (enc_repeat encode_Parties "453" msg.f_ListOrdGrp_Parties) [])))))))))))) -;; - -let encode_QuotReqRjctGrp (msg) = - (@) (encode_YieldData msg.f_QuotReqRjctGrp_YieldData) ((@) (encode_SpreadOrBenchmarkCurveData msg.f_QuotReqRjctGrp_SpreadOrBenchmarkCurveData) ((@) (encode_OrderQtyData msg.f_QuotReqRjctGrp_OrderQtyData) ((@) (encode_FinancingDetails msg.f_QuotReqRjctGrp_FinancingDetails) ((@) (encode_Instrument msg.f_QuotReqRjctGrp_Instrument) ((@) (("140",enc_opt encode_float_6 msg.f_QuotReqRjctGrp_PrevClosePx) :: (("303",enc_opt encode_QuoteRequestType msg.f_QuotReqRjctGrp_QuoteRequestType) :: (("537",enc_opt encode_QuoteType msg.f_QuotReqRjctGrp_QuoteType) :: (("336",enc_opt encode_string msg.f_QuotReqRjctGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_QuotReqRjctGrp_TradingSessionSubID) :: (("229",enc_opt encode_LocalMktDate msg.f_QuotReqRjctGrp_TradeOriginationDate) :: (("54",enc_opt encode_Side msg.f_QuotReqRjctGrp_Side) :: (("854",enc_opt encode_QtyType msg.f_QuotReqRjctGrp_QtyType) :: (("63",enc_opt encode_SettlType msg.f_QuotReqRjctGrp_SettlType) :: (("64",enc_opt encode_LocalMktDate msg.f_QuotReqRjctGrp_SettlDate) :: (("193",enc_opt encode_LocalMktDate msg.f_QuotReqRjctGrp_SettlDate2) :: (("192",enc_opt encode_float_6 msg.f_QuotReqRjctGrp_OrderQty2) :: (("15",enc_opt encode_Currency msg.f_QuotReqRjctGrp_Currency) :: (("1",enc_opt encode_string msg.f_QuotReqRjctGrp_Account) :: (("660",enc_opt encode_AcctIDSource msg.f_QuotReqRjctGrp_AcctIDSource) :: (("581",enc_opt encode_AccountType msg.f_QuotReqRjctGrp_AccountType) :: (("692",enc_opt encode_QuotePriceType msg.f_QuotReqRjctGrp_QuotePriceType) :: (("40",enc_opt encode_OrdType msg.f_QuotReqRjctGrp_OrdType) :: (("126",enc_opt encode_UTCTimestamp_milli msg.f_QuotReqRjctGrp_ExpireTime) :: (("60",enc_opt encode_UTCTimestamp_milli msg.f_QuotReqRjctGrp_TransactTime) :: (("423",enc_opt encode_PriceType msg.f_QuotReqRjctGrp_PriceType) :: (("44",enc_opt encode_float_6 msg.f_QuotReqRjctGrp_Price) :: (("640",enc_opt encode_float_6 msg.f_QuotReqRjctGrp_Price2) :: []))))))))))))))))))))))) ((@) (enc_repeat encode_Parties "453" msg.f_QuotReqRjctGrp_Parties) ((@) (enc_repeat encode_QuotQualGrp "735" msg.f_QuotReqRjctGrp_QuotQualGrp) ((@) (enc_repeat encode_QuotReqLegsGrp "555" msg.f_QuotReqRjctGrp_QuotReqLegsGrp) ((@) (enc_repeat encode_Stipulations "232" msg.f_QuotReqRjctGrp_Stipulations) ((@) (enc_repeat encode_UndInstrmtGrp "711" msg.f_QuotReqRjctGrp_UndInstrmtGrp) [])))))))))) -;; - -let encode_RFQReqGrp (msg) = - (@) (encode_Instrument msg.f_RFQReqGrp_Instrument) ((@) (("140",enc_opt encode_float_6 msg.f_RFQReqGrp_PrevClosePx) :: (("303",enc_opt encode_QuoteRequestType msg.f_RFQReqGrp_QuoteRequestType) :: (("537",enc_opt encode_QuoteType msg.f_RFQReqGrp_QuoteType) :: (("336",enc_opt encode_string msg.f_RFQReqGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_RFQReqGrp_TradingSessionSubID) :: []))))) ((@) (enc_repeat encode_InstrmtLegGrp "555" msg.f_RFQReqGrp_InstrmtLegGrp) ((@) (enc_repeat encode_UndInstrmtGrp "711" msg.f_RFQReqGrp_UndInstrmtGrp) []))) -;; - -let encode_InstrmtMDReqGrp (msg) = - (@) (encode_Instrument msg.f_InstrmtMDReqGrp_Instrument) ((@) [] ((@) (enc_repeat encode_InstrmtLegGrp "555" msg.f_InstrmtMDReqGrp_InstrmtLegGrp) ((@) (enc_repeat encode_UndInstrmtGrp "711" msg.f_InstrmtMDReqGrp_UndInstrmtGrp) []))) -;; - -let encode_MDIncGrp (msg) = - (@) (encode_Instrument msg.f_MDIncGrp_Instrument) ((@) (("279",enc_opt encode_MDUpdateAction msg.f_MDIncGrp_MDUpdateAction) :: (("285",enc_opt encode_DeleteReason msg.f_MDIncGrp_DeleteReason) :: (("269",enc_opt encode_MDEntryType msg.f_MDIncGrp_MDEntryType) :: (("278",enc_opt encode_string msg.f_MDIncGrp_MDEntryID) :: (("280",enc_opt encode_string msg.f_MDIncGrp_MDEntryRefID) :: (("291",enc_opt encode_FinancialStatus msg.f_MDIncGrp_FinancialStatus) :: (("292",enc_opt encode_CorporateAction msg.f_MDIncGrp_CorporateAction) :: (("270",enc_opt encode_float_6 msg.f_MDIncGrp_MDEntryPx) :: (("15",enc_opt encode_Currency msg.f_MDIncGrp_Currency) :: (("271",enc_opt encode_float_6 msg.f_MDIncGrp_MDEntrySize) :: (("272",enc_opt encode_UTCDateOnly msg.f_MDIncGrp_MDEntryDate) :: (("273",enc_opt encode_UTCTimeOnly_milli msg.f_MDIncGrp_MDEntryTime) :: (("274",enc_opt encode_TickDirection msg.f_MDIncGrp_TickDirection) :: (("275",enc_opt encode_Exchange msg.f_MDIncGrp_MDMkt) :: (("336",enc_opt encode_string msg.f_MDIncGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_MDIncGrp_TradingSessionSubID) :: (("276",enc_opt encode_QuoteCondition msg.f_MDIncGrp_QuoteCondition) :: (("277",enc_opt encode_TradeCondition msg.f_MDIncGrp_TradeCondition) :: (("282",enc_opt encode_string msg.f_MDIncGrp_MDEntryOriginator) :: (("283",enc_opt encode_string msg.f_MDIncGrp_LocationID) :: (("284",enc_opt encode_string msg.f_MDIncGrp_DeskID) :: (("286",enc_opt encode_OpenCloseSettlFlag msg.f_MDIncGrp_OpenCloseSettlFlag) :: (("59",enc_opt encode_TimeInForce msg.f_MDIncGrp_TimeInForce) :: (("432",enc_opt encode_LocalMktDate msg.f_MDIncGrp_ExpireDate) :: (("126",enc_opt encode_UTCTimestamp_milli msg.f_MDIncGrp_ExpireTime) :: (("110",enc_opt encode_float_6 msg.f_MDIncGrp_MinQty) :: (("18",enc_opt encode_ExecInst msg.f_MDIncGrp_ExecInst) :: (("287",enc_opt encode_int msg.f_MDIncGrp_SellerDays) :: (("37",enc_opt encode_string msg.f_MDIncGrp_OrderID) :: (("299",enc_opt encode_string msg.f_MDIncGrp_QuoteEntryID) :: (("288",enc_opt encode_string msg.f_MDIncGrp_MDEntryBuyer) :: (("289",enc_opt encode_string msg.f_MDIncGrp_MDEntrySeller) :: (("346",enc_opt encode_int msg.f_MDIncGrp_NumberOfOrders) :: (("290",enc_opt encode_int msg.f_MDIncGrp_MDEntryPositionNo) :: (("546",enc_opt encode_Scope msg.f_MDIncGrp_Scope) :: (("811",enc_opt encode_float msg.f_MDIncGrp_PriceDelta) :: (("451",enc_opt encode_float_6 msg.f_MDIncGrp_NetChgPrevDay) :: (("58",enc_opt encode_string msg.f_MDIncGrp_Text) :: (("354",enc_opt encode_int msg.f_MDIncGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_MDIncGrp_EncodedText) :: [])))))))))))))))))))))))))))))))))))))))) ((@) (enc_repeat encode_InstrmtLegGrp "555" msg.f_MDIncGrp_InstrmtLegGrp) ((@) (enc_repeat encode_UndInstrmtGrp "711" msg.f_MDIncGrp_UndInstrmtGrp) []))) -;; - -let encode_SecListGrp (msg) = - (@) (encode_YieldData msg.f_SecListGrp_YieldData) ((@) (encode_SpreadOrBenchmarkCurveData msg.f_SecListGrp_SpreadOrBenchmarkCurveData) ((@) (encode_FinancingDetails msg.f_SecListGrp_FinancingDetails) ((@) (encode_InstrumentExtension msg.f_SecListGrp_InstrumentExtension) ((@) (encode_Instrument msg.f_SecListGrp_Instrument) ((@) (("15",enc_opt encode_Currency msg.f_SecListGrp_Currency) :: (("561",enc_opt encode_float_6 msg.f_SecListGrp_RoundLot) :: (("562",enc_opt encode_float_6 msg.f_SecListGrp_MinTradeVol) :: (("336",enc_opt encode_string msg.f_SecListGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_SecListGrp_TradingSessionSubID) :: (("827",enc_opt encode_ExpirationCycle msg.f_SecListGrp_ExpirationCycle) :: (("58",enc_opt encode_string msg.f_SecListGrp_Text) :: (("354",enc_opt encode_int msg.f_SecListGrp_EncodedTextLen) :: (("355",enc_opt encode_string msg.f_SecListGrp_EncodedText) :: []))))))))) ((@) (enc_repeat encode_InstrmtLegSecListGrp "555" msg.f_SecListGrp_InstrmtLegSecListGrp) ((@) (enc_repeat encode_Stipulations "232" msg.f_SecListGrp_Stipulations) ((@) (enc_repeat encode_UndInstrmtGrp "711" msg.f_SecListGrp_UndInstrmtGrp) [])))))))) -;; - -let encode_QuotReqGrp (msg) = - (@) (encode_YieldData msg.f_QuotReqGrp_YieldData) ((@) (encode_SpreadOrBenchmarkCurveData msg.f_QuotReqGrp_SpreadOrBenchmarkCurveData) ((@) (encode_OrderQtyData msg.f_QuotReqGrp_OrderQtyData) ((@) (encode_FinancingDetails msg.f_QuotReqGrp_FinancingDetails) ((@) (encode_Instrument msg.f_QuotReqGrp_Instrument) ((@) (("140",enc_opt encode_float_6 msg.f_QuotReqGrp_PrevClosePx) :: (("303",enc_opt encode_QuoteRequestType msg.f_QuotReqGrp_QuoteRequestType) :: (("537",enc_opt encode_QuoteType msg.f_QuotReqGrp_QuoteType) :: (("336",enc_opt encode_string msg.f_QuotReqGrp_TradingSessionID) :: (("625",enc_opt encode_string msg.f_QuotReqGrp_TradingSessionSubID) :: (("229",enc_opt encode_LocalMktDate msg.f_QuotReqGrp_TradeOriginationDate) :: (("54",enc_opt encode_Side msg.f_QuotReqGrp_Side) :: (("854",enc_opt encode_QtyType msg.f_QuotReqGrp_QtyType) :: (("63",enc_opt encode_SettlType msg.f_QuotReqGrp_SettlType) :: (("64",enc_opt encode_LocalMktDate msg.f_QuotReqGrp_SettlDate) :: (("193",enc_opt encode_LocalMktDate msg.f_QuotReqGrp_SettlDate2) :: (("192",enc_opt encode_float_6 msg.f_QuotReqGrp_OrderQty2) :: (("15",enc_opt encode_Currency msg.f_QuotReqGrp_Currency) :: (("1",enc_opt encode_string msg.f_QuotReqGrp_Account) :: (("660",enc_opt encode_AcctIDSource msg.f_QuotReqGrp_AcctIDSource) :: (("581",enc_opt encode_AccountType msg.f_QuotReqGrp_AccountType) :: (("692",enc_opt encode_QuotePriceType msg.f_QuotReqGrp_QuotePriceType) :: (("40",enc_opt encode_OrdType msg.f_QuotReqGrp_OrdType) :: (("62",enc_opt encode_UTCTimestamp_milli msg.f_QuotReqGrp_ValidUntilTime) :: (("126",enc_opt encode_UTCTimestamp_milli msg.f_QuotReqGrp_ExpireTime) :: (("60",enc_opt encode_UTCTimestamp_milli msg.f_QuotReqGrp_TransactTime) :: (("423",enc_opt encode_PriceType msg.f_QuotReqGrp_PriceType) :: (("44",enc_opt encode_float_6 msg.f_QuotReqGrp_Price) :: (("640",enc_opt encode_float_6 msg.f_QuotReqGrp_Price2) :: [])))))))))))))))))))))))) ((@) (enc_repeat encode_Parties "453" msg.f_QuotReqGrp_Parties) ((@) (enc_repeat encode_QuotQualGrp "735" msg.f_QuotReqGrp_QuotQualGrp) ((@) (enc_repeat encode_QuotReqLegsGrp "555" msg.f_QuotReqGrp_QuotReqLegsGrp) ((@) (enc_repeat encode_Stipulations "232" msg.f_QuotReqGrp_Stipulations) ((@) (enc_repeat encode_UndInstrmtGrp "711" msg.f_QuotReqGrp_UndInstrmtGrp) [])))))))))) -;; - -let encode_QuotCxlEntriesGrp (msg) = - (@) (encode_FinancingDetails msg.f_QuotCxlEntriesGrp_FinancingDetails) ((@) (encode_Instrument msg.f_QuotCxlEntriesGrp_Instrument) ((@) [] ((@) (enc_repeat encode_InstrmtLegGrp "555" msg.f_QuotCxlEntriesGrp_InstrmtLegGrp) ((@) (enc_repeat encode_UndInstrmtGrp "711" msg.f_QuotCxlEntriesGrp_UndInstrmtGrp) [])))) -;; - -let encode_QuotSetAckGrp (msg) = - (@) (encode_UnderlyingInstrument msg.f_QuotSetAckGrp_UnderlyingInstrument) ((@) (("302",enc_opt encode_string msg.f_QuotSetAckGrp_QuoteSetID) :: (("304",enc_opt encode_int msg.f_QuotSetAckGrp_TotNoQuoteEntries) :: (("893",enc_opt encode_LastFragment msg.f_QuotSetAckGrp_LastFragment) :: []))) ((@) (enc_repeat encode_QuotEntryAckGrp "295" msg.f_QuotSetAckGrp_QuotEntryAckGrp) [])) -;; - -let encode_QuotSetGrp (msg) = - (@) (encode_UnderlyingInstrument msg.f_QuotSetGrp_UnderlyingInstrument) ((@) (("302",enc_opt encode_string msg.f_QuotSetGrp_QuoteSetID) :: (("367",enc_opt encode_UTCTimestamp_milli msg.f_QuotSetGrp_QuoteSetValidUntilTime) :: (("304",enc_opt encode_int msg.f_QuotSetGrp_TotNoQuoteEntries) :: (("893",enc_opt encode_LastFragment msg.f_QuotSetGrp_LastFragment) :: [])))) ((@) (enc_repeat encode_QuotEntryGrp "295" msg.f_QuotSetGrp_QuotEntryGrp) [])) -;; - -let encode_SettlInstGrp (msg) = - (@) (encode_SettlInstructionsData msg.f_SettlInstGrp_SettlInstructionsData) ((@) (("162",enc_opt encode_string msg.f_SettlInstGrp_SettlInstID) :: (("163",enc_opt encode_SettlInstTransType msg.f_SettlInstGrp_SettlInstTransType) :: (("214",enc_opt encode_string msg.f_SettlInstGrp_SettlInstRefID) :: (("54",enc_opt encode_Side msg.f_SettlInstGrp_Side) :: (("460",enc_opt encode_Product msg.f_SettlInstGrp_Product) :: (("167",enc_opt encode_SecurityType msg.f_SettlInstGrp_SecurityType) :: (("461",enc_opt encode_string msg.f_SettlInstGrp_CFICode) :: (("168",enc_opt encode_UTCTimestamp_milli msg.f_SettlInstGrp_EffectiveTime) :: (("126",enc_opt encode_UTCTimestamp_milli msg.f_SettlInstGrp_ExpireTime) :: (("779",enc_opt encode_UTCTimestamp_milli msg.f_SettlInstGrp_LastUpdateTime) :: (("492",enc_opt encode_PaymentMethod msg.f_SettlInstGrp_PaymentMethod) :: (("476",enc_opt encode_string msg.f_SettlInstGrp_PaymentRef) :: (("488",enc_opt encode_string msg.f_SettlInstGrp_CardHolderName) :: (("489",enc_opt encode_string msg.f_SettlInstGrp_CardNumber) :: (("503",enc_opt encode_LocalMktDate msg.f_SettlInstGrp_CardStartDate) :: (("490",enc_opt encode_LocalMktDate msg.f_SettlInstGrp_CardExpDate) :: (("491",enc_opt encode_string msg.f_SettlInstGrp_CardIssNum) :: (("504",enc_opt encode_LocalMktDate msg.f_SettlInstGrp_PaymentDate) :: (("505",enc_opt encode_string msg.f_SettlInstGrp_PaymentRemitterID) :: []))))))))))))))))))) ((@) (enc_repeat encode_Parties "453" msg.f_SettlInstGrp_Parties) [])) -;; - -let encode_AllocGrp (msg) = - (@) (encode_SettlInstructionsData msg.f_AllocGrp_SettlInstructionsData) ((@) (encode_CommissionData msg.f_AllocGrp_CommissionData) ((@) (("79",enc_opt encode_string msg.f_AllocGrp_AllocAccount) :: (("661",enc_opt encode_int msg.f_AllocGrp_AllocAcctIDSource) :: (("573",enc_opt encode_MatchStatus msg.f_AllocGrp_MatchStatus) :: (("366",enc_opt encode_float_6 msg.f_AllocGrp_AllocPrice) :: (("80",enc_opt encode_float_6 msg.f_AllocGrp_AllocQty) :: (("467",enc_opt encode_string msg.f_AllocGrp_IndividualAllocID) :: (("81",enc_opt encode_ProcessCode msg.f_AllocGrp_ProcessCode) :: (("208",enc_opt encode_NotifyBrokerOfCredit msg.f_AllocGrp_NotifyBrokerOfCredit) :: (("209",enc_opt encode_AllocHandlInst msg.f_AllocGrp_AllocHandlInst) :: (("161",enc_opt encode_string msg.f_AllocGrp_AllocText) :: (("360",enc_opt encode_int msg.f_AllocGrp_EncodedAllocTextLen) :: (("361",enc_opt encode_string msg.f_AllocGrp_EncodedAllocText) :: (("153",enc_opt encode_float_6 msg.f_AllocGrp_AllocAvgPx) :: (("154",enc_opt encode_float_6 msg.f_AllocGrp_AllocNetMoney) :: (("119",enc_opt encode_float_6 msg.f_AllocGrp_SettlCurrAmt) :: (("737",enc_opt encode_float_6 msg.f_AllocGrp_AllocSettlCurrAmt) :: (("120",enc_opt encode_Currency msg.f_AllocGrp_SettlCurrency) :: (("736",enc_opt encode_Currency msg.f_AllocGrp_AllocSettlCurrency) :: (("155",enc_opt encode_float msg.f_AllocGrp_SettlCurrFxRate) :: (("156",enc_opt encode_SettlCurrFxRateCalc msg.f_AllocGrp_SettlCurrFxRateCalc) :: (("742",enc_opt encode_float_6 msg.f_AllocGrp_AllocAccruedInterestAmt) :: (("741",enc_opt encode_float_6 msg.f_AllocGrp_AllocInterestAtMaturity) :: (("780",enc_opt encode_AllocSettlInstType msg.f_AllocGrp_AllocSettlInstType) :: []))))))))))))))))))))))) ((@) (enc_repeat encode_ClrInstGrp "576" msg.f_AllocGrp_ClrInstGrp) ((@) (enc_repeat encode_MiscFeesGrp "136" msg.f_AllocGrp_MiscFeesGrp) ((@) (enc_repeat encode_NestedParties "539" msg.f_AllocGrp_NestedParties) []))))) -;; [@@@logic] diff --git a/src-protocol-exts-pp/encode_app_tags.iml b/src-protocol-exts-pp/encode_app_tags.iml index b3644f11..142fc4c9 100644 --- a/src-protocol-exts-pp/encode_app_tags.iml +++ b/src-protocol-exts-pp/encode_app_tags.iml @@ -1,390 +1,57 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "../src-protocol-exts/full_app_tags.iml"] +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-protocol-exts/full_app_tags.iml"] open Full_app_tags;; + let encode_app_msg_tag (d) = (match d with - | Full_Msg_ExecutionReport_Tag -> "8" | Full_Msg_NewOrderSingle_Tag -> "D" + | Full_Msg_ExecutionReport_Tag -> "8" ) ;; let encode_app_field_tag (d) = (match d with - | Full_Field_OrderID_Tag -> ("37") - | Full_Field_SecondaryOrderID_Tag -> ("198") - | Full_Field_SecondaryClOrdID_Tag -> ("526") - | Full_Field_SecondaryExecID_Tag -> ("527") | Full_Field_ClOrdID_Tag -> ("11") - | Full_Field_OrigClOrdID_Tag -> ("41") - | Full_Field_ClOrdLinkID_Tag -> ("583") - | Full_Field_QuoteRespID_Tag -> ("693") - | Full_Field_OrdStatusReqID_Tag -> ("790") - | Full_Field_MassStatusReqID_Tag -> ("584") - | Full_Field_TotNumReports_Tag -> ("911") - | Full_Field_LastRptRequested_Tag -> ("912") - | Full_Field_TradeOriginationDate_Tag -> ("229") - | Full_Field_ListID_Tag -> ("66") - | Full_Field_CrossID_Tag -> ("548") - | Full_Field_OrigCrossID_Tag -> ("551") - | Full_Field_CrossType_Tag -> ("549") - | Full_Field_ExecID_Tag -> ("17") - | Full_Field_ExecRefID_Tag -> ("19") - | Full_Field_ExecType_Tag -> ("150") - | Full_Field_OrdStatus_Tag -> ("39") - | Full_Field_WorkingIndicator_Tag -> ("636") - | Full_Field_OrdRejReason_Tag -> ("103") - | Full_Field_ExecRestatementReason_Tag -> ("378") + | Full_Field_Parties_Tag -> ("") | Full_Field_Account_Tag -> ("1") - | Full_Field_AcctIDSource_Tag -> ("660") - | Full_Field_AccountType_Tag -> ("581") - | Full_Field_DayBookingInst_Tag -> ("589") - | Full_Field_BookingUnit_Tag -> ("590") - | Full_Field_PreallocMethod_Tag -> ("591") - | Full_Field_SettlType_Tag -> ("63") - | Full_Field_SettlDate_Tag -> ("64") - | Full_Field_CashMargin_Tag -> ("544") - | Full_Field_ClearingFeeIndicator_Tag -> ("635") + | Full_Field_ExecInst_Tag -> ("18") | Full_Field_Side_Tag -> ("54") - | Full_Field_QtyType_Tag -> ("854") + | Full_Field_TransactTime_Tag -> ("60") + | Full_Field_OrderQtyData_Tag -> ("") | Full_Field_OrdType_Tag -> ("40") - | Full_Field_PriceType_Tag -> ("423") | Full_Field_Price_Tag -> ("44") - | Full_Field_StopPx_Tag -> ("99") - | Full_Field_PeggedPrice_Tag -> ("839") - | Full_Field_DiscretionPrice_Tag -> ("845") - | Full_Field_TargetStrategy_Tag -> ("847") - | Full_Field_TargetStrategyParameters_Tag -> ("848") - | Full_Field_ParticipationRate_Tag -> ("849") - | Full_Field_TargetStrategyPerformance_Tag -> ("850") - | Full_Field_Currency_Tag -> ("15") - | Full_Field_ComplianceID_Tag -> ("376") - | Full_Field_SolicitedFlag_Tag -> ("377") - | Full_Field_TimeInForce_Tag -> ("59") - | Full_Field_EffectiveTime_Tag -> ("168") - | Full_Field_ExpireDate_Tag -> ("432") - | Full_Field_ExpireTime_Tag -> ("126") - | Full_Field_ExecInst_Tag -> ("18") - | Full_Field_OrderCapacity_Tag -> ("528") - | Full_Field_OrderRestrictions_Tag -> ("529") - | Full_Field_CustOrderCapacity_Tag -> ("582") - | Full_Field_LastQty_Tag -> ("32") - | Full_Field_UnderlyingLastQty_Tag -> ("652") - | Full_Field_LastPx_Tag -> ("31") - | Full_Field_UnderlyingLastPx_Tag -> ("651") - | Full_Field_LastParPx_Tag -> ("669") - | Full_Field_LastSpotRate_Tag -> ("194") - | Full_Field_LastForwardPoints_Tag -> ("195") - | Full_Field_LastMkt_Tag -> ("30") - | Full_Field_TradingSessionID_Tag -> ("336") - | Full_Field_TradingSessionSubID_Tag -> ("625") - | Full_Field_TimeBracket_Tag -> ("943") - | Full_Field_LastCapacity_Tag -> ("29") + | Full_Field_SpreadProportion_Tag -> ("10001") + | Full_Field_OrderID_Tag -> ("37") + | Full_Field_ExecID_Tag -> ("17") + | Full_Field_ExecType_Tag -> ("150") + | Full_Field_OrdStatus_Tag -> ("39") | Full_Field_LeavesQty_Tag -> ("151") | Full_Field_CumQty_Tag -> ("14") - | Full_Field_AvgPx_Tag -> ("6") - | Full_Field_DayOrderQty_Tag -> ("424") - | Full_Field_DayCumQty_Tag -> ("425") - | Full_Field_DayAvgPx_Tag -> ("426") - | Full_Field_GTBookingInst_Tag -> ("427") - | Full_Field_TradeDate_Tag -> ("75") - | Full_Field_TransactTime_Tag -> ("60") - | Full_Field_ReportToExch_Tag -> ("113") - | Full_Field_GrossTradeAmt_Tag -> ("381") - | Full_Field_NumDaysInterest_Tag -> ("157") - | Full_Field_ExDate_Tag -> ("230") - | Full_Field_AccruedInterestRate_Tag -> ("158") - | Full_Field_AccruedInterestAmt_Tag -> ("159") - | Full_Field_InterestAtMaturity_Tag -> ("738") - | Full_Field_EndAccruedInterestAmt_Tag -> ("920") - | Full_Field_StartCash_Tag -> ("921") - | Full_Field_EndCash_Tag -> ("922") - | Full_Field_TradedFlatSwitch_Tag -> ("258") - | Full_Field_BasisFeatureDate_Tag -> ("259") - | Full_Field_BasisFeaturePrice_Tag -> ("260") - | Full_Field_Concession_Tag -> ("238") - | Full_Field_TotalTakedown_Tag -> ("237") - | Full_Field_NetMoney_Tag -> ("118") - | Full_Field_SettlCurrAmt_Tag -> ("119") - | Full_Field_SettlCurrency_Tag -> ("120") - | Full_Field_SettlCurrFxRate_Tag -> ("155") - | Full_Field_SettlCurrFxRateCalc_Tag -> ("156") - | Full_Field_HandlInst_Tag -> ("21") - | Full_Field_MinQty_Tag -> ("110") - | Full_Field_MaxFloor_Tag -> ("111") - | Full_Field_PositionEffect_Tag -> ("77") - | Full_Field_MaxShow_Tag -> ("210") - | Full_Field_BookingType_Tag -> ("775") | Full_Field_Text_Tag -> ("58") - | Full_Field_EncodedTextLen_Tag -> ("354") - | Full_Field_EncodedText_Tag -> ("355") - | Full_Field_SettlDate2_Tag -> ("193") - | Full_Field_OrderQty2_Tag -> ("192") - | Full_Field_LastForwardPoints2_Tag -> ("641") - | Full_Field_MultiLegReportingType_Tag -> ("442") - | Full_Field_CancellationRights_Tag -> ("480") - | Full_Field_MoneyLaunderingStatus_Tag -> ("481") - | Full_Field_RegistID_Tag -> ("513") - | Full_Field_Designation_Tag -> ("494") - | Full_Field_TransBkdTime_Tag -> ("483") - | Full_Field_ExecValuationPoint_Tag -> ("515") - | Full_Field_ExecPriceType_Tag -> ("484") - | Full_Field_ExecPriceAdjustment_Tag -> ("485") - | Full_Field_PriorityIndicator_Tag -> ("638") - | Full_Field_PriceImprovement_Tag -> ("639") - | Full_Field_LastLiquidityInd_Tag -> ("851") - | Full_Field_CopyMsgIndicator_Tag -> ("797") - | Full_Field_NoPartyIDs_Tag -> ("453") - | Full_Field_PartyID_Tag -> ("448") - | Full_Field_PartyIDSource_Tag -> ("447") - | Full_Field_PartyRole_Tag -> ("452") - | Full_Field_NoPartySubIDs_Tag -> ("802") - | Full_Field_PartySubID_Tag -> ("523") - | Full_Field_PartySubIDType_Tag -> ("803") - | Full_Field_NoContraBrokers_Tag -> ("382") - | Full_Field_ContraBroker_Tag -> ("375") - | Full_Field_ContraTrader_Tag -> ("337") - | Full_Field_ContraTradeQty_Tag -> ("437") - | Full_Field_ContraTradeTime_Tag -> ("438") - | Full_Field_ContraLegRefID_Tag -> ("655") - | Full_Field_Symbol_Tag -> ("55") - | Full_Field_SymbolSfx_Tag -> ("65") - | Full_Field_SecurityID_Tag -> ("48") - | Full_Field_SecurityIDSource_Tag -> ("22") - | Full_Field_Product_Tag -> ("460") - | Full_Field_CFICode_Tag -> ("461") - | Full_Field_SecurityType_Tag -> ("167") - | Full_Field_SecuritySubType_Tag -> ("762") - | Full_Field_MaturityMonthYear_Tag -> ("200") - | Full_Field_MaturityDate_Tag -> ("541") - | Full_Field_CouponPaymentDate_Tag -> ("224") - | Full_Field_IssueDate_Tag -> ("225") - | Full_Field_RepoCollateralSecurityType_Tag -> ("239") - | Full_Field_RepurchaseTerm_Tag -> ("226") - | Full_Field_RepurchaseRate_Tag -> ("227") - | Full_Field_Factor_Tag -> ("228") - | Full_Field_CreditRating_Tag -> ("255") - | Full_Field_InstrRegistry_Tag -> ("543") - | Full_Field_CountryOfIssue_Tag -> ("470") - | Full_Field_StateOrProvinceOfIssue_Tag -> ("471") - | Full_Field_LocaleOfIssue_Tag -> ("472") - | Full_Field_RedemptionDate_Tag -> ("240") - | Full_Field_StrikePrice_Tag -> ("202") - | Full_Field_StrikeCurrency_Tag -> ("947") - | Full_Field_OptAttribute_Tag -> ("206") - | Full_Field_ContractMultiplier_Tag -> ("231") - | Full_Field_CouponRate_Tag -> ("223") - | Full_Field_SecurityExchange_Tag -> ("207") - | Full_Field_Issuer_Tag -> ("106") - | Full_Field_EncodedIssuerLen_Tag -> ("348") - | Full_Field_EncodedIssuer_Tag -> ("349") - | Full_Field_SecurityDesc_Tag -> ("107") - | Full_Field_EncodedSecurityDescLen_Tag -> ("350") - | Full_Field_EncodedSecurityDesc_Tag -> ("351") - | Full_Field_Pool_Tag -> ("691") - | Full_Field_ContractSettlMonth_Tag -> ("667") - | Full_Field_CPProgram_Tag -> ("875") - | Full_Field_CPRegType_Tag -> ("876") - | Full_Field_DatedDate_Tag -> ("873") - | Full_Field_InterestAccrualDate_Tag -> ("874") - | Full_Field_NoSecurityAltID_Tag -> ("454") - | Full_Field_SecurityAltID_Tag -> ("455") - | Full_Field_SecurityAltIDSource_Tag -> ("456") - | Full_Field_NoEvents_Tag -> ("864") - | Full_Field_EventType_Tag -> ("865") - | Full_Field_EventDate_Tag -> ("866") - | Full_Field_EventPx_Tag -> ("867") - | Full_Field_EventText_Tag -> ("868") - | Full_Field_AgreementDesc_Tag -> ("913") - | Full_Field_AgreementID_Tag -> ("914") - | Full_Field_AgreementDate_Tag -> ("915") - | Full_Field_AgreementCurrency_Tag -> ("918") - | Full_Field_TerminationType_Tag -> ("788") - | Full_Field_StartDate_Tag -> ("916") - | Full_Field_EndDate_Tag -> ("917") - | Full_Field_DeliveryType_Tag -> ("919") - | Full_Field_MarginRatio_Tag -> ("898") - | Full_Field_NoUnderlyings_Tag -> ("711") - | Full_Field_UnderlyingSymbol_Tag -> ("311") - | Full_Field_UnderlyingSymbolSfx_Tag -> ("312") - | Full_Field_UnderlyingSecurityID_Tag -> ("309") - | Full_Field_UnderlyingSecurityIDSource_Tag -> ("305") - | Full_Field_UnderlyingProduct_Tag -> ("462") - | Full_Field_UnderlyingCFICode_Tag -> ("463") - | Full_Field_UnderlyingSecurityType_Tag -> ("310") - | Full_Field_UnderlyingSecuritySubType_Tag -> ("763") - | Full_Field_UnderlyingMaturityMonthYear_Tag -> ("313") - | Full_Field_UnderlyingMaturityDate_Tag -> ("542") - | Full_Field_UnderlyingCouponPaymentDate_Tag -> ("241") - | Full_Field_UnderlyingIssueDate_Tag -> ("242") - | Full_Field_UnderlyingRepoCollateralSecurityType_Tag -> ("243") - | Full_Field_UnderlyingRepurchaseTerm_Tag -> ("244") - | Full_Field_UnderlyingRepurchaseRate_Tag -> ("245") - | Full_Field_UnderlyingFactor_Tag -> ("246") - | Full_Field_UnderlyingCreditRating_Tag -> ("256") - | Full_Field_UnderlyingInstrRegistry_Tag -> ("595") - | Full_Field_UnderlyingCountryOfIssue_Tag -> ("592") - | Full_Field_UnderlyingStateOrProvinceOfIssue_Tag -> ("593") - | Full_Field_UnderlyingLocaleOfIssue_Tag -> ("594") - | Full_Field_UnderlyingRedemptionDate_Tag -> ("247") - | Full_Field_UnderlyingStrikePrice_Tag -> ("316") - | Full_Field_UnderlyingStrikeCurrency_Tag -> ("941") - | Full_Field_UnderlyingOptAttribute_Tag -> ("317") - | Full_Field_UnderlyingContractMultiplier_Tag -> ("436") - | Full_Field_UnderlyingCouponRate_Tag -> ("435") - | Full_Field_UnderlyingSecurityExchange_Tag -> ("308") - | Full_Field_UnderlyingIssuer_Tag -> ("306") - | Full_Field_EncodedUnderlyingIssuerLen_Tag -> ("362") - | Full_Field_EncodedUnderlyingIssuer_Tag -> ("363") - | Full_Field_UnderlyingSecurityDesc_Tag -> ("307") - | Full_Field_EncodedUnderlyingSecurityDescLen_Tag -> ("364") - | Full_Field_EncodedUnderlyingSecurityDesc_Tag -> ("365") - | Full_Field_UnderlyingCPProgram_Tag -> ("877") - | Full_Field_UnderlyingCPRegType_Tag -> ("878") - | Full_Field_UnderlyingCurrency_Tag -> ("318") - | Full_Field_UnderlyingQty_Tag -> ("879") - | Full_Field_UnderlyingPx_Tag -> ("810") - | Full_Field_UnderlyingDirtyPrice_Tag -> ("882") - | Full_Field_UnderlyingEndPrice_Tag -> ("883") - | Full_Field_UnderlyingStartValue_Tag -> ("884") - | Full_Field_UnderlyingCurrentValue_Tag -> ("885") - | Full_Field_UnderlyingEndValue_Tag -> ("886") - | Full_Field_NoUnderlyingSecurityAltID_Tag -> ("457") - | Full_Field_UnderlyingSecurityAltID_Tag -> ("458") - | Full_Field_UnderlyingSecurityAltIDSource_Tag -> ("459") - | Full_Field_NoUnderlyingStips_Tag -> ("887") - | Full_Field_UnderlyingStipType_Tag -> ("888") - | Full_Field_UnderlyingStipValue_Tag -> ("889") - | Full_Field_NoStipulations_Tag -> ("232") - | Full_Field_StipulationType_Tag -> ("233") - | Full_Field_StipulationValue_Tag -> ("234") - | Full_Field_OrderQty_Tag -> ("38") - | Full_Field_CashOrderQty_Tag -> ("152") - | Full_Field_OrderPercent_Tag -> ("516") - | Full_Field_RoundingDirection_Tag -> ("468") - | Full_Field_RoundingModulus_Tag -> ("469") - | Full_Field_PegOffsetValue_Tag -> ("211") - | Full_Field_PegMoveType_Tag -> ("835") - | Full_Field_PegOffsetType_Tag -> ("836") - | Full_Field_PegLimitType_Tag -> ("837") - | Full_Field_PegRoundDirection_Tag -> ("838") - | Full_Field_PegScope_Tag -> ("840") - | Full_Field_DiscretionInst_Tag -> ("388") - | Full_Field_DiscretionOffsetValue_Tag -> ("389") - | Full_Field_DiscretionMoveType_Tag -> ("841") - | Full_Field_DiscretionOffsetType_Tag -> ("842") - | Full_Field_DiscretionLimitType_Tag -> ("843") - | Full_Field_DiscretionRoundDirection_Tag -> ("844") - | Full_Field_DiscretionScope_Tag -> ("846") - | Full_Field_Commission_Tag -> ("12") - | Full_Field_CommType_Tag -> ("13") - | Full_Field_CommCurrency_Tag -> ("479") - | Full_Field_FundRenewWaiv_Tag -> ("497") - | Full_Field_Spread_Tag -> ("218") - | Full_Field_BenchmarkCurveCurrency_Tag -> ("220") - | Full_Field_BenchmarkCurveName_Tag -> ("221") - | Full_Field_BenchmarkCurvePoint_Tag -> ("222") - | Full_Field_BenchmarkPrice_Tag -> ("662") - | Full_Field_BenchmarkPriceType_Tag -> ("663") - | Full_Field_BenchmarkSecurityID_Tag -> ("699") - | Full_Field_BenchmarkSecurityIDSource_Tag -> ("761") - | Full_Field_YieldType_Tag -> ("235") - | Full_Field_Yield_Tag -> ("236") - | Full_Field_YieldCalcDate_Tag -> ("701") - | Full_Field_YieldRedemptionDate_Tag -> ("696") - | Full_Field_YieldRedemptionPrice_Tag -> ("697") - | Full_Field_YieldRedemptionPriceType_Tag -> ("698") - | Full_Field_NoContAmts_Tag -> ("518") - | Full_Field_ContAmtType_Tag -> ("519") - | Full_Field_ContAmtValue_Tag -> ("520") - | Full_Field_ContAmtCurr_Tag -> ("521") - | Full_Field_NoLegs_Tag -> ("555") - | Full_Field_LegQty_Tag -> ("687") - | Full_Field_LegSwapType_Tag -> ("690") - | Full_Field_LegPositionEffect_Tag -> ("564") - | Full_Field_LegCoveredOrUncovered_Tag -> ("565") - | Full_Field_LegRefID_Tag -> ("654") - | Full_Field_LegPrice_Tag -> ("566") - | Full_Field_LegSettlType_Tag -> ("587") - | Full_Field_LegSettlDate_Tag -> ("588") - | Full_Field_LegLastPx_Tag -> ("637") - | Full_Field_LegSymbol_Tag -> ("600") - | Full_Field_LegSymbolSfx_Tag -> ("601") - | Full_Field_LegSecurityID_Tag -> ("602") - | Full_Field_LegSecurityIDSource_Tag -> ("603") - | Full_Field_LegProduct_Tag -> ("607") - | Full_Field_LegCFICode_Tag -> ("608") - | Full_Field_LegSecurityType_Tag -> ("609") - | Full_Field_LegSecuritySubType_Tag -> ("764") - | Full_Field_LegMaturityMonthYear_Tag -> ("610") - | Full_Field_LegMaturityDate_Tag -> ("611") - | Full_Field_LegCouponPaymentDate_Tag -> ("248") - | Full_Field_LegIssueDate_Tag -> ("249") - | Full_Field_LegRepoCollateralSecurityType_Tag -> ("250") - | Full_Field_LegRepurchaseTerm_Tag -> ("251") - | Full_Field_LegRepurchaseRate_Tag -> ("252") - | Full_Field_LegFactor_Tag -> ("253") - | Full_Field_LegCreditRating_Tag -> ("257") - | Full_Field_LegInstrRegistry_Tag -> ("599") - | Full_Field_LegCountryOfIssue_Tag -> ("596") - | Full_Field_LegStateOrProvinceOfIssue_Tag -> ("597") - | Full_Field_LegLocaleOfIssue_Tag -> ("598") - | Full_Field_LegRedemptionDate_Tag -> ("254") - | Full_Field_LegStrikePrice_Tag -> ("612") - | Full_Field_LegStrikeCurrency_Tag -> ("942") - | Full_Field_LegOptAttribute_Tag -> ("613") - | Full_Field_LegContractMultiplier_Tag -> ("614") - | Full_Field_LegCouponRate_Tag -> ("615") - | Full_Field_LegSecurityExchange_Tag -> ("616") - | Full_Field_LegIssuer_Tag -> ("617") - | Full_Field_EncodedLegIssuerLen_Tag -> ("618") - | Full_Field_EncodedLegIssuer_Tag -> ("619") - | Full_Field_LegSecurityDesc_Tag -> ("620") - | Full_Field_EncodedLegSecurityDescLen_Tag -> ("621") - | Full_Field_EncodedLegSecurityDesc_Tag -> ("622") - | Full_Field_LegRatioQty_Tag -> ("623") - | Full_Field_LegSide_Tag -> ("624") - | Full_Field_LegCurrency_Tag -> ("556") - | Full_Field_LegPool_Tag -> ("740") - | Full_Field_LegDatedDate_Tag -> ("739") - | Full_Field_LegContractSettlMonth_Tag -> ("955") - | Full_Field_LegInterestAccrualDate_Tag -> ("956") - | Full_Field_NoLegSecurityAltID_Tag -> ("604") - | Full_Field_LegSecurityAltID_Tag -> ("605") - | Full_Field_LegSecurityAltIDSource_Tag -> ("606") - | Full_Field_NoLegStipulations_Tag -> ("683") - | Full_Field_LegStipulationType_Tag -> ("688") - | Full_Field_LegStipulationValue_Tag -> ("689") - | Full_Field_NoNestedPartyIDs_Tag -> ("539") - | Full_Field_NestedPartyID_Tag -> ("524") - | Full_Field_NestedPartyIDSource_Tag -> ("525") - | Full_Field_NestedPartyRole_Tag -> ("538") - | Full_Field_NoNestedPartySubIDs_Tag -> ("804") - | Full_Field_NestedPartySubID_Tag -> ("545") - | Full_Field_NestedPartySubIDType_Tag -> ("805") - | Full_Field_NoMiscFees_Tag -> ("136") - | Full_Field_MiscFeeAmt_Tag -> ("137") - | Full_Field_MiscFeeCurr_Tag -> ("138") - | Full_Field_MiscFeeType_Tag -> ("139") - | Full_Field_MiscFeeBasis_Tag -> ("891") - | Full_Field_AllocID_Tag -> ("70") - | Full_Field_ExDestination_Tag -> ("100") - | Full_Field_ProcessCode_Tag -> ("81") - | Full_Field_PrevClosePx_Tag -> ("140") - | Full_Field_LocateReqd_Tag -> ("114") - | Full_Field_IOIID_Tag -> ("23") - | Full_Field_QuoteID_Tag -> ("117") - | Full_Field_ForexReq_Tag -> ("121") - | Full_Field_Price2_Tag -> ("640") - | Full_Field_CoveredOrUncovered_Tag -> ("203") - | Full_Field_NoAllocs_Tag -> ("78") - | Full_Field_AllocAccount_Tag -> ("79") - | Full_Field_AllocAcctIDSource_Tag -> ("661") - | Full_Field_AllocSettlCurrency_Tag -> ("736") - | Full_Field_IndividualAllocID_Tag -> ("467") - | Full_Field_AllocQty_Tag -> ("80") - | Full_Field_NoTradingSessions_Tag -> ("386") ) ;; + +let get_field_tag_name (d) = + (match d with + | "11" -> ("ClOrdID") + | "1" -> ("Account") + | "18" -> ("ExecInst") + | "54" -> ("Side") + | "60" -> ("TransactTime") + | "40" -> ("OrdType") + | "44" -> ("Price") + | "10001" -> ("SpreadProportion") + | "37" -> ("OrderID") + | "17" -> ("ExecID") + | "150" -> ("ExecType") + | "39" -> ("OrdStatus") + | "151" -> ("LeavesQty") + | "14" -> ("CumQty") + | "58" -> ("Text") + | _ -> "" + ) +;; + [@@@logic] diff --git a/src-protocol-exts-pp/encode_utils.iml b/src-protocol-exts-pp/encode_utils.iml index efbc3b5d..13740456 100644 --- a/src-protocol-exts-pp/encode_utils.iml +++ b/src-protocol-exts-pp/encode_utils.iml @@ -1,10 +1,11 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "../src-core-pp/encode_base_types.iml"] -[@@@import "../src-core-pp/encode_datetime.iml"] +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-core-pp/encode_base_types.iml"] open Encode_base_types;; +[@@@import "../src-core-pp/encode_datetime.iml"] open Encode_datetime;; + let enc_req (f) (x) = Some (f x) ;; @@ -23,4 +24,5 @@ let enc_repeat (f) (tag) (lst) = ) []))) ) ;; + [@@@logic] diff --git a/src-protocol-exts-pp/full_app_enums_decoder.iml b/src-protocol-exts-pp/full_app_enums_decoder.iml index 5f8eee6d..24e6819f 100644 --- a/src-protocol-exts-pp/full_app_enums_decoder.iml +++ b/src-protocol-exts-pp/full_app_enums_decoder.iml @@ -8,4964 +8,218 @@ open Decoders_yojson.Basic.Decode.Infix;; open Full_app_enums;; -let string_to_currency_opt (d) = - (match d with - | "CHF" -> (Some FIX_Currency_CHF) - | "EUR" -> (Some FIX_Currency_EUR) - | "GBP" -> (Some FIX_Currency_GBP) - | "USD" -> (Some FIX_Currency_USD) - | _ -> None - ) -;; - -let string_to_country_opt (d) = - (match d with - | "DE" -> (Some FIX_Country_DE) - | "GB" -> (Some FIX_Country_GB) - | "US" -> (Some FIX_Country_US) - | _ -> None - ) -;; - -let string_to_exchange_opt (d) = - (match d with - | "XSHG" -> (Some FIX_Exchange_XSHG) - | "SHSC" -> (Some FIX_Exchange_SHSC) - | "XJAS" -> (Some FIX_Exchange_XJAS) - | "XLON" -> (Some FIX_Exchange_XLON) - | "XNYS" -> (Some FIX_Exchange_XNYS) - | _ -> None - ) -;; - -let string_to_accounttype_opt (d) = - (match d with - | "CarriedCustomerSide" -> (Some FIX_AccountType_CarriedCustomerSide) - | "CarriedNonCustomerSide" -> (Some FIX_AccountType_CarriedNonCustomerSide) - | "HouseTrader" -> (Some FIX_AccountType_HouseTrader) - | "FloorTrader" -> (Some FIX_AccountType_FloorTrader) - | "CarriedNonCustomerSideCrossMargined" -> (Some FIX_AccountType_CarriedNonCustomerSideCrossMargined) - | "HouseTraderCrossMargined" -> (Some FIX_AccountType_HouseTraderCrossMargined) - | "JointBackOfficeAccount" -> (Some FIX_AccountType_JointBackOfficeAccount) - | _ -> None - ) -;; - -let string_to_acctidsource_opt (d) = - (match d with - | "BIC" -> (Some FIX_AcctIDSource_BIC) - | "SIDCode" -> (Some FIX_AcctIDSource_SIDCode) - | "TFM" -> (Some FIX_AcctIDSource_TFM) - | "OMGEO" -> (Some FIX_AcctIDSource_OMGEO) - | "DTCCCode" -> (Some FIX_AcctIDSource_DTCCCode) - | "Other" -> (Some FIX_AcctIDSource_Other) - | _ -> None - ) -;; - -let string_to_adjustment_opt (d) = - (match d with - | "Cancel" -> (Some FIX_Adjustment_Cancel) - | "Error" -> (Some FIX_Adjustment_Error) - | "Correction" -> (Some FIX_Adjustment_Correction) - | _ -> None - ) -;; - -let string_to_adjustmenttype_opt (d) = - (match d with - | "ProcessRequestAsMarginDisposition" -> (Some FIX_AdjustmentType_ProcessRequestAsMarginDisposition) - | "DeltaPlus" -> (Some FIX_AdjustmentType_DeltaPlus) - | "DeltaMinus" -> (Some FIX_AdjustmentType_DeltaMinus) - | "Final" -> (Some FIX_AdjustmentType_Final) - | _ -> None - ) -;; - -let string_to_advside_opt (d) = - (match d with - | "Buy" -> (Some FIX_AdvSide_Buy) - | "Sell" -> (Some FIX_AdvSide_Sell) - | "Cross" -> (Some FIX_AdvSide_Cross) - | "Trade" -> (Some FIX_AdvSide_Trade) - | _ -> None - ) -;; - -let string_to_advtranstype_opt (d) = - (match d with - | "New" -> (Some FIX_AdvTransType_New) - | "Cancel" -> (Some FIX_AdvTransType_Cancel) - | "Replace" -> (Some FIX_AdvTransType_Replace) - | _ -> None - ) -;; - -let string_to_affirmstatus_opt (d) = - (match d with - | "Received" -> (Some FIX_AffirmStatus_Received) - | "ConfirmRejected" -> (Some FIX_AffirmStatus_ConfirmRejected) - | "Affirmed" -> (Some FIX_AffirmStatus_Affirmed) - | _ -> None - ) -;; - -let string_to_aggregatedbook_opt (d) = - (match d with - | "BookEntriesToBeAggregated" -> (Some FIX_AggregatedBook_BookEntriesToBeAggregated) - | "BookEntriesShouldNotBeAggregated" -> (Some FIX_AggregatedBook_BookEntriesShouldNotBeAggregated) - | _ -> None - ) -;; - -let string_to_allocaccounttype_opt (d) = - (match d with - | "CarriedCustomerSide" -> (Some FIX_AllocAccountType_CarriedCustomerSide) - | "CarriedNonCustomerSide" -> (Some FIX_AllocAccountType_CarriedNonCustomerSide) - | "HouseTrader" -> (Some FIX_AllocAccountType_HouseTrader) - | "FloorTrader" -> (Some FIX_AllocAccountType_FloorTrader) - | "CarriedNonCustomerSideCrossMargined" -> (Some FIX_AllocAccountType_CarriedNonCustomerSideCrossMargined) - | "HouseTraderCrossMargined" -> (Some FIX_AllocAccountType_HouseTraderCrossMargined) - | "JointBackOfficeAccount" -> (Some FIX_AllocAccountType_JointBackOfficeAccount) - | _ -> None - ) -;; - -let string_to_alloccancreplacereason_opt (d) = - (match d with - | "OriginalDetailsIncomplete" -> (Some FIX_AllocCancReplaceReason_OriginalDetailsIncomplete) - | "ChangeInUnderlyingOrderDetails" -> (Some FIX_AllocCancReplaceReason_ChangeInUnderlyingOrderDetails) - | "Other" -> (Some FIX_AllocCancReplaceReason_Other) - | _ -> None - ) -;; - -let string_to_allochandlinst_opt (d) = - (match d with - | "Match" -> (Some FIX_AllocHandlInst_Match) - | "Forward" -> (Some FIX_AllocHandlInst_Forward) - | "ForwardAndMatch" -> (Some FIX_AllocHandlInst_ForwardAndMatch) - | _ -> None - ) -;; - -let string_to_allocintermedreqtype_opt (d) = - (match d with - | "PendingAccept" -> (Some FIX_AllocIntermedReqType_PendingAccept) - | "PendingRelease" -> (Some FIX_AllocIntermedReqType_PendingRelease) - | "PendingReversal" -> (Some FIX_AllocIntermedReqType_PendingReversal) - | "Accept" -> (Some FIX_AllocIntermedReqType_Accept) - | "BlockLevelReject" -> (Some FIX_AllocIntermedReqType_BlockLevelReject) - | "AccountLevelReject" -> (Some FIX_AllocIntermedReqType_AccountLevelReject) - | _ -> None - ) -;; - -let string_to_alloclinktype_opt (d) = - (match d with - | "FXNetting" -> (Some FIX_AllocLinkType_FXNetting) - | "FXSwap" -> (Some FIX_AllocLinkType_FXSwap) - | _ -> None - ) -;; - -let string_to_allocnoorderstype_opt (d) = - (match d with - | "NotSpecified" -> (Some FIX_AllocNoOrdersType_NotSpecified) - | "ExplicitListProvided" -> (Some FIX_AllocNoOrdersType_ExplicitListProvided) - | _ -> None - ) -;; - -let string_to_allocrejcode_opt (d) = - (match d with - | "UnknownAccount" -> (Some FIX_AllocRejCode_UnknownAccount) - | "IncorrectQuantity" -> (Some FIX_AllocRejCode_IncorrectQuantity) - | "IncorrectAveragegPrice" -> (Some FIX_AllocRejCode_IncorrectAveragegPrice) - | "UnknownExecutingBrokerMnemonic" -> (Some FIX_AllocRejCode_UnknownExecutingBrokerMnemonic) - | "CommissionDifference" -> (Some FIX_AllocRejCode_CommissionDifference) - | "UnknownOrderID" -> (Some FIX_AllocRejCode_UnknownOrderID) - | "UnknownListID" -> (Some FIX_AllocRejCode_UnknownListID) - | "OtherSeeText" -> (Some FIX_AllocRejCode_OtherSeeText) - | "IncorrectAllocatedQuantity" -> (Some FIX_AllocRejCode_IncorrectAllocatedQuantity) - | "CalculationDifference" -> (Some FIX_AllocRejCode_CalculationDifference) - | "UnknownOrStaleExecID" -> (Some FIX_AllocRejCode_UnknownOrStaleExecID) - | "MismatchedData" -> (Some FIX_AllocRejCode_MismatchedData) - | "UnknownClOrdID" -> (Some FIX_AllocRejCode_UnknownClOrdID) - | "WarehouseRequestRejected" -> (Some FIX_AllocRejCode_WarehouseRequestRejected) - | _ -> None - ) -;; - -let string_to_allocreporttype_opt (d) = - (match d with - | "SellsideCalculatedUsingPreliminary" -> (Some FIX_AllocReportType_SellsideCalculatedUsingPreliminary) - | "SellsideCalculatedWithoutPreliminary" -> (Some FIX_AllocReportType_SellsideCalculatedWithoutPreliminary) - | "WarehouseRecap" -> (Some FIX_AllocReportType_WarehouseRecap) - | "RequestToIntermediary" -> (Some FIX_AllocReportType_RequestToIntermediary) - | _ -> None - ) -;; - -let string_to_allocsettlinsttype_opt (d) = - (match d with - | "UseDefaultInstructions" -> (Some FIX_AllocSettlInstType_UseDefaultInstructions) - | "DeriveFromParametersProvided" -> (Some FIX_AllocSettlInstType_DeriveFromParametersProvided) - | "FullDetailsProvided" -> (Some FIX_AllocSettlInstType_FullDetailsProvided) - | "SSIDBIDsProvided" -> (Some FIX_AllocSettlInstType_SSIDBIDsProvided) - | "PhoneForInstructions" -> (Some FIX_AllocSettlInstType_PhoneForInstructions) - | _ -> None - ) -;; - -let string_to_allocstatus_opt (d) = - (match d with - | "Accepted" -> (Some FIX_AllocStatus_Accepted) - | "BlockLevelReject" -> (Some FIX_AllocStatus_BlockLevelReject) - | "AccountLevelReject" -> (Some FIX_AllocStatus_AccountLevelReject) - | "Received" -> (Some FIX_AllocStatus_Received) - | "Incomplete" -> (Some FIX_AllocStatus_Incomplete) - | "RejectedByIntermediary" -> (Some FIX_AllocStatus_RejectedByIntermediary) - | _ -> None - ) -;; - -let string_to_alloctranstype_opt (d) = - (match d with - | "New" -> (Some FIX_AllocTransType_New) - | "Replace" -> (Some FIX_AllocTransType_Replace) - | "Cancel" -> (Some FIX_AllocTransType_Cancel) - | _ -> None - ) -;; - -let string_to_alloctype_opt (d) = - (match d with - | "Calculated" -> (Some FIX_AllocType_Calculated) - | "Preliminary" -> (Some FIX_AllocType_Preliminary) - | "ReadyToBook" -> (Some FIX_AllocType_ReadyToBook) - | "WarehouseInstruction" -> (Some FIX_AllocType_WarehouseInstruction) - | "RequestToIntermediary" -> (Some FIX_AllocType_RequestToIntermediary) - | _ -> None - ) -;; - -let string_to_applqueueaction_opt (d) = - (match d with - | "NoActionTaken" -> (Some FIX_ApplQueueAction_NoActionTaken) - | "QueueFlushed" -> (Some FIX_ApplQueueAction_QueueFlushed) - | "OverlayLast" -> (Some FIX_ApplQueueAction_OverlayLast) - | "EndSession" -> (Some FIX_ApplQueueAction_EndSession) - | _ -> None - ) -;; - -let string_to_applqueueresolution_opt (d) = - (match d with - | "NoActionTaken" -> (Some FIX_ApplQueueResolution_NoActionTaken) - | "QueueFlushed" -> (Some FIX_ApplQueueResolution_QueueFlushed) - | "OverlayLast" -> (Some FIX_ApplQueueResolution_OverlayLast) - | "EndSession" -> (Some FIX_ApplQueueResolution_EndSession) - | _ -> None - ) -;; - -let string_to_assignmentmethod_opt (d) = - (match d with - | "Random" -> (Some FIX_AssignmentMethod_Random) - | "ProRata" -> (Some FIX_AssignmentMethod_ProRata) - | _ -> None - ) -;; - -let string_to_avgpxindicator_opt (d) = - (match d with - | "NoAveragePricing" -> (Some FIX_AvgPxIndicator_NoAveragePricing) - | "Trade" -> (Some FIX_AvgPxIndicator_Trade) - | "LastTrade" -> (Some FIX_AvgPxIndicator_LastTrade) - | _ -> None - ) -;; - -let string_to_basispxtype_opt (d) = - (match d with - | "ClosingPriceAtMorningSession" -> (Some FIX_BasisPxType_ClosingPriceAtMorningSession) - | "ClosingPrice" -> (Some FIX_BasisPxType_ClosingPrice) - | "CurrentPrice" -> (Some FIX_BasisPxType_CurrentPrice) - | "SQ" -> (Some FIX_BasisPxType_SQ) - | "VWAPThroughADay" -> (Some FIX_BasisPxType_VWAPThroughADay) - | "VWAPThroughAMorningSession" -> (Some FIX_BasisPxType_VWAPThroughAMorningSession) - | "VWAPThroughAnAfternoonSession" -> (Some FIX_BasisPxType_VWAPThroughAnAfternoonSession) - | "VWAPThroughADayExcept" -> (Some FIX_BasisPxType_VWAPThroughADayExcept) - | "VWAPThroughAMorningSessionExcept" -> (Some FIX_BasisPxType_VWAPThroughAMorningSessionExcept) - | "VWAPThroughAnAfternoonSessionExcept" -> (Some FIX_BasisPxType_VWAPThroughAnAfternoonSessionExcept) - | "Strike" -> (Some FIX_BasisPxType_Strike) - | "Open" -> (Some FIX_BasisPxType_Open) - | "Others" -> (Some FIX_BasisPxType_Others) - | _ -> None - ) -;; - -let string_to_biddescriptortype_opt (d) = - (match d with - | "Sector" -> (Some FIX_BidDescriptorType_Sector) - | "Country" -> (Some FIX_BidDescriptorType_Country) - | "Index" -> (Some FIX_BidDescriptorType_Index) - | _ -> None - ) -;; - -let string_to_bidrequesttranstype_opt (d) = - (match d with - | "New" -> (Some FIX_BidRequestTransType_New) - | "Cancel" -> (Some FIX_BidRequestTransType_Cancel) - | _ -> None - ) -;; - -let string_to_bidtradetype_opt (d) = - (match d with - | "RiskTrade" -> (Some FIX_BidTradeType_RiskTrade) - | "VWAPGuarantee" -> (Some FIX_BidTradeType_VWAPGuarantee) - | "Agency" -> (Some FIX_BidTradeType_Agency) - | "GuaranteedClose" -> (Some FIX_BidTradeType_GuaranteedClose) - | _ -> None - ) -;; - -let string_to_bidtype_opt (d) = - (match d with - | "NonDisclosed" -> (Some FIX_BidType_NonDisclosed) - | "Disclosed" -> (Some FIX_BidType_Disclosed) - | "NoBiddingProcess" -> (Some FIX_BidType_NoBiddingProcess) - | _ -> None - ) -;; - -let string_to_bookingtype_opt (d) = - (match d with - | "RegularBooking" -> (Some FIX_BookingType_RegularBooking) - | "CFD" -> (Some FIX_BookingType_CFD) - | "TotalReturnSwap" -> (Some FIX_BookingType_TotalReturnSwap) - | _ -> None - ) -;; - -let string_to_bookingunit_opt (d) = - (match d with - | "EachPartialExecutionIsABookableUnit" -> (Some FIX_BookingUnit_EachPartialExecutionIsABookableUnit) - | "AggregatePartialExecutionsOnThisOrder" -> (Some FIX_BookingUnit_AggregatePartialExecutionsOnThisOrder) - | "AggregateExecutionsForThisSymbol" -> (Some FIX_BookingUnit_AggregateExecutionsForThisSymbol) - | _ -> None - ) -;; - -let string_to_cpprogram_opt (d) = - (match d with - | "Program3a3" -> (Some FIX_CPProgram_Program3a3) - | "Program42" -> (Some FIX_CPProgram_Program42) - | "Other" -> (Some FIX_CPProgram_Other) - | _ -> None - ) -;; - -let string_to_cancellationrights_opt (d) = - (match d with - | "Yes" -> (Some FIX_CancellationRights_Yes) - | "NoExecutionOnly" -> (Some FIX_CancellationRights_NoExecutionOnly) - | "NoWaiverAgreement" -> (Some FIX_CancellationRights_NoWaiverAgreement) - | "NoInstitutional" -> (Some FIX_CancellationRights_NoInstitutional) - | _ -> None - ) -;; - -let string_to_cashmargin_opt (d) = - (match d with - | "Cash" -> (Some FIX_CashMargin_Cash) - | "MarginOpen" -> (Some FIX_CashMargin_MarginOpen) - | "MarginClose" -> (Some FIX_CashMargin_MarginClose) - | _ -> None - ) -;; - -let string_to_clearingfeeindicator_opt (d) = - (match d with - | "CBOEMember" -> (Some FIX_ClearingFeeIndicator_CBOEMember) - | "NonMemberAndCustomer" -> (Some FIX_ClearingFeeIndicator_NonMemberAndCustomer) - | "EquityMemberAndClearingMember" -> (Some FIX_ClearingFeeIndicator_EquityMemberAndClearingMember) - | "FullAndAssociateMember" -> (Some FIX_ClearingFeeIndicator_FullAndAssociateMember) - | "Firms106HAnd106J" -> (Some FIX_ClearingFeeIndicator_Firms106HAnd106J) - | "GIM" -> (Some FIX_ClearingFeeIndicator_GIM) - | "Lessee106FEmployees" -> (Some FIX_ClearingFeeIndicator_Lessee106FEmployees) - | "AllOtherOwnershipTypes" -> (Some FIX_ClearingFeeIndicator_AllOtherOwnershipTypes) - | "FirstYearDelegate" -> (Some FIX_ClearingFeeIndicator_FirstYearDelegate) - | "SecondYearDelegate" -> (Some FIX_ClearingFeeIndicator_SecondYearDelegate) - | "ThirdYearDelegate" -> (Some FIX_ClearingFeeIndicator_ThirdYearDelegate) - | "FourthYearDelegate" -> (Some FIX_ClearingFeeIndicator_FourthYearDelegate) - | "FifthYearDelegate" -> (Some FIX_ClearingFeeIndicator_FifthYearDelegate) - | "SixthYearDelegate" -> (Some FIX_ClearingFeeIndicator_SixthYearDelegate) - | _ -> None - ) -;; - -let string_to_clearinginstruction_opt (d) = - (match d with - | "ProcessNormally" -> (Some FIX_ClearingInstruction_ProcessNormally) - | "ExcludeFromAllNetting" -> (Some FIX_ClearingInstruction_ExcludeFromAllNetting) - | "BilateralNettingOnly" -> (Some FIX_ClearingInstruction_BilateralNettingOnly) - | "ExClearing" -> (Some FIX_ClearingInstruction_ExClearing) - | "SpecialTrade" -> (Some FIX_ClearingInstruction_SpecialTrade) - | "MultilateralNetting" -> (Some FIX_ClearingInstruction_MultilateralNetting) - | "ClearAgainstCentralCounterparty" -> (Some FIX_ClearingInstruction_ClearAgainstCentralCounterparty) - | "ExcludeFromCentralCounterparty" -> (Some FIX_ClearingInstruction_ExcludeFromCentralCounterparty) - | "ManualMode" -> (Some FIX_ClearingInstruction_ManualMode) - | "AutomaticPostingMode" -> (Some FIX_ClearingInstruction_AutomaticPostingMode) - | "AutomaticGiveUpMode" -> (Some FIX_ClearingInstruction_AutomaticGiveUpMode) - | "QualifiedServiceRepresentativeQSR" -> (Some FIX_ClearingInstruction_QualifiedServiceRepresentativeQSR) - | "CustomerTrade" -> (Some FIX_ClearingInstruction_CustomerTrade) - | "SelfClearing" -> (Some FIX_ClearingInstruction_SelfClearing) - | _ -> None - ) -;; - -let string_to_collaction_opt (d) = - (match d with - | "Retain" -> (Some FIX_CollAction_Retain) - | "Add" -> (Some FIX_CollAction_Add) - | "Remove" -> (Some FIX_CollAction_Remove) - | _ -> None - ) -;; - -let string_to_collasgnreason_opt (d) = - (match d with - | "Initial" -> (Some FIX_CollAsgnReason_Initial) - | "Scheduled" -> (Some FIX_CollAsgnReason_Scheduled) - | "TimeWarning" -> (Some FIX_CollAsgnReason_TimeWarning) - | "MarginDeficiency" -> (Some FIX_CollAsgnReason_MarginDeficiency) - | "MarginExcess" -> (Some FIX_CollAsgnReason_MarginExcess) - | "ForwardCollateralDemand" -> (Some FIX_CollAsgnReason_ForwardCollateralDemand) - | "EventOfDefault" -> (Some FIX_CollAsgnReason_EventOfDefault) - | "AdverseTaxEvent" -> (Some FIX_CollAsgnReason_AdverseTaxEvent) - | _ -> None - ) -;; - -let string_to_collasgnrejectreason_opt (d) = - (match d with - | "UnknownDeal" -> (Some FIX_CollAsgnRejectReason_UnknownDeal) - | "UnknownOrInvalidInstrument" -> (Some FIX_CollAsgnRejectReason_UnknownOrInvalidInstrument) - | "UnauthorizedTransaction" -> (Some FIX_CollAsgnRejectReason_UnauthorizedTransaction) - | "InsufficientCollateral" -> (Some FIX_CollAsgnRejectReason_InsufficientCollateral) - | "InvalidTypeOfCollateral" -> (Some FIX_CollAsgnRejectReason_InvalidTypeOfCollateral) - | "ExcessiveSubstitution" -> (Some FIX_CollAsgnRejectReason_ExcessiveSubstitution) - | "Other" -> (Some FIX_CollAsgnRejectReason_Other) - | _ -> None - ) -;; - -let string_to_collasgnresptype_opt (d) = - (match d with - | "Received" -> (Some FIX_CollAsgnRespType_Received) - | "Accepted" -> (Some FIX_CollAsgnRespType_Accepted) - | "Declined" -> (Some FIX_CollAsgnRespType_Declined) - | "Rejected" -> (Some FIX_CollAsgnRespType_Rejected) - | _ -> None - ) -;; - -let string_to_collasgntranstype_opt (d) = - (match d with - | "New" -> (Some FIX_CollAsgnTransType_New) - | "Replace" -> (Some FIX_CollAsgnTransType_Replace) - | "Cancel" -> (Some FIX_CollAsgnTransType_Cancel) - | "Release" -> (Some FIX_CollAsgnTransType_Release) - | "Reverse" -> (Some FIX_CollAsgnTransType_Reverse) - | _ -> None - ) -;; - -let string_to_collinquiryqualifier_opt (d) = - (match d with - | "TradeDate" -> (Some FIX_CollInquiryQualifier_TradeDate) - | "GCInstrument" -> (Some FIX_CollInquiryQualifier_GCInstrument) - | "CollateralInstrument" -> (Some FIX_CollInquiryQualifier_CollateralInstrument) - | "SubstitutionEligible" -> (Some FIX_CollInquiryQualifier_SubstitutionEligible) - | "NotAssigned" -> (Some FIX_CollInquiryQualifier_NotAssigned) - | "PartiallyAssigned" -> (Some FIX_CollInquiryQualifier_PartiallyAssigned) - | "FullyAssigned" -> (Some FIX_CollInquiryQualifier_FullyAssigned) - | "OutstandingTrades" -> (Some FIX_CollInquiryQualifier_OutstandingTrades) - | _ -> None - ) -;; - -let string_to_collinquiryresult_opt (d) = - (match d with - | "Successful" -> (Some FIX_CollInquiryResult_Successful) - | "InvalidOrUnknownInstrument" -> (Some FIX_CollInquiryResult_InvalidOrUnknownInstrument) - | "InvalidOrUnknownCollateralType" -> (Some FIX_CollInquiryResult_InvalidOrUnknownCollateralType) - | "InvalidParties" -> (Some FIX_CollInquiryResult_InvalidParties) - | "InvalidTransportTypeRequested" -> (Some FIX_CollInquiryResult_InvalidTransportTypeRequested) - | "InvalidDestinationRequested" -> (Some FIX_CollInquiryResult_InvalidDestinationRequested) - | "NoCollateralFoundForTheTradeSpecified" -> (Some FIX_CollInquiryResult_NoCollateralFoundForTheTradeSpecified) - | "NoCollateralFoundForTheOrderSpecified" -> (Some FIX_CollInquiryResult_NoCollateralFoundForTheOrderSpecified) - | "CollateralInquiryTypeNotSupported" -> (Some FIX_CollInquiryResult_CollateralInquiryTypeNotSupported) - | "UnauthorizedForCollateralInquiry" -> (Some FIX_CollInquiryResult_UnauthorizedForCollateralInquiry) - | "Other" -> (Some FIX_CollInquiryResult_Other) - | _ -> None - ) -;; - -let string_to_collinquirystatus_opt (d) = - (match d with - | "Accepted" -> (Some FIX_CollInquiryStatus_Accepted) - | "AcceptedWithWarnings" -> (Some FIX_CollInquiryStatus_AcceptedWithWarnings) - | "Completed" -> (Some FIX_CollInquiryStatus_Completed) - | "CompletedWithWarnings" -> (Some FIX_CollInquiryStatus_CompletedWithWarnings) - | "Rejected" -> (Some FIX_CollInquiryStatus_Rejected) - | _ -> None - ) -;; - -let string_to_collstatus_opt (d) = - (match d with - | "Unassigned" -> (Some FIX_CollStatus_Unassigned) - | "PartiallyAssigned" -> (Some FIX_CollStatus_PartiallyAssigned) - | "AssignmentProposed" -> (Some FIX_CollStatus_AssignmentProposed) - | "Assigned" -> (Some FIX_CollStatus_Assigned) - | "Challenged" -> (Some FIX_CollStatus_Challenged) - | _ -> None - ) -;; - -let string_to_commtype_opt (d) = - (match d with - | "PerUnit" -> (Some FIX_CommType_PerUnit) - | "Percent" -> (Some FIX_CommType_Percent) - | "Absolute" -> (Some FIX_CommType_Absolute) - | "PercentageWaivedCashDiscount" -> (Some FIX_CommType_PercentageWaivedCashDiscount) - | "PercentageWaivedEnhancedUnits" -> (Some FIX_CommType_PercentageWaivedEnhancedUnits) - | "PointsPerBondOrContract" -> (Some FIX_CommType_PointsPerBondOrContract) - | _ -> None - ) -;; - -let string_to_confirmrejreason_opt (d) = - (match d with - | "MismatchedAccount" -> (Some FIX_ConfirmRejReason_MismatchedAccount) - | "MissingSettlementInstructions" -> (Some FIX_ConfirmRejReason_MissingSettlementInstructions) - | "Other" -> (Some FIX_ConfirmRejReason_Other) - | _ -> None - ) -;; - -let string_to_confirmstatus_opt (d) = - (match d with - | "Received" -> (Some FIX_ConfirmStatus_Received) - | "MismatchedAccount" -> (Some FIX_ConfirmStatus_MismatchedAccount) - | "MissingSettlementInstructions" -> (Some FIX_ConfirmStatus_MissingSettlementInstructions) - | "Confirmed" -> (Some FIX_ConfirmStatus_Confirmed) - | "RequestRejected" -> (Some FIX_ConfirmStatus_RequestRejected) - | _ -> None - ) -;; - -let string_to_confirmtranstype_opt (d) = - (match d with - | "New" -> (Some FIX_ConfirmTransType_New) - | "Replace" -> (Some FIX_ConfirmTransType_Replace) - | "Cancel" -> (Some FIX_ConfirmTransType_Cancel) - | _ -> None - ) -;; - -let string_to_confirmtype_opt (d) = - (match d with - | "Status" -> (Some FIX_ConfirmType_Status) - | "Confirmation" -> (Some FIX_ConfirmType_Confirmation) - | "ConfirmationRequestRejected" -> (Some FIX_ConfirmType_ConfirmationRequestRejected) - | _ -> None - ) -;; - -let string_to_contamttype_opt (d) = - (match d with - | "CommissionAmount" -> (Some FIX_ContAmtType_CommissionAmount) - | "CommissionPercent" -> (Some FIX_ContAmtType_CommissionPercent) - | "InitialChargeAmount" -> (Some FIX_ContAmtType_InitialChargeAmount) - | "InitialChargePercent" -> (Some FIX_ContAmtType_InitialChargePercent) - | "DiscountAmount" -> (Some FIX_ContAmtType_DiscountAmount) - | "DiscountPercent" -> (Some FIX_ContAmtType_DiscountPercent) - | "DilutionLevyAmount" -> (Some FIX_ContAmtType_DilutionLevyAmount) - | "DilutionLevyPercent" -> (Some FIX_ContAmtType_DilutionLevyPercent) - | "ExitChargeAmount" -> (Some FIX_ContAmtType_ExitChargeAmount) - | "ExitChargePercent" -> (Some FIX_ContAmtType_ExitChargePercent) - | "FundBasedRenewalCommissionPercent" -> (Some FIX_ContAmtType_FundBasedRenewalCommissionPercent) - | "ProjectedFundValue" -> (Some FIX_ContAmtType_ProjectedFundValue) - | "FundBasedRenewalCommissionOnOrder" -> (Some FIX_ContAmtType_FundBasedRenewalCommissionOnOrder) - | "FundBasedRenewalCommissionOnFund" -> (Some FIX_ContAmtType_FundBasedRenewalCommissionOnFund) - | "NetSettlementAmount" -> (Some FIX_ContAmtType_NetSettlementAmount) - | _ -> None - ) -;; - -let string_to_corporateaction_opt (d) = - (match d with - | "ExDividend" -> (Some FIX_CorporateAction_ExDividend) - | "ExDistribution" -> (Some FIX_CorporateAction_ExDistribution) - | "ExRights" -> (Some FIX_CorporateAction_ExRights) - | "New" -> (Some FIX_CorporateAction_New) - | "ExInterest" -> (Some FIX_CorporateAction_ExInterest) - | _ -> None - ) -;; - -let string_to_coveredoruncovered_opt (d) = - (match d with - | "Covered" -> (Some FIX_CoveredOrUncovered_Covered) - | "Uncovered" -> (Some FIX_CoveredOrUncovered_Uncovered) - | _ -> None - ) -;; - -let string_to_crossprioritization_opt (d) = - (match d with - | "FIXNone" -> (Some FIX_CrossPrioritization_FIXNone) - | "BuySideIsPrioritized" -> (Some FIX_CrossPrioritization_BuySideIsPrioritized) - | "SellSideIsPrioritized" -> (Some FIX_CrossPrioritization_SellSideIsPrioritized) - | _ -> None - ) -;; - -let string_to_crosstype_opt (d) = - (match d with - | "CrossAON" -> (Some FIX_CrossType_CrossAON) - | "CrossIOC" -> (Some FIX_CrossType_CrossIOC) - | "CrossOneSide" -> (Some FIX_CrossType_CrossOneSide) - | "CrossSamePrice" -> (Some FIX_CrossType_CrossSamePrice) - | _ -> None - ) -;; - -let string_to_custordercapacity_opt (d) = - (match d with - | "MemberTradingForTheirOwnAccount" -> (Some FIX_CustOrderCapacity_MemberTradingForTheirOwnAccount) - | "ClearingFirmTradingForItsProprietaryAccount" -> (Some FIX_CustOrderCapacity_ClearingFirmTradingForItsProprietaryAccount) - | "MemberTradingForAnotherMember" -> (Some FIX_CustOrderCapacity_MemberTradingForAnotherMember) - | "AllOther" -> (Some FIX_CustOrderCapacity_AllOther) - | _ -> None - ) -;; - -let string_to_cxlrejreason_opt (d) = - (match d with - | "TooLateToCancel" -> (Some FIX_CxlRejReason_TooLateToCancel) - | "UnknownOrder" -> (Some FIX_CxlRejReason_UnknownOrder) - | "BrokerCredit" -> (Some FIX_CxlRejReason_BrokerCredit) - | "OrderAlreadyInPendingStatus" -> (Some FIX_CxlRejReason_OrderAlreadyInPendingStatus) - | "UnableToProcessOrderMassCancelRequest" -> (Some FIX_CxlRejReason_UnableToProcessOrderMassCancelRequest) - | "OrigOrdModTime" -> (Some FIX_CxlRejReason_OrigOrdModTime) - | "DuplicateClOrdID" -> (Some FIX_CxlRejReason_DuplicateClOrdID) - | "Other" -> (Some FIX_CxlRejReason_Other) - | _ -> None - ) -;; - -let string_to_dkreason_opt (d) = - (match d with - | "UnknownSymbol" -> (Some FIX_DKReason_UnknownSymbol) - | "WrongSide" -> (Some FIX_DKReason_WrongSide) - | "QuantityExceedsOrder" -> (Some FIX_DKReason_QuantityExceedsOrder) - | "NoMatchingOrder" -> (Some FIX_DKReason_NoMatchingOrder) - | "PriceExceedsLimit" -> (Some FIX_DKReason_PriceExceedsLimit) - | "CalculationDifference" -> (Some FIX_DKReason_CalculationDifference) - | "Other" -> (Some FIX_DKReason_Other) - | _ -> None - ) -;; - -let string_to_daybookinginst_opt (d) = - (match d with - | "Auto" -> (Some FIX_DayBookingInst_Auto) - | "SpeakWithOrderInitiatorBeforeBooking" -> (Some FIX_DayBookingInst_SpeakWithOrderInitiatorBeforeBooking) - | "Accumulate" -> (Some FIX_DayBookingInst_Accumulate) - | _ -> None - ) -;; - -let string_to_deletereason_opt (d) = - (match d with - | "Cancellation" -> (Some FIX_DeleteReason_Cancellation) - | "Error" -> (Some FIX_DeleteReason_Error) - | _ -> None - ) -;; - -let string_to_deliveryform_opt (d) = - (match d with - | "BookEntry" -> (Some FIX_DeliveryForm_BookEntry) - | "Bearer" -> (Some FIX_DeliveryForm_Bearer) - | _ -> None - ) -;; - -let string_to_deliverytype_opt (d) = - (match d with - | "VersusPayment" -> (Some FIX_DeliveryType_VersusPayment) - | "Free" -> (Some FIX_DeliveryType_Free) - | "TriParty" -> (Some FIX_DeliveryType_TriParty) - | "HoldInCustody" -> (Some FIX_DeliveryType_HoldInCustody) - | _ -> None - ) -;; - -let string_to_discretioninst_opt (d) = - (match d with - | "RelatedToDisplayedPrice" -> (Some FIX_DiscretionInst_RelatedToDisplayedPrice) - | "RelatedToMarketPrice" -> (Some FIX_DiscretionInst_RelatedToMarketPrice) - | "RelatedToPrimaryPrice" -> (Some FIX_DiscretionInst_RelatedToPrimaryPrice) - | "RelatedToLocalPrimaryPrice" -> (Some FIX_DiscretionInst_RelatedToLocalPrimaryPrice) - | "RelatedToMidpointPrice" -> (Some FIX_DiscretionInst_RelatedToMidpointPrice) - | "RelatedToLastTradePrice" -> (Some FIX_DiscretionInst_RelatedToLastTradePrice) - | "RelatedToVWAP" -> (Some FIX_DiscretionInst_RelatedToVWAP) - | _ -> None - ) -;; - -let string_to_discretionlimittype_opt (d) = - (match d with - | "OrBetter" -> (Some FIX_DiscretionLimitType_OrBetter) - | "Strict" -> (Some FIX_DiscretionLimitType_Strict) - | "OrWorse" -> (Some FIX_DiscretionLimitType_OrWorse) - | _ -> None - ) -;; - -let string_to_discretionmovetype_opt (d) = - (match d with - | "Floating" -> (Some FIX_DiscretionMoveType_Floating) - | "Fixed" -> (Some FIX_DiscretionMoveType_Fixed) - | _ -> None - ) -;; - -let string_to_discretionoffsettype_opt (d) = - (match d with - | "Price" -> (Some FIX_DiscretionOffsetType_Price) - | "BasisPoints" -> (Some FIX_DiscretionOffsetType_BasisPoints) - | "Ticks" -> (Some FIX_DiscretionOffsetType_Ticks) - | "PriceTier" -> (Some FIX_DiscretionOffsetType_PriceTier) - | _ -> None - ) -;; - -let string_to_discretionrounddirection_opt (d) = - (match d with - | "MoreAggressive" -> (Some FIX_DiscretionRoundDirection_MoreAggressive) - | "MorePassive" -> (Some FIX_DiscretionRoundDirection_MorePassive) - | _ -> None - ) -;; - -let string_to_discretionscope_opt (d) = - (match d with - | "Local" -> (Some FIX_DiscretionScope_Local) - | "National" -> (Some FIX_DiscretionScope_National) - | "Global" -> (Some FIX_DiscretionScope_Global) - | "NationalExcludingLocal" -> (Some FIX_DiscretionScope_NationalExcludingLocal) - | _ -> None - ) -;; - -let string_to_distribpaymentmethod_opt (d) = - (match d with - | "CREST" -> (Some FIX_DistribPaymentMethod_CREST) - | "NSCC" -> (Some FIX_DistribPaymentMethod_NSCC) - | "Euroclear" -> (Some FIX_DistribPaymentMethod_Euroclear) - | "Clearstream" -> (Some FIX_DistribPaymentMethod_Clearstream) - | "Cheque" -> (Some FIX_DistribPaymentMethod_Cheque) - | "TelegraphicTransfer" -> (Some FIX_DistribPaymentMethod_TelegraphicTransfer) - | "FedWire" -> (Some FIX_DistribPaymentMethod_FedWire) - | "DirectCredit" -> (Some FIX_DistribPaymentMethod_DirectCredit) - | "ACHCredit" -> (Some FIX_DistribPaymentMethod_ACHCredit) - | "BPAY" -> (Some FIX_DistribPaymentMethod_BPAY) - | "HighValueClearingSystemHVACS" -> (Some FIX_DistribPaymentMethod_HighValueClearingSystemHVACS) - | "ReinvestInFund" -> (Some FIX_DistribPaymentMethod_ReinvestInFund) - | _ -> None - ) -;; - -let string_to_dlvyinsttype_opt (d) = - (match d with - | "Securities" -> (Some FIX_DlvyInstType_Securities) - | "Cash" -> (Some FIX_DlvyInstType_Cash) - | _ -> None - ) -;; - -let string_to_duetorelated_opt (d) = - (match d with - | "RelatedToSecurityHalt" -> (Some FIX_DueToRelated_RelatedToSecurityHalt) - | "NotRelatedToSecurityHalt" -> (Some FIX_DueToRelated_NotRelatedToSecurityHalt) - | _ -> None - ) -;; - -let string_to_emailtype_opt (d) = - (match d with - | "New" -> (Some FIX_EmailType_New) - | "Reply" -> (Some FIX_EmailType_Reply) - | "AdminReply" -> (Some FIX_EmailType_AdminReply) - | _ -> None - ) -;; - -let string_to_eventtype_opt (d) = - (match d with - | "Put" -> (Some FIX_EventType_Put) - | "Call" -> (Some FIX_EventType_Call) - | "Tender" -> (Some FIX_EventType_Tender) - | "SinkingFundCall" -> (Some FIX_EventType_SinkingFundCall) - | "Other" -> (Some FIX_EventType_Other) - | _ -> None - ) -;; - -let string_to_exchangeforphysical_opt (d) = - (match d with - | "True" -> (Some FIX_ExchangeForPhysical_True) - | "False" -> (Some FIX_ExchangeForPhysical_False) - | _ -> None - ) -;; - -let string_to_execinst_opt (d) = - (match d with - | "NotHeld" -> (Some FIX_ExecInst_NotHeld) - | "Work" -> (Some FIX_ExecInst_Work) - | "GoAlong" -> (Some FIX_ExecInst_GoAlong) - | "OverTheDay" -> (Some FIX_ExecInst_OverTheDay) - | "Held" -> (Some FIX_ExecInst_Held) - | "ParticipateDoNotInitiate" -> (Some FIX_ExecInst_ParticipateDoNotInitiate) - | "StrictScale" -> (Some FIX_ExecInst_StrictScale) - | "TryToScale" -> (Some FIX_ExecInst_TryToScale) - | "StayOnBidSide" -> (Some FIX_ExecInst_StayOnBidSide) - | "StayOnOfferSide" -> (Some FIX_ExecInst_StayOnOfferSide) - | "NoCross" -> (Some FIX_ExecInst_NoCross) - | "OKToCross" -> (Some FIX_ExecInst_OKToCross) - | "CallFirst" -> (Some FIX_ExecInst_CallFirst) - | "PercentOfVolume" -> (Some FIX_ExecInst_PercentOfVolume) - | "DoNotIncrease" -> (Some FIX_ExecInst_DoNotIncrease) - | "DoNotReduce" -> (Some FIX_ExecInst_DoNotReduce) - | "AllOrNone" -> (Some FIX_ExecInst_AllOrNone) - | "ReinstateOnSystemFailure" -> (Some FIX_ExecInst_ReinstateOnSystemFailure) - | "InstitutionsOnly" -> (Some FIX_ExecInst_InstitutionsOnly) - | "ReinstateOnTradingHalt" -> (Some FIX_ExecInst_ReinstateOnTradingHalt) - | "CancelOnTradingHalt" -> (Some FIX_ExecInst_CancelOnTradingHalt) - | "LastPeg" -> (Some FIX_ExecInst_LastPeg) - | "MidPricePeg" -> (Some FIX_ExecInst_MidPricePeg) - | "NonNegotiable" -> (Some FIX_ExecInst_NonNegotiable) - | "OpeningPeg" -> (Some FIX_ExecInst_OpeningPeg) - | "MarketPeg" -> (Some FIX_ExecInst_MarketPeg) - | "CancelOnSystemFailure" -> (Some FIX_ExecInst_CancelOnSystemFailure) - | "PrimaryPeg" -> (Some FIX_ExecInst_PrimaryPeg) - | "Suspend" -> (Some FIX_ExecInst_Suspend) - | "CustomerDisplayInstruction" -> (Some FIX_ExecInst_CustomerDisplayInstruction) - | "Netting" -> (Some FIX_ExecInst_Netting) - | "PegToVWAP" -> (Some FIX_ExecInst_PegToVWAP) - | "TradeAlong" -> (Some FIX_ExecInst_TradeAlong) - | "TryToStop" -> (Some FIX_ExecInst_TryToStop) - | "CancelIfNotBest" -> (Some FIX_ExecInst_CancelIfNotBest) - | "TrailingStopPeg" -> (Some FIX_ExecInst_TrailingStopPeg) - | "StrictLimit" -> (Some FIX_ExecInst_StrictLimit) - | "IgnorePriceValidityChecks" -> (Some FIX_ExecInst_IgnorePriceValidityChecks) - | "PegToLimitPrice" -> (Some FIX_ExecInst_PegToLimitPrice) - | "WorkToTargetStrategy" -> (Some FIX_ExecInst_WorkToTargetStrategy) - | _ -> None - ) -;; - -let string_to_execpricetype_opt (d) = - (match d with - | "BidPrice" -> (Some FIX_ExecPriceType_BidPrice) - | "CreationPrice" -> (Some FIX_ExecPriceType_CreationPrice) - | "CreationPricePlusAdjustmentPercent" -> (Some FIX_ExecPriceType_CreationPricePlusAdjustmentPercent) - | "CreationPricePlusAdjustmentAmount" -> (Some FIX_ExecPriceType_CreationPricePlusAdjustmentAmount) - | "OfferPrice" -> (Some FIX_ExecPriceType_OfferPrice) - | "OfferPriceMinusAdjustmentPercent" -> (Some FIX_ExecPriceType_OfferPriceMinusAdjustmentPercent) - | "OfferPriceMinusAdjustmentAmount" -> (Some FIX_ExecPriceType_OfferPriceMinusAdjustmentAmount) - | "SinglePrice" -> (Some FIX_ExecPriceType_SinglePrice) - | _ -> None - ) -;; - -let string_to_execrestatementreason_opt (d) = - (match d with - | "GTCorporateAction" -> (Some FIX_ExecRestatementReason_GTCorporateAction) - | "GTRenewal" -> (Some FIX_ExecRestatementReason_GTRenewal) - | "VerbalChange" -> (Some FIX_ExecRestatementReason_VerbalChange) - | "RepricingOfOrder" -> (Some FIX_ExecRestatementReason_RepricingOfOrder) - | "BrokerOption" -> (Some FIX_ExecRestatementReason_BrokerOption) - | "PartialDeclineOfOrderQty" -> (Some FIX_ExecRestatementReason_PartialDeclineOfOrderQty) - | "CancelOnTradingHalt" -> (Some FIX_ExecRestatementReason_CancelOnTradingHalt) - | "CancelOnSystemFailure" -> (Some FIX_ExecRestatementReason_CancelOnSystemFailure) - | "Market" -> (Some FIX_ExecRestatementReason_Market) - | "Canceled" -> (Some FIX_ExecRestatementReason_Canceled) - | "WarehouseRecap" -> (Some FIX_ExecRestatementReason_WarehouseRecap) - | "Other" -> (Some FIX_ExecRestatementReason_Other) - | _ -> None - ) -;; - -let string_to_exectype_opt (d) = - (match d with - | "New" -> (Some FIX_ExecType_New) - | "DoneForDay" -> (Some FIX_ExecType_DoneForDay) - | "Canceled" -> (Some FIX_ExecType_Canceled) - | "Replaced" -> (Some FIX_ExecType_Replaced) - | "PendingCancel" -> (Some FIX_ExecType_PendingCancel) - | "Stopped" -> (Some FIX_ExecType_Stopped) - | "Rejected" -> (Some FIX_ExecType_Rejected) - | "Suspended" -> (Some FIX_ExecType_Suspended) - | "PendingNew" -> (Some FIX_ExecType_PendingNew) - | "Calculated" -> (Some FIX_ExecType_Calculated) - | "Expired" -> (Some FIX_ExecType_Expired) - | "Restated" -> (Some FIX_ExecType_Restated) - | "PendingReplace" -> (Some FIX_ExecType_PendingReplace) - | "Trade" -> (Some FIX_ExecType_Trade) - | "TradeCorrect" -> (Some FIX_ExecType_TradeCorrect) - | "TradeCancel" -> (Some FIX_ExecType_TradeCancel) - | "OrderStatus" -> (Some FIX_ExecType_OrderStatus) - | _ -> None - ) -;; - -let string_to_exercisemethod_opt (d) = - (match d with - | "Automatic" -> (Some FIX_ExerciseMethod_Automatic) - | "Manual" -> (Some FIX_ExerciseMethod_Manual) - | _ -> None - ) -;; - -let string_to_expirationcycle_opt (d) = - (match d with - | "ExpireOnTradingSessionClose" -> (Some FIX_ExpirationCycle_ExpireOnTradingSessionClose) - | "ExpireOnTradingSessionOpen" -> (Some FIX_ExpirationCycle_ExpireOnTradingSessionOpen) - | _ -> None - ) -;; - -let string_to_financialstatus_opt (d) = - (match d with - | "Bankrupt" -> (Some FIX_FinancialStatus_Bankrupt) - | "PendingDelisting" -> (Some FIX_FinancialStatus_PendingDelisting) - | _ -> None - ) -;; - -let string_to_forexreq_opt (d) = - (match d with - | "ExecuteForexAfterSecurityTrade" -> (Some FIX_ForexReq_ExecuteForexAfterSecurityTrade) - | "DoNotExecuteForexAfterSecurityTrade" -> (Some FIX_ForexReq_DoNotExecuteForexAfterSecurityTrade) - | _ -> None - ) -;; - -let string_to_fundrenewwaiv_opt (d) = - (match d with - | "Yes" -> (Some FIX_FundRenewWaiv_Yes) - | "No" -> (Some FIX_FundRenewWaiv_No) - | _ -> None - ) -;; - -let string_to_gtbookinginst_opt (d) = - (match d with - | "BookOutAllTradesOnDayOfExecution" -> (Some FIX_GTBookingInst_BookOutAllTradesOnDayOfExecution) - | "AccumulateUntilFilledOrExpired" -> (Some FIX_GTBookingInst_AccumulateUntilFilledOrExpired) - | "AccumulateUntilVerballyNotifiedOtherwise" -> (Some FIX_GTBookingInst_AccumulateUntilVerballyNotifiedOtherwise) - | _ -> None - ) -;; - -let string_to_haltreason_opt (d) = - (match d with - | "OrderImbalance" -> (Some FIX_HaltReason_OrderImbalance) - | "EquipmentChangeover" -> (Some FIX_HaltReason_EquipmentChangeover) - | "NewsPending" -> (Some FIX_HaltReason_NewsPending) - | "NewsDissemination" -> (Some FIX_HaltReason_NewsDissemination) - | "OrderInflux" -> (Some FIX_HaltReason_OrderInflux) - | "AdditionalInformation" -> (Some FIX_HaltReason_AdditionalInformation) - | _ -> None - ) -;; - -let string_to_handlinst_opt (d) = - (match d with - | "AutomatedExecutionNoIntervention" -> (Some FIX_HandlInst_AutomatedExecutionNoIntervention) - | "AutomatedExecutionInterventionOK" -> (Some FIX_HandlInst_AutomatedExecutionInterventionOK) - | "ManualOrder" -> (Some FIX_HandlInst_ManualOrder) - | _ -> None - ) -;; - -let string_to_ioinaturalflag_opt (d) = - (match d with - | "Natural" -> (Some FIX_IOINaturalFlag_Natural) - | "NotNatural" -> (Some FIX_IOINaturalFlag_NotNatural) - | _ -> None - ) -;; - -let string_to_ioiqltyind_opt (d) = - (match d with - | "Low" -> (Some FIX_IOIQltyInd_Low) - | "Medium" -> (Some FIX_IOIQltyInd_Medium) - | "High" -> (Some FIX_IOIQltyInd_High) - | _ -> None - ) -;; - -let string_to_ioiqty_opt (d) = - (match d with - | "Small" -> (Some FIX_IOIQty_Small) - | "Medium" -> (Some FIX_IOIQty_Medium) - | "Large" -> (Some FIX_IOIQty_Large) - | _ -> None - ) -;; - -let string_to_ioiqualifier_opt (d) = - (match d with - | "AllOrNone" -> (Some FIX_IOIQualifier_AllOrNone) - | "MarketOnClose" -> (Some FIX_IOIQualifier_MarketOnClose) - | "AtTheClose" -> (Some FIX_IOIQualifier_AtTheClose) - | "VWAP" -> (Some FIX_IOIQualifier_VWAP) - | "InTouchWith" -> (Some FIX_IOIQualifier_InTouchWith) - | "Limit" -> (Some FIX_IOIQualifier_Limit) - | "MoreBehind" -> (Some FIX_IOIQualifier_MoreBehind) - | "AtTheOpen" -> (Some FIX_IOIQualifier_AtTheOpen) - | "TakingAPosition" -> (Some FIX_IOIQualifier_TakingAPosition) - | "AtTheMarket" -> (Some FIX_IOIQualifier_AtTheMarket) - | "ReadyToTrade" -> (Some FIX_IOIQualifier_ReadyToTrade) - | "PortfolioShown" -> (Some FIX_IOIQualifier_PortfolioShown) - | "ThroughTheDay" -> (Some FIX_IOIQualifier_ThroughTheDay) - | "Versus" -> (Some FIX_IOIQualifier_Versus) - | "Indication" -> (Some FIX_IOIQualifier_Indication) - | "CrossingOpportunity" -> (Some FIX_IOIQualifier_CrossingOpportunity) - | "AtTheMidpoint" -> (Some FIX_IOIQualifier_AtTheMidpoint) - | "PreOpen" -> (Some FIX_IOIQualifier_PreOpen) - | _ -> None - ) -;; - -let string_to_ioitranstype_opt (d) = - (match d with - | "New" -> (Some FIX_IOITransType_New) - | "Cancel" -> (Some FIX_IOITransType_Cancel) - | "Replace" -> (Some FIX_IOITransType_Replace) - | _ -> None - ) -;; - -let string_to_inviewofcommon_opt (d) = - (match d with - | "HaltWasDueToCommonStockBeingHalted" -> (Some FIX_InViewOfCommon_HaltWasDueToCommonStockBeingHalted) - | "HaltWasNotRelatedToAHaltOfTheCommonStock" -> (Some FIX_InViewOfCommon_HaltWasNotRelatedToAHaltOfTheCommonStock) - | _ -> None - ) -;; - -let string_to_inctaxind_opt (d) = - (match d with - | "Net" -> (Some FIX_IncTaxInd_Net) - | "Gross" -> (Some FIX_IncTaxInd_Gross) - | _ -> None - ) -;; - -let string_to_instrattribtype_opt (d) = - (match d with - | "Flat" -> (Some FIX_InstrAttribType_Flat) - | "ZeroCoupon" -> (Some FIX_InstrAttribType_ZeroCoupon) - | "InterestBearing" -> (Some FIX_InstrAttribType_InterestBearing) - | "NoPeriodicPayments" -> (Some FIX_InstrAttribType_NoPeriodicPayments) - | "VariableRate" -> (Some FIX_InstrAttribType_VariableRate) - | "LessFeeForPut" -> (Some FIX_InstrAttribType_LessFeeForPut) - | "SteppedCoupon" -> (Some FIX_InstrAttribType_SteppedCoupon) - | "CouponPeriod" -> (Some FIX_InstrAttribType_CouponPeriod) - | "When" -> (Some FIX_InstrAttribType_When) - | "OriginalIssueDiscount" -> (Some FIX_InstrAttribType_OriginalIssueDiscount) - | "Callable" -> (Some FIX_InstrAttribType_Callable) - | "EscrowedToMaturity" -> (Some FIX_InstrAttribType_EscrowedToMaturity) - | "EscrowedToRedemptionDate" -> (Some FIX_InstrAttribType_EscrowedToRedemptionDate) - | "PreRefunded" -> (Some FIX_InstrAttribType_PreRefunded) - | "InDefault" -> (Some FIX_InstrAttribType_InDefault) - | "Unrated" -> (Some FIX_InstrAttribType_Unrated) - | "Taxable" -> (Some FIX_InstrAttribType_Taxable) - | "Indexed" -> (Some FIX_InstrAttribType_Indexed) - | "SubjectToAlternativeMinimumTax" -> (Some FIX_InstrAttribType_SubjectToAlternativeMinimumTax) - | "OriginalIssueDiscountPrice" -> (Some FIX_InstrAttribType_OriginalIssueDiscountPrice) - | "CallableBelowMaturityValue" -> (Some FIX_InstrAttribType_CallableBelowMaturityValue) - | "CallableWithoutNotice" -> (Some FIX_InstrAttribType_CallableWithoutNotice) - | "Text" -> (Some FIX_InstrAttribType_Text) - | _ -> None - ) -;; - -let string_to_lastcapacity_opt (d) = - (match d with - | "Agent" -> (Some FIX_LastCapacity_Agent) - | "CrossAsAgent" -> (Some FIX_LastCapacity_CrossAsAgent) - | "CrossAsPrincipal" -> (Some FIX_LastCapacity_CrossAsPrincipal) - | "Principal" -> (Some FIX_LastCapacity_Principal) - | _ -> None - ) -;; - -let string_to_lastfragment_opt (d) = - (match d with - | "LastMessage" -> (Some FIX_LastFragment_LastMessage) - | "NotLastMessage" -> (Some FIX_LastFragment_NotLastMessage) - | _ -> None - ) -;; - -let string_to_lastliquidityind_opt (d) = - (match d with - | "AddedLiquidity" -> (Some FIX_LastLiquidityInd_AddedLiquidity) - | "RemovedLiquidity" -> (Some FIX_LastLiquidityInd_RemovedLiquidity) - | "LiquidityRoutedOut" -> (Some FIX_LastLiquidityInd_LiquidityRoutedOut) - | _ -> None - ) -;; - -let string_to_legswaptype_opt (d) = - (match d with - | "ParForPar" -> (Some FIX_LegSwapType_ParForPar) - | "ModifiedDuration" -> (Some FIX_LegSwapType_ModifiedDuration) - | "Risk" -> (Some FIX_LegSwapType_Risk) - | "Proceeds" -> (Some FIX_LegSwapType_Proceeds) - | _ -> None - ) -;; - -let string_to_legalconfirm_opt (d) = - (match d with - | "LegalConfirm" -> (Some FIX_LegalConfirm_LegalConfirm) - | "DoesNotConsituteALegalConfirm" -> (Some FIX_LegalConfirm_DoesNotConsituteALegalConfirm) - | _ -> None - ) -;; - -let string_to_liquidityindtype_opt (d) = - (match d with - | "FiveDayMovingAverage" -> (Some FIX_LiquidityIndType_FiveDayMovingAverage) - | "TwentyDayMovingAverage" -> (Some FIX_LiquidityIndType_TwentyDayMovingAverage) - | "NormalMarketSize" -> (Some FIX_LiquidityIndType_NormalMarketSize) - | "Other" -> (Some FIX_LiquidityIndType_Other) - | _ -> None - ) -;; - -let string_to_listexecinsttype_opt (d) = - (match d with - | "Immediate" -> (Some FIX_ListExecInstType_Immediate) - | "WaitForInstruction" -> (Some FIX_ListExecInstType_WaitForInstruction) - | "SellDriven" -> (Some FIX_ListExecInstType_SellDriven) - | "BuyDrivenCashTopUp" -> (Some FIX_ListExecInstType_BuyDrivenCashTopUp) - | "BuyDrivenCashWithdraw" -> (Some FIX_ListExecInstType_BuyDrivenCashWithdraw) - | _ -> None - ) -;; - -let string_to_listorderstatus_opt (d) = - (match d with - | "InBiddingProcess" -> (Some FIX_ListOrderStatus_InBiddingProcess) - | "ReceivedForExecution" -> (Some FIX_ListOrderStatus_ReceivedForExecution) - | "Executing" -> (Some FIX_ListOrderStatus_Executing) - | "Cancelling" -> (Some FIX_ListOrderStatus_Cancelling) - | "Alert" -> (Some FIX_ListOrderStatus_Alert) - | "AllDone" -> (Some FIX_ListOrderStatus_AllDone) - | "Reject" -> (Some FIX_ListOrderStatus_Reject) - | _ -> None - ) -;; - -let string_to_liststatustype_opt (d) = - (match d with - | "Ack" -> (Some FIX_ListStatusType_Ack) - | "Response" -> (Some FIX_ListStatusType_Response) - | "Timed" -> (Some FIX_ListStatusType_Timed) - | "ExecStarted" -> (Some FIX_ListStatusType_ExecStarted) - | "AllDone" -> (Some FIX_ListStatusType_AllDone) - | "Alert" -> (Some FIX_ListStatusType_Alert) - | _ -> None - ) -;; - -let string_to_locatereqd_opt (d) = - (match d with - | "Yes" -> (Some FIX_LocateReqd_Yes) - | "No" -> (Some FIX_LocateReqd_No) - | _ -> None - ) -;; - -let string_to_mdentrytype_opt (d) = - (match d with - | "Bid" -> (Some FIX_MDEntryType_Bid) - | "Offer" -> (Some FIX_MDEntryType_Offer) - | "Trade" -> (Some FIX_MDEntryType_Trade) - | "IndexValue" -> (Some FIX_MDEntryType_IndexValue) - | "OpeningPrice" -> (Some FIX_MDEntryType_OpeningPrice) - | "ClosingPrice" -> (Some FIX_MDEntryType_ClosingPrice) - | "SettlementPrice" -> (Some FIX_MDEntryType_SettlementPrice) - | "TradingSessionHighPrice" -> (Some FIX_MDEntryType_TradingSessionHighPrice) - | "TradingSessionLowPrice" -> (Some FIX_MDEntryType_TradingSessionLowPrice) - | "TradingSessionVWAPPrice" -> (Some FIX_MDEntryType_TradingSessionVWAPPrice) - | "Imbalance" -> (Some FIX_MDEntryType_Imbalance) - | "TradeVolume" -> (Some FIX_MDEntryType_TradeVolume) - | "OpenInterest" -> (Some FIX_MDEntryType_OpenInterest) - | _ -> None - ) -;; - -let string_to_mdimplicitdelete_opt (d) = - (match d with - | "Yes" -> (Some FIX_MDImplicitDelete_Yes) - | "No" -> (Some FIX_MDImplicitDelete_No) - | _ -> None - ) -;; - -let string_to_mdreqrejreason_opt (d) = - (match d with - | "UnknownSymbol" -> (Some FIX_MDReqRejReason_UnknownSymbol) - | "DuplicateMDReqID" -> (Some FIX_MDReqRejReason_DuplicateMDReqID) - | "InsufficientBandwidth" -> (Some FIX_MDReqRejReason_InsufficientBandwidth) - | "InsufficientPermissions" -> (Some FIX_MDReqRejReason_InsufficientPermissions) - | "UnsupportedSubscriptionRequestType" -> (Some FIX_MDReqRejReason_UnsupportedSubscriptionRequestType) - | "UnsupportedMarketDepth" -> (Some FIX_MDReqRejReason_UnsupportedMarketDepth) - | "UnsupportedMDUpdateType" -> (Some FIX_MDReqRejReason_UnsupportedMDUpdateType) - | "UnsupportedAggregatedBook" -> (Some FIX_MDReqRejReason_UnsupportedAggregatedBook) - | "UnsupportedMDEntryType" -> (Some FIX_MDReqRejReason_UnsupportedMDEntryType) - | "UnsupportedTradingSessionID" -> (Some FIX_MDReqRejReason_UnsupportedTradingSessionID) - | "UnsupportedScope" -> (Some FIX_MDReqRejReason_UnsupportedScope) - | "UnsupportedOpenCloseSettleFlag" -> (Some FIX_MDReqRejReason_UnsupportedOpenCloseSettleFlag) - | "UnsupportedMDImplicitDelete" -> (Some FIX_MDReqRejReason_UnsupportedMDImplicitDelete) - | _ -> None - ) -;; - -let string_to_mdupdateaction_opt (d) = - (match d with - | "New" -> (Some FIX_MDUpdateAction_New) - | "Change" -> (Some FIX_MDUpdateAction_Change) - | "Delete" -> (Some FIX_MDUpdateAction_Delete) - | _ -> None - ) -;; - -let string_to_mdupdatetype_opt (d) = - (match d with - | "FullRefresh" -> (Some FIX_MDUpdateType_FullRefresh) - | "IncrementalRefresh" -> (Some FIX_MDUpdateType_IncrementalRefresh) - | _ -> None - ) -;; - -let string_to_masscancelrejectreason_opt (d) = - (match d with - | "MassCancelNotSupported" -> (Some FIX_MassCancelRejectReason_MassCancelNotSupported) - | "InvalidOrUnknownSecurity" -> (Some FIX_MassCancelRejectReason_InvalidOrUnknownSecurity) - | "InvalidOrUnkownUnderlyingSecurity" -> (Some FIX_MassCancelRejectReason_InvalidOrUnkownUnderlyingSecurity) - | "InvalidOrUnknownProduct" -> (Some FIX_MassCancelRejectReason_InvalidOrUnknownProduct) - | "InvalidOrUnknownCFICode" -> (Some FIX_MassCancelRejectReason_InvalidOrUnknownCFICode) - | "InvalidOrUnknownSecurityType" -> (Some FIX_MassCancelRejectReason_InvalidOrUnknownSecurityType) - | "InvalidOrUnknownTradingSession" -> (Some FIX_MassCancelRejectReason_InvalidOrUnknownTradingSession) - | "Other" -> (Some FIX_MassCancelRejectReason_Other) - | _ -> None - ) -;; - -let string_to_masscancelrequesttype_opt (d) = - (match d with - | "CancelOrdersForASecurity" -> (Some FIX_MassCancelRequestType_CancelOrdersForASecurity) - | "CancelOrdersForAnUnderlyingSecurity" -> (Some FIX_MassCancelRequestType_CancelOrdersForAnUnderlyingSecurity) - | "CancelOrdersForAProduct" -> (Some FIX_MassCancelRequestType_CancelOrdersForAProduct) - | "CancelOrdersForACFICode" -> (Some FIX_MassCancelRequestType_CancelOrdersForACFICode) - | "CancelOrdersForASecurityType" -> (Some FIX_MassCancelRequestType_CancelOrdersForASecurityType) - | "CancelOrdersForATradingSession" -> (Some FIX_MassCancelRequestType_CancelOrdersForATradingSession) - | "CancelAllOrders" -> (Some FIX_MassCancelRequestType_CancelAllOrders) - | _ -> None - ) -;; - -let string_to_masscancelresponse_opt (d) = - (match d with - | "CancelRequestRejected" -> (Some FIX_MassCancelResponse_CancelRequestRejected) - | "CancelOrdersForASecurity" -> (Some FIX_MassCancelResponse_CancelOrdersForASecurity) - | "CancelOrdersForAnUnderlyingSecurity" -> (Some FIX_MassCancelResponse_CancelOrdersForAnUnderlyingSecurity) - | "CancelOrdersForAProduct" -> (Some FIX_MassCancelResponse_CancelOrdersForAProduct) - | "CancelOrdersForACFICode" -> (Some FIX_MassCancelResponse_CancelOrdersForACFICode) - | "CancelOrdersForASecurityType" -> (Some FIX_MassCancelResponse_CancelOrdersForASecurityType) - | "CancelOrdersForATradingSession" -> (Some FIX_MassCancelResponse_CancelOrdersForATradingSession) - | "CancelAllOrders" -> (Some FIX_MassCancelResponse_CancelAllOrders) - | _ -> None - ) -;; - -let string_to_massstatusreqtype_opt (d) = - (match d with - | "StatusForOrdersForASecurity" -> (Some FIX_MassStatusReqType_StatusForOrdersForASecurity) - | "StatusForOrdersForAnUnderlyingSecurity" -> (Some FIX_MassStatusReqType_StatusForOrdersForAnUnderlyingSecurity) - | "StatusForOrdersForAProduct" -> (Some FIX_MassStatusReqType_StatusForOrdersForAProduct) - | "StatusForOrdersForACFICode" -> (Some FIX_MassStatusReqType_StatusForOrdersForACFICode) - | "StatusForOrdersForASecurityType" -> (Some FIX_MassStatusReqType_StatusForOrdersForASecurityType) - | "StatusForOrdersForATradingSession" -> (Some FIX_MassStatusReqType_StatusForOrdersForATradingSession) - | "StatusForAllOrders" -> (Some FIX_MassStatusReqType_StatusForAllOrders) - | "StatusForOrdersForAPartyID" -> (Some FIX_MassStatusReqType_StatusForOrdersForAPartyID) - | _ -> None - ) -;; - -let string_to_matchstatus_opt (d) = - (match d with - | "Compared" -> (Some FIX_MatchStatus_Compared) - | "Uncompared" -> (Some FIX_MatchStatus_Uncompared) - | "AdvisoryOrAlert" -> (Some FIX_MatchStatus_AdvisoryOrAlert) - | _ -> None - ) -;; - -let string_to_matchtype_opt (d) = - (match d with - | "ExactMatchPlus4BadgesExecTime" -> (Some FIX_MatchType_ExactMatchPlus4BadgesExecTime) - | "ExactMatchPlus4Badges" -> (Some FIX_MatchType_ExactMatchPlus4Badges) - | "ExactMatchPlus2BadgesExecTime" -> (Some FIX_MatchType_ExactMatchPlus2BadgesExecTime) - | "ExactMatchPlus2Badges" -> (Some FIX_MatchType_ExactMatchPlus2Badges) - | "ExactMatchPlusExecTime" -> (Some FIX_MatchType_ExactMatchPlusExecTime) - | "StampedAdvisoriesOrSpecialistAccepts" -> (Some FIX_MatchType_StampedAdvisoriesOrSpecialistAccepts) - | "A1ExactMatchSummarizedQuantity" -> (Some FIX_MatchType_A1ExactMatchSummarizedQuantity) - | "A2ExactMatchSummarizedQuantity" -> (Some FIX_MatchType_A2ExactMatchSummarizedQuantity) - | "A3ExactMatchSummarizedQuantity" -> (Some FIX_MatchType_A3ExactMatchSummarizedQuantity) - | "A4ExactMatchSummarizedQuantity" -> (Some FIX_MatchType_A4ExactMatchSummarizedQuantity) - | "A5ExactMatchSummarizedQuantity" -> (Some FIX_MatchType_A5ExactMatchSummarizedQuantity) - | "ExactMatchMinusBadgesTimes" -> (Some FIX_MatchType_ExactMatchMinusBadgesTimes) - | "SummarizedMatchMinusBadgesTimes" -> (Some FIX_MatchType_SummarizedMatchMinusBadgesTimes) - | "OCSLockedIn" -> (Some FIX_MatchType_OCSLockedIn) - | "ACTAcceptedTrade" -> (Some FIX_MatchType_ACTAcceptedTrade) - | "ACTDefaultTrade" -> (Some FIX_MatchType_ACTDefaultTrade) - | "ACTDefaultAfterM2" -> (Some FIX_MatchType_ACTDefaultAfterM2) - | "ACTM6Match" -> (Some FIX_MatchType_ACTM6Match) - | _ -> None - ) -;; - -let string_to_messageencoding_opt (d) = - (match d with - | "ISO2022JP" -> (Some FIX_MessageEncoding_ISO2022JP) - | "EUCJP" -> (Some FIX_MessageEncoding_EUCJP) - | "ShiftJIS" -> (Some FIX_MessageEncoding_ShiftJIS) - | "UTF8" -> (Some FIX_MessageEncoding_UTF8) - | _ -> None - ) -;; - -let string_to_miscfeebasis_opt (d) = - (match d with - | "Absolute" -> (Some FIX_MiscFeeBasis_Absolute) - | "PerUnit" -> (Some FIX_MiscFeeBasis_PerUnit) - | "Percentage" -> (Some FIX_MiscFeeBasis_Percentage) - | _ -> None - ) -;; - -let string_to_miscfeetype_opt (d) = - (match d with - | "Regulatory" -> (Some FIX_MiscFeeType_Regulatory) - | "Tax" -> (Some FIX_MiscFeeType_Tax) - | "LocalCommission" -> (Some FIX_MiscFeeType_LocalCommission) - | "ExchangeFees" -> (Some FIX_MiscFeeType_ExchangeFees) - | "Stamp" -> (Some FIX_MiscFeeType_Stamp) - | "Levy" -> (Some FIX_MiscFeeType_Levy) - | "Other" -> (Some FIX_MiscFeeType_Other) - | "Markup" -> (Some FIX_MiscFeeType_Markup) - | "ConsumptionTax" -> (Some FIX_MiscFeeType_ConsumptionTax) - | "PerTransaction" -> (Some FIX_MiscFeeType_PerTransaction) - | "Conversion" -> (Some FIX_MiscFeeType_Conversion) - | "Agent" -> (Some FIX_MiscFeeType_Agent) - | _ -> None - ) -;; - -let string_to_moneylaunderingstatus_opt (d) = - (match d with - | "Passed" -> (Some FIX_MoneyLaunderingStatus_Passed) - | "NotChecked" -> (Some FIX_MoneyLaunderingStatus_NotChecked) - | "ExemptBelowLimit" -> (Some FIX_MoneyLaunderingStatus_ExemptBelowLimit) - | "ExemptMoneyType" -> (Some FIX_MoneyLaunderingStatus_ExemptMoneyType) - | "ExemptAuthorised" -> (Some FIX_MoneyLaunderingStatus_ExemptAuthorised) - | _ -> None - ) -;; - -let string_to_msgdirection_opt (d) = - (match d with - | "Send" -> (Some FIX_MsgDirection_Send) - | "Receive" -> (Some FIX_MsgDirection_Receive) - | _ -> None - ) -;; - -let string_to_multilegreportingtype_opt (d) = - (match d with - | "SingleSecurity" -> (Some FIX_MultiLegReportingType_SingleSecurity) - | "IndividualLegOfAMultiLegSecurity" -> (Some FIX_MultiLegReportingType_IndividualLegOfAMultiLegSecurity) - | "MultiLegSecurity" -> (Some FIX_MultiLegReportingType_MultiLegSecurity) - | _ -> None - ) -;; - -let string_to_multilegrpttypereq_opt (d) = - (match d with - | "ReportByMulitlegSecurityOnly" -> (Some FIX_MultiLegRptTypeReq_ReportByMulitlegSecurityOnly) - | "ReportByMultilegSecurityAndInstrumentLegs" -> (Some FIX_MultiLegRptTypeReq_ReportByMultilegSecurityAndInstrumentLegs) - | "ReportByInstrumentLegsOnly" -> (Some FIX_MultiLegRptTypeReq_ReportByInstrumentLegsOnly) - | _ -> None - ) -;; - -let string_to_netgrossind_opt (d) = - (match d with - | "Net" -> (Some FIX_NetGrossInd_Net) - | "Gross" -> (Some FIX_NetGrossInd_Gross) - | _ -> None - ) -;; - -let string_to_networkrequesttype_opt (d) = - (match d with - | "Snapshot" -> (Some FIX_NetworkRequestType_Snapshot) - | "Subscribe" -> (Some FIX_NetworkRequestType_Subscribe) - | "StopSubscribing" -> (Some FIX_NetworkRequestType_StopSubscribing) - | "LevelOfDetail" -> (Some FIX_NetworkRequestType_LevelOfDetail) - | _ -> None - ) -;; - -let string_to_networkstatusresponsetype_opt (d) = - (match d with - | "Full" -> (Some FIX_NetworkStatusResponseType_Full) - | "IncrementalUpdate" -> (Some FIX_NetworkStatusResponseType_IncrementalUpdate) - | _ -> None - ) -;; - -let string_to_notifybrokerofcredit_opt (d) = - (match d with - | "DetailsShouldBeCommunicated" -> (Some FIX_NotifyBrokerOfCredit_DetailsShouldBeCommunicated) - | "DetailsShouldNotBeCommunicated" -> (Some FIX_NotifyBrokerOfCredit_DetailsShouldNotBeCommunicated) - | _ -> None - ) -;; - -let string_to_oddlot_opt (d) = - (match d with - | "TreatAsOddLot" -> (Some FIX_OddLot_TreatAsOddLot) - | "TreatAsRoundLot" -> (Some FIX_OddLot_TreatAsRoundLot) - | _ -> None - ) -;; - -let string_to_openclosesettlflag_opt (d) = - (match d with - | "DailyOpen" -> (Some FIX_OpenCloseSettlFlag_DailyOpen) - | "SessionOpen" -> (Some FIX_OpenCloseSettlFlag_SessionOpen) - | "DeliverySettlementEntry" -> (Some FIX_OpenCloseSettlFlag_DeliverySettlementEntry) - | "ExpectedEntry" -> (Some FIX_OpenCloseSettlFlag_ExpectedEntry) - | "EntryFromPreviousBusinessDay" -> (Some FIX_OpenCloseSettlFlag_EntryFromPreviousBusinessDay) - | "TheoreticalPriceValue" -> (Some FIX_OpenCloseSettlFlag_TheoreticalPriceValue) - | _ -> None - ) -;; - -let string_to_ordrejreason_opt (d) = - (match d with - | "BrokerCredit" -> (Some FIX_OrdRejReason_BrokerCredit) - | "UnknownSymbol" -> (Some FIX_OrdRejReason_UnknownSymbol) - | "ExchangeClosed" -> (Some FIX_OrdRejReason_ExchangeClosed) - | "OrderExceedsLimit" -> (Some FIX_OrdRejReason_OrderExceedsLimit) - | "TooLateToEnter" -> (Some FIX_OrdRejReason_TooLateToEnter) - | "UnknownOrder" -> (Some FIX_OrdRejReason_UnknownOrder) - | "DuplicateOrder" -> (Some FIX_OrdRejReason_DuplicateOrder) - | "DuplicateOfAVerballyCommunicatedOrder" -> (Some FIX_OrdRejReason_DuplicateOfAVerballyCommunicatedOrder) - | "StaleOrder" -> (Some FIX_OrdRejReason_StaleOrder) - | "TradeAlongRequired" -> (Some FIX_OrdRejReason_TradeAlongRequired) - | "InvalidInvestorID" -> (Some FIX_OrdRejReason_InvalidInvestorID) - | "UnsupportedOrderCharacteristic" -> (Some FIX_OrdRejReason_UnsupportedOrderCharacteristic) - | "IncorrectQuantity" -> (Some FIX_OrdRejReason_IncorrectQuantity) - | "IncorrectAllocatedQuantity" -> (Some FIX_OrdRejReason_IncorrectAllocatedQuantity) - | "UnknownAccount" -> (Some FIX_OrdRejReason_UnknownAccount) - | "Other" -> (Some FIX_OrdRejReason_Other) - | _ -> None - ) -;; - -let string_to_ordstatus_opt (d) = - (match d with - | "New" -> (Some FIX_OrdStatus_New) - | "PartiallyFilled" -> (Some FIX_OrdStatus_PartiallyFilled) - | "Filled" -> (Some FIX_OrdStatus_Filled) - | "DoneForDay" -> (Some FIX_OrdStatus_DoneForDay) - | "Canceled" -> (Some FIX_OrdStatus_Canceled) - | "PendingCancel" -> (Some FIX_OrdStatus_PendingCancel) - | "Stopped" -> (Some FIX_OrdStatus_Stopped) - | "Rejected" -> (Some FIX_OrdStatus_Rejected) - | "Suspended" -> (Some FIX_OrdStatus_Suspended) - | "PendingNew" -> (Some FIX_OrdStatus_PendingNew) - | "Calculated" -> (Some FIX_OrdStatus_Calculated) - | "Expired" -> (Some FIX_OrdStatus_Expired) - | "AcceptedForBidding" -> (Some FIX_OrdStatus_AcceptedForBidding) - | "PendingReplace" -> (Some FIX_OrdStatus_PendingReplace) - | "Replaced" -> (Some FIX_OrdStatus_Replaced) - | _ -> None - ) -;; - -let string_to_ordtype_opt (d) = - (match d with - | "Market" -> (Some FIX_OrdType_Market) - | "Limit" -> (Some FIX_OrdType_Limit) - | "Stop" -> (Some FIX_OrdType_Stop) - | "StopLimit" -> (Some FIX_OrdType_StopLimit) - | "WithOrWithout" -> (Some FIX_OrdType_WithOrWithout) - | "LimitOrBetter" -> (Some FIX_OrdType_LimitOrBetter) - | "LimitWithOrWithout" -> (Some FIX_OrdType_LimitWithOrWithout) - | "OnBasis" -> (Some FIX_OrdType_OnBasis) - | "PreviouslyQuoted" -> (Some FIX_OrdType_PreviouslyQuoted) - | "PreviouslyIndicated" -> (Some FIX_OrdType_PreviouslyIndicated) - | "ForexSwap" -> (Some FIX_OrdType_ForexSwap) - | "Funari" -> (Some FIX_OrdType_Funari) - | "MarketIfTouched" -> (Some FIX_OrdType_MarketIfTouched) - | "MarketWithLeftOverAsLimit" -> (Some FIX_OrdType_MarketWithLeftOverAsLimit) - | "PreviousFundValuationPoint" -> (Some FIX_OrdType_PreviousFundValuationPoint) - | "NextFundValuationPoint" -> (Some FIX_OrdType_NextFundValuationPoint) - | "Pegged" -> (Some FIX_OrdType_Pegged) - | _ -> None - ) -;; - -let string_to_ordercapacity_opt (d) = - (match d with - | "Agency" -> (Some FIX_OrderCapacity_Agency) - | "Proprietary" -> (Some FIX_OrderCapacity_Proprietary) - | "Individual" -> (Some FIX_OrderCapacity_Individual) - | "Principal" -> (Some FIX_OrderCapacity_Principal) - | "RisklessPrincipal" -> (Some FIX_OrderCapacity_RisklessPrincipal) - | "AgentForOtherMember" -> (Some FIX_OrderCapacity_AgentForOtherMember) - | _ -> None - ) -;; - -let string_to_orderrestrictions_opt (d) = - (match d with - | "ProgramTrade" -> (Some FIX_OrderRestrictions_ProgramTrade) - | "IndexArbitrage" -> (Some FIX_OrderRestrictions_IndexArbitrage) - | "NonIndexArbitrage" -> (Some FIX_OrderRestrictions_NonIndexArbitrage) - | "CompetingMarketMaker" -> (Some FIX_OrderRestrictions_CompetingMarketMaker) - | "ActingAsMarketMakerOrSpecialistInSecurity" -> (Some FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInSecurity) - | "ActingAsMarketMakerOrSpecialistInUnderlying" -> (Some FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInUnderlying) - | "ForeignEntity" -> (Some FIX_OrderRestrictions_ForeignEntity) - | "ExternalMarketParticipant" -> (Some FIX_OrderRestrictions_ExternalMarketParticipant) - | "ExternalInterConnectedMarketLinkage" -> (Some FIX_OrderRestrictions_ExternalInterConnectedMarketLinkage) - | "RisklessArbitrage" -> (Some FIX_OrderRestrictions_RisklessArbitrage) - | _ -> None - ) -;; - -let string_to_ownertype_opt (d) = - (match d with - | "IndividualInvestor" -> (Some FIX_OwnerType_IndividualInvestor) - | "PublicCompany" -> (Some FIX_OwnerType_PublicCompany) - | "PrivateCompany" -> (Some FIX_OwnerType_PrivateCompany) - | "IndividualTrustee" -> (Some FIX_OwnerType_IndividualTrustee) - | "CompanyTrustee" -> (Some FIX_OwnerType_CompanyTrustee) - | "PensionPlan" -> (Some FIX_OwnerType_PensionPlan) - | "CustodianUnderGiftsToMinorsAct" -> (Some FIX_OwnerType_CustodianUnderGiftsToMinorsAct) - | "Trusts" -> (Some FIX_OwnerType_Trusts) - | "Fiduciaries" -> (Some FIX_OwnerType_Fiduciaries) - | "NetworkingSubAccount" -> (Some FIX_OwnerType_NetworkingSubAccount) - | "NonProfitOrganization" -> (Some FIX_OwnerType_NonProfitOrganization) - | "CorporateBody" -> (Some FIX_OwnerType_CorporateBody) - | "Nominee" -> (Some FIX_OwnerType_Nominee) - | _ -> None - ) -;; - -let string_to_ownershiptype_opt (d) = - (match d with - | "JointInvestors" -> (Some FIX_OwnershipType_JointInvestors) - | "TenantsInCommon" -> (Some FIX_OwnershipType_TenantsInCommon) - | "JointTrustees" -> (Some FIX_OwnershipType_JointTrustees) - | _ -> None - ) -;; - -let string_to_partyidsource_opt (d) = - (match d with - | "BIC" -> (Some FIX_PartyIDSource_BIC) - | "GeneralIdentifier" -> (Some FIX_PartyIDSource_GeneralIdentifier) - | "Proprietary" -> (Some FIX_PartyIDSource_Proprietary) - | "ISOCountryCode" -> (Some FIX_PartyIDSource_ISOCountryCode) - | "SettlementEntityLocation" -> (Some FIX_PartyIDSource_SettlementEntityLocation) - | "MIC" -> (Some FIX_PartyIDSource_MIC) - | "CSDParticipant" -> (Some FIX_PartyIDSource_CSDParticipant) - | "KoreanInvestorID" -> (Some FIX_PartyIDSource_KoreanInvestorID) - | "TaiwaneseForeignInvestorID" -> (Some FIX_PartyIDSource_TaiwaneseForeignInvestorID) - | "TaiwaneseTradingAcct" -> (Some FIX_PartyIDSource_TaiwaneseTradingAcct) - | "MalaysianCentralDepository" -> (Some FIX_PartyIDSource_MalaysianCentralDepository) - | "ChineseInvestorID" -> (Some FIX_PartyIDSource_ChineseInvestorID) - | "UKNationalInsuranceOrPensionNumber" -> (Some FIX_PartyIDSource_UKNationalInsuranceOrPensionNumber) - | "USSocialSecurityNumber" -> (Some FIX_PartyIDSource_USSocialSecurityNumber) - | "USEmployerOrTaxIDNumber" -> (Some FIX_PartyIDSource_USEmployerOrTaxIDNumber) - | "AustralianBusinessNumber" -> (Some FIX_PartyIDSource_AustralianBusinessNumber) - | "AustralianTaxFileNumber" -> (Some FIX_PartyIDSource_AustralianTaxFileNumber) - | "ISITCAcronym" -> (Some FIX_PartyIDSource_ISITCAcronym) - | _ -> None - ) -;; - -let string_to_partyrole_opt (d) = - (match d with - | "ExecutingFirm" -> (Some FIX_PartyRole_ExecutingFirm) - | "BrokerOfCredit" -> (Some FIX_PartyRole_BrokerOfCredit) - | "ClientID" -> (Some FIX_PartyRole_ClientID) - | "ClearingFirm" -> (Some FIX_PartyRole_ClearingFirm) - | "InvestorID" -> (Some FIX_PartyRole_InvestorID) - | "IntroducingFirm" -> (Some FIX_PartyRole_IntroducingFirm) - | "EnteringFirm" -> (Some FIX_PartyRole_EnteringFirm) - | "Locate" -> (Some FIX_PartyRole_Locate) - | "FundManagerClientID" -> (Some FIX_PartyRole_FundManagerClientID) - | "SettlementLocation" -> (Some FIX_PartyRole_SettlementLocation) - | "OrderOriginationTrader" -> (Some FIX_PartyRole_OrderOriginationTrader) - | "ExecutingTrader" -> (Some FIX_PartyRole_ExecutingTrader) - | "OrderOriginationFirm" -> (Some FIX_PartyRole_OrderOriginationFirm) - | "GiveupClearingFirm" -> (Some FIX_PartyRole_GiveupClearingFirm) - | "CorrespondantClearingFirm" -> (Some FIX_PartyRole_CorrespondantClearingFirm) - | "ExecutingSystem" -> (Some FIX_PartyRole_ExecutingSystem) - | "ContraFirm" -> (Some FIX_PartyRole_ContraFirm) - | "ContraClearingFirm" -> (Some FIX_PartyRole_ContraClearingFirm) - | "SponsoringFirm" -> (Some FIX_PartyRole_SponsoringFirm) - | "UnderlyingContraFirm" -> (Some FIX_PartyRole_UnderlyingContraFirm) - | "ClearingOrganization" -> (Some FIX_PartyRole_ClearingOrganization) - | "Exchange" -> (Some FIX_PartyRole_Exchange) - | "CustomerAccount" -> (Some FIX_PartyRole_CustomerAccount) - | "CorrespondentClearingOrganization" -> (Some FIX_PartyRole_CorrespondentClearingOrganization) - | "CorrespondentBroker" -> (Some FIX_PartyRole_CorrespondentBroker) - | "Buyer" -> (Some FIX_PartyRole_Buyer) - | "Custodian" -> (Some FIX_PartyRole_Custodian) - | "Intermediary" -> (Some FIX_PartyRole_Intermediary) - | "Agent" -> (Some FIX_PartyRole_Agent) - | "SubCustodian" -> (Some FIX_PartyRole_SubCustodian) - | "Beneficiary" -> (Some FIX_PartyRole_Beneficiary) - | "InterestedParty" -> (Some FIX_PartyRole_InterestedParty) - | "RegulatoryBody" -> (Some FIX_PartyRole_RegulatoryBody) - | "LiquidityProvider" -> (Some FIX_PartyRole_LiquidityProvider) - | "EnteringTrader" -> (Some FIX_PartyRole_EnteringTrader) - | "ContraTrader" -> (Some FIX_PartyRole_ContraTrader) - | "PositionAccount" -> (Some FIX_PartyRole_PositionAccount) - | _ -> None - ) -;; - -let string_to_partysubidtype_opt (d) = - (match d with - | "Firm" -> (Some FIX_PartySubIDType_Firm) - | "Person" -> (Some FIX_PartySubIDType_Person) - | "System" -> (Some FIX_PartySubIDType_System) - | "Application" -> (Some FIX_PartySubIDType_Application) - | "FullLegalNameOfFirm" -> (Some FIX_PartySubIDType_FullLegalNameOfFirm) - | "PostalAddress" -> (Some FIX_PartySubIDType_PostalAddress) - | "PhoneNumber" -> (Some FIX_PartySubIDType_PhoneNumber) - | "EmailAddress" -> (Some FIX_PartySubIDType_EmailAddress) - | "ContactName" -> (Some FIX_PartySubIDType_ContactName) - | "SecuritiesAccountNumber" -> (Some FIX_PartySubIDType_SecuritiesAccountNumber) - | "RegistrationNumber" -> (Some FIX_PartySubIDType_RegistrationNumber) - | "RegisteredAddressForConfirmation" -> (Some FIX_PartySubIDType_RegisteredAddressForConfirmation) - | "RegulatoryStatus" -> (Some FIX_PartySubIDType_RegulatoryStatus) - | "RegistrationName" -> (Some FIX_PartySubIDType_RegistrationName) - | "CashAccountNumber" -> (Some FIX_PartySubIDType_CashAccountNumber) - | "BIC" -> (Some FIX_PartySubIDType_BIC) - | "CSDParticipantMemberCode" -> (Some FIX_PartySubIDType_CSDParticipantMemberCode) - | "RegisteredAddress" -> (Some FIX_PartySubIDType_RegisteredAddress) - | "FundAccountName" -> (Some FIX_PartySubIDType_FundAccountName) - | "TelexNumber" -> (Some FIX_PartySubIDType_TelexNumber) - | "FaxNumber" -> (Some FIX_PartySubIDType_FaxNumber) - | "SecuritiesAccountName" -> (Some FIX_PartySubIDType_SecuritiesAccountName) - | "CashAccountName" -> (Some FIX_PartySubIDType_CashAccountName) - | "Department" -> (Some FIX_PartySubIDType_Department) - | "LocationDesk" -> (Some FIX_PartySubIDType_LocationDesk) - | "PositionAccountType" -> (Some FIX_PartySubIDType_PositionAccountType) - | _ -> None - ) -;; - -let string_to_paymentmethod_opt (d) = - (match d with - | "CREST" -> (Some FIX_PaymentMethod_CREST) - | "NSCC" -> (Some FIX_PaymentMethod_NSCC) - | "Euroclear" -> (Some FIX_PaymentMethod_Euroclear) - | "Clearstream" -> (Some FIX_PaymentMethod_Clearstream) - | "Cheque" -> (Some FIX_PaymentMethod_Cheque) - | "TelegraphicTransfer" -> (Some FIX_PaymentMethod_TelegraphicTransfer) - | "FedWire" -> (Some FIX_PaymentMethod_FedWire) - | "DebitCard" -> (Some FIX_PaymentMethod_DebitCard) - | "DirectDebit" -> (Some FIX_PaymentMethod_DirectDebit) - | "DirectCredit" -> (Some FIX_PaymentMethod_DirectCredit) - | "CreditCard" -> (Some FIX_PaymentMethod_CreditCard) - | "ACHDebit" -> (Some FIX_PaymentMethod_ACHDebit) - | "ACHCredit" -> (Some FIX_PaymentMethod_ACHCredit) - | "BPAY" -> (Some FIX_PaymentMethod_BPAY) - | "HighValueClearingSystem" -> (Some FIX_PaymentMethod_HighValueClearingSystem) - | _ -> None - ) -;; - -let string_to_peglimittype_opt (d) = - (match d with - | "OrBetter" -> (Some FIX_PegLimitType_OrBetter) - | "Strict" -> (Some FIX_PegLimitType_Strict) - | "OrWorse" -> (Some FIX_PegLimitType_OrWorse) - | _ -> None - ) -;; - -let string_to_pegmovetype_opt (d) = - (match d with - | "Floating" -> (Some FIX_PegMoveType_Floating) - | "Fixed" -> (Some FIX_PegMoveType_Fixed) - | _ -> None - ) -;; - -let string_to_pegoffsettype_opt (d) = - (match d with - | "Price" -> (Some FIX_PegOffsetType_Price) - | "BasisPoints" -> (Some FIX_PegOffsetType_BasisPoints) - | "Ticks" -> (Some FIX_PegOffsetType_Ticks) - | "PriceTier" -> (Some FIX_PegOffsetType_PriceTier) - | _ -> None - ) -;; - -let string_to_pegrounddirection_opt (d) = - (match d with - | "MoreAggressive" -> (Some FIX_PegRoundDirection_MoreAggressive) - | "MorePassive" -> (Some FIX_PegRoundDirection_MorePassive) - | _ -> None - ) -;; - -let string_to_pegscope_opt (d) = - (match d with - | "Local" -> (Some FIX_PegScope_Local) - | "National" -> (Some FIX_PegScope_National) - | "Global" -> (Some FIX_PegScope_Global) - | "NationalExcludingLocal" -> (Some FIX_PegScope_NationalExcludingLocal) - | _ -> None - ) -;; - -let string_to_posamttype_opt (d) = - (match d with - | "FinalMarkToMarketAmount" -> (Some FIX_PosAmtType_FinalMarkToMarketAmount) - | "IncrementalMarkToMarketAmount" -> (Some FIX_PosAmtType_IncrementalMarkToMarketAmount) - | "TradeVariationAmount" -> (Some FIX_PosAmtType_TradeVariationAmount) - | "StartOfDayMarkToMarketAmount" -> (Some FIX_PosAmtType_StartOfDayMarkToMarketAmount) - | "PremiumAmount" -> (Some FIX_PosAmtType_PremiumAmount) - | "CashResidualAmount" -> (Some FIX_PosAmtType_CashResidualAmount) - | "CashAmount" -> (Some FIX_PosAmtType_CashAmount) - | "ValueAdjustedAmount" -> (Some FIX_PosAmtType_ValueAdjustedAmount) - | _ -> None - ) -;; - -let string_to_posmaintaction_opt (d) = - (match d with - | "New" -> (Some FIX_PosMaintAction_New) - | "Replace" -> (Some FIX_PosMaintAction_Replace) - | "Cancel" -> (Some FIX_PosMaintAction_Cancel) - | _ -> None - ) -;; - -let string_to_posmaintresult_opt (d) = - (match d with - | "SuccessfulCompletion" -> (Some FIX_PosMaintResult_SuccessfulCompletion) - | "Rejected" -> (Some FIX_PosMaintResult_Rejected) - | "Other" -> (Some FIX_PosMaintResult_Other) - | _ -> None - ) -;; - -let string_to_posmaintstatus_opt (d) = - (match d with - | "Accepted" -> (Some FIX_PosMaintStatus_Accepted) - | "AcceptedWithWarnings" -> (Some FIX_PosMaintStatus_AcceptedWithWarnings) - | "Rejected" -> (Some FIX_PosMaintStatus_Rejected) - | "Completed" -> (Some FIX_PosMaintStatus_Completed) - | "CompletedWithWarnings" -> (Some FIX_PosMaintStatus_CompletedWithWarnings) - | _ -> None - ) -;; - -let string_to_posqtystatus_opt (d) = - (match d with - | "Submitted" -> (Some FIX_PosQtyStatus_Submitted) - | "Accepted" -> (Some FIX_PosQtyStatus_Accepted) - | "Rejected" -> (Some FIX_PosQtyStatus_Rejected) - | _ -> None - ) -;; - -let string_to_posreqresult_opt (d) = - (match d with - | "ValidRequest" -> (Some FIX_PosReqResult_ValidRequest) - | "InvalidOrUnsupportedRequest" -> (Some FIX_PosReqResult_InvalidOrUnsupportedRequest) - | "NoPositionsFoundThatMatchCriteria" -> (Some FIX_PosReqResult_NoPositionsFoundThatMatchCriteria) - | "NotAuthorizedToRequestPositions" -> (Some FIX_PosReqResult_NotAuthorizedToRequestPositions) - | "RequestForPositionNotSupported" -> (Some FIX_PosReqResult_RequestForPositionNotSupported) - | "Other" -> (Some FIX_PosReqResult_Other) - | _ -> None - ) -;; - -let string_to_posreqstatus_opt (d) = - (match d with - | "Completed" -> (Some FIX_PosReqStatus_Completed) - | "CompletedWithWarnings" -> (Some FIX_PosReqStatus_CompletedWithWarnings) - | "Rejected" -> (Some FIX_PosReqStatus_Rejected) - | _ -> None - ) -;; - -let string_to_posreqtype_opt (d) = - (match d with - | "Positions" -> (Some FIX_PosReqType_Positions) - | "Trades" -> (Some FIX_PosReqType_Trades) - | "Exercises" -> (Some FIX_PosReqType_Exercises) - | "Assignments" -> (Some FIX_PosReqType_Assignments) - | _ -> None - ) -;; - -let string_to_postranstype_opt (d) = - (match d with - | "Exercise" -> (Some FIX_PosTransType_Exercise) - | "DoNotExercise" -> (Some FIX_PosTransType_DoNotExercise) - | "PositionAdjustment" -> (Some FIX_PosTransType_PositionAdjustment) - | "PositionChangeSubmission" -> (Some FIX_PosTransType_PositionChangeSubmission) - | "Pledge" -> (Some FIX_PosTransType_Pledge) - | _ -> None - ) -;; - -let string_to_postype_opt (d) = - (match d with - | "TransactionQuantity" -> (Some FIX_PosType_TransactionQuantity) - | "IntraSpreadQty" -> (Some FIX_PosType_IntraSpreadQty) - | "InterSpreadQty" -> (Some FIX_PosType_InterSpreadQty) - | "EndOfDayQty" -> (Some FIX_PosType_EndOfDayQty) - | "StartOfDayQty" -> (Some FIX_PosType_StartOfDayQty) - | "OptionExerciseQty" -> (Some FIX_PosType_OptionExerciseQty) - | "OptionAssignment" -> (Some FIX_PosType_OptionAssignment) - | "TransactionFromExercise" -> (Some FIX_PosType_TransactionFromExercise) - | "TransactionFromAssignment" -> (Some FIX_PosType_TransactionFromAssignment) - | "PitTradeQty" -> (Some FIX_PosType_PitTradeQty) - | "TransferTradeQty" -> (Some FIX_PosType_TransferTradeQty) - | "ElectronicTradeQty" -> (Some FIX_PosType_ElectronicTradeQty) - | "AllocationTradeQty" -> (Some FIX_PosType_AllocationTradeQty) - | "AdjustmentQty" -> (Some FIX_PosType_AdjustmentQty) - | "AsOfTradeQty" -> (Some FIX_PosType_AsOfTradeQty) - | "DeliveryQty" -> (Some FIX_PosType_DeliveryQty) - | "TotalTransactionQty" -> (Some FIX_PosType_TotalTransactionQty) - | "CrossMarginQty" -> (Some FIX_PosType_CrossMarginQty) - | "IntegralSplit" -> (Some FIX_PosType_IntegralSplit) - | _ -> None - ) -;; - -let string_to_positioneffect_opt (d) = - (match d with - | "Open" -> (Some FIX_PositionEffect_Open) - | "Close" -> (Some FIX_PositionEffect_Close) - | "Rolled" -> (Some FIX_PositionEffect_Rolled) - | "FIFO" -> (Some FIX_PositionEffect_FIFO) - | _ -> None - ) -;; - -let string_to_possdupflag_opt (d) = - (match d with - | "PossibleDuplicate" -> (Some FIX_PossDupFlag_PossibleDuplicate) - | "OriginalTransmission" -> (Some FIX_PossDupFlag_OriginalTransmission) - | _ -> None - ) -;; - -let string_to_possresend_opt (d) = - (match d with - | "PossibleResend" -> (Some FIX_PossResend_PossibleResend) - | "OriginalTransmission" -> (Some FIX_PossResend_OriginalTransmission) - | _ -> None - ) -;; - -let string_to_preallocmethod_opt (d) = - (match d with - | "ProRata" -> (Some FIX_PreallocMethod_ProRata) - | "DoNotProRata" -> (Some FIX_PreallocMethod_DoNotProRata) - | _ -> None - ) -;; - -let string_to_previouslyreported_opt (d) = - (match d with - | "PerviouslyReportedToCounterparty" -> (Some FIX_PreviouslyReported_PerviouslyReportedToCounterparty) - | "NotReportedToCounterparty" -> (Some FIX_PreviouslyReported_NotReportedToCounterparty) - | _ -> None - ) -;; - -let string_to_pricetype_opt (d) = - (match d with - | "Percentage" -> (Some FIX_PriceType_Percentage) - | "PerUnit" -> (Some FIX_PriceType_PerUnit) - | "FixedAmount" -> (Some FIX_PriceType_FixedAmount) - | "Discount" -> (Some FIX_PriceType_Discount) - | "Premium" -> (Some FIX_PriceType_Premium) - | "Spread" -> (Some FIX_PriceType_Spread) - | "TEDPrice" -> (Some FIX_PriceType_TEDPrice) - | "TEDYield" -> (Some FIX_PriceType_TEDYield) - | "Yield" -> (Some FIX_PriceType_Yield) - | "FixedCabinetTradePrice" -> (Some FIX_PriceType_FixedCabinetTradePrice) - | "VariableCabinetTradePrice" -> (Some FIX_PriceType_VariableCabinetTradePrice) - | _ -> None - ) -;; - -let string_to_priorityindicator_opt (d) = - (match d with - | "PriorityUnchanged" -> (Some FIX_PriorityIndicator_PriorityUnchanged) - | "LostPriorityAsResultOfOrderChange" -> (Some FIX_PriorityIndicator_LostPriorityAsResultOfOrderChange) - | _ -> None - ) -;; - -let string_to_processcode_opt (d) = - (match d with - | "Regular" -> (Some FIX_ProcessCode_Regular) - | "SoftDollar" -> (Some FIX_ProcessCode_SoftDollar) - | "StepIn" -> (Some FIX_ProcessCode_StepIn) - | "StepOut" -> (Some FIX_ProcessCode_StepOut) - | "SoftDollarStepIn" -> (Some FIX_ProcessCode_SoftDollarStepIn) - | "SoftDollarStepOut" -> (Some FIX_ProcessCode_SoftDollarStepOut) - | "PlanSponsor" -> (Some FIX_ProcessCode_PlanSponsor) - | _ -> None - ) -;; - -let string_to_product_opt (d) = - (match d with - | "AGENCY" -> (Some FIX_Product_AGENCY) - | "COMMODITY" -> (Some FIX_Product_COMMODITY) - | "CORPORATE" -> (Some FIX_Product_CORPORATE) - | "CURRENCY" -> (Some FIX_Product_CURRENCY) - | "EQUITY" -> (Some FIX_Product_EQUITY) - | "GOVERNMENT" -> (Some FIX_Product_GOVERNMENT) - | "INDEX" -> (Some FIX_Product_INDEX) - | "LOAN" -> (Some FIX_Product_LOAN) - | "MONEYMARKET" -> (Some FIX_Product_MONEYMARKET) - | "MORTGAGE" -> (Some FIX_Product_MORTGAGE) - | "MUNICIPAL" -> (Some FIX_Product_MUNICIPAL) - | "OTHER" -> (Some FIX_Product_OTHER) - | "FINANCING" -> (Some FIX_Product_FINANCING) - | _ -> None - ) -;; - -let string_to_progrptreqs_opt (d) = - (match d with - | "BuySideRequests" -> (Some FIX_ProgRptReqs_BuySideRequests) - | "SellSideSends" -> (Some FIX_ProgRptReqs_SellSideSends) - | "RealTimeExecutionReports" -> (Some FIX_ProgRptReqs_RealTimeExecutionReports) - | _ -> None - ) -;; - -let string_to_publishtrdindicator_opt (d) = - (match d with - | "ReportTrade" -> (Some FIX_PublishTrdIndicator_ReportTrade) - | "DoNotReportTrade" -> (Some FIX_PublishTrdIndicator_DoNotReportTrade) - | _ -> None - ) -;; - -let string_to_putorcall_opt (d) = - (match d with - | "Put" -> (Some FIX_PutOrCall_Put) - | "Call" -> (Some FIX_PutOrCall_Call) - | _ -> None - ) -;; - -let string_to_qtytype_opt (d) = - (match d with - | "Units" -> (Some FIX_QtyType_Units) - | "Contracts" -> (Some FIX_QtyType_Contracts) - | _ -> None - ) -;; - -let string_to_quotecanceltype_opt (d) = - (match d with - | "CancelForOneOrMoreSecurities" -> (Some FIX_QuoteCancelType_CancelForOneOrMoreSecurities) - | "CancelForSecurityType" -> (Some FIX_QuoteCancelType_CancelForSecurityType) - | "CancelForUnderlyingSecurity" -> (Some FIX_QuoteCancelType_CancelForUnderlyingSecurity) - | "CancelAllQuotes" -> (Some FIX_QuoteCancelType_CancelAllQuotes) - | _ -> None - ) -;; - -let string_to_quotecondition_opt (d) = - (match d with - | "Open" -> (Some FIX_QuoteCondition_Open) - | "Closed" -> (Some FIX_QuoteCondition_Closed) - | "ExchangeBest" -> (Some FIX_QuoteCondition_ExchangeBest) - | "ConsolidatedBest" -> (Some FIX_QuoteCondition_ConsolidatedBest) - | "Locked" -> (Some FIX_QuoteCondition_Locked) - | "Crossed" -> (Some FIX_QuoteCondition_Crossed) - | "Depth" -> (Some FIX_QuoteCondition_Depth) - | "FastTrading" -> (Some FIX_QuoteCondition_FastTrading) - | "NonFirm" -> (Some FIX_QuoteCondition_NonFirm) - | _ -> None - ) -;; - -let string_to_quotepricetype_opt (d) = - (match d with - | "Percent" -> (Some FIX_QuotePriceType_Percent) - | "PerShare" -> (Some FIX_QuotePriceType_PerShare) - | "FixedAmount" -> (Some FIX_QuotePriceType_FixedAmount) - | "Discount" -> (Some FIX_QuotePriceType_Discount) - | "Premium" -> (Some FIX_QuotePriceType_Premium) - | "Spread" -> (Some FIX_QuotePriceType_Spread) - | "TEDPrice" -> (Some FIX_QuotePriceType_TEDPrice) - | "TEDYield" -> (Some FIX_QuotePriceType_TEDYield) - | "YieldSpread" -> (Some FIX_QuotePriceType_YieldSpread) - | "Yield" -> (Some FIX_QuotePriceType_Yield) - | _ -> None - ) -;; - -let string_to_quoterejectreason_opt (d) = - (match d with - | "UnknownSymbol" -> (Some FIX_QuoteRejectReason_UnknownSymbol) - | "Exchange" -> (Some FIX_QuoteRejectReason_Exchange) - | "QuoteRequestExceedsLimit" -> (Some FIX_QuoteRejectReason_QuoteRequestExceedsLimit) - | "TooLateToEnter" -> (Some FIX_QuoteRejectReason_TooLateToEnter) - | "UnknownQuote" -> (Some FIX_QuoteRejectReason_UnknownQuote) - | "DuplicateQuote" -> (Some FIX_QuoteRejectReason_DuplicateQuote) - | "InvalidBid" -> (Some FIX_QuoteRejectReason_InvalidBid) - | "InvalidPrice" -> (Some FIX_QuoteRejectReason_InvalidPrice) - | "NotAuthorizedToQuoteSecurity" -> (Some FIX_QuoteRejectReason_NotAuthorizedToQuoteSecurity) - | "Other" -> (Some FIX_QuoteRejectReason_Other) - | _ -> None - ) -;; - -let string_to_quoterequestrejectreason_opt (d) = - (match d with - | "UnknownSymbol" -> (Some FIX_QuoteRequestRejectReason_UnknownSymbol) - | "Exchange" -> (Some FIX_QuoteRequestRejectReason_Exchange) - | "QuoteRequestExceedsLimit" -> (Some FIX_QuoteRequestRejectReason_QuoteRequestExceedsLimit) - | "TooLateToEnter" -> (Some FIX_QuoteRequestRejectReason_TooLateToEnter) - | "InvalidPrice" -> (Some FIX_QuoteRequestRejectReason_InvalidPrice) - | "NotAuthorizedToRequestQuote" -> (Some FIX_QuoteRequestRejectReason_NotAuthorizedToRequestQuote) - | "NoMatchForInquiry" -> (Some FIX_QuoteRequestRejectReason_NoMatchForInquiry) - | "NoMarketForInstrument" -> (Some FIX_QuoteRequestRejectReason_NoMarketForInstrument) - | "NoInventory" -> (Some FIX_QuoteRequestRejectReason_NoInventory) - | "Pass" -> (Some FIX_QuoteRequestRejectReason_Pass) - | "Other" -> (Some FIX_QuoteRequestRejectReason_Other) - | _ -> None - ) -;; - -let string_to_quoterequesttype_opt (d) = - (match d with - | "Manual" -> (Some FIX_QuoteRequestType_Manual) - | "Automatic" -> (Some FIX_QuoteRequestType_Automatic) - | _ -> None - ) -;; - -let string_to_quoteresptype_opt (d) = - (match d with - | "Hit" -> (Some FIX_QuoteRespType_Hit) - | "Counter" -> (Some FIX_QuoteRespType_Counter) - | "Expired" -> (Some FIX_QuoteRespType_Expired) - | "Cover" -> (Some FIX_QuoteRespType_Cover) - | "DoneAway" -> (Some FIX_QuoteRespType_DoneAway) - | "Pass" -> (Some FIX_QuoteRespType_Pass) - | _ -> None - ) -;; - -let string_to_quoteresponselevel_opt (d) = - (match d with - | "NoAcknowledgement" -> (Some FIX_QuoteResponseLevel_NoAcknowledgement) - | "AcknowledgeOnlyNegativeOrErroneousQuotes" -> (Some FIX_QuoteResponseLevel_AcknowledgeOnlyNegativeOrErroneousQuotes) - | "AcknowledgeEachQuoteMessage" -> (Some FIX_QuoteResponseLevel_AcknowledgeEachQuoteMessage) - | _ -> None - ) -;; - -let string_to_quotestatus_opt (d) = - (match d with - | "Accepted" -> (Some FIX_QuoteStatus_Accepted) - | "CancelForSymbol" -> (Some FIX_QuoteStatus_CancelForSymbol) - | "CanceledForSecurityType" -> (Some FIX_QuoteStatus_CanceledForSecurityType) - | "CanceledForUnderlying" -> (Some FIX_QuoteStatus_CanceledForUnderlying) - | "CanceledAll" -> (Some FIX_QuoteStatus_CanceledAll) - | "Rejected" -> (Some FIX_QuoteStatus_Rejected) - | "RemovedFromMarket" -> (Some FIX_QuoteStatus_RemovedFromMarket) - | "Expired" -> (Some FIX_QuoteStatus_Expired) - | "Query" -> (Some FIX_QuoteStatus_Query) - | "QuoteNotFound" -> (Some FIX_QuoteStatus_QuoteNotFound) - | "Pending" -> (Some FIX_QuoteStatus_Pending) - | "Pass" -> (Some FIX_QuoteStatus_Pass) - | "LockedMarketWarning" -> (Some FIX_QuoteStatus_LockedMarketWarning) - | "CrossMarketWarning" -> (Some FIX_QuoteStatus_CrossMarketWarning) - | "CanceledDueToLockMarket" -> (Some FIX_QuoteStatus_CanceledDueToLockMarket) - | "CanceledDueToCrossMarket" -> (Some FIX_QuoteStatus_CanceledDueToCrossMarket) - | _ -> None - ) -;; - -let string_to_quotetype_opt (d) = - (match d with - | "Indicative" -> (Some FIX_QuoteType_Indicative) - | "Tradeable" -> (Some FIX_QuoteType_Tradeable) - | "RestrictedTradeable" -> (Some FIX_QuoteType_RestrictedTradeable) - | "Counter" -> (Some FIX_QuoteType_Counter) - | _ -> None - ) -;; - -let string_to_registrejreasoncode_opt (d) = - (match d with - | "InvalidAccountType" -> (Some FIX_RegistRejReasonCode_InvalidAccountType) - | "InvalidTaxExemptType" -> (Some FIX_RegistRejReasonCode_InvalidTaxExemptType) - | "InvalidOwnershipType" -> (Some FIX_RegistRejReasonCode_InvalidOwnershipType) - | "NoRegDetails" -> (Some FIX_RegistRejReasonCode_NoRegDetails) - | "InvalidRegSeqNo" -> (Some FIX_RegistRejReasonCode_InvalidRegSeqNo) - | "InvalidRegDetails" -> (Some FIX_RegistRejReasonCode_InvalidRegDetails) - | "InvalidMailingDetails" -> (Some FIX_RegistRejReasonCode_InvalidMailingDetails) - | "InvalidMailingInstructions" -> (Some FIX_RegistRejReasonCode_InvalidMailingInstructions) - | "InvalidInvestorID" -> (Some FIX_RegistRejReasonCode_InvalidInvestorID) - | "InvalidInvestorIDSource" -> (Some FIX_RegistRejReasonCode_InvalidInvestorIDSource) - | "InvalidDateOfBirth" -> (Some FIX_RegistRejReasonCode_InvalidDateOfBirth) - | "InvalidCountry" -> (Some FIX_RegistRejReasonCode_InvalidCountry) - | "InvalidDistribInstns" -> (Some FIX_RegistRejReasonCode_InvalidDistribInstns) - | "InvalidPercentage" -> (Some FIX_RegistRejReasonCode_InvalidPercentage) - | "InvalidPaymentMethod" -> (Some FIX_RegistRejReasonCode_InvalidPaymentMethod) - | "InvalidAccountName" -> (Some FIX_RegistRejReasonCode_InvalidAccountName) - | "InvalidAgentCode" -> (Some FIX_RegistRejReasonCode_InvalidAgentCode) - | "InvalidAccountNum" -> (Some FIX_RegistRejReasonCode_InvalidAccountNum) - | "Other" -> (Some FIX_RegistRejReasonCode_Other) - | _ -> None - ) -;; - -let string_to_registstatus_opt (d) = - (match d with - | "Accepted" -> (Some FIX_RegistStatus_Accepted) - | "Rejected" -> (Some FIX_RegistStatus_Rejected) - | "Held" -> (Some FIX_RegistStatus_Held) - | "Reminder" -> (Some FIX_RegistStatus_Reminder) - | _ -> None - ) -;; - -let string_to_registtranstype_opt (d) = - (match d with - | "New" -> (Some FIX_RegistTransType_New) - | "Replace" -> (Some FIX_RegistTransType_Replace) - | "Cancel" -> (Some FIX_RegistTransType_Cancel) - | _ -> None - ) -;; - -let string_to_reporttoexch_opt (d) = - (match d with - | "ReceiverReports" -> (Some FIX_ReportToExch_ReceiverReports) - | "SenderReports" -> (Some FIX_ReportToExch_SenderReports) - | _ -> None - ) -;; - -let string_to_resetseqnumflag_opt (d) = - (match d with - | "Yes" -> (Some FIX_ResetSeqNumFlag_Yes) - | "No" -> (Some FIX_ResetSeqNumFlag_No) - | _ -> None - ) -;; - -let string_to_responsetransporttype_opt (d) = - (match d with - | "Inband" -> (Some FIX_ResponseTransportType_Inband) - | "OutOfBand" -> (Some FIX_ResponseTransportType_OutOfBand) - | _ -> None - ) -;; - -let string_to_roundingdirection_opt (d) = - (match d with - | "RoundToNearest" -> (Some FIX_RoundingDirection_RoundToNearest) - | "RoundDown" -> (Some FIX_RoundingDirection_RoundDown) - | "RoundUp" -> (Some FIX_RoundingDirection_RoundUp) - | _ -> None - ) -;; - -let string_to_routingtype_opt (d) = - (match d with - | "TargetFirm" -> (Some FIX_RoutingType_TargetFirm) - | "TargetList" -> (Some FIX_RoutingType_TargetList) - | "BlockFirm" -> (Some FIX_RoutingType_BlockFirm) - | "BlockList" -> (Some FIX_RoutingType_BlockList) - | _ -> None - ) -;; - -let string_to_scope_opt (d) = - (match d with - | "LocalMarket" -> (Some FIX_Scope_LocalMarket) - | "National" -> (Some FIX_Scope_National) - | "Global" -> (Some FIX_Scope_Global) - | _ -> None - ) -;; - -let string_to_securityidsource_opt (d) = - (match d with - | "CUSIP" -> (Some FIX_SecurityIDSource_CUSIP) - | "SEDOL" -> (Some FIX_SecurityIDSource_SEDOL) - | "QUIK" -> (Some FIX_SecurityIDSource_QUIK) - | "ISINNumber" -> (Some FIX_SecurityIDSource_ISINNumber) - | "RICCode" -> (Some FIX_SecurityIDSource_RICCode) - | "ISOCurrencyCode" -> (Some FIX_SecurityIDSource_ISOCurrencyCode) - | "ISOCountryCode" -> (Some FIX_SecurityIDSource_ISOCountryCode) - | "ExchangeSymbol" -> (Some FIX_SecurityIDSource_ExchangeSymbol) - | "ConsolidatedTapeAssociation" -> (Some FIX_SecurityIDSource_ConsolidatedTapeAssociation) - | "BloombergSymbol" -> (Some FIX_SecurityIDSource_BloombergSymbol) - | "Wertpapier" -> (Some FIX_SecurityIDSource_Wertpapier) - | "Dutch" -> (Some FIX_SecurityIDSource_Dutch) - | "Valoren" -> (Some FIX_SecurityIDSource_Valoren) - | "Sicovam" -> (Some FIX_SecurityIDSource_Sicovam) - | "Belgian" -> (Some FIX_SecurityIDSource_Belgian) - | "Common" -> (Some FIX_SecurityIDSource_Common) - | "ClearingHouse" -> (Some FIX_SecurityIDSource_ClearingHouse) - | "ISDAFpMLSpecification" -> (Some FIX_SecurityIDSource_ISDAFpMLSpecification) - | "OptionPriceReportingAuthority" -> (Some FIX_SecurityIDSource_OptionPriceReportingAuthority) - | _ -> None - ) -;; - -let string_to_securitylistrequesttype_opt (d) = - (match d with - | "Symbol" -> (Some FIX_SecurityListRequestType_Symbol) - | "SecurityTypeAnd" -> (Some FIX_SecurityListRequestType_SecurityTypeAnd) - | "Product" -> (Some FIX_SecurityListRequestType_Product) - | "TradingSessionID" -> (Some FIX_SecurityListRequestType_TradingSessionID) - | "AllSecurities" -> (Some FIX_SecurityListRequestType_AllSecurities) - | _ -> None - ) -;; - -let string_to_securityrequestresult_opt (d) = - (match d with - | "ValidRequest" -> (Some FIX_SecurityRequestResult_ValidRequest) - | "InvalidOrUnsupportedRequest" -> (Some FIX_SecurityRequestResult_InvalidOrUnsupportedRequest) - | "NoInstrumentsFound" -> (Some FIX_SecurityRequestResult_NoInstrumentsFound) - | "NotAuthorizedToRetrieveInstrumentData" -> (Some FIX_SecurityRequestResult_NotAuthorizedToRetrieveInstrumentData) - | "InstrumentDataTemporarilyUnavailable" -> (Some FIX_SecurityRequestResult_InstrumentDataTemporarilyUnavailable) - | "RequestForInstrumentDataNotSupported" -> (Some FIX_SecurityRequestResult_RequestForInstrumentDataNotSupported) - | _ -> None - ) -;; - -let string_to_securityrequesttype_opt (d) = - (match d with - | "RequestSecurityIdentityAndSpecifications" -> (Some FIX_SecurityRequestType_RequestSecurityIdentityAndSpecifications) - | "RequestSecurityIdentityForSpecifications" -> (Some FIX_SecurityRequestType_RequestSecurityIdentityForSpecifications) - | "RequestListSecurityTypes" -> (Some FIX_SecurityRequestType_RequestListSecurityTypes) - | "RequestListSecurities" -> (Some FIX_SecurityRequestType_RequestListSecurities) - | _ -> None - ) -;; - -let string_to_securityresponsetype_opt (d) = - (match d with - | "AcceptAsIs" -> (Some FIX_SecurityResponseType_AcceptAsIs) - | "AcceptWithRevisions" -> (Some FIX_SecurityResponseType_AcceptWithRevisions) - | "RejectSecurityProposal" -> (Some FIX_SecurityResponseType_RejectSecurityProposal) - | "CannotMatchSelectionCriteria" -> (Some FIX_SecurityResponseType_CannotMatchSelectionCriteria) - | _ -> None - ) -;; - -let string_to_securitytradingstatus_opt (d) = - (match d with - | "OpeningDelay" -> (Some FIX_SecurityTradingStatus_OpeningDelay) - | "TradingHalt" -> (Some FIX_SecurityTradingStatus_TradingHalt) - | "Resume" -> (Some FIX_SecurityTradingStatus_Resume) - | "NoOpen" -> (Some FIX_SecurityTradingStatus_NoOpen) - | "PriceIndication" -> (Some FIX_SecurityTradingStatus_PriceIndication) - | "TradingRangeIndication" -> (Some FIX_SecurityTradingStatus_TradingRangeIndication) - | "MarketImbalanceBuy" -> (Some FIX_SecurityTradingStatus_MarketImbalanceBuy) - | "MarketImbalanceSell" -> (Some FIX_SecurityTradingStatus_MarketImbalanceSell) - | "MarketOnCloseImbalanceBuy" -> (Some FIX_SecurityTradingStatus_MarketOnCloseImbalanceBuy) - | "MarketOnCloseImbalanceSell" -> (Some FIX_SecurityTradingStatus_MarketOnCloseImbalanceSell) - | "NoMarketImbalance" -> (Some FIX_SecurityTradingStatus_NoMarketImbalance) - | "NoMarketOnCloseImbalance" -> (Some FIX_SecurityTradingStatus_NoMarketOnCloseImbalance) - | "ITSPreOpening" -> (Some FIX_SecurityTradingStatus_ITSPreOpening) - | "NewPriceIndication" -> (Some FIX_SecurityTradingStatus_NewPriceIndication) - | "TradeDisseminationTime" -> (Some FIX_SecurityTradingStatus_TradeDisseminationTime) - | "ReadyToTrade" -> (Some FIX_SecurityTradingStatus_ReadyToTrade) - | "NotAvailableForTrading" -> (Some FIX_SecurityTradingStatus_NotAvailableForTrading) - | "NotTradedOnThisMarket" -> (Some FIX_SecurityTradingStatus_NotTradedOnThisMarket) - | "UnknownOrInvalid" -> (Some FIX_SecurityTradingStatus_UnknownOrInvalid) - | "PreOpen" -> (Some FIX_SecurityTradingStatus_PreOpen) - | "OpeningRotation" -> (Some FIX_SecurityTradingStatus_OpeningRotation) - | "FastMarket" -> (Some FIX_SecurityTradingStatus_FastMarket) - | _ -> None - ) -;; - -let string_to_securitytype_opt (d) = - (match d with - | "Future" -> (Some FIX_SecurityType_Future) - | "Option" -> (Some FIX_SecurityType_Option) - | "EuroSupranationalCoupons" -> (Some FIX_SecurityType_EuroSupranationalCoupons) - | "FederalAgencyCoupon" -> (Some FIX_SecurityType_FederalAgencyCoupon) - | "FederalAgencyDiscountNote" -> (Some FIX_SecurityType_FederalAgencyDiscountNote) - | "PrivateExportFunding" -> (Some FIX_SecurityType_PrivateExportFunding) - | "USDSupranationalCoupons" -> (Some FIX_SecurityType_USDSupranationalCoupons) - | "CorporateBond" -> (Some FIX_SecurityType_CorporateBond) - | "CorporatePrivatePlacement" -> (Some FIX_SecurityType_CorporatePrivatePlacement) - | "ConvertibleBond" -> (Some FIX_SecurityType_ConvertibleBond) - | "DualCurrency" -> (Some FIX_SecurityType_DualCurrency) - | "EuroCorporateBond" -> (Some FIX_SecurityType_EuroCorporateBond) - | "IndexedLinked" -> (Some FIX_SecurityType_IndexedLinked) - | "StructuredNotes" -> (Some FIX_SecurityType_StructuredNotes) - | "YankeeCorporateBond" -> (Some FIX_SecurityType_YankeeCorporateBond) - | "ForeignExchangeContract" -> (Some FIX_SecurityType_ForeignExchangeContract) - | "CommonStock" -> (Some FIX_SecurityType_CommonStock) - | "PreferredStock" -> (Some FIX_SecurityType_PreferredStock) - | "BradyBond" -> (Some FIX_SecurityType_BradyBond) - | "EuroSovereigns" -> (Some FIX_SecurityType_EuroSovereigns) - | "USTreasuryBond" -> (Some FIX_SecurityType_USTreasuryBond) - | "InterestStripFromAnyBondOrNote" -> (Some FIX_SecurityType_InterestStripFromAnyBondOrNote) - | "TreasuryInflationProtectedSecurities" -> (Some FIX_SecurityType_TreasuryInflationProtectedSecurities) - | "PrincipalStripOfACallableBondOrNote" -> (Some FIX_SecurityType_PrincipalStripOfACallableBondOrNote) - | "PrincipalStripFromANonCallableBondOrNote" -> (Some FIX_SecurityType_PrincipalStripFromANonCallableBondOrNote) - | "USTreasuryNoteOld" -> (Some FIX_SecurityType_USTreasuryNoteOld) - | "USTreasuryBillOld" -> (Some FIX_SecurityType_USTreasuryBillOld) - | "USTreasuryNote" -> (Some FIX_SecurityType_USTreasuryNote) - | "USTreasuryBill" -> (Some FIX_SecurityType_USTreasuryBill) - | "Repurchase" -> (Some FIX_SecurityType_Repurchase) - | "Forward" -> (Some FIX_SecurityType_Forward) - | "BuySellback" -> (Some FIX_SecurityType_BuySellback) - | "SecuritiesLoan" -> (Some FIX_SecurityType_SecuritiesLoan) - | "SecuritiesPledge" -> (Some FIX_SecurityType_SecuritiesPledge) - | "TermLoan" -> (Some FIX_SecurityType_TermLoan) - | "RevolverLoan" -> (Some FIX_SecurityType_RevolverLoan) - | "Revolver" -> (Some FIX_SecurityType_Revolver) - | "BridgeLoan" -> (Some FIX_SecurityType_BridgeLoan) - | "LetterOfCredit" -> (Some FIX_SecurityType_LetterOfCredit) - | "SwingLineFacility" -> (Some FIX_SecurityType_SwingLineFacility) - | "DebtorInPossession" -> (Some FIX_SecurityType_DebtorInPossession) - | "Defaulted" -> (Some FIX_SecurityType_Defaulted) - | "Withdrawn" -> (Some FIX_SecurityType_Withdrawn) - | "Replaced" -> (Some FIX_SecurityType_Replaced) - | "Matured" -> (Some FIX_SecurityType_Matured) - | "Amended" -> (Some FIX_SecurityType_Amended) - | "Retired" -> (Some FIX_SecurityType_Retired) - | "BankersAcceptance" -> (Some FIX_SecurityType_BankersAcceptance) - | "BankNotes" -> (Some FIX_SecurityType_BankNotes) - | "BillOfExchanges" -> (Some FIX_SecurityType_BillOfExchanges) - | "CertificateOfDeposit" -> (Some FIX_SecurityType_CertificateOfDeposit) - | "CallLoans" -> (Some FIX_SecurityType_CallLoans) - | "CommercialPaper" -> (Some FIX_SecurityType_CommercialPaper) - | "DepositNotes" -> (Some FIX_SecurityType_DepositNotes) - | "EuroCertificateOfDeposit" -> (Some FIX_SecurityType_EuroCertificateOfDeposit) - | "EuroCommercialPaper" -> (Some FIX_SecurityType_EuroCommercialPaper) - | "LiquidityNote" -> (Some FIX_SecurityType_LiquidityNote) - | "MediumTermNotes" -> (Some FIX_SecurityType_MediumTermNotes) - | "Overnight" -> (Some FIX_SecurityType_Overnight) - | "PromissoryNote" -> (Some FIX_SecurityType_PromissoryNote) - | "PlazosFijos" -> (Some FIX_SecurityType_PlazosFijos) - | "ShortTermLoanNote" -> (Some FIX_SecurityType_ShortTermLoanNote) - | "TimeDeposit" -> (Some FIX_SecurityType_TimeDeposit) - | "ExtendedCommNote" -> (Some FIX_SecurityType_ExtendedCommNote) - | "YankeeCertificateOfDeposit" -> (Some FIX_SecurityType_YankeeCertificateOfDeposit) - | "AssetBackedSecurities" -> (Some FIX_SecurityType_AssetBackedSecurities) - | "Corp" -> (Some FIX_SecurityType_Corp) - | "CollateralizedMortgageObligation" -> (Some FIX_SecurityType_CollateralizedMortgageObligation) - | "IOETTEMortgage" -> (Some FIX_SecurityType_IOETTEMortgage) - | "MortgageBackedSecurities" -> (Some FIX_SecurityType_MortgageBackedSecurities) - | "MortgageInterestOnly" -> (Some FIX_SecurityType_MortgageInterestOnly) - | "MortgagePrincipalOnly" -> (Some FIX_SecurityType_MortgagePrincipalOnly) - | "MortgagePrivatePlacement" -> (Some FIX_SecurityType_MortgagePrivatePlacement) - | "MiscellaneousPassThrough" -> (Some FIX_SecurityType_MiscellaneousPassThrough) - | "Pfandbriefe" -> (Some FIX_SecurityType_Pfandbriefe) - | "ToBeAnnounced" -> (Some FIX_SecurityType_ToBeAnnounced) - | "OtherAnticipationNotes" -> (Some FIX_SecurityType_OtherAnticipationNotes) - | "CertificateOfObligation" -> (Some FIX_SecurityType_CertificateOfObligation) - | "CertificateOfParticipation" -> (Some FIX_SecurityType_CertificateOfParticipation) - | "GeneralObligationBonds" -> (Some FIX_SecurityType_GeneralObligationBonds) - | "MandatoryTender" -> (Some FIX_SecurityType_MandatoryTender) - | "RevenueAnticipationNote" -> (Some FIX_SecurityType_RevenueAnticipationNote) - | "RevenueBonds" -> (Some FIX_SecurityType_RevenueBonds) - | "SpecialAssessment" -> (Some FIX_SecurityType_SpecialAssessment) - | "SpecialObligation" -> (Some FIX_SecurityType_SpecialObligation) - | "SpecialTax" -> (Some FIX_SecurityType_SpecialTax) - | "TaxAnticipationNote" -> (Some FIX_SecurityType_TaxAnticipationNote) - | "TaxAllocation" -> (Some FIX_SecurityType_TaxAllocation) - | "TaxExemptCommercialPaper" -> (Some FIX_SecurityType_TaxExemptCommercialPaper) - | "TaxRevenueAnticipationNote" -> (Some FIX_SecurityType_TaxRevenueAnticipationNote) - | "VariableRateDemandNote" -> (Some FIX_SecurityType_VariableRateDemandNote) - | "Warrant" -> (Some FIX_SecurityType_Warrant) - | "MutualFund" -> (Some FIX_SecurityType_MutualFund) - | "MultilegInstrument" -> (Some FIX_SecurityType_MultilegInstrument) - | "NoSecurityType" -> (Some FIX_SecurityType_NoSecurityType) - | _ -> None - ) -;; - -let string_to_settlcurrfxratecalc_opt (d) = - (match d with - | "Multiply" -> (Some FIX_SettlCurrFxRateCalc_Multiply) - | "Divide" -> (Some FIX_SettlCurrFxRateCalc_Divide) - | _ -> None - ) -;; - -let string_to_settldeliverytype_opt (d) = - (match d with - | "Versus" -> (Some FIX_SettlDeliveryType_Versus) - | "Free" -> (Some FIX_SettlDeliveryType_Free) - | "TriParty" -> (Some FIX_SettlDeliveryType_TriParty) - | "HoldInCustody" -> (Some FIX_SettlDeliveryType_HoldInCustody) - | _ -> None - ) -;; - -let string_to_settlinstmode_opt (d) = - (match d with - | "StandingInstructionsProvided" -> (Some FIX_SettlInstMode_StandingInstructionsProvided) - | "SpecificOrderForASingleAccount" -> (Some FIX_SettlInstMode_SpecificOrderForASingleAccount) - | "RequestReject" -> (Some FIX_SettlInstMode_RequestReject) - | _ -> None - ) -;; - -let string_to_settlinstreqrejcode_opt (d) = - (match d with - | "UnableToProcessRequest" -> (Some FIX_SettlInstReqRejCode_UnableToProcessRequest) - | "UnknownAccount" -> (Some FIX_SettlInstReqRejCode_UnknownAccount) - | "NoMatchingSettlementInstructionsFound" -> (Some FIX_SettlInstReqRejCode_NoMatchingSettlementInstructionsFound) - | "Other" -> (Some FIX_SettlInstReqRejCode_Other) - | _ -> None - ) -;; - -let string_to_settlinstsource_opt (d) = - (match d with - | "BrokerCredit" -> (Some FIX_SettlInstSource_BrokerCredit) - | "Institution" -> (Some FIX_SettlInstSource_Institution) - | "Investor" -> (Some FIX_SettlInstSource_Investor) - | _ -> None - ) -;; - -let string_to_settlinsttranstype_opt (d) = - (match d with - | "New" -> (Some FIX_SettlInstTransType_New) - | "Cancel" -> (Some FIX_SettlInstTransType_Cancel) - | "Replace" -> (Some FIX_SettlInstTransType_Replace) - | "Restate" -> (Some FIX_SettlInstTransType_Restate) - | _ -> None - ) -;; - -let string_to_settlpricetype_opt (d) = - (match d with - | "Final" -> (Some FIX_SettlPriceType_Final) - | "Theoretical" -> (Some FIX_SettlPriceType_Theoretical) - | _ -> None - ) -;; - -let string_to_settlsessid_opt (d) = - (match d with - | "Intraday" -> (Some FIX_SettlSessID_Intraday) - | "RegularTradingHours" -> (Some FIX_SettlSessID_RegularTradingHours) - | "ElectronicTradingHours" -> (Some FIX_SettlSessID_ElectronicTradingHours) - | _ -> None - ) -;; - -let string_to_settltype_opt (d) = - (match d with - | "Regular" -> (Some FIX_SettlType_Regular) - | "Cash" -> (Some FIX_SettlType_Cash) - | "NextDay" -> (Some FIX_SettlType_NextDay) - | "TPlus2" -> (Some FIX_SettlType_TPlus2) - | "TPlus3" -> (Some FIX_SettlType_TPlus3) - | "TPlus4" -> (Some FIX_SettlType_TPlus4) - | "Future" -> (Some FIX_SettlType_Future) - | "WhenAndIfIssued" -> (Some FIX_SettlType_WhenAndIfIssued) - | "SellersOption" -> (Some FIX_SettlType_SellersOption) - | "TPlus5" -> (Some FIX_SettlType_TPlus5) - | _ -> None - ) -;; - -let string_to_shortsalereason_opt (d) = - (match d with - | "DealerSoldShort" -> (Some FIX_ShortSaleReason_DealerSoldShort) - | "DealerSoldShortExempt" -> (Some FIX_ShortSaleReason_DealerSoldShortExempt) - | "SellingCustomerSoldShort" -> (Some FIX_ShortSaleReason_SellingCustomerSoldShort) - | "SellingCustomerSoldShortExempt" -> (Some FIX_ShortSaleReason_SellingCustomerSoldShortExempt) - | "QualifiedServiceRepresentative" -> (Some FIX_ShortSaleReason_QualifiedServiceRepresentative) - | "QSROrAGUContraSideSoldShortExempt" -> (Some FIX_ShortSaleReason_QSROrAGUContraSideSoldShortExempt) - | _ -> None - ) -;; - -let string_to_side_opt (d) = - (match d with - | "Buy" -> (Some FIX_Side_Buy) - | "Sell" -> (Some FIX_Side_Sell) - | "BuyMinus" -> (Some FIX_Side_BuyMinus) - | "SellPlus" -> (Some FIX_Side_SellPlus) - | "SellShort" -> (Some FIX_Side_SellShort) - | "SellShortExempt" -> (Some FIX_Side_SellShortExempt) - | "Undisclosed" -> (Some FIX_Side_Undisclosed) - | "Cross" -> (Some FIX_Side_Cross) - | "CrossShort" -> (Some FIX_Side_CrossShort) - | "CrossShortExempt" -> (Some FIX_Side_CrossShortExempt) - | "AsDefined" -> (Some FIX_Side_AsDefined) - | "Opposite" -> (Some FIX_Side_Opposite) - | "Subscribe" -> (Some FIX_Side_Subscribe) - | "Redeem" -> (Some FIX_Side_Redeem) - | "Lend" -> (Some FIX_Side_Lend) - | "Borrow" -> (Some FIX_Side_Borrow) - | _ -> None - ) -;; - -let string_to_sidemultilegreportingtype_opt (d) = - (match d with - | "SingleSecurity" -> (Some FIX_SideMultiLegReportingType_SingleSecurity) - | "IndividualLegOfAMultilegSecurity" -> (Some FIX_SideMultiLegReportingType_IndividualLegOfAMultilegSecurity) - | "MultilegSecurity" -> (Some FIX_SideMultiLegReportingType_MultilegSecurity) - | _ -> None - ) -;; - -let string_to_sidevalueind_opt (d) = - (match d with - | "SideValue1" -> (Some FIX_SideValueInd_SideValue1) - | "SideValue2" -> (Some FIX_SideValueInd_SideValue2) - | _ -> None - ) -;; - -let string_to_solicitedflag_opt (d) = - (match d with - | "WasSolicited" -> (Some FIX_SolicitedFlag_WasSolicited) - | "WasNotSolicited" -> (Some FIX_SolicitedFlag_WasNotSolicited) - | _ -> None - ) -;; - -let string_to_standinstdbtype_opt (d) = - (match d with - | "Other" -> (Some FIX_StandInstDbType_Other) - | "DTCSID" -> (Some FIX_StandInstDbType_DTCSID) - | "ThomsonALERT" -> (Some FIX_StandInstDbType_ThomsonALERT) - | "AGlobalCustodian" -> (Some FIX_StandInstDbType_AGlobalCustodian) - | "AccountNet" -> (Some FIX_StandInstDbType_AccountNet) - | _ -> None - ) -;; - -let string_to_statusvalue_opt (d) = - (match d with - | "Connected" -> (Some FIX_StatusValue_Connected) - | "NotConnectedUnexpected" -> (Some FIX_StatusValue_NotConnectedUnexpected) - | "NotConnectedExpected" -> (Some FIX_StatusValue_NotConnectedExpected) - | "InProcess" -> (Some FIX_StatusValue_InProcess) - | _ -> None - ) -;; - -let string_to_stipulationtype_opt (d) = - (match d with - | "AlternativeMinimumTax" -> (Some FIX_StipulationType_AlternativeMinimumTax) - | "AutoReinvestment" -> (Some FIX_StipulationType_AutoReinvestment) - | "BankQualified" -> (Some FIX_StipulationType_BankQualified) - | "BargainConditions" -> (Some FIX_StipulationType_BargainConditions) - | "CouponRange" -> (Some FIX_StipulationType_CouponRange) - | "ISOCurrencyCode" -> (Some FIX_StipulationType_ISOCurrencyCode) - | "CustomStart" -> (Some FIX_StipulationType_CustomStart) - | "Geographics" -> (Some FIX_StipulationType_Geographics) - | "ValuationDiscount" -> (Some FIX_StipulationType_ValuationDiscount) - | "Insured" -> (Some FIX_StipulationType_Insured) - | "IssueDate" -> (Some FIX_StipulationType_IssueDate) - | "Issuer" -> (Some FIX_StipulationType_Issuer) - | "IssueSizeRange" -> (Some FIX_StipulationType_IssueSizeRange) - | "LookbackDays" -> (Some FIX_StipulationType_LookbackDays) - | "ExplicitLotIdentifier" -> (Some FIX_StipulationType_ExplicitLotIdentifier) - | "LotVariance" -> (Some FIX_StipulationType_LotVariance) - | "MaturityYearAndMonth" -> (Some FIX_StipulationType_MaturityYearAndMonth) - | "MaturityRange" -> (Some FIX_StipulationType_MaturityRange) - | "MaximumSubstitutions" -> (Some FIX_StipulationType_MaximumSubstitutions) - | "MinimumQuantity" -> (Some FIX_StipulationType_MinimumQuantity) - | "MinimumIncrement" -> (Some FIX_StipulationType_MinimumIncrement) - | "MinimumDenomination" -> (Some FIX_StipulationType_MinimumDenomination) - | "PaymentFrequency" -> (Some FIX_StipulationType_PaymentFrequency) - | "NumberOfPieces" -> (Some FIX_StipulationType_NumberOfPieces) - | "PoolsMaximum" -> (Some FIX_StipulationType_PoolsMaximum) - | "PoolsPerMillion" -> (Some FIX_StipulationType_PoolsPerMillion) - | "PoolsPerLot" -> (Some FIX_StipulationType_PoolsPerLot) - | "PoolsPerTrade" -> (Some FIX_StipulationType_PoolsPerTrade) - | "PriceRange" -> (Some FIX_StipulationType_PriceRange) - | "PricingFrequency" -> (Some FIX_StipulationType_PricingFrequency) - | "ProductionYear" -> (Some FIX_StipulationType_ProductionYear) - | "CallProtection" -> (Some FIX_StipulationType_CallProtection) - | "Purpose" -> (Some FIX_StipulationType_Purpose) - | "BenchmarkPriceSource" -> (Some FIX_StipulationType_BenchmarkPriceSource) - | "RatingSourceAndRange" -> (Some FIX_StipulationType_RatingSourceAndRange) - | "TypeOfRedemption" -> (Some FIX_StipulationType_TypeOfRedemption) - | "Restricted" -> (Some FIX_StipulationType_Restricted) - | "MarketSector" -> (Some FIX_StipulationType_MarketSector) - | "SecurityTypeIncludedOrExcluded" -> (Some FIX_StipulationType_SecurityTypeIncludedOrExcluded) - | "Structure" -> (Some FIX_StipulationType_Structure) - | "SubstitutionsFrequency" -> (Some FIX_StipulationType_SubstitutionsFrequency) - | "SubstitutionsLeft" -> (Some FIX_StipulationType_SubstitutionsLeft) - | "FreeformText" -> (Some FIX_StipulationType_FreeformText) - | "TradeVariance" -> (Some FIX_StipulationType_TradeVariance) - | "WeightedAverageCoupon" -> (Some FIX_StipulationType_WeightedAverageCoupon) - | "WeightedAverageLifeCoupon" -> (Some FIX_StipulationType_WeightedAverageLifeCoupon) - | "WeightedAverageLoanAge" -> (Some FIX_StipulationType_WeightedAverageLoanAge) - | "WeightedAverageMaturity" -> (Some FIX_StipulationType_WeightedAverageMaturity) - | "WholePool" -> (Some FIX_StipulationType_WholePool) - | "YieldRange" -> (Some FIX_StipulationType_YieldRange) - | _ -> None - ) -;; - -let string_to_subscriptionrequesttype_opt (d) = - (match d with - | "Snapshot" -> (Some FIX_SubscriptionRequestType_Snapshot) - | "SnapshotAndUpdates" -> (Some FIX_SubscriptionRequestType_SnapshotAndUpdates) - | "DisablePreviousSnapshot" -> (Some FIX_SubscriptionRequestType_DisablePreviousSnapshot) - | _ -> None - ) -;; - -let string_to_targetstrategy_opt (d) = - (match d with - | "VWAP" -> (Some FIX_TargetStrategy_VWAP) - | "Participate" -> (Some FIX_TargetStrategy_Participate) - | "MininizeMarketImpact" -> (Some FIX_TargetStrategy_MininizeMarketImpact) - | _ -> None - ) -;; - -let string_to_taxadvantagetype_opt (d) = - (match d with - | "FIXNone" -> (Some FIX_TaxAdvantageType_FIXNone) - | "MaxiISA" -> (Some FIX_TaxAdvantageType_MaxiISA) - | "TESSA" -> (Some FIX_TaxAdvantageType_TESSA) - | "MiniCashISA" -> (Some FIX_TaxAdvantageType_MiniCashISA) - | "MiniStocksAndSharesISA" -> (Some FIX_TaxAdvantageType_MiniStocksAndSharesISA) - | "MiniInsuranceISA" -> (Some FIX_TaxAdvantageType_MiniInsuranceISA) - | "CurrentYearPayment" -> (Some FIX_TaxAdvantageType_CurrentYearPayment) - | "PriorYearPayment" -> (Some FIX_TaxAdvantageType_PriorYearPayment) - | "AssetTransfer" -> (Some FIX_TaxAdvantageType_AssetTransfer) - | "EmployeePriorYear" -> (Some FIX_TaxAdvantageType_EmployeePriorYear) - | "EmployeeCurrentYear" -> (Some FIX_TaxAdvantageType_EmployeeCurrentYear) - | "EmployerPriorYear" -> (Some FIX_TaxAdvantageType_EmployerPriorYear) - | "EmployerCurrentYear" -> (Some FIX_TaxAdvantageType_EmployerCurrentYear) - | "NonFundPrototypeIRA" -> (Some FIX_TaxAdvantageType_NonFundPrototypeIRA) - | "NonFundQualifiedPlan" -> (Some FIX_TaxAdvantageType_NonFundQualifiedPlan) - | "DefinedContributionPlan" -> (Some FIX_TaxAdvantageType_DefinedContributionPlan) - | "IRA" -> (Some FIX_TaxAdvantageType_IRA) - | "IRARollover" -> (Some FIX_TaxAdvantageType_IRARollover) - | "KEOGH" -> (Some FIX_TaxAdvantageType_KEOGH) - | "ProfitSharingPlan" -> (Some FIX_TaxAdvantageType_ProfitSharingPlan) - | "US401K" -> (Some FIX_TaxAdvantageType_US401K) - | "SelfDirectedIRA" -> (Some FIX_TaxAdvantageType_SelfDirectedIRA) - | "US403b" -> (Some FIX_TaxAdvantageType_US403b) - | "US457" -> (Some FIX_TaxAdvantageType_US457) - | "RothIRAPrototype" -> (Some FIX_TaxAdvantageType_RothIRAPrototype) - | "RothIRANonPrototype" -> (Some FIX_TaxAdvantageType_RothIRANonPrototype) - | "RothConversionIRAPrototype" -> (Some FIX_TaxAdvantageType_RothConversionIRAPrototype) - | "RothConversionIRANonPrototype" -> (Some FIX_TaxAdvantageType_RothConversionIRANonPrototype) - | "EducationIRAPrototype" -> (Some FIX_TaxAdvantageType_EducationIRAPrototype) - | "EducationIRANonPrototype" -> (Some FIX_TaxAdvantageType_EducationIRANonPrototype) - | _ -> None - ) -;; - -let string_to_terminationtype_opt (d) = - (match d with - | "Overnight" -> (Some FIX_TerminationType_Overnight) - | "Term" -> (Some FIX_TerminationType_Term) - | "Flexible" -> (Some FIX_TerminationType_Flexible) - | "Open" -> (Some FIX_TerminationType_Open) - | _ -> None - ) -;; - -let string_to_testmessageindicator_opt (d) = - (match d with - | "True" -> (Some FIX_TestMessageIndicator_True) - | "Fales" -> (Some FIX_TestMessageIndicator_Fales) - | _ -> None - ) -;; - -let string_to_tickdirection_opt (d) = - (match d with - | "PlusTick" -> (Some FIX_TickDirection_PlusTick) - | "ZeroPlusTick" -> (Some FIX_TickDirection_ZeroPlusTick) - | "MinusTick" -> (Some FIX_TickDirection_MinusTick) - | "ZeroMinusTick" -> (Some FIX_TickDirection_ZeroMinusTick) - | _ -> None - ) -;; - -let string_to_timeinforce_opt (d) = - (match d with - | "Day" -> (Some FIX_TimeInForce_Day) - | "GoodTillCancel" -> (Some FIX_TimeInForce_GoodTillCancel) - | "AtTheOpening" -> (Some FIX_TimeInForce_AtTheOpening) - | "ImmediateOrCancel" -> (Some FIX_TimeInForce_ImmediateOrCancel) - | "FillOrKill" -> (Some FIX_TimeInForce_FillOrKill) - | "GoodTillCrossing" -> (Some FIX_TimeInForce_GoodTillCrossing) - | "GoodTillDate" -> (Some FIX_TimeInForce_GoodTillDate) - | "AtTheClose" -> (Some FIX_TimeInForce_AtTheClose) - | _ -> None - ) -;; - -let string_to_tradsesmethod_opt (d) = - (match d with - | "Electronic" -> (Some FIX_TradSesMethod_Electronic) - | "OpenOutcry" -> (Some FIX_TradSesMethod_OpenOutcry) - | "TwoParty" -> (Some FIX_TradSesMethod_TwoParty) - | _ -> None - ) -;; - -let string_to_tradsesmode_opt (d) = - (match d with - | "Testing" -> (Some FIX_TradSesMode_Testing) - | "Simulated" -> (Some FIX_TradSesMode_Simulated) - | "Production" -> (Some FIX_TradSesMode_Production) - | _ -> None - ) -;; - -let string_to_tradsesstatus_opt (d) = - (match d with - | "Unknown" -> (Some FIX_TradSesStatus_Unknown) - | "Halted" -> (Some FIX_TradSesStatus_Halted) - | "Open" -> (Some FIX_TradSesStatus_Open) - | "Closed" -> (Some FIX_TradSesStatus_Closed) - | "PreOpen" -> (Some FIX_TradSesStatus_PreOpen) - | "PreClose" -> (Some FIX_TradSesStatus_PreClose) - | "RequestRejected" -> (Some FIX_TradSesStatus_RequestRejected) - | _ -> None - ) -;; - -let string_to_tradsesstatusrejreason_opt (d) = - (match d with - | "UnknownOrInvalidTradingSessionID" -> (Some FIX_TradSesStatusRejReason_UnknownOrInvalidTradingSessionID) - | "Other" -> (Some FIX_TradSesStatusRejReason_Other) - | _ -> None - ) -;; - -let string_to_tradeallocindicator_opt (d) = - (match d with - | "AllocationNotRequired" -> (Some FIX_TradeAllocIndicator_AllocationNotRequired) - | "AllocationRequired" -> (Some FIX_TradeAllocIndicator_AllocationRequired) - | "UseAllocationProvidedWithTheTrade" -> (Some FIX_TradeAllocIndicator_UseAllocationProvidedWithTheTrade) - | _ -> None - ) -;; - -let string_to_tradecondition_opt (d) = - (match d with - | "Cash" -> (Some FIX_TradeCondition_Cash) - | "AveragePriceTrade" -> (Some FIX_TradeCondition_AveragePriceTrade) - | "CashTrade" -> (Some FIX_TradeCondition_CashTrade) - | "NextDay" -> (Some FIX_TradeCondition_NextDay) - | "Opening" -> (Some FIX_TradeCondition_Opening) - | "IntradayTradeDetail" -> (Some FIX_TradeCondition_IntradayTradeDetail) - | "Rule127Trade" -> (Some FIX_TradeCondition_Rule127Trade) - | "Rule155Trade" -> (Some FIX_TradeCondition_Rule155Trade) - | "SoldLast" -> (Some FIX_TradeCondition_SoldLast) - | "NextDayTrade" -> (Some FIX_TradeCondition_NextDayTrade) - | "Opened" -> (Some FIX_TradeCondition_Opened) - | "Seller" -> (Some FIX_TradeCondition_Seller) - | "Sold" -> (Some FIX_TradeCondition_Sold) - | "StoppedStock" -> (Some FIX_TradeCondition_StoppedStock) - | "ImbalanceMoreBuyers" -> (Some FIX_TradeCondition_ImbalanceMoreBuyers) - | "ImbalanceMoreSellers" -> (Some FIX_TradeCondition_ImbalanceMoreSellers) - | "OpeningPrice" -> (Some FIX_TradeCondition_OpeningPrice) - | _ -> None - ) -;; - -let string_to_tradereportrejectreason_opt (d) = - (match d with - | "Successful" -> (Some FIX_TradeReportRejectReason_Successful) - | "InvalidPartyOnformation" -> (Some FIX_TradeReportRejectReason_InvalidPartyOnformation) - | "UnknownInstrument" -> (Some FIX_TradeReportRejectReason_UnknownInstrument) - | "UnauthorizedToReportTrades" -> (Some FIX_TradeReportRejectReason_UnauthorizedToReportTrades) - | "InvalidTradeType" -> (Some FIX_TradeReportRejectReason_InvalidTradeType) - | "Other" -> (Some FIX_TradeReportRejectReason_Other) - | _ -> None - ) -;; - -let string_to_tradereporttype_opt (d) = - (match d with - | "Submit" -> (Some FIX_TradeReportType_Submit) - | "Alleged" -> (Some FIX_TradeReportType_Alleged) - | "Accept" -> (Some FIX_TradeReportType_Accept) - | "Decline" -> (Some FIX_TradeReportType_Decline) - | "Addendum" -> (Some FIX_TradeReportType_Addendum) - | "No" -> (Some FIX_TradeReportType_No) - | "TradeReportCancel" -> (Some FIX_TradeReportType_TradeReportCancel) - | "LockedIn" -> (Some FIX_TradeReportType_LockedIn) - | _ -> None - ) -;; - -let string_to_traderequestresult_opt (d) = - (match d with - | "Successful" -> (Some FIX_TradeRequestResult_Successful) - | "InvalidOrUnknownInstrument" -> (Some FIX_TradeRequestResult_InvalidOrUnknownInstrument) - | "InvalidTypeOfTradeRequested" -> (Some FIX_TradeRequestResult_InvalidTypeOfTradeRequested) - | "InvalidParties" -> (Some FIX_TradeRequestResult_InvalidParties) - | "InvalidTransportTypeRequested" -> (Some FIX_TradeRequestResult_InvalidTransportTypeRequested) - | "InvalidDestinationRequested" -> (Some FIX_TradeRequestResult_InvalidDestinationRequested) - | "TradeRequestTypeNotSupported" -> (Some FIX_TradeRequestResult_TradeRequestTypeNotSupported) - | "NotAuthorized" -> (Some FIX_TradeRequestResult_NotAuthorized) - | "Other" -> (Some FIX_TradeRequestResult_Other) - | _ -> None - ) -;; - -let string_to_traderequeststatus_opt (d) = - (match d with - | "Accepted" -> (Some FIX_TradeRequestStatus_Accepted) - | "Completed" -> (Some FIX_TradeRequestStatus_Completed) - | "Rejected" -> (Some FIX_TradeRequestStatus_Rejected) - | _ -> None - ) -;; - -let string_to_traderequesttype_opt (d) = - (match d with - | "AllTrades" -> (Some FIX_TradeRequestType_AllTrades) - | "MatchedTradesMatchingCriteria" -> (Some FIX_TradeRequestType_MatchedTradesMatchingCriteria) - | "UnmatchedTradesThatMatchCriteria" -> (Some FIX_TradeRequestType_UnmatchedTradesThatMatchCriteria) - | "UnreportedTradesThatMatchCriteria" -> (Some FIX_TradeRequestType_UnreportedTradesThatMatchCriteria) - | "AdvisoriesThatMatchCriteria" -> (Some FIX_TradeRequestType_AdvisoriesThatMatchCriteria) - | _ -> None - ) -;; - -let string_to_tradedflatswitch_opt (d) = - (match d with - | "TradedFlat" -> (Some FIX_TradedFlatSwitch_TradedFlat) - | "NotTradedFlat" -> (Some FIX_TradedFlatSwitch_NotTradedFlat) - | _ -> None - ) -;; - -let string_to_trdregtimestamptype_opt (d) = - (match d with - | "ExecutionTime" -> (Some FIX_TrdRegTimestampType_ExecutionTime) - | "TimeIn" -> (Some FIX_TrdRegTimestampType_TimeIn) - | "TimeOut" -> (Some FIX_TrdRegTimestampType_TimeOut) - | "BrokerReceipt" -> (Some FIX_TrdRegTimestampType_BrokerReceipt) - | "BrokerExecution" -> (Some FIX_TrdRegTimestampType_BrokerExecution) - | _ -> None - ) -;; - -let string_to_trdrptstatus_opt (d) = - (match d with - | "Accepted" -> (Some FIX_TrdRptStatus_Accepted) - | "Rejected" -> (Some FIX_TrdRptStatus_Rejected) - | _ -> None - ) -;; - -let string_to_trdtype_opt (d) = - (match d with - | "RegularTrade" -> (Some FIX_TrdType_RegularTrade) - | "BlockTrade" -> (Some FIX_TrdType_BlockTrade) - | "EFP" -> (Some FIX_TrdType_EFP) - | "Transfer" -> (Some FIX_TrdType_Transfer) - | "LateTrade" -> (Some FIX_TrdType_LateTrade) - | "TTrade" -> (Some FIX_TrdType_TTrade) - | "WeightedAveragePriceTrade" -> (Some FIX_TrdType_WeightedAveragePriceTrade) - | "BunchedTrade" -> (Some FIX_TrdType_BunchedTrade) - | "LateBunchedTrade" -> (Some FIX_TrdType_LateBunchedTrade) - | "PriorReferencePriceTrade" -> (Some FIX_TrdType_PriorReferencePriceTrade) - | "AfterHoursTrade" -> (Some FIX_TrdType_AfterHoursTrade) - | _ -> None - ) -;; - -let string_to_unsolicitedindicator_opt (d) = - (match d with - | "MessageIsBeingSentUnsolicited" -> (Some FIX_UnsolicitedIndicator_MessageIsBeingSentUnsolicited) - | "MessageIsBeingSentAsAResultOfAPriorRequest" -> (Some FIX_UnsolicitedIndicator_MessageIsBeingSentAsAResultOfAPriorRequest) - | _ -> None - ) -;; - -let string_to_urgency_opt (d) = - (match d with - | "Normal" -> (Some FIX_Urgency_Normal) - | "Flash" -> (Some FIX_Urgency_Flash) - | "Background" -> (Some FIX_Urgency_Background) - | _ -> None - ) -;; - -let string_to_userrequesttype_opt (d) = - (match d with - | "LogOnUser" -> (Some FIX_UserRequestType_LogOnUser) - | "LogOffUser" -> (Some FIX_UserRequestType_LogOffUser) - | "ChangePasswordForUser" -> (Some FIX_UserRequestType_ChangePasswordForUser) - | "RequestIndividualUserStatus" -> (Some FIX_UserRequestType_RequestIndividualUserStatus) - | _ -> None - ) -;; - -let string_to_userstatus_opt (d) = - (match d with - | "LoggedIn" -> (Some FIX_UserStatus_LoggedIn) - | "NotLoggedIn" -> (Some FIX_UserStatus_NotLoggedIn) - | "UserNotRecognised" -> (Some FIX_UserStatus_UserNotRecognised) - | "PasswordIncorrect" -> (Some FIX_UserStatus_PasswordIncorrect) - | "PasswordChanged" -> (Some FIX_UserStatus_PasswordChanged) - | "Other" -> (Some FIX_UserStatus_Other) - | _ -> None - ) -;; - -let string_to_workingindicator_opt (d) = - (match d with - | "Working" -> (Some FIX_WorkingIndicator_Working) - | "NotWorking" -> (Some FIX_WorkingIndicator_NotWorking) - | _ -> None - ) -;; - -let string_to_yieldtype_opt (d) = - (match d with - | "AfterTaxYield" -> (Some FIX_YieldType_AfterTaxYield) - | "AnnualYield" -> (Some FIX_YieldType_AnnualYield) - | "YieldAtIssue" -> (Some FIX_YieldType_YieldAtIssue) - | "YieldToAverageMaturity" -> (Some FIX_YieldType_YieldToAverageMaturity) - | "BookYield" -> (Some FIX_YieldType_BookYield) - | "YieldToNextCall" -> (Some FIX_YieldType_YieldToNextCall) - | "YieldChangeSinceClose" -> (Some FIX_YieldType_YieldChangeSinceClose) - | "ClosingYield" -> (Some FIX_YieldType_ClosingYield) - | "CompoundYield" -> (Some FIX_YieldType_CompoundYield) - | "CurrentYield" -> (Some FIX_YieldType_CurrentYield) - | "TrueGrossYield" -> (Some FIX_YieldType_TrueGrossYield) - | "GvntEquivalentYield" -> (Some FIX_YieldType_GvntEquivalentYield) - | "YieldWithInflationAssumption" -> (Some FIX_YieldType_YieldWithInflationAssumption) - | "InverseFloaterBondYield" -> (Some FIX_YieldType_InverseFloaterBondYield) - | "MostRecentClosingYield" -> (Some FIX_YieldType_MostRecentClosingYield) - | "ClosingYieldMostRecentMonth" -> (Some FIX_YieldType_ClosingYieldMostRecentMonth) - | "ClosingYieldMostRecentQuarter" -> (Some FIX_YieldType_ClosingYieldMostRecentQuarter) - | "ClosingYieldMostRecentYear" -> (Some FIX_YieldType_ClosingYieldMostRecentYear) - | "YieldToLongestAverageLife" -> (Some FIX_YieldType_YieldToLongestAverageLife) - | "MarkToMarketYield" -> (Some FIX_YieldType_MarkToMarketYield) - | "YieldToMaturity" -> (Some FIX_YieldType_YieldToMaturity) - | "YieldToNextRefund" -> (Some FIX_YieldType_YieldToNextRefund) - | "OpenAverageYield" -> (Some FIX_YieldType_OpenAverageYield) - | "YieldToNextPut" -> (Some FIX_YieldType_YieldToNextPut) - | "PreviousCloseYield" -> (Some FIX_YieldType_PreviousCloseYield) - | "ProceedsYield" -> (Some FIX_YieldType_ProceedsYield) - | "SemiAnnualYield" -> (Some FIX_YieldType_SemiAnnualYield) - | "YieldToShortestAverageLife" -> (Some FIX_YieldType_YieldToShortestAverageLife) - | "SimpleYield" -> (Some FIX_YieldType_SimpleYield) - | "TaxEquivalentYield" -> (Some FIX_YieldType_TaxEquivalentYield) - | "YieldToTenderDate" -> (Some FIX_YieldType_YieldToTenderDate) - | "TrueYield" -> (Some FIX_YieldType_TrueYield) - | "YieldValueOf132" -> (Some FIX_YieldType_YieldValueOf132) - | "YieldToWorst" -> (Some FIX_YieldType_YieldToWorst) - | _ -> None - ) -;; - -let full_enum_currency_decoder : fix_currency decoder = - string >>= (fun x -> (match string_to_currency_opt x with - | None -> (fail "Unknown enum (Currency) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_country_decoder : fix_country decoder = - string >>= (fun x -> (match string_to_country_opt x with - | None -> (fail "Unknown enum (Country) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_exchange_decoder : fix_exchange decoder = - string >>= (fun x -> (match string_to_exchange_opt x with - | None -> (fail "Unknown enum (Exchange) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_accounttype_decoder : fix_accounttype decoder = - string >>= (fun x -> (match string_to_accounttype_opt x with - | None -> (fail "Unknown enum (AccountType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_acctidsource_decoder : fix_acctidsource decoder = - string >>= (fun x -> (match string_to_acctidsource_opt x with - | None -> (fail "Unknown enum (AcctIDSource) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_adjustment_decoder : fix_adjustment decoder = - string >>= (fun x -> (match string_to_adjustment_opt x with - | None -> (fail "Unknown enum (Adjustment) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_adjustmenttype_decoder : fix_adjustmenttype decoder = - string >>= (fun x -> (match string_to_adjustmenttype_opt x with - | None -> (fail "Unknown enum (AdjustmentType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_advside_decoder : fix_advside decoder = - string >>= (fun x -> (match string_to_advside_opt x with - | None -> (fail "Unknown enum (AdvSide) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_advtranstype_decoder : fix_advtranstype decoder = - string >>= (fun x -> (match string_to_advtranstype_opt x with - | None -> (fail "Unknown enum (AdvTransType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_affirmstatus_decoder : fix_affirmstatus decoder = - string >>= (fun x -> (match string_to_affirmstatus_opt x with - | None -> (fail "Unknown enum (AffirmStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_aggregatedbook_decoder : fix_aggregatedbook decoder = - string >>= (fun x -> (match string_to_aggregatedbook_opt x with - | None -> (fail "Unknown enum (AggregatedBook) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_allocaccounttype_decoder : fix_allocaccounttype decoder = - string >>= (fun x -> (match string_to_allocaccounttype_opt x with - | None -> (fail "Unknown enum (AllocAccountType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_alloccancreplacereason_decoder : fix_alloccancreplacereason decoder = - string >>= (fun x -> (match string_to_alloccancreplacereason_opt x with - | None -> (fail "Unknown enum (AllocCancReplaceReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_allochandlinst_decoder : fix_allochandlinst decoder = - string >>= (fun x -> (match string_to_allochandlinst_opt x with - | None -> (fail "Unknown enum (AllocHandlInst) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_allocintermedreqtype_decoder : fix_allocintermedreqtype decoder = - string >>= (fun x -> (match string_to_allocintermedreqtype_opt x with - | None -> (fail "Unknown enum (AllocIntermedReqType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_alloclinktype_decoder : fix_alloclinktype decoder = - string >>= (fun x -> (match string_to_alloclinktype_opt x with - | None -> (fail "Unknown enum (AllocLinkType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_allocnoorderstype_decoder : fix_allocnoorderstype decoder = - string >>= (fun x -> (match string_to_allocnoorderstype_opt x with - | None -> (fail "Unknown enum (AllocNoOrdersType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_allocrejcode_decoder : fix_allocrejcode decoder = - string >>= (fun x -> (match string_to_allocrejcode_opt x with - | None -> (fail "Unknown enum (AllocRejCode) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_allocreporttype_decoder : fix_allocreporttype decoder = - string >>= (fun x -> (match string_to_allocreporttype_opt x with - | None -> (fail "Unknown enum (AllocReportType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_allocsettlinsttype_decoder : fix_allocsettlinsttype decoder = - string >>= (fun x -> (match string_to_allocsettlinsttype_opt x with - | None -> (fail "Unknown enum (AllocSettlInstType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_allocstatus_decoder : fix_allocstatus decoder = - string >>= (fun x -> (match string_to_allocstatus_opt x with - | None -> (fail "Unknown enum (AllocStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_alloctranstype_decoder : fix_alloctranstype decoder = - string >>= (fun x -> (match string_to_alloctranstype_opt x with - | None -> (fail "Unknown enum (AllocTransType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_alloctype_decoder : fix_alloctype decoder = - string >>= (fun x -> (match string_to_alloctype_opt x with - | None -> (fail "Unknown enum (AllocType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_applqueueaction_decoder : fix_applqueueaction decoder = - string >>= (fun x -> (match string_to_applqueueaction_opt x with - | None -> (fail "Unknown enum (ApplQueueAction) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_applqueueresolution_decoder : fix_applqueueresolution decoder = - string >>= (fun x -> (match string_to_applqueueresolution_opt x with - | None -> (fail "Unknown enum (ApplQueueResolution) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_assignmentmethod_decoder : fix_assignmentmethod decoder = - string >>= (fun x -> (match string_to_assignmentmethod_opt x with - | None -> (fail "Unknown enum (AssignmentMethod) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_avgpxindicator_decoder : fix_avgpxindicator decoder = - string >>= (fun x -> (match string_to_avgpxindicator_opt x with - | None -> (fail "Unknown enum (AvgPxIndicator) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_basispxtype_decoder : fix_basispxtype decoder = - string >>= (fun x -> (match string_to_basispxtype_opt x with - | None -> (fail "Unknown enum (BasisPxType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_biddescriptortype_decoder : fix_biddescriptortype decoder = - string >>= (fun x -> (match string_to_biddescriptortype_opt x with - | None -> (fail "Unknown enum (BidDescriptorType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_bidrequesttranstype_decoder : fix_bidrequesttranstype decoder = - string >>= (fun x -> (match string_to_bidrequesttranstype_opt x with - | None -> (fail "Unknown enum (BidRequestTransType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_bidtradetype_decoder : fix_bidtradetype decoder = - string >>= (fun x -> (match string_to_bidtradetype_opt x with - | None -> (fail "Unknown enum (BidTradeType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_bidtype_decoder : fix_bidtype decoder = - string >>= (fun x -> (match string_to_bidtype_opt x with - | None -> (fail "Unknown enum (BidType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_bookingtype_decoder : fix_bookingtype decoder = - string >>= (fun x -> (match string_to_bookingtype_opt x with - | None -> (fail "Unknown enum (BookingType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_bookingunit_decoder : fix_bookingunit decoder = - string >>= (fun x -> (match string_to_bookingunit_opt x with - | None -> (fail "Unknown enum (BookingUnit) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_cpprogram_decoder : fix_cpprogram decoder = - string >>= (fun x -> (match string_to_cpprogram_opt x with - | None -> (fail "Unknown enum (CPProgram) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_cancellationrights_decoder : fix_cancellationrights decoder = - string >>= (fun x -> (match string_to_cancellationrights_opt x with - | None -> (fail "Unknown enum (CancellationRights) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_cashmargin_decoder : fix_cashmargin decoder = - string >>= (fun x -> (match string_to_cashmargin_opt x with - | None -> (fail "Unknown enum (CashMargin) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_clearingfeeindicator_decoder : fix_clearingfeeindicator decoder = - string >>= (fun x -> (match string_to_clearingfeeindicator_opt x with - | None -> (fail "Unknown enum (ClearingFeeIndicator) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_clearinginstruction_decoder : fix_clearinginstruction decoder = - string >>= (fun x -> (match string_to_clearinginstruction_opt x with - | None -> (fail "Unknown enum (ClearingInstruction) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_collaction_decoder : fix_collaction decoder = - string >>= (fun x -> (match string_to_collaction_opt x with - | None -> (fail "Unknown enum (CollAction) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_collasgnreason_decoder : fix_collasgnreason decoder = - string >>= (fun x -> (match string_to_collasgnreason_opt x with - | None -> (fail "Unknown enum (CollAsgnReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_collasgnrejectreason_decoder : fix_collasgnrejectreason decoder = - string >>= (fun x -> (match string_to_collasgnrejectreason_opt x with - | None -> (fail "Unknown enum (CollAsgnRejectReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_collasgnresptype_decoder : fix_collasgnresptype decoder = - string >>= (fun x -> (match string_to_collasgnresptype_opt x with - | None -> (fail "Unknown enum (CollAsgnRespType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_collasgntranstype_decoder : fix_collasgntranstype decoder = - string >>= (fun x -> (match string_to_collasgntranstype_opt x with - | None -> (fail "Unknown enum (CollAsgnTransType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_collinquiryqualifier_decoder : fix_collinquiryqualifier decoder = - string >>= (fun x -> (match string_to_collinquiryqualifier_opt x with - | None -> (fail "Unknown enum (CollInquiryQualifier) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_collinquiryresult_decoder : fix_collinquiryresult decoder = - string >>= (fun x -> (match string_to_collinquiryresult_opt x with - | None -> (fail "Unknown enum (CollInquiryResult) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_collinquirystatus_decoder : fix_collinquirystatus decoder = - string >>= (fun x -> (match string_to_collinquirystatus_opt x with - | None -> (fail "Unknown enum (CollInquiryStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_collstatus_decoder : fix_collstatus decoder = - string >>= (fun x -> (match string_to_collstatus_opt x with - | None -> (fail "Unknown enum (CollStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_commtype_decoder : fix_commtype decoder = - string >>= (fun x -> (match string_to_commtype_opt x with - | None -> (fail "Unknown enum (CommType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_confirmrejreason_decoder : fix_confirmrejreason decoder = - string >>= (fun x -> (match string_to_confirmrejreason_opt x with - | None -> (fail "Unknown enum (ConfirmRejReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_confirmstatus_decoder : fix_confirmstatus decoder = - string >>= (fun x -> (match string_to_confirmstatus_opt x with - | None -> (fail "Unknown enum (ConfirmStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_confirmtranstype_decoder : fix_confirmtranstype decoder = - string >>= (fun x -> (match string_to_confirmtranstype_opt x with - | None -> (fail "Unknown enum (ConfirmTransType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_confirmtype_decoder : fix_confirmtype decoder = - string >>= (fun x -> (match string_to_confirmtype_opt x with - | None -> (fail "Unknown enum (ConfirmType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_contamttype_decoder : fix_contamttype decoder = - string >>= (fun x -> (match string_to_contamttype_opt x with - | None -> (fail "Unknown enum (ContAmtType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_corporateaction_decoder : fix_corporateaction list decoder = - list (string >>= (fun x -> (match string_to_corporateaction_opt x with - | None -> (fail "Unknown enum (CorporateAction) encoding.") - | Some y -> (succeed y) - ) - )) -;; - -let full_enum_coveredoruncovered_decoder : fix_coveredoruncovered decoder = - string >>= (fun x -> (match string_to_coveredoruncovered_opt x with - | None -> (fail "Unknown enum (CoveredOrUncovered) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_crossprioritization_decoder : fix_crossprioritization decoder = - string >>= (fun x -> (match string_to_crossprioritization_opt x with - | None -> (fail "Unknown enum (CrossPrioritization) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_crosstype_decoder : fix_crosstype decoder = - string >>= (fun x -> (match string_to_crosstype_opt x with - | None -> (fail "Unknown enum (CrossType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_custordercapacity_decoder : fix_custordercapacity decoder = - string >>= (fun x -> (match string_to_custordercapacity_opt x with - | None -> (fail "Unknown enum (CustOrderCapacity) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_cxlrejreason_decoder : fix_cxlrejreason decoder = - string >>= (fun x -> (match string_to_cxlrejreason_opt x with - | None -> (fail "Unknown enum (CxlRejReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_dkreason_decoder : fix_dkreason decoder = - string >>= (fun x -> (match string_to_dkreason_opt x with - | None -> (fail "Unknown enum (DKReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_daybookinginst_decoder : fix_daybookinginst decoder = - string >>= (fun x -> (match string_to_daybookinginst_opt x with - | None -> (fail "Unknown enum (DayBookingInst) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_deletereason_decoder : fix_deletereason decoder = - string >>= (fun x -> (match string_to_deletereason_opt x with - | None -> (fail "Unknown enum (DeleteReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_deliveryform_decoder : fix_deliveryform decoder = - string >>= (fun x -> (match string_to_deliveryform_opt x with - | None -> (fail "Unknown enum (DeliveryForm) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_deliverytype_decoder : fix_deliverytype decoder = - string >>= (fun x -> (match string_to_deliverytype_opt x with - | None -> (fail "Unknown enum (DeliveryType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_discretioninst_decoder : fix_discretioninst decoder = - string >>= (fun x -> (match string_to_discretioninst_opt x with - | None -> (fail "Unknown enum (DiscretionInst) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_discretionlimittype_decoder : fix_discretionlimittype decoder = - string >>= (fun x -> (match string_to_discretionlimittype_opt x with - | None -> (fail "Unknown enum (DiscretionLimitType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_discretionmovetype_decoder : fix_discretionmovetype decoder = - string >>= (fun x -> (match string_to_discretionmovetype_opt x with - | None -> (fail "Unknown enum (DiscretionMoveType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_discretionoffsettype_decoder : fix_discretionoffsettype decoder = - string >>= (fun x -> (match string_to_discretionoffsettype_opt x with - | None -> (fail "Unknown enum (DiscretionOffsetType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_discretionrounddirection_decoder : fix_discretionrounddirection decoder = - string >>= (fun x -> (match string_to_discretionrounddirection_opt x with - | None -> (fail "Unknown enum (DiscretionRoundDirection) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_discretionscope_decoder : fix_discretionscope decoder = - string >>= (fun x -> (match string_to_discretionscope_opt x with - | None -> (fail "Unknown enum (DiscretionScope) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_distribpaymentmethod_decoder : fix_distribpaymentmethod decoder = - string >>= (fun x -> (match string_to_distribpaymentmethod_opt x with - | None -> (fail "Unknown enum (DistribPaymentMethod) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_dlvyinsttype_decoder : fix_dlvyinsttype decoder = - string >>= (fun x -> (match string_to_dlvyinsttype_opt x with - | None -> (fail "Unknown enum (DlvyInstType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_duetorelated_decoder : fix_duetorelated decoder = - string >>= (fun x -> (match string_to_duetorelated_opt x with - | None -> (fail "Unknown enum (DueToRelated) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_emailtype_decoder : fix_emailtype decoder = - string >>= (fun x -> (match string_to_emailtype_opt x with - | None -> (fail "Unknown enum (EmailType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_eventtype_decoder : fix_eventtype decoder = - string >>= (fun x -> (match string_to_eventtype_opt x with - | None -> (fail "Unknown enum (EventType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_exchangeforphysical_decoder : fix_exchangeforphysical decoder = - string >>= (fun x -> (match string_to_exchangeforphysical_opt x with - | None -> (fail "Unknown enum (ExchangeForPhysical) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_execinst_decoder : fix_execinst list decoder = - list (string >>= (fun x -> (match string_to_execinst_opt x with - | None -> (fail "Unknown enum (ExecInst) encoding.") - | Some y -> (succeed y) - ) - )) -;; - -let full_enum_execpricetype_decoder : fix_execpricetype decoder = - string >>= (fun x -> (match string_to_execpricetype_opt x with - | None -> (fail "Unknown enum (ExecPriceType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_execrestatementreason_decoder : fix_execrestatementreason decoder = - string >>= (fun x -> (match string_to_execrestatementreason_opt x with - | None -> (fail "Unknown enum (ExecRestatementReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_exectype_decoder : fix_exectype decoder = - string >>= (fun x -> (match string_to_exectype_opt x with - | None -> (fail "Unknown enum (ExecType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_exercisemethod_decoder : fix_exercisemethod decoder = - string >>= (fun x -> (match string_to_exercisemethod_opt x with - | None -> (fail "Unknown enum (ExerciseMethod) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_expirationcycle_decoder : fix_expirationcycle decoder = - string >>= (fun x -> (match string_to_expirationcycle_opt x with - | None -> (fail "Unknown enum (ExpirationCycle) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_financialstatus_decoder : fix_financialstatus list decoder = - list (string >>= (fun x -> (match string_to_financialstatus_opt x with - | None -> (fail "Unknown enum (FinancialStatus) encoding.") - | Some y -> (succeed y) - ) - )) -;; - -let full_enum_forexreq_decoder : fix_forexreq decoder = - string >>= (fun x -> (match string_to_forexreq_opt x with - | None -> (fail "Unknown enum (ForexReq) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_fundrenewwaiv_decoder : fix_fundrenewwaiv decoder = - string >>= (fun x -> (match string_to_fundrenewwaiv_opt x with - | None -> (fail "Unknown enum (FundRenewWaiv) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_gtbookinginst_decoder : fix_gtbookinginst decoder = - string >>= (fun x -> (match string_to_gtbookinginst_opt x with - | None -> (fail "Unknown enum (GTBookingInst) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_haltreason_decoder : fix_haltreason decoder = - string >>= (fun x -> (match string_to_haltreason_opt x with - | None -> (fail "Unknown enum (HaltReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_handlinst_decoder : fix_handlinst decoder = - string >>= (fun x -> (match string_to_handlinst_opt x with - | None -> (fail "Unknown enum (HandlInst) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_ioinaturalflag_decoder : fix_ioinaturalflag decoder = - string >>= (fun x -> (match string_to_ioinaturalflag_opt x with - | None -> (fail "Unknown enum (IOINaturalFlag) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_ioiqltyind_decoder : fix_ioiqltyind decoder = - string >>= (fun x -> (match string_to_ioiqltyind_opt x with - | None -> (fail "Unknown enum (IOIQltyInd) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_ioiqty_decoder : fix_ioiqty decoder = - string >>= (fun x -> (match string_to_ioiqty_opt x with - | None -> (fail "Unknown enum (IOIQty) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_ioiqualifier_decoder : fix_ioiqualifier decoder = - string >>= (fun x -> (match string_to_ioiqualifier_opt x with - | None -> (fail "Unknown enum (IOIQualifier) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_ioitranstype_decoder : fix_ioitranstype decoder = - string >>= (fun x -> (match string_to_ioitranstype_opt x with - | None -> (fail "Unknown enum (IOITransType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_inviewofcommon_decoder : fix_inviewofcommon decoder = - string >>= (fun x -> (match string_to_inviewofcommon_opt x with - | None -> (fail "Unknown enum (InViewOfCommon) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_inctaxind_decoder : fix_inctaxind decoder = - string >>= (fun x -> (match string_to_inctaxind_opt x with - | None -> (fail "Unknown enum (IncTaxInd) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_instrattribtype_decoder : fix_instrattribtype decoder = - string >>= (fun x -> (match string_to_instrattribtype_opt x with - | None -> (fail "Unknown enum (InstrAttribType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_lastcapacity_decoder : fix_lastcapacity decoder = - string >>= (fun x -> (match string_to_lastcapacity_opt x with - | None -> (fail "Unknown enum (LastCapacity) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_lastfragment_decoder : fix_lastfragment decoder = - string >>= (fun x -> (match string_to_lastfragment_opt x with - | None -> (fail "Unknown enum (LastFragment) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_lastliquidityind_decoder : fix_lastliquidityind decoder = - string >>= (fun x -> (match string_to_lastliquidityind_opt x with - | None -> (fail "Unknown enum (LastLiquidityInd) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_legswaptype_decoder : fix_legswaptype decoder = - string >>= (fun x -> (match string_to_legswaptype_opt x with - | None -> (fail "Unknown enum (LegSwapType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_legalconfirm_decoder : fix_legalconfirm decoder = - string >>= (fun x -> (match string_to_legalconfirm_opt x with - | None -> (fail "Unknown enum (LegalConfirm) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_liquidityindtype_decoder : fix_liquidityindtype decoder = - string >>= (fun x -> (match string_to_liquidityindtype_opt x with - | None -> (fail "Unknown enum (LiquidityIndType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_listexecinsttype_decoder : fix_listexecinsttype decoder = - string >>= (fun x -> (match string_to_listexecinsttype_opt x with - | None -> (fail "Unknown enum (ListExecInstType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_listorderstatus_decoder : fix_listorderstatus decoder = - string >>= (fun x -> (match string_to_listorderstatus_opt x with - | None -> (fail "Unknown enum (ListOrderStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_liststatustype_decoder : fix_liststatustype decoder = - string >>= (fun x -> (match string_to_liststatustype_opt x with - | None -> (fail "Unknown enum (ListStatusType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_locatereqd_decoder : fix_locatereqd decoder = - string >>= (fun x -> (match string_to_locatereqd_opt x with - | None -> (fail "Unknown enum (LocateReqd) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_mdentrytype_decoder : fix_mdentrytype decoder = - string >>= (fun x -> (match string_to_mdentrytype_opt x with - | None -> (fail "Unknown enum (MDEntryType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_mdimplicitdelete_decoder : fix_mdimplicitdelete decoder = - string >>= (fun x -> (match string_to_mdimplicitdelete_opt x with - | None -> (fail "Unknown enum (MDImplicitDelete) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_mdreqrejreason_decoder : fix_mdreqrejreason decoder = - string >>= (fun x -> (match string_to_mdreqrejreason_opt x with - | None -> (fail "Unknown enum (MDReqRejReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_mdupdateaction_decoder : fix_mdupdateaction decoder = - string >>= (fun x -> (match string_to_mdupdateaction_opt x with - | None -> (fail "Unknown enum (MDUpdateAction) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_mdupdatetype_decoder : fix_mdupdatetype decoder = - string >>= (fun x -> (match string_to_mdupdatetype_opt x with - | None -> (fail "Unknown enum (MDUpdateType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_masscancelrejectreason_decoder : fix_masscancelrejectreason decoder = - string >>= (fun x -> (match string_to_masscancelrejectreason_opt x with - | None -> (fail "Unknown enum (MassCancelRejectReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_masscancelrequesttype_decoder : fix_masscancelrequesttype decoder = - string >>= (fun x -> (match string_to_masscancelrequesttype_opt x with - | None -> (fail "Unknown enum (MassCancelRequestType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_masscancelresponse_decoder : fix_masscancelresponse decoder = - string >>= (fun x -> (match string_to_masscancelresponse_opt x with - | None -> (fail "Unknown enum (MassCancelResponse) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_massstatusreqtype_decoder : fix_massstatusreqtype decoder = - string >>= (fun x -> (match string_to_massstatusreqtype_opt x with - | None -> (fail "Unknown enum (MassStatusReqType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_matchstatus_decoder : fix_matchstatus decoder = - string >>= (fun x -> (match string_to_matchstatus_opt x with - | None -> (fail "Unknown enum (MatchStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_matchtype_decoder : fix_matchtype decoder = - string >>= (fun x -> (match string_to_matchtype_opt x with - | None -> (fail "Unknown enum (MatchType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_messageencoding_decoder : fix_messageencoding decoder = - string >>= (fun x -> (match string_to_messageencoding_opt x with - | None -> (fail "Unknown enum (MessageEncoding) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_miscfeebasis_decoder : fix_miscfeebasis decoder = - string >>= (fun x -> (match string_to_miscfeebasis_opt x with - | None -> (fail "Unknown enum (MiscFeeBasis) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_miscfeetype_decoder : fix_miscfeetype decoder = - string >>= (fun x -> (match string_to_miscfeetype_opt x with - | None -> (fail "Unknown enum (MiscFeeType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_moneylaunderingstatus_decoder : fix_moneylaunderingstatus decoder = - string >>= (fun x -> (match string_to_moneylaunderingstatus_opt x with - | None -> (fail "Unknown enum (MoneyLaunderingStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_msgdirection_decoder : fix_msgdirection decoder = - string >>= (fun x -> (match string_to_msgdirection_opt x with - | None -> (fail "Unknown enum (MsgDirection) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_multilegreportingtype_decoder : fix_multilegreportingtype decoder = - string >>= (fun x -> (match string_to_multilegreportingtype_opt x with - | None -> (fail "Unknown enum (MultiLegReportingType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_multilegrpttypereq_decoder : fix_multilegrpttypereq decoder = - string >>= (fun x -> (match string_to_multilegrpttypereq_opt x with - | None -> (fail "Unknown enum (MultiLegRptTypeReq) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_netgrossind_decoder : fix_netgrossind decoder = - string >>= (fun x -> (match string_to_netgrossind_opt x with - | None -> (fail "Unknown enum (NetGrossInd) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_networkrequesttype_decoder : fix_networkrequesttype decoder = - string >>= (fun x -> (match string_to_networkrequesttype_opt x with - | None -> (fail "Unknown enum (NetworkRequestType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_networkstatusresponsetype_decoder : fix_networkstatusresponsetype decoder = - string >>= (fun x -> (match string_to_networkstatusresponsetype_opt x with - | None -> (fail "Unknown enum (NetworkStatusResponseType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_notifybrokerofcredit_decoder : fix_notifybrokerofcredit decoder = - string >>= (fun x -> (match string_to_notifybrokerofcredit_opt x with - | None -> (fail "Unknown enum (NotifyBrokerOfCredit) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_oddlot_decoder : fix_oddlot decoder = - string >>= (fun x -> (match string_to_oddlot_opt x with - | None -> (fail "Unknown enum (OddLot) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_openclosesettlflag_decoder : fix_openclosesettlflag list decoder = - list (string >>= (fun x -> (match string_to_openclosesettlflag_opt x with - | None -> (fail "Unknown enum (OpenCloseSettlFlag) encoding.") - | Some y -> (succeed y) - ) - )) -;; - -let full_enum_ordrejreason_decoder : fix_ordrejreason decoder = - string >>= (fun x -> (match string_to_ordrejreason_opt x with - | None -> (fail "Unknown enum (OrdRejReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_ordstatus_decoder : fix_ordstatus decoder = - string >>= (fun x -> (match string_to_ordstatus_opt x with - | None -> (fail "Unknown enum (OrdStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_ordtype_decoder : fix_ordtype decoder = - string >>= (fun x -> (match string_to_ordtype_opt x with - | None -> (fail "Unknown enum (OrdType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_ordercapacity_decoder : fix_ordercapacity decoder = - string >>= (fun x -> (match string_to_ordercapacity_opt x with - | None -> (fail "Unknown enum (OrderCapacity) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_orderrestrictions_decoder : fix_orderrestrictions list decoder = - list (string >>= (fun x -> (match string_to_orderrestrictions_opt x with - | None -> (fail "Unknown enum (OrderRestrictions) encoding.") - | Some y -> (succeed y) - ) - )) -;; - -let full_enum_ownertype_decoder : fix_ownertype decoder = - string >>= (fun x -> (match string_to_ownertype_opt x with - | None -> (fail "Unknown enum (OwnerType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_ownershiptype_decoder : fix_ownershiptype decoder = - string >>= (fun x -> (match string_to_ownershiptype_opt x with - | None -> (fail "Unknown enum (OwnershipType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_partyidsource_decoder : fix_partyidsource decoder = - string >>= (fun x -> (match string_to_partyidsource_opt x with - | None -> (fail "Unknown enum (PartyIDSource) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_partyrole_decoder : fix_partyrole decoder = - string >>= (fun x -> (match string_to_partyrole_opt x with - | None -> (fail "Unknown enum (PartyRole) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_partysubidtype_decoder : fix_partysubidtype decoder = - string >>= (fun x -> (match string_to_partysubidtype_opt x with - | None -> (fail "Unknown enum (PartySubIDType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_paymentmethod_decoder : fix_paymentmethod decoder = - string >>= (fun x -> (match string_to_paymentmethod_opt x with - | None -> (fail "Unknown enum (PaymentMethod) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_peglimittype_decoder : fix_peglimittype decoder = - string >>= (fun x -> (match string_to_peglimittype_opt x with - | None -> (fail "Unknown enum (PegLimitType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_pegmovetype_decoder : fix_pegmovetype decoder = - string >>= (fun x -> (match string_to_pegmovetype_opt x with - | None -> (fail "Unknown enum (PegMoveType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_pegoffsettype_decoder : fix_pegoffsettype decoder = - string >>= (fun x -> (match string_to_pegoffsettype_opt x with - | None -> (fail "Unknown enum (PegOffsetType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_pegrounddirection_decoder : fix_pegrounddirection decoder = - string >>= (fun x -> (match string_to_pegrounddirection_opt x with - | None -> (fail "Unknown enum (PegRoundDirection) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_pegscope_decoder : fix_pegscope decoder = - string >>= (fun x -> (match string_to_pegscope_opt x with - | None -> (fail "Unknown enum (PegScope) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_posamttype_decoder : fix_posamttype decoder = - string >>= (fun x -> (match string_to_posamttype_opt x with - | None -> (fail "Unknown enum (PosAmtType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_posmaintaction_decoder : fix_posmaintaction decoder = - string >>= (fun x -> (match string_to_posmaintaction_opt x with - | None -> (fail "Unknown enum (PosMaintAction) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_posmaintresult_decoder : fix_posmaintresult decoder = - string >>= (fun x -> (match string_to_posmaintresult_opt x with - | None -> (fail "Unknown enum (PosMaintResult) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_posmaintstatus_decoder : fix_posmaintstatus decoder = - string >>= (fun x -> (match string_to_posmaintstatus_opt x with - | None -> (fail "Unknown enum (PosMaintStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_posqtystatus_decoder : fix_posqtystatus decoder = - string >>= (fun x -> (match string_to_posqtystatus_opt x with - | None -> (fail "Unknown enum (PosQtyStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_posreqresult_decoder : fix_posreqresult decoder = - string >>= (fun x -> (match string_to_posreqresult_opt x with - | None -> (fail "Unknown enum (PosReqResult) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_posreqstatus_decoder : fix_posreqstatus decoder = - string >>= (fun x -> (match string_to_posreqstatus_opt x with - | None -> (fail "Unknown enum (PosReqStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_posreqtype_decoder : fix_posreqtype decoder = - string >>= (fun x -> (match string_to_posreqtype_opt x with - | None -> (fail "Unknown enum (PosReqType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_postranstype_decoder : fix_postranstype decoder = - string >>= (fun x -> (match string_to_postranstype_opt x with - | None -> (fail "Unknown enum (PosTransType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_postype_decoder : fix_postype decoder = - string >>= (fun x -> (match string_to_postype_opt x with - | None -> (fail "Unknown enum (PosType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_positioneffect_decoder : fix_positioneffect decoder = - string >>= (fun x -> (match string_to_positioneffect_opt x with - | None -> (fail "Unknown enum (PositionEffect) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_possdupflag_decoder : fix_possdupflag decoder = - string >>= (fun x -> (match string_to_possdupflag_opt x with - | None -> (fail "Unknown enum (PossDupFlag) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_possresend_decoder : fix_possresend decoder = - string >>= (fun x -> (match string_to_possresend_opt x with - | None -> (fail "Unknown enum (PossResend) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_preallocmethod_decoder : fix_preallocmethod decoder = - string >>= (fun x -> (match string_to_preallocmethod_opt x with - | None -> (fail "Unknown enum (PreallocMethod) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_previouslyreported_decoder : fix_previouslyreported decoder = - string >>= (fun x -> (match string_to_previouslyreported_opt x with - | None -> (fail "Unknown enum (PreviouslyReported) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_pricetype_decoder : fix_pricetype decoder = - string >>= (fun x -> (match string_to_pricetype_opt x with - | None -> (fail "Unknown enum (PriceType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_priorityindicator_decoder : fix_priorityindicator decoder = - string >>= (fun x -> (match string_to_priorityindicator_opt x with - | None -> (fail "Unknown enum (PriorityIndicator) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_processcode_decoder : fix_processcode decoder = - string >>= (fun x -> (match string_to_processcode_opt x with - | None -> (fail "Unknown enum (ProcessCode) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_product_decoder : fix_product decoder = - string >>= (fun x -> (match string_to_product_opt x with - | None -> (fail "Unknown enum (Product) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_progrptreqs_decoder : fix_progrptreqs decoder = - string >>= (fun x -> (match string_to_progrptreqs_opt x with - | None -> (fail "Unknown enum (ProgRptReqs) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_publishtrdindicator_decoder : fix_publishtrdindicator decoder = - string >>= (fun x -> (match string_to_publishtrdindicator_opt x with - | None -> (fail "Unknown enum (PublishTrdIndicator) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_putorcall_decoder : fix_putorcall decoder = - string >>= (fun x -> (match string_to_putorcall_opt x with - | None -> (fail "Unknown enum (PutOrCall) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_qtytype_decoder : fix_qtytype decoder = - string >>= (fun x -> (match string_to_qtytype_opt x with - | None -> (fail "Unknown enum (QtyType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_quotecanceltype_decoder : fix_quotecanceltype decoder = - string >>= (fun x -> (match string_to_quotecanceltype_opt x with - | None -> (fail "Unknown enum (QuoteCancelType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_quotecondition_decoder : fix_quotecondition list decoder = - list (string >>= (fun x -> (match string_to_quotecondition_opt x with - | None -> (fail "Unknown enum (QuoteCondition) encoding.") - | Some y -> (succeed y) - ) - )) -;; - -let full_enum_quotepricetype_decoder : fix_quotepricetype decoder = - string >>= (fun x -> (match string_to_quotepricetype_opt x with - | None -> (fail "Unknown enum (QuotePriceType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_quoterejectreason_decoder : fix_quoterejectreason decoder = - string >>= (fun x -> (match string_to_quoterejectreason_opt x with - | None -> (fail "Unknown enum (QuoteRejectReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_quoterequestrejectreason_decoder : fix_quoterequestrejectreason decoder = - string >>= (fun x -> (match string_to_quoterequestrejectreason_opt x with - | None -> (fail "Unknown enum (QuoteRequestRejectReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_quoterequesttype_decoder : fix_quoterequesttype decoder = - string >>= (fun x -> (match string_to_quoterequesttype_opt x with - | None -> (fail "Unknown enum (QuoteRequestType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_quoteresptype_decoder : fix_quoteresptype decoder = - string >>= (fun x -> (match string_to_quoteresptype_opt x with - | None -> (fail "Unknown enum (QuoteRespType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_quoteresponselevel_decoder : fix_quoteresponselevel decoder = - string >>= (fun x -> (match string_to_quoteresponselevel_opt x with - | None -> (fail "Unknown enum (QuoteResponseLevel) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_quotestatus_decoder : fix_quotestatus decoder = - string >>= (fun x -> (match string_to_quotestatus_opt x with - | None -> (fail "Unknown enum (QuoteStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_quotetype_decoder : fix_quotetype decoder = - string >>= (fun x -> (match string_to_quotetype_opt x with - | None -> (fail "Unknown enum (QuoteType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_registrejreasoncode_decoder : fix_registrejreasoncode decoder = - string >>= (fun x -> (match string_to_registrejreasoncode_opt x with - | None -> (fail "Unknown enum (RegistRejReasonCode) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_registstatus_decoder : fix_registstatus decoder = - string >>= (fun x -> (match string_to_registstatus_opt x with - | None -> (fail "Unknown enum (RegistStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_registtranstype_decoder : fix_registtranstype decoder = - string >>= (fun x -> (match string_to_registtranstype_opt x with - | None -> (fail "Unknown enum (RegistTransType) encoding.") - | Some y -> (succeed y) - ) +let string_to_execinst_opt (d) = + (match d with + | "NotHeld" -> (Some FIX_ExecInst_NotHeld) + | "Work" -> (Some FIX_ExecInst_Work) + | "GoAlong" -> (Some FIX_ExecInst_GoAlong) + | "OverTheDay" -> (Some FIX_ExecInst_OverTheDay) + | "Held" -> (Some FIX_ExecInst_Held) + | "ParticipateDoNotInitiate" -> (Some FIX_ExecInst_ParticipateDoNotInitiate) + | "StrictScale" -> (Some FIX_ExecInst_StrictScale) + | "TryToScale" -> (Some FIX_ExecInst_TryToScale) + | "StayOnBidSide" -> (Some FIX_ExecInst_StayOnBidSide) + | "StayOnOfferSide" -> (Some FIX_ExecInst_StayOnOfferSide) + | "NoCross" -> (Some FIX_ExecInst_NoCross) + | "OKToCross" -> (Some FIX_ExecInst_OKToCross) + | "CallFirst" -> (Some FIX_ExecInst_CallFirst) + | "PercentOfVolume" -> (Some FIX_ExecInst_PercentOfVolume) + | "DoNotIncrease" -> (Some FIX_ExecInst_DoNotIncrease) + | "DoNotReduce" -> (Some FIX_ExecInst_DoNotReduce) + | "AllOrNone" -> (Some FIX_ExecInst_AllOrNone) + | "ReinstateOnSystemFailure" -> (Some FIX_ExecInst_ReinstateOnSystemFailure) + | "InstitutionsOnly" -> (Some FIX_ExecInst_InstitutionsOnly) + | "ReinstateOnTradingHalt" -> (Some FIX_ExecInst_ReinstateOnTradingHalt) + | "CancelOnTradingHalt" -> (Some FIX_ExecInst_CancelOnTradingHalt) + | "LastPeg" -> (Some FIX_ExecInst_LastPeg) + | "MidPricePeg" -> (Some FIX_ExecInst_MidPricePeg) + | "NonNegotiable" -> (Some FIX_ExecInst_NonNegotiable) + | "OpeningPeg" -> (Some FIX_ExecInst_OpeningPeg) + | "MarketPeg" -> (Some FIX_ExecInst_MarketPeg) + | "CancelOnSystemFailure" -> (Some FIX_ExecInst_CancelOnSystemFailure) + | "PrimaryPeg" -> (Some FIX_ExecInst_PrimaryPeg) + | "Suspend" -> (Some FIX_ExecInst_Suspend) + | "CustomerDisplayInstruction" -> (Some FIX_ExecInst_CustomerDisplayInstruction) + | "Netting" -> (Some FIX_ExecInst_Netting) + | "PegToVWAP" -> (Some FIX_ExecInst_PegToVWAP) + | "TradeAlong" -> (Some FIX_ExecInst_TradeAlong) + | "TryToStop" -> (Some FIX_ExecInst_TryToStop) + | "CancelIfNotBest" -> (Some FIX_ExecInst_CancelIfNotBest) + | "TrailingStopPeg" -> (Some FIX_ExecInst_TrailingStopPeg) + | "StrictLimit" -> (Some FIX_ExecInst_StrictLimit) + | "IgnorePriceValidityChecks" -> (Some FIX_ExecInst_IgnorePriceValidityChecks) + | "PegToLimitPrice" -> (Some FIX_ExecInst_PegToLimitPrice) + | "WorkToTargetStrategy" -> (Some FIX_ExecInst_WorkToTargetStrategy) + | s -> (Some (FIX_INVALID_ExecInst s)) ) ;; -let full_enum_reporttoexch_decoder : fix_reporttoexch decoder = - string >>= (fun x -> (match string_to_reporttoexch_opt x with - | None -> (fail "Unknown enum (ReportToExch) encoding.") - | Some y -> (succeed y) - ) +let string_to_exectype_opt (d) = + (match d with + | "New" -> (Some FIX_ExecType_New) + | "DoneForDay" -> (Some FIX_ExecType_DoneForDay) + | "Canceled" -> (Some FIX_ExecType_Canceled) + | "Replaced" -> (Some FIX_ExecType_Replaced) + | "PendingCancel" -> (Some FIX_ExecType_PendingCancel) + | "Stopped" -> (Some FIX_ExecType_Stopped) + | "Rejected" -> (Some FIX_ExecType_Rejected) + | "Suspended" -> (Some FIX_ExecType_Suspended) + | "PendingNew" -> (Some FIX_ExecType_PendingNew) + | "Calculated" -> (Some FIX_ExecType_Calculated) + | "Expired" -> (Some FIX_ExecType_Expired) + | "Restated" -> (Some FIX_ExecType_Restated) + | "PendingReplace" -> (Some FIX_ExecType_PendingReplace) + | "Trade" -> (Some FIX_ExecType_Trade) + | "TradeCorrect" -> (Some FIX_ExecType_TradeCorrect) + | "TradeCancel" -> (Some FIX_ExecType_TradeCancel) + | "OrderStatus" -> (Some FIX_ExecType_OrderStatus) + | s -> (Some (FIX_INVALID_ExecType s)) ) ;; -let full_enum_resetseqnumflag_decoder : fix_resetseqnumflag decoder = - string >>= (fun x -> (match string_to_resetseqnumflag_opt x with - | None -> (fail "Unknown enum (ResetSeqNumFlag) encoding.") - | Some y -> (succeed y) - ) +let string_to_ordstatus_opt (d) = + (match d with + | "New" -> (Some FIX_OrdStatus_New) + | "PartiallyFilled" -> (Some FIX_OrdStatus_PartiallyFilled) + | "Filled" -> (Some FIX_OrdStatus_Filled) + | "DoneForDay" -> (Some FIX_OrdStatus_DoneForDay) + | "Canceled" -> (Some FIX_OrdStatus_Canceled) + | "PendingCancel" -> (Some FIX_OrdStatus_PendingCancel) + | "Stopped" -> (Some FIX_OrdStatus_Stopped) + | "Rejected" -> (Some FIX_OrdStatus_Rejected) + | "Suspended" -> (Some FIX_OrdStatus_Suspended) + | "PendingNew" -> (Some FIX_OrdStatus_PendingNew) + | "Calculated" -> (Some FIX_OrdStatus_Calculated) + | "Expired" -> (Some FIX_OrdStatus_Expired) + | "AcceptedForBidding" -> (Some FIX_OrdStatus_AcceptedForBidding) + | "PendingReplace" -> (Some FIX_OrdStatus_PendingReplace) + | "Replaced" -> (Some FIX_OrdStatus_Replaced) + | s -> (Some (FIX_INVALID_OrdStatus s)) ) ;; -let full_enum_responsetransporttype_decoder : fix_responsetransporttype decoder = - string >>= (fun x -> (match string_to_responsetransporttype_opt x with - | None -> (fail "Unknown enum (ResponseTransportType) encoding.") - | Some y -> (succeed y) - ) +let string_to_ordtype_opt (d) = + (match d with + | "Market" -> (Some FIX_OrdType_Market) + | "Limit" -> (Some FIX_OrdType_Limit) + | "Stop" -> (Some FIX_OrdType_Stop) + | "StopLimit" -> (Some FIX_OrdType_StopLimit) + | "WithOrWithout" -> (Some FIX_OrdType_WithOrWithout) + | "LimitOrBetter" -> (Some FIX_OrdType_LimitOrBetter) + | "LimitWithOrWithout" -> (Some FIX_OrdType_LimitWithOrWithout) + | "OnBasis" -> (Some FIX_OrdType_OnBasis) + | "PreviouslyQuoted" -> (Some FIX_OrdType_PreviouslyQuoted) + | "PreviouslyIndicated" -> (Some FIX_OrdType_PreviouslyIndicated) + | "ForexSwap" -> (Some FIX_OrdType_ForexSwap) + | "Funari" -> (Some FIX_OrdType_Funari) + | "MarketIfTouched" -> (Some FIX_OrdType_MarketIfTouched) + | "MarketWithLeftOverAsLimit" -> (Some FIX_OrdType_MarketWithLeftOverAsLimit) + | "PreviousFundValuationPoint" -> (Some FIX_OrdType_PreviousFundValuationPoint) + | "NextFundValuationPoint" -> (Some FIX_OrdType_NextFundValuationPoint) + | "Pegged" -> (Some FIX_OrdType_Pegged) + | "StopSpread" -> (Some FIX_OrdType_StopSpread) + | s -> (Some (FIX_INVALID_OrdType s)) ) ;; -let full_enum_roundingdirection_decoder : fix_roundingdirection decoder = - string >>= (fun x -> (match string_to_roundingdirection_opt x with - | None -> (fail "Unknown enum (RoundingDirection) encoding.") - | Some y -> (succeed y) - ) +let string_to_partysubidtype_opt (d) = + (match d with + | "Firm" -> (Some FIX_PartySubIDType_Firm) + | "Person" -> (Some FIX_PartySubIDType_Person) + | "System" -> (Some FIX_PartySubIDType_System) + | "Application" -> (Some FIX_PartySubIDType_Application) + | "FullLegalNameOfFirm" -> (Some FIX_PartySubIDType_FullLegalNameOfFirm) + | "PostalAddress" -> (Some FIX_PartySubIDType_PostalAddress) + | "PhoneNumber" -> (Some FIX_PartySubIDType_PhoneNumber) + | "EmailAddress" -> (Some FIX_PartySubIDType_EmailAddress) + | "ContactName" -> (Some FIX_PartySubIDType_ContactName) + | "SecuritiesAccountNumber" -> (Some FIX_PartySubIDType_SecuritiesAccountNumber) + | "RegistrationNumber" -> (Some FIX_PartySubIDType_RegistrationNumber) + | "RegisteredAddressForConfirmation" -> (Some FIX_PartySubIDType_RegisteredAddressForConfirmation) + | "RegulatoryStatus" -> (Some FIX_PartySubIDType_RegulatoryStatus) + | "RegistrationName" -> (Some FIX_PartySubIDType_RegistrationName) + | "CashAccountNumber" -> (Some FIX_PartySubIDType_CashAccountNumber) + | "BIC" -> (Some FIX_PartySubIDType_BIC) + | "CSDParticipantMemberCode" -> (Some FIX_PartySubIDType_CSDParticipantMemberCode) + | "RegisteredAddress" -> (Some FIX_PartySubIDType_RegisteredAddress) + | "FundAccountName" -> (Some FIX_PartySubIDType_FundAccountName) + | "TelexNumber" -> (Some FIX_PartySubIDType_TelexNumber) + | "FaxNumber" -> (Some FIX_PartySubIDType_FaxNumber) + | "SecuritiesAccountName" -> (Some FIX_PartySubIDType_SecuritiesAccountName) + | "CashAccountName" -> (Some FIX_PartySubIDType_CashAccountName) + | "Department" -> (Some FIX_PartySubIDType_Department) + | "LocationDesk" -> (Some FIX_PartySubIDType_LocationDesk) + | "PositionAccountType" -> (Some FIX_PartySubIDType_PositionAccountType) + | s -> (Some (FIX_INVALID_PartySubIDType s)) ) ;; -let full_enum_routingtype_decoder : fix_routingtype decoder = - string >>= (fun x -> (match string_to_routingtype_opt x with - | None -> (fail "Unknown enum (RoutingType) encoding.") - | Some y -> (succeed y) - ) +let string_to_side_opt (d) = + (match d with + | "Buy" -> (Some FIX_Side_Buy) + | "Sell" -> (Some FIX_Side_Sell) + | "BuyMinus" -> (Some FIX_Side_BuyMinus) + | "SellPlus" -> (Some FIX_Side_SellPlus) + | "SellShort" -> (Some FIX_Side_SellShort) + | "SellShortExempt" -> (Some FIX_Side_SellShortExempt) + | "Undisclosed" -> (Some FIX_Side_Undisclosed) + | "Cross" -> (Some FIX_Side_Cross) + | "CrossShort" -> (Some FIX_Side_CrossShort) + | "CrossShortExempt" -> (Some FIX_Side_CrossShortExempt) + | "AsDefined" -> (Some FIX_Side_AsDefined) + | "Opposite" -> (Some FIX_Side_Opposite) + | "Subscribe" -> (Some FIX_Side_Subscribe) + | "Redeem" -> (Some FIX_Side_Redeem) + | "Lend" -> (Some FIX_Side_Lend) + | "Borrow" -> (Some FIX_Side_Borrow) + | s -> (Some (FIX_INVALID_Side s)) ) ;; -let full_enum_scope_decoder : fix_scope list decoder = - list (string >>= (fun x -> (match string_to_scope_opt x with - | None -> (fail "Unknown enum (Scope) encoding.") - | Some y -> (succeed y) +let full_enum_execinst_decoder : fix_execinst list decoder = + list (string >>= (fun x -> (match string_to_execinst_opt x with + | None -> (fail "Unknown enum (ExecInst) encoding.") + | Some y -> (succeed y) ) )) ;; -let full_enum_securityidsource_decoder : fix_securityidsource decoder = - string >>= (fun x -> (match string_to_securityidsource_opt x with - | None -> (fail "Unknown enum (SecurityIDSource) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_securitylistrequesttype_decoder : fix_securitylistrequesttype decoder = - string >>= (fun x -> (match string_to_securitylistrequesttype_opt x with - | None -> (fail "Unknown enum (SecurityListRequestType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_securityrequestresult_decoder : fix_securityrequestresult decoder = - string >>= (fun x -> (match string_to_securityrequestresult_opt x with - | None -> (fail "Unknown enum (SecurityRequestResult) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_securityrequesttype_decoder : fix_securityrequesttype decoder = - string >>= (fun x -> (match string_to_securityrequesttype_opt x with - | None -> (fail "Unknown enum (SecurityRequestType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_securityresponsetype_decoder : fix_securityresponsetype decoder = - string >>= (fun x -> (match string_to_securityresponsetype_opt x with - | None -> (fail "Unknown enum (SecurityResponseType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_securitytradingstatus_decoder : fix_securitytradingstatus decoder = - string >>= (fun x -> (match string_to_securitytradingstatus_opt x with - | None -> (fail "Unknown enum (SecurityTradingStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_securitytype_decoder : fix_securitytype decoder = - string >>= (fun x -> (match string_to_securitytype_opt x with - | None -> (fail "Unknown enum (SecurityType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_settlcurrfxratecalc_decoder : fix_settlcurrfxratecalc decoder = - string >>= (fun x -> (match string_to_settlcurrfxratecalc_opt x with - | None -> (fail "Unknown enum (SettlCurrFxRateCalc) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_settldeliverytype_decoder : fix_settldeliverytype decoder = - string >>= (fun x -> (match string_to_settldeliverytype_opt x with - | None -> (fail "Unknown enum (SettlDeliveryType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_settlinstmode_decoder : fix_settlinstmode decoder = - string >>= (fun x -> (match string_to_settlinstmode_opt x with - | None -> (fail "Unknown enum (SettlInstMode) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_settlinstreqrejcode_decoder : fix_settlinstreqrejcode decoder = - string >>= (fun x -> (match string_to_settlinstreqrejcode_opt x with - | None -> (fail "Unknown enum (SettlInstReqRejCode) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_settlinstsource_decoder : fix_settlinstsource decoder = - string >>= (fun x -> (match string_to_settlinstsource_opt x with - | None -> (fail "Unknown enum (SettlInstSource) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_settlinsttranstype_decoder : fix_settlinsttranstype decoder = - string >>= (fun x -> (match string_to_settlinsttranstype_opt x with - | None -> (fail "Unknown enum (SettlInstTransType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_settlpricetype_decoder : fix_settlpricetype decoder = - string >>= (fun x -> (match string_to_settlpricetype_opt x with - | None -> (fail "Unknown enum (SettlPriceType) encoding.") - | Some y -> (succeed y) +let full_enum_exectype_decoder : fix_exectype decoder = + string >>= (fun x -> (match string_to_exectype_opt x with + | None -> (fail "Unknown enum (ExecType) encoding.") + | Some y -> (succeed y) ) ) ;; -let full_enum_settlsessid_decoder : fix_settlsessid decoder = - string >>= (fun x -> (match string_to_settlsessid_opt x with - | None -> (fail "Unknown enum (SettlSessID) encoding.") - | Some y -> (succeed y) +let full_enum_ordstatus_decoder : fix_ordstatus decoder = + string >>= (fun x -> (match string_to_ordstatus_opt x with + | None -> (fail "Unknown enum (OrdStatus) encoding.") + | Some y -> (succeed y) ) ) ;; -let full_enum_settltype_decoder : fix_settltype decoder = - string >>= (fun x -> (match string_to_settltype_opt x with - | None -> (fail "Unknown enum (SettlType) encoding.") - | Some y -> (succeed y) +let full_enum_ordtype_decoder : fix_ordtype decoder = + string >>= (fun x -> (match string_to_ordtype_opt x with + | None -> (fail "Unknown enum (OrdType) encoding.") + | Some y -> (succeed y) ) ) ;; -let full_enum_shortsalereason_decoder : fix_shortsalereason decoder = - string >>= (fun x -> (match string_to_shortsalereason_opt x with - | None -> (fail "Unknown enum (ShortSaleReason) encoding.") - | Some y -> (succeed y) +let full_enum_partysubidtype_decoder : fix_partysubidtype decoder = + string >>= (fun x -> (match string_to_partysubidtype_opt x with + | None -> (fail "Unknown enum (PartySubIDType) encoding.") + | Some y -> (succeed y) ) ) ;; let full_enum_side_decoder : fix_side decoder = - string >>= (fun x -> (match string_to_side_opt x with - | None -> (fail "Unknown enum (Side) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_sidemultilegreportingtype_decoder : fix_sidemultilegreportingtype decoder = - string >>= (fun x -> (match string_to_sidemultilegreportingtype_opt x with - | None -> (fail "Unknown enum (SideMultiLegReportingType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_sidevalueind_decoder : fix_sidevalueind decoder = - string >>= (fun x -> (match string_to_sidevalueind_opt x with - | None -> (fail "Unknown enum (SideValueInd) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_solicitedflag_decoder : fix_solicitedflag decoder = - string >>= (fun x -> (match string_to_solicitedflag_opt x with - | None -> (fail "Unknown enum (SolicitedFlag) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_standinstdbtype_decoder : fix_standinstdbtype decoder = - string >>= (fun x -> (match string_to_standinstdbtype_opt x with - | None -> (fail "Unknown enum (StandInstDbType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_statusvalue_decoder : fix_statusvalue decoder = - string >>= (fun x -> (match string_to_statusvalue_opt x with - | None -> (fail "Unknown enum (StatusValue) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_stipulationtype_decoder : fix_stipulationtype decoder = - string >>= (fun x -> (match string_to_stipulationtype_opt x with - | None -> (fail "Unknown enum (StipulationType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_subscriptionrequesttype_decoder : fix_subscriptionrequesttype decoder = - string >>= (fun x -> (match string_to_subscriptionrequesttype_opt x with - | None -> (fail "Unknown enum (SubscriptionRequestType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_targetstrategy_decoder : fix_targetstrategy decoder = - string >>= (fun x -> (match string_to_targetstrategy_opt x with - | None -> (fail "Unknown enum (TargetStrategy) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_taxadvantagetype_decoder : fix_taxadvantagetype decoder = - string >>= (fun x -> (match string_to_taxadvantagetype_opt x with - | None -> (fail "Unknown enum (TaxAdvantageType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_terminationtype_decoder : fix_terminationtype decoder = - string >>= (fun x -> (match string_to_terminationtype_opt x with - | None -> (fail "Unknown enum (TerminationType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_testmessageindicator_decoder : fix_testmessageindicator decoder = - string >>= (fun x -> (match string_to_testmessageindicator_opt x with - | None -> (fail "Unknown enum (TestMessageIndicator) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_tickdirection_decoder : fix_tickdirection decoder = - string >>= (fun x -> (match string_to_tickdirection_opt x with - | None -> (fail "Unknown enum (TickDirection) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_timeinforce_decoder : fix_timeinforce decoder = - string >>= (fun x -> (match string_to_timeinforce_opt x with - | None -> (fail "Unknown enum (TimeInForce) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_tradsesmethod_decoder : fix_tradsesmethod decoder = - string >>= (fun x -> (match string_to_tradsesmethod_opt x with - | None -> (fail "Unknown enum (TradSesMethod) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_tradsesmode_decoder : fix_tradsesmode decoder = - string >>= (fun x -> (match string_to_tradsesmode_opt x with - | None -> (fail "Unknown enum (TradSesMode) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_tradsesstatus_decoder : fix_tradsesstatus decoder = - string >>= (fun x -> (match string_to_tradsesstatus_opt x with - | None -> (fail "Unknown enum (TradSesStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_tradsesstatusrejreason_decoder : fix_tradsesstatusrejreason decoder = - string >>= (fun x -> (match string_to_tradsesstatusrejreason_opt x with - | None -> (fail "Unknown enum (TradSesStatusRejReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_tradeallocindicator_decoder : fix_tradeallocindicator decoder = - string >>= (fun x -> (match string_to_tradeallocindicator_opt x with - | None -> (fail "Unknown enum (TradeAllocIndicator) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_tradecondition_decoder : fix_tradecondition list decoder = - list (string >>= (fun x -> (match string_to_tradecondition_opt x with - | None -> (fail "Unknown enum (TradeCondition) encoding.") - | Some y -> (succeed y) - ) - )) -;; - -let full_enum_tradereportrejectreason_decoder : fix_tradereportrejectreason decoder = - string >>= (fun x -> (match string_to_tradereportrejectreason_opt x with - | None -> (fail "Unknown enum (TradeReportRejectReason) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_tradereporttype_decoder : fix_tradereporttype decoder = - string >>= (fun x -> (match string_to_tradereporttype_opt x with - | None -> (fail "Unknown enum (TradeReportType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_traderequestresult_decoder : fix_traderequestresult decoder = - string >>= (fun x -> (match string_to_traderequestresult_opt x with - | None -> (fail "Unknown enum (TradeRequestResult) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_traderequeststatus_decoder : fix_traderequeststatus decoder = - string >>= (fun x -> (match string_to_traderequeststatus_opt x with - | None -> (fail "Unknown enum (TradeRequestStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_traderequesttype_decoder : fix_traderequesttype decoder = - string >>= (fun x -> (match string_to_traderequesttype_opt x with - | None -> (fail "Unknown enum (TradeRequestType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_tradedflatswitch_decoder : fix_tradedflatswitch decoder = - string >>= (fun x -> (match string_to_tradedflatswitch_opt x with - | None -> (fail "Unknown enum (TradedFlatSwitch) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_trdregtimestamptype_decoder : fix_trdregtimestamptype decoder = - string >>= (fun x -> (match string_to_trdregtimestamptype_opt x with - | None -> (fail "Unknown enum (TrdRegTimestampType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_trdrptstatus_decoder : fix_trdrptstatus decoder = - string >>= (fun x -> (match string_to_trdrptstatus_opt x with - | None -> (fail "Unknown enum (TrdRptStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_trdtype_decoder : fix_trdtype decoder = - string >>= (fun x -> (match string_to_trdtype_opt x with - | None -> (fail "Unknown enum (TrdType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_unsolicitedindicator_decoder : fix_unsolicitedindicator decoder = - string >>= (fun x -> (match string_to_unsolicitedindicator_opt x with - | None -> (fail "Unknown enum (UnsolicitedIndicator) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_urgency_decoder : fix_urgency decoder = - string >>= (fun x -> (match string_to_urgency_opt x with - | None -> (fail "Unknown enum (Urgency) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_userrequesttype_decoder : fix_userrequesttype decoder = - string >>= (fun x -> (match string_to_userrequesttype_opt x with - | None -> (fail "Unknown enum (UserRequestType) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_userstatus_decoder : fix_userstatus decoder = - string >>= (fun x -> (match string_to_userstatus_opt x with - | None -> (fail "Unknown enum (UserStatus) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_workingindicator_decoder : fix_workingindicator decoder = - string >>= (fun x -> (match string_to_workingindicator_opt x with - | None -> (fail "Unknown enum (WorkingIndicator) encoding.") - | Some y -> (succeed y) - ) - ) -;; - -let full_enum_yieldtype_decoder : fix_yieldtype decoder = - string >>= (fun x -> (match string_to_yieldtype_opt x with - | None -> (fail "Unknown enum (YieldType) encoding.") - | Some y -> (succeed y) + string >>= (fun x -> (match string_to_side_opt x with + | None -> (fail "Unknown enum (Side) encoding.") + | Some y -> (succeed y) ) ) ;; diff --git a/src-protocol-exts-pp/full_app_enums_json.iml b/src-protocol-exts-pp/full_app_enums_json.iml index 864d667f..0347c452 100644 --- a/src-protocol-exts-pp/full_app_enums_json.iml +++ b/src-protocol-exts-pp/full_app_enums_json.iml @@ -1,5517 +1,244 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "../src-protocol-exts/full_app_enums.iml"] -[@@@program] -open Full_app_enums;; -open Yojson.Basic;; - -let week_to_string (d) = - (match d with - | FIX_week_noweek -> "noweek" - | FIX_week_w1 -> "w1" - | FIX_week_w2 -> "w2" - | FIX_week_w3 -> "w3" - | FIX_week_w4 -> "w4" - | FIX_week_w5 -> "w5" - ) -;; - -let accounttype_to_string (d) = - (match d with - | FIX_AccountType_CarriedCustomerSide -> "CarriedCustomerSide" - | FIX_AccountType_CarriedNonCustomerSide -> "CarriedNonCustomerSide" - | FIX_AccountType_HouseTrader -> "HouseTrader" - | FIX_AccountType_FloorTrader -> "FloorTrader" - | FIX_AccountType_CarriedNonCustomerSideCrossMargined -> "CarriedNonCustomerSideCrossMargined" - | FIX_AccountType_HouseTraderCrossMargined -> "HouseTraderCrossMargined" - | FIX_AccountType_JointBackOfficeAccount -> "JointBackOfficeAccount" - ) -;; - -let acctidsource_to_string (d) = - (match d with - | FIX_AcctIDSource_BIC -> "BIC" - | FIX_AcctIDSource_SIDCode -> "SIDCode" - | FIX_AcctIDSource_TFM -> "TFM" - | FIX_AcctIDSource_OMGEO -> "OMGEO" - | FIX_AcctIDSource_DTCCCode -> "DTCCCode" - | FIX_AcctIDSource_Other -> "Other" - ) -;; - -let adjustment_to_string (d) = - (match d with - | FIX_Adjustment_Cancel -> "Cancel" - | FIX_Adjustment_Error -> "Error" - | FIX_Adjustment_Correction -> "Correction" - ) -;; - -let adjustmenttype_to_string (d) = - (match d with - | FIX_AdjustmentType_ProcessRequestAsMarginDisposition -> "ProcessRequestAsMarginDisposition" - | FIX_AdjustmentType_DeltaPlus -> "DeltaPlus" - | FIX_AdjustmentType_DeltaMinus -> "DeltaMinus" - | FIX_AdjustmentType_Final -> "Final" - ) -;; - -let advside_to_string (d) = - (match d with - | FIX_AdvSide_Buy -> "Buy" - | FIX_AdvSide_Sell -> "Sell" - | FIX_AdvSide_Cross -> "Cross" - | FIX_AdvSide_Trade -> "Trade" - ) -;; - -let advtranstype_to_string (d) = - (match d with - | FIX_AdvTransType_New -> "New" - | FIX_AdvTransType_Cancel -> "Cancel" - | FIX_AdvTransType_Replace -> "Replace" - ) -;; - -let affirmstatus_to_string (d) = - (match d with - | FIX_AffirmStatus_Received -> "Received" - | FIX_AffirmStatus_ConfirmRejected -> "ConfirmRejected" - | FIX_AffirmStatus_Affirmed -> "Affirmed" - ) -;; - -let aggregatedbook_to_string (d) = - (match d with - | FIX_AggregatedBook_BookEntriesToBeAggregated -> "BookEntriesToBeAggregated" - | FIX_AggregatedBook_BookEntriesShouldNotBeAggregated -> "BookEntriesShouldNotBeAggregated" - ) -;; - -let allocaccounttype_to_string (d) = - (match d with - | FIX_AllocAccountType_CarriedCustomerSide -> "CarriedCustomerSide" - | FIX_AllocAccountType_CarriedNonCustomerSide -> "CarriedNonCustomerSide" - | FIX_AllocAccountType_HouseTrader -> "HouseTrader" - | FIX_AllocAccountType_FloorTrader -> "FloorTrader" - | FIX_AllocAccountType_CarriedNonCustomerSideCrossMargined -> "CarriedNonCustomerSideCrossMargined" - | FIX_AllocAccountType_HouseTraderCrossMargined -> "HouseTraderCrossMargined" - | FIX_AllocAccountType_JointBackOfficeAccount -> "JointBackOfficeAccount" - ) -;; - -let alloccancreplacereason_to_string (d) = - (match d with - | FIX_AllocCancReplaceReason_OriginalDetailsIncomplete -> "OriginalDetailsIncomplete" - | FIX_AllocCancReplaceReason_ChangeInUnderlyingOrderDetails -> "ChangeInUnderlyingOrderDetails" - | FIX_AllocCancReplaceReason_Other -> "Other" - ) -;; - -let allochandlinst_to_string (d) = - (match d with - | FIX_AllocHandlInst_Match -> "Match" - | FIX_AllocHandlInst_Forward -> "Forward" - | FIX_AllocHandlInst_ForwardAndMatch -> "ForwardAndMatch" - ) -;; - -let allocintermedreqtype_to_string (d) = - (match d with - | FIX_AllocIntermedReqType_PendingAccept -> "PendingAccept" - | FIX_AllocIntermedReqType_PendingRelease -> "PendingRelease" - | FIX_AllocIntermedReqType_PendingReversal -> "PendingReversal" - | FIX_AllocIntermedReqType_Accept -> "Accept" - | FIX_AllocIntermedReqType_BlockLevelReject -> "BlockLevelReject" - | FIX_AllocIntermedReqType_AccountLevelReject -> "AccountLevelReject" - ) -;; - -let alloclinktype_to_string (d) = - (match d with - | FIX_AllocLinkType_FXNetting -> "FXNetting" - | FIX_AllocLinkType_FXSwap -> "FXSwap" - ) -;; - -let allocnoorderstype_to_string (d) = - (match d with - | FIX_AllocNoOrdersType_NotSpecified -> "NotSpecified" - | FIX_AllocNoOrdersType_ExplicitListProvided -> "ExplicitListProvided" - ) -;; - -let allocrejcode_to_string (d) = - (match d with - | FIX_AllocRejCode_UnknownAccount -> "UnknownAccount" - | FIX_AllocRejCode_IncorrectQuantity -> "IncorrectQuantity" - | FIX_AllocRejCode_IncorrectAveragegPrice -> "IncorrectAveragegPrice" - | FIX_AllocRejCode_UnknownExecutingBrokerMnemonic -> "UnknownExecutingBrokerMnemonic" - | FIX_AllocRejCode_CommissionDifference -> "CommissionDifference" - | FIX_AllocRejCode_UnknownOrderID -> "UnknownOrderID" - | FIX_AllocRejCode_UnknownListID -> "UnknownListID" - | FIX_AllocRejCode_OtherSeeText -> "OtherSeeText" - | FIX_AllocRejCode_IncorrectAllocatedQuantity -> "IncorrectAllocatedQuantity" - | FIX_AllocRejCode_CalculationDifference -> "CalculationDifference" - | FIX_AllocRejCode_UnknownOrStaleExecID -> "UnknownOrStaleExecID" - | FIX_AllocRejCode_MismatchedData -> "MismatchedData" - | FIX_AllocRejCode_UnknownClOrdID -> "UnknownClOrdID" - | FIX_AllocRejCode_WarehouseRequestRejected -> "WarehouseRequestRejected" - ) -;; - -let allocreporttype_to_string (d) = - (match d with - | FIX_AllocReportType_SellsideCalculatedUsingPreliminary -> "SellsideCalculatedUsingPreliminary" - | FIX_AllocReportType_SellsideCalculatedWithoutPreliminary -> "SellsideCalculatedWithoutPreliminary" - | FIX_AllocReportType_WarehouseRecap -> "WarehouseRecap" - | FIX_AllocReportType_RequestToIntermediary -> "RequestToIntermediary" - ) -;; - -let allocsettlinsttype_to_string (d) = - (match d with - | FIX_AllocSettlInstType_UseDefaultInstructions -> "UseDefaultInstructions" - | FIX_AllocSettlInstType_DeriveFromParametersProvided -> "DeriveFromParametersProvided" - | FIX_AllocSettlInstType_FullDetailsProvided -> "FullDetailsProvided" - | FIX_AllocSettlInstType_SSIDBIDsProvided -> "SSIDBIDsProvided" - | FIX_AllocSettlInstType_PhoneForInstructions -> "PhoneForInstructions" - ) -;; - -let allocstatus_to_string (d) = - (match d with - | FIX_AllocStatus_Accepted -> "Accepted" - | FIX_AllocStatus_BlockLevelReject -> "BlockLevelReject" - | FIX_AllocStatus_AccountLevelReject -> "AccountLevelReject" - | FIX_AllocStatus_Received -> "Received" - | FIX_AllocStatus_Incomplete -> "Incomplete" - | FIX_AllocStatus_RejectedByIntermediary -> "RejectedByIntermediary" - ) -;; - -let alloctranstype_to_string (d) = - (match d with - | FIX_AllocTransType_New -> "New" - | FIX_AllocTransType_Replace -> "Replace" - | FIX_AllocTransType_Cancel -> "Cancel" - ) -;; - -let alloctype_to_string (d) = - (match d with - | FIX_AllocType_Calculated -> "Calculated" - | FIX_AllocType_Preliminary -> "Preliminary" - | FIX_AllocType_ReadyToBook -> "ReadyToBook" - | FIX_AllocType_WarehouseInstruction -> "WarehouseInstruction" - | FIX_AllocType_RequestToIntermediary -> "RequestToIntermediary" - ) -;; - -let applqueueaction_to_string (d) = - (match d with - | FIX_ApplQueueAction_NoActionTaken -> "NoActionTaken" - | FIX_ApplQueueAction_QueueFlushed -> "QueueFlushed" - | FIX_ApplQueueAction_OverlayLast -> "OverlayLast" - | FIX_ApplQueueAction_EndSession -> "EndSession" - ) -;; - -let applqueueresolution_to_string (d) = - (match d with - | FIX_ApplQueueResolution_NoActionTaken -> "NoActionTaken" - | FIX_ApplQueueResolution_QueueFlushed -> "QueueFlushed" - | FIX_ApplQueueResolution_OverlayLast -> "OverlayLast" - | FIX_ApplQueueResolution_EndSession -> "EndSession" - ) -;; - -let assignmentmethod_to_string (d) = - (match d with - | FIX_AssignmentMethod_Random -> "Random" - | FIX_AssignmentMethod_ProRata -> "ProRata" - ) -;; - -let avgpxindicator_to_string (d) = - (match d with - | FIX_AvgPxIndicator_NoAveragePricing -> "NoAveragePricing" - | FIX_AvgPxIndicator_Trade -> "Trade" - | FIX_AvgPxIndicator_LastTrade -> "LastTrade" - ) -;; - -let basispxtype_to_string (d) = - (match d with - | FIX_BasisPxType_ClosingPriceAtMorningSession -> "ClosingPriceAtMorningSession" - | FIX_BasisPxType_ClosingPrice -> "ClosingPrice" - | FIX_BasisPxType_CurrentPrice -> "CurrentPrice" - | FIX_BasisPxType_SQ -> "SQ" - | FIX_BasisPxType_VWAPThroughADay -> "VWAPThroughADay" - | FIX_BasisPxType_VWAPThroughAMorningSession -> "VWAPThroughAMorningSession" - | FIX_BasisPxType_VWAPThroughAnAfternoonSession -> "VWAPThroughAnAfternoonSession" - | FIX_BasisPxType_VWAPThroughADayExcept -> "VWAPThroughADayExcept" - | FIX_BasisPxType_VWAPThroughAMorningSessionExcept -> "VWAPThroughAMorningSessionExcept" - | FIX_BasisPxType_VWAPThroughAnAfternoonSessionExcept -> "VWAPThroughAnAfternoonSessionExcept" - | FIX_BasisPxType_Strike -> "Strike" - | FIX_BasisPxType_Open -> "Open" - | FIX_BasisPxType_Others -> "Others" - ) -;; - -let biddescriptortype_to_string (d) = - (match d with - | FIX_BidDescriptorType_Sector -> "Sector" - | FIX_BidDescriptorType_Country -> "Country" - | FIX_BidDescriptorType_Index -> "Index" - ) -;; - -let bidrequesttranstype_to_string (d) = - (match d with - | FIX_BidRequestTransType_New -> "New" - | FIX_BidRequestTransType_Cancel -> "Cancel" - ) -;; - -let bidtradetype_to_string (d) = - (match d with - | FIX_BidTradeType_RiskTrade -> "RiskTrade" - | FIX_BidTradeType_VWAPGuarantee -> "VWAPGuarantee" - | FIX_BidTradeType_Agency -> "Agency" - | FIX_BidTradeType_GuaranteedClose -> "GuaranteedClose" - ) -;; - -let bidtype_to_string (d) = - (match d with - | FIX_BidType_NonDisclosed -> "NonDisclosed" - | FIX_BidType_Disclosed -> "Disclosed" - | FIX_BidType_NoBiddingProcess -> "NoBiddingProcess" - ) -;; - -let bookingtype_to_string (d) = - (match d with - | FIX_BookingType_RegularBooking -> "RegularBooking" - | FIX_BookingType_CFD -> "CFD" - | FIX_BookingType_TotalReturnSwap -> "TotalReturnSwap" - ) -;; - -let bookingunit_to_string (d) = - (match d with - | FIX_BookingUnit_EachPartialExecutionIsABookableUnit -> "EachPartialExecutionIsABookableUnit" - | FIX_BookingUnit_AggregatePartialExecutionsOnThisOrder -> "AggregatePartialExecutionsOnThisOrder" - | FIX_BookingUnit_AggregateExecutionsForThisSymbol -> "AggregateExecutionsForThisSymbol" - ) -;; - -let cpprogram_to_string (d) = - (match d with - | FIX_CPProgram_Program3a3 -> "Program3a3" - | FIX_CPProgram_Program42 -> "Program42" - | FIX_CPProgram_Other -> "Other" - ) -;; - -let cancellationrights_to_string (d) = - (match d with - | FIX_CancellationRights_Yes -> "Yes" - | FIX_CancellationRights_NoExecutionOnly -> "NoExecutionOnly" - | FIX_CancellationRights_NoWaiverAgreement -> "NoWaiverAgreement" - | FIX_CancellationRights_NoInstitutional -> "NoInstitutional" - ) -;; - -let cashmargin_to_string (d) = - (match d with - | FIX_CashMargin_Cash -> "Cash" - | FIX_CashMargin_MarginOpen -> "MarginOpen" - | FIX_CashMargin_MarginClose -> "MarginClose" - ) -;; - -let clearingfeeindicator_to_string (d) = - (match d with - | FIX_ClearingFeeIndicator_CBOEMember -> "CBOEMember" - | FIX_ClearingFeeIndicator_NonMemberAndCustomer -> "NonMemberAndCustomer" - | FIX_ClearingFeeIndicator_EquityMemberAndClearingMember -> "EquityMemberAndClearingMember" - | FIX_ClearingFeeIndicator_FullAndAssociateMember -> "FullAndAssociateMember" - | FIX_ClearingFeeIndicator_Firms106HAnd106J -> "Firms106HAnd106J" - | FIX_ClearingFeeIndicator_GIM -> "GIM" - | FIX_ClearingFeeIndicator_Lessee106FEmployees -> "Lessee106FEmployees" - | FIX_ClearingFeeIndicator_AllOtherOwnershipTypes -> "AllOtherOwnershipTypes" - | FIX_ClearingFeeIndicator_FirstYearDelegate -> "FirstYearDelegate" - | FIX_ClearingFeeIndicator_SecondYearDelegate -> "SecondYearDelegate" - | FIX_ClearingFeeIndicator_ThirdYearDelegate -> "ThirdYearDelegate" - | FIX_ClearingFeeIndicator_FourthYearDelegate -> "FourthYearDelegate" - | FIX_ClearingFeeIndicator_FifthYearDelegate -> "FifthYearDelegate" - | FIX_ClearingFeeIndicator_SixthYearDelegate -> "SixthYearDelegate" - ) -;; - -let clearinginstruction_to_string (d) = - (match d with - | FIX_ClearingInstruction_ProcessNormally -> "ProcessNormally" - | FIX_ClearingInstruction_ExcludeFromAllNetting -> "ExcludeFromAllNetting" - | FIX_ClearingInstruction_BilateralNettingOnly -> "BilateralNettingOnly" - | FIX_ClearingInstruction_ExClearing -> "ExClearing" - | FIX_ClearingInstruction_SpecialTrade -> "SpecialTrade" - | FIX_ClearingInstruction_MultilateralNetting -> "MultilateralNetting" - | FIX_ClearingInstruction_ClearAgainstCentralCounterparty -> "ClearAgainstCentralCounterparty" - | FIX_ClearingInstruction_ExcludeFromCentralCounterparty -> "ExcludeFromCentralCounterparty" - | FIX_ClearingInstruction_ManualMode -> "ManualMode" - | FIX_ClearingInstruction_AutomaticPostingMode -> "AutomaticPostingMode" - | FIX_ClearingInstruction_AutomaticGiveUpMode -> "AutomaticGiveUpMode" - | FIX_ClearingInstruction_QualifiedServiceRepresentativeQSR -> "QualifiedServiceRepresentativeQSR" - | FIX_ClearingInstruction_CustomerTrade -> "CustomerTrade" - | FIX_ClearingInstruction_SelfClearing -> "SelfClearing" - ) -;; - -let collaction_to_string (d) = - (match d with - | FIX_CollAction_Retain -> "Retain" - | FIX_CollAction_Add -> "Add" - | FIX_CollAction_Remove -> "Remove" - ) -;; - -let collasgnreason_to_string (d) = - (match d with - | FIX_CollAsgnReason_Initial -> "Initial" - | FIX_CollAsgnReason_Scheduled -> "Scheduled" - | FIX_CollAsgnReason_TimeWarning -> "TimeWarning" - | FIX_CollAsgnReason_MarginDeficiency -> "MarginDeficiency" - | FIX_CollAsgnReason_MarginExcess -> "MarginExcess" - | FIX_CollAsgnReason_ForwardCollateralDemand -> "ForwardCollateralDemand" - | FIX_CollAsgnReason_EventOfDefault -> "EventOfDefault" - | FIX_CollAsgnReason_AdverseTaxEvent -> "AdverseTaxEvent" - ) -;; - -let collasgnrejectreason_to_string (d) = - (match d with - | FIX_CollAsgnRejectReason_UnknownDeal -> "UnknownDeal" - | FIX_CollAsgnRejectReason_UnknownOrInvalidInstrument -> "UnknownOrInvalidInstrument" - | FIX_CollAsgnRejectReason_UnauthorizedTransaction -> "UnauthorizedTransaction" - | FIX_CollAsgnRejectReason_InsufficientCollateral -> "InsufficientCollateral" - | FIX_CollAsgnRejectReason_InvalidTypeOfCollateral -> "InvalidTypeOfCollateral" - | FIX_CollAsgnRejectReason_ExcessiveSubstitution -> "ExcessiveSubstitution" - | FIX_CollAsgnRejectReason_Other -> "Other" - ) -;; - -let collasgnresptype_to_string (d) = - (match d with - | FIX_CollAsgnRespType_Received -> "Received" - | FIX_CollAsgnRespType_Accepted -> "Accepted" - | FIX_CollAsgnRespType_Declined -> "Declined" - | FIX_CollAsgnRespType_Rejected -> "Rejected" - ) -;; - -let collasgntranstype_to_string (d) = - (match d with - | FIX_CollAsgnTransType_New -> "New" - | FIX_CollAsgnTransType_Replace -> "Replace" - | FIX_CollAsgnTransType_Cancel -> "Cancel" - | FIX_CollAsgnTransType_Release -> "Release" - | FIX_CollAsgnTransType_Reverse -> "Reverse" - ) -;; - -let collinquiryqualifier_to_string (d) = - (match d with - | FIX_CollInquiryQualifier_TradeDate -> "TradeDate" - | FIX_CollInquiryQualifier_GCInstrument -> "GCInstrument" - | FIX_CollInquiryQualifier_CollateralInstrument -> "CollateralInstrument" - | FIX_CollInquiryQualifier_SubstitutionEligible -> "SubstitutionEligible" - | FIX_CollInquiryQualifier_NotAssigned -> "NotAssigned" - | FIX_CollInquiryQualifier_PartiallyAssigned -> "PartiallyAssigned" - | FIX_CollInquiryQualifier_FullyAssigned -> "FullyAssigned" - | FIX_CollInquiryQualifier_OutstandingTrades -> "OutstandingTrades" - ) -;; - -let collinquiryresult_to_string (d) = - (match d with - | FIX_CollInquiryResult_Successful -> "Successful" - | FIX_CollInquiryResult_InvalidOrUnknownInstrument -> "InvalidOrUnknownInstrument" - | FIX_CollInquiryResult_InvalidOrUnknownCollateralType -> "InvalidOrUnknownCollateralType" - | FIX_CollInquiryResult_InvalidParties -> "InvalidParties" - | FIX_CollInquiryResult_InvalidTransportTypeRequested -> "InvalidTransportTypeRequested" - | FIX_CollInquiryResult_InvalidDestinationRequested -> "InvalidDestinationRequested" - | FIX_CollInquiryResult_NoCollateralFoundForTheTradeSpecified -> "NoCollateralFoundForTheTradeSpecified" - | FIX_CollInquiryResult_NoCollateralFoundForTheOrderSpecified -> "NoCollateralFoundForTheOrderSpecified" - | FIX_CollInquiryResult_CollateralInquiryTypeNotSupported -> "CollateralInquiryTypeNotSupported" - | FIX_CollInquiryResult_UnauthorizedForCollateralInquiry -> "UnauthorizedForCollateralInquiry" - | FIX_CollInquiryResult_Other -> "Other" - ) -;; - -let collinquirystatus_to_string (d) = - (match d with - | FIX_CollInquiryStatus_Accepted -> "Accepted" - | FIX_CollInquiryStatus_AcceptedWithWarnings -> "AcceptedWithWarnings" - | FIX_CollInquiryStatus_Completed -> "Completed" - | FIX_CollInquiryStatus_CompletedWithWarnings -> "CompletedWithWarnings" - | FIX_CollInquiryStatus_Rejected -> "Rejected" - ) -;; - -let collstatus_to_string (d) = - (match d with - | FIX_CollStatus_Unassigned -> "Unassigned" - | FIX_CollStatus_PartiallyAssigned -> "PartiallyAssigned" - | FIX_CollStatus_AssignmentProposed -> "AssignmentProposed" - | FIX_CollStatus_Assigned -> "Assigned" - | FIX_CollStatus_Challenged -> "Challenged" - ) -;; - -let commtype_to_string (d) = - (match d with - | FIX_CommType_PerUnit -> "PerUnit" - | FIX_CommType_Percent -> "Percent" - | FIX_CommType_Absolute -> "Absolute" - | FIX_CommType_PercentageWaivedCashDiscount -> "PercentageWaivedCashDiscount" - | FIX_CommType_PercentageWaivedEnhancedUnits -> "PercentageWaivedEnhancedUnits" - | FIX_CommType_PointsPerBondOrContract -> "PointsPerBondOrContract" - ) -;; - -let confirmrejreason_to_string (d) = - (match d with - | FIX_ConfirmRejReason_MismatchedAccount -> "MismatchedAccount" - | FIX_ConfirmRejReason_MissingSettlementInstructions -> "MissingSettlementInstructions" - | FIX_ConfirmRejReason_Other -> "Other" - ) -;; - -let confirmstatus_to_string (d) = - (match d with - | FIX_ConfirmStatus_Received -> "Received" - | FIX_ConfirmStatus_MismatchedAccount -> "MismatchedAccount" - | FIX_ConfirmStatus_MissingSettlementInstructions -> "MissingSettlementInstructions" - | FIX_ConfirmStatus_Confirmed -> "Confirmed" - | FIX_ConfirmStatus_RequestRejected -> "RequestRejected" - ) -;; - -let confirmtranstype_to_string (d) = - (match d with - | FIX_ConfirmTransType_New -> "New" - | FIX_ConfirmTransType_Replace -> "Replace" - | FIX_ConfirmTransType_Cancel -> "Cancel" - ) -;; - -let confirmtype_to_string (d) = - (match d with - | FIX_ConfirmType_Status -> "Status" - | FIX_ConfirmType_Confirmation -> "Confirmation" - | FIX_ConfirmType_ConfirmationRequestRejected -> "ConfirmationRequestRejected" - ) -;; - -let contamttype_to_string (d) = - (match d with - | FIX_ContAmtType_CommissionAmount -> "CommissionAmount" - | FIX_ContAmtType_CommissionPercent -> "CommissionPercent" - | FIX_ContAmtType_InitialChargeAmount -> "InitialChargeAmount" - | FIX_ContAmtType_InitialChargePercent -> "InitialChargePercent" - | FIX_ContAmtType_DiscountAmount -> "DiscountAmount" - | FIX_ContAmtType_DiscountPercent -> "DiscountPercent" - | FIX_ContAmtType_DilutionLevyAmount -> "DilutionLevyAmount" - | FIX_ContAmtType_DilutionLevyPercent -> "DilutionLevyPercent" - | FIX_ContAmtType_ExitChargeAmount -> "ExitChargeAmount" - | FIX_ContAmtType_ExitChargePercent -> "ExitChargePercent" - | FIX_ContAmtType_FundBasedRenewalCommissionPercent -> "FundBasedRenewalCommissionPercent" - | FIX_ContAmtType_ProjectedFundValue -> "ProjectedFundValue" - | FIX_ContAmtType_FundBasedRenewalCommissionOnOrder -> "FundBasedRenewalCommissionOnOrder" - | FIX_ContAmtType_FundBasedRenewalCommissionOnFund -> "FundBasedRenewalCommissionOnFund" - | FIX_ContAmtType_NetSettlementAmount -> "NetSettlementAmount" - ) -;; - -let corporateaction_to_string (d) = - (match d with - | FIX_CorporateAction_ExDividend -> "ExDividend" - | FIX_CorporateAction_ExDistribution -> "ExDistribution" - | FIX_CorporateAction_ExRights -> "ExRights" - | FIX_CorporateAction_New -> "New" - | FIX_CorporateAction_ExInterest -> "ExInterest" - ) -;; - -let coveredoruncovered_to_string (d) = - (match d with - | FIX_CoveredOrUncovered_Covered -> "Covered" - | FIX_CoveredOrUncovered_Uncovered -> "Uncovered" - ) -;; - -let crossprioritization_to_string (d) = - (match d with - | FIX_CrossPrioritization_FIXNone -> "FIXNone" - | FIX_CrossPrioritization_BuySideIsPrioritized -> "BuySideIsPrioritized" - | FIX_CrossPrioritization_SellSideIsPrioritized -> "SellSideIsPrioritized" - ) -;; - -let crosstype_to_string (d) = - (match d with - | FIX_CrossType_CrossAON -> "CrossAON" - | FIX_CrossType_CrossIOC -> "CrossIOC" - | FIX_CrossType_CrossOneSide -> "CrossOneSide" - | FIX_CrossType_CrossSamePrice -> "CrossSamePrice" - ) -;; - -let custordercapacity_to_string (d) = - (match d with - | FIX_CustOrderCapacity_MemberTradingForTheirOwnAccount -> "MemberTradingForTheirOwnAccount" - | FIX_CustOrderCapacity_ClearingFirmTradingForItsProprietaryAccount -> "ClearingFirmTradingForItsProprietaryAccount" - | FIX_CustOrderCapacity_MemberTradingForAnotherMember -> "MemberTradingForAnotherMember" - | FIX_CustOrderCapacity_AllOther -> "AllOther" - ) -;; - -let cxlrejreason_to_string (d) = - (match d with - | FIX_CxlRejReason_TooLateToCancel -> "TooLateToCancel" - | FIX_CxlRejReason_UnknownOrder -> "UnknownOrder" - | FIX_CxlRejReason_BrokerCredit -> "BrokerCredit" - | FIX_CxlRejReason_OrderAlreadyInPendingStatus -> "OrderAlreadyInPendingStatus" - | FIX_CxlRejReason_UnableToProcessOrderMassCancelRequest -> "UnableToProcessOrderMassCancelRequest" - | FIX_CxlRejReason_OrigOrdModTime -> "OrigOrdModTime" - | FIX_CxlRejReason_DuplicateClOrdID -> "DuplicateClOrdID" - | FIX_CxlRejReason_Other -> "Other" - ) -;; - -let cxlrejresponseto_to_string (d) = - (match d with - | FIX_CxlRejResponseTo_OrderCancelRequest -> "OrderCancelRequest" - | FIX_CxlRejResponseTo_OrderCancel -> "OrderCancel" - ) -;; - -let dkreason_to_string (d) = - (match d with - | FIX_DKReason_UnknownSymbol -> "UnknownSymbol" - | FIX_DKReason_WrongSide -> "WrongSide" - | FIX_DKReason_QuantityExceedsOrder -> "QuantityExceedsOrder" - | FIX_DKReason_NoMatchingOrder -> "NoMatchingOrder" - | FIX_DKReason_PriceExceedsLimit -> "PriceExceedsLimit" - | FIX_DKReason_CalculationDifference -> "CalculationDifference" - | FIX_DKReason_Other -> "Other" - ) -;; - -let daybookinginst_to_string (d) = - (match d with - | FIX_DayBookingInst_Auto -> "Auto" - | FIX_DayBookingInst_SpeakWithOrderInitiatorBeforeBooking -> "SpeakWithOrderInitiatorBeforeBooking" - | FIX_DayBookingInst_Accumulate -> "Accumulate" - ) -;; - -let deletereason_to_string (d) = - (match d with - | FIX_DeleteReason_Cancellation -> "Cancellation" - | FIX_DeleteReason_Error -> "Error" - ) -;; - -let deliveryform_to_string (d) = - (match d with - | FIX_DeliveryForm_BookEntry -> "BookEntry" - | FIX_DeliveryForm_Bearer -> "Bearer" - ) -;; - -let deliverytype_to_string (d) = - (match d with - | FIX_DeliveryType_VersusPayment -> "VersusPayment" - | FIX_DeliveryType_Free -> "Free" - | FIX_DeliveryType_TriParty -> "TriParty" - | FIX_DeliveryType_HoldInCustody -> "HoldInCustody" - ) -;; - -let discretioninst_to_string (d) = - (match d with - | FIX_DiscretionInst_RelatedToDisplayedPrice -> "RelatedToDisplayedPrice" - | FIX_DiscretionInst_RelatedToMarketPrice -> "RelatedToMarketPrice" - | FIX_DiscretionInst_RelatedToPrimaryPrice -> "RelatedToPrimaryPrice" - | FIX_DiscretionInst_RelatedToLocalPrimaryPrice -> "RelatedToLocalPrimaryPrice" - | FIX_DiscretionInst_RelatedToMidpointPrice -> "RelatedToMidpointPrice" - | FIX_DiscretionInst_RelatedToLastTradePrice -> "RelatedToLastTradePrice" - | FIX_DiscretionInst_RelatedToVWAP -> "RelatedToVWAP" - ) -;; - -let discretionlimittype_to_string (d) = - (match d with - | FIX_DiscretionLimitType_OrBetter -> "OrBetter" - | FIX_DiscretionLimitType_Strict -> "Strict" - | FIX_DiscretionLimitType_OrWorse -> "OrWorse" - ) -;; - -let discretionmovetype_to_string (d) = - (match d with - | FIX_DiscretionMoveType_Floating -> "Floating" - | FIX_DiscretionMoveType_Fixed -> "Fixed" - ) -;; - -let discretionoffsettype_to_string (d) = - (match d with - | FIX_DiscretionOffsetType_Price -> "Price" - | FIX_DiscretionOffsetType_BasisPoints -> "BasisPoints" - | FIX_DiscretionOffsetType_Ticks -> "Ticks" - | FIX_DiscretionOffsetType_PriceTier -> "PriceTier" - ) -;; - -let discretionrounddirection_to_string (d) = - (match d with - | FIX_DiscretionRoundDirection_MoreAggressive -> "MoreAggressive" - | FIX_DiscretionRoundDirection_MorePassive -> "MorePassive" - ) -;; - -let discretionscope_to_string (d) = - (match d with - | FIX_DiscretionScope_Local -> "Local" - | FIX_DiscretionScope_National -> "National" - | FIX_DiscretionScope_Global -> "Global" - | FIX_DiscretionScope_NationalExcludingLocal -> "NationalExcludingLocal" - ) -;; - -let distribpaymentmethod_to_string (d) = - (match d with - | FIX_DistribPaymentMethod_CREST -> "CREST" - | FIX_DistribPaymentMethod_NSCC -> "NSCC" - | FIX_DistribPaymentMethod_Euroclear -> "Euroclear" - | FIX_DistribPaymentMethod_Clearstream -> "Clearstream" - | FIX_DistribPaymentMethod_Cheque -> "Cheque" - | FIX_DistribPaymentMethod_TelegraphicTransfer -> "TelegraphicTransfer" - | FIX_DistribPaymentMethod_FedWire -> "FedWire" - | FIX_DistribPaymentMethod_DirectCredit -> "DirectCredit" - | FIX_DistribPaymentMethod_ACHCredit -> "ACHCredit" - | FIX_DistribPaymentMethod_BPAY -> "BPAY" - | FIX_DistribPaymentMethod_HighValueClearingSystemHVACS -> "HighValueClearingSystemHVACS" - | FIX_DistribPaymentMethod_ReinvestInFund -> "ReinvestInFund" - ) -;; - -let dlvyinsttype_to_string (d) = - (match d with - | FIX_DlvyInstType_Securities -> "Securities" - | FIX_DlvyInstType_Cash -> "Cash" - ) -;; - -let duetorelated_to_string (d) = - (match d with - | FIX_DueToRelated_RelatedToSecurityHalt -> "RelatedToSecurityHalt" - | FIX_DueToRelated_NotRelatedToSecurityHalt -> "NotRelatedToSecurityHalt" - ) -;; - -let emailtype_to_string (d) = - (match d with - | FIX_EmailType_New -> "New" - | FIX_EmailType_Reply -> "Reply" - | FIX_EmailType_AdminReply -> "AdminReply" - ) -;; - -let eventtype_to_string (d) = - (match d with - | FIX_EventType_Put -> "Put" - | FIX_EventType_Call -> "Call" - | FIX_EventType_Tender -> "Tender" - | FIX_EventType_SinkingFundCall -> "SinkingFundCall" - | FIX_EventType_Other -> "Other" - ) -;; - -let exchangeforphysical_to_string (d) = - (match d with - | FIX_ExchangeForPhysical_True -> "True" - | FIX_ExchangeForPhysical_False -> "False" - ) -;; - -let execinst_to_string (d) = - (match d with - | FIX_ExecInst_NotHeld -> "NotHeld" - | FIX_ExecInst_Work -> "Work" - | FIX_ExecInst_GoAlong -> "GoAlong" - | FIX_ExecInst_OverTheDay -> "OverTheDay" - | FIX_ExecInst_Held -> "Held" - | FIX_ExecInst_ParticipateDoNotInitiate -> "ParticipateDoNotInitiate" - | FIX_ExecInst_StrictScale -> "StrictScale" - | FIX_ExecInst_TryToScale -> "TryToScale" - | FIX_ExecInst_StayOnBidSide -> "StayOnBidSide" - | FIX_ExecInst_StayOnOfferSide -> "StayOnOfferSide" - | FIX_ExecInst_NoCross -> "NoCross" - | FIX_ExecInst_OKToCross -> "OKToCross" - | FIX_ExecInst_CallFirst -> "CallFirst" - | FIX_ExecInst_PercentOfVolume -> "PercentOfVolume" - | FIX_ExecInst_DoNotIncrease -> "DoNotIncrease" - | FIX_ExecInst_DoNotReduce -> "DoNotReduce" - | FIX_ExecInst_AllOrNone -> "AllOrNone" - | FIX_ExecInst_ReinstateOnSystemFailure -> "ReinstateOnSystemFailure" - | FIX_ExecInst_InstitutionsOnly -> "InstitutionsOnly" - | FIX_ExecInst_ReinstateOnTradingHalt -> "ReinstateOnTradingHalt" - | FIX_ExecInst_CancelOnTradingHalt -> "CancelOnTradingHalt" - | FIX_ExecInst_LastPeg -> "LastPeg" - | FIX_ExecInst_MidPricePeg -> "MidPricePeg" - | FIX_ExecInst_NonNegotiable -> "NonNegotiable" - | FIX_ExecInst_OpeningPeg -> "OpeningPeg" - | FIX_ExecInst_MarketPeg -> "MarketPeg" - | FIX_ExecInst_CancelOnSystemFailure -> "CancelOnSystemFailure" - | FIX_ExecInst_PrimaryPeg -> "PrimaryPeg" - | FIX_ExecInst_Suspend -> "Suspend" - | FIX_ExecInst_CustomerDisplayInstruction -> "CustomerDisplayInstruction" - | FIX_ExecInst_Netting -> "Netting" - | FIX_ExecInst_PegToVWAP -> "PegToVWAP" - | FIX_ExecInst_TradeAlong -> "TradeAlong" - | FIX_ExecInst_TryToStop -> "TryToStop" - | FIX_ExecInst_CancelIfNotBest -> "CancelIfNotBest" - | FIX_ExecInst_TrailingStopPeg -> "TrailingStopPeg" - | FIX_ExecInst_StrictLimit -> "StrictLimit" - | FIX_ExecInst_IgnorePriceValidityChecks -> "IgnorePriceValidityChecks" - | FIX_ExecInst_PegToLimitPrice -> "PegToLimitPrice" - | FIX_ExecInst_WorkToTargetStrategy -> "WorkToTargetStrategy" - ) -;; - -let execpricetype_to_string (d) = - (match d with - | FIX_ExecPriceType_BidPrice -> "BidPrice" - | FIX_ExecPriceType_CreationPrice -> "CreationPrice" - | FIX_ExecPriceType_CreationPricePlusAdjustmentPercent -> "CreationPricePlusAdjustmentPercent" - | FIX_ExecPriceType_CreationPricePlusAdjustmentAmount -> "CreationPricePlusAdjustmentAmount" - | FIX_ExecPriceType_OfferPrice -> "OfferPrice" - | FIX_ExecPriceType_OfferPriceMinusAdjustmentPercent -> "OfferPriceMinusAdjustmentPercent" - | FIX_ExecPriceType_OfferPriceMinusAdjustmentAmount -> "OfferPriceMinusAdjustmentAmount" - | FIX_ExecPriceType_SinglePrice -> "SinglePrice" - ) -;; - -let execrestatementreason_to_string (d) = - (match d with - | FIX_ExecRestatementReason_GTCorporateAction -> "GTCorporateAction" - | FIX_ExecRestatementReason_GTRenewal -> "GTRenewal" - | FIX_ExecRestatementReason_VerbalChange -> "VerbalChange" - | FIX_ExecRestatementReason_RepricingOfOrder -> "RepricingOfOrder" - | FIX_ExecRestatementReason_BrokerOption -> "BrokerOption" - | FIX_ExecRestatementReason_PartialDeclineOfOrderQty -> "PartialDeclineOfOrderQty" - | FIX_ExecRestatementReason_CancelOnTradingHalt -> "CancelOnTradingHalt" - | FIX_ExecRestatementReason_CancelOnSystemFailure -> "CancelOnSystemFailure" - | FIX_ExecRestatementReason_Market -> "Market" - | FIX_ExecRestatementReason_Canceled -> "Canceled" - | FIX_ExecRestatementReason_WarehouseRecap -> "WarehouseRecap" - | FIX_ExecRestatementReason_Other -> "Other" - ) -;; - -let exectype_to_string (d) = - (match d with - | FIX_ExecType_New -> "New" - | FIX_ExecType_DoneForDay -> "DoneForDay" - | FIX_ExecType_Canceled -> "Canceled" - | FIX_ExecType_Replaced -> "Replaced" - | FIX_ExecType_PendingCancel -> "PendingCancel" - | FIX_ExecType_Stopped -> "Stopped" - | FIX_ExecType_Rejected -> "Rejected" - | FIX_ExecType_Suspended -> "Suspended" - | FIX_ExecType_PendingNew -> "PendingNew" - | FIX_ExecType_Calculated -> "Calculated" - | FIX_ExecType_Expired -> "Expired" - | FIX_ExecType_Restated -> "Restated" - | FIX_ExecType_PendingReplace -> "PendingReplace" - | FIX_ExecType_Trade -> "Trade" - | FIX_ExecType_TradeCorrect -> "TradeCorrect" - | FIX_ExecType_TradeCancel -> "TradeCancel" - | FIX_ExecType_OrderStatus -> "OrderStatus" - ) -;; - -let exercisemethod_to_string (d) = - (match d with - | FIX_ExerciseMethod_Automatic -> "Automatic" - | FIX_ExerciseMethod_Manual -> "Manual" - ) -;; - -let expirationcycle_to_string (d) = - (match d with - | FIX_ExpirationCycle_ExpireOnTradingSessionClose -> "ExpireOnTradingSessionClose" - | FIX_ExpirationCycle_ExpireOnTradingSessionOpen -> "ExpireOnTradingSessionOpen" - ) -;; - -let financialstatus_to_string (d) = - (match d with - | FIX_FinancialStatus_Bankrupt -> "Bankrupt" - | FIX_FinancialStatus_PendingDelisting -> "PendingDelisting" - ) -;; - -let forexreq_to_string (d) = - (match d with - | FIX_ForexReq_ExecuteForexAfterSecurityTrade -> "ExecuteForexAfterSecurityTrade" - | FIX_ForexReq_DoNotExecuteForexAfterSecurityTrade -> "DoNotExecuteForexAfterSecurityTrade" - ) -;; - -let fundrenewwaiv_to_string (d) = - (match d with - | FIX_FundRenewWaiv_Yes -> "Yes" - | FIX_FundRenewWaiv_No -> "No" - ) -;; - -let gtbookinginst_to_string (d) = - (match d with - | FIX_GTBookingInst_BookOutAllTradesOnDayOfExecution -> "BookOutAllTradesOnDayOfExecution" - | FIX_GTBookingInst_AccumulateUntilFilledOrExpired -> "AccumulateUntilFilledOrExpired" - | FIX_GTBookingInst_AccumulateUntilVerballyNotifiedOtherwise -> "AccumulateUntilVerballyNotifiedOtherwise" - ) -;; - -let haltreason_to_string (d) = - (match d with - | FIX_HaltReason_OrderImbalance -> "OrderImbalance" - | FIX_HaltReason_EquipmentChangeover -> "EquipmentChangeover" - | FIX_HaltReason_NewsPending -> "NewsPending" - | FIX_HaltReason_NewsDissemination -> "NewsDissemination" - | FIX_HaltReason_OrderInflux -> "OrderInflux" - | FIX_HaltReason_AdditionalInformation -> "AdditionalInformation" - ) -;; - -let handlinst_to_string (d) = - (match d with - | FIX_HandlInst_AutomatedExecutionNoIntervention -> "AutomatedExecutionNoIntervention" - | FIX_HandlInst_AutomatedExecutionInterventionOK -> "AutomatedExecutionInterventionOK" - | FIX_HandlInst_ManualOrder -> "ManualOrder" - ) -;; - -let ioinaturalflag_to_string (d) = - (match d with - | FIX_IOINaturalFlag_Natural -> "Natural" - | FIX_IOINaturalFlag_NotNatural -> "NotNatural" - ) -;; - -let ioiqltyind_to_string (d) = - (match d with - | FIX_IOIQltyInd_Low -> "Low" - | FIX_IOIQltyInd_Medium -> "Medium" - | FIX_IOIQltyInd_High -> "High" - ) -;; - -let ioiqty_to_string (d) = - (match d with - | FIX_IOIQty_Small -> "Small" - | FIX_IOIQty_Medium -> "Medium" - | FIX_IOIQty_Large -> "Large" - ) -;; - -let ioiqualifier_to_string (d) = - (match d with - | FIX_IOIQualifier_AllOrNone -> "AllOrNone" - | FIX_IOIQualifier_MarketOnClose -> "MarketOnClose" - | FIX_IOIQualifier_AtTheClose -> "AtTheClose" - | FIX_IOIQualifier_VWAP -> "VWAP" - | FIX_IOIQualifier_InTouchWith -> "InTouchWith" - | FIX_IOIQualifier_Limit -> "Limit" - | FIX_IOIQualifier_MoreBehind -> "MoreBehind" - | FIX_IOIQualifier_AtTheOpen -> "AtTheOpen" - | FIX_IOIQualifier_TakingAPosition -> "TakingAPosition" - | FIX_IOIQualifier_AtTheMarket -> "AtTheMarket" - | FIX_IOIQualifier_ReadyToTrade -> "ReadyToTrade" - | FIX_IOIQualifier_PortfolioShown -> "PortfolioShown" - | FIX_IOIQualifier_ThroughTheDay -> "ThroughTheDay" - | FIX_IOIQualifier_Versus -> "Versus" - | FIX_IOIQualifier_Indication -> "Indication" - | FIX_IOIQualifier_CrossingOpportunity -> "CrossingOpportunity" - | FIX_IOIQualifier_AtTheMidpoint -> "AtTheMidpoint" - | FIX_IOIQualifier_PreOpen -> "PreOpen" - ) -;; - -let ioitranstype_to_string (d) = - (match d with - | FIX_IOITransType_New -> "New" - | FIX_IOITransType_Cancel -> "Cancel" - | FIX_IOITransType_Replace -> "Replace" - ) -;; - -let inviewofcommon_to_string (d) = - (match d with - | FIX_InViewOfCommon_HaltWasDueToCommonStockBeingHalted -> "HaltWasDueToCommonStockBeingHalted" - | FIX_InViewOfCommon_HaltWasNotRelatedToAHaltOfTheCommonStock -> "HaltWasNotRelatedToAHaltOfTheCommonStock" - ) -;; - -let inctaxind_to_string (d) = - (match d with - | FIX_IncTaxInd_Net -> "Net" - | FIX_IncTaxInd_Gross -> "Gross" - ) -;; - -let instrattribtype_to_string (d) = - (match d with - | FIX_InstrAttribType_Flat -> "Flat" - | FIX_InstrAttribType_ZeroCoupon -> "ZeroCoupon" - | FIX_InstrAttribType_InterestBearing -> "InterestBearing" - | FIX_InstrAttribType_NoPeriodicPayments -> "NoPeriodicPayments" - | FIX_InstrAttribType_VariableRate -> "VariableRate" - | FIX_InstrAttribType_LessFeeForPut -> "LessFeeForPut" - | FIX_InstrAttribType_SteppedCoupon -> "SteppedCoupon" - | FIX_InstrAttribType_CouponPeriod -> "CouponPeriod" - | FIX_InstrAttribType_When -> "When" - | FIX_InstrAttribType_OriginalIssueDiscount -> "OriginalIssueDiscount" - | FIX_InstrAttribType_Callable -> "Callable" - | FIX_InstrAttribType_EscrowedToMaturity -> "EscrowedToMaturity" - | FIX_InstrAttribType_EscrowedToRedemptionDate -> "EscrowedToRedemptionDate" - | FIX_InstrAttribType_PreRefunded -> "PreRefunded" - | FIX_InstrAttribType_InDefault -> "InDefault" - | FIX_InstrAttribType_Unrated -> "Unrated" - | FIX_InstrAttribType_Taxable -> "Taxable" - | FIX_InstrAttribType_Indexed -> "Indexed" - | FIX_InstrAttribType_SubjectToAlternativeMinimumTax -> "SubjectToAlternativeMinimumTax" - | FIX_InstrAttribType_OriginalIssueDiscountPrice -> "OriginalIssueDiscountPrice" - | FIX_InstrAttribType_CallableBelowMaturityValue -> "CallableBelowMaturityValue" - | FIX_InstrAttribType_CallableWithoutNotice -> "CallableWithoutNotice" - | FIX_InstrAttribType_Text -> "Text" - ) -;; - -let lastcapacity_to_string (d) = - (match d with - | FIX_LastCapacity_Agent -> "Agent" - | FIX_LastCapacity_CrossAsAgent -> "CrossAsAgent" - | FIX_LastCapacity_CrossAsPrincipal -> "CrossAsPrincipal" - | FIX_LastCapacity_Principal -> "Principal" - ) -;; - -let lastfragment_to_string (d) = - (match d with - | FIX_LastFragment_LastMessage -> "LastMessage" - | FIX_LastFragment_NotLastMessage -> "NotLastMessage" - ) -;; - -let lastliquidityind_to_string (d) = - (match d with - | FIX_LastLiquidityInd_AddedLiquidity -> "AddedLiquidity" - | FIX_LastLiquidityInd_RemovedLiquidity -> "RemovedLiquidity" - | FIX_LastLiquidityInd_LiquidityRoutedOut -> "LiquidityRoutedOut" - ) -;; - -let legswaptype_to_string (d) = - (match d with - | FIX_LegSwapType_ParForPar -> "ParForPar" - | FIX_LegSwapType_ModifiedDuration -> "ModifiedDuration" - | FIX_LegSwapType_Risk -> "Risk" - | FIX_LegSwapType_Proceeds -> "Proceeds" - ) -;; - -let legalconfirm_to_string (d) = - (match d with - | FIX_LegalConfirm_LegalConfirm -> "LegalConfirm" - | FIX_LegalConfirm_DoesNotConsituteALegalConfirm -> "DoesNotConsituteALegalConfirm" - ) -;; - -let liquidityindtype_to_string (d) = - (match d with - | FIX_LiquidityIndType_FiveDayMovingAverage -> "FiveDayMovingAverage" - | FIX_LiquidityIndType_TwentyDayMovingAverage -> "TwentyDayMovingAverage" - | FIX_LiquidityIndType_NormalMarketSize -> "NormalMarketSize" - | FIX_LiquidityIndType_Other -> "Other" - ) -;; - -let listexecinsttype_to_string (d) = - (match d with - | FIX_ListExecInstType_Immediate -> "Immediate" - | FIX_ListExecInstType_WaitForInstruction -> "WaitForInstruction" - | FIX_ListExecInstType_SellDriven -> "SellDriven" - | FIX_ListExecInstType_BuyDrivenCashTopUp -> "BuyDrivenCashTopUp" - | FIX_ListExecInstType_BuyDrivenCashWithdraw -> "BuyDrivenCashWithdraw" - ) -;; - -let listorderstatus_to_string (d) = - (match d with - | FIX_ListOrderStatus_InBiddingProcess -> "InBiddingProcess" - | FIX_ListOrderStatus_ReceivedForExecution -> "ReceivedForExecution" - | FIX_ListOrderStatus_Executing -> "Executing" - | FIX_ListOrderStatus_Cancelling -> "Cancelling" - | FIX_ListOrderStatus_Alert -> "Alert" - | FIX_ListOrderStatus_AllDone -> "AllDone" - | FIX_ListOrderStatus_Reject -> "Reject" - ) -;; - -let liststatustype_to_string (d) = - (match d with - | FIX_ListStatusType_Ack -> "Ack" - | FIX_ListStatusType_Response -> "Response" - | FIX_ListStatusType_Timed -> "Timed" - | FIX_ListStatusType_ExecStarted -> "ExecStarted" - | FIX_ListStatusType_AllDone -> "AllDone" - | FIX_ListStatusType_Alert -> "Alert" - ) -;; - -let locatereqd_to_string (d) = - (match d with - | FIX_LocateReqd_Yes -> "Yes" - | FIX_LocateReqd_No -> "No" - ) -;; - -let mdentrytype_to_string (d) = - (match d with - | FIX_MDEntryType_Bid -> "Bid" - | FIX_MDEntryType_Offer -> "Offer" - | FIX_MDEntryType_Trade -> "Trade" - | FIX_MDEntryType_IndexValue -> "IndexValue" - | FIX_MDEntryType_OpeningPrice -> "OpeningPrice" - | FIX_MDEntryType_ClosingPrice -> "ClosingPrice" - | FIX_MDEntryType_SettlementPrice -> "SettlementPrice" - | FIX_MDEntryType_TradingSessionHighPrice -> "TradingSessionHighPrice" - | FIX_MDEntryType_TradingSessionLowPrice -> "TradingSessionLowPrice" - | FIX_MDEntryType_TradingSessionVWAPPrice -> "TradingSessionVWAPPrice" - | FIX_MDEntryType_Imbalance -> "Imbalance" - | FIX_MDEntryType_TradeVolume -> "TradeVolume" - | FIX_MDEntryType_OpenInterest -> "OpenInterest" - ) -;; - -let mdimplicitdelete_to_string (d) = - (match d with - | FIX_MDImplicitDelete_Yes -> "Yes" - | FIX_MDImplicitDelete_No -> "No" - ) -;; - -let mdreqrejreason_to_string (d) = - (match d with - | FIX_MDReqRejReason_UnknownSymbol -> "UnknownSymbol" - | FIX_MDReqRejReason_DuplicateMDReqID -> "DuplicateMDReqID" - | FIX_MDReqRejReason_InsufficientBandwidth -> "InsufficientBandwidth" - | FIX_MDReqRejReason_InsufficientPermissions -> "InsufficientPermissions" - | FIX_MDReqRejReason_UnsupportedSubscriptionRequestType -> "UnsupportedSubscriptionRequestType" - | FIX_MDReqRejReason_UnsupportedMarketDepth -> "UnsupportedMarketDepth" - | FIX_MDReqRejReason_UnsupportedMDUpdateType -> "UnsupportedMDUpdateType" - | FIX_MDReqRejReason_UnsupportedAggregatedBook -> "UnsupportedAggregatedBook" - | FIX_MDReqRejReason_UnsupportedMDEntryType -> "UnsupportedMDEntryType" - | FIX_MDReqRejReason_UnsupportedTradingSessionID -> "UnsupportedTradingSessionID" - | FIX_MDReqRejReason_UnsupportedScope -> "UnsupportedScope" - | FIX_MDReqRejReason_UnsupportedOpenCloseSettleFlag -> "UnsupportedOpenCloseSettleFlag" - | FIX_MDReqRejReason_UnsupportedMDImplicitDelete -> "UnsupportedMDImplicitDelete" - ) -;; - -let mdupdateaction_to_string (d) = - (match d with - | FIX_MDUpdateAction_New -> "New" - | FIX_MDUpdateAction_Change -> "Change" - | FIX_MDUpdateAction_Delete -> "Delete" - ) -;; - -let mdupdatetype_to_string (d) = - (match d with - | FIX_MDUpdateType_FullRefresh -> "FullRefresh" - | FIX_MDUpdateType_IncrementalRefresh -> "IncrementalRefresh" - ) -;; - -let masscancelrejectreason_to_string (d) = - (match d with - | FIX_MassCancelRejectReason_MassCancelNotSupported -> "MassCancelNotSupported" - | FIX_MassCancelRejectReason_InvalidOrUnknownSecurity -> "InvalidOrUnknownSecurity" - | FIX_MassCancelRejectReason_InvalidOrUnkownUnderlyingSecurity -> "InvalidOrUnkownUnderlyingSecurity" - | FIX_MassCancelRejectReason_InvalidOrUnknownProduct -> "InvalidOrUnknownProduct" - | FIX_MassCancelRejectReason_InvalidOrUnknownCFICode -> "InvalidOrUnknownCFICode" - | FIX_MassCancelRejectReason_InvalidOrUnknownSecurityType -> "InvalidOrUnknownSecurityType" - | FIX_MassCancelRejectReason_InvalidOrUnknownTradingSession -> "InvalidOrUnknownTradingSession" - | FIX_MassCancelRejectReason_Other -> "Other" - ) -;; - -let masscancelrequesttype_to_string (d) = - (match d with - | FIX_MassCancelRequestType_CancelOrdersForASecurity -> "CancelOrdersForASecurity" - | FIX_MassCancelRequestType_CancelOrdersForAnUnderlyingSecurity -> "CancelOrdersForAnUnderlyingSecurity" - | FIX_MassCancelRequestType_CancelOrdersForAProduct -> "CancelOrdersForAProduct" - | FIX_MassCancelRequestType_CancelOrdersForACFICode -> "CancelOrdersForACFICode" - | FIX_MassCancelRequestType_CancelOrdersForASecurityType -> "CancelOrdersForASecurityType" - | FIX_MassCancelRequestType_CancelOrdersForATradingSession -> "CancelOrdersForATradingSession" - | FIX_MassCancelRequestType_CancelAllOrders -> "CancelAllOrders" - ) -;; - -let masscancelresponse_to_string (d) = - (match d with - | FIX_MassCancelResponse_CancelRequestRejected -> "CancelRequestRejected" - | FIX_MassCancelResponse_CancelOrdersForASecurity -> "CancelOrdersForASecurity" - | FIX_MassCancelResponse_CancelOrdersForAnUnderlyingSecurity -> "CancelOrdersForAnUnderlyingSecurity" - | FIX_MassCancelResponse_CancelOrdersForAProduct -> "CancelOrdersForAProduct" - | FIX_MassCancelResponse_CancelOrdersForACFICode -> "CancelOrdersForACFICode" - | FIX_MassCancelResponse_CancelOrdersForASecurityType -> "CancelOrdersForASecurityType" - | FIX_MassCancelResponse_CancelOrdersForATradingSession -> "CancelOrdersForATradingSession" - | FIX_MassCancelResponse_CancelAllOrders -> "CancelAllOrders" - ) -;; - -let massstatusreqtype_to_string (d) = - (match d with - | FIX_MassStatusReqType_StatusForOrdersForASecurity -> "StatusForOrdersForASecurity" - | FIX_MassStatusReqType_StatusForOrdersForAnUnderlyingSecurity -> "StatusForOrdersForAnUnderlyingSecurity" - | FIX_MassStatusReqType_StatusForOrdersForAProduct -> "StatusForOrdersForAProduct" - | FIX_MassStatusReqType_StatusForOrdersForACFICode -> "StatusForOrdersForACFICode" - | FIX_MassStatusReqType_StatusForOrdersForASecurityType -> "StatusForOrdersForASecurityType" - | FIX_MassStatusReqType_StatusForOrdersForATradingSession -> "StatusForOrdersForATradingSession" - | FIX_MassStatusReqType_StatusForAllOrders -> "StatusForAllOrders" - | FIX_MassStatusReqType_StatusForOrdersForAPartyID -> "StatusForOrdersForAPartyID" - ) -;; - -let matchstatus_to_string (d) = - (match d with - | FIX_MatchStatus_Compared -> "Compared" - | FIX_MatchStatus_Uncompared -> "Uncompared" - | FIX_MatchStatus_AdvisoryOrAlert -> "AdvisoryOrAlert" - ) -;; - -let matchtype_to_string (d) = - (match d with - | FIX_MatchType_ExactMatchPlus4BadgesExecTime -> "ExactMatchPlus4BadgesExecTime" - | FIX_MatchType_ExactMatchPlus4Badges -> "ExactMatchPlus4Badges" - | FIX_MatchType_ExactMatchPlus2BadgesExecTime -> "ExactMatchPlus2BadgesExecTime" - | FIX_MatchType_ExactMatchPlus2Badges -> "ExactMatchPlus2Badges" - | FIX_MatchType_ExactMatchPlusExecTime -> "ExactMatchPlusExecTime" - | FIX_MatchType_StampedAdvisoriesOrSpecialistAccepts -> "StampedAdvisoriesOrSpecialistAccepts" - | FIX_MatchType_A1ExactMatchSummarizedQuantity -> "A1ExactMatchSummarizedQuantity" - | FIX_MatchType_A2ExactMatchSummarizedQuantity -> "A2ExactMatchSummarizedQuantity" - | FIX_MatchType_A3ExactMatchSummarizedQuantity -> "A3ExactMatchSummarizedQuantity" - | FIX_MatchType_A4ExactMatchSummarizedQuantity -> "A4ExactMatchSummarizedQuantity" - | FIX_MatchType_A5ExactMatchSummarizedQuantity -> "A5ExactMatchSummarizedQuantity" - | FIX_MatchType_ExactMatchMinusBadgesTimes -> "ExactMatchMinusBadgesTimes" - | FIX_MatchType_SummarizedMatchMinusBadgesTimes -> "SummarizedMatchMinusBadgesTimes" - | FIX_MatchType_OCSLockedIn -> "OCSLockedIn" - | FIX_MatchType_ACTAcceptedTrade -> "ACTAcceptedTrade" - | FIX_MatchType_ACTDefaultTrade -> "ACTDefaultTrade" - | FIX_MatchType_ACTDefaultAfterM2 -> "ACTDefaultAfterM2" - | FIX_MatchType_ACTM6Match -> "ACTM6Match" - ) -;; - -let messageencoding_to_string (d) = - (match d with - | FIX_MessageEncoding_ISO2022JP -> "ISO2022JP" - | FIX_MessageEncoding_EUCJP -> "EUCJP" - | FIX_MessageEncoding_ShiftJIS -> "ShiftJIS" - | FIX_MessageEncoding_UTF8 -> "UTF8" - ) -;; - -let miscfeebasis_to_string (d) = - (match d with - | FIX_MiscFeeBasis_Absolute -> "Absolute" - | FIX_MiscFeeBasis_PerUnit -> "PerUnit" - | FIX_MiscFeeBasis_Percentage -> "Percentage" - ) -;; - -let miscfeetype_to_string (d) = - (match d with - | FIX_MiscFeeType_Regulatory -> "Regulatory" - | FIX_MiscFeeType_Tax -> "Tax" - | FIX_MiscFeeType_LocalCommission -> "LocalCommission" - | FIX_MiscFeeType_ExchangeFees -> "ExchangeFees" - | FIX_MiscFeeType_Stamp -> "Stamp" - | FIX_MiscFeeType_Levy -> "Levy" - | FIX_MiscFeeType_Other -> "Other" - | FIX_MiscFeeType_Markup -> "Markup" - | FIX_MiscFeeType_ConsumptionTax -> "ConsumptionTax" - | FIX_MiscFeeType_PerTransaction -> "PerTransaction" - | FIX_MiscFeeType_Conversion -> "Conversion" - | FIX_MiscFeeType_Agent -> "Agent" - ) -;; - -let moneylaunderingstatus_to_string (d) = - (match d with - | FIX_MoneyLaunderingStatus_Passed -> "Passed" - | FIX_MoneyLaunderingStatus_NotChecked -> "NotChecked" - | FIX_MoneyLaunderingStatus_ExemptBelowLimit -> "ExemptBelowLimit" - | FIX_MoneyLaunderingStatus_ExemptMoneyType -> "ExemptMoneyType" - | FIX_MoneyLaunderingStatus_ExemptAuthorised -> "ExemptAuthorised" - ) -;; - -let msgdirection_to_string (d) = - (match d with - | FIX_MsgDirection_Send -> "Send" - | FIX_MsgDirection_Receive -> "Receive" - ) -;; - -let multilegreportingtype_to_string (d) = - (match d with - | FIX_MultiLegReportingType_SingleSecurity -> "SingleSecurity" - | FIX_MultiLegReportingType_IndividualLegOfAMultiLegSecurity -> "IndividualLegOfAMultiLegSecurity" - | FIX_MultiLegReportingType_MultiLegSecurity -> "MultiLegSecurity" - ) -;; - -let multilegrpttypereq_to_string (d) = - (match d with - | FIX_MultiLegRptTypeReq_ReportByMulitlegSecurityOnly -> "ReportByMulitlegSecurityOnly" - | FIX_MultiLegRptTypeReq_ReportByMultilegSecurityAndInstrumentLegs -> "ReportByMultilegSecurityAndInstrumentLegs" - | FIX_MultiLegRptTypeReq_ReportByInstrumentLegsOnly -> "ReportByInstrumentLegsOnly" - ) -;; - -let netgrossind_to_string (d) = - (match d with - | FIX_NetGrossInd_Net -> "Net" - | FIX_NetGrossInd_Gross -> "Gross" - ) -;; - -let networkrequesttype_to_string (d) = - (match d with - | FIX_NetworkRequestType_Snapshot -> "Snapshot" - | FIX_NetworkRequestType_Subscribe -> "Subscribe" - | FIX_NetworkRequestType_StopSubscribing -> "StopSubscribing" - | FIX_NetworkRequestType_LevelOfDetail -> "LevelOfDetail" - ) -;; - -let networkstatusresponsetype_to_string (d) = - (match d with - | FIX_NetworkStatusResponseType_Full -> "Full" - | FIX_NetworkStatusResponseType_IncrementalUpdate -> "IncrementalUpdate" - ) -;; - -let nosides_to_string (d) = - (match d with - | FIX_NoSides_OneSide -> "OneSide" - | FIX_NoSides_BothSides -> "BothSides" - ) -;; - -let notifybrokerofcredit_to_string (d) = - (match d with - | FIX_NotifyBrokerOfCredit_DetailsShouldBeCommunicated -> "DetailsShouldBeCommunicated" - | FIX_NotifyBrokerOfCredit_DetailsShouldNotBeCommunicated -> "DetailsShouldNotBeCommunicated" - ) -;; - -let oddlot_to_string (d) = - (match d with - | FIX_OddLot_TreatAsOddLot -> "TreatAsOddLot" - | FIX_OddLot_TreatAsRoundLot -> "TreatAsRoundLot" - ) -;; - -let openclosesettlflag_to_string (d) = - (match d with - | FIX_OpenCloseSettlFlag_DailyOpen -> "DailyOpen" - | FIX_OpenCloseSettlFlag_SessionOpen -> "SessionOpen" - | FIX_OpenCloseSettlFlag_DeliverySettlementEntry -> "DeliverySettlementEntry" - | FIX_OpenCloseSettlFlag_ExpectedEntry -> "ExpectedEntry" - | FIX_OpenCloseSettlFlag_EntryFromPreviousBusinessDay -> "EntryFromPreviousBusinessDay" - | FIX_OpenCloseSettlFlag_TheoreticalPriceValue -> "TheoreticalPriceValue" - ) -;; - -let ordrejreason_to_string (d) = - (match d with - | FIX_OrdRejReason_BrokerCredit -> "BrokerCredit" - | FIX_OrdRejReason_UnknownSymbol -> "UnknownSymbol" - | FIX_OrdRejReason_ExchangeClosed -> "ExchangeClosed" - | FIX_OrdRejReason_OrderExceedsLimit -> "OrderExceedsLimit" - | FIX_OrdRejReason_TooLateToEnter -> "TooLateToEnter" - | FIX_OrdRejReason_UnknownOrder -> "UnknownOrder" - | FIX_OrdRejReason_DuplicateOrder -> "DuplicateOrder" - | FIX_OrdRejReason_DuplicateOfAVerballyCommunicatedOrder -> "DuplicateOfAVerballyCommunicatedOrder" - | FIX_OrdRejReason_StaleOrder -> "StaleOrder" - | FIX_OrdRejReason_TradeAlongRequired -> "TradeAlongRequired" - | FIX_OrdRejReason_InvalidInvestorID -> "InvalidInvestorID" - | FIX_OrdRejReason_UnsupportedOrderCharacteristic -> "UnsupportedOrderCharacteristic" - | FIX_OrdRejReason_IncorrectQuantity -> "IncorrectQuantity" - | FIX_OrdRejReason_IncorrectAllocatedQuantity -> "IncorrectAllocatedQuantity" - | FIX_OrdRejReason_UnknownAccount -> "UnknownAccount" - | FIX_OrdRejReason_Other -> "Other" - ) -;; - -let ordstatus_to_string (d) = - (match d with - | FIX_OrdStatus_New -> "New" - | FIX_OrdStatus_PartiallyFilled -> "PartiallyFilled" - | FIX_OrdStatus_Filled -> "Filled" - | FIX_OrdStatus_DoneForDay -> "DoneForDay" - | FIX_OrdStatus_Canceled -> "Canceled" - | FIX_OrdStatus_PendingCancel -> "PendingCancel" - | FIX_OrdStatus_Stopped -> "Stopped" - | FIX_OrdStatus_Rejected -> "Rejected" - | FIX_OrdStatus_Suspended -> "Suspended" - | FIX_OrdStatus_PendingNew -> "PendingNew" - | FIX_OrdStatus_Calculated -> "Calculated" - | FIX_OrdStatus_Expired -> "Expired" - | FIX_OrdStatus_AcceptedForBidding -> "AcceptedForBidding" - | FIX_OrdStatus_PendingReplace -> "PendingReplace" - | FIX_OrdStatus_Replaced -> "Replaced" - ) -;; - -let ordtype_to_string (d) = - (match d with - | FIX_OrdType_Market -> "Market" - | FIX_OrdType_Limit -> "Limit" - | FIX_OrdType_Stop -> "Stop" - | FIX_OrdType_StopLimit -> "StopLimit" - | FIX_OrdType_WithOrWithout -> "WithOrWithout" - | FIX_OrdType_LimitOrBetter -> "LimitOrBetter" - | FIX_OrdType_LimitWithOrWithout -> "LimitWithOrWithout" - | FIX_OrdType_OnBasis -> "OnBasis" - | FIX_OrdType_PreviouslyQuoted -> "PreviouslyQuoted" - | FIX_OrdType_PreviouslyIndicated -> "PreviouslyIndicated" - | FIX_OrdType_ForexSwap -> "ForexSwap" - | FIX_OrdType_Funari -> "Funari" - | FIX_OrdType_MarketIfTouched -> "MarketIfTouched" - | FIX_OrdType_MarketWithLeftOverAsLimit -> "MarketWithLeftOverAsLimit" - | FIX_OrdType_PreviousFundValuationPoint -> "PreviousFundValuationPoint" - | FIX_OrdType_NextFundValuationPoint -> "NextFundValuationPoint" - | FIX_OrdType_Pegged -> "Pegged" - ) -;; - -let ordercapacity_to_string (d) = - (match d with - | FIX_OrderCapacity_Agency -> "Agency" - | FIX_OrderCapacity_Proprietary -> "Proprietary" - | FIX_OrderCapacity_Individual -> "Individual" - | FIX_OrderCapacity_Principal -> "Principal" - | FIX_OrderCapacity_RisklessPrincipal -> "RisklessPrincipal" - | FIX_OrderCapacity_AgentForOtherMember -> "AgentForOtherMember" - ) -;; - -let orderrestrictions_to_string (d) = - (match d with - | FIX_OrderRestrictions_ProgramTrade -> "ProgramTrade" - | FIX_OrderRestrictions_IndexArbitrage -> "IndexArbitrage" - | FIX_OrderRestrictions_NonIndexArbitrage -> "NonIndexArbitrage" - | FIX_OrderRestrictions_CompetingMarketMaker -> "CompetingMarketMaker" - | FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInSecurity -> "ActingAsMarketMakerOrSpecialistInSecurity" - | FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInUnderlying -> "ActingAsMarketMakerOrSpecialistInUnderlying" - | FIX_OrderRestrictions_ForeignEntity -> "ForeignEntity" - | FIX_OrderRestrictions_ExternalMarketParticipant -> "ExternalMarketParticipant" - | FIX_OrderRestrictions_ExternalInterConnectedMarketLinkage -> "ExternalInterConnectedMarketLinkage" - | FIX_OrderRestrictions_RisklessArbitrage -> "RisklessArbitrage" - ) -;; - -let ownertype_to_string (d) = - (match d with - | FIX_OwnerType_IndividualInvestor -> "IndividualInvestor" - | FIX_OwnerType_PublicCompany -> "PublicCompany" - | FIX_OwnerType_PrivateCompany -> "PrivateCompany" - | FIX_OwnerType_IndividualTrustee -> "IndividualTrustee" - | FIX_OwnerType_CompanyTrustee -> "CompanyTrustee" - | FIX_OwnerType_PensionPlan -> "PensionPlan" - | FIX_OwnerType_CustodianUnderGiftsToMinorsAct -> "CustodianUnderGiftsToMinorsAct" - | FIX_OwnerType_Trusts -> "Trusts" - | FIX_OwnerType_Fiduciaries -> "Fiduciaries" - | FIX_OwnerType_NetworkingSubAccount -> "NetworkingSubAccount" - | FIX_OwnerType_NonProfitOrganization -> "NonProfitOrganization" - | FIX_OwnerType_CorporateBody -> "CorporateBody" - | FIX_OwnerType_Nominee -> "Nominee" - ) -;; - -let ownershiptype_to_string (d) = - (match d with - | FIX_OwnershipType_JointInvestors -> "JointInvestors" - | FIX_OwnershipType_TenantsInCommon -> "TenantsInCommon" - | FIX_OwnershipType_JointTrustees -> "JointTrustees" - ) -;; - -let partyidsource_to_string (d) = - (match d with - | FIX_PartyIDSource_BIC -> "BIC" - | FIX_PartyIDSource_GeneralIdentifier -> "GeneralIdentifier" - | FIX_PartyIDSource_Proprietary -> "Proprietary" - | FIX_PartyIDSource_ISOCountryCode -> "ISOCountryCode" - | FIX_PartyIDSource_SettlementEntityLocation -> "SettlementEntityLocation" - | FIX_PartyIDSource_MIC -> "MIC" - | FIX_PartyIDSource_CSDParticipant -> "CSDParticipant" - | FIX_PartyIDSource_KoreanInvestorID -> "KoreanInvestorID" - | FIX_PartyIDSource_TaiwaneseForeignInvestorID -> "TaiwaneseForeignInvestorID" - | FIX_PartyIDSource_TaiwaneseTradingAcct -> "TaiwaneseTradingAcct" - | FIX_PartyIDSource_MalaysianCentralDepository -> "MalaysianCentralDepository" - | FIX_PartyIDSource_ChineseInvestorID -> "ChineseInvestorID" - | FIX_PartyIDSource_UKNationalInsuranceOrPensionNumber -> "UKNationalInsuranceOrPensionNumber" - | FIX_PartyIDSource_USSocialSecurityNumber -> "USSocialSecurityNumber" - | FIX_PartyIDSource_USEmployerOrTaxIDNumber -> "USEmployerOrTaxIDNumber" - | FIX_PartyIDSource_AustralianBusinessNumber -> "AustralianBusinessNumber" - | FIX_PartyIDSource_AustralianTaxFileNumber -> "AustralianTaxFileNumber" - | FIX_PartyIDSource_ISITCAcronym -> "ISITCAcronym" - ) -;; - -let partyrole_to_string (d) = - (match d with - | FIX_PartyRole_ExecutingFirm -> "ExecutingFirm" - | FIX_PartyRole_BrokerOfCredit -> "BrokerOfCredit" - | FIX_PartyRole_ClientID -> "ClientID" - | FIX_PartyRole_ClearingFirm -> "ClearingFirm" - | FIX_PartyRole_InvestorID -> "InvestorID" - | FIX_PartyRole_IntroducingFirm -> "IntroducingFirm" - | FIX_PartyRole_EnteringFirm -> "EnteringFirm" - | FIX_PartyRole_Locate -> "Locate" - | FIX_PartyRole_FundManagerClientID -> "FundManagerClientID" - | FIX_PartyRole_SettlementLocation -> "SettlementLocation" - | FIX_PartyRole_OrderOriginationTrader -> "OrderOriginationTrader" - | FIX_PartyRole_ExecutingTrader -> "ExecutingTrader" - | FIX_PartyRole_OrderOriginationFirm -> "OrderOriginationFirm" - | FIX_PartyRole_GiveupClearingFirm -> "GiveupClearingFirm" - | FIX_PartyRole_CorrespondantClearingFirm -> "CorrespondantClearingFirm" - | FIX_PartyRole_ExecutingSystem -> "ExecutingSystem" - | FIX_PartyRole_ContraFirm -> "ContraFirm" - | FIX_PartyRole_ContraClearingFirm -> "ContraClearingFirm" - | FIX_PartyRole_SponsoringFirm -> "SponsoringFirm" - | FIX_PartyRole_UnderlyingContraFirm -> "UnderlyingContraFirm" - | FIX_PartyRole_ClearingOrganization -> "ClearingOrganization" - | FIX_PartyRole_Exchange -> "Exchange" - | FIX_PartyRole_CustomerAccount -> "CustomerAccount" - | FIX_PartyRole_CorrespondentClearingOrganization -> "CorrespondentClearingOrganization" - | FIX_PartyRole_CorrespondentBroker -> "CorrespondentBroker" - | FIX_PartyRole_Buyer -> "Buyer" - | FIX_PartyRole_Custodian -> "Custodian" - | FIX_PartyRole_Intermediary -> "Intermediary" - | FIX_PartyRole_Agent -> "Agent" - | FIX_PartyRole_SubCustodian -> "SubCustodian" - | FIX_PartyRole_Beneficiary -> "Beneficiary" - | FIX_PartyRole_InterestedParty -> "InterestedParty" - | FIX_PartyRole_RegulatoryBody -> "RegulatoryBody" - | FIX_PartyRole_LiquidityProvider -> "LiquidityProvider" - | FIX_PartyRole_EnteringTrader -> "EnteringTrader" - | FIX_PartyRole_ContraTrader -> "ContraTrader" - | FIX_PartyRole_PositionAccount -> "PositionAccount" - ) -;; - -let partysubidtype_to_string (d) = - (match d with - | FIX_PartySubIDType_Firm -> "Firm" - | FIX_PartySubIDType_Person -> "Person" - | FIX_PartySubIDType_System -> "System" - | FIX_PartySubIDType_Application -> "Application" - | FIX_PartySubIDType_FullLegalNameOfFirm -> "FullLegalNameOfFirm" - | FIX_PartySubIDType_PostalAddress -> "PostalAddress" - | FIX_PartySubIDType_PhoneNumber -> "PhoneNumber" - | FIX_PartySubIDType_EmailAddress -> "EmailAddress" - | FIX_PartySubIDType_ContactName -> "ContactName" - | FIX_PartySubIDType_SecuritiesAccountNumber -> "SecuritiesAccountNumber" - | FIX_PartySubIDType_RegistrationNumber -> "RegistrationNumber" - | FIX_PartySubIDType_RegisteredAddressForConfirmation -> "RegisteredAddressForConfirmation" - | FIX_PartySubIDType_RegulatoryStatus -> "RegulatoryStatus" - | FIX_PartySubIDType_RegistrationName -> "RegistrationName" - | FIX_PartySubIDType_CashAccountNumber -> "CashAccountNumber" - | FIX_PartySubIDType_BIC -> "BIC" - | FIX_PartySubIDType_CSDParticipantMemberCode -> "CSDParticipantMemberCode" - | FIX_PartySubIDType_RegisteredAddress -> "RegisteredAddress" - | FIX_PartySubIDType_FundAccountName -> "FundAccountName" - | FIX_PartySubIDType_TelexNumber -> "TelexNumber" - | FIX_PartySubIDType_FaxNumber -> "FaxNumber" - | FIX_PartySubIDType_SecuritiesAccountName -> "SecuritiesAccountName" - | FIX_PartySubIDType_CashAccountName -> "CashAccountName" - | FIX_PartySubIDType_Department -> "Department" - | FIX_PartySubIDType_LocationDesk -> "LocationDesk" - | FIX_PartySubIDType_PositionAccountType -> "PositionAccountType" - ) -;; - -let paymentmethod_to_string (d) = - (match d with - | FIX_PaymentMethod_CREST -> "CREST" - | FIX_PaymentMethod_NSCC -> "NSCC" - | FIX_PaymentMethod_Euroclear -> "Euroclear" - | FIX_PaymentMethod_Clearstream -> "Clearstream" - | FIX_PaymentMethod_Cheque -> "Cheque" - | FIX_PaymentMethod_TelegraphicTransfer -> "TelegraphicTransfer" - | FIX_PaymentMethod_FedWire -> "FedWire" - | FIX_PaymentMethod_DebitCard -> "DebitCard" - | FIX_PaymentMethod_DirectDebit -> "DirectDebit" - | FIX_PaymentMethod_DirectCredit -> "DirectCredit" - | FIX_PaymentMethod_CreditCard -> "CreditCard" - | FIX_PaymentMethod_ACHDebit -> "ACHDebit" - | FIX_PaymentMethod_ACHCredit -> "ACHCredit" - | FIX_PaymentMethod_BPAY -> "BPAY" - | FIX_PaymentMethod_HighValueClearingSystem -> "HighValueClearingSystem" - ) -;; - -let peglimittype_to_string (d) = - (match d with - | FIX_PegLimitType_OrBetter -> "OrBetter" - | FIX_PegLimitType_Strict -> "Strict" - | FIX_PegLimitType_OrWorse -> "OrWorse" - ) -;; - -let pegmovetype_to_string (d) = - (match d with - | FIX_PegMoveType_Floating -> "Floating" - | FIX_PegMoveType_Fixed -> "Fixed" - ) -;; - -let pegoffsettype_to_string (d) = - (match d with - | FIX_PegOffsetType_Price -> "Price" - | FIX_PegOffsetType_BasisPoints -> "BasisPoints" - | FIX_PegOffsetType_Ticks -> "Ticks" - | FIX_PegOffsetType_PriceTier -> "PriceTier" - ) -;; - -let pegrounddirection_to_string (d) = - (match d with - | FIX_PegRoundDirection_MoreAggressive -> "MoreAggressive" - | FIX_PegRoundDirection_MorePassive -> "MorePassive" - ) -;; - -let pegscope_to_string (d) = - (match d with - | FIX_PegScope_Local -> "Local" - | FIX_PegScope_National -> "National" - | FIX_PegScope_Global -> "Global" - | FIX_PegScope_NationalExcludingLocal -> "NationalExcludingLocal" - ) -;; - -let posamttype_to_string (d) = - (match d with - | FIX_PosAmtType_FinalMarkToMarketAmount -> "FinalMarkToMarketAmount" - | FIX_PosAmtType_IncrementalMarkToMarketAmount -> "IncrementalMarkToMarketAmount" - | FIX_PosAmtType_TradeVariationAmount -> "TradeVariationAmount" - | FIX_PosAmtType_StartOfDayMarkToMarketAmount -> "StartOfDayMarkToMarketAmount" - | FIX_PosAmtType_PremiumAmount -> "PremiumAmount" - | FIX_PosAmtType_CashResidualAmount -> "CashResidualAmount" - | FIX_PosAmtType_CashAmount -> "CashAmount" - | FIX_PosAmtType_ValueAdjustedAmount -> "ValueAdjustedAmount" - ) -;; - -let posmaintaction_to_string (d) = - (match d with - | FIX_PosMaintAction_New -> "New" - | FIX_PosMaintAction_Replace -> "Replace" - | FIX_PosMaintAction_Cancel -> "Cancel" - ) -;; - -let posmaintresult_to_string (d) = - (match d with - | FIX_PosMaintResult_SuccessfulCompletion -> "SuccessfulCompletion" - | FIX_PosMaintResult_Rejected -> "Rejected" - | FIX_PosMaintResult_Other -> "Other" - ) -;; - -let posmaintstatus_to_string (d) = - (match d with - | FIX_PosMaintStatus_Accepted -> "Accepted" - | FIX_PosMaintStatus_AcceptedWithWarnings -> "AcceptedWithWarnings" - | FIX_PosMaintStatus_Rejected -> "Rejected" - | FIX_PosMaintStatus_Completed -> "Completed" - | FIX_PosMaintStatus_CompletedWithWarnings -> "CompletedWithWarnings" - ) -;; - -let posqtystatus_to_string (d) = - (match d with - | FIX_PosQtyStatus_Submitted -> "Submitted" - | FIX_PosQtyStatus_Accepted -> "Accepted" - | FIX_PosQtyStatus_Rejected -> "Rejected" - ) -;; - -let posreqresult_to_string (d) = - (match d with - | FIX_PosReqResult_ValidRequest -> "ValidRequest" - | FIX_PosReqResult_InvalidOrUnsupportedRequest -> "InvalidOrUnsupportedRequest" - | FIX_PosReqResult_NoPositionsFoundThatMatchCriteria -> "NoPositionsFoundThatMatchCriteria" - | FIX_PosReqResult_NotAuthorizedToRequestPositions -> "NotAuthorizedToRequestPositions" - | FIX_PosReqResult_RequestForPositionNotSupported -> "RequestForPositionNotSupported" - | FIX_PosReqResult_Other -> "Other" - ) -;; - -let posreqstatus_to_string (d) = - (match d with - | FIX_PosReqStatus_Completed -> "Completed" - | FIX_PosReqStatus_CompletedWithWarnings -> "CompletedWithWarnings" - | FIX_PosReqStatus_Rejected -> "Rejected" - ) -;; - -let posreqtype_to_string (d) = - (match d with - | FIX_PosReqType_Positions -> "Positions" - | FIX_PosReqType_Trades -> "Trades" - | FIX_PosReqType_Exercises -> "Exercises" - | FIX_PosReqType_Assignments -> "Assignments" - ) -;; - -let postranstype_to_string (d) = - (match d with - | FIX_PosTransType_Exercise -> "Exercise" - | FIX_PosTransType_DoNotExercise -> "DoNotExercise" - | FIX_PosTransType_PositionAdjustment -> "PositionAdjustment" - | FIX_PosTransType_PositionChangeSubmission -> "PositionChangeSubmission" - | FIX_PosTransType_Pledge -> "Pledge" - ) -;; - -let postype_to_string (d) = - (match d with - | FIX_PosType_TransactionQuantity -> "TransactionQuantity" - | FIX_PosType_IntraSpreadQty -> "IntraSpreadQty" - | FIX_PosType_InterSpreadQty -> "InterSpreadQty" - | FIX_PosType_EndOfDayQty -> "EndOfDayQty" - | FIX_PosType_StartOfDayQty -> "StartOfDayQty" - | FIX_PosType_OptionExerciseQty -> "OptionExerciseQty" - | FIX_PosType_OptionAssignment -> "OptionAssignment" - | FIX_PosType_TransactionFromExercise -> "TransactionFromExercise" - | FIX_PosType_TransactionFromAssignment -> "TransactionFromAssignment" - | FIX_PosType_PitTradeQty -> "PitTradeQty" - | FIX_PosType_TransferTradeQty -> "TransferTradeQty" - | FIX_PosType_ElectronicTradeQty -> "ElectronicTradeQty" - | FIX_PosType_AllocationTradeQty -> "AllocationTradeQty" - | FIX_PosType_AdjustmentQty -> "AdjustmentQty" - | FIX_PosType_AsOfTradeQty -> "AsOfTradeQty" - | FIX_PosType_DeliveryQty -> "DeliveryQty" - | FIX_PosType_TotalTransactionQty -> "TotalTransactionQty" - | FIX_PosType_CrossMarginQty -> "CrossMarginQty" - | FIX_PosType_IntegralSplit -> "IntegralSplit" - ) -;; - -let positioneffect_to_string (d) = - (match d with - | FIX_PositionEffect_Open -> "Open" - | FIX_PositionEffect_Close -> "Close" - | FIX_PositionEffect_Rolled -> "Rolled" - | FIX_PositionEffect_FIFO -> "FIFO" - ) -;; - -let possdupflag_to_string (d) = - (match d with - | FIX_PossDupFlag_PossibleDuplicate -> "PossibleDuplicate" - | FIX_PossDupFlag_OriginalTransmission -> "OriginalTransmission" - ) -;; - -let possresend_to_string (d) = - (match d with - | FIX_PossResend_PossibleResend -> "PossibleResend" - | FIX_PossResend_OriginalTransmission -> "OriginalTransmission" - ) -;; - -let preallocmethod_to_string (d) = - (match d with - | FIX_PreallocMethod_ProRata -> "ProRata" - | FIX_PreallocMethod_DoNotProRata -> "DoNotProRata" - ) -;; - -let previouslyreported_to_string (d) = - (match d with - | FIX_PreviouslyReported_PerviouslyReportedToCounterparty -> "PerviouslyReportedToCounterparty" - | FIX_PreviouslyReported_NotReportedToCounterparty -> "NotReportedToCounterparty" - ) -;; - -let pricetype_to_string (d) = - (match d with - | FIX_PriceType_Percentage -> "Percentage" - | FIX_PriceType_PerUnit -> "PerUnit" - | FIX_PriceType_FixedAmount -> "FixedAmount" - | FIX_PriceType_Discount -> "Discount" - | FIX_PriceType_Premium -> "Premium" - | FIX_PriceType_Spread -> "Spread" - | FIX_PriceType_TEDPrice -> "TEDPrice" - | FIX_PriceType_TEDYield -> "TEDYield" - | FIX_PriceType_Yield -> "Yield" - | FIX_PriceType_FixedCabinetTradePrice -> "FixedCabinetTradePrice" - | FIX_PriceType_VariableCabinetTradePrice -> "VariableCabinetTradePrice" - ) -;; - -let priorityindicator_to_string (d) = - (match d with - | FIX_PriorityIndicator_PriorityUnchanged -> "PriorityUnchanged" - | FIX_PriorityIndicator_LostPriorityAsResultOfOrderChange -> "LostPriorityAsResultOfOrderChange" - ) -;; - -let processcode_to_string (d) = - (match d with - | FIX_ProcessCode_Regular -> "Regular" - | FIX_ProcessCode_SoftDollar -> "SoftDollar" - | FIX_ProcessCode_StepIn -> "StepIn" - | FIX_ProcessCode_StepOut -> "StepOut" - | FIX_ProcessCode_SoftDollarStepIn -> "SoftDollarStepIn" - | FIX_ProcessCode_SoftDollarStepOut -> "SoftDollarStepOut" - | FIX_ProcessCode_PlanSponsor -> "PlanSponsor" - ) -;; - -let product_to_string (d) = - (match d with - | FIX_Product_AGENCY -> "AGENCY" - | FIX_Product_COMMODITY -> "COMMODITY" - | FIX_Product_CORPORATE -> "CORPORATE" - | FIX_Product_CURRENCY -> "CURRENCY" - | FIX_Product_EQUITY -> "EQUITY" - | FIX_Product_GOVERNMENT -> "GOVERNMENT" - | FIX_Product_INDEX -> "INDEX" - | FIX_Product_LOAN -> "LOAN" - | FIX_Product_MONEYMARKET -> "MONEYMARKET" - | FIX_Product_MORTGAGE -> "MORTGAGE" - | FIX_Product_MUNICIPAL -> "MUNICIPAL" - | FIX_Product_OTHER -> "OTHER" - | FIX_Product_FINANCING -> "FINANCING" - ) -;; - -let progrptreqs_to_string (d) = - (match d with - | FIX_ProgRptReqs_BuySideRequests -> "BuySideRequests" - | FIX_ProgRptReqs_SellSideSends -> "SellSideSends" - | FIX_ProgRptReqs_RealTimeExecutionReports -> "RealTimeExecutionReports" - ) -;; - -let publishtrdindicator_to_string (d) = - (match d with - | FIX_PublishTrdIndicator_ReportTrade -> "ReportTrade" - | FIX_PublishTrdIndicator_DoNotReportTrade -> "DoNotReportTrade" - ) -;; - -let putorcall_to_string (d) = - (match d with - | FIX_PutOrCall_Put -> "Put" - | FIX_PutOrCall_Call -> "Call" - ) -;; - -let qtytype_to_string (d) = - (match d with - | FIX_QtyType_Units -> "Units" - | FIX_QtyType_Contracts -> "Contracts" - ) -;; - -let quotecanceltype_to_string (d) = - (match d with - | FIX_QuoteCancelType_CancelForOneOrMoreSecurities -> "CancelForOneOrMoreSecurities" - | FIX_QuoteCancelType_CancelForSecurityType -> "CancelForSecurityType" - | FIX_QuoteCancelType_CancelForUnderlyingSecurity -> "CancelForUnderlyingSecurity" - | FIX_QuoteCancelType_CancelAllQuotes -> "CancelAllQuotes" - ) -;; - -let quotecondition_to_string (d) = - (match d with - | FIX_QuoteCondition_Open -> "Open" - | FIX_QuoteCondition_Closed -> "Closed" - | FIX_QuoteCondition_ExchangeBest -> "ExchangeBest" - | FIX_QuoteCondition_ConsolidatedBest -> "ConsolidatedBest" - | FIX_QuoteCondition_Locked -> "Locked" - | FIX_QuoteCondition_Crossed -> "Crossed" - | FIX_QuoteCondition_Depth -> "Depth" - | FIX_QuoteCondition_FastTrading -> "FastTrading" - | FIX_QuoteCondition_NonFirm -> "NonFirm" - ) -;; - -let quotepricetype_to_string (d) = - (match d with - | FIX_QuotePriceType_Percent -> "Percent" - | FIX_QuotePriceType_PerShare -> "PerShare" - | FIX_QuotePriceType_FixedAmount -> "FixedAmount" - | FIX_QuotePriceType_Discount -> "Discount" - | FIX_QuotePriceType_Premium -> "Premium" - | FIX_QuotePriceType_Spread -> "Spread" - | FIX_QuotePriceType_TEDPrice -> "TEDPrice" - | FIX_QuotePriceType_TEDYield -> "TEDYield" - | FIX_QuotePriceType_YieldSpread -> "YieldSpread" - | FIX_QuotePriceType_Yield -> "Yield" - ) -;; - -let quoterejectreason_to_string (d) = - (match d with - | FIX_QuoteRejectReason_UnknownSymbol -> "UnknownSymbol" - | FIX_QuoteRejectReason_Exchange -> "Exchange" - | FIX_QuoteRejectReason_QuoteRequestExceedsLimit -> "QuoteRequestExceedsLimit" - | FIX_QuoteRejectReason_TooLateToEnter -> "TooLateToEnter" - | FIX_QuoteRejectReason_UnknownQuote -> "UnknownQuote" - | FIX_QuoteRejectReason_DuplicateQuote -> "DuplicateQuote" - | FIX_QuoteRejectReason_InvalidBid -> "InvalidBid" - | FIX_QuoteRejectReason_InvalidPrice -> "InvalidPrice" - | FIX_QuoteRejectReason_NotAuthorizedToQuoteSecurity -> "NotAuthorizedToQuoteSecurity" - | FIX_QuoteRejectReason_Other -> "Other" - ) -;; - -let quoterequestrejectreason_to_string (d) = - (match d with - | FIX_QuoteRequestRejectReason_UnknownSymbol -> "UnknownSymbol" - | FIX_QuoteRequestRejectReason_Exchange -> "Exchange" - | FIX_QuoteRequestRejectReason_QuoteRequestExceedsLimit -> "QuoteRequestExceedsLimit" - | FIX_QuoteRequestRejectReason_TooLateToEnter -> "TooLateToEnter" - | FIX_QuoteRequestRejectReason_InvalidPrice -> "InvalidPrice" - | FIX_QuoteRequestRejectReason_NotAuthorizedToRequestQuote -> "NotAuthorizedToRequestQuote" - | FIX_QuoteRequestRejectReason_NoMatchForInquiry -> "NoMatchForInquiry" - | FIX_QuoteRequestRejectReason_NoMarketForInstrument -> "NoMarketForInstrument" - | FIX_QuoteRequestRejectReason_NoInventory -> "NoInventory" - | FIX_QuoteRequestRejectReason_Pass -> "Pass" - | FIX_QuoteRequestRejectReason_Other -> "Other" - ) -;; - -let quoterequesttype_to_string (d) = - (match d with - | FIX_QuoteRequestType_Manual -> "Manual" - | FIX_QuoteRequestType_Automatic -> "Automatic" - ) -;; - -let quoteresptype_to_string (d) = - (match d with - | FIX_QuoteRespType_Hit -> "Hit" - | FIX_QuoteRespType_Counter -> "Counter" - | FIX_QuoteRespType_Expired -> "Expired" - | FIX_QuoteRespType_Cover -> "Cover" - | FIX_QuoteRespType_DoneAway -> "DoneAway" - | FIX_QuoteRespType_Pass -> "Pass" - ) -;; - -let quoteresponselevel_to_string (d) = - (match d with - | FIX_QuoteResponseLevel_NoAcknowledgement -> "NoAcknowledgement" - | FIX_QuoteResponseLevel_AcknowledgeOnlyNegativeOrErroneousQuotes -> "AcknowledgeOnlyNegativeOrErroneousQuotes" - | FIX_QuoteResponseLevel_AcknowledgeEachQuoteMessage -> "AcknowledgeEachQuoteMessage" - ) -;; - -let quotestatus_to_string (d) = - (match d with - | FIX_QuoteStatus_Accepted -> "Accepted" - | FIX_QuoteStatus_CancelForSymbol -> "CancelForSymbol" - | FIX_QuoteStatus_CanceledForSecurityType -> "CanceledForSecurityType" - | FIX_QuoteStatus_CanceledForUnderlying -> "CanceledForUnderlying" - | FIX_QuoteStatus_CanceledAll -> "CanceledAll" - | FIX_QuoteStatus_Rejected -> "Rejected" - | FIX_QuoteStatus_RemovedFromMarket -> "RemovedFromMarket" - | FIX_QuoteStatus_Expired -> "Expired" - | FIX_QuoteStatus_Query -> "Query" - | FIX_QuoteStatus_QuoteNotFound -> "QuoteNotFound" - | FIX_QuoteStatus_Pending -> "Pending" - | FIX_QuoteStatus_Pass -> "Pass" - | FIX_QuoteStatus_LockedMarketWarning -> "LockedMarketWarning" - | FIX_QuoteStatus_CrossMarketWarning -> "CrossMarketWarning" - | FIX_QuoteStatus_CanceledDueToLockMarket -> "CanceledDueToLockMarket" - | FIX_QuoteStatus_CanceledDueToCrossMarket -> "CanceledDueToCrossMarket" - ) -;; - -let quotetype_to_string (d) = - (match d with - | FIX_QuoteType_Indicative -> "Indicative" - | FIX_QuoteType_Tradeable -> "Tradeable" - | FIX_QuoteType_RestrictedTradeable -> "RestrictedTradeable" - | FIX_QuoteType_Counter -> "Counter" - ) -;; - -let registrejreasoncode_to_string (d) = - (match d with - | FIX_RegistRejReasonCode_InvalidAccountType -> "InvalidAccountType" - | FIX_RegistRejReasonCode_InvalidTaxExemptType -> "InvalidTaxExemptType" - | FIX_RegistRejReasonCode_InvalidOwnershipType -> "InvalidOwnershipType" - | FIX_RegistRejReasonCode_NoRegDetails -> "NoRegDetails" - | FIX_RegistRejReasonCode_InvalidRegSeqNo -> "InvalidRegSeqNo" - | FIX_RegistRejReasonCode_InvalidRegDetails -> "InvalidRegDetails" - | FIX_RegistRejReasonCode_InvalidMailingDetails -> "InvalidMailingDetails" - | FIX_RegistRejReasonCode_InvalidMailingInstructions -> "InvalidMailingInstructions" - | FIX_RegistRejReasonCode_InvalidInvestorID -> "InvalidInvestorID" - | FIX_RegistRejReasonCode_InvalidInvestorIDSource -> "InvalidInvestorIDSource" - | FIX_RegistRejReasonCode_InvalidDateOfBirth -> "InvalidDateOfBirth" - | FIX_RegistRejReasonCode_InvalidCountry -> "InvalidCountry" - | FIX_RegistRejReasonCode_InvalidDistribInstns -> "InvalidDistribInstns" - | FIX_RegistRejReasonCode_InvalidPercentage -> "InvalidPercentage" - | FIX_RegistRejReasonCode_InvalidPaymentMethod -> "InvalidPaymentMethod" - | FIX_RegistRejReasonCode_InvalidAccountName -> "InvalidAccountName" - | FIX_RegistRejReasonCode_InvalidAgentCode -> "InvalidAgentCode" - | FIX_RegistRejReasonCode_InvalidAccountNum -> "InvalidAccountNum" - | FIX_RegistRejReasonCode_Other -> "Other" - ) -;; - -let registstatus_to_string (d) = - (match d with - | FIX_RegistStatus_Accepted -> "Accepted" - | FIX_RegistStatus_Rejected -> "Rejected" - | FIX_RegistStatus_Held -> "Held" - | FIX_RegistStatus_Reminder -> "Reminder" - ) -;; - -let registtranstype_to_string (d) = - (match d with - | FIX_RegistTransType_New -> "New" - | FIX_RegistTransType_Replace -> "Replace" - | FIX_RegistTransType_Cancel -> "Cancel" - ) -;; - -let reporttoexch_to_string (d) = - (match d with - | FIX_ReportToExch_ReceiverReports -> "ReceiverReports" - | FIX_ReportToExch_SenderReports -> "SenderReports" - ) -;; - -let resetseqnumflag_to_string (d) = - (match d with - | FIX_ResetSeqNumFlag_Yes -> "Yes" - | FIX_ResetSeqNumFlag_No -> "No" - ) -;; - -let responsetransporttype_to_string (d) = - (match d with - | FIX_ResponseTransportType_Inband -> "Inband" - | FIX_ResponseTransportType_OutOfBand -> "OutOfBand" - ) -;; - -let roundingdirection_to_string (d) = - (match d with - | FIX_RoundingDirection_RoundToNearest -> "RoundToNearest" - | FIX_RoundingDirection_RoundDown -> "RoundDown" - | FIX_RoundingDirection_RoundUp -> "RoundUp" - ) -;; - -let routingtype_to_string (d) = - (match d with - | FIX_RoutingType_TargetFirm -> "TargetFirm" - | FIX_RoutingType_TargetList -> "TargetList" - | FIX_RoutingType_BlockFirm -> "BlockFirm" - | FIX_RoutingType_BlockList -> "BlockList" - ) -;; - -let scope_to_string (d) = - (match d with - | FIX_Scope_LocalMarket -> "LocalMarket" - | FIX_Scope_National -> "National" - | FIX_Scope_Global -> "Global" - ) -;; - -let securityidsource_to_string (d) = - (match d with - | FIX_SecurityIDSource_CUSIP -> "CUSIP" - | FIX_SecurityIDSource_SEDOL -> "SEDOL" - | FIX_SecurityIDSource_QUIK -> "QUIK" - | FIX_SecurityIDSource_ISINNumber -> "ISINNumber" - | FIX_SecurityIDSource_RICCode -> "RICCode" - | FIX_SecurityIDSource_ISOCurrencyCode -> "ISOCurrencyCode" - | FIX_SecurityIDSource_ISOCountryCode -> "ISOCountryCode" - | FIX_SecurityIDSource_ExchangeSymbol -> "ExchangeSymbol" - | FIX_SecurityIDSource_ConsolidatedTapeAssociation -> "ConsolidatedTapeAssociation" - | FIX_SecurityIDSource_BloombergSymbol -> "BloombergSymbol" - | FIX_SecurityIDSource_Wertpapier -> "Wertpapier" - | FIX_SecurityIDSource_Dutch -> "Dutch" - | FIX_SecurityIDSource_Valoren -> "Valoren" - | FIX_SecurityIDSource_Sicovam -> "Sicovam" - | FIX_SecurityIDSource_Belgian -> "Belgian" - | FIX_SecurityIDSource_Common -> "Common" - | FIX_SecurityIDSource_ClearingHouse -> "ClearingHouse" - | FIX_SecurityIDSource_ISDAFpMLSpecification -> "ISDAFpMLSpecification" - | FIX_SecurityIDSource_OptionPriceReportingAuthority -> "OptionPriceReportingAuthority" - ) -;; - -let securitylistrequesttype_to_string (d) = - (match d with - | FIX_SecurityListRequestType_Symbol -> "Symbol" - | FIX_SecurityListRequestType_SecurityTypeAnd -> "SecurityTypeAnd" - | FIX_SecurityListRequestType_Product -> "Product" - | FIX_SecurityListRequestType_TradingSessionID -> "TradingSessionID" - | FIX_SecurityListRequestType_AllSecurities -> "AllSecurities" - ) -;; - -let securityrequestresult_to_string (d) = - (match d with - | FIX_SecurityRequestResult_ValidRequest -> "ValidRequest" - | FIX_SecurityRequestResult_InvalidOrUnsupportedRequest -> "InvalidOrUnsupportedRequest" - | FIX_SecurityRequestResult_NoInstrumentsFound -> "NoInstrumentsFound" - | FIX_SecurityRequestResult_NotAuthorizedToRetrieveInstrumentData -> "NotAuthorizedToRetrieveInstrumentData" - | FIX_SecurityRequestResult_InstrumentDataTemporarilyUnavailable -> "InstrumentDataTemporarilyUnavailable" - | FIX_SecurityRequestResult_RequestForInstrumentDataNotSupported -> "RequestForInstrumentDataNotSupported" - ) -;; - -let securityrequesttype_to_string (d) = - (match d with - | FIX_SecurityRequestType_RequestSecurityIdentityAndSpecifications -> "RequestSecurityIdentityAndSpecifications" - | FIX_SecurityRequestType_RequestSecurityIdentityForSpecifications -> "RequestSecurityIdentityForSpecifications" - | FIX_SecurityRequestType_RequestListSecurityTypes -> "RequestListSecurityTypes" - | FIX_SecurityRequestType_RequestListSecurities -> "RequestListSecurities" - ) -;; - -let securityresponsetype_to_string (d) = - (match d with - | FIX_SecurityResponseType_AcceptAsIs -> "AcceptAsIs" - | FIX_SecurityResponseType_AcceptWithRevisions -> "AcceptWithRevisions" - | FIX_SecurityResponseType_RejectSecurityProposal -> "RejectSecurityProposal" - | FIX_SecurityResponseType_CannotMatchSelectionCriteria -> "CannotMatchSelectionCriteria" - ) -;; - -let securitytradingstatus_to_string (d) = - (match d with - | FIX_SecurityTradingStatus_OpeningDelay -> "OpeningDelay" - | FIX_SecurityTradingStatus_TradingHalt -> "TradingHalt" - | FIX_SecurityTradingStatus_Resume -> "Resume" - | FIX_SecurityTradingStatus_NoOpen -> "NoOpen" - | FIX_SecurityTradingStatus_PriceIndication -> "PriceIndication" - | FIX_SecurityTradingStatus_TradingRangeIndication -> "TradingRangeIndication" - | FIX_SecurityTradingStatus_MarketImbalanceBuy -> "MarketImbalanceBuy" - | FIX_SecurityTradingStatus_MarketImbalanceSell -> "MarketImbalanceSell" - | FIX_SecurityTradingStatus_MarketOnCloseImbalanceBuy -> "MarketOnCloseImbalanceBuy" - | FIX_SecurityTradingStatus_MarketOnCloseImbalanceSell -> "MarketOnCloseImbalanceSell" - | FIX_SecurityTradingStatus_NoMarketImbalance -> "NoMarketImbalance" - | FIX_SecurityTradingStatus_NoMarketOnCloseImbalance -> "NoMarketOnCloseImbalance" - | FIX_SecurityTradingStatus_ITSPreOpening -> "ITSPreOpening" - | FIX_SecurityTradingStatus_NewPriceIndication -> "NewPriceIndication" - | FIX_SecurityTradingStatus_TradeDisseminationTime -> "TradeDisseminationTime" - | FIX_SecurityTradingStatus_ReadyToTrade -> "ReadyToTrade" - | FIX_SecurityTradingStatus_NotAvailableForTrading -> "NotAvailableForTrading" - | FIX_SecurityTradingStatus_NotTradedOnThisMarket -> "NotTradedOnThisMarket" - | FIX_SecurityTradingStatus_UnknownOrInvalid -> "UnknownOrInvalid" - | FIX_SecurityTradingStatus_PreOpen -> "PreOpen" - | FIX_SecurityTradingStatus_OpeningRotation -> "OpeningRotation" - | FIX_SecurityTradingStatus_FastMarket -> "FastMarket" - ) -;; - -let securitytype_to_string (d) = - (match d with - | FIX_SecurityType_Future -> "Future" - | FIX_SecurityType_Option -> "Option" - | FIX_SecurityType_EuroSupranationalCoupons -> "EuroSupranationalCoupons" - | FIX_SecurityType_FederalAgencyCoupon -> "FederalAgencyCoupon" - | FIX_SecurityType_FederalAgencyDiscountNote -> "FederalAgencyDiscountNote" - | FIX_SecurityType_PrivateExportFunding -> "PrivateExportFunding" - | FIX_SecurityType_USDSupranationalCoupons -> "USDSupranationalCoupons" - | FIX_SecurityType_CorporateBond -> "CorporateBond" - | FIX_SecurityType_CorporatePrivatePlacement -> "CorporatePrivatePlacement" - | FIX_SecurityType_ConvertibleBond -> "ConvertibleBond" - | FIX_SecurityType_DualCurrency -> "DualCurrency" - | FIX_SecurityType_EuroCorporateBond -> "EuroCorporateBond" - | FIX_SecurityType_IndexedLinked -> "IndexedLinked" - | FIX_SecurityType_StructuredNotes -> "StructuredNotes" - | FIX_SecurityType_YankeeCorporateBond -> "YankeeCorporateBond" - | FIX_SecurityType_ForeignExchangeContract -> "ForeignExchangeContract" - | FIX_SecurityType_CommonStock -> "CommonStock" - | FIX_SecurityType_PreferredStock -> "PreferredStock" - | FIX_SecurityType_BradyBond -> "BradyBond" - | FIX_SecurityType_EuroSovereigns -> "EuroSovereigns" - | FIX_SecurityType_USTreasuryBond -> "USTreasuryBond" - | FIX_SecurityType_InterestStripFromAnyBondOrNote -> "InterestStripFromAnyBondOrNote" - | FIX_SecurityType_TreasuryInflationProtectedSecurities -> "TreasuryInflationProtectedSecurities" - | FIX_SecurityType_PrincipalStripOfACallableBondOrNote -> "PrincipalStripOfACallableBondOrNote" - | FIX_SecurityType_PrincipalStripFromANonCallableBondOrNote -> "PrincipalStripFromANonCallableBondOrNote" - | FIX_SecurityType_USTreasuryNoteOld -> "USTreasuryNoteOld" - | FIX_SecurityType_USTreasuryBillOld -> "USTreasuryBillOld" - | FIX_SecurityType_USTreasuryNote -> "USTreasuryNote" - | FIX_SecurityType_USTreasuryBill -> "USTreasuryBill" - | FIX_SecurityType_Repurchase -> "Repurchase" - | FIX_SecurityType_Forward -> "Forward" - | FIX_SecurityType_BuySellback -> "BuySellback" - | FIX_SecurityType_SecuritiesLoan -> "SecuritiesLoan" - | FIX_SecurityType_SecuritiesPledge -> "SecuritiesPledge" - | FIX_SecurityType_TermLoan -> "TermLoan" - | FIX_SecurityType_RevolverLoan -> "RevolverLoan" - | FIX_SecurityType_Revolver -> "Revolver" - | FIX_SecurityType_BridgeLoan -> "BridgeLoan" - | FIX_SecurityType_LetterOfCredit -> "LetterOfCredit" - | FIX_SecurityType_SwingLineFacility -> "SwingLineFacility" - | FIX_SecurityType_DebtorInPossession -> "DebtorInPossession" - | FIX_SecurityType_Defaulted -> "Defaulted" - | FIX_SecurityType_Withdrawn -> "Withdrawn" - | FIX_SecurityType_Replaced -> "Replaced" - | FIX_SecurityType_Matured -> "Matured" - | FIX_SecurityType_Amended -> "Amended" - | FIX_SecurityType_Retired -> "Retired" - | FIX_SecurityType_BankersAcceptance -> "BankersAcceptance" - | FIX_SecurityType_BankNotes -> "BankNotes" - | FIX_SecurityType_BillOfExchanges -> "BillOfExchanges" - | FIX_SecurityType_CertificateOfDeposit -> "CertificateOfDeposit" - | FIX_SecurityType_CallLoans -> "CallLoans" - | FIX_SecurityType_CommercialPaper -> "CommercialPaper" - | FIX_SecurityType_DepositNotes -> "DepositNotes" - | FIX_SecurityType_EuroCertificateOfDeposit -> "EuroCertificateOfDeposit" - | FIX_SecurityType_EuroCommercialPaper -> "EuroCommercialPaper" - | FIX_SecurityType_LiquidityNote -> "LiquidityNote" - | FIX_SecurityType_MediumTermNotes -> "MediumTermNotes" - | FIX_SecurityType_Overnight -> "Overnight" - | FIX_SecurityType_PromissoryNote -> "PromissoryNote" - | FIX_SecurityType_PlazosFijos -> "PlazosFijos" - | FIX_SecurityType_ShortTermLoanNote -> "ShortTermLoanNote" - | FIX_SecurityType_TimeDeposit -> "TimeDeposit" - | FIX_SecurityType_ExtendedCommNote -> "ExtendedCommNote" - | FIX_SecurityType_YankeeCertificateOfDeposit -> "YankeeCertificateOfDeposit" - | FIX_SecurityType_AssetBackedSecurities -> "AssetBackedSecurities" - | FIX_SecurityType_Corp -> "Corp" - | FIX_SecurityType_CollateralizedMortgageObligation -> "CollateralizedMortgageObligation" - | FIX_SecurityType_IOETTEMortgage -> "IOETTEMortgage" - | FIX_SecurityType_MortgageBackedSecurities -> "MortgageBackedSecurities" - | FIX_SecurityType_MortgageInterestOnly -> "MortgageInterestOnly" - | FIX_SecurityType_MortgagePrincipalOnly -> "MortgagePrincipalOnly" - | FIX_SecurityType_MortgagePrivatePlacement -> "MortgagePrivatePlacement" - | FIX_SecurityType_MiscellaneousPassThrough -> "MiscellaneousPassThrough" - | FIX_SecurityType_Pfandbriefe -> "Pfandbriefe" - | FIX_SecurityType_ToBeAnnounced -> "ToBeAnnounced" - | FIX_SecurityType_OtherAnticipationNotes -> "OtherAnticipationNotes" - | FIX_SecurityType_CertificateOfObligation -> "CertificateOfObligation" - | FIX_SecurityType_CertificateOfParticipation -> "CertificateOfParticipation" - | FIX_SecurityType_GeneralObligationBonds -> "GeneralObligationBonds" - | FIX_SecurityType_MandatoryTender -> "MandatoryTender" - | FIX_SecurityType_RevenueAnticipationNote -> "RevenueAnticipationNote" - | FIX_SecurityType_RevenueBonds -> "RevenueBonds" - | FIX_SecurityType_SpecialAssessment -> "SpecialAssessment" - | FIX_SecurityType_SpecialObligation -> "SpecialObligation" - | FIX_SecurityType_SpecialTax -> "SpecialTax" - | FIX_SecurityType_TaxAnticipationNote -> "TaxAnticipationNote" - | FIX_SecurityType_TaxAllocation -> "TaxAllocation" - | FIX_SecurityType_TaxExemptCommercialPaper -> "TaxExemptCommercialPaper" - | FIX_SecurityType_TaxRevenueAnticipationNote -> "TaxRevenueAnticipationNote" - | FIX_SecurityType_VariableRateDemandNote -> "VariableRateDemandNote" - | FIX_SecurityType_Warrant -> "Warrant" - | FIX_SecurityType_MutualFund -> "MutualFund" - | FIX_SecurityType_MultilegInstrument -> "MultilegInstrument" - | FIX_SecurityType_NoSecurityType -> "NoSecurityType" - ) -;; - -let settlcurrfxratecalc_to_string (d) = - (match d with - | FIX_SettlCurrFxRateCalc_Multiply -> "Multiply" - | FIX_SettlCurrFxRateCalc_Divide -> "Divide" - ) -;; - -let settldeliverytype_to_string (d) = - (match d with - | FIX_SettlDeliveryType_Versus -> "Versus" - | FIX_SettlDeliveryType_Free -> "Free" - | FIX_SettlDeliveryType_TriParty -> "TriParty" - | FIX_SettlDeliveryType_HoldInCustody -> "HoldInCustody" - ) -;; - -let settlinstmode_to_string (d) = - (match d with - | FIX_SettlInstMode_StandingInstructionsProvided -> "StandingInstructionsProvided" - | FIX_SettlInstMode_SpecificOrderForASingleAccount -> "SpecificOrderForASingleAccount" - | FIX_SettlInstMode_RequestReject -> "RequestReject" - ) -;; - -let settlinstreqrejcode_to_string (d) = - (match d with - | FIX_SettlInstReqRejCode_UnableToProcessRequest -> "UnableToProcessRequest" - | FIX_SettlInstReqRejCode_UnknownAccount -> "UnknownAccount" - | FIX_SettlInstReqRejCode_NoMatchingSettlementInstructionsFound -> "NoMatchingSettlementInstructionsFound" - | FIX_SettlInstReqRejCode_Other -> "Other" - ) -;; - -let settlinstsource_to_string (d) = - (match d with - | FIX_SettlInstSource_BrokerCredit -> "BrokerCredit" - | FIX_SettlInstSource_Institution -> "Institution" - | FIX_SettlInstSource_Investor -> "Investor" - ) -;; - -let settlinsttranstype_to_string (d) = - (match d with - | FIX_SettlInstTransType_New -> "New" - | FIX_SettlInstTransType_Cancel -> "Cancel" - | FIX_SettlInstTransType_Replace -> "Replace" - | FIX_SettlInstTransType_Restate -> "Restate" - ) -;; - -let settlpricetype_to_string (d) = - (match d with - | FIX_SettlPriceType_Final -> "Final" - | FIX_SettlPriceType_Theoretical -> "Theoretical" - ) -;; - -let settlsessid_to_string (d) = - (match d with - | FIX_SettlSessID_Intraday -> "Intraday" - | FIX_SettlSessID_RegularTradingHours -> "RegularTradingHours" - | FIX_SettlSessID_ElectronicTradingHours -> "ElectronicTradingHours" - ) -;; - -let settltype_to_string (d) = - (match d with - | FIX_SettlType_Regular -> "Regular" - | FIX_SettlType_Cash -> "Cash" - | FIX_SettlType_NextDay -> "NextDay" - | FIX_SettlType_TPlus2 -> "TPlus2" - | FIX_SettlType_TPlus3 -> "TPlus3" - | FIX_SettlType_TPlus4 -> "TPlus4" - | FIX_SettlType_Future -> "Future" - | FIX_SettlType_WhenAndIfIssued -> "WhenAndIfIssued" - | FIX_SettlType_SellersOption -> "SellersOption" - | FIX_SettlType_TPlus5 -> "TPlus5" - ) -;; - -let shortsalereason_to_string (d) = - (match d with - | FIX_ShortSaleReason_DealerSoldShort -> "DealerSoldShort" - | FIX_ShortSaleReason_DealerSoldShortExempt -> "DealerSoldShortExempt" - | FIX_ShortSaleReason_SellingCustomerSoldShort -> "SellingCustomerSoldShort" - | FIX_ShortSaleReason_SellingCustomerSoldShortExempt -> "SellingCustomerSoldShortExempt" - | FIX_ShortSaleReason_QualifiedServiceRepresentative -> "QualifiedServiceRepresentative" - | FIX_ShortSaleReason_QSROrAGUContraSideSoldShortExempt -> "QSROrAGUContraSideSoldShortExempt" - ) -;; - -let side_to_string (d) = - (match d with - | FIX_Side_Buy -> "Buy" - | FIX_Side_Sell -> "Sell" - | FIX_Side_BuyMinus -> "BuyMinus" - | FIX_Side_SellPlus -> "SellPlus" - | FIX_Side_SellShort -> "SellShort" - | FIX_Side_SellShortExempt -> "SellShortExempt" - | FIX_Side_Undisclosed -> "Undisclosed" - | FIX_Side_Cross -> "Cross" - | FIX_Side_CrossShort -> "CrossShort" - | FIX_Side_CrossShortExempt -> "CrossShortExempt" - | FIX_Side_AsDefined -> "AsDefined" - | FIX_Side_Opposite -> "Opposite" - | FIX_Side_Subscribe -> "Subscribe" - | FIX_Side_Redeem -> "Redeem" - | FIX_Side_Lend -> "Lend" - | FIX_Side_Borrow -> "Borrow" - ) -;; - -let sidemultilegreportingtype_to_string (d) = - (match d with - | FIX_SideMultiLegReportingType_SingleSecurity -> "SingleSecurity" - | FIX_SideMultiLegReportingType_IndividualLegOfAMultilegSecurity -> "IndividualLegOfAMultilegSecurity" - | FIX_SideMultiLegReportingType_MultilegSecurity -> "MultilegSecurity" - ) -;; - -let sidevalueind_to_string (d) = - (match d with - | FIX_SideValueInd_SideValue1 -> "SideValue1" - | FIX_SideValueInd_SideValue2 -> "SideValue2" - ) -;; - -let solicitedflag_to_string (d) = - (match d with - | FIX_SolicitedFlag_WasSolicited -> "WasSolicited" - | FIX_SolicitedFlag_WasNotSolicited -> "WasNotSolicited" - ) -;; - -let standinstdbtype_to_string (d) = - (match d with - | FIX_StandInstDbType_Other -> "Other" - | FIX_StandInstDbType_DTCSID -> "DTCSID" - | FIX_StandInstDbType_ThomsonALERT -> "ThomsonALERT" - | FIX_StandInstDbType_AGlobalCustodian -> "AGlobalCustodian" - | FIX_StandInstDbType_AccountNet -> "AccountNet" - ) -;; - -let statusvalue_to_string (d) = - (match d with - | FIX_StatusValue_Connected -> "Connected" - | FIX_StatusValue_NotConnectedUnexpected -> "NotConnectedUnexpected" - | FIX_StatusValue_NotConnectedExpected -> "NotConnectedExpected" - | FIX_StatusValue_InProcess -> "InProcess" - ) -;; - -let stipulationtype_to_string (d) = - (match d with - | FIX_StipulationType_AlternativeMinimumTax -> "AlternativeMinimumTax" - | FIX_StipulationType_AutoReinvestment -> "AutoReinvestment" - | FIX_StipulationType_BankQualified -> "BankQualified" - | FIX_StipulationType_BargainConditions -> "BargainConditions" - | FIX_StipulationType_CouponRange -> "CouponRange" - | FIX_StipulationType_ISOCurrencyCode -> "ISOCurrencyCode" - | FIX_StipulationType_CustomStart -> "CustomStart" - | FIX_StipulationType_Geographics -> "Geographics" - | FIX_StipulationType_ValuationDiscount -> "ValuationDiscount" - | FIX_StipulationType_Insured -> "Insured" - | FIX_StipulationType_IssueDate -> "IssueDate" - | FIX_StipulationType_Issuer -> "Issuer" - | FIX_StipulationType_IssueSizeRange -> "IssueSizeRange" - | FIX_StipulationType_LookbackDays -> "LookbackDays" - | FIX_StipulationType_ExplicitLotIdentifier -> "ExplicitLotIdentifier" - | FIX_StipulationType_LotVariance -> "LotVariance" - | FIX_StipulationType_MaturityYearAndMonth -> "MaturityYearAndMonth" - | FIX_StipulationType_MaturityRange -> "MaturityRange" - | FIX_StipulationType_MaximumSubstitutions -> "MaximumSubstitutions" - | FIX_StipulationType_MinimumQuantity -> "MinimumQuantity" - | FIX_StipulationType_MinimumIncrement -> "MinimumIncrement" - | FIX_StipulationType_MinimumDenomination -> "MinimumDenomination" - | FIX_StipulationType_PaymentFrequency -> "PaymentFrequency" - | FIX_StipulationType_NumberOfPieces -> "NumberOfPieces" - | FIX_StipulationType_PoolsMaximum -> "PoolsMaximum" - | FIX_StipulationType_PoolsPerMillion -> "PoolsPerMillion" - | FIX_StipulationType_PoolsPerLot -> "PoolsPerLot" - | FIX_StipulationType_PoolsPerTrade -> "PoolsPerTrade" - | FIX_StipulationType_PriceRange -> "PriceRange" - | FIX_StipulationType_PricingFrequency -> "PricingFrequency" - | FIX_StipulationType_ProductionYear -> "ProductionYear" - | FIX_StipulationType_CallProtection -> "CallProtection" - | FIX_StipulationType_Purpose -> "Purpose" - | FIX_StipulationType_BenchmarkPriceSource -> "BenchmarkPriceSource" - | FIX_StipulationType_RatingSourceAndRange -> "RatingSourceAndRange" - | FIX_StipulationType_TypeOfRedemption -> "TypeOfRedemption" - | FIX_StipulationType_Restricted -> "Restricted" - | FIX_StipulationType_MarketSector -> "MarketSector" - | FIX_StipulationType_SecurityTypeIncludedOrExcluded -> "SecurityTypeIncludedOrExcluded" - | FIX_StipulationType_Structure -> "Structure" - | FIX_StipulationType_SubstitutionsFrequency -> "SubstitutionsFrequency" - | FIX_StipulationType_SubstitutionsLeft -> "SubstitutionsLeft" - | FIX_StipulationType_FreeformText -> "FreeformText" - | FIX_StipulationType_TradeVariance -> "TradeVariance" - | FIX_StipulationType_WeightedAverageCoupon -> "WeightedAverageCoupon" - | FIX_StipulationType_WeightedAverageLifeCoupon -> "WeightedAverageLifeCoupon" - | FIX_StipulationType_WeightedAverageLoanAge -> "WeightedAverageLoanAge" - | FIX_StipulationType_WeightedAverageMaturity -> "WeightedAverageMaturity" - | FIX_StipulationType_WholePool -> "WholePool" - | FIX_StipulationType_YieldRange -> "YieldRange" - ) -;; - -let subscriptionrequesttype_to_string (d) = - (match d with - | FIX_SubscriptionRequestType_Snapshot -> "Snapshot" - | FIX_SubscriptionRequestType_SnapshotAndUpdates -> "SnapshotAndUpdates" - | FIX_SubscriptionRequestType_DisablePreviousSnapshot -> "DisablePreviousSnapshot" - ) -;; - -let targetstrategy_to_string (d) = - (match d with - | FIX_TargetStrategy_VWAP -> "VWAP" - | FIX_TargetStrategy_Participate -> "Participate" - | FIX_TargetStrategy_MininizeMarketImpact -> "MininizeMarketImpact" - ) -;; - -let taxadvantagetype_to_string (d) = - (match d with - | FIX_TaxAdvantageType_FIXNone -> "FIXNone" - | FIX_TaxAdvantageType_MaxiISA -> "MaxiISA" - | FIX_TaxAdvantageType_TESSA -> "TESSA" - | FIX_TaxAdvantageType_MiniCashISA -> "MiniCashISA" - | FIX_TaxAdvantageType_MiniStocksAndSharesISA -> "MiniStocksAndSharesISA" - | FIX_TaxAdvantageType_MiniInsuranceISA -> "MiniInsuranceISA" - | FIX_TaxAdvantageType_CurrentYearPayment -> "CurrentYearPayment" - | FIX_TaxAdvantageType_PriorYearPayment -> "PriorYearPayment" - | FIX_TaxAdvantageType_AssetTransfer -> "AssetTransfer" - | FIX_TaxAdvantageType_EmployeePriorYear -> "EmployeePriorYear" - | FIX_TaxAdvantageType_EmployeeCurrentYear -> "EmployeeCurrentYear" - | FIX_TaxAdvantageType_EmployerPriorYear -> "EmployerPriorYear" - | FIX_TaxAdvantageType_EmployerCurrentYear -> "EmployerCurrentYear" - | FIX_TaxAdvantageType_NonFundPrototypeIRA -> "NonFundPrototypeIRA" - | FIX_TaxAdvantageType_NonFundQualifiedPlan -> "NonFundQualifiedPlan" - | FIX_TaxAdvantageType_DefinedContributionPlan -> "DefinedContributionPlan" - | FIX_TaxAdvantageType_IRA -> "IRA" - | FIX_TaxAdvantageType_IRARollover -> "IRARollover" - | FIX_TaxAdvantageType_KEOGH -> "KEOGH" - | FIX_TaxAdvantageType_ProfitSharingPlan -> "ProfitSharingPlan" - | FIX_TaxAdvantageType_US401K -> "US401K" - | FIX_TaxAdvantageType_SelfDirectedIRA -> "SelfDirectedIRA" - | FIX_TaxAdvantageType_US403b -> "US403b" - | FIX_TaxAdvantageType_US457 -> "US457" - | FIX_TaxAdvantageType_RothIRAPrototype -> "RothIRAPrototype" - | FIX_TaxAdvantageType_RothIRANonPrototype -> "RothIRANonPrototype" - | FIX_TaxAdvantageType_RothConversionIRAPrototype -> "RothConversionIRAPrototype" - | FIX_TaxAdvantageType_RothConversionIRANonPrototype -> "RothConversionIRANonPrototype" - | FIX_TaxAdvantageType_EducationIRAPrototype -> "EducationIRAPrototype" - | FIX_TaxAdvantageType_EducationIRANonPrototype -> "EducationIRANonPrototype" - ) -;; - -let terminationtype_to_string (d) = - (match d with - | FIX_TerminationType_Overnight -> "Overnight" - | FIX_TerminationType_Term -> "Term" - | FIX_TerminationType_Flexible -> "Flexible" - | FIX_TerminationType_Open -> "Open" - ) -;; - -let testmessageindicator_to_string (d) = - (match d with - | FIX_TestMessageIndicator_True -> "True" - | FIX_TestMessageIndicator_Fales -> "Fales" - ) -;; - -let tickdirection_to_string (d) = - (match d with - | FIX_TickDirection_PlusTick -> "PlusTick" - | FIX_TickDirection_ZeroPlusTick -> "ZeroPlusTick" - | FIX_TickDirection_MinusTick -> "MinusTick" - | FIX_TickDirection_ZeroMinusTick -> "ZeroMinusTick" - ) -;; - -let timeinforce_to_string (d) = - (match d with - | FIX_TimeInForce_Day -> "Day" - | FIX_TimeInForce_GoodTillCancel -> "GoodTillCancel" - | FIX_TimeInForce_AtTheOpening -> "AtTheOpening" - | FIX_TimeInForce_ImmediateOrCancel -> "ImmediateOrCancel" - | FIX_TimeInForce_FillOrKill -> "FillOrKill" - | FIX_TimeInForce_GoodTillCrossing -> "GoodTillCrossing" - | FIX_TimeInForce_GoodTillDate -> "GoodTillDate" - | FIX_TimeInForce_AtTheClose -> "AtTheClose" - ) -;; - -let tradsesmethod_to_string (d) = - (match d with - | FIX_TradSesMethod_Electronic -> "Electronic" - | FIX_TradSesMethod_OpenOutcry -> "OpenOutcry" - | FIX_TradSesMethod_TwoParty -> "TwoParty" - ) -;; - -let tradsesmode_to_string (d) = - (match d with - | FIX_TradSesMode_Testing -> "Testing" - | FIX_TradSesMode_Simulated -> "Simulated" - | FIX_TradSesMode_Production -> "Production" - ) -;; - -let tradsesstatus_to_string (d) = - (match d with - | FIX_TradSesStatus_Unknown -> "Unknown" - | FIX_TradSesStatus_Halted -> "Halted" - | FIX_TradSesStatus_Open -> "Open" - | FIX_TradSesStatus_Closed -> "Closed" - | FIX_TradSesStatus_PreOpen -> "PreOpen" - | FIX_TradSesStatus_PreClose -> "PreClose" - | FIX_TradSesStatus_RequestRejected -> "RequestRejected" - ) -;; - -let tradsesstatusrejreason_to_string (d) = - (match d with - | FIX_TradSesStatusRejReason_UnknownOrInvalidTradingSessionID -> "UnknownOrInvalidTradingSessionID" - | FIX_TradSesStatusRejReason_Other -> "Other" - ) -;; - -let tradeallocindicator_to_string (d) = - (match d with - | FIX_TradeAllocIndicator_AllocationNotRequired -> "AllocationNotRequired" - | FIX_TradeAllocIndicator_AllocationRequired -> "AllocationRequired" - | FIX_TradeAllocIndicator_UseAllocationProvidedWithTheTrade -> "UseAllocationProvidedWithTheTrade" - ) -;; - -let tradecondition_to_string (d) = - (match d with - | FIX_TradeCondition_Cash -> "Cash" - | FIX_TradeCondition_AveragePriceTrade -> "AveragePriceTrade" - | FIX_TradeCondition_CashTrade -> "CashTrade" - | FIX_TradeCondition_NextDay -> "NextDay" - | FIX_TradeCondition_Opening -> "Opening" - | FIX_TradeCondition_IntradayTradeDetail -> "IntradayTradeDetail" - | FIX_TradeCondition_Rule127Trade -> "Rule127Trade" - | FIX_TradeCondition_Rule155Trade -> "Rule155Trade" - | FIX_TradeCondition_SoldLast -> "SoldLast" - | FIX_TradeCondition_NextDayTrade -> "NextDayTrade" - | FIX_TradeCondition_Opened -> "Opened" - | FIX_TradeCondition_Seller -> "Seller" - | FIX_TradeCondition_Sold -> "Sold" - | FIX_TradeCondition_StoppedStock -> "StoppedStock" - | FIX_TradeCondition_ImbalanceMoreBuyers -> "ImbalanceMoreBuyers" - | FIX_TradeCondition_ImbalanceMoreSellers -> "ImbalanceMoreSellers" - | FIX_TradeCondition_OpeningPrice -> "OpeningPrice" - ) -;; - -let tradereportrejectreason_to_string (d) = - (match d with - | FIX_TradeReportRejectReason_Successful -> "Successful" - | FIX_TradeReportRejectReason_InvalidPartyOnformation -> "InvalidPartyOnformation" - | FIX_TradeReportRejectReason_UnknownInstrument -> "UnknownInstrument" - | FIX_TradeReportRejectReason_UnauthorizedToReportTrades -> "UnauthorizedToReportTrades" - | FIX_TradeReportRejectReason_InvalidTradeType -> "InvalidTradeType" - | FIX_TradeReportRejectReason_Other -> "Other" - ) -;; - -let tradereporttype_to_string (d) = - (match d with - | FIX_TradeReportType_Submit -> "Submit" - | FIX_TradeReportType_Alleged -> "Alleged" - | FIX_TradeReportType_Accept -> "Accept" - | FIX_TradeReportType_Decline -> "Decline" - | FIX_TradeReportType_Addendum -> "Addendum" - | FIX_TradeReportType_No -> "No" - | FIX_TradeReportType_TradeReportCancel -> "TradeReportCancel" - | FIX_TradeReportType_LockedIn -> "LockedIn" - ) -;; - -let traderequestresult_to_string (d) = - (match d with - | FIX_TradeRequestResult_Successful -> "Successful" - | FIX_TradeRequestResult_InvalidOrUnknownInstrument -> "InvalidOrUnknownInstrument" - | FIX_TradeRequestResult_InvalidTypeOfTradeRequested -> "InvalidTypeOfTradeRequested" - | FIX_TradeRequestResult_InvalidParties -> "InvalidParties" - | FIX_TradeRequestResult_InvalidTransportTypeRequested -> "InvalidTransportTypeRequested" - | FIX_TradeRequestResult_InvalidDestinationRequested -> "InvalidDestinationRequested" - | FIX_TradeRequestResult_TradeRequestTypeNotSupported -> "TradeRequestTypeNotSupported" - | FIX_TradeRequestResult_NotAuthorized -> "NotAuthorized" - | FIX_TradeRequestResult_Other -> "Other" - ) -;; - -let traderequeststatus_to_string (d) = - (match d with - | FIX_TradeRequestStatus_Accepted -> "Accepted" - | FIX_TradeRequestStatus_Completed -> "Completed" - | FIX_TradeRequestStatus_Rejected -> "Rejected" - ) -;; - -let traderequesttype_to_string (d) = - (match d with - | FIX_TradeRequestType_AllTrades -> "AllTrades" - | FIX_TradeRequestType_MatchedTradesMatchingCriteria -> "MatchedTradesMatchingCriteria" - | FIX_TradeRequestType_UnmatchedTradesThatMatchCriteria -> "UnmatchedTradesThatMatchCriteria" - | FIX_TradeRequestType_UnreportedTradesThatMatchCriteria -> "UnreportedTradesThatMatchCriteria" - | FIX_TradeRequestType_AdvisoriesThatMatchCriteria -> "AdvisoriesThatMatchCriteria" - ) -;; - -let tradedflatswitch_to_string (d) = - (match d with - | FIX_TradedFlatSwitch_TradedFlat -> "TradedFlat" - | FIX_TradedFlatSwitch_NotTradedFlat -> "NotTradedFlat" - ) -;; - -let trdregtimestamptype_to_string (d) = - (match d with - | FIX_TrdRegTimestampType_ExecutionTime -> "ExecutionTime" - | FIX_TrdRegTimestampType_TimeIn -> "TimeIn" - | FIX_TrdRegTimestampType_TimeOut -> "TimeOut" - | FIX_TrdRegTimestampType_BrokerReceipt -> "BrokerReceipt" - | FIX_TrdRegTimestampType_BrokerExecution -> "BrokerExecution" - ) -;; - -let trdrptstatus_to_string (d) = - (match d with - | FIX_TrdRptStatus_Accepted -> "Accepted" - | FIX_TrdRptStatus_Rejected -> "Rejected" - ) -;; - -let trdtype_to_string (d) = - (match d with - | FIX_TrdType_RegularTrade -> "RegularTrade" - | FIX_TrdType_BlockTrade -> "BlockTrade" - | FIX_TrdType_EFP -> "EFP" - | FIX_TrdType_Transfer -> "Transfer" - | FIX_TrdType_LateTrade -> "LateTrade" - | FIX_TrdType_TTrade -> "TTrade" - | FIX_TrdType_WeightedAveragePriceTrade -> "WeightedAveragePriceTrade" - | FIX_TrdType_BunchedTrade -> "BunchedTrade" - | FIX_TrdType_LateBunchedTrade -> "LateBunchedTrade" - | FIX_TrdType_PriorReferencePriceTrade -> "PriorReferencePriceTrade" - | FIX_TrdType_AfterHoursTrade -> "AfterHoursTrade" - ) -;; - -let unsolicitedindicator_to_string (d) = - (match d with - | FIX_UnsolicitedIndicator_MessageIsBeingSentUnsolicited -> "MessageIsBeingSentUnsolicited" - | FIX_UnsolicitedIndicator_MessageIsBeingSentAsAResultOfAPriorRequest -> "MessageIsBeingSentAsAResultOfAPriorRequest" - ) -;; - -let urgency_to_string (d) = - (match d with - | FIX_Urgency_Normal -> "Normal" - | FIX_Urgency_Flash -> "Flash" - | FIX_Urgency_Background -> "Background" - ) -;; - -let userrequesttype_to_string (d) = - (match d with - | FIX_UserRequestType_LogOnUser -> "LogOnUser" - | FIX_UserRequestType_LogOffUser -> "LogOffUser" - | FIX_UserRequestType_ChangePasswordForUser -> "ChangePasswordForUser" - | FIX_UserRequestType_RequestIndividualUserStatus -> "RequestIndividualUserStatus" - ) -;; - -let userstatus_to_string (d) = - (match d with - | FIX_UserStatus_LoggedIn -> "LoggedIn" - | FIX_UserStatus_NotLoggedIn -> "NotLoggedIn" - | FIX_UserStatus_UserNotRecognised -> "UserNotRecognised" - | FIX_UserStatus_PasswordIncorrect -> "PasswordIncorrect" - | FIX_UserStatus_PasswordChanged -> "PasswordChanged" - | FIX_UserStatus_Other -> "Other" - ) -;; - -let workingindicator_to_string (d) = - (match d with - | FIX_WorkingIndicator_Working -> "Working" - | FIX_WorkingIndicator_NotWorking -> "NotWorking" - ) -;; - -let yieldtype_to_string (d) = - (match d with - | FIX_YieldType_AfterTaxYield -> "AfterTaxYield" - | FIX_YieldType_AnnualYield -> "AnnualYield" - | FIX_YieldType_YieldAtIssue -> "YieldAtIssue" - | FIX_YieldType_YieldToAverageMaturity -> "YieldToAverageMaturity" - | FIX_YieldType_BookYield -> "BookYield" - | FIX_YieldType_YieldToNextCall -> "YieldToNextCall" - | FIX_YieldType_YieldChangeSinceClose -> "YieldChangeSinceClose" - | FIX_YieldType_ClosingYield -> "ClosingYield" - | FIX_YieldType_CompoundYield -> "CompoundYield" - | FIX_YieldType_CurrentYield -> "CurrentYield" - | FIX_YieldType_TrueGrossYield -> "TrueGrossYield" - | FIX_YieldType_GvntEquivalentYield -> "GvntEquivalentYield" - | FIX_YieldType_YieldWithInflationAssumption -> "YieldWithInflationAssumption" - | FIX_YieldType_InverseFloaterBondYield -> "InverseFloaterBondYield" - | FIX_YieldType_MostRecentClosingYield -> "MostRecentClosingYield" - | FIX_YieldType_ClosingYieldMostRecentMonth -> "ClosingYieldMostRecentMonth" - | FIX_YieldType_ClosingYieldMostRecentQuarter -> "ClosingYieldMostRecentQuarter" - | FIX_YieldType_ClosingYieldMostRecentYear -> "ClosingYieldMostRecentYear" - | FIX_YieldType_YieldToLongestAverageLife -> "YieldToLongestAverageLife" - | FIX_YieldType_MarkToMarketYield -> "MarkToMarketYield" - | FIX_YieldType_YieldToMaturity -> "YieldToMaturity" - | FIX_YieldType_YieldToNextRefund -> "YieldToNextRefund" - | FIX_YieldType_OpenAverageYield -> "OpenAverageYield" - | FIX_YieldType_YieldToNextPut -> "YieldToNextPut" - | FIX_YieldType_PreviousCloseYield -> "PreviousCloseYield" - | FIX_YieldType_ProceedsYield -> "ProceedsYield" - | FIX_YieldType_SemiAnnualYield -> "SemiAnnualYield" - | FIX_YieldType_YieldToShortestAverageLife -> "YieldToShortestAverageLife" - | FIX_YieldType_SimpleYield -> "SimpleYield" - | FIX_YieldType_TaxEquivalentYield -> "TaxEquivalentYield" - | FIX_YieldType_YieldToTenderDate -> "YieldToTenderDate" - | FIX_YieldType_TrueYield -> "TrueYield" - | FIX_YieldType_YieldValueOf132 -> "YieldValueOf132" - | FIX_YieldType_YieldToWorst -> "YieldToWorst" - ) -;; - -let currency_to_string (d) = - (match d with - | FIX_Currency_EUR -> "EUR" - | FIX_Currency_GBP -> "GBP" - | FIX_Currency_USD -> "USD" - | FIX_Currency_CHF -> "CHF" - ) -;; - -let country_to_string (d) = - (match d with - | FIX_Country_DE -> "DE" - | FIX_Country_GB -> "GB" - | FIX_Country_US -> "US" - ) -;; - -let exchange_to_string (d) = - (match d with - | FIX_Exchange_XLON -> "XLON" - | FIX_Exchange_XNYS -> "XNYS" - | FIX_Exchange_XNAS -> "XNAS" - | FIX_Exchange_XJAS -> "XJAS" - | FIX_Exchange_XSHG -> "XSHG" - | FIX_Exchange_SHSC -> "SHSC" - ) -;; - -let week_to_json (d) : json = - `String (week_to_string d) -;; - -let accounttype_to_json (d) : json = - `String (accounttype_to_string d) -;; - -let acctidsource_to_json (d) : json = - `String (acctidsource_to_string d) -;; - -let adjustment_to_json (d) : json = - `String (adjustment_to_string d) -;; - -let adjustmenttype_to_json (d) : json = - `String (adjustmenttype_to_string d) -;; - -let advside_to_json (d) : json = - `String (advside_to_string d) -;; - -let advtranstype_to_json (d) : json = - `String (advtranstype_to_string d) -;; - -let affirmstatus_to_json (d) : json = - `String (affirmstatus_to_string d) -;; - -let aggregatedbook_to_json (d) : json = - `String (aggregatedbook_to_string d) -;; - -let allocaccounttype_to_json (d) : json = - `String (allocaccounttype_to_string d) -;; - -let alloccancreplacereason_to_json (d) : json = - `String (alloccancreplacereason_to_string d) -;; - -let allochandlinst_to_json (d) : json = - `String (allochandlinst_to_string d) -;; - -let allocintermedreqtype_to_json (d) : json = - `String (allocintermedreqtype_to_string d) -;; - -let alloclinktype_to_json (d) : json = - `String (alloclinktype_to_string d) -;; - -let allocnoorderstype_to_json (d) : json = - `String (allocnoorderstype_to_string d) -;; - -let allocrejcode_to_json (d) : json = - `String (allocrejcode_to_string d) -;; - -let allocreporttype_to_json (d) : json = - `String (allocreporttype_to_string d) -;; - -let allocsettlinsttype_to_json (d) : json = - `String (allocsettlinsttype_to_string d) -;; - -let allocstatus_to_json (d) : json = - `String (allocstatus_to_string d) -;; - -let alloctranstype_to_json (d) : json = - `String (alloctranstype_to_string d) -;; - -let alloctype_to_json (d) : json = - `String (alloctype_to_string d) -;; - -let applqueueaction_to_json (d) : json = - `String (applqueueaction_to_string d) -;; - -let applqueueresolution_to_json (d) : json = - `String (applqueueresolution_to_string d) -;; - -let assignmentmethod_to_json (d) : json = - `String (assignmentmethod_to_string d) -;; - -let avgpxindicator_to_json (d) : json = - `String (avgpxindicator_to_string d) -;; - -let basispxtype_to_json (d) : json = - `String (basispxtype_to_string d) -;; - -let biddescriptortype_to_json (d) : json = - `String (biddescriptortype_to_string d) -;; - -let bidrequesttranstype_to_json (d) : json = - `String (bidrequesttranstype_to_string d) -;; - -let bidtradetype_to_json (d) : json = - `String (bidtradetype_to_string d) -;; - -let bidtype_to_json (d) : json = - `String (bidtype_to_string d) -;; - -let bookingtype_to_json (d) : json = - `String (bookingtype_to_string d) -;; - -let bookingunit_to_json (d) : json = - `String (bookingunit_to_string d) -;; - -let cpprogram_to_json (d) : json = - `String (cpprogram_to_string d) -;; - -let cancellationrights_to_json (d) : json = - `String (cancellationrights_to_string d) -;; - -let cashmargin_to_json (d) : json = - `String (cashmargin_to_string d) -;; - -let clearingfeeindicator_to_json (d) : json = - `String (clearingfeeindicator_to_string d) -;; - -let clearinginstruction_to_json (d) : json = - `String (clearinginstruction_to_string d) -;; - -let collaction_to_json (d) : json = - `String (collaction_to_string d) -;; - -let collasgnreason_to_json (d) : json = - `String (collasgnreason_to_string d) -;; - -let collasgnrejectreason_to_json (d) : json = - `String (collasgnrejectreason_to_string d) -;; - -let collasgnresptype_to_json (d) : json = - `String (collasgnresptype_to_string d) -;; - -let collasgntranstype_to_json (d) : json = - `String (collasgntranstype_to_string d) -;; - -let collinquiryqualifier_to_json (d) : json = - `String (collinquiryqualifier_to_string d) -;; - -let collinquiryresult_to_json (d) : json = - `String (collinquiryresult_to_string d) -;; - -let collinquirystatus_to_json (d) : json = - `String (collinquirystatus_to_string d) -;; - -let collstatus_to_json (d) : json = - `String (collstatus_to_string d) -;; - -let commtype_to_json (d) : json = - `String (commtype_to_string d) -;; - -let confirmrejreason_to_json (d) : json = - `String (confirmrejreason_to_string d) -;; - -let confirmstatus_to_json (d) : json = - `String (confirmstatus_to_string d) -;; - -let confirmtranstype_to_json (d) : json = - `String (confirmtranstype_to_string d) -;; - -let confirmtype_to_json (d) : json = - `String (confirmtype_to_string d) -;; - -let contamttype_to_json (d) : json = - `String (contamttype_to_string d) -;; - -let corporateaction_to_json (d) : json = - `List (List.map (fun x -> `String (corporateaction_to_string x) - ) d) -;; - -let coveredoruncovered_to_json (d) : json = - `String (coveredoruncovered_to_string d) -;; - -let crossprioritization_to_json (d) : json = - `String (crossprioritization_to_string d) -;; - -let crosstype_to_json (d) : json = - `String (crosstype_to_string d) -;; - -let custordercapacity_to_json (d) : json = - `String (custordercapacity_to_string d) -;; - -let cxlrejreason_to_json (d) : json = - `String (cxlrejreason_to_string d) -;; - -let cxlrejresponseto_to_json (d) : json = - `String (cxlrejresponseto_to_string d) -;; - -let dkreason_to_json (d) : json = - `String (dkreason_to_string d) -;; - -let daybookinginst_to_json (d) : json = - `String (daybookinginst_to_string d) -;; - -let deletereason_to_json (d) : json = - `String (deletereason_to_string d) -;; - -let deliveryform_to_json (d) : json = - `String (deliveryform_to_string d) -;; - -let deliverytype_to_json (d) : json = - `String (deliverytype_to_string d) -;; - -let discretioninst_to_json (d) : json = - `String (discretioninst_to_string d) -;; - -let discretionlimittype_to_json (d) : json = - `String (discretionlimittype_to_string d) -;; - -let discretionmovetype_to_json (d) : json = - `String (discretionmovetype_to_string d) -;; - -let discretionoffsettype_to_json (d) : json = - `String (discretionoffsettype_to_string d) -;; - -let discretionrounddirection_to_json (d) : json = - `String (discretionrounddirection_to_string d) -;; - -let discretionscope_to_json (d) : json = - `String (discretionscope_to_string d) -;; - -let distribpaymentmethod_to_json (d) : json = - `String (distribpaymentmethod_to_string d) -;; - -let dlvyinsttype_to_json (d) : json = - `String (dlvyinsttype_to_string d) -;; - -let duetorelated_to_json (d) : json = - `String (duetorelated_to_string d) -;; - -let emailtype_to_json (d) : json = - `String (emailtype_to_string d) -;; - -let eventtype_to_json (d) : json = - `String (eventtype_to_string d) -;; - -let exchangeforphysical_to_json (d) : json = - `String (exchangeforphysical_to_string d) -;; - -let execinst_to_json (d) : json = - `List (List.map (fun x -> `String (execinst_to_string x) - ) d) -;; - -let execpricetype_to_json (d) : json = - `String (execpricetype_to_string d) -;; - -let execrestatementreason_to_json (d) : json = - `String (execrestatementreason_to_string d) -;; - -let exectype_to_json (d) : json = - `String (exectype_to_string d) -;; - -let exercisemethod_to_json (d) : json = - `String (exercisemethod_to_string d) -;; - -let expirationcycle_to_json (d) : json = - `String (expirationcycle_to_string d) -;; - -let financialstatus_to_json (d) : json = - `List (List.map (fun x -> `String (financialstatus_to_string x) - ) d) -;; - -let forexreq_to_json (d) : json = - `String (forexreq_to_string d) -;; - -let fundrenewwaiv_to_json (d) : json = - `String (fundrenewwaiv_to_string d) -;; - -let gtbookinginst_to_json (d) : json = - `String (gtbookinginst_to_string d) -;; - -let haltreason_to_json (d) : json = - `String (haltreason_to_string d) -;; - -let handlinst_to_json (d) : json = - `String (handlinst_to_string d) -;; - -let ioinaturalflag_to_json (d) : json = - `String (ioinaturalflag_to_string d) -;; - -let ioiqltyind_to_json (d) : json = - `String (ioiqltyind_to_string d) -;; - -let ioiqty_to_json (d) : json = - `String (ioiqty_to_string d) -;; - -let ioiqualifier_to_json (d) : json = - `String (ioiqualifier_to_string d) -;; - -let ioitranstype_to_json (d) : json = - `String (ioitranstype_to_string d) -;; - -let inviewofcommon_to_json (d) : json = - `String (inviewofcommon_to_string d) -;; - -let inctaxind_to_json (d) : json = - `String (inctaxind_to_string d) -;; - -let instrattribtype_to_json (d) : json = - `String (instrattribtype_to_string d) -;; - -let lastcapacity_to_json (d) : json = - `String (lastcapacity_to_string d) -;; - -let lastfragment_to_json (d) : json = - `String (lastfragment_to_string d) -;; - -let lastliquidityind_to_json (d) : json = - `String (lastliquidityind_to_string d) -;; - -let legswaptype_to_json (d) : json = - `String (legswaptype_to_string d) -;; - -let legalconfirm_to_json (d) : json = - `String (legalconfirm_to_string d) -;; - -let liquidityindtype_to_json (d) : json = - `String (liquidityindtype_to_string d) -;; - -let listexecinsttype_to_json (d) : json = - `String (listexecinsttype_to_string d) -;; - -let listorderstatus_to_json (d) : json = - `String (listorderstatus_to_string d) -;; - -let liststatustype_to_json (d) : json = - `String (liststatustype_to_string d) -;; - -let locatereqd_to_json (d) : json = - `String (locatereqd_to_string d) -;; - -let mdentrytype_to_json (d) : json = - `String (mdentrytype_to_string d) -;; - -let mdimplicitdelete_to_json (d) : json = - `String (mdimplicitdelete_to_string d) -;; - -let mdreqrejreason_to_json (d) : json = - `String (mdreqrejreason_to_string d) -;; - -let mdupdateaction_to_json (d) : json = - `String (mdupdateaction_to_string d) -;; - -let mdupdatetype_to_json (d) : json = - `String (mdupdatetype_to_string d) -;; - -let masscancelrejectreason_to_json (d) : json = - `String (masscancelrejectreason_to_string d) -;; - -let masscancelrequesttype_to_json (d) : json = - `String (masscancelrequesttype_to_string d) -;; - -let masscancelresponse_to_json (d) : json = - `String (masscancelresponse_to_string d) -;; - -let massstatusreqtype_to_json (d) : json = - `String (massstatusreqtype_to_string d) -;; - -let matchstatus_to_json (d) : json = - `String (matchstatus_to_string d) -;; - -let matchtype_to_json (d) : json = - `String (matchtype_to_string d) -;; - -let messageencoding_to_json (d) : json = - `String (messageencoding_to_string d) -;; - -let miscfeebasis_to_json (d) : json = - `String (miscfeebasis_to_string d) -;; - -let miscfeetype_to_json (d) : json = - `String (miscfeetype_to_string d) -;; - -let moneylaunderingstatus_to_json (d) : json = - `String (moneylaunderingstatus_to_string d) -;; - -let msgdirection_to_json (d) : json = - `String (msgdirection_to_string d) -;; - -let multilegreportingtype_to_json (d) : json = - `String (multilegreportingtype_to_string d) -;; - -let multilegrpttypereq_to_json (d) : json = - `String (multilegrpttypereq_to_string d) -;; - -let netgrossind_to_json (d) : json = - `String (netgrossind_to_string d) -;; - -let networkrequesttype_to_json (d) : json = - `String (networkrequesttype_to_string d) -;; - -let networkstatusresponsetype_to_json (d) : json = - `String (networkstatusresponsetype_to_string d) -;; - -let nosides_to_json (d) : json = - `String (nosides_to_string d) -;; - -let notifybrokerofcredit_to_json (d) : json = - `String (notifybrokerofcredit_to_string d) -;; - -let oddlot_to_json (d) : json = - `String (oddlot_to_string d) -;; - -let openclosesettlflag_to_json (d) : json = - `List (List.map (fun x -> `String (openclosesettlflag_to_string x) - ) d) -;; - -let ordrejreason_to_json (d) : json = - `String (ordrejreason_to_string d) -;; - -let ordstatus_to_json (d) : json = - `String (ordstatus_to_string d) -;; - -let ordtype_to_json (d) : json = - `String (ordtype_to_string d) -;; - -let ordercapacity_to_json (d) : json = - `String (ordercapacity_to_string d) -;; - -let orderrestrictions_to_json (d) : json = - `List (List.map (fun x -> `String (orderrestrictions_to_string x) - ) d) -;; - -let ownertype_to_json (d) : json = - `String (ownertype_to_string d) -;; - -let ownershiptype_to_json (d) : json = - `String (ownershiptype_to_string d) -;; - -let partyidsource_to_json (d) : json = - `String (partyidsource_to_string d) -;; - -let partyrole_to_json (d) : json = - `String (partyrole_to_string d) -;; - -let partysubidtype_to_json (d) : json = - `String (partysubidtype_to_string d) -;; - -let paymentmethod_to_json (d) : json = - `String (paymentmethod_to_string d) -;; - -let peglimittype_to_json (d) : json = - `String (peglimittype_to_string d) -;; - -let pegmovetype_to_json (d) : json = - `String (pegmovetype_to_string d) -;; - -let pegoffsettype_to_json (d) : json = - `String (pegoffsettype_to_string d) -;; - -let pegrounddirection_to_json (d) : json = - `String (pegrounddirection_to_string d) -;; - -let pegscope_to_json (d) : json = - `String (pegscope_to_string d) -;; - -let posamttype_to_json (d) : json = - `String (posamttype_to_string d) -;; - -let posmaintaction_to_json (d) : json = - `String (posmaintaction_to_string d) -;; - -let posmaintresult_to_json (d) : json = - `String (posmaintresult_to_string d) -;; - -let posmaintstatus_to_json (d) : json = - `String (posmaintstatus_to_string d) -;; - -let posqtystatus_to_json (d) : json = - `String (posqtystatus_to_string d) -;; - -let posreqresult_to_json (d) : json = - `String (posreqresult_to_string d) -;; - -let posreqstatus_to_json (d) : json = - `String (posreqstatus_to_string d) -;; - -let posreqtype_to_json (d) : json = - `String (posreqtype_to_string d) -;; - -let postranstype_to_json (d) : json = - `String (postranstype_to_string d) -;; - -let postype_to_json (d) : json = - `String (postype_to_string d) -;; - -let positioneffect_to_json (d) : json = - `String (positioneffect_to_string d) -;; - -let possdupflag_to_json (d) : json = - `String (possdupflag_to_string d) -;; - -let possresend_to_json (d) : json = - `String (possresend_to_string d) -;; - -let preallocmethod_to_json (d) : json = - `String (preallocmethod_to_string d) -;; - -let previouslyreported_to_json (d) : json = - `String (previouslyreported_to_string d) -;; - -let pricetype_to_json (d) : json = - `String (pricetype_to_string d) -;; - -let priorityindicator_to_json (d) : json = - `String (priorityindicator_to_string d) -;; - -let processcode_to_json (d) : json = - `String (processcode_to_string d) -;; - -let product_to_json (d) : json = - `String (product_to_string d) -;; - -let progrptreqs_to_json (d) : json = - `String (progrptreqs_to_string d) -;; - -let publishtrdindicator_to_json (d) : json = - `String (publishtrdindicator_to_string d) -;; - -let putorcall_to_json (d) : json = - `String (putorcall_to_string d) -;; - -let qtytype_to_json (d) : json = - `String (qtytype_to_string d) -;; - -let quotecanceltype_to_json (d) : json = - `String (quotecanceltype_to_string d) -;; - -let quotecondition_to_json (d) : json = - `List (List.map (fun x -> `String (quotecondition_to_string x) - ) d) -;; - -let quotepricetype_to_json (d) : json = - `String (quotepricetype_to_string d) -;; - -let quoterejectreason_to_json (d) : json = - `String (quoterejectreason_to_string d) -;; - -let quoterequestrejectreason_to_json (d) : json = - `String (quoterequestrejectreason_to_string d) -;; - -let quoterequesttype_to_json (d) : json = - `String (quoterequesttype_to_string d) -;; - -let quoteresptype_to_json (d) : json = - `String (quoteresptype_to_string d) -;; - -let quoteresponselevel_to_json (d) : json = - `String (quoteresponselevel_to_string d) -;; - -let quotestatus_to_json (d) : json = - `String (quotestatus_to_string d) -;; - -let quotetype_to_json (d) : json = - `String (quotetype_to_string d) -;; - -let registrejreasoncode_to_json (d) : json = - `String (registrejreasoncode_to_string d) -;; - -let registstatus_to_json (d) : json = - `String (registstatus_to_string d) -;; - -let registtranstype_to_json (d) : json = - `String (registtranstype_to_string d) -;; - -let reporttoexch_to_json (d) : json = - `String (reporttoexch_to_string d) -;; - -let resetseqnumflag_to_json (d) : json = - `String (resetseqnumflag_to_string d) -;; - -let responsetransporttype_to_json (d) : json = - `String (responsetransporttype_to_string d) -;; - -let roundingdirection_to_json (d) : json = - `String (roundingdirection_to_string d) -;; - -let routingtype_to_json (d) : json = - `String (routingtype_to_string d) -;; - -let scope_to_json (d) : json = - `List (List.map (fun x -> `String (scope_to_string x) - ) d) -;; - -let securityidsource_to_json (d) : json = - `String (securityidsource_to_string d) -;; - -let securitylistrequesttype_to_json (d) : json = - `String (securitylistrequesttype_to_string d) -;; - -let securityrequestresult_to_json (d) : json = - `String (securityrequestresult_to_string d) -;; - -let securityrequesttype_to_json (d) : json = - `String (securityrequesttype_to_string d) -;; - -let securityresponsetype_to_json (d) : json = - `String (securityresponsetype_to_string d) -;; - -let securitytradingstatus_to_json (d) : json = - `String (securitytradingstatus_to_string d) -;; - -let securitytype_to_json (d) : json = - `String (securitytype_to_string d) -;; - -let settlcurrfxratecalc_to_json (d) : json = - `String (settlcurrfxratecalc_to_string d) -;; - -let settldeliverytype_to_json (d) : json = - `String (settldeliverytype_to_string d) -;; - -let settlinstmode_to_json (d) : json = - `String (settlinstmode_to_string d) -;; - -let settlinstreqrejcode_to_json (d) : json = - `String (settlinstreqrejcode_to_string d) -;; - -let settlinstsource_to_json (d) : json = - `String (settlinstsource_to_string d) -;; - -let settlinsttranstype_to_json (d) : json = - `String (settlinsttranstype_to_string d) -;; - -let settlpricetype_to_json (d) : json = - `String (settlpricetype_to_string d) -;; - -let settlsessid_to_json (d) : json = - `String (settlsessid_to_string d) -;; - -let settltype_to_json (d) : json = - `String (settltype_to_string d) -;; - -let shortsalereason_to_json (d) : json = - `String (shortsalereason_to_string d) -;; - -let side_to_json (d) : json = - `String (side_to_string d) -;; - -let sidemultilegreportingtype_to_json (d) : json = - `String (sidemultilegreportingtype_to_string d) -;; - -let sidevalueind_to_json (d) : json = - `String (sidevalueind_to_string d) -;; - -let solicitedflag_to_json (d) : json = - `String (solicitedflag_to_string d) -;; - -let standinstdbtype_to_json (d) : json = - `String (standinstdbtype_to_string d) -;; - -let statusvalue_to_json (d) : json = - `String (statusvalue_to_string d) -;; - -let stipulationtype_to_json (d) : json = - `String (stipulationtype_to_string d) -;; - -let subscriptionrequesttype_to_json (d) : json = - `String (subscriptionrequesttype_to_string d) -;; - -let targetstrategy_to_json (d) : json = - `String (targetstrategy_to_string d) -;; - -let taxadvantagetype_to_json (d) : json = - `String (taxadvantagetype_to_string d) -;; - -let terminationtype_to_json (d) : json = - `String (terminationtype_to_string d) -;; - -let testmessageindicator_to_json (d) : json = - `String (testmessageindicator_to_string d) -;; - -let tickdirection_to_json (d) : json = - `String (tickdirection_to_string d) -;; - -let timeinforce_to_json (d) : json = - `String (timeinforce_to_string d) -;; - -let tradsesmethod_to_json (d) : json = - `String (tradsesmethod_to_string d) -;; - -let tradsesmode_to_json (d) : json = - `String (tradsesmode_to_string d) -;; - -let tradsesstatus_to_json (d) : json = - `String (tradsesstatus_to_string d) -;; - -let tradsesstatusrejreason_to_json (d) : json = - `String (tradsesstatusrejreason_to_string d) -;; - -let tradeallocindicator_to_json (d) : json = - `String (tradeallocindicator_to_string d) -;; - -let tradecondition_to_json (d) : json = - `List (List.map (fun x -> `String (tradecondition_to_string x) - ) d) -;; - -let tradereportrejectreason_to_json (d) : json = - `String (tradereportrejectreason_to_string d) -;; - -let tradereporttype_to_json (d) : json = - `String (tradereporttype_to_string d) -;; - -let traderequestresult_to_json (d) : json = - `String (traderequestresult_to_string d) -;; - -let traderequeststatus_to_json (d) : json = - `String (traderequeststatus_to_string d) -;; - -let traderequesttype_to_json (d) : json = - `String (traderequesttype_to_string d) -;; - -let tradedflatswitch_to_json (d) : json = - `String (tradedflatswitch_to_string d) -;; - -let trdregtimestamptype_to_json (d) : json = - `String (trdregtimestamptype_to_string d) -;; - -let trdrptstatus_to_json (d) : json = - `String (trdrptstatus_to_string d) -;; - -let trdtype_to_json (d) : json = - `String (trdtype_to_string d) -;; - -let unsolicitedindicator_to_json (d) : json = - `String (unsolicitedindicator_to_string d) -;; - -let urgency_to_json (d) : json = - `String (urgency_to_string d) -;; - -let userrequesttype_to_json (d) : json = - `String (userrequesttype_to_string d) -;; - -let userstatus_to_json (d) : json = - `String (userstatus_to_string d) -;; - -let workingindicator_to_json (d) : json = - `String (workingindicator_to_string d) -;; - -let yieldtype_to_json (d) : json = - `String (yieldtype_to_string d) -;; - -let currency_to_json (d) : json = - `String (currency_to_string d) -;; - -let country_to_json (d) : json = - `String (country_to_string d) -;; - -let exchange_to_json (d) : json = - `String (exchange_to_string d) -;; - -let week_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (week_to_json d) - ) -;; - -let accounttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (accounttype_to_json d) - ) -;; - -let acctidsource_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (acctidsource_to_json d) - ) -;; - -let adjustment_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (adjustment_to_json d) - ) -;; - -let adjustmenttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (adjustmenttype_to_json d) - ) -;; - -let advside_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (advside_to_json d) - ) -;; - -let advtranstype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (advtranstype_to_json d) - ) -;; - -let affirmstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (affirmstatus_to_json d) - ) -;; - -let aggregatedbook_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (aggregatedbook_to_json d) - ) -;; - -let allocaccounttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (allocaccounttype_to_json d) - ) -;; - -let alloccancreplacereason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (alloccancreplacereason_to_json d) - ) -;; - -let allochandlinst_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (allochandlinst_to_json d) - ) -;; - -let allocintermedreqtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (allocintermedreqtype_to_json d) - ) -;; - -let alloclinktype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (alloclinktype_to_json d) - ) -;; - -let allocnoorderstype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (allocnoorderstype_to_json d) - ) -;; - -let allocrejcode_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (allocrejcode_to_json d) - ) -;; - -let allocreporttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (allocreporttype_to_json d) - ) -;; - -let allocsettlinsttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (allocsettlinsttype_to_json d) - ) -;; - -let allocstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (allocstatus_to_json d) - ) -;; - -let alloctranstype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (alloctranstype_to_json d) - ) -;; - -let alloctype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (alloctype_to_json d) - ) -;; - -let applqueueaction_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (applqueueaction_to_json d) - ) -;; - -let applqueueresolution_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (applqueueresolution_to_json d) - ) -;; - -let assignmentmethod_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (assignmentmethod_to_json d) - ) -;; - -let avgpxindicator_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (avgpxindicator_to_json d) - ) -;; - -let basispxtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (basispxtype_to_json d) - ) -;; - -let biddescriptortype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (biddescriptortype_to_json d) - ) -;; - -let bidrequesttranstype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (bidrequesttranstype_to_json d) - ) -;; - -let bidtradetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (bidtradetype_to_json d) - ) -;; - -let bidtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (bidtype_to_json d) - ) -;; - -let bookingtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (bookingtype_to_json d) - ) -;; - -let bookingunit_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (bookingunit_to_json d) - ) -;; - -let cpprogram_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (cpprogram_to_json d) - ) -;; - -let cancellationrights_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (cancellationrights_to_json d) - ) -;; - -let cashmargin_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (cashmargin_to_json d) - ) -;; - -let clearingfeeindicator_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (clearingfeeindicator_to_json d) - ) -;; - -let clearinginstruction_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (clearinginstruction_to_json d) - ) -;; - -let collaction_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (collaction_to_json d) - ) -;; - -let collasgnreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (collasgnreason_to_json d) - ) -;; - -let collasgnrejectreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (collasgnrejectreason_to_json d) - ) -;; - -let collasgnresptype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (collasgnresptype_to_json d) - ) -;; - -let collasgntranstype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (collasgntranstype_to_json d) - ) -;; - -let collinquiryqualifier_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (collinquiryqualifier_to_json d) - ) -;; - -let collinquiryresult_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (collinquiryresult_to_json d) - ) -;; - -let collinquirystatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (collinquirystatus_to_json d) - ) -;; - -let collstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (collstatus_to_json d) - ) -;; - -let commtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (commtype_to_json d) - ) -;; - -let confirmrejreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (confirmrejreason_to_json d) - ) -;; - -let confirmstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (confirmstatus_to_json d) - ) -;; - -let confirmtranstype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (confirmtranstype_to_json d) - ) -;; - -let confirmtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (confirmtype_to_json d) - ) -;; - -let contamttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (contamttype_to_json d) - ) -;; - -let corporateaction_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (corporateaction_to_json d) - ) -;; - -let coveredoruncovered_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (coveredoruncovered_to_json d) - ) -;; - -let crossprioritization_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (crossprioritization_to_json d) - ) -;; - -let crosstype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (crosstype_to_json d) - ) -;; - -let custordercapacity_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (custordercapacity_to_json d) - ) -;; - -let cxlrejreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (cxlrejreason_to_json d) - ) -;; - -let cxlrejresponseto_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (cxlrejresponseto_to_json d) - ) -;; - -let dkreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (dkreason_to_json d) - ) -;; - -let daybookinginst_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (daybookinginst_to_json d) - ) -;; - -let deletereason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (deletereason_to_json d) - ) -;; - -let deliveryform_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (deliveryform_to_json d) - ) -;; - -let deliverytype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (deliverytype_to_json d) - ) -;; - -let discretioninst_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (discretioninst_to_json d) - ) -;; - -let discretionlimittype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (discretionlimittype_to_json d) - ) -;; - -let discretionmovetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (discretionmovetype_to_json d) - ) -;; - -let discretionoffsettype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (discretionoffsettype_to_json d) - ) -;; - -let discretionrounddirection_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (discretionrounddirection_to_json d) - ) -;; - -let discretionscope_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (discretionscope_to_json d) - ) -;; - -let distribpaymentmethod_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (distribpaymentmethod_to_json d) - ) -;; - -let dlvyinsttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (dlvyinsttype_to_json d) - ) -;; - -let duetorelated_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (duetorelated_to_json d) - ) -;; - -let emailtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (emailtype_to_json d) - ) -;; - -let eventtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (eventtype_to_json d) - ) -;; - -let exchangeforphysical_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (exchangeforphysical_to_json d) - ) -;; - -let execinst_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (execinst_to_json d) - ) -;; - -let execpricetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (execpricetype_to_json d) - ) -;; - -let execrestatementreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (execrestatementreason_to_json d) - ) -;; - -let exectype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (exectype_to_json d) - ) -;; - -let exercisemethod_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (exercisemethod_to_json d) - ) -;; - -let expirationcycle_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (expirationcycle_to_json d) - ) -;; - -let financialstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (financialstatus_to_json d) - ) -;; - -let forexreq_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (forexreq_to_json d) - ) -;; - -let fundrenewwaiv_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (fundrenewwaiv_to_json d) - ) -;; - -let gtbookinginst_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (gtbookinginst_to_json d) - ) -;; - -let haltreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (haltreason_to_json d) - ) -;; - -let handlinst_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (handlinst_to_json d) - ) -;; - -let ioinaturalflag_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (ioinaturalflag_to_json d) - ) -;; - -let ioiqltyind_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (ioiqltyind_to_json d) - ) -;; - -let ioiqty_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (ioiqty_to_json d) - ) -;; - -let ioiqualifier_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (ioiqualifier_to_json d) - ) -;; - -let ioitranstype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (ioitranstype_to_json d) - ) -;; - -let inviewofcommon_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (inviewofcommon_to_json d) - ) -;; - -let inctaxind_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (inctaxind_to_json d) - ) -;; - -let instrattribtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (instrattribtype_to_json d) - ) -;; - -let lastcapacity_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (lastcapacity_to_json d) - ) -;; - -let lastfragment_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (lastfragment_to_json d) - ) -;; - -let lastliquidityind_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (lastliquidityind_to_json d) - ) -;; - -let legswaptype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (legswaptype_to_json d) - ) -;; - -let legalconfirm_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (legalconfirm_to_json d) - ) -;; - -let liquidityindtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (liquidityindtype_to_json d) - ) -;; - -let listexecinsttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (listexecinsttype_to_json d) - ) -;; - -let listorderstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (listorderstatus_to_json d) - ) -;; - -let liststatustype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (liststatustype_to_json d) - ) -;; - -let locatereqd_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (locatereqd_to_json d) - ) -;; - -let mdentrytype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (mdentrytype_to_json d) - ) -;; - -let mdimplicitdelete_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (mdimplicitdelete_to_json d) - ) -;; - -let mdreqrejreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (mdreqrejreason_to_json d) - ) -;; - -let mdupdateaction_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (mdupdateaction_to_json d) - ) -;; - -let mdupdatetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (mdupdatetype_to_json d) - ) -;; - -let masscancelrejectreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (masscancelrejectreason_to_json d) - ) -;; - -let masscancelrequesttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (masscancelrequesttype_to_json d) - ) -;; - -let masscancelresponse_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (masscancelresponse_to_json d) - ) -;; - -let massstatusreqtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (massstatusreqtype_to_json d) - ) -;; - -let matchstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (matchstatus_to_json d) - ) -;; - -let matchtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (matchtype_to_json d) - ) -;; - -let messageencoding_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (messageencoding_to_json d) - ) -;; - -let miscfeebasis_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (miscfeebasis_to_json d) - ) -;; - -let miscfeetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (miscfeetype_to_json d) - ) -;; - -let moneylaunderingstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (moneylaunderingstatus_to_json d) - ) -;; - -let msgdirection_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (msgdirection_to_json d) - ) -;; - -let multilegreportingtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (multilegreportingtype_to_json d) - ) -;; - -let multilegrpttypereq_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (multilegrpttypereq_to_json d) - ) -;; - -let netgrossind_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (netgrossind_to_json d) - ) -;; - -let networkrequesttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (networkrequesttype_to_json d) - ) -;; - -let networkstatusresponsetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (networkstatusresponsetype_to_json d) - ) -;; - -let nosides_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (nosides_to_json d) - ) -;; - -let notifybrokerofcredit_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (notifybrokerofcredit_to_json d) - ) -;; - -let oddlot_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (oddlot_to_json d) - ) -;; - -let openclosesettlflag_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (openclosesettlflag_to_json d) - ) -;; - -let ordrejreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (ordrejreason_to_json d) - ) -;; - -let ordstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (ordstatus_to_json d) - ) -;; - -let ordtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (ordtype_to_json d) - ) -;; - -let ordercapacity_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (ordercapacity_to_json d) - ) -;; - -let orderrestrictions_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (orderrestrictions_to_json d) - ) -;; - -let ownertype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (ownertype_to_json d) - ) -;; - -let ownershiptype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (ownershiptype_to_json d) - ) -;; - -let partyidsource_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (partyidsource_to_json d) - ) -;; - -let partyrole_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (partyrole_to_json d) - ) -;; - -let partysubidtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (partysubidtype_to_json d) - ) -;; - -let paymentmethod_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (paymentmethod_to_json d) - ) -;; - -let peglimittype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (peglimittype_to_json d) - ) -;; - -let pegmovetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (pegmovetype_to_json d) - ) -;; - -let pegoffsettype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (pegoffsettype_to_json d) - ) -;; - -let pegrounddirection_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (pegrounddirection_to_json d) - ) -;; - -let pegscope_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (pegscope_to_json d) - ) -;; - -let posamttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (posamttype_to_json d) - ) -;; - -let posmaintaction_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (posmaintaction_to_json d) - ) -;; - -let posmaintresult_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (posmaintresult_to_json d) - ) -;; - -let posmaintstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (posmaintstatus_to_json d) - ) -;; - -let posqtystatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (posqtystatus_to_json d) - ) -;; - -let posreqresult_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (posreqresult_to_json d) - ) -;; - -let posreqstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (posreqstatus_to_json d) - ) -;; - -let posreqtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (posreqtype_to_json d) - ) -;; - -let postranstype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (postranstype_to_json d) - ) -;; - -let postype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (postype_to_json d) - ) -;; - -let positioneffect_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (positioneffect_to_json d) - ) -;; - -let possdupflag_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (possdupflag_to_json d) - ) -;; - -let possresend_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (possresend_to_json d) - ) -;; - -let preallocmethod_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (preallocmethod_to_json d) - ) -;; - -let previouslyreported_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (previouslyreported_to_json d) - ) -;; - -let pricetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (pricetype_to_json d) - ) -;; - -let priorityindicator_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (priorityindicator_to_json d) - ) -;; - -let processcode_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (processcode_to_json d) - ) -;; - -let product_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (product_to_json d) - ) -;; - -let progrptreqs_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (progrptreqs_to_json d) - ) -;; - -let publishtrdindicator_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (publishtrdindicator_to_json d) - ) -;; - -let putorcall_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (putorcall_to_json d) - ) -;; - -let qtytype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (qtytype_to_json d) - ) -;; - -let quotecanceltype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (quotecanceltype_to_json d) - ) -;; - -let quotecondition_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (quotecondition_to_json d) - ) -;; - -let quotepricetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (quotepricetype_to_json d) - ) -;; - -let quoterejectreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (quoterejectreason_to_json d) - ) -;; - -let quoterequestrejectreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (quoterequestrejectreason_to_json d) - ) -;; - -let quoterequesttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (quoterequesttype_to_json d) - ) -;; - -let quoteresptype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (quoteresptype_to_json d) - ) -;; - -let quoteresponselevel_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (quoteresponselevel_to_json d) - ) -;; - -let quotestatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (quotestatus_to_json d) - ) -;; - -let quotetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (quotetype_to_json d) - ) -;; - -let registrejreasoncode_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (registrejreasoncode_to_json d) - ) -;; - -let registstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (registstatus_to_json d) - ) -;; - -let registtranstype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (registtranstype_to_json d) - ) -;; - -let reporttoexch_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (reporttoexch_to_json d) - ) -;; - -let resetseqnumflag_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (resetseqnumflag_to_json d) - ) -;; - -let responsetransporttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (responsetransporttype_to_json d) - ) -;; - -let roundingdirection_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (roundingdirection_to_json d) - ) -;; - -let routingtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (routingtype_to_json d) - ) -;; - -let scope_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (scope_to_json d) - ) -;; - -let securityidsource_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (securityidsource_to_json d) - ) -;; - -let securitylistrequesttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (securitylistrequesttype_to_json d) - ) -;; - -let securityrequestresult_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (securityrequestresult_to_json d) - ) -;; - -let securityrequesttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (securityrequesttype_to_json d) - ) -;; - -let securityresponsetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (securityresponsetype_to_json d) - ) -;; - -let securitytradingstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (securitytradingstatus_to_json d) - ) -;; - -let securitytype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (securitytype_to_json d) - ) -;; - -let settlcurrfxratecalc_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (settlcurrfxratecalc_to_json d) - ) -;; - -let settldeliverytype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (settldeliverytype_to_json d) - ) -;; - -let settlinstmode_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (settlinstmode_to_json d) - ) -;; - -let settlinstreqrejcode_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (settlinstreqrejcode_to_json d) - ) -;; - -let settlinstsource_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (settlinstsource_to_json d) - ) -;; - -let settlinsttranstype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (settlinsttranstype_to_json d) - ) -;; - -let settlpricetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (settlpricetype_to_json d) - ) -;; - -let settlsessid_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (settlsessid_to_json d) - ) -;; - -let settltype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (settltype_to_json d) - ) -;; - -let shortsalereason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (shortsalereason_to_json d) - ) -;; - -let side_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (side_to_json d) - ) -;; - -let sidemultilegreportingtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (sidemultilegreportingtype_to_json d) - ) -;; - -let sidevalueind_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (sidevalueind_to_json d) - ) -;; - -let solicitedflag_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (solicitedflag_to_json d) - ) -;; - -let standinstdbtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (standinstdbtype_to_json d) - ) -;; - -let statusvalue_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (statusvalue_to_json d) - ) -;; - -let stipulationtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (stipulationtype_to_json d) - ) -;; - -let subscriptionrequesttype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (subscriptionrequesttype_to_json d) - ) -;; - -let targetstrategy_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (targetstrategy_to_json d) - ) -;; - -let taxadvantagetype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (taxadvantagetype_to_json d) - ) -;; - -let terminationtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (terminationtype_to_json d) - ) -;; - -let testmessageindicator_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (testmessageindicator_to_json d) - ) -;; - -let tickdirection_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (tickdirection_to_json d) - ) -;; - -let timeinforce_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (timeinforce_to_json d) - ) -;; - -let tradsesmethod_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (tradsesmethod_to_json d) - ) -;; - -let tradsesmode_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (tradsesmode_to_json d) - ) -;; - -let tradsesstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (tradsesstatus_to_json d) - ) -;; - -let tradsesstatusrejreason_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (tradsesstatusrejreason_to_json d) - ) -;; +(* Imandra Inc. copyright 2021 *) +[@@@program] +[@@@import "../src-protocol-exts/full_app_enums.iml"] +open Full_app_enums;; +[@@@require "yojson"] +open Yojson.Basic;; -let tradeallocindicator_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (tradeallocindicator_to_json d) - ) -;; -let tradecondition_opt_to_json (d) : json = +let execinst_to_string (d) = (match d with - | None -> (`Null) - | Some d -> (tradecondition_to_json d) + | FIX_ExecInst_NotHeld -> "NotHeld" + | FIX_ExecInst_Work -> "Work" + | FIX_ExecInst_GoAlong -> "GoAlong" + | FIX_ExecInst_OverTheDay -> "OverTheDay" + | FIX_ExecInst_Held -> "Held" + | FIX_ExecInst_ParticipateDoNotInitiate -> "ParticipateDoNotInitiate" + | FIX_ExecInst_StrictScale -> "StrictScale" + | FIX_ExecInst_TryToScale -> "TryToScale" + | FIX_ExecInst_StayOnBidSide -> "StayOnBidSide" + | FIX_ExecInst_StayOnOfferSide -> "StayOnOfferSide" + | FIX_ExecInst_NoCross -> "NoCross" + | FIX_ExecInst_OKToCross -> "OKToCross" + | FIX_ExecInst_CallFirst -> "CallFirst" + | FIX_ExecInst_PercentOfVolume -> "PercentOfVolume" + | FIX_ExecInst_DoNotIncrease -> "DoNotIncrease" + | FIX_ExecInst_DoNotReduce -> "DoNotReduce" + | FIX_ExecInst_AllOrNone -> "AllOrNone" + | FIX_ExecInst_ReinstateOnSystemFailure -> "ReinstateOnSystemFailure" + | FIX_ExecInst_InstitutionsOnly -> "InstitutionsOnly" + | FIX_ExecInst_ReinstateOnTradingHalt -> "ReinstateOnTradingHalt" + | FIX_ExecInst_CancelOnTradingHalt -> "CancelOnTradingHalt" + | FIX_ExecInst_LastPeg -> "LastPeg" + | FIX_ExecInst_MidPricePeg -> "MidPricePeg" + | FIX_ExecInst_NonNegotiable -> "NonNegotiable" + | FIX_ExecInst_OpeningPeg -> "OpeningPeg" + | FIX_ExecInst_MarketPeg -> "MarketPeg" + | FIX_ExecInst_CancelOnSystemFailure -> "CancelOnSystemFailure" + | FIX_ExecInst_PrimaryPeg -> "PrimaryPeg" + | FIX_ExecInst_Suspend -> "Suspend" + | FIX_ExecInst_CustomerDisplayInstruction -> "CustomerDisplayInstruction" + | FIX_ExecInst_Netting -> "Netting" + | FIX_ExecInst_PegToVWAP -> "PegToVWAP" + | FIX_ExecInst_TradeAlong -> "TradeAlong" + | FIX_ExecInst_TryToStop -> "TryToStop" + | FIX_ExecInst_CancelIfNotBest -> "CancelIfNotBest" + | FIX_ExecInst_TrailingStopPeg -> "TrailingStopPeg" + | FIX_ExecInst_StrictLimit -> "StrictLimit" + | FIX_ExecInst_IgnorePriceValidityChecks -> "IgnorePriceValidityChecks" + | FIX_ExecInst_PegToLimitPrice -> "PegToLimitPrice" + | FIX_ExecInst_WorkToTargetStrategy -> "WorkToTargetStrategy" + | FIX_INVALID_ExecInst s -> s ) ;; -let tradereportrejectreason_opt_to_json (d) : json = +let exectype_to_string (d) = (match d with - | None -> (`Null) - | Some d -> (tradereportrejectreason_to_json d) + | FIX_ExecType_New -> "New" + | FIX_ExecType_DoneForDay -> "DoneForDay" + | FIX_ExecType_Canceled -> "Canceled" + | FIX_ExecType_Replaced -> "Replaced" + | FIX_ExecType_PendingCancel -> "PendingCancel" + | FIX_ExecType_Stopped -> "Stopped" + | FIX_ExecType_Rejected -> "Rejected" + | FIX_ExecType_Suspended -> "Suspended" + | FIX_ExecType_PendingNew -> "PendingNew" + | FIX_ExecType_Calculated -> "Calculated" + | FIX_ExecType_Expired -> "Expired" + | FIX_ExecType_Restated -> "Restated" + | FIX_ExecType_PendingReplace -> "PendingReplace" + | FIX_ExecType_Trade -> "Trade" + | FIX_ExecType_TradeCorrect -> "TradeCorrect" + | FIX_ExecType_TradeCancel -> "TradeCancel" + | FIX_ExecType_OrderStatus -> "OrderStatus" + | FIX_INVALID_ExecType s -> s ) ;; -let tradereporttype_opt_to_json (d) : json = +let ordstatus_to_string (d) = (match d with - | None -> (`Null) - | Some d -> (tradereporttype_to_json d) + | FIX_OrdStatus_New -> "New" + | FIX_OrdStatus_PartiallyFilled -> "PartiallyFilled" + | FIX_OrdStatus_Filled -> "Filled" + | FIX_OrdStatus_DoneForDay -> "DoneForDay" + | FIX_OrdStatus_Canceled -> "Canceled" + | FIX_OrdStatus_PendingCancel -> "PendingCancel" + | FIX_OrdStatus_Stopped -> "Stopped" + | FIX_OrdStatus_Rejected -> "Rejected" + | FIX_OrdStatus_Suspended -> "Suspended" + | FIX_OrdStatus_PendingNew -> "PendingNew" + | FIX_OrdStatus_Calculated -> "Calculated" + | FIX_OrdStatus_Expired -> "Expired" + | FIX_OrdStatus_AcceptedForBidding -> "AcceptedForBidding" + | FIX_OrdStatus_PendingReplace -> "PendingReplace" + | FIX_OrdStatus_Replaced -> "Replaced" + | FIX_INVALID_OrdStatus s -> s ) ;; -let traderequestresult_opt_to_json (d) : json = +let ordtype_to_string (d) = (match d with - | None -> (`Null) - | Some d -> (traderequestresult_to_json d) + | FIX_OrdType_Market -> "Market" + | FIX_OrdType_Limit -> "Limit" + | FIX_OrdType_Stop -> "Stop" + | FIX_OrdType_StopLimit -> "StopLimit" + | FIX_OrdType_WithOrWithout -> "WithOrWithout" + | FIX_OrdType_LimitOrBetter -> "LimitOrBetter" + | FIX_OrdType_LimitWithOrWithout -> "LimitWithOrWithout" + | FIX_OrdType_OnBasis -> "OnBasis" + | FIX_OrdType_PreviouslyQuoted -> "PreviouslyQuoted" + | FIX_OrdType_PreviouslyIndicated -> "PreviouslyIndicated" + | FIX_OrdType_ForexSwap -> "ForexSwap" + | FIX_OrdType_Funari -> "Funari" + | FIX_OrdType_MarketIfTouched -> "MarketIfTouched" + | FIX_OrdType_MarketWithLeftOverAsLimit -> "MarketWithLeftOverAsLimit" + | FIX_OrdType_PreviousFundValuationPoint -> "PreviousFundValuationPoint" + | FIX_OrdType_NextFundValuationPoint -> "NextFundValuationPoint" + | FIX_OrdType_Pegged -> "Pegged" + | FIX_OrdType_StopSpread -> "StopSpread" + | FIX_INVALID_OrdType s -> s ) ;; -let traderequeststatus_opt_to_json (d) : json = +let partysubidtype_to_string (d) = (match d with - | None -> (`Null) - | Some d -> (traderequeststatus_to_json d) + | FIX_PartySubIDType_Firm -> "Firm" + | FIX_PartySubIDType_Person -> "Person" + | FIX_PartySubIDType_System -> "System" + | FIX_PartySubIDType_Application -> "Application" + | FIX_PartySubIDType_FullLegalNameOfFirm -> "FullLegalNameOfFirm" + | FIX_PartySubIDType_PostalAddress -> "PostalAddress" + | FIX_PartySubIDType_PhoneNumber -> "PhoneNumber" + | FIX_PartySubIDType_EmailAddress -> "EmailAddress" + | FIX_PartySubIDType_ContactName -> "ContactName" + | FIX_PartySubIDType_SecuritiesAccountNumber -> "SecuritiesAccountNumber" + | FIX_PartySubIDType_RegistrationNumber -> "RegistrationNumber" + | FIX_PartySubIDType_RegisteredAddressForConfirmation -> "RegisteredAddressForConfirmation" + | FIX_PartySubIDType_RegulatoryStatus -> "RegulatoryStatus" + | FIX_PartySubIDType_RegistrationName -> "RegistrationName" + | FIX_PartySubIDType_CashAccountNumber -> "CashAccountNumber" + | FIX_PartySubIDType_BIC -> "BIC" + | FIX_PartySubIDType_CSDParticipantMemberCode -> "CSDParticipantMemberCode" + | FIX_PartySubIDType_RegisteredAddress -> "RegisteredAddress" + | FIX_PartySubIDType_FundAccountName -> "FundAccountName" + | FIX_PartySubIDType_TelexNumber -> "TelexNumber" + | FIX_PartySubIDType_FaxNumber -> "FaxNumber" + | FIX_PartySubIDType_SecuritiesAccountName -> "SecuritiesAccountName" + | FIX_PartySubIDType_CashAccountName -> "CashAccountName" + | FIX_PartySubIDType_Department -> "Department" + | FIX_PartySubIDType_LocationDesk -> "LocationDesk" + | FIX_PartySubIDType_PositionAccountType -> "PositionAccountType" + | FIX_INVALID_PartySubIDType s -> s ) ;; -let traderequesttype_opt_to_json (d) : json = +let side_to_string (d) = (match d with - | None -> (`Null) - | Some d -> (traderequesttype_to_json d) + | FIX_Side_Buy -> "Buy" + | FIX_Side_Sell -> "Sell" + | FIX_Side_BuyMinus -> "BuyMinus" + | FIX_Side_SellPlus -> "SellPlus" + | FIX_Side_SellShort -> "SellShort" + | FIX_Side_SellShortExempt -> "SellShortExempt" + | FIX_Side_Undisclosed -> "Undisclosed" + | FIX_Side_Cross -> "Cross" + | FIX_Side_CrossShort -> "CrossShort" + | FIX_Side_CrossShortExempt -> "CrossShortExempt" + | FIX_Side_AsDefined -> "AsDefined" + | FIX_Side_Opposite -> "Opposite" + | FIX_Side_Subscribe -> "Subscribe" + | FIX_Side_Redeem -> "Redeem" + | FIX_Side_Lend -> "Lend" + | FIX_Side_Borrow -> "Borrow" + | FIX_INVALID_Side s -> s ) ;; -let tradedflatswitch_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (tradedflatswitch_to_json d) - ) +let execinst_to_json (d) : json = + `List (List.map (fun x -> `String (execinst_to_string x) + ) d) ;; -let trdregtimestamptype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (trdregtimestamptype_to_json d) - ) +let exectype_to_json (d) : json = + `String (exectype_to_string d) ;; -let trdrptstatus_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (trdrptstatus_to_json d) - ) +let ordstatus_to_json (d) : json = + `String (ordstatus_to_string d) ;; -let trdtype_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (trdtype_to_json d) - ) +let ordtype_to_json (d) : json = + `String (ordtype_to_string d) ;; -let unsolicitedindicator_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (unsolicitedindicator_to_json d) - ) +let partysubidtype_to_json (d) : json = + `String (partysubidtype_to_string d) ;; -let urgency_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (urgency_to_json d) - ) +let side_to_json (d) : json = + `String (side_to_string d) ;; -let userrequesttype_opt_to_json (d) : json = +let execinst_opt_to_json (d) : json = (match d with | None -> (`Null) - | Some d -> (userrequesttype_to_json d) + | Some d -> (execinst_to_json d) ) ;; -let userstatus_opt_to_json (d) : json = +let exectype_opt_to_json (d) : json = (match d with | None -> (`Null) - | Some d -> (userstatus_to_json d) + | Some d -> (exectype_to_json d) ) ;; -let workingindicator_opt_to_json (d) : json = +let ordstatus_opt_to_json (d) : json = (match d with | None -> (`Null) - | Some d -> (workingindicator_to_json d) + | Some d -> (ordstatus_to_json d) ) ;; -let yieldtype_opt_to_json (d) : json = +let ordtype_opt_to_json (d) : json = (match d with | None -> (`Null) - | Some d -> (yieldtype_to_json d) + | Some d -> (ordtype_to_json d) ) ;; -let currency_opt_to_json (d) : json = +let partysubidtype_opt_to_json (d) : json = (match d with | None -> (`Null) - | Some d -> (currency_to_json d) + | Some d -> (partysubidtype_to_json d) ) ;; -let country_opt_to_json (d) : json = +let side_opt_to_json (d) : json = (match d with | None -> (`Null) - | Some d -> (country_to_json d) + | Some d -> (side_to_json d) ) ;; -let exchange_opt_to_json (d) : json = - (match d with - | None -> (`Null) - | Some d -> (exchange_to_json d) - ) -;; [@@@logic] diff --git a/src-protocol-exts-pp/full_app_messages_decoder.iml b/src-protocol-exts-pp/full_app_messages_decoder.iml index 95ea176b..07d646fd 100644 --- a/src-protocol-exts-pp/full_app_messages_decoder.iml +++ b/src-protocol-exts-pp/full_app_messages_decoder.iml @@ -1,13 +1,79 @@ (* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-core-pp/base_types_json.iml"] +open Base_types_json;; +[@@@import "../src-core-pp/datetime_json.iml"] +open Datetime_json;; [@@@require "decoders-yojson"] open Decoders_yojson.Basic.Decode;; +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode.Infix;; +[@@@import "full_app_enums_decoder.iml"] +open Full_app_enums_decoder;; [@@@import "../src-protocol-exts/full_app_messages.iml"] open Full_app_messages;; +[@@@import "full_app_records_decoder.iml"] +open Full_app_records_decoder;; + + +let full_message_newordersingle_decoder : full_fix_newordersingle_data decoder = + (maybe (field "SpreadProportion" float_decoder)) >>= (fun f_NewOrderSingle_SpreadProportion -> (maybe (field "Price" float_2_decoder)) >>= (fun f_NewOrderSingle_Price -> (maybe (field "OrdType" full_enum_ordtype_decoder)) >>= (fun f_NewOrderSingle_OrdType -> (field "OrderQtyData" full_record_orderqtydata_decoder) >>= (fun f_NewOrderSingle_OrderQtyData -> (maybe (field "TransactTime" utctimestamp_milli_decoder)) >>= (fun f_NewOrderSingle_TransactTime -> (maybe (field "Side" full_enum_side_decoder)) >>= (fun f_NewOrderSingle_Side -> (maybe (field "ExecInst" full_enum_execinst_decoder)) >>= (fun f_NewOrderSingle_ExecInst -> (maybe (field "Account" string_decoder)) >>= (fun f_NewOrderSingle_Account -> (field "Parties" full_rg_parties_decoder) >>= (fun f_NewOrderSingle_Parties -> (maybe (field "ClOrdID" string_decoder)) >>= (fun f_NewOrderSingle_ClOrdID -> succeed { + f_NewOrderSingle_ClOrdID = f_NewOrderSingle_ClOrdID; + f_NewOrderSingle_Parties = f_NewOrderSingle_Parties; + f_NewOrderSingle_Account = f_NewOrderSingle_Account; + f_NewOrderSingle_ExecInst = f_NewOrderSingle_ExecInst; + f_NewOrderSingle_Side = f_NewOrderSingle_Side; + f_NewOrderSingle_TransactTime = f_NewOrderSingle_TransactTime; + f_NewOrderSingle_OrderQtyData = f_NewOrderSingle_OrderQtyData; + f_NewOrderSingle_OrdType = f_NewOrderSingle_OrdType; + f_NewOrderSingle_Price = f_NewOrderSingle_Price; + f_NewOrderSingle_SpreadProportion = f_NewOrderSingle_SpreadProportion + } + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) +;; +let full_message_executionreport_decoder : full_fix_executionreport_data decoder = + (maybe (field "Text" string_decoder)) >>= (fun f_ExecutionReport_Text -> (maybe (field "CumQty" float_6_decoder)) >>= (fun f_ExecutionReport_CumQty -> (maybe (field "LeavesQty" float_6_decoder)) >>= (fun f_ExecutionReport_LeavesQty -> (maybe (field "ExecInst" full_enum_execinst_decoder)) >>= (fun f_ExecutionReport_ExecInst -> (field "OrderQtyData" full_record_orderqtydata_decoder) >>= (fun f_ExecutionReport_OrderQtyData -> (maybe (field "Side" full_enum_side_decoder)) >>= (fun f_ExecutionReport_Side -> (maybe (field "OrdStatus" full_enum_ordstatus_decoder)) >>= (fun f_ExecutionReport_OrdStatus -> (maybe (field "ExecType" full_enum_exectype_decoder)) >>= (fun f_ExecutionReport_ExecType -> (maybe (field "ExecID" string_decoder)) >>= (fun f_ExecutionReport_ExecID -> (field "Parties" full_rg_parties_decoder) >>= (fun f_ExecutionReport_Parties -> (maybe (field "OrderID" string_decoder)) >>= (fun f_ExecutionReport_OrderID -> succeed { + f_ExecutionReport_OrderID = f_ExecutionReport_OrderID; + f_ExecutionReport_Parties = f_ExecutionReport_Parties; + f_ExecutionReport_ExecID = f_ExecutionReport_ExecID; + f_ExecutionReport_ExecType = f_ExecutionReport_ExecType; + f_ExecutionReport_OrdStatus = f_ExecutionReport_OrdStatus; + f_ExecutionReport_Side = f_ExecutionReport_Side; + f_ExecutionReport_OrderQtyData = f_ExecutionReport_OrderQtyData; + f_ExecutionReport_ExecInst = f_ExecutionReport_ExecInst; + f_ExecutionReport_LeavesQty = f_ExecutionReport_LeavesQty; + f_ExecutionReport_CumQty = f_ExecutionReport_CumQty; + f_ExecutionReport_Text = f_ExecutionReport_Text + } + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) + ) +;; let full_app_msg_of_json : full_app_msg_data decoder = single_field (fun x -> (match x with + | "NewOrderSingle" -> (full_message_newordersingle_decoder >>= (fun y -> succeed (FIX_Full_Msg_NewOrderSingle y) + )) + | "ExecutionReport" -> (full_message_executionreport_decoder >>= (fun y -> succeed (FIX_Full_Msg_ExecutionReport y) + )) | d -> (fail ("Unknown Message ("^d^") in JSON decoding.")) ) ) diff --git a/src-protocol-exts-pp/full_app_messages_json.iml b/src-protocol-exts-pp/full_app_messages_json.iml index 2e97c160..00a7509d 100644 --- a/src-protocol-exts-pp/full_app_messages_json.iml +++ b/src-protocol-exts-pp/full_app_messages_json.iml @@ -1,31 +1,44 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "../src-core-pp/base_types_json.iml"] -[@@@import "../src-core-pp/datetime_json.iml"] -[@@@import "full_app_enums_json.iml"] -[@@@import "../src-protocol-exts/full_app_messages.iml"] -[@@@import "full_app_records_json.iml"] -[@@@import "json_generator_utils.iml"] +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-core-pp/base_types_json.iml"] open Base_types_json;; +[@@@import "../src-core-pp/datetime_json.iml"] open Datetime_json;; +[@@@import "full_app_enums_json.iml"] open Full_app_enums_json;; +[@@@import "../src-protocol-exts/full_app_messages.iml"] open Full_app_messages;; +[@@@import "full_app_records_json.iml"] open Full_app_records_json;; +[@@@import "json_generator_utils.iml"] open Json_generator_utils;; +[@@@require "yojson"] open Yojson.Basic;; -let executionreport_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_ExecutionReport_Instrument) :: (("FinancingDetails",financingdetails_to_json x.f_ExecutionReport_FinancingDetails) :: (("OrderQtyData",orderqtydata_to_json x.f_ExecutionReport_OrderQtyData) :: (("PegInstructions",peginstructions_to_json x.f_ExecutionReport_PegInstructions) :: (("DiscretionInstructions",discretioninstructions_to_json x.f_ExecutionReport_DiscretionInstructions) :: (("CommissionData",commissiondata_to_json x.f_ExecutionReport_CommissionData) :: (("SpreadOrBenchmarkCurveData",spreadorbenchmarkcurvedata_to_json x.f_ExecutionReport_SpreadOrBenchmarkCurveData) :: (("YieldData",yielddata_to_json x.f_ExecutionReport_YieldData) :: (("OrderID",string_opt_to_json x.f_ExecutionReport_OrderID) :: (("SecondaryOrderID",string_opt_to_json x.f_ExecutionReport_SecondaryOrderID) :: (("SecondaryClOrdID",string_opt_to_json x.f_ExecutionReport_SecondaryClOrdID) :: (("SecondaryExecID",string_opt_to_json x.f_ExecutionReport_SecondaryExecID) :: (("ClOrdID",string_opt_to_json x.f_ExecutionReport_ClOrdID) :: (("OrigClOrdID",string_opt_to_json x.f_ExecutionReport_OrigClOrdID) :: (("ClOrdLinkID",string_opt_to_json x.f_ExecutionReport_ClOrdLinkID) :: (("QuoteRespID",string_opt_to_json x.f_ExecutionReport_QuoteRespID) :: (("OrdStatusReqID",string_opt_to_json x.f_ExecutionReport_OrdStatusReqID) :: (("MassStatusReqID",string_opt_to_json x.f_ExecutionReport_MassStatusReqID) :: (("TotNumReports",int_opt_to_json x.f_ExecutionReport_TotNumReports) :: (("LastRptRequested",bool_opt_to_json x.f_ExecutionReport_LastRptRequested) :: (("TradeOriginationDate",localmktdate_opt_to_json x.f_ExecutionReport_TradeOriginationDate) :: (("ListID",string_opt_to_json x.f_ExecutionReport_ListID) :: (("CrossID",string_opt_to_json x.f_ExecutionReport_CrossID) :: (("OrigCrossID",string_opt_to_json x.f_ExecutionReport_OrigCrossID) :: (("CrossType",crosstype_opt_to_json x.f_ExecutionReport_CrossType) :: (("ExecID",string_opt_to_json x.f_ExecutionReport_ExecID) :: (("ExecRefID",string_opt_to_json x.f_ExecutionReport_ExecRefID) :: (("ExecType",exectype_opt_to_json x.f_ExecutionReport_ExecType) :: (("OrdStatus",ordstatus_opt_to_json x.f_ExecutionReport_OrdStatus) :: (("WorkingIndicator",workingindicator_opt_to_json x.f_ExecutionReport_WorkingIndicator) :: (("OrdRejReason",ordrejreason_opt_to_json x.f_ExecutionReport_OrdRejReason) :: (("ExecRestatementReason",execrestatementreason_opt_to_json x.f_ExecutionReport_ExecRestatementReason) :: (("Account",string_opt_to_json x.f_ExecutionReport_Account) :: (("AcctIDSource",acctidsource_opt_to_json x.f_ExecutionReport_AcctIDSource) :: (("AccountType",accounttype_opt_to_json x.f_ExecutionReport_AccountType) :: (("DayBookingInst",daybookinginst_opt_to_json x.f_ExecutionReport_DayBookingInst) :: (("BookingUnit",bookingunit_opt_to_json x.f_ExecutionReport_BookingUnit) :: (("PreallocMethod",preallocmethod_opt_to_json x.f_ExecutionReport_PreallocMethod) :: (("SettlType",settltype_opt_to_json x.f_ExecutionReport_SettlType) :: (("SettlDate",localmktdate_opt_to_json x.f_ExecutionReport_SettlDate) :: (("CashMargin",cashmargin_opt_to_json x.f_ExecutionReport_CashMargin) :: (("ClearingFeeIndicator",clearingfeeindicator_opt_to_json x.f_ExecutionReport_ClearingFeeIndicator) :: (("Side",side_opt_to_json x.f_ExecutionReport_Side) :: (("QtyType",qtytype_opt_to_json x.f_ExecutionReport_QtyType) :: (("OrdType",ordtype_opt_to_json x.f_ExecutionReport_OrdType) :: (("PriceType",pricetype_opt_to_json x.f_ExecutionReport_PriceType) :: (("Price",float_6_opt_to_json x.f_ExecutionReport_Price) :: (("StopPx",float_6_opt_to_json x.f_ExecutionReport_StopPx) :: (("PeggedPrice",float_6_opt_to_json x.f_ExecutionReport_PeggedPrice) :: (("DiscretionPrice",float_6_opt_to_json x.f_ExecutionReport_DiscretionPrice) :: (("TargetStrategy",targetstrategy_opt_to_json x.f_ExecutionReport_TargetStrategy) :: (("TargetStrategyParameters",string_opt_to_json x.f_ExecutionReport_TargetStrategyParameters) :: (("ParticipationRate",float_6_opt_to_json x.f_ExecutionReport_ParticipationRate) :: (("TargetStrategyPerformance",float_opt_to_json x.f_ExecutionReport_TargetStrategyPerformance) :: (("Currency",currency_opt_to_json x.f_ExecutionReport_Currency) :: (("ComplianceID",string_opt_to_json x.f_ExecutionReport_ComplianceID) :: (("SolicitedFlag",solicitedflag_opt_to_json x.f_ExecutionReport_SolicitedFlag) :: (("TimeInForce",timeinforce_opt_to_json x.f_ExecutionReport_TimeInForce) :: (("EffectiveTime",utctimestamp_milli_opt_to_json x.f_ExecutionReport_EffectiveTime) :: (("ExpireDate",localmktdate_opt_to_json x.f_ExecutionReport_ExpireDate) :: (("ExpireTime",utctimestamp_milli_opt_to_json x.f_ExecutionReport_ExpireTime) :: (("ExecInst",execinst_opt_to_json x.f_ExecutionReport_ExecInst) :: (("OrderCapacity",ordercapacity_opt_to_json x.f_ExecutionReport_OrderCapacity) :: (("OrderRestrictions",orderrestrictions_opt_to_json x.f_ExecutionReport_OrderRestrictions) :: (("CustOrderCapacity",custordercapacity_opt_to_json x.f_ExecutionReport_CustOrderCapacity) :: (("LastQty",float_6_opt_to_json x.f_ExecutionReport_LastQty) :: (("UnderlyingLastQty",float_6_opt_to_json x.f_ExecutionReport_UnderlyingLastQty) :: (("LastPx",float_6_opt_to_json x.f_ExecutionReport_LastPx) :: (("UnderlyingLastPx",float_6_opt_to_json x.f_ExecutionReport_UnderlyingLastPx) :: (("LastParPx",float_6_opt_to_json x.f_ExecutionReport_LastParPx) :: (("LastSpotRate",float_6_opt_to_json x.f_ExecutionReport_LastSpotRate) :: (("LastForwardPoints",float_6_opt_to_json x.f_ExecutionReport_LastForwardPoints) :: (("LastMkt",exchange_opt_to_json x.f_ExecutionReport_LastMkt) :: (("TradingSessionID",string_opt_to_json x.f_ExecutionReport_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_ExecutionReport_TradingSessionSubID) :: (("TimeBracket",string_opt_to_json x.f_ExecutionReport_TimeBracket) :: (("LastCapacity",lastcapacity_opt_to_json x.f_ExecutionReport_LastCapacity) :: (("LeavesQty",float_6_opt_to_json x.f_ExecutionReport_LeavesQty) :: (("CumQty",float_6_opt_to_json x.f_ExecutionReport_CumQty) :: (("AvgPx",float_6_opt_to_json x.f_ExecutionReport_AvgPx) :: (("DayOrderQty",float_6_opt_to_json x.f_ExecutionReport_DayOrderQty) :: (("DayCumQty",float_6_opt_to_json x.f_ExecutionReport_DayCumQty) :: (("DayAvgPx",float_6_opt_to_json x.f_ExecutionReport_DayAvgPx) :: (("GTBookingInst",gtbookinginst_opt_to_json x.f_ExecutionReport_GTBookingInst) :: (("TradeDate",localmktdate_opt_to_json x.f_ExecutionReport_TradeDate) :: (("TransactTime",utctimestamp_milli_opt_to_json x.f_ExecutionReport_TransactTime) :: (("ReportToExch",reporttoexch_opt_to_json x.f_ExecutionReport_ReportToExch) :: (("GrossTradeAmt",float_6_opt_to_json x.f_ExecutionReport_GrossTradeAmt) :: (("NumDaysInterest",int_opt_to_json x.f_ExecutionReport_NumDaysInterest) :: (("ExDate",localmktdate_opt_to_json x.f_ExecutionReport_ExDate) :: (("AccruedInterestRate",float_6_opt_to_json x.f_ExecutionReport_AccruedInterestRate) :: (("AccruedInterestAmt",float_6_opt_to_json x.f_ExecutionReport_AccruedInterestAmt) :: (("InterestAtMaturity",float_6_opt_to_json x.f_ExecutionReport_InterestAtMaturity) :: (("EndAccruedInterestAmt",float_6_opt_to_json x.f_ExecutionReport_EndAccruedInterestAmt) :: (("StartCash",float_6_opt_to_json x.f_ExecutionReport_StartCash) :: (("EndCash",float_6_opt_to_json x.f_ExecutionReport_EndCash) :: (("TradedFlatSwitch",tradedflatswitch_opt_to_json x.f_ExecutionReport_TradedFlatSwitch) :: (("BasisFeatureDate",localmktdate_opt_to_json x.f_ExecutionReport_BasisFeatureDate) :: (("BasisFeaturePrice",float_6_opt_to_json x.f_ExecutionReport_BasisFeaturePrice) :: (("Concession",float_6_opt_to_json x.f_ExecutionReport_Concession) :: (("TotalTakedown",float_6_opt_to_json x.f_ExecutionReport_TotalTakedown) :: (("NetMoney",float_6_opt_to_json x.f_ExecutionReport_NetMoney) :: (("SettlCurrAmt",float_6_opt_to_json x.f_ExecutionReport_SettlCurrAmt) :: (("SettlCurrency",currency_opt_to_json x.f_ExecutionReport_SettlCurrency) :: (("SettlCurrFxRate",float_opt_to_json x.f_ExecutionReport_SettlCurrFxRate) :: (("SettlCurrFxRateCalc",settlcurrfxratecalc_opt_to_json x.f_ExecutionReport_SettlCurrFxRateCalc) :: (("HandlInst",handlinst_opt_to_json x.f_ExecutionReport_HandlInst) :: (("MinQty",float_6_opt_to_json x.f_ExecutionReport_MinQty) :: (("MaxFloor",float_6_opt_to_json x.f_ExecutionReport_MaxFloor) :: (("PositionEffect",positioneffect_opt_to_json x.f_ExecutionReport_PositionEffect) :: (("MaxShow",float_6_opt_to_json x.f_ExecutionReport_MaxShow) :: (("BookingType",bookingtype_opt_to_json x.f_ExecutionReport_BookingType) :: (("Text",string_opt_to_json x.f_ExecutionReport_Text) :: (("EncodedTextLen",int_opt_to_json x.f_ExecutionReport_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_ExecutionReport_EncodedText) :: (("SettlDate2",localmktdate_opt_to_json x.f_ExecutionReport_SettlDate2) :: (("OrderQty2",float_6_opt_to_json x.f_ExecutionReport_OrderQty2) :: (("LastForwardPoints2",float_6_opt_to_json x.f_ExecutionReport_LastForwardPoints2) :: (("MultiLegReportingType",multilegreportingtype_opt_to_json x.f_ExecutionReport_MultiLegReportingType) :: (("CancellationRights",cancellationrights_opt_to_json x.f_ExecutionReport_CancellationRights) :: (("MoneyLaunderingStatus",moneylaunderingstatus_opt_to_json x.f_ExecutionReport_MoneyLaunderingStatus) :: (("RegistID",string_opt_to_json x.f_ExecutionReport_RegistID) :: (("Designation",string_opt_to_json x.f_ExecutionReport_Designation) :: (("TransBkdTime",utctimestamp_milli_opt_to_json x.f_ExecutionReport_TransBkdTime) :: (("ExecValuationPoint",utctimestamp_milli_opt_to_json x.f_ExecutionReport_ExecValuationPoint) :: (("ExecPriceType",execpricetype_opt_to_json x.f_ExecutionReport_ExecPriceType) :: (("ExecPriceAdjustment",float_opt_to_json x.f_ExecutionReport_ExecPriceAdjustment) :: (("PriorityIndicator",priorityindicator_opt_to_json x.f_ExecutionReport_PriorityIndicator) :: (("PriceImprovement",float_6_opt_to_json x.f_ExecutionReport_PriceImprovement) :: (("LastLiquidityInd",lastliquidityind_opt_to_json x.f_ExecutionReport_LastLiquidityInd) :: (("CopyMsgIndicator",bool_opt_to_json x.f_ExecutionReport_CopyMsgIndicator) :: (("Parties",rg_for_json parties_to_json x.f_ExecutionReport_Parties) :: (("ContraGrp",rg_for_json contragrp_to_json x.f_ExecutionReport_ContraGrp) :: (("UndInstrmtGrp",rg_for_json undinstrmtgrp_to_json x.f_ExecutionReport_UndInstrmtGrp) :: (("Stipulations",rg_for_json stipulations_to_json x.f_ExecutionReport_Stipulations) :: (("ContAmtGrp",rg_for_json contamtgrp_to_json x.f_ExecutionReport_ContAmtGrp) :: (("InstrmtLegExecGrp",rg_for_json instrmtlegexecgrp_to_json x.f_ExecutionReport_InstrmtLegExecGrp) :: (("MiscFeesGrp",rg_for_json miscfeesgrp_to_json x.f_ExecutionReport_MiscFeesGrp) :: [])))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) -;; let newordersingle_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_NewOrderSingle_Instrument) :: (("FinancingDetails",financingdetails_to_json x.f_NewOrderSingle_FinancingDetails) :: (("OrderQtyData",orderqtydata_to_json x.f_NewOrderSingle_OrderQtyData) :: (("SpreadOrBenchmarkCurveData",spreadorbenchmarkcurvedata_to_json x.f_NewOrderSingle_SpreadOrBenchmarkCurveData) :: (("YieldData",yielddata_to_json x.f_NewOrderSingle_YieldData) :: (("CommissionData",commissiondata_to_json x.f_NewOrderSingle_CommissionData) :: (("PegInstructions",peginstructions_to_json x.f_NewOrderSingle_PegInstructions) :: (("DiscretionInstructions",discretioninstructions_to_json x.f_NewOrderSingle_DiscretionInstructions) :: (("ClOrdID",string_opt_to_json x.f_NewOrderSingle_ClOrdID) :: (("SecondaryClOrdID",string_opt_to_json x.f_NewOrderSingle_SecondaryClOrdID) :: (("ClOrdLinkID",string_opt_to_json x.f_NewOrderSingle_ClOrdLinkID) :: (("TradeOriginationDate",localmktdate_opt_to_json x.f_NewOrderSingle_TradeOriginationDate) :: (("TradeDate",localmktdate_opt_to_json x.f_NewOrderSingle_TradeDate) :: (("Account",string_opt_to_json x.f_NewOrderSingle_Account) :: (("AcctIDSource",acctidsource_opt_to_json x.f_NewOrderSingle_AcctIDSource) :: (("AccountType",accounttype_opt_to_json x.f_NewOrderSingle_AccountType) :: (("DayBookingInst",daybookinginst_opt_to_json x.f_NewOrderSingle_DayBookingInst) :: (("BookingUnit",bookingunit_opt_to_json x.f_NewOrderSingle_BookingUnit) :: (("PreallocMethod",preallocmethod_opt_to_json x.f_NewOrderSingle_PreallocMethod) :: (("AllocID",string_opt_to_json x.f_NewOrderSingle_AllocID) :: (("SettlType",settltype_opt_to_json x.f_NewOrderSingle_SettlType) :: (("SettlDate",localmktdate_opt_to_json x.f_NewOrderSingle_SettlDate) :: (("CashMargin",cashmargin_opt_to_json x.f_NewOrderSingle_CashMargin) :: (("ClearingFeeIndicator",clearingfeeindicator_opt_to_json x.f_NewOrderSingle_ClearingFeeIndicator) :: (("HandlInst",handlinst_opt_to_json x.f_NewOrderSingle_HandlInst) :: (("ExecInst",execinst_opt_to_json x.f_NewOrderSingle_ExecInst) :: (("MinQty",float_6_opt_to_json x.f_NewOrderSingle_MinQty) :: (("MaxFloor",float_6_opt_to_json x.f_NewOrderSingle_MaxFloor) :: (("ExDestination",exchange_opt_to_json x.f_NewOrderSingle_ExDestination) :: (("ProcessCode",processcode_opt_to_json x.f_NewOrderSingle_ProcessCode) :: (("PrevClosePx",float_6_opt_to_json x.f_NewOrderSingle_PrevClosePx) :: (("Side",side_opt_to_json x.f_NewOrderSingle_Side) :: (("LocateReqd",locatereqd_opt_to_json x.f_NewOrderSingle_LocateReqd) :: (("TransactTime",utctimestamp_milli_opt_to_json x.f_NewOrderSingle_TransactTime) :: (("QtyType",qtytype_opt_to_json x.f_NewOrderSingle_QtyType) :: (("OrdType",ordtype_opt_to_json x.f_NewOrderSingle_OrdType) :: (("PriceType",pricetype_opt_to_json x.f_NewOrderSingle_PriceType) :: (("Price",float_6_opt_to_json x.f_NewOrderSingle_Price) :: (("StopPx",float_6_opt_to_json x.f_NewOrderSingle_StopPx) :: (("Currency",currency_opt_to_json x.f_NewOrderSingle_Currency) :: (("ComplianceID",string_opt_to_json x.f_NewOrderSingle_ComplianceID) :: (("SolicitedFlag",solicitedflag_opt_to_json x.f_NewOrderSingle_SolicitedFlag) :: (("IOIID",string_opt_to_json x.f_NewOrderSingle_IOIID) :: (("QuoteID",string_opt_to_json x.f_NewOrderSingle_QuoteID) :: (("TimeInForce",timeinforce_opt_to_json x.f_NewOrderSingle_TimeInForce) :: (("EffectiveTime",utctimestamp_milli_opt_to_json x.f_NewOrderSingle_EffectiveTime) :: (("ExpireDate",localmktdate_opt_to_json x.f_NewOrderSingle_ExpireDate) :: (("ExpireTime",utctimestamp_milli_opt_to_json x.f_NewOrderSingle_ExpireTime) :: (("GTBookingInst",gtbookinginst_opt_to_json x.f_NewOrderSingle_GTBookingInst) :: (("OrderCapacity",ordercapacity_opt_to_json x.f_NewOrderSingle_OrderCapacity) :: (("OrderRestrictions",orderrestrictions_opt_to_json x.f_NewOrderSingle_OrderRestrictions) :: (("CustOrderCapacity",custordercapacity_opt_to_json x.f_NewOrderSingle_CustOrderCapacity) :: (("ForexReq",forexreq_opt_to_json x.f_NewOrderSingle_ForexReq) :: (("SettlCurrency",currency_opt_to_json x.f_NewOrderSingle_SettlCurrency) :: (("BookingType",bookingtype_opt_to_json x.f_NewOrderSingle_BookingType) :: (("Text",string_opt_to_json x.f_NewOrderSingle_Text) :: (("EncodedTextLen",int_opt_to_json x.f_NewOrderSingle_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_NewOrderSingle_EncodedText) :: (("SettlDate2",localmktdate_opt_to_json x.f_NewOrderSingle_SettlDate2) :: (("OrderQty2",float_6_opt_to_json x.f_NewOrderSingle_OrderQty2) :: (("Price2",float_6_opt_to_json x.f_NewOrderSingle_Price2) :: (("PositionEffect",positioneffect_opt_to_json x.f_NewOrderSingle_PositionEffect) :: (("CoveredOrUncovered",coveredoruncovered_opt_to_json x.f_NewOrderSingle_CoveredOrUncovered) :: (("MaxShow",float_6_opt_to_json x.f_NewOrderSingle_MaxShow) :: (("TargetStrategy",targetstrategy_opt_to_json x.f_NewOrderSingle_TargetStrategy) :: (("TargetStrategyParameters",string_opt_to_json x.f_NewOrderSingle_TargetStrategyParameters) :: (("ParticipationRate",float_6_opt_to_json x.f_NewOrderSingle_ParticipationRate) :: (("CancellationRights",cancellationrights_opt_to_json x.f_NewOrderSingle_CancellationRights) :: (("MoneyLaunderingStatus",moneylaunderingstatus_opt_to_json x.f_NewOrderSingle_MoneyLaunderingStatus) :: (("RegistID",string_opt_to_json x.f_NewOrderSingle_RegistID) :: (("Designation",string_opt_to_json x.f_NewOrderSingle_Designation) :: (("Parties",rg_for_json parties_to_json x.f_NewOrderSingle_Parties) :: (("PreAllocGrp",rg_for_json preallocgrp_to_json x.f_NewOrderSingle_PreAllocGrp) :: (("TrdgSesGrp",rg_for_json trdgsesgrp_to_json x.f_NewOrderSingle_TrdgSesGrp) :: (("UndInstrmtGrp",rg_for_json undinstrmtgrp_to_json x.f_NewOrderSingle_UndInstrmtGrp) :: (("Stipulations",rg_for_json stipulations_to_json x.f_NewOrderSingle_Stipulations) :: [])))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) + assoc_filter_nulls ([(("OrderQtyData",orderqtydata_to_json x.f_NewOrderSingle_OrderQtyData));(("ClOrdID",string_opt_to_json x.f_NewOrderSingle_ClOrdID));(("Account",string_opt_to_json x.f_NewOrderSingle_Account));(("ExecInst",execinst_opt_to_json x.f_NewOrderSingle_ExecInst));(("Side",side_opt_to_json x.f_NewOrderSingle_Side));(("TransactTime",utctimestamp_milli_opt_to_json x.f_NewOrderSingle_TransactTime));(("OrdType",ordtype_opt_to_json x.f_NewOrderSingle_OrdType));(("Price",float_2_opt_to_json x.f_NewOrderSingle_Price));(("SpreadProportion",float_opt_to_json x.f_NewOrderSingle_SpreadProportion));(("Parties",rg_for_json parties_to_json x.f_NewOrderSingle_Parties))]) +;; + +let executionreport_to_json (x) : json = + assoc_filter_nulls ([(("OrderQtyData",orderqtydata_to_json x.f_ExecutionReport_OrderQtyData)); + (("OrderID",string_opt_to_json x.f_ExecutionReport_OrderID)); + (("ExecID",string_opt_to_json x.f_ExecutionReport_ExecID)); + (("ExecType",exectype_opt_to_json x.f_ExecutionReport_ExecType)); + (("OrdStatus",ordstatus_opt_to_json x.f_ExecutionReport_OrdStatus)); + (("Side",side_opt_to_json x.f_ExecutionReport_Side)); + (("ExecInst",execinst_opt_to_json x.f_ExecutionReport_ExecInst)); + (("LeavesQty",float_6_opt_to_json x.f_ExecutionReport_LeavesQty)); + (("CumQty",float_6_opt_to_json x.f_ExecutionReport_CumQty)); + (("Text",string_opt_to_json x.f_ExecutionReport_Text)); + (("Parties",rg_for_json parties_to_json x.f_ExecutionReport_Parties))]) ;; let full_app_msg_to_json (x) : json = (match x with - | FIX_Full_Msg_ExecutionReport x -> (`Assoc (("ExecutionReport",executionreport_to_json x) :: [])) - | FIX_Full_Msg_NewOrderSingle x -> (`Assoc (("NewOrderSingle",newordersingle_to_json x) :: [])) + | FIX_Full_Msg_NewOrderSingle x -> (`Assoc ([(("NewOrderSingle",newordersingle_to_json x))])) + | FIX_Full_Msg_ExecutionReport x -> (`Assoc ([(("ExecutionReport",executionreport_to_json x))])) ) ;; + [@@@logic] diff --git a/src-protocol-exts-pp/full_app_records_decoder.iml b/src-protocol-exts-pp/full_app_records_decoder.iml index 10f646ca..ee09f160 100644 --- a/src-protocol-exts-pp/full_app_records_decoder.iml +++ b/src-protocol-exts-pp/full_app_records_decoder.iml @@ -1,5 +1,52 @@ (* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-core-pp/base_types_json.iml"] +open Base_types_json;; +[@@@import "../src-core-pp/datetime_json.iml"] +open Datetime_json;; +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode;; +[@@@require "decoders-yojson"] +open Decoders_yojson.Basic.Decode.Infix;; +[@@@import "../src-protocol-exts/full_app_records.iml"] +open Full_app_records;; +let full_record_orderqtydata_decoder : fix_orderqtydata decoder = + (maybe (field "OrderQty" float_6_decoder)) >>= (fun f_OrderQtyData_OrderQty -> succeed { + f_OrderQtyData_OrderQty = f_OrderQtyData_OrderQty + } + ) +;; + +let full_rg_inner_PtysSubGrp_decoder : fix_rg_inner_ptyssubgrp decoder = + (maybe (field "PartySubID" string_decoder)) >>= (fun f_PtysSubGrp_PartySubID -> (maybe (field "NoPartySubIDs" int_decoder)) >>= (fun f_PtysSubGrp_NoPartySubIDs -> succeed { + f_PtysSubGrp_NoPartySubIDs = f_PtysSubGrp_NoPartySubIDs; + f_PtysSubGrp_PartySubID = f_PtysSubGrp_PartySubID + } + ) + ) +;; + +let full_rg_ptyssubgrp_decoder : fix_rg_ptyssubgrp decoder = + list full_rg_inner_PtysSubGrp_decoder +;; + +let full_rg_inner_Parties_decoder : fix_rg_inner_parties decoder = + (maybe (field "PartyIndex" int_decoder)) >>= (fun f_Parties_PartyIndex -> (field "PtysSubGrp" full_rg_ptyssubgrp_decoder) >>= (fun f_Parties_PtysSubGrp -> (maybe (field "PartyID" string_decoder)) >>= (fun f_Parties_PartyID -> (maybe (field "NoPartyIDs" int_decoder)) >>= (fun f_Parties_NoPartyIDs -> succeed { + f_Parties_NoPartyIDs = f_Parties_NoPartyIDs; + f_Parties_PartyID = f_Parties_PartyID; + f_Parties_PtysSubGrp = f_Parties_PtysSubGrp; + f_Parties_PartyIndex = f_Parties_PartyIndex + } + ) + ) + ) + ) +;; + +let full_rg_parties_decoder : fix_rg_parties decoder = + list full_rg_inner_Parties_decoder +;; + [@@@logic] diff --git a/src-protocol-exts-pp/full_app_records_json.iml b/src-protocol-exts-pp/full_app_records_json.iml index 5f147744..948de544 100644 --- a/src-protocol-exts-pp/full_app_records_json.iml +++ b/src-protocol-exts-pp/full_app_records_json.iml @@ -1,854 +1,39 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "../src-core-pp/base_types_json.iml"] -[@@@import "../src-core-pp/datetime_json.iml"] -[@@@import "full_app_enums_json.iml"] -[@@@import "../src-protocol-exts/full_app_records.iml"] -[@@@import "json_generator_utils.iml"] +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-core-pp/base_types_json.iml"] open Base_types_json;; +[@@@import "../src-core-pp/datetime_json.iml"] open Datetime_json;; -open Full_app_enums_json;; +[@@@import "../src-protocol-exts/full_app_records.iml"] open Full_app_records;; +[@@@import "json_generator_utils.iml"] open Json_generator_utils;; +[@@@require "yojson"] open Yojson.Basic;; -let logonmsgtypes_to_string (d) = - "" -;; - -let logonmsgtypes_to_json (x) : json = - assoc_filter_nulls (("NoMsgTypes",int_opt_to_json x.f_LogonMsgTypes_NoMsgTypes) :: (("RefMsgType",string_opt_to_json x.f_LogonMsgTypes_RefMsgType) :: (("MsgDirection",msgdirection_opt_to_json x.f_LogonMsgTypes_MsgDirection) :: []))) -;; - -let mdreqgrp_to_string (d) = - "" -;; - -let mdreqgrp_to_json (x) : json = - assoc_filter_nulls (("NoMDEntryTypes",int_opt_to_json x.f_MDReqGrp_NoMDEntryTypes) :: (("MDEntryType",mdentrytype_opt_to_json x.f_MDReqGrp_MDEntryType) :: [])) -;; - -let underlyingstipulations_to_string (d) = - "" -;; - -let underlyingstipulations_to_json (x) : json = - assoc_filter_nulls (("NoUnderlyingStips",int_opt_to_json x.f_UnderlyingStipulations_NoUnderlyingStips) :: (("UnderlyingStipType",string_opt_to_json x.f_UnderlyingStipulations_UnderlyingStipType) :: (("UnderlyingStipValue",string_opt_to_json x.f_UnderlyingStipulations_UnderlyingStipValue) :: []))) -;; - -let evntgrp_to_string (d) = - "" -;; - -let evntgrp_to_json (x) : json = - assoc_filter_nulls (("NoEvents",int_opt_to_json x.f_EvntGrp_NoEvents) :: (("EventType",eventtype_opt_to_json x.f_EvntGrp_EventType) :: (("EventDate",localmktdate_opt_to_json x.f_EvntGrp_EventDate) :: (("EventPx",float_6_opt_to_json x.f_EvntGrp_EventPx) :: (("EventText",string_opt_to_json x.f_EvntGrp_EventText) :: []))))) -;; - -let mdfullgrp_to_string (d) = - "" -;; - -let mdfullgrp_to_json (x) : json = - assoc_filter_nulls (("NoMDEntries",int_opt_to_json x.f_MDFullGrp_NoMDEntries) :: (("MDEntryType",mdentrytype_opt_to_json x.f_MDFullGrp_MDEntryType) :: (("MDEntryPx",float_6_opt_to_json x.f_MDFullGrp_MDEntryPx) :: (("Currency",currency_opt_to_json x.f_MDFullGrp_Currency) :: (("MDEntrySize",float_6_opt_to_json x.f_MDFullGrp_MDEntrySize) :: (("MDEntryDate",utcdateonly_opt_to_json x.f_MDFullGrp_MDEntryDate) :: (("MDEntryTime",utctimeonly_milli_opt_to_json x.f_MDFullGrp_MDEntryTime) :: (("TickDirection",tickdirection_opt_to_json x.f_MDFullGrp_TickDirection) :: (("MDMkt",exchange_opt_to_json x.f_MDFullGrp_MDMkt) :: (("TradingSessionID",string_opt_to_json x.f_MDFullGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_MDFullGrp_TradingSessionSubID) :: (("QuoteCondition",quotecondition_opt_to_json x.f_MDFullGrp_QuoteCondition) :: (("TradeCondition",tradecondition_opt_to_json x.f_MDFullGrp_TradeCondition) :: (("MDEntryOriginator",string_opt_to_json x.f_MDFullGrp_MDEntryOriginator) :: (("LocationID",string_opt_to_json x.f_MDFullGrp_LocationID) :: (("DeskID",string_opt_to_json x.f_MDFullGrp_DeskID) :: (("OpenCloseSettlFlag",openclosesettlflag_opt_to_json x.f_MDFullGrp_OpenCloseSettlFlag) :: (("TimeInForce",timeinforce_opt_to_json x.f_MDFullGrp_TimeInForce) :: (("ExpireDate",localmktdate_opt_to_json x.f_MDFullGrp_ExpireDate) :: (("ExpireTime",utctimestamp_milli_opt_to_json x.f_MDFullGrp_ExpireTime) :: (("MinQty",float_6_opt_to_json x.f_MDFullGrp_MinQty) :: (("ExecInst",execinst_opt_to_json x.f_MDFullGrp_ExecInst) :: (("SellerDays",int_opt_to_json x.f_MDFullGrp_SellerDays) :: (("OrderID",string_opt_to_json x.f_MDFullGrp_OrderID) :: (("QuoteEntryID",string_opt_to_json x.f_MDFullGrp_QuoteEntryID) :: (("MDEntryBuyer",string_opt_to_json x.f_MDFullGrp_MDEntryBuyer) :: (("MDEntrySeller",string_opt_to_json x.f_MDFullGrp_MDEntrySeller) :: (("NumberOfOrders",int_opt_to_json x.f_MDFullGrp_NumberOfOrders) :: (("MDEntryPositionNo",int_opt_to_json x.f_MDFullGrp_MDEntryPositionNo) :: (("Scope",scope_opt_to_json x.f_MDFullGrp_Scope) :: (("PriceDelta",float_opt_to_json x.f_MDFullGrp_PriceDelta) :: (("Text",string_opt_to_json x.f_MDFullGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_MDFullGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_MDFullGrp_EncodedText) :: [])))))))))))))))))))))))))))))))))) -;; - -let undsecaltidgrp_to_string (d) = - "" -;; - -let undsecaltidgrp_to_json (x) : json = - assoc_filter_nulls (("NoUnderlyingSecurityAltID",int_opt_to_json x.f_UndSecAltIDGrp_NoUnderlyingSecurityAltID) :: (("UnderlyingSecurityAltID",string_opt_to_json x.f_UndSecAltIDGrp_UnderlyingSecurityAltID) :: (("UnderlyingSecurityAltIDSource",string_opt_to_json x.f_UndSecAltIDGrp_UnderlyingSecurityAltIDSource) :: []))) -;; - -let linesoftextgrp_to_string (d) = - "" -;; - -let linesoftextgrp_to_json (x) : json = - assoc_filter_nulls (("NoLinesOfText",int_opt_to_json x.f_LinesOfTextGrp_NoLinesOfText) :: (("Text",string_opt_to_json x.f_LinesOfTextGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_LinesOfTextGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_LinesOfTextGrp_EncodedText) :: [])))) -;; - -let legsecaltidgrp_to_string (d) = - "" -;; - -let legsecaltidgrp_to_json (x) : json = - assoc_filter_nulls (("NoLegSecurityAltID",int_opt_to_json x.f_LegSecAltIDGrp_NoLegSecurityAltID) :: (("LegSecurityAltID",string_opt_to_json x.f_LegSecAltIDGrp_LegSecurityAltID) :: (("LegSecurityAltIDSource",string_opt_to_json x.f_LegSecAltIDGrp_LegSecurityAltIDSource) :: []))) -;; - -let spreadorbenchmarkcurvedata_to_string (d) = - "" -;; - -let spreadorbenchmarkcurvedata_to_json (x) : json = - assoc_filter_nulls (("Spread",float_6_opt_to_json x.f_SpreadOrBenchmarkCurveData_Spread) :: (("BenchmarkCurveCurrency",currency_opt_to_json x.f_SpreadOrBenchmarkCurveData_BenchmarkCurveCurrency) :: (("BenchmarkCurveName",string_opt_to_json x.f_SpreadOrBenchmarkCurveData_BenchmarkCurveName) :: (("BenchmarkCurvePoint",string_opt_to_json x.f_SpreadOrBenchmarkCurveData_BenchmarkCurvePoint) :: (("BenchmarkPrice",float_6_opt_to_json x.f_SpreadOrBenchmarkCurveData_BenchmarkPrice) :: (("BenchmarkPriceType",int_opt_to_json x.f_SpreadOrBenchmarkCurveData_BenchmarkPriceType) :: (("BenchmarkSecurityID",string_opt_to_json x.f_SpreadOrBenchmarkCurveData_BenchmarkSecurityID) :: (("BenchmarkSecurityIDSource",string_opt_to_json x.f_SpreadOrBenchmarkCurveData_BenchmarkSecurityIDSource) :: [])))))))) -;; - -let miscfeesgrp_to_string (d) = - "" -;; - -let miscfeesgrp_to_json (x) : json = - assoc_filter_nulls (("NoMiscFees",int_opt_to_json x.f_MiscFeesGrp_NoMiscFees) :: (("MiscFeeAmt",float_6_opt_to_json x.f_MiscFeesGrp_MiscFeeAmt) :: (("MiscFeeCurr",currency_opt_to_json x.f_MiscFeesGrp_MiscFeeCurr) :: (("MiscFeeType",miscfeetype_opt_to_json x.f_MiscFeesGrp_MiscFeeType) :: (("MiscFeeBasis",miscfeebasis_opt_to_json x.f_MiscFeesGrp_MiscFeeBasis) :: []))))) -;; - -let trdgsesgrp_to_string (d) = - "" -;; - -let trdgsesgrp_to_json (x) : json = - assoc_filter_nulls (("NoTradingSessions",int_opt_to_json x.f_TrdgSesGrp_NoTradingSessions) :: (("TradingSessionID",string_opt_to_json x.f_TrdgSesGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_TrdgSesGrp_TradingSessionSubID) :: []))) -;; - -let contragrp_to_string (d) = - "" -;; - -let contragrp_to_json (x) : json = - assoc_filter_nulls (("NoContraBrokers",int_opt_to_json x.f_ContraGrp_NoContraBrokers) :: (("ContraBroker",string_opt_to_json x.f_ContraGrp_ContraBroker) :: (("ContraTrader",string_opt_to_json x.f_ContraGrp_ContraTrader) :: (("ContraTradeQty",float_6_opt_to_json x.f_ContraGrp_ContraTradeQty) :: (("ContraTradeTime",utctimestamp_milli_opt_to_json x.f_ContraGrp_ContraTradeTime) :: (("ContraLegRefID",string_opt_to_json x.f_ContraGrp_ContraLegRefID) :: [])))))) -;; - -let bidcompreqgrp_to_string (d) = - "" -;; - -let bidcompreqgrp_to_json (x) : json = - assoc_filter_nulls (("NoBidComponents",int_opt_to_json x.f_BidCompReqGrp_NoBidComponents) :: (("ListID",string_opt_to_json x.f_BidCompReqGrp_ListID) :: (("Side",side_opt_to_json x.f_BidCompReqGrp_Side) :: (("TradingSessionID",string_opt_to_json x.f_BidCompReqGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_BidCompReqGrp_TradingSessionSubID) :: (("NetGrossInd",netgrossind_opt_to_json x.f_BidCompReqGrp_NetGrossInd) :: (("SettlType",settltype_opt_to_json x.f_BidCompReqGrp_SettlType) :: (("SettlDate",localmktdate_opt_to_json x.f_BidCompReqGrp_SettlDate) :: (("Account",string_opt_to_json x.f_BidCompReqGrp_Account) :: (("AcctIDSource",acctidsource_opt_to_json x.f_BidCompReqGrp_AcctIDSource) :: [])))))))))) -;; - -let contamtgrp_to_string (d) = - "" -;; - -let contamtgrp_to_json (x) : json = - assoc_filter_nulls (("NoContAmts",int_opt_to_json x.f_ContAmtGrp_NoContAmts) :: (("ContAmtType",contamttype_opt_to_json x.f_ContAmtGrp_ContAmtType) :: (("ContAmtValue",float_opt_to_json x.f_ContAmtGrp_ContAmtValue) :: (("ContAmtCurr",currency_opt_to_json x.f_ContAmtGrp_ContAmtCurr) :: [])))) -;; - -let collinqqualgrp_to_string (d) = - "" -;; - -let collinqqualgrp_to_json (x) : json = - assoc_filter_nulls (("NoCollInquiryQualifier",int_opt_to_json x.f_CollInqQualGrp_NoCollInquiryQualifier) :: (("CollInquiryQualifier",collinquiryqualifier_opt_to_json x.f_CollInqQualGrp_CollInquiryQualifier) :: [])) -;; - -let execsgrp_to_string (d) = - "" -;; - -let execsgrp_to_json (x) : json = - assoc_filter_nulls (("NoExecs",int_opt_to_json x.f_ExecsGrp_NoExecs) :: (("ExecID",string_opt_to_json x.f_ExecsGrp_ExecID) :: [])) -;; - -let allocackgrp_to_string (d) = - "" -;; - -let allocackgrp_to_json (x) : json = - assoc_filter_nulls (("NoAllocs",int_opt_to_json x.f_AllocAckGrp_NoAllocs) :: (("AllocAccount",string_opt_to_json x.f_AllocAckGrp_AllocAccount) :: (("AllocAcctIDSource",int_opt_to_json x.f_AllocAckGrp_AllocAcctIDSource) :: (("AllocPrice",float_6_opt_to_json x.f_AllocAckGrp_AllocPrice) :: (("IndividualAllocID",string_opt_to_json x.f_AllocAckGrp_IndividualAllocID) :: (("IndividualAllocRejCode",int_opt_to_json x.f_AllocAckGrp_IndividualAllocRejCode) :: (("AllocText",string_opt_to_json x.f_AllocAckGrp_AllocText) :: (("EncodedAllocTextLen",int_opt_to_json x.f_AllocAckGrp_EncodedAllocTextLen) :: (("EncodedAllocText",string_opt_to_json x.f_AllocAckGrp_EncodedAllocText) :: []))))))))) -;; - -let discretioninstructions_to_string (d) = - "" -;; - -let discretioninstructions_to_json (x) : json = - assoc_filter_nulls (("DiscretionInst",discretioninst_opt_to_json x.f_DiscretionInstructions_DiscretionInst) :: (("DiscretionOffsetValue",float_opt_to_json x.f_DiscretionInstructions_DiscretionOffsetValue) :: (("DiscretionMoveType",discretionmovetype_opt_to_json x.f_DiscretionInstructions_DiscretionMoveType) :: (("DiscretionOffsetType",discretionoffsettype_opt_to_json x.f_DiscretionInstructions_DiscretionOffsetType) :: (("DiscretionLimitType",discretionlimittype_opt_to_json x.f_DiscretionInstructions_DiscretionLimitType) :: (("DiscretionRoundDirection",discretionrounddirection_opt_to_json x.f_DiscretionInstructions_DiscretionRoundDirection) :: (("DiscretionScope",discretionscope_opt_to_json x.f_DiscretionInstructions_DiscretionScope) :: []))))))) -;; - -let positionamountdata_to_string (d) = - "" -;; - -let positionamountdata_to_json (x) : json = - assoc_filter_nulls (("NoPosAmt",int_opt_to_json x.f_PositionAmountData_NoPosAmt) :: (("PosAmtType",posamttype_opt_to_json x.f_PositionAmountData_PosAmtType) :: (("PosAmt",float_6_opt_to_json x.f_PositionAmountData_PosAmt) :: []))) -;; - -let mdrjctgrp_to_string (d) = - "" -;; - -let mdrjctgrp_to_json (x) : json = - assoc_filter_nulls (("NoAltMDSource",int_opt_to_json x.f_MDRjctGrp_NoAltMDSource) :: (("AltMDSourceID",string_opt_to_json x.f_MDRjctGrp_AltMDSourceID) :: [])) -;; - -let attrbgrp_to_string (d) = - "" -;; - -let attrbgrp_to_json (x) : json = - assoc_filter_nulls (("NoInstrAttrib",int_opt_to_json x.f_AttrbGrp_NoInstrAttrib) :: (("InstrAttribType",instrattribtype_opt_to_json x.f_AttrbGrp_InstrAttribType) :: (("InstrAttribValue",string_opt_to_json x.f_AttrbGrp_InstrAttribValue) :: []))) -;; - -let trdregtimestamps_to_string (d) = - "" -;; - -let trdregtimestamps_to_json (x) : json = - assoc_filter_nulls (("NoTrdRegTimestamps",int_opt_to_json x.f_TrdRegTimestamps_NoTrdRegTimestamps) :: (("TrdRegTimestamp",utctimestamp_milli_opt_to_json x.f_TrdRegTimestamps_TrdRegTimestamp) :: (("TrdRegTimestampType",trdregtimestamptype_opt_to_json x.f_TrdRegTimestamps_TrdRegTimestampType) :: (("TrdRegTimestampOrigin",string_opt_to_json x.f_TrdRegTimestamps_TrdRegTimestampOrigin) :: [])))) -;; - -let routinggrp_to_string (d) = - "" -;; - -let routinggrp_to_json (x) : json = - assoc_filter_nulls (("NoRoutingIDs",int_opt_to_json x.f_RoutingGrp_NoRoutingIDs) :: (("RoutingType",routingtype_opt_to_json x.f_RoutingGrp_RoutingType) :: (("RoutingID",string_opt_to_json x.f_RoutingGrp_RoutingID) :: []))) -;; - -let cpctyconfgrp_to_string (d) = - "" -;; - -let cpctyconfgrp_to_json (x) : json = - assoc_filter_nulls (("NoCapacities",int_opt_to_json x.f_CpctyConfGrp_NoCapacities) :: (("OrderCapacity",ordercapacity_opt_to_json x.f_CpctyConfGrp_OrderCapacity) :: (("OrderRestrictions",orderrestrictions_opt_to_json x.f_CpctyConfGrp_OrderRestrictions) :: (("OrderCapacityQty",float_6_opt_to_json x.f_CpctyConfGrp_OrderCapacityQty) :: [])))) -;; - -let yielddata_to_string (d) = - "" -;; - -let yielddata_to_json (x) : json = - assoc_filter_nulls (("YieldType",yieldtype_opt_to_json x.f_YieldData_YieldType) :: (("Yield",float_6_opt_to_json x.f_YieldData_Yield) :: (("YieldCalcDate",localmktdate_opt_to_json x.f_YieldData_YieldCalcDate) :: (("YieldRedemptionDate",localmktdate_opt_to_json x.f_YieldData_YieldRedemptionDate) :: (("YieldRedemptionPrice",float_6_opt_to_json x.f_YieldData_YieldRedemptionPrice) :: (("YieldRedemptionPriceType",int_opt_to_json x.f_YieldData_YieldRedemptionPriceType) :: [])))))) -;; - -let compidstatgrp_to_string (d) = - "" -;; - -let compidstatgrp_to_json (x) : json = - assoc_filter_nulls (("NoCompIDs",int_opt_to_json x.f_CompIDStatGrp_NoCompIDs) :: (("RefCompID",string_opt_to_json x.f_CompIDStatGrp_RefCompID) :: (("RefSubID",string_opt_to_json x.f_CompIDStatGrp_RefSubID) :: (("LocationID",string_opt_to_json x.f_CompIDStatGrp_LocationID) :: (("DeskID",string_opt_to_json x.f_CompIDStatGrp_DeskID) :: (("StatusValue",statusvalue_opt_to_json x.f_CompIDStatGrp_StatusValue) :: (("StatusText",string_opt_to_json x.f_CompIDStatGrp_StatusText) :: []))))))) -;; - -let nstdptys3subgrp_to_string (d) = - "" -;; - -let nstdptys3subgrp_to_json (x) : json = - assoc_filter_nulls (("NoNested3PartySubIDs",int_opt_to_json x.f_NstdPtys3SubGrp_NoNested3PartySubIDs) :: (("Nested3PartySubID",string_opt_to_json x.f_NstdPtys3SubGrp_Nested3PartySubID) :: (("Nested3PartySubIDType",int_opt_to_json x.f_NstdPtys3SubGrp_Nested3PartySubIDType) :: []))) -;; - -let clrinstgrp_to_string (d) = - "" -;; - -let clrinstgrp_to_json (x) : json = - assoc_filter_nulls (("NoClearingInstructions",int_opt_to_json x.f_ClrInstGrp_NoClearingInstructions) :: (("ClearingInstruction",clearinginstruction_opt_to_json x.f_ClrInstGrp_ClearingInstruction) :: [])) -;; - -let nstdptys2subgrp_to_string (d) = - "" -;; - -let nstdptys2subgrp_to_json (x) : json = - assoc_filter_nulls (("NoNested2PartySubIDs",int_opt_to_json x.f_NstdPtys2SubGrp_NoNested2PartySubIDs) :: (("Nested2PartySubID",string_opt_to_json x.f_NstdPtys2SubGrp_Nested2PartySubID) :: (("Nested2PartySubIDType",int_opt_to_json x.f_NstdPtys2SubGrp_Nested2PartySubIDType) :: []))) -;; - -let affectedordgrp_to_string (d) = - "" -;; - -let affectedordgrp_to_json (x) : json = - assoc_filter_nulls (("NoAffectedOrders",int_opt_to_json x.f_AffectedOrdGrp_NoAffectedOrders) :: (("OrigClOrdID",string_opt_to_json x.f_AffectedOrdGrp_OrigClOrdID) :: (("AffectedOrderID",string_opt_to_json x.f_AffectedOrdGrp_AffectedOrderID) :: (("AffectedSecondaryOrderID",string_opt_to_json x.f_AffectedOrdGrp_AffectedSecondaryOrderID) :: [])))) -;; - -let financingdetails_to_string (d) = - "" -;; -let financingdetails_to_json (x) : json = - assoc_filter_nulls (("AgreementDesc",string_opt_to_json x.f_FinancingDetails_AgreementDesc) :: (("AgreementID",string_opt_to_json x.f_FinancingDetails_AgreementID) :: (("AgreementDate",localmktdate_opt_to_json x.f_FinancingDetails_AgreementDate) :: (("AgreementCurrency",currency_opt_to_json x.f_FinancingDetails_AgreementCurrency) :: (("TerminationType",terminationtype_opt_to_json x.f_FinancingDetails_TerminationType) :: (("StartDate",localmktdate_opt_to_json x.f_FinancingDetails_StartDate) :: (("EndDate",localmktdate_opt_to_json x.f_FinancingDetails_EndDate) :: (("DeliveryType",deliverytype_opt_to_json x.f_FinancingDetails_DeliveryType) :: (("MarginRatio",float_6_opt_to_json x.f_FinancingDetails_MarginRatio) :: []))))))))) -;; - -let trdcapdtgrp_to_string (d) = - "" -;; - -let trdcapdtgrp_to_json (x) : json = - assoc_filter_nulls (("NoDates",int_opt_to_json x.f_TrdCapDtGrp_NoDates) :: (("TradeDate",localmktdate_opt_to_json x.f_TrdCapDtGrp_TradeDate) :: (("TransactTime",utctimestamp_milli_opt_to_json x.f_TrdCapDtGrp_TransactTime) :: []))) -;; - -let orderqtydata_to_string (d) = +let orderqtydata_to_string (_d) = "" ;; let orderqtydata_to_json (x) : json = - assoc_filter_nulls (("OrderQty",float_6_opt_to_json x.f_OrderQtyData_OrderQty) :: (("CashOrderQty",float_6_opt_to_json x.f_OrderQtyData_CashOrderQty) :: (("OrderPercent",float_6_opt_to_json x.f_OrderQtyData_OrderPercent) :: (("RoundingDirection",roundingdirection_opt_to_json x.f_OrderQtyData_RoundingDirection) :: (("RoundingModulus",float_opt_to_json x.f_OrderQtyData_RoundingModulus) :: []))))) -;; - -let trdcollgrp_to_string (d) = - "" -;; - -let trdcollgrp_to_json (x) : json = - assoc_filter_nulls (("NoTrades",int_opt_to_json x.f_TrdCollGrp_NoTrades) :: (("TradeReportID",string_opt_to_json x.f_TrdCollGrp_TradeReportID) :: (("SecondaryTradeReportID",string_opt_to_json x.f_TrdCollGrp_SecondaryTradeReportID) :: []))) -;; - -let peginstructions_to_string (d) = - "" -;; - -let peginstructions_to_json (x) : json = - assoc_filter_nulls (("PegOffsetValue",float_opt_to_json x.f_PegInstructions_PegOffsetValue) :: (("PegMoveType",pegmovetype_opt_to_json x.f_PegInstructions_PegMoveType) :: (("PegOffsetType",pegoffsettype_opt_to_json x.f_PegInstructions_PegOffsetType) :: (("PegLimitType",peglimittype_opt_to_json x.f_PegInstructions_PegLimitType) :: (("PegRoundDirection",pegrounddirection_opt_to_json x.f_PegInstructions_PegRoundDirection) :: (("PegScope",pegscope_opt_to_json x.f_PegInstructions_PegScope) :: [])))))) -;; - -let interval_to_string (d) = - "" -;; - -let interval_to_json (x) : json = - assoc_filter_nulls (("start_time",utctimestamp_milli_opt_to_json x.f_interval_start_time) :: (("duration",duration_opt_to_json x.f_interval_duration) :: [])) -;; - -let rgstdistinstgrp_to_string (d) = - "" -;; - -let rgstdistinstgrp_to_json (x) : json = - assoc_filter_nulls (("NoDistribInsts",int_opt_to_json x.f_RgstDistInstGrp_NoDistribInsts) :: (("DistribPaymentMethod",distribpaymentmethod_opt_to_json x.f_RgstDistInstGrp_DistribPaymentMethod) :: (("DistribPercentage",float_6_opt_to_json x.f_RgstDistInstGrp_DistribPercentage) :: (("CashDistribCurr",currency_opt_to_json x.f_RgstDistInstGrp_CashDistribCurr) :: (("CashDistribAgentName",string_opt_to_json x.f_RgstDistInstGrp_CashDistribAgentName) :: (("CashDistribAgentCode",string_opt_to_json x.f_RgstDistInstGrp_CashDistribAgentCode) :: (("CashDistribAgentAcctNumber",string_opt_to_json x.f_RgstDistInstGrp_CashDistribAgentAcctNumber) :: (("CashDistribPayRef",string_opt_to_json x.f_RgstDistInstGrp_CashDistribPayRef) :: (("CashDistribAgentAcctName",string_opt_to_json x.f_RgstDistInstGrp_CashDistribAgentAcctName) :: []))))))))) -;; - -let execcollgrp_to_string (d) = - "" -;; - -let execcollgrp_to_json (x) : json = - assoc_filter_nulls (("NoExecs",int_opt_to_json x.f_ExecCollGrp_NoExecs) :: (("ExecID",string_opt_to_json x.f_ExecCollGrp_ExecID) :: [])) + assoc_filter_nulls ([(("OrderQty",float_6_opt_to_json x.f_OrderQtyData_OrderQty))]) ;; -let compidreqgrp_to_string (d) = - "" -;; - -let compidreqgrp_to_json (x) : json = - assoc_filter_nulls (("NoCompIDs",int_opt_to_json x.f_CompIDReqGrp_NoCompIDs) :: (("RefCompID",string_opt_to_json x.f_CompIDReqGrp_RefCompID) :: (("RefSubID",string_opt_to_json x.f_CompIDReqGrp_RefSubID) :: (("LocationID",string_opt_to_json x.f_CompIDReqGrp_LocationID) :: (("DeskID",string_opt_to_json x.f_CompIDReqGrp_DeskID) :: []))))) -;; - -let nstdptyssubgrp_to_string (d) = - "" -;; - -let nstdptyssubgrp_to_json (x) : json = - assoc_filter_nulls (("NoNestedPartySubIDs",int_opt_to_json x.f_NstdPtysSubGrp_NoNestedPartySubIDs) :: (("NestedPartySubID",string_opt_to_json x.f_NstdPtysSubGrp_NestedPartySubID) :: (("NestedPartySubIDType",int_opt_to_json x.f_NstdPtysSubGrp_NestedPartySubIDType) :: []))) -;; - -let stipulations_to_string (d) = - "" -;; - -let stipulations_to_json (x) : json = - assoc_filter_nulls (("NoStipulations",int_opt_to_json x.f_Stipulations_NoStipulations) :: (("StipulationType",stipulationtype_opt_to_json x.f_Stipulations_StipulationType) :: (("StipulationValue",string_opt_to_json x.f_Stipulations_StipulationValue) :: []))) -;; - -let ioiqualgrp_to_string (d) = - "" -;; - -let ioiqualgrp_to_json (x) : json = - assoc_filter_nulls (("NoIOIQualifiers",int_opt_to_json x.f_IOIQualGrp_NoIOIQualifiers) :: (("IOIQualifier",ioiqualifier_opt_to_json x.f_IOIQualGrp_IOIQualifier) :: [])) -;; - -let legbenchmarkcurvedata_to_string (d) = - "" -;; - -let legbenchmarkcurvedata_to_json (x) : json = - assoc_filter_nulls (("LegBenchmarkCurveCurrency",currency_opt_to_json x.f_LegBenchmarkCurveData_LegBenchmarkCurveCurrency) :: (("LegBenchmarkCurveName",string_opt_to_json x.f_LegBenchmarkCurveData_LegBenchmarkCurveName) :: (("LegBenchmarkCurvePoint",string_opt_to_json x.f_LegBenchmarkCurveData_LegBenchmarkCurvePoint) :: (("LegBenchmarkPrice",float_6_opt_to_json x.f_LegBenchmarkCurveData_LegBenchmarkPrice) :: (("LegBenchmarkPriceType",int_opt_to_json x.f_LegBenchmarkCurveData_LegBenchmarkPriceType) :: []))))) -;; - -let execallocgrp_to_string (d) = - "" -;; - -let execallocgrp_to_json (x) : json = - assoc_filter_nulls (("NoExecs",int_opt_to_json x.f_ExecAllocGrp_NoExecs) :: (("LastQty",float_6_opt_to_json x.f_ExecAllocGrp_LastQty) :: (("ExecID",string_opt_to_json x.f_ExecAllocGrp_ExecID) :: (("SecondaryExecID",string_opt_to_json x.f_ExecAllocGrp_SecondaryExecID) :: (("LastPx",float_6_opt_to_json x.f_ExecAllocGrp_LastPx) :: (("LastParPx",float_6_opt_to_json x.f_ExecAllocGrp_LastParPx) :: (("LastCapacity",lastcapacity_opt_to_json x.f_ExecAllocGrp_LastCapacity) :: []))))))) -;; - -let commissiondata_to_string (d) = - "" -;; - -let commissiondata_to_json (x) : json = - assoc_filter_nulls (("Commission",float_6_opt_to_json x.f_CommissionData_Commission) :: (("CommType",commtype_opt_to_json x.f_CommissionData_CommType) :: (("CommCurrency",currency_opt_to_json x.f_CommissionData_CommCurrency) :: (("FundRenewWaiv",fundrenewwaiv_opt_to_json x.f_CommissionData_FundRenewWaiv) :: [])))) -;; - -let ptyssubgrp_to_string (d) = +let ptyssubgrp_to_string (_d) = "" ;; let ptyssubgrp_to_json (x) : json = - assoc_filter_nulls (("NoPartySubIDs",int_opt_to_json x.f_PtysSubGrp_NoPartySubIDs) :: (("PartySubID",string_opt_to_json x.f_PtysSubGrp_PartySubID) :: (("PartySubIDType",partysubidtype_opt_to_json x.f_PtysSubGrp_PartySubIDType) :: []))) -;; - -let settlptyssubgrp_to_string (d) = - "" -;; - -let settlptyssubgrp_to_json (x) : json = - assoc_filter_nulls (("NoSettlPartySubIDs",int_opt_to_json x.f_SettlPtysSubGrp_NoSettlPartySubIDs) :: (("SettlPartySubID",string_opt_to_json x.f_SettlPtysSubGrp_SettlPartySubID) :: (("SettlPartySubIDType",int_opt_to_json x.f_SettlPtysSubGrp_SettlPartySubIDType) :: []))) -;; - -let sectypesgrp_to_string (d) = - "" -;; - -let sectypesgrp_to_json (x) : json = - assoc_filter_nulls (("NoSecurityTypes",int_opt_to_json x.f_SecTypesGrp_NoSecurityTypes) :: (("SecurityType",securitytype_opt_to_json x.f_SecTypesGrp_SecurityType) :: (("SecuritySubType",string_opt_to_json x.f_SecTypesGrp_SecuritySubType) :: (("Product",product_opt_to_json x.f_SecTypesGrp_Product) :: (("CFICode",string_opt_to_json x.f_SecTypesGrp_CFICode) :: []))))) -;; - -let quotqualgrp_to_string (d) = - "" + assoc_filter_nulls ([(("NoPartySubIDs",int_opt_to_json x.f_PtysSubGrp_NoPartySubIDs));(("PartySubID",string_opt_to_json x.f_PtysSubGrp_PartySubID))]) ;; -let quotqualgrp_to_json (x) : json = - assoc_filter_nulls (("NoQuoteQualifiers",int_opt_to_json x.f_QuotQualGrp_NoQuoteQualifiers) :: (("QuoteQualifier",char_opt_to_json x.f_QuotQualGrp_QuoteQualifier) :: [])) -;; - -let biddescreqgrp_to_string (d) = - "" -;; - -let biddescreqgrp_to_json (x) : json = - assoc_filter_nulls (("NoBidDescriptors",int_opt_to_json x.f_BidDescReqGrp_NoBidDescriptors) :: (("BidDescriptorType",biddescriptortype_opt_to_json x.f_BidDescReqGrp_BidDescriptorType) :: (("BidDescriptor",string_opt_to_json x.f_BidDescReqGrp_BidDescriptor) :: (("SideValueInd",sidevalueind_opt_to_json x.f_BidDescReqGrp_SideValueInd) :: (("LiquidityValue",float_6_opt_to_json x.f_BidDescReqGrp_LiquidityValue) :: (("LiquidityNumSecurities",int_opt_to_json x.f_BidDescReqGrp_LiquidityNumSecurities) :: (("LiquidityPctLow",float_6_opt_to_json x.f_BidDescReqGrp_LiquidityPctLow) :: (("LiquidityPctHigh",float_6_opt_to_json x.f_BidDescReqGrp_LiquidityPctHigh) :: (("EFPTrackingError",float_6_opt_to_json x.f_BidDescReqGrp_EFPTrackingError) :: (("FairValue",float_6_opt_to_json x.f_BidDescReqGrp_FairValue) :: (("OutsideIndexPct",float_6_opt_to_json x.f_BidDescReqGrp_OutsideIndexPct) :: (("ValueOfFutures",float_6_opt_to_json x.f_BidDescReqGrp_ValueOfFutures) :: [])))))))))))) -;; - -let secaltidgrp_to_string (d) = - "" -;; - -let secaltidgrp_to_json (x) : json = - assoc_filter_nulls (("NoSecurityAltID",int_opt_to_json x.f_SecAltIDGrp_NoSecurityAltID) :: (("SecurityAltID",string_opt_to_json x.f_SecAltIDGrp_SecurityAltID) :: (("SecurityAltIDSource",string_opt_to_json x.f_SecAltIDGrp_SecurityAltIDSource) :: []))) -;; - -let ordliststatgrp_to_string (d) = +let parties_to_string (_d) = "" ;; -let ordliststatgrp_to_json (x) : json = - assoc_filter_nulls (("NoOrders",int_opt_to_json x.f_OrdListStatGrp_NoOrders) :: (("ClOrdID",string_opt_to_json x.f_OrdListStatGrp_ClOrdID) :: (("SecondaryClOrdID",string_opt_to_json x.f_OrdListStatGrp_SecondaryClOrdID) :: (("CumQty",float_6_opt_to_json x.f_OrdListStatGrp_CumQty) :: (("OrdStatus",ordstatus_opt_to_json x.f_OrdListStatGrp_OrdStatus) :: (("WorkingIndicator",workingindicator_opt_to_json x.f_OrdListStatGrp_WorkingIndicator) :: (("LeavesQty",float_6_opt_to_json x.f_OrdListStatGrp_LeavesQty) :: (("CxlQty",float_6_opt_to_json x.f_OrdListStatGrp_CxlQty) :: (("AvgPx",float_6_opt_to_json x.f_OrdListStatGrp_AvgPx) :: (("OrdRejReason",ordrejreason_opt_to_json x.f_OrdListStatGrp_OrdRejReason) :: (("Text",string_opt_to_json x.f_OrdListStatGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_OrdListStatGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_OrdListStatGrp_EncodedText) :: []))))))))))))) -;; - -let legstipulations_to_string (d) = - "" +let parties_to_json (x) : json = + assoc_filter_nulls ([(("NoPartyIDs",int_opt_to_json x.f_Parties_NoPartyIDs));(("PartyID",string_opt_to_json x.f_Parties_PartyID));(("PartyIndex",int_opt_to_json x.f_Parties_PartyIndex));(("PtysSubGrp",rg_for_json ptyssubgrp_to_json x.f_Parties_PtysSubGrp))]) ;; -let legstipulations_to_json (x) : json = - assoc_filter_nulls (("NoLegStipulations",int_opt_to_json x.f_LegStipulations_NoLegStipulations) :: (("LegStipulationType",string_opt_to_json x.f_LegStipulations_LegStipulationType) :: (("LegStipulationValue",string_opt_to_json x.f_LegStipulations_LegStipulationValue) :: []))) -;; - -let settlparties_to_string (d) = - "" -;; - -let settlparties_to_json (x) : json = - assoc_filter_nulls (("NoSettlPartyIDs",int_opt_to_json x.f_SettlParties_NoSettlPartyIDs) :: (("SettlPartyID",string_opt_to_json x.f_SettlParties_SettlPartyID) :: (("SettlPartyIDSource",char_opt_to_json x.f_SettlParties_SettlPartyIDSource) :: (("SettlPartyRole",int_opt_to_json x.f_SettlParties_SettlPartyRole) :: (("SettlPtysSubGrp",rg_for_json settlptyssubgrp_to_json x.f_SettlParties_SettlPtysSubGrp) :: []))))) -;; - -let parties_to_string (d) = - "" -;; - -let parties_to_json (x) : json = - assoc_filter_nulls (("NoPartyIDs",int_opt_to_json x.f_Parties_NoPartyIDs) :: (("PartyID",string_opt_to_json x.f_Parties_PartyID) :: (("PartyIDSource",partyidsource_opt_to_json x.f_Parties_PartyIDSource) :: (("PartyRole",partyrole_opt_to_json x.f_Parties_PartyRole) :: (("PtysSubGrp",rg_for_json ptyssubgrp_to_json x.f_Parties_PtysSubGrp) :: []))))) -;; - -let bidcomprspgrp_to_string (d) = - "" -;; - -let bidcomprspgrp_to_json (x) : json = - assoc_filter_nulls (("CommissionData",commissiondata_to_json x.f_BidCompRspGrp_CommissionData) :: (("NoBidComponents",int_opt_to_json x.f_BidCompRspGrp_NoBidComponents) :: (("ListID",string_opt_to_json x.f_BidCompRspGrp_ListID) :: (("Country",country_opt_to_json x.f_BidCompRspGrp_Country) :: (("Side",side_opt_to_json x.f_BidCompRspGrp_Side) :: (("Price",float_6_opt_to_json x.f_BidCompRspGrp_Price) :: (("PriceType",pricetype_opt_to_json x.f_BidCompRspGrp_PriceType) :: (("FairValue",float_6_opt_to_json x.f_BidCompRspGrp_FairValue) :: (("NetGrossInd",netgrossind_opt_to_json x.f_BidCompRspGrp_NetGrossInd) :: (("SettlType",settltype_opt_to_json x.f_BidCompRspGrp_SettlType) :: (("SettlDate",localmktdate_opt_to_json x.f_BidCompRspGrp_SettlDate) :: (("TradingSessionID",string_opt_to_json x.f_BidCompRspGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_BidCompRspGrp_TradingSessionSubID) :: (("Text",string_opt_to_json x.f_BidCompRspGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_BidCompRspGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_BidCompRspGrp_EncodedText) :: [])))))))))))))))) -;; - -let nestedparties_to_string (d) = - "" -;; - -let nestedparties_to_json (x) : json = - assoc_filter_nulls (("NoNestedPartyIDs",int_opt_to_json x.f_NestedParties_NoNestedPartyIDs) :: (("NestedPartyID",string_opt_to_json x.f_NestedParties_NestedPartyID) :: (("NestedPartyIDSource",char_opt_to_json x.f_NestedParties_NestedPartyIDSource) :: (("NestedPartyRole",int_opt_to_json x.f_NestedParties_NestedPartyRole) :: (("NstdPtysSubGrp",rg_for_json nstdptyssubgrp_to_json x.f_NestedParties_NstdPtysSubGrp) :: []))))) -;; - -let nestedparties2_to_string (d) = - "" -;; - -let nestedparties2_to_json (x) : json = - assoc_filter_nulls (("NoNested2PartyIDs",int_opt_to_json x.f_NestedParties2_NoNested2PartyIDs) :: (("Nested2PartyID",string_opt_to_json x.f_NestedParties2_Nested2PartyID) :: (("Nested2PartyIDSource",char_opt_to_json x.f_NestedParties2_Nested2PartyIDSource) :: (("Nested2PartyRole",int_opt_to_json x.f_NestedParties2_Nested2PartyRole) :: (("NstdPtys2SubGrp",rg_for_json nstdptys2subgrp_to_json x.f_NestedParties2_NstdPtys2SubGrp) :: []))))) -;; - -let nestedparties3_to_string (d) = - "" -;; - -let nestedparties3_to_json (x) : json = - assoc_filter_nulls (("NoNested3PartyIDs",int_opt_to_json x.f_NestedParties3_NoNested3PartyIDs) :: (("Nested3PartyID",string_opt_to_json x.f_NestedParties3_Nested3PartyID) :: (("Nested3PartyIDSource",char_opt_to_json x.f_NestedParties3_Nested3PartyIDSource) :: (("Nested3PartyRole",int_opt_to_json x.f_NestedParties3_Nested3PartyRole) :: (("NstdPtys3SubGrp",rg_for_json nstdptys3subgrp_to_json x.f_NestedParties3_NstdPtys3SubGrp) :: []))))) -;; - -let instrumentextension_to_string (d) = - "" -;; - -let instrumentextension_to_json (x) : json = - assoc_filter_nulls (("DeliveryForm",deliveryform_opt_to_json x.f_InstrumentExtension_DeliveryForm) :: (("PctAtRisk",float_6_opt_to_json x.f_InstrumentExtension_PctAtRisk) :: (("AttrbGrp",rg_for_json attrbgrp_to_json x.f_InstrumentExtension_AttrbGrp) :: []))) -;; - -let instrumentleg_to_string (d) = - "" -;; - -let instrumentleg_to_json (x) : json = - assoc_filter_nulls (("LegSymbol",string_opt_to_json x.f_InstrumentLeg_LegSymbol) :: (("LegSymbolSfx",string_opt_to_json x.f_InstrumentLeg_LegSymbolSfx) :: (("LegSecurityID",string_opt_to_json x.f_InstrumentLeg_LegSecurityID) :: (("LegSecurityIDSource",string_opt_to_json x.f_InstrumentLeg_LegSecurityIDSource) :: (("LegProduct",int_opt_to_json x.f_InstrumentLeg_LegProduct) :: (("LegCFICode",string_opt_to_json x.f_InstrumentLeg_LegCFICode) :: (("LegSecurityType",string_opt_to_json x.f_InstrumentLeg_LegSecurityType) :: (("LegSecuritySubType",string_opt_to_json x.f_InstrumentLeg_LegSecuritySubType) :: (("LegMaturityMonthYear",monthyear_opt_to_json x.f_InstrumentLeg_LegMaturityMonthYear) :: (("LegMaturityDate",localmktdate_opt_to_json x.f_InstrumentLeg_LegMaturityDate) :: (("LegCouponPaymentDate",localmktdate_opt_to_json x.f_InstrumentLeg_LegCouponPaymentDate) :: (("LegIssueDate",localmktdate_opt_to_json x.f_InstrumentLeg_LegIssueDate) :: (("LegRepoCollateralSecurityType",string_opt_to_json x.f_InstrumentLeg_LegRepoCollateralSecurityType) :: (("LegRepurchaseTerm",int_opt_to_json x.f_InstrumentLeg_LegRepurchaseTerm) :: (("LegRepurchaseRate",float_6_opt_to_json x.f_InstrumentLeg_LegRepurchaseRate) :: (("LegFactor",float_opt_to_json x.f_InstrumentLeg_LegFactor) :: (("LegCreditRating",string_opt_to_json x.f_InstrumentLeg_LegCreditRating) :: (("LegInstrRegistry",string_opt_to_json x.f_InstrumentLeg_LegInstrRegistry) :: (("LegCountryOfIssue",country_opt_to_json x.f_InstrumentLeg_LegCountryOfIssue) :: (("LegStateOrProvinceOfIssue",string_opt_to_json x.f_InstrumentLeg_LegStateOrProvinceOfIssue) :: (("LegLocaleOfIssue",string_opt_to_json x.f_InstrumentLeg_LegLocaleOfIssue) :: (("LegRedemptionDate",localmktdate_opt_to_json x.f_InstrumentLeg_LegRedemptionDate) :: (("LegStrikePrice",float_6_opt_to_json x.f_InstrumentLeg_LegStrikePrice) :: (("LegStrikeCurrency",currency_opt_to_json x.f_InstrumentLeg_LegStrikeCurrency) :: (("LegOptAttribute",char_opt_to_json x.f_InstrumentLeg_LegOptAttribute) :: (("LegContractMultiplier",float_opt_to_json x.f_InstrumentLeg_LegContractMultiplier) :: (("LegCouponRate",float_6_opt_to_json x.f_InstrumentLeg_LegCouponRate) :: (("LegSecurityExchange",exchange_opt_to_json x.f_InstrumentLeg_LegSecurityExchange) :: (("LegIssuer",string_opt_to_json x.f_InstrumentLeg_LegIssuer) :: (("EncodedLegIssuerLen",int_opt_to_json x.f_InstrumentLeg_EncodedLegIssuerLen) :: (("EncodedLegIssuer",string_opt_to_json x.f_InstrumentLeg_EncodedLegIssuer) :: (("LegSecurityDesc",string_opt_to_json x.f_InstrumentLeg_LegSecurityDesc) :: (("EncodedLegSecurityDescLen",int_opt_to_json x.f_InstrumentLeg_EncodedLegSecurityDescLen) :: (("EncodedLegSecurityDesc",string_opt_to_json x.f_InstrumentLeg_EncodedLegSecurityDesc) :: (("LegRatioQty",float_opt_to_json x.f_InstrumentLeg_LegRatioQty) :: (("LegSide",char_opt_to_json x.f_InstrumentLeg_LegSide) :: (("LegCurrency",currency_opt_to_json x.f_InstrumentLeg_LegCurrency) :: (("LegPool",string_opt_to_json x.f_InstrumentLeg_LegPool) :: (("LegDatedDate",localmktdate_opt_to_json x.f_InstrumentLeg_LegDatedDate) :: (("LegContractSettlMonth",monthyear_opt_to_json x.f_InstrumentLeg_LegContractSettlMonth) :: (("LegInterestAccrualDate",localmktdate_opt_to_json x.f_InstrumentLeg_LegInterestAccrualDate) :: (("LegSecAltIDGrp",rg_for_json legsecaltidgrp_to_json x.f_InstrumentLeg_LegSecAltIDGrp) :: [])))))))))))))))))))))))))))))))))))))))))) -;; - -let instrument_to_string (d) = - "" -;; - -let instrument_to_json (x) : json = - assoc_filter_nulls (("Symbol",string_opt_to_json x.f_Instrument_Symbol) :: (("SymbolSfx",string_opt_to_json x.f_Instrument_SymbolSfx) :: (("SecurityID",string_opt_to_json x.f_Instrument_SecurityID) :: (("SecurityIDSource",securityidsource_opt_to_json x.f_Instrument_SecurityIDSource) :: (("Product",product_opt_to_json x.f_Instrument_Product) :: (("CFICode",string_opt_to_json x.f_Instrument_CFICode) :: (("SecurityType",securitytype_opt_to_json x.f_Instrument_SecurityType) :: (("SecuritySubType",string_opt_to_json x.f_Instrument_SecuritySubType) :: (("MaturityMonthYear",monthyear_opt_to_json x.f_Instrument_MaturityMonthYear) :: (("MaturityDate",localmktdate_opt_to_json x.f_Instrument_MaturityDate) :: (("CouponPaymentDate",localmktdate_opt_to_json x.f_Instrument_CouponPaymentDate) :: (("IssueDate",localmktdate_opt_to_json x.f_Instrument_IssueDate) :: (("RepoCollateralSecurityType",string_opt_to_json x.f_Instrument_RepoCollateralSecurityType) :: (("RepurchaseTerm",int_opt_to_json x.f_Instrument_RepurchaseTerm) :: (("RepurchaseRate",float_6_opt_to_json x.f_Instrument_RepurchaseRate) :: (("Factor",float_opt_to_json x.f_Instrument_Factor) :: (("CreditRating",string_opt_to_json x.f_Instrument_CreditRating) :: (("InstrRegistry",string_opt_to_json x.f_Instrument_InstrRegistry) :: (("CountryOfIssue",country_opt_to_json x.f_Instrument_CountryOfIssue) :: (("StateOrProvinceOfIssue",string_opt_to_json x.f_Instrument_StateOrProvinceOfIssue) :: (("LocaleOfIssue",string_opt_to_json x.f_Instrument_LocaleOfIssue) :: (("RedemptionDate",localmktdate_opt_to_json x.f_Instrument_RedemptionDate) :: (("StrikePrice",float_6_opt_to_json x.f_Instrument_StrikePrice) :: (("StrikeCurrency",currency_opt_to_json x.f_Instrument_StrikeCurrency) :: (("OptAttribute",char_opt_to_json x.f_Instrument_OptAttribute) :: (("ContractMultiplier",float_opt_to_json x.f_Instrument_ContractMultiplier) :: (("CouponRate",float_6_opt_to_json x.f_Instrument_CouponRate) :: (("SecurityExchange",exchange_opt_to_json x.f_Instrument_SecurityExchange) :: (("Issuer",string_opt_to_json x.f_Instrument_Issuer) :: (("EncodedIssuerLen",int_opt_to_json x.f_Instrument_EncodedIssuerLen) :: (("EncodedIssuer",string_opt_to_json x.f_Instrument_EncodedIssuer) :: (("SecurityDesc",string_opt_to_json x.f_Instrument_SecurityDesc) :: (("EncodedSecurityDescLen",int_opt_to_json x.f_Instrument_EncodedSecurityDescLen) :: (("EncodedSecurityDesc",string_opt_to_json x.f_Instrument_EncodedSecurityDesc) :: (("Pool",string_opt_to_json x.f_Instrument_Pool) :: (("ContractSettlMonth",monthyear_opt_to_json x.f_Instrument_ContractSettlMonth) :: (("CPProgram",cpprogram_opt_to_json x.f_Instrument_CPProgram) :: (("CPRegType",string_opt_to_json x.f_Instrument_CPRegType) :: (("DatedDate",localmktdate_opt_to_json x.f_Instrument_DatedDate) :: (("InterestAccrualDate",localmktdate_opt_to_json x.f_Instrument_InterestAccrualDate) :: (("SecAltIDGrp",rg_for_json secaltidgrp_to_json x.f_Instrument_SecAltIDGrp) :: (("EvntGrp",rg_for_json evntgrp_to_json x.f_Instrument_EvntGrp) :: [])))))))))))))))))))))))))))))))))))))))))) -;; - -let underlyinginstrument_to_string (d) = - "" -;; - -let underlyinginstrument_to_json (x) : json = - assoc_filter_nulls (("UnderlyingSymbol",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingSymbol) :: (("UnderlyingSymbolSfx",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingSymbolSfx) :: (("UnderlyingSecurityID",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingSecurityID) :: (("UnderlyingSecurityIDSource",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingSecurityIDSource) :: (("UnderlyingProduct",int_opt_to_json x.f_UnderlyingInstrument_UnderlyingProduct) :: (("UnderlyingCFICode",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingCFICode) :: (("UnderlyingSecurityType",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingSecurityType) :: (("UnderlyingSecuritySubType",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingSecuritySubType) :: (("UnderlyingMaturityMonthYear",monthyear_opt_to_json x.f_UnderlyingInstrument_UnderlyingMaturityMonthYear) :: (("UnderlyingMaturityDate",localmktdate_opt_to_json x.f_UnderlyingInstrument_UnderlyingMaturityDate) :: (("UnderlyingCouponPaymentDate",localmktdate_opt_to_json x.f_UnderlyingInstrument_UnderlyingCouponPaymentDate) :: (("UnderlyingIssueDate",localmktdate_opt_to_json x.f_UnderlyingInstrument_UnderlyingIssueDate) :: (("UnderlyingRepoCollateralSecurityType",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingRepoCollateralSecurityType) :: (("UnderlyingRepurchaseTerm",int_opt_to_json x.f_UnderlyingInstrument_UnderlyingRepurchaseTerm) :: (("UnderlyingRepurchaseRate",float_6_opt_to_json x.f_UnderlyingInstrument_UnderlyingRepurchaseRate) :: (("UnderlyingFactor",float_opt_to_json x.f_UnderlyingInstrument_UnderlyingFactor) :: (("UnderlyingCreditRating",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingCreditRating) :: (("UnderlyingInstrRegistry",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingInstrRegistry) :: (("UnderlyingCountryOfIssue",country_opt_to_json x.f_UnderlyingInstrument_UnderlyingCountryOfIssue) :: (("UnderlyingStateOrProvinceOfIssue",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingStateOrProvinceOfIssue) :: (("UnderlyingLocaleOfIssue",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingLocaleOfIssue) :: (("UnderlyingRedemptionDate",localmktdate_opt_to_json x.f_UnderlyingInstrument_UnderlyingRedemptionDate) :: (("UnderlyingStrikePrice",float_6_opt_to_json x.f_UnderlyingInstrument_UnderlyingStrikePrice) :: (("UnderlyingStrikeCurrency",currency_opt_to_json x.f_UnderlyingInstrument_UnderlyingStrikeCurrency) :: (("UnderlyingOptAttribute",char_opt_to_json x.f_UnderlyingInstrument_UnderlyingOptAttribute) :: (("UnderlyingContractMultiplier",float_opt_to_json x.f_UnderlyingInstrument_UnderlyingContractMultiplier) :: (("UnderlyingCouponRate",float_6_opt_to_json x.f_UnderlyingInstrument_UnderlyingCouponRate) :: (("UnderlyingSecurityExchange",exchange_opt_to_json x.f_UnderlyingInstrument_UnderlyingSecurityExchange) :: (("UnderlyingIssuer",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingIssuer) :: (("EncodedUnderlyingIssuerLen",int_opt_to_json x.f_UnderlyingInstrument_EncodedUnderlyingIssuerLen) :: (("EncodedUnderlyingIssuer",string_opt_to_json x.f_UnderlyingInstrument_EncodedUnderlyingIssuer) :: (("UnderlyingSecurityDesc",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingSecurityDesc) :: (("EncodedUnderlyingSecurityDescLen",int_opt_to_json x.f_UnderlyingInstrument_EncodedUnderlyingSecurityDescLen) :: (("EncodedUnderlyingSecurityDesc",string_opt_to_json x.f_UnderlyingInstrument_EncodedUnderlyingSecurityDesc) :: (("UnderlyingCPProgram",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingCPProgram) :: (("UnderlyingCPRegType",string_opt_to_json x.f_UnderlyingInstrument_UnderlyingCPRegType) :: (("UnderlyingCurrency",currency_opt_to_json x.f_UnderlyingInstrument_UnderlyingCurrency) :: (("UnderlyingQty",float_6_opt_to_json x.f_UnderlyingInstrument_UnderlyingQty) :: (("UnderlyingPx",float_6_opt_to_json x.f_UnderlyingInstrument_UnderlyingPx) :: (("UnderlyingDirtyPrice",float_6_opt_to_json x.f_UnderlyingInstrument_UnderlyingDirtyPrice) :: (("UnderlyingEndPrice",float_6_opt_to_json x.f_UnderlyingInstrument_UnderlyingEndPrice) :: (("UnderlyingStartValue",float_6_opt_to_json x.f_UnderlyingInstrument_UnderlyingStartValue) :: (("UnderlyingCurrentValue",float_6_opt_to_json x.f_UnderlyingInstrument_UnderlyingCurrentValue) :: (("UnderlyingEndValue",float_6_opt_to_json x.f_UnderlyingInstrument_UnderlyingEndValue) :: (("UndSecAltIDGrp",rg_for_json undsecaltidgrp_to_json x.f_UnderlyingInstrument_UndSecAltIDGrp) :: (("UnderlyingStipulations",rg_for_json underlyingstipulations_to_json x.f_UnderlyingInstrument_UnderlyingStipulations) :: [])))))))))))))))))))))))))))))))))))))))))))))) -;; - -let undinstrmtcollgrp_to_string (d) = - "" -;; - -let undinstrmtcollgrp_to_json (x) : json = - assoc_filter_nulls (("UnderlyingInstrument",underlyinginstrument_to_json x.f_UndInstrmtCollGrp_UnderlyingInstrument) :: (("NoUnderlyings",int_opt_to_json x.f_UndInstrmtCollGrp_NoUnderlyings) :: (("CollAction",collaction_opt_to_json x.f_UndInstrmtCollGrp_CollAction) :: []))) -;; - -let posundinstrmtgrp_to_string (d) = - "" -;; - -let posundinstrmtgrp_to_json (x) : json = - assoc_filter_nulls (("UnderlyingInstrument",underlyinginstrument_to_json x.f_PosUndInstrmtGrp_UnderlyingInstrument) :: (("NoUnderlyings",int_opt_to_json x.f_PosUndInstrmtGrp_NoUnderlyings) :: (("UnderlyingSettlPrice",float_6_opt_to_json x.f_PosUndInstrmtGrp_UnderlyingSettlPrice) :: (("UnderlyingSettlPriceType",int_opt_to_json x.f_PosUndInstrmtGrp_UnderlyingSettlPriceType) :: [])))) -;; - -let undinstrmtgrp_to_string (d) = - "" -;; - -let undinstrmtgrp_to_json (x) : json = - assoc_filter_nulls (("UnderlyingInstrument",underlyinginstrument_to_json x.f_UndInstrmtGrp_UnderlyingInstrument) :: (("NoUnderlyings",int_opt_to_json x.f_UndInstrmtGrp_NoUnderlyings) :: [])) -;; - -let undinstrmtstrkpxgrp_to_string (d) = - "" -;; - -let undinstrmtstrkpxgrp_to_json (x) : json = - assoc_filter_nulls (("UnderlyingInstrument",underlyinginstrument_to_json x.f_UndInstrmtStrkPxGrp_UnderlyingInstrument) :: (("NoUnderlyings",int_opt_to_json x.f_UndInstrmtStrkPxGrp_NoUnderlyings) :: (("PrevClosePx",float_6_opt_to_json x.f_UndInstrmtStrkPxGrp_PrevClosePx) :: (("ClOrdID",string_opt_to_json x.f_UndInstrmtStrkPxGrp_ClOrdID) :: (("SecondaryClOrdID",string_opt_to_json x.f_UndInstrmtStrkPxGrp_SecondaryClOrdID) :: (("Side",side_opt_to_json x.f_UndInstrmtStrkPxGrp_Side) :: (("Price",float_6_opt_to_json x.f_UndInstrmtStrkPxGrp_Price) :: (("Currency",currency_opt_to_json x.f_UndInstrmtStrkPxGrp_Currency) :: (("Text",string_opt_to_json x.f_UndInstrmtStrkPxGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_UndInstrmtStrkPxGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_UndInstrmtStrkPxGrp_EncodedText) :: []))))))))))) -;; - -let instrmtgrp_to_string (d) = - "" -;; - -let instrmtgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_InstrmtGrp_Instrument) :: (("NoRelatedSym",int_opt_to_json x.f_InstrmtGrp_NoRelatedSym) :: [])) -;; - -let instrmtstrkpxgrp_to_string (d) = - "" -;; - -let instrmtstrkpxgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_InstrmtStrkPxGrp_Instrument) :: (("NoStrikes",int_opt_to_json x.f_InstrmtStrkPxGrp_NoStrikes) :: [])) -;; - -let instrmtlegseclistgrp_to_string (d) = - "" -;; - -let instrmtlegseclistgrp_to_json (x) : json = - assoc_filter_nulls (("InstrumentLeg",instrumentleg_to_json x.f_InstrmtLegSecListGrp_InstrumentLeg) :: (("LegBenchmarkCurveData",legbenchmarkcurvedata_to_json x.f_InstrmtLegSecListGrp_LegBenchmarkCurveData) :: (("NoLegs",int_opt_to_json x.f_InstrmtLegSecListGrp_NoLegs) :: (("LegSwapType",legswaptype_opt_to_json x.f_InstrmtLegSecListGrp_LegSwapType) :: (("LegSettlType",char_opt_to_json x.f_InstrmtLegSecListGrp_LegSettlType) :: (("LegStipulations",rg_for_json legstipulations_to_json x.f_InstrmtLegSecListGrp_LegStipulations) :: [])))))) -;; - -let instrmtleggrp_to_string (d) = - "" -;; - -let instrmtleggrp_to_json (x) : json = - assoc_filter_nulls (("InstrumentLeg",instrumentleg_to_json x.f_InstrmtLegGrp_InstrumentLeg) :: (("NoLegs",int_opt_to_json x.f_InstrmtLegGrp_NoLegs) :: [])) -;; - -let instrmtlegioigrp_to_string (d) = - "" -;; - -let instrmtlegioigrp_to_json (x) : json = - assoc_filter_nulls (("InstrumentLeg",instrumentleg_to_json x.f_InstrmtLegIOIGrp_InstrumentLeg) :: (("NoLegs",int_opt_to_json x.f_InstrmtLegIOIGrp_NoLegs) :: (("LegIOIQty",string_opt_to_json x.f_InstrmtLegIOIGrp_LegIOIQty) :: (("LegStipulations",rg_for_json legstipulations_to_json x.f_InstrmtLegIOIGrp_LegStipulations) :: [])))) -;; - -let preallocmleggrp_to_string (d) = - "" -;; - -let preallocmleggrp_to_json (x) : json = - assoc_filter_nulls (("NoAllocs",int_opt_to_json x.f_PreAllocMlegGrp_NoAllocs) :: (("AllocAccount",string_opt_to_json x.f_PreAllocMlegGrp_AllocAccount) :: (("AllocAcctIDSource",int_opt_to_json x.f_PreAllocMlegGrp_AllocAcctIDSource) :: (("AllocSettlCurrency",currency_opt_to_json x.f_PreAllocMlegGrp_AllocSettlCurrency) :: (("IndividualAllocID",string_opt_to_json x.f_PreAllocMlegGrp_IndividualAllocID) :: (("AllocQty",float_6_opt_to_json x.f_PreAllocMlegGrp_AllocQty) :: (("NestedParties3",rg_for_json nestedparties3_to_json x.f_PreAllocMlegGrp_NestedParties3) :: []))))))) -;; - -let trdallocgrp_to_string (d) = - "" -;; - -let trdallocgrp_to_json (x) : json = - assoc_filter_nulls (("NoAllocs",int_opt_to_json x.f_TrdAllocGrp_NoAllocs) :: (("AllocAccount",string_opt_to_json x.f_TrdAllocGrp_AllocAccount) :: (("AllocAcctIDSource",int_opt_to_json x.f_TrdAllocGrp_AllocAcctIDSource) :: (("AllocSettlCurrency",currency_opt_to_json x.f_TrdAllocGrp_AllocSettlCurrency) :: (("IndividualAllocID",string_opt_to_json x.f_TrdAllocGrp_IndividualAllocID) :: (("AllocQty",float_6_opt_to_json x.f_TrdAllocGrp_AllocQty) :: (("NestedParties2",rg_for_json nestedparties2_to_json x.f_TrdAllocGrp_NestedParties2) :: []))))))) -;; - -let legpreallocgrp_to_string (d) = - "" -;; - -let legpreallocgrp_to_json (x) : json = - assoc_filter_nulls (("NoLegAllocs",int_opt_to_json x.f_LegPreAllocGrp_NoLegAllocs) :: (("LegAllocAccount",string_opt_to_json x.f_LegPreAllocGrp_LegAllocAccount) :: (("LegIndividualAllocID",string_opt_to_json x.f_LegPreAllocGrp_LegIndividualAllocID) :: (("LegAllocQty",float_6_opt_to_json x.f_LegPreAllocGrp_LegAllocQty) :: (("LegAllocAcctIDSource",string_opt_to_json x.f_LegPreAllocGrp_LegAllocAcctIDSource) :: (("LegSettlCurrency",currency_opt_to_json x.f_LegPreAllocGrp_LegSettlCurrency) :: (("NestedParties2",rg_for_json nestedparties2_to_json x.f_LegPreAllocGrp_NestedParties2) :: []))))))) -;; - -let ordallocgrp_to_string (d) = - "" -;; - -let ordallocgrp_to_json (x) : json = - assoc_filter_nulls (("NoOrders",int_opt_to_json x.f_OrdAllocGrp_NoOrders) :: (("ClOrdID",string_opt_to_json x.f_OrdAllocGrp_ClOrdID) :: (("OrderID",string_opt_to_json x.f_OrdAllocGrp_OrderID) :: (("SecondaryOrderID",string_opt_to_json x.f_OrdAllocGrp_SecondaryOrderID) :: (("SecondaryClOrdID",string_opt_to_json x.f_OrdAllocGrp_SecondaryClOrdID) :: (("ListID",string_opt_to_json x.f_OrdAllocGrp_ListID) :: (("OrderQty",float_6_opt_to_json x.f_OrdAllocGrp_OrderQty) :: (("OrderAvgPx",float_6_opt_to_json x.f_OrdAllocGrp_OrderAvgPx) :: (("OrderBookingQty",float_6_opt_to_json x.f_OrdAllocGrp_OrderBookingQty) :: (("NestedParties2",rg_for_json nestedparties2_to_json x.f_OrdAllocGrp_NestedParties2) :: [])))))))))) -;; - -let legquotstatgrp_to_string (d) = - "" -;; - -let legquotstatgrp_to_json (x) : json = - assoc_filter_nulls (("InstrumentLeg",instrumentleg_to_json x.f_LegQuotStatGrp_InstrumentLeg) :: (("NoLegs",int_opt_to_json x.f_LegQuotStatGrp_NoLegs) :: (("LegQty",float_6_opt_to_json x.f_LegQuotStatGrp_LegQty) :: (("LegSwapType",legswaptype_opt_to_json x.f_LegQuotStatGrp_LegSwapType) :: (("LegSettlType",char_opt_to_json x.f_LegQuotStatGrp_LegSettlType) :: (("LegSettlDate",localmktdate_opt_to_json x.f_LegQuotStatGrp_LegSettlDate) :: (("LegStipulations",rg_for_json legstipulations_to_json x.f_LegQuotStatGrp_LegStipulations) :: (("NestedParties",rg_for_json nestedparties_to_json x.f_LegQuotStatGrp_NestedParties) :: [])))))))) -;; - -let preallocgrp_to_string (d) = - "" -;; - -let preallocgrp_to_json (x) : json = - assoc_filter_nulls (("NoAllocs",int_opt_to_json x.f_PreAllocGrp_NoAllocs) :: (("AllocAccount",string_opt_to_json x.f_PreAllocGrp_AllocAccount) :: (("AllocAcctIDSource",int_opt_to_json x.f_PreAllocGrp_AllocAcctIDSource) :: (("AllocSettlCurrency",currency_opt_to_json x.f_PreAllocGrp_AllocSettlCurrency) :: (("IndividualAllocID",string_opt_to_json x.f_PreAllocGrp_IndividualAllocID) :: (("AllocQty",float_6_opt_to_json x.f_PreAllocGrp_AllocQty) :: (("NestedParties",rg_for_json nestedparties_to_json x.f_PreAllocGrp_NestedParties) :: []))))))) -;; - -let rgstdtlsgrp_to_string (d) = - "" -;; - -let rgstdtlsgrp_to_json (x) : json = - assoc_filter_nulls (("NoRegistDtls",int_opt_to_json x.f_RgstDtlsGrp_NoRegistDtls) :: (("RegistDtls",string_opt_to_json x.f_RgstDtlsGrp_RegistDtls) :: (("RegistEmail",string_opt_to_json x.f_RgstDtlsGrp_RegistEmail) :: (("MailingDtls",string_opt_to_json x.f_RgstDtlsGrp_MailingDtls) :: (("MailingInst",string_opt_to_json x.f_RgstDtlsGrp_MailingInst) :: (("OwnerType",ownertype_opt_to_json x.f_RgstDtlsGrp_OwnerType) :: (("DateOfBirth",localmktdate_opt_to_json x.f_RgstDtlsGrp_DateOfBirth) :: (("InvestorCountryOfResidence",country_opt_to_json x.f_RgstDtlsGrp_InvestorCountryOfResidence) :: (("NestedParties",rg_for_json nestedparties_to_json x.f_RgstDtlsGrp_NestedParties) :: []))))))))) -;; - -let instrmtlegexecgrp_to_string (d) = - "" -;; - -let instrmtlegexecgrp_to_json (x) : json = - assoc_filter_nulls (("InstrumentLeg",instrumentleg_to_json x.f_InstrmtLegExecGrp_InstrumentLeg) :: (("NoLegs",int_opt_to_json x.f_InstrmtLegExecGrp_NoLegs) :: (("LegQty",float_6_opt_to_json x.f_InstrmtLegExecGrp_LegQty) :: (("LegSwapType",legswaptype_opt_to_json x.f_InstrmtLegExecGrp_LegSwapType) :: (("LegPositionEffect",char_opt_to_json x.f_InstrmtLegExecGrp_LegPositionEffect) :: (("LegCoveredOrUncovered",int_opt_to_json x.f_InstrmtLegExecGrp_LegCoveredOrUncovered) :: (("LegRefID",string_opt_to_json x.f_InstrmtLegExecGrp_LegRefID) :: (("LegPrice",float_6_opt_to_json x.f_InstrmtLegExecGrp_LegPrice) :: (("LegSettlType",char_opt_to_json x.f_InstrmtLegExecGrp_LegSettlType) :: (("LegSettlDate",localmktdate_opt_to_json x.f_InstrmtLegExecGrp_LegSettlDate) :: (("LegLastPx",float_6_opt_to_json x.f_InstrmtLegExecGrp_LegLastPx) :: (("LegStipulations",rg_for_json legstipulations_to_json x.f_InstrmtLegExecGrp_LegStipulations) :: (("NestedParties",rg_for_json nestedparties_to_json x.f_InstrmtLegExecGrp_NestedParties) :: []))))))))))))) -;; - -let legquotgrp_to_string (d) = - "" -;; - -let legquotgrp_to_json (x) : json = - assoc_filter_nulls (("InstrumentLeg",instrumentleg_to_json x.f_LegQuotGrp_InstrumentLeg) :: (("LegBenchmarkCurveData",legbenchmarkcurvedata_to_json x.f_LegQuotGrp_LegBenchmarkCurveData) :: (("NoLegs",int_opt_to_json x.f_LegQuotGrp_NoLegs) :: (("LegQty",float_6_opt_to_json x.f_LegQuotGrp_LegQty) :: (("LegSwapType",legswaptype_opt_to_json x.f_LegQuotGrp_LegSwapType) :: (("LegSettlType",char_opt_to_json x.f_LegQuotGrp_LegSettlType) :: (("LegSettlDate",localmktdate_opt_to_json x.f_LegQuotGrp_LegSettlDate) :: (("LegPriceType",int_opt_to_json x.f_LegQuotGrp_LegPriceType) :: (("LegBidPx",float_6_opt_to_json x.f_LegQuotGrp_LegBidPx) :: (("LegOfferPx",float_6_opt_to_json x.f_LegQuotGrp_LegOfferPx) :: (("LegStipulations",rg_for_json legstipulations_to_json x.f_LegQuotGrp_LegStipulations) :: (("NestedParties",rg_for_json nestedparties_to_json x.f_LegQuotGrp_NestedParties) :: [])))))))))))) -;; - -let quotreqlegsgrp_to_string (d) = - "" -;; - -let quotreqlegsgrp_to_json (x) : json = - assoc_filter_nulls (("InstrumentLeg",instrumentleg_to_json x.f_QuotReqLegsGrp_InstrumentLeg) :: (("LegBenchmarkCurveData",legbenchmarkcurvedata_to_json x.f_QuotReqLegsGrp_LegBenchmarkCurveData) :: (("NoLegs",int_opt_to_json x.f_QuotReqLegsGrp_NoLegs) :: (("LegQty",float_6_opt_to_json x.f_QuotReqLegsGrp_LegQty) :: (("LegSwapType",legswaptype_opt_to_json x.f_QuotReqLegsGrp_LegSwapType) :: (("LegSettlType",char_opt_to_json x.f_QuotReqLegsGrp_LegSettlType) :: (("LegSettlDate",localmktdate_opt_to_json x.f_QuotReqLegsGrp_LegSettlDate) :: (("LegStipulations",rg_for_json legstipulations_to_json x.f_QuotReqLegsGrp_LegStipulations) :: (("NestedParties",rg_for_json nestedparties_to_json x.f_QuotReqLegsGrp_NestedParties) :: []))))))))) -;; - -let positionqty_to_string (d) = - "" -;; - -let positionqty_to_json (x) : json = - assoc_filter_nulls (("NoPositions",int_opt_to_json x.f_PositionQty_NoPositions) :: (("PosType",postype_opt_to_json x.f_PositionQty_PosType) :: (("LongQty",float_6_opt_to_json x.f_PositionQty_LongQty) :: (("ShortQty",float_6_opt_to_json x.f_PositionQty_ShortQty) :: (("PosQtyStatus",posqtystatus_opt_to_json x.f_PositionQty_PosQtyStatus) :: (("NestedParties",rg_for_json nestedparties_to_json x.f_PositionQty_NestedParties) :: [])))))) -;; - -let trdinstrmtleggrp_to_string (d) = - "" -;; - -let trdinstrmtleggrp_to_json (x) : json = - assoc_filter_nulls (("InstrumentLeg",instrumentleg_to_json x.f_TrdInstrmtLegGrp_InstrumentLeg) :: (("NoLegs",int_opt_to_json x.f_TrdInstrmtLegGrp_NoLegs) :: (("LegQty",float_6_opt_to_json x.f_TrdInstrmtLegGrp_LegQty) :: (("LegSwapType",legswaptype_opt_to_json x.f_TrdInstrmtLegGrp_LegSwapType) :: (("LegPositionEffect",char_opt_to_json x.f_TrdInstrmtLegGrp_LegPositionEffect) :: (("LegCoveredOrUncovered",int_opt_to_json x.f_TrdInstrmtLegGrp_LegCoveredOrUncovered) :: (("LegRefID",string_opt_to_json x.f_TrdInstrmtLegGrp_LegRefID) :: (("LegPrice",float_6_opt_to_json x.f_TrdInstrmtLegGrp_LegPrice) :: (("LegSettlType",char_opt_to_json x.f_TrdInstrmtLegGrp_LegSettlType) :: (("LegSettlDate",localmktdate_opt_to_json x.f_TrdInstrmtLegGrp_LegSettlDate) :: (("LegLastPx",float_6_opt_to_json x.f_TrdInstrmtLegGrp_LegLastPx) :: (("LegStipulations",rg_for_json legstipulations_to_json x.f_TrdInstrmtLegGrp_LegStipulations) :: (("NestedParties",rg_for_json nestedparties_to_json x.f_TrdInstrmtLegGrp_NestedParties) :: []))))))))))))) -;; - -let sidecrossordcxlgrp_to_string (d) = - "" -;; - -let sidecrossordcxlgrp_to_json (x) : json = - assoc_filter_nulls (("OrderQtyData",orderqtydata_to_json x.f_SideCrossOrdCxlGrp_OrderQtyData) :: (("NoSides",int_opt_to_json x.f_SideCrossOrdCxlGrp_NoSides) :: (("Side",side_opt_to_json x.f_SideCrossOrdCxlGrp_Side) :: (("OrigClOrdID",string_opt_to_json x.f_SideCrossOrdCxlGrp_OrigClOrdID) :: (("ClOrdID",string_opt_to_json x.f_SideCrossOrdCxlGrp_ClOrdID) :: (("SecondaryClOrdID",string_opt_to_json x.f_SideCrossOrdCxlGrp_SecondaryClOrdID) :: (("ClOrdLinkID",string_opt_to_json x.f_SideCrossOrdCxlGrp_ClOrdLinkID) :: (("OrigOrdModTime",utctimestamp_milli_opt_to_json x.f_SideCrossOrdCxlGrp_OrigOrdModTime) :: (("TradeOriginationDate",localmktdate_opt_to_json x.f_SideCrossOrdCxlGrp_TradeOriginationDate) :: (("TradeDate",localmktdate_opt_to_json x.f_SideCrossOrdCxlGrp_TradeDate) :: (("ComplianceID",string_opt_to_json x.f_SideCrossOrdCxlGrp_ComplianceID) :: (("Text",string_opt_to_json x.f_SideCrossOrdCxlGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_SideCrossOrdCxlGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_SideCrossOrdCxlGrp_EncodedText) :: (("Parties",rg_for_json parties_to_json x.f_SideCrossOrdCxlGrp_Parties) :: []))))))))))))))) -;; - -let dlvyinstgrp_to_string (d) = - "" -;; - -let dlvyinstgrp_to_json (x) : json = - assoc_filter_nulls (("NoDlvyInst",int_opt_to_json x.f_DlvyInstGrp_NoDlvyInst) :: (("SettlInstSource",settlinstsource_opt_to_json x.f_DlvyInstGrp_SettlInstSource) :: (("DlvyInstType",dlvyinsttype_opt_to_json x.f_DlvyInstGrp_DlvyInstType) :: (("SettlParties",rg_for_json settlparties_to_json x.f_DlvyInstGrp_SettlParties) :: [])))) -;; - -let settlinstructionsdata_to_string (d) = - "" -;; - -let settlinstructionsdata_to_json (x) : json = - assoc_filter_nulls (("SettlDeliveryType",settldeliverytype_opt_to_json x.f_SettlInstructionsData_SettlDeliveryType) :: (("StandInstDbType",standinstdbtype_opt_to_json x.f_SettlInstructionsData_StandInstDbType) :: (("StandInstDbName",string_opt_to_json x.f_SettlInstructionsData_StandInstDbName) :: (("StandInstDbID",string_opt_to_json x.f_SettlInstructionsData_StandInstDbID) :: (("DlvyInstGrp",rg_for_json dlvyinstgrp_to_json x.f_SettlInstructionsData_DlvyInstGrp) :: []))))) -;; - -let sidecrossordmodgrp_to_string (d) = - "" -;; - -let sidecrossordmodgrp_to_json (x) : json = - assoc_filter_nulls (("OrderQtyData",orderqtydata_to_json x.f_SideCrossOrdModGrp_OrderQtyData) :: (("CommissionData",commissiondata_to_json x.f_SideCrossOrdModGrp_CommissionData) :: (("NoSides",int_opt_to_json x.f_SideCrossOrdModGrp_NoSides) :: (("Side",side_opt_to_json x.f_SideCrossOrdModGrp_Side) :: (("ClOrdID",string_opt_to_json x.f_SideCrossOrdModGrp_ClOrdID) :: (("SecondaryClOrdID",string_opt_to_json x.f_SideCrossOrdModGrp_SecondaryClOrdID) :: (("ClOrdLinkID",string_opt_to_json x.f_SideCrossOrdModGrp_ClOrdLinkID) :: (("TradeOriginationDate",localmktdate_opt_to_json x.f_SideCrossOrdModGrp_TradeOriginationDate) :: (("TradeDate",localmktdate_opt_to_json x.f_SideCrossOrdModGrp_TradeDate) :: (("Account",string_opt_to_json x.f_SideCrossOrdModGrp_Account) :: (("AcctIDSource",acctidsource_opt_to_json x.f_SideCrossOrdModGrp_AcctIDSource) :: (("AccountType",accounttype_opt_to_json x.f_SideCrossOrdModGrp_AccountType) :: (("DayBookingInst",daybookinginst_opt_to_json x.f_SideCrossOrdModGrp_DayBookingInst) :: (("BookingUnit",bookingunit_opt_to_json x.f_SideCrossOrdModGrp_BookingUnit) :: (("PreallocMethod",preallocmethod_opt_to_json x.f_SideCrossOrdModGrp_PreallocMethod) :: (("AllocID",string_opt_to_json x.f_SideCrossOrdModGrp_AllocID) :: (("QtyType",qtytype_opt_to_json x.f_SideCrossOrdModGrp_QtyType) :: (("OrderCapacity",ordercapacity_opt_to_json x.f_SideCrossOrdModGrp_OrderCapacity) :: (("OrderRestrictions",orderrestrictions_opt_to_json x.f_SideCrossOrdModGrp_OrderRestrictions) :: (("CustOrderCapacity",custordercapacity_opt_to_json x.f_SideCrossOrdModGrp_CustOrderCapacity) :: (("ForexReq",forexreq_opt_to_json x.f_SideCrossOrdModGrp_ForexReq) :: (("SettlCurrency",currency_opt_to_json x.f_SideCrossOrdModGrp_SettlCurrency) :: (("BookingType",bookingtype_opt_to_json x.f_SideCrossOrdModGrp_BookingType) :: (("Text",string_opt_to_json x.f_SideCrossOrdModGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_SideCrossOrdModGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_SideCrossOrdModGrp_EncodedText) :: (("PositionEffect",positioneffect_opt_to_json x.f_SideCrossOrdModGrp_PositionEffect) :: (("CoveredOrUncovered",coveredoruncovered_opt_to_json x.f_SideCrossOrdModGrp_CoveredOrUncovered) :: (("CashMargin",cashmargin_opt_to_json x.f_SideCrossOrdModGrp_CashMargin) :: (("ClearingFeeIndicator",clearingfeeindicator_opt_to_json x.f_SideCrossOrdModGrp_ClearingFeeIndicator) :: (("SolicitedFlag",solicitedflag_opt_to_json x.f_SideCrossOrdModGrp_SolicitedFlag) :: (("SideComplianceID",string_opt_to_json x.f_SideCrossOrdModGrp_SideComplianceID) :: (("Parties",rg_for_json parties_to_json x.f_SideCrossOrdModGrp_Parties) :: (("PreAllocGrp",rg_for_json preallocgrp_to_json x.f_SideCrossOrdModGrp_PreAllocGrp) :: [])))))))))))))))))))))))))))))))))) -;; - -let legordgrp_to_string (d) = - "" -;; - -let legordgrp_to_json (x) : json = - assoc_filter_nulls (("InstrumentLeg",instrumentleg_to_json x.f_LegOrdGrp_InstrumentLeg) :: (("NoLegs",int_opt_to_json x.f_LegOrdGrp_NoLegs) :: (("LegQty",float_6_opt_to_json x.f_LegOrdGrp_LegQty) :: (("LegSwapType",legswaptype_opt_to_json x.f_LegOrdGrp_LegSwapType) :: (("LegPositionEffect",char_opt_to_json x.f_LegOrdGrp_LegPositionEffect) :: (("LegCoveredOrUncovered",int_opt_to_json x.f_LegOrdGrp_LegCoveredOrUncovered) :: (("LegRefID",string_opt_to_json x.f_LegOrdGrp_LegRefID) :: (("LegPrice",float_6_opt_to_json x.f_LegOrdGrp_LegPrice) :: (("LegSettlType",char_opt_to_json x.f_LegOrdGrp_LegSettlType) :: (("LegSettlDate",localmktdate_opt_to_json x.f_LegOrdGrp_LegSettlDate) :: (("LegStipulations",rg_for_json legstipulations_to_json x.f_LegOrdGrp_LegStipulations) :: (("LegPreAllocGrp",rg_for_json legpreallocgrp_to_json x.f_LegOrdGrp_LegPreAllocGrp) :: (("NestedParties",rg_for_json nestedparties_to_json x.f_LegOrdGrp_NestedParties) :: []))))))))))))) -;; - -let trdcaprptsidegrp_to_string (d) = - "" -;; - -let trdcaprptsidegrp_to_json (x) : json = - assoc_filter_nulls (("CommissionData",commissiondata_to_json x.f_TrdCapRptSideGrp_CommissionData) :: (("NoSides",int_opt_to_json x.f_TrdCapRptSideGrp_NoSides) :: (("Side",side_opt_to_json x.f_TrdCapRptSideGrp_Side) :: (("OrderID",string_opt_to_json x.f_TrdCapRptSideGrp_OrderID) :: (("SecondaryOrderID",string_opt_to_json x.f_TrdCapRptSideGrp_SecondaryOrderID) :: (("ClOrdID",string_opt_to_json x.f_TrdCapRptSideGrp_ClOrdID) :: (("SecondaryClOrdID",string_opt_to_json x.f_TrdCapRptSideGrp_SecondaryClOrdID) :: (("ListID",string_opt_to_json x.f_TrdCapRptSideGrp_ListID) :: (("Account",string_opt_to_json x.f_TrdCapRptSideGrp_Account) :: (("AcctIDSource",acctidsource_opt_to_json x.f_TrdCapRptSideGrp_AcctIDSource) :: (("AccountType",accounttype_opt_to_json x.f_TrdCapRptSideGrp_AccountType) :: (("ProcessCode",processcode_opt_to_json x.f_TrdCapRptSideGrp_ProcessCode) :: (("OddLot",oddlot_opt_to_json x.f_TrdCapRptSideGrp_OddLot) :: (("TradeInputSource",string_opt_to_json x.f_TrdCapRptSideGrp_TradeInputSource) :: (("TradeInputDevice",string_opt_to_json x.f_TrdCapRptSideGrp_TradeInputDevice) :: (("OrderInputDevice",string_opt_to_json x.f_TrdCapRptSideGrp_OrderInputDevice) :: (("Currency",currency_opt_to_json x.f_TrdCapRptSideGrp_Currency) :: (("ComplianceID",string_opt_to_json x.f_TrdCapRptSideGrp_ComplianceID) :: (("SolicitedFlag",solicitedflag_opt_to_json x.f_TrdCapRptSideGrp_SolicitedFlag) :: (("OrderCapacity",ordercapacity_opt_to_json x.f_TrdCapRptSideGrp_OrderCapacity) :: (("OrderRestrictions",orderrestrictions_opt_to_json x.f_TrdCapRptSideGrp_OrderRestrictions) :: (("CustOrderCapacity",custordercapacity_opt_to_json x.f_TrdCapRptSideGrp_CustOrderCapacity) :: (("OrdType",ordtype_opt_to_json x.f_TrdCapRptSideGrp_OrdType) :: (("ExecInst",execinst_opt_to_json x.f_TrdCapRptSideGrp_ExecInst) :: (("TransBkdTime",utctimestamp_milli_opt_to_json x.f_TrdCapRptSideGrp_TransBkdTime) :: (("TradingSessionID",string_opt_to_json x.f_TrdCapRptSideGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_TrdCapRptSideGrp_TradingSessionSubID) :: (("TimeBracket",string_opt_to_json x.f_TrdCapRptSideGrp_TimeBracket) :: (("GrossTradeAmt",float_6_opt_to_json x.f_TrdCapRptSideGrp_GrossTradeAmt) :: (("NumDaysInterest",int_opt_to_json x.f_TrdCapRptSideGrp_NumDaysInterest) :: (("ExDate",localmktdate_opt_to_json x.f_TrdCapRptSideGrp_ExDate) :: (("AccruedInterestRate",float_6_opt_to_json x.f_TrdCapRptSideGrp_AccruedInterestRate) :: (("AccruedInterestAmt",float_6_opt_to_json x.f_TrdCapRptSideGrp_AccruedInterestAmt) :: (("InterestAtMaturity",float_6_opt_to_json x.f_TrdCapRptSideGrp_InterestAtMaturity) :: (("EndAccruedInterestAmt",float_6_opt_to_json x.f_TrdCapRptSideGrp_EndAccruedInterestAmt) :: (("StartCash",float_6_opt_to_json x.f_TrdCapRptSideGrp_StartCash) :: (("EndCash",float_6_opt_to_json x.f_TrdCapRptSideGrp_EndCash) :: (("Concession",float_6_opt_to_json x.f_TrdCapRptSideGrp_Concession) :: (("TotalTakedown",float_6_opt_to_json x.f_TrdCapRptSideGrp_TotalTakedown) :: (("NetMoney",float_6_opt_to_json x.f_TrdCapRptSideGrp_NetMoney) :: (("SettlCurrAmt",float_6_opt_to_json x.f_TrdCapRptSideGrp_SettlCurrAmt) :: (("SettlCurrency",currency_opt_to_json x.f_TrdCapRptSideGrp_SettlCurrency) :: (("SettlCurrFxRate",float_opt_to_json x.f_TrdCapRptSideGrp_SettlCurrFxRate) :: (("SettlCurrFxRateCalc",settlcurrfxratecalc_opt_to_json x.f_TrdCapRptSideGrp_SettlCurrFxRateCalc) :: (("PositionEffect",positioneffect_opt_to_json x.f_TrdCapRptSideGrp_PositionEffect) :: (("Text",string_opt_to_json x.f_TrdCapRptSideGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_TrdCapRptSideGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_TrdCapRptSideGrp_EncodedText) :: (("SideMultiLegReportingType",sidemultilegreportingtype_opt_to_json x.f_TrdCapRptSideGrp_SideMultiLegReportingType) :: (("ExchangeRule",string_opt_to_json x.f_TrdCapRptSideGrp_ExchangeRule) :: (("TradeAllocIndicator",tradeallocindicator_opt_to_json x.f_TrdCapRptSideGrp_TradeAllocIndicator) :: (("PreallocMethod",preallocmethod_opt_to_json x.f_TrdCapRptSideGrp_PreallocMethod) :: (("AllocID",string_opt_to_json x.f_TrdCapRptSideGrp_AllocID) :: (("Parties",rg_for_json parties_to_json x.f_TrdCapRptSideGrp_Parties) :: (("ClrInstGrp",rg_for_json clrinstgrp_to_json x.f_TrdCapRptSideGrp_ClrInstGrp) :: (("ContAmtGrp",rg_for_json contamtgrp_to_json x.f_TrdCapRptSideGrp_ContAmtGrp) :: (("Stipulations",rg_for_json stipulations_to_json x.f_TrdCapRptSideGrp_Stipulations) :: (("MiscFeesGrp",rg_for_json miscfeesgrp_to_json x.f_TrdCapRptSideGrp_MiscFeesGrp) :: (("TrdAllocGrp",rg_for_json trdallocgrp_to_json x.f_TrdCapRptSideGrp_TrdAllocGrp) :: []))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) -;; - -let relsymderivsecgrp_to_string (d) = - "" -;; - -let relsymderivsecgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_RelSymDerivSecGrp_Instrument) :: (("InstrumentExtension",instrumentextension_to_json x.f_RelSymDerivSecGrp_InstrumentExtension) :: (("NoRelatedSym",int_opt_to_json x.f_RelSymDerivSecGrp_NoRelatedSym) :: (("Currency",currency_opt_to_json x.f_RelSymDerivSecGrp_Currency) :: (("ExpirationCycle",expirationcycle_opt_to_json x.f_RelSymDerivSecGrp_ExpirationCycle) :: (("TradingSessionID",string_opt_to_json x.f_RelSymDerivSecGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_RelSymDerivSecGrp_TradingSessionSubID) :: (("Text",string_opt_to_json x.f_RelSymDerivSecGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_RelSymDerivSecGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_RelSymDerivSecGrp_EncodedText) :: (("InstrmtLegGrp",rg_for_json instrmtleggrp_to_json x.f_RelSymDerivSecGrp_InstrmtLegGrp) :: []))))))))))) -;; - -let quotentrygrp_to_string (d) = - "" -;; - -let quotentrygrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_QuotEntryGrp_Instrument) :: (("NoQuoteEntries",int_opt_to_json x.f_QuotEntryGrp_NoQuoteEntries) :: (("QuoteEntryID",string_opt_to_json x.f_QuotEntryGrp_QuoteEntryID) :: (("BidPx",float_6_opt_to_json x.f_QuotEntryGrp_BidPx) :: (("OfferPx",float_6_opt_to_json x.f_QuotEntryGrp_OfferPx) :: (("BidSize",float_6_opt_to_json x.f_QuotEntryGrp_BidSize) :: (("OfferSize",float_6_opt_to_json x.f_QuotEntryGrp_OfferSize) :: (("ValidUntilTime",utctimestamp_milli_opt_to_json x.f_QuotEntryGrp_ValidUntilTime) :: (("BidSpotRate",float_6_opt_to_json x.f_QuotEntryGrp_BidSpotRate) :: (("OfferSpotRate",float_6_opt_to_json x.f_QuotEntryGrp_OfferSpotRate) :: (("BidForwardPoints",float_6_opt_to_json x.f_QuotEntryGrp_BidForwardPoints) :: (("OfferForwardPoints",float_6_opt_to_json x.f_QuotEntryGrp_OfferForwardPoints) :: (("MidPx",float_6_opt_to_json x.f_QuotEntryGrp_MidPx) :: (("BidYield",float_6_opt_to_json x.f_QuotEntryGrp_BidYield) :: (("MidYield",float_6_opt_to_json x.f_QuotEntryGrp_MidYield) :: (("OfferYield",float_6_opt_to_json x.f_QuotEntryGrp_OfferYield) :: (("TransactTime",utctimestamp_milli_opt_to_json x.f_QuotEntryGrp_TransactTime) :: (("TradingSessionID",string_opt_to_json x.f_QuotEntryGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_QuotEntryGrp_TradingSessionSubID) :: (("SettlDate",localmktdate_opt_to_json x.f_QuotEntryGrp_SettlDate) :: (("OrdType",ordtype_opt_to_json x.f_QuotEntryGrp_OrdType) :: (("SettlDate2",localmktdate_opt_to_json x.f_QuotEntryGrp_SettlDate2) :: (("OrderQty2",float_6_opt_to_json x.f_QuotEntryGrp_OrderQty2) :: (("BidForwardPoints2",float_6_opt_to_json x.f_QuotEntryGrp_BidForwardPoints2) :: (("OfferForwardPoints2",float_6_opt_to_json x.f_QuotEntryGrp_OfferForwardPoints2) :: (("Currency",currency_opt_to_json x.f_QuotEntryGrp_Currency) :: (("InstrmtLegGrp",rg_for_json instrmtleggrp_to_json x.f_QuotEntryGrp_InstrmtLegGrp) :: []))))))))))))))))))))))))))) -;; - -let quotentryackgrp_to_string (d) = - "" -;; - -let quotentryackgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_QuotEntryAckGrp_Instrument) :: (("NoQuoteEntries",int_opt_to_json x.f_QuotEntryAckGrp_NoQuoteEntries) :: (("QuoteEntryID",string_opt_to_json x.f_QuotEntryAckGrp_QuoteEntryID) :: (("BidPx",float_6_opt_to_json x.f_QuotEntryAckGrp_BidPx) :: (("OfferPx",float_6_opt_to_json x.f_QuotEntryAckGrp_OfferPx) :: (("BidSize",float_6_opt_to_json x.f_QuotEntryAckGrp_BidSize) :: (("OfferSize",float_6_opt_to_json x.f_QuotEntryAckGrp_OfferSize) :: (("ValidUntilTime",utctimestamp_milli_opt_to_json x.f_QuotEntryAckGrp_ValidUntilTime) :: (("BidSpotRate",float_6_opt_to_json x.f_QuotEntryAckGrp_BidSpotRate) :: (("OfferSpotRate",float_6_opt_to_json x.f_QuotEntryAckGrp_OfferSpotRate) :: (("BidForwardPoints",float_6_opt_to_json x.f_QuotEntryAckGrp_BidForwardPoints) :: (("OfferForwardPoints",float_6_opt_to_json x.f_QuotEntryAckGrp_OfferForwardPoints) :: (("MidPx",float_6_opt_to_json x.f_QuotEntryAckGrp_MidPx) :: (("BidYield",float_6_opt_to_json x.f_QuotEntryAckGrp_BidYield) :: (("MidYield",float_6_opt_to_json x.f_QuotEntryAckGrp_MidYield) :: (("OfferYield",float_6_opt_to_json x.f_QuotEntryAckGrp_OfferYield) :: (("TransactTime",utctimestamp_milli_opt_to_json x.f_QuotEntryAckGrp_TransactTime) :: (("TradingSessionID",string_opt_to_json x.f_QuotEntryAckGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_QuotEntryAckGrp_TradingSessionSubID) :: (("SettlDate",localmktdate_opt_to_json x.f_QuotEntryAckGrp_SettlDate) :: (("OrdType",ordtype_opt_to_json x.f_QuotEntryAckGrp_OrdType) :: (("SettlDate2",localmktdate_opt_to_json x.f_QuotEntryAckGrp_SettlDate2) :: (("OrderQty2",float_6_opt_to_json x.f_QuotEntryAckGrp_OrderQty2) :: (("BidForwardPoints2",float_6_opt_to_json x.f_QuotEntryAckGrp_BidForwardPoints2) :: (("OfferForwardPoints2",float_6_opt_to_json x.f_QuotEntryAckGrp_OfferForwardPoints2) :: (("Currency",currency_opt_to_json x.f_QuotEntryAckGrp_Currency) :: (("QuoteEntryRejectReason",int_opt_to_json x.f_QuotEntryAckGrp_QuoteEntryRejectReason) :: (("InstrmtLegGrp",rg_for_json instrmtleggrp_to_json x.f_QuotEntryAckGrp_InstrmtLegGrp) :: [])))))))))))))))))))))))))))) -;; - -let listordgrp_to_string (d) = - "" -;; - -let listordgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_ListOrdGrp_Instrument) :: (("OrderQtyData",orderqtydata_to_json x.f_ListOrdGrp_OrderQtyData) :: (("SpreadOrBenchmarkCurveData",spreadorbenchmarkcurvedata_to_json x.f_ListOrdGrp_SpreadOrBenchmarkCurveData) :: (("YieldData",yielddata_to_json x.f_ListOrdGrp_YieldData) :: (("CommissionData",commissiondata_to_json x.f_ListOrdGrp_CommissionData) :: (("PegInstructions",peginstructions_to_json x.f_ListOrdGrp_PegInstructions) :: (("DiscretionInstructions",discretioninstructions_to_json x.f_ListOrdGrp_DiscretionInstructions) :: (("NoOrders",int_opt_to_json x.f_ListOrdGrp_NoOrders) :: (("ClOrdID",string_opt_to_json x.f_ListOrdGrp_ClOrdID) :: (("SecondaryClOrdID",string_opt_to_json x.f_ListOrdGrp_SecondaryClOrdID) :: (("ListSeqNo",int_opt_to_json x.f_ListOrdGrp_ListSeqNo) :: (("ClOrdLinkID",string_opt_to_json x.f_ListOrdGrp_ClOrdLinkID) :: (("SettlInstMode",settlinstmode_opt_to_json x.f_ListOrdGrp_SettlInstMode) :: (("TradeOriginationDate",localmktdate_opt_to_json x.f_ListOrdGrp_TradeOriginationDate) :: (("TradeDate",localmktdate_opt_to_json x.f_ListOrdGrp_TradeDate) :: (("Account",string_opt_to_json x.f_ListOrdGrp_Account) :: (("AcctIDSource",acctidsource_opt_to_json x.f_ListOrdGrp_AcctIDSource) :: (("AccountType",accounttype_opt_to_json x.f_ListOrdGrp_AccountType) :: (("DayBookingInst",daybookinginst_opt_to_json x.f_ListOrdGrp_DayBookingInst) :: (("BookingUnit",bookingunit_opt_to_json x.f_ListOrdGrp_BookingUnit) :: (("AllocID",string_opt_to_json x.f_ListOrdGrp_AllocID) :: (("PreallocMethod",preallocmethod_opt_to_json x.f_ListOrdGrp_PreallocMethod) :: (("SettlType",settltype_opt_to_json x.f_ListOrdGrp_SettlType) :: (("SettlDate",localmktdate_opt_to_json x.f_ListOrdGrp_SettlDate) :: (("CashMargin",cashmargin_opt_to_json x.f_ListOrdGrp_CashMargin) :: (("ClearingFeeIndicator",clearingfeeindicator_opt_to_json x.f_ListOrdGrp_ClearingFeeIndicator) :: (("HandlInst",handlinst_opt_to_json x.f_ListOrdGrp_HandlInst) :: (("ExecInst",execinst_opt_to_json x.f_ListOrdGrp_ExecInst) :: (("MinQty",float_6_opt_to_json x.f_ListOrdGrp_MinQty) :: (("MaxFloor",float_6_opt_to_json x.f_ListOrdGrp_MaxFloor) :: (("ExDestination",exchange_opt_to_json x.f_ListOrdGrp_ExDestination) :: (("ProcessCode",processcode_opt_to_json x.f_ListOrdGrp_ProcessCode) :: (("PrevClosePx",float_6_opt_to_json x.f_ListOrdGrp_PrevClosePx) :: (("Side",side_opt_to_json x.f_ListOrdGrp_Side) :: (("SideValueInd",sidevalueind_opt_to_json x.f_ListOrdGrp_SideValueInd) :: (("LocateReqd",locatereqd_opt_to_json x.f_ListOrdGrp_LocateReqd) :: (("TransactTime",utctimestamp_milli_opt_to_json x.f_ListOrdGrp_TransactTime) :: (("QtyType",qtytype_opt_to_json x.f_ListOrdGrp_QtyType) :: (("OrdType",ordtype_opt_to_json x.f_ListOrdGrp_OrdType) :: (("PriceType",pricetype_opt_to_json x.f_ListOrdGrp_PriceType) :: (("Price",float_6_opt_to_json x.f_ListOrdGrp_Price) :: (("StopPx",float_6_opt_to_json x.f_ListOrdGrp_StopPx) :: (("Currency",currency_opt_to_json x.f_ListOrdGrp_Currency) :: (("ComplianceID",string_opt_to_json x.f_ListOrdGrp_ComplianceID) :: (("SolicitedFlag",solicitedflag_opt_to_json x.f_ListOrdGrp_SolicitedFlag) :: (("IOIID",string_opt_to_json x.f_ListOrdGrp_IOIID) :: (("QuoteID",string_opt_to_json x.f_ListOrdGrp_QuoteID) :: (("TimeInForce",timeinforce_opt_to_json x.f_ListOrdGrp_TimeInForce) :: (("EffectiveTime",utctimestamp_milli_opt_to_json x.f_ListOrdGrp_EffectiveTime) :: (("ExpireDate",localmktdate_opt_to_json x.f_ListOrdGrp_ExpireDate) :: (("ExpireTime",utctimestamp_milli_opt_to_json x.f_ListOrdGrp_ExpireTime) :: (("GTBookingInst",gtbookinginst_opt_to_json x.f_ListOrdGrp_GTBookingInst) :: (("OrderCapacity",ordercapacity_opt_to_json x.f_ListOrdGrp_OrderCapacity) :: (("OrderRestrictions",orderrestrictions_opt_to_json x.f_ListOrdGrp_OrderRestrictions) :: (("CustOrderCapacity",custordercapacity_opt_to_json x.f_ListOrdGrp_CustOrderCapacity) :: (("ForexReq",forexreq_opt_to_json x.f_ListOrdGrp_ForexReq) :: (("SettlCurrency",currency_opt_to_json x.f_ListOrdGrp_SettlCurrency) :: (("BookingType",bookingtype_opt_to_json x.f_ListOrdGrp_BookingType) :: (("Text",string_opt_to_json x.f_ListOrdGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_ListOrdGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_ListOrdGrp_EncodedText) :: (("SettlDate2",localmktdate_opt_to_json x.f_ListOrdGrp_SettlDate2) :: (("OrderQty2",float_6_opt_to_json x.f_ListOrdGrp_OrderQty2) :: (("Price2",float_6_opt_to_json x.f_ListOrdGrp_Price2) :: (("PositionEffect",positioneffect_opt_to_json x.f_ListOrdGrp_PositionEffect) :: (("CoveredOrUncovered",coveredoruncovered_opt_to_json x.f_ListOrdGrp_CoveredOrUncovered) :: (("MaxShow",float_6_opt_to_json x.f_ListOrdGrp_MaxShow) :: (("TargetStrategy",targetstrategy_opt_to_json x.f_ListOrdGrp_TargetStrategy) :: (("TargetStrategyParameters",string_opt_to_json x.f_ListOrdGrp_TargetStrategyParameters) :: (("ParticipationRate",float_6_opt_to_json x.f_ListOrdGrp_ParticipationRate) :: (("Designation",string_opt_to_json x.f_ListOrdGrp_Designation) :: (("Parties",rg_for_json parties_to_json x.f_ListOrdGrp_Parties) :: (("PreAllocGrp",rg_for_json preallocgrp_to_json x.f_ListOrdGrp_PreAllocGrp) :: (("TrdgSesGrp",rg_for_json trdgsesgrp_to_json x.f_ListOrdGrp_TrdgSesGrp) :: (("UndInstrmtGrp",rg_for_json undinstrmtgrp_to_json x.f_ListOrdGrp_UndInstrmtGrp) :: (("Stipulations",rg_for_json stipulations_to_json x.f_ListOrdGrp_Stipulations) :: [])))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) -;; - -let quotreqrjctgrp_to_string (d) = - "" -;; - -let quotreqrjctgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_QuotReqRjctGrp_Instrument) :: (("FinancingDetails",financingdetails_to_json x.f_QuotReqRjctGrp_FinancingDetails) :: (("OrderQtyData",orderqtydata_to_json x.f_QuotReqRjctGrp_OrderQtyData) :: (("SpreadOrBenchmarkCurveData",spreadorbenchmarkcurvedata_to_json x.f_QuotReqRjctGrp_SpreadOrBenchmarkCurveData) :: (("YieldData",yielddata_to_json x.f_QuotReqRjctGrp_YieldData) :: (("NoRelatedSym",int_opt_to_json x.f_QuotReqRjctGrp_NoRelatedSym) :: (("PrevClosePx",float_6_opt_to_json x.f_QuotReqRjctGrp_PrevClosePx) :: (("QuoteRequestType",quoterequesttype_opt_to_json x.f_QuotReqRjctGrp_QuoteRequestType) :: (("QuoteType",quotetype_opt_to_json x.f_QuotReqRjctGrp_QuoteType) :: (("TradingSessionID",string_opt_to_json x.f_QuotReqRjctGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_QuotReqRjctGrp_TradingSessionSubID) :: (("TradeOriginationDate",localmktdate_opt_to_json x.f_QuotReqRjctGrp_TradeOriginationDate) :: (("Side",side_opt_to_json x.f_QuotReqRjctGrp_Side) :: (("QtyType",qtytype_opt_to_json x.f_QuotReqRjctGrp_QtyType) :: (("SettlType",settltype_opt_to_json x.f_QuotReqRjctGrp_SettlType) :: (("SettlDate",localmktdate_opt_to_json x.f_QuotReqRjctGrp_SettlDate) :: (("SettlDate2",localmktdate_opt_to_json x.f_QuotReqRjctGrp_SettlDate2) :: (("OrderQty2",float_6_opt_to_json x.f_QuotReqRjctGrp_OrderQty2) :: (("Currency",currency_opt_to_json x.f_QuotReqRjctGrp_Currency) :: (("Account",string_opt_to_json x.f_QuotReqRjctGrp_Account) :: (("AcctIDSource",acctidsource_opt_to_json x.f_QuotReqRjctGrp_AcctIDSource) :: (("AccountType",accounttype_opt_to_json x.f_QuotReqRjctGrp_AccountType) :: (("QuotePriceType",quotepricetype_opt_to_json x.f_QuotReqRjctGrp_QuotePriceType) :: (("OrdType",ordtype_opt_to_json x.f_QuotReqRjctGrp_OrdType) :: (("ExpireTime",utctimestamp_milli_opt_to_json x.f_QuotReqRjctGrp_ExpireTime) :: (("TransactTime",utctimestamp_milli_opt_to_json x.f_QuotReqRjctGrp_TransactTime) :: (("PriceType",pricetype_opt_to_json x.f_QuotReqRjctGrp_PriceType) :: (("Price",float_6_opt_to_json x.f_QuotReqRjctGrp_Price) :: (("Price2",float_6_opt_to_json x.f_QuotReqRjctGrp_Price2) :: (("UndInstrmtGrp",rg_for_json undinstrmtgrp_to_json x.f_QuotReqRjctGrp_UndInstrmtGrp) :: (("Stipulations",rg_for_json stipulations_to_json x.f_QuotReqRjctGrp_Stipulations) :: (("QuotReqLegsGrp",rg_for_json quotreqlegsgrp_to_json x.f_QuotReqRjctGrp_QuotReqLegsGrp) :: (("QuotQualGrp",rg_for_json quotqualgrp_to_json x.f_QuotReqRjctGrp_QuotQualGrp) :: (("Parties",rg_for_json parties_to_json x.f_QuotReqRjctGrp_Parties) :: [])))))))))))))))))))))))))))))))))) -;; - -let rfqreqgrp_to_string (d) = - "" -;; - -let rfqreqgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_RFQReqGrp_Instrument) :: (("NoRelatedSym",int_opt_to_json x.f_RFQReqGrp_NoRelatedSym) :: (("PrevClosePx",float_6_opt_to_json x.f_RFQReqGrp_PrevClosePx) :: (("QuoteRequestType",quoterequesttype_opt_to_json x.f_RFQReqGrp_QuoteRequestType) :: (("QuoteType",quotetype_opt_to_json x.f_RFQReqGrp_QuoteType) :: (("TradingSessionID",string_opt_to_json x.f_RFQReqGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_RFQReqGrp_TradingSessionSubID) :: (("UndInstrmtGrp",rg_for_json undinstrmtgrp_to_json x.f_RFQReqGrp_UndInstrmtGrp) :: (("InstrmtLegGrp",rg_for_json instrmtleggrp_to_json x.f_RFQReqGrp_InstrmtLegGrp) :: []))))))))) -;; - -let instrmtmdreqgrp_to_string (d) = - "" -;; - -let instrmtmdreqgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_InstrmtMDReqGrp_Instrument) :: (("NoRelatedSym",int_opt_to_json x.f_InstrmtMDReqGrp_NoRelatedSym) :: (("UndInstrmtGrp",rg_for_json undinstrmtgrp_to_json x.f_InstrmtMDReqGrp_UndInstrmtGrp) :: (("InstrmtLegGrp",rg_for_json instrmtleggrp_to_json x.f_InstrmtMDReqGrp_InstrmtLegGrp) :: [])))) -;; - -let mdincgrp_to_string (d) = - "" -;; - -let mdincgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_MDIncGrp_Instrument) :: (("NoMDEntries",int_opt_to_json x.f_MDIncGrp_NoMDEntries) :: (("MDUpdateAction",mdupdateaction_opt_to_json x.f_MDIncGrp_MDUpdateAction) :: (("DeleteReason",deletereason_opt_to_json x.f_MDIncGrp_DeleteReason) :: (("MDEntryType",mdentrytype_opt_to_json x.f_MDIncGrp_MDEntryType) :: (("MDEntryID",string_opt_to_json x.f_MDIncGrp_MDEntryID) :: (("MDEntryRefID",string_opt_to_json x.f_MDIncGrp_MDEntryRefID) :: (("FinancialStatus",financialstatus_opt_to_json x.f_MDIncGrp_FinancialStatus) :: (("CorporateAction",corporateaction_opt_to_json x.f_MDIncGrp_CorporateAction) :: (("MDEntryPx",float_6_opt_to_json x.f_MDIncGrp_MDEntryPx) :: (("Currency",currency_opt_to_json x.f_MDIncGrp_Currency) :: (("MDEntrySize",float_6_opt_to_json x.f_MDIncGrp_MDEntrySize) :: (("MDEntryDate",utcdateonly_opt_to_json x.f_MDIncGrp_MDEntryDate) :: (("MDEntryTime",utctimeonly_milli_opt_to_json x.f_MDIncGrp_MDEntryTime) :: (("TickDirection",tickdirection_opt_to_json x.f_MDIncGrp_TickDirection) :: (("MDMkt",exchange_opt_to_json x.f_MDIncGrp_MDMkt) :: (("TradingSessionID",string_opt_to_json x.f_MDIncGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_MDIncGrp_TradingSessionSubID) :: (("QuoteCondition",quotecondition_opt_to_json x.f_MDIncGrp_QuoteCondition) :: (("TradeCondition",tradecondition_opt_to_json x.f_MDIncGrp_TradeCondition) :: (("MDEntryOriginator",string_opt_to_json x.f_MDIncGrp_MDEntryOriginator) :: (("LocationID",string_opt_to_json x.f_MDIncGrp_LocationID) :: (("DeskID",string_opt_to_json x.f_MDIncGrp_DeskID) :: (("OpenCloseSettlFlag",openclosesettlflag_opt_to_json x.f_MDIncGrp_OpenCloseSettlFlag) :: (("TimeInForce",timeinforce_opt_to_json x.f_MDIncGrp_TimeInForce) :: (("ExpireDate",localmktdate_opt_to_json x.f_MDIncGrp_ExpireDate) :: (("ExpireTime",utctimestamp_milli_opt_to_json x.f_MDIncGrp_ExpireTime) :: (("MinQty",float_6_opt_to_json x.f_MDIncGrp_MinQty) :: (("ExecInst",execinst_opt_to_json x.f_MDIncGrp_ExecInst) :: (("SellerDays",int_opt_to_json x.f_MDIncGrp_SellerDays) :: (("OrderID",string_opt_to_json x.f_MDIncGrp_OrderID) :: (("QuoteEntryID",string_opt_to_json x.f_MDIncGrp_QuoteEntryID) :: (("MDEntryBuyer",string_opt_to_json x.f_MDIncGrp_MDEntryBuyer) :: (("MDEntrySeller",string_opt_to_json x.f_MDIncGrp_MDEntrySeller) :: (("NumberOfOrders",int_opt_to_json x.f_MDIncGrp_NumberOfOrders) :: (("MDEntryPositionNo",int_opt_to_json x.f_MDIncGrp_MDEntryPositionNo) :: (("Scope",scope_opt_to_json x.f_MDIncGrp_Scope) :: (("PriceDelta",float_opt_to_json x.f_MDIncGrp_PriceDelta) :: (("NetChgPrevDay",float_6_opt_to_json x.f_MDIncGrp_NetChgPrevDay) :: (("Text",string_opt_to_json x.f_MDIncGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_MDIncGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_MDIncGrp_EncodedText) :: (("UndInstrmtGrp",rg_for_json undinstrmtgrp_to_json x.f_MDIncGrp_UndInstrmtGrp) :: (("InstrmtLegGrp",rg_for_json instrmtleggrp_to_json x.f_MDIncGrp_InstrmtLegGrp) :: [])))))))))))))))))))))))))))))))))))))))))))) -;; - -let seclistgrp_to_string (d) = - "" -;; - -let seclistgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_SecListGrp_Instrument) :: (("InstrumentExtension",instrumentextension_to_json x.f_SecListGrp_InstrumentExtension) :: (("FinancingDetails",financingdetails_to_json x.f_SecListGrp_FinancingDetails) :: (("SpreadOrBenchmarkCurveData",spreadorbenchmarkcurvedata_to_json x.f_SecListGrp_SpreadOrBenchmarkCurveData) :: (("YieldData",yielddata_to_json x.f_SecListGrp_YieldData) :: (("NoRelatedSym",int_opt_to_json x.f_SecListGrp_NoRelatedSym) :: (("Currency",currency_opt_to_json x.f_SecListGrp_Currency) :: (("RoundLot",float_6_opt_to_json x.f_SecListGrp_RoundLot) :: (("MinTradeVol",float_6_opt_to_json x.f_SecListGrp_MinTradeVol) :: (("TradingSessionID",string_opt_to_json x.f_SecListGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_SecListGrp_TradingSessionSubID) :: (("ExpirationCycle",expirationcycle_opt_to_json x.f_SecListGrp_ExpirationCycle) :: (("Text",string_opt_to_json x.f_SecListGrp_Text) :: (("EncodedTextLen",int_opt_to_json x.f_SecListGrp_EncodedTextLen) :: (("EncodedText",string_opt_to_json x.f_SecListGrp_EncodedText) :: (("UndInstrmtGrp",rg_for_json undinstrmtgrp_to_json x.f_SecListGrp_UndInstrmtGrp) :: (("Stipulations",rg_for_json stipulations_to_json x.f_SecListGrp_Stipulations) :: (("InstrmtLegSecListGrp",rg_for_json instrmtlegseclistgrp_to_json x.f_SecListGrp_InstrmtLegSecListGrp) :: [])))))))))))))))))) -;; - -let quotreqgrp_to_string (d) = - "" -;; - -let quotreqgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_QuotReqGrp_Instrument) :: (("FinancingDetails",financingdetails_to_json x.f_QuotReqGrp_FinancingDetails) :: (("OrderQtyData",orderqtydata_to_json x.f_QuotReqGrp_OrderQtyData) :: (("SpreadOrBenchmarkCurveData",spreadorbenchmarkcurvedata_to_json x.f_QuotReqGrp_SpreadOrBenchmarkCurveData) :: (("YieldData",yielddata_to_json x.f_QuotReqGrp_YieldData) :: (("NoRelatedSym",int_opt_to_json x.f_QuotReqGrp_NoRelatedSym) :: (("PrevClosePx",float_6_opt_to_json x.f_QuotReqGrp_PrevClosePx) :: (("QuoteRequestType",quoterequesttype_opt_to_json x.f_QuotReqGrp_QuoteRequestType) :: (("QuoteType",quotetype_opt_to_json x.f_QuotReqGrp_QuoteType) :: (("TradingSessionID",string_opt_to_json x.f_QuotReqGrp_TradingSessionID) :: (("TradingSessionSubID",string_opt_to_json x.f_QuotReqGrp_TradingSessionSubID) :: (("TradeOriginationDate",localmktdate_opt_to_json x.f_QuotReqGrp_TradeOriginationDate) :: (("Side",side_opt_to_json x.f_QuotReqGrp_Side) :: (("QtyType",qtytype_opt_to_json x.f_QuotReqGrp_QtyType) :: (("SettlType",settltype_opt_to_json x.f_QuotReqGrp_SettlType) :: (("SettlDate",localmktdate_opt_to_json x.f_QuotReqGrp_SettlDate) :: (("SettlDate2",localmktdate_opt_to_json x.f_QuotReqGrp_SettlDate2) :: (("OrderQty2",float_6_opt_to_json x.f_QuotReqGrp_OrderQty2) :: (("Currency",currency_opt_to_json x.f_QuotReqGrp_Currency) :: (("Account",string_opt_to_json x.f_QuotReqGrp_Account) :: (("AcctIDSource",acctidsource_opt_to_json x.f_QuotReqGrp_AcctIDSource) :: (("AccountType",accounttype_opt_to_json x.f_QuotReqGrp_AccountType) :: (("QuotePriceType",quotepricetype_opt_to_json x.f_QuotReqGrp_QuotePriceType) :: (("OrdType",ordtype_opt_to_json x.f_QuotReqGrp_OrdType) :: (("ValidUntilTime",utctimestamp_milli_opt_to_json x.f_QuotReqGrp_ValidUntilTime) :: (("ExpireTime",utctimestamp_milli_opt_to_json x.f_QuotReqGrp_ExpireTime) :: (("TransactTime",utctimestamp_milli_opt_to_json x.f_QuotReqGrp_TransactTime) :: (("PriceType",pricetype_opt_to_json x.f_QuotReqGrp_PriceType) :: (("Price",float_6_opt_to_json x.f_QuotReqGrp_Price) :: (("Price2",float_6_opt_to_json x.f_QuotReqGrp_Price2) :: (("UndInstrmtGrp",rg_for_json undinstrmtgrp_to_json x.f_QuotReqGrp_UndInstrmtGrp) :: (("Stipulations",rg_for_json stipulations_to_json x.f_QuotReqGrp_Stipulations) :: (("QuotReqLegsGrp",rg_for_json quotreqlegsgrp_to_json x.f_QuotReqGrp_QuotReqLegsGrp) :: (("QuotQualGrp",rg_for_json quotqualgrp_to_json x.f_QuotReqGrp_QuotQualGrp) :: (("Parties",rg_for_json parties_to_json x.f_QuotReqGrp_Parties) :: []))))))))))))))))))))))))))))))))))) -;; - -let quotcxlentriesgrp_to_string (d) = - "" -;; - -let quotcxlentriesgrp_to_json (x) : json = - assoc_filter_nulls (("Instrument",instrument_to_json x.f_QuotCxlEntriesGrp_Instrument) :: (("FinancingDetails",financingdetails_to_json x.f_QuotCxlEntriesGrp_FinancingDetails) :: (("NoQuoteEntries",int_opt_to_json x.f_QuotCxlEntriesGrp_NoQuoteEntries) :: (("UndInstrmtGrp",rg_for_json undinstrmtgrp_to_json x.f_QuotCxlEntriesGrp_UndInstrmtGrp) :: (("InstrmtLegGrp",rg_for_json instrmtleggrp_to_json x.f_QuotCxlEntriesGrp_InstrmtLegGrp) :: []))))) -;; - -let quotsetackgrp_to_string (d) = - "" -;; - -let quotsetackgrp_to_json (x) : json = - assoc_filter_nulls (("UnderlyingInstrument",underlyinginstrument_to_json x.f_QuotSetAckGrp_UnderlyingInstrument) :: (("NoQuoteSets",int_opt_to_json x.f_QuotSetAckGrp_NoQuoteSets) :: (("QuoteSetID",string_opt_to_json x.f_QuotSetAckGrp_QuoteSetID) :: (("TotNoQuoteEntries",int_opt_to_json x.f_QuotSetAckGrp_TotNoQuoteEntries) :: (("LastFragment",lastfragment_opt_to_json x.f_QuotSetAckGrp_LastFragment) :: (("QuotEntryAckGrp",rg_for_json quotentryackgrp_to_json x.f_QuotSetAckGrp_QuotEntryAckGrp) :: [])))))) -;; - -let quotsetgrp_to_string (d) = - "" -;; - -let quotsetgrp_to_json (x) : json = - assoc_filter_nulls (("UnderlyingInstrument",underlyinginstrument_to_json x.f_QuotSetGrp_UnderlyingInstrument) :: (("NoQuoteSets",int_opt_to_json x.f_QuotSetGrp_NoQuoteSets) :: (("QuoteSetID",string_opt_to_json x.f_QuotSetGrp_QuoteSetID) :: (("QuoteSetValidUntilTime",utctimestamp_milli_opt_to_json x.f_QuotSetGrp_QuoteSetValidUntilTime) :: (("TotNoQuoteEntries",int_opt_to_json x.f_QuotSetGrp_TotNoQuoteEntries) :: (("LastFragment",lastfragment_opt_to_json x.f_QuotSetGrp_LastFragment) :: (("QuotEntryGrp",rg_for_json quotentrygrp_to_json x.f_QuotSetGrp_QuotEntryGrp) :: []))))))) -;; - -let settlinstgrp_to_string (d) = - "" -;; - -let settlinstgrp_to_json (x) : json = - assoc_filter_nulls (("SettlInstructionsData",settlinstructionsdata_to_json x.f_SettlInstGrp_SettlInstructionsData) :: (("NoSettlInst",int_opt_to_json x.f_SettlInstGrp_NoSettlInst) :: (("SettlInstID",string_opt_to_json x.f_SettlInstGrp_SettlInstID) :: (("SettlInstTransType",settlinsttranstype_opt_to_json x.f_SettlInstGrp_SettlInstTransType) :: (("SettlInstRefID",string_opt_to_json x.f_SettlInstGrp_SettlInstRefID) :: (("Side",side_opt_to_json x.f_SettlInstGrp_Side) :: (("Product",product_opt_to_json x.f_SettlInstGrp_Product) :: (("SecurityType",securitytype_opt_to_json x.f_SettlInstGrp_SecurityType) :: (("CFICode",string_opt_to_json x.f_SettlInstGrp_CFICode) :: (("EffectiveTime",utctimestamp_milli_opt_to_json x.f_SettlInstGrp_EffectiveTime) :: (("ExpireTime",utctimestamp_milli_opt_to_json x.f_SettlInstGrp_ExpireTime) :: (("LastUpdateTime",utctimestamp_milli_opt_to_json x.f_SettlInstGrp_LastUpdateTime) :: (("PaymentMethod",paymentmethod_opt_to_json x.f_SettlInstGrp_PaymentMethod) :: (("PaymentRef",string_opt_to_json x.f_SettlInstGrp_PaymentRef) :: (("CardHolderName",string_opt_to_json x.f_SettlInstGrp_CardHolderName) :: (("CardNumber",string_opt_to_json x.f_SettlInstGrp_CardNumber) :: (("CardStartDate",localmktdate_opt_to_json x.f_SettlInstGrp_CardStartDate) :: (("CardExpDate",localmktdate_opt_to_json x.f_SettlInstGrp_CardExpDate) :: (("CardIssNum",string_opt_to_json x.f_SettlInstGrp_CardIssNum) :: (("PaymentDate",localmktdate_opt_to_json x.f_SettlInstGrp_PaymentDate) :: (("PaymentRemitterID",string_opt_to_json x.f_SettlInstGrp_PaymentRemitterID) :: (("Parties",rg_for_json parties_to_json x.f_SettlInstGrp_Parties) :: [])))))))))))))))))))))) -;; - -let allocgrp_to_string (d) = - "" -;; - -let allocgrp_to_json (x) : json = - assoc_filter_nulls (("CommissionData",commissiondata_to_json x.f_AllocGrp_CommissionData) :: (("SettlInstructionsData",settlinstructionsdata_to_json x.f_AllocGrp_SettlInstructionsData) :: (("NoAllocs",int_opt_to_json x.f_AllocGrp_NoAllocs) :: (("AllocAccount",string_opt_to_json x.f_AllocGrp_AllocAccount) :: (("AllocAcctIDSource",int_opt_to_json x.f_AllocGrp_AllocAcctIDSource) :: (("MatchStatus",matchstatus_opt_to_json x.f_AllocGrp_MatchStatus) :: (("AllocPrice",float_6_opt_to_json x.f_AllocGrp_AllocPrice) :: (("AllocQty",float_6_opt_to_json x.f_AllocGrp_AllocQty) :: (("IndividualAllocID",string_opt_to_json x.f_AllocGrp_IndividualAllocID) :: (("ProcessCode",processcode_opt_to_json x.f_AllocGrp_ProcessCode) :: (("NotifyBrokerOfCredit",notifybrokerofcredit_opt_to_json x.f_AllocGrp_NotifyBrokerOfCredit) :: (("AllocHandlInst",allochandlinst_opt_to_json x.f_AllocGrp_AllocHandlInst) :: (("AllocText",string_opt_to_json x.f_AllocGrp_AllocText) :: (("EncodedAllocTextLen",int_opt_to_json x.f_AllocGrp_EncodedAllocTextLen) :: (("EncodedAllocText",string_opt_to_json x.f_AllocGrp_EncodedAllocText) :: (("AllocAvgPx",float_6_opt_to_json x.f_AllocGrp_AllocAvgPx) :: (("AllocNetMoney",float_6_opt_to_json x.f_AllocGrp_AllocNetMoney) :: (("SettlCurrAmt",float_6_opt_to_json x.f_AllocGrp_SettlCurrAmt) :: (("AllocSettlCurrAmt",float_6_opt_to_json x.f_AllocGrp_AllocSettlCurrAmt) :: (("SettlCurrency",currency_opt_to_json x.f_AllocGrp_SettlCurrency) :: (("AllocSettlCurrency",currency_opt_to_json x.f_AllocGrp_AllocSettlCurrency) :: (("SettlCurrFxRate",float_opt_to_json x.f_AllocGrp_SettlCurrFxRate) :: (("SettlCurrFxRateCalc",settlcurrfxratecalc_opt_to_json x.f_AllocGrp_SettlCurrFxRateCalc) :: (("AllocAccruedInterestAmt",float_6_opt_to_json x.f_AllocGrp_AllocAccruedInterestAmt) :: (("AllocInterestAtMaturity",float_6_opt_to_json x.f_AllocGrp_AllocInterestAtMaturity) :: (("AllocSettlInstType",allocsettlinsttype_opt_to_json x.f_AllocGrp_AllocSettlInstType) :: (("NestedParties",rg_for_json nestedparties_to_json x.f_AllocGrp_NestedParties) :: (("MiscFeesGrp",rg_for_json miscfeesgrp_to_json x.f_AllocGrp_MiscFeesGrp) :: (("ClrInstGrp",rg_for_json clrinstgrp_to_json x.f_AllocGrp_ClrInstGrp) :: []))))))))))))))))))))))))))))) -;; [@@@logic] diff --git a/src-protocol-exts-pp/full_app_tags_decoder.iml b/src-protocol-exts-pp/full_app_tags_decoder.iml index 83019056..0c1bed00 100644 --- a/src-protocol-exts-pp/full_app_tags_decoder.iml +++ b/src-protocol-exts-pp/full_app_tags_decoder.iml @@ -10,13 +10,32 @@ open Full_app_tags;; let full_app_string_to_msg_tag (tag) = (match tag with - | _ -> None + | "NewOrderSingle" -> (Some Full_Msg_NewOrderSingle_Tag) + | "ExecutionReport" -> (Some Full_Msg_ExecutionReport_Tag) + | _ -> (None) ) ;; let full_app_string_to_field_tag (tag) = (match tag with - | _ -> None + | "ClOrdID" -> (Some Full_Field_ClOrdID_Tag) + | "Parties" -> (Some Full_Field_Parties_Tag) + | "Account" -> (Some Full_Field_Account_Tag) + | "ExecInst" -> (Some Full_Field_ExecInst_Tag) + | "Side" -> (Some Full_Field_Side_Tag) + | "TransactTime" -> (Some Full_Field_TransactTime_Tag) + | "OrderQtyData" -> (Some Full_Field_OrderQtyData_Tag) + | "OrdType" -> (Some Full_Field_OrdType_Tag) + | "Price" -> (Some Full_Field_Price_Tag) + | "SpreadProportion" -> (Some Full_Field_SpreadProportion_Tag) + | "OrderID" -> (Some Full_Field_OrderID_Tag) + | "ExecID" -> (Some Full_Field_ExecID_Tag) + | "ExecType" -> (Some Full_Field_ExecType_Tag) + | "OrdStatus" -> (Some Full_Field_OrdStatus_Tag) + | "LeavesQty" -> (Some Full_Field_LeavesQty_Tag) + | "CumQty" -> (Some Full_Field_CumQty_Tag) + | "Text" -> (Some Full_Field_Text_Tag) + | _ -> (None) ) ;; diff --git a/src-protocol-exts-pp/full_app_tags_json.iml b/src-protocol-exts-pp/full_app_tags_json.iml index 08ea1b35..8bd22346 100644 --- a/src-protocol-exts-pp/full_app_tags_json.iml +++ b/src-protocol-exts-pp/full_app_tags_json.iml @@ -1,391 +1,37 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "../src-protocol-exts/full_app_tags.iml"] +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-protocol-exts/full_app_tags.iml"] open Full_app_tags;; +[@@@require "yojson"] open Yojson.Basic;; + let full_app_msg_tag_to_string (tag) = (match tag with - | Full_Msg_ExecutionReport_Tag -> "ExecutionReport" | Full_Msg_NewOrderSingle_Tag -> "NewOrderSingle" + | Full_Msg_ExecutionReport_Tag -> "ExecutionReport" ) ;; let full_app_field_tag_to_string (tag) = (match tag with - | Full_Field_OrderID_Tag -> "OrderID" - | Full_Field_SecondaryOrderID_Tag -> "SecondaryOrderID" - | Full_Field_SecondaryClOrdID_Tag -> "SecondaryClOrdID" - | Full_Field_SecondaryExecID_Tag -> "SecondaryExecID" | Full_Field_ClOrdID_Tag -> "ClOrdID" - | Full_Field_OrigClOrdID_Tag -> "OrigClOrdID" - | Full_Field_ClOrdLinkID_Tag -> "ClOrdLinkID" - | Full_Field_QuoteRespID_Tag -> "QuoteRespID" - | Full_Field_OrdStatusReqID_Tag -> "OrdStatusReqID" - | Full_Field_MassStatusReqID_Tag -> "MassStatusReqID" - | Full_Field_TotNumReports_Tag -> "TotNumReports" - | Full_Field_LastRptRequested_Tag -> "LastRptRequested" - | Full_Field_TradeOriginationDate_Tag -> "TradeOriginationDate" - | Full_Field_ListID_Tag -> "ListID" - | Full_Field_CrossID_Tag -> "CrossID" - | Full_Field_OrigCrossID_Tag -> "OrigCrossID" - | Full_Field_CrossType_Tag -> "CrossType" - | Full_Field_ExecID_Tag -> "ExecID" - | Full_Field_ExecRefID_Tag -> "ExecRefID" - | Full_Field_ExecType_Tag -> "ExecType" - | Full_Field_OrdStatus_Tag -> "OrdStatus" - | Full_Field_WorkingIndicator_Tag -> "WorkingIndicator" - | Full_Field_OrdRejReason_Tag -> "OrdRejReason" - | Full_Field_ExecRestatementReason_Tag -> "ExecRestatementReason" + | Full_Field_Parties_Tag -> "Parties" | Full_Field_Account_Tag -> "Account" - | Full_Field_AcctIDSource_Tag -> "AcctIDSource" - | Full_Field_AccountType_Tag -> "AccountType" - | Full_Field_DayBookingInst_Tag -> "DayBookingInst" - | Full_Field_BookingUnit_Tag -> "BookingUnit" - | Full_Field_PreallocMethod_Tag -> "PreallocMethod" - | Full_Field_SettlType_Tag -> "SettlType" - | Full_Field_SettlDate_Tag -> "SettlDate" - | Full_Field_CashMargin_Tag -> "CashMargin" - | Full_Field_ClearingFeeIndicator_Tag -> "ClearingFeeIndicator" + | Full_Field_ExecInst_Tag -> "ExecInst" | Full_Field_Side_Tag -> "Side" - | Full_Field_QtyType_Tag -> "QtyType" + | Full_Field_TransactTime_Tag -> "TransactTime" + | Full_Field_OrderQtyData_Tag -> "OrderQtyData" | Full_Field_OrdType_Tag -> "OrdType" - | Full_Field_PriceType_Tag -> "PriceType" | Full_Field_Price_Tag -> "Price" - | Full_Field_StopPx_Tag -> "StopPx" - | Full_Field_PeggedPrice_Tag -> "PeggedPrice" - | Full_Field_DiscretionPrice_Tag -> "DiscretionPrice" - | Full_Field_TargetStrategy_Tag -> "TargetStrategy" - | Full_Field_TargetStrategyParameters_Tag -> "TargetStrategyParameters" - | Full_Field_ParticipationRate_Tag -> "ParticipationRate" - | Full_Field_TargetStrategyPerformance_Tag -> "TargetStrategyPerformance" - | Full_Field_Currency_Tag -> "Currency" - | Full_Field_ComplianceID_Tag -> "ComplianceID" - | Full_Field_SolicitedFlag_Tag -> "SolicitedFlag" - | Full_Field_TimeInForce_Tag -> "TimeInForce" - | Full_Field_EffectiveTime_Tag -> "EffectiveTime" - | Full_Field_ExpireDate_Tag -> "ExpireDate" - | Full_Field_ExpireTime_Tag -> "ExpireTime" - | Full_Field_ExecInst_Tag -> "ExecInst" - | Full_Field_OrderCapacity_Tag -> "OrderCapacity" - | Full_Field_OrderRestrictions_Tag -> "OrderRestrictions" - | Full_Field_CustOrderCapacity_Tag -> "CustOrderCapacity" - | Full_Field_LastQty_Tag -> "LastQty" - | Full_Field_UnderlyingLastQty_Tag -> "UnderlyingLastQty" - | Full_Field_LastPx_Tag -> "LastPx" - | Full_Field_UnderlyingLastPx_Tag -> "UnderlyingLastPx" - | Full_Field_LastParPx_Tag -> "LastParPx" - | Full_Field_LastSpotRate_Tag -> "LastSpotRate" - | Full_Field_LastForwardPoints_Tag -> "LastForwardPoints" - | Full_Field_LastMkt_Tag -> "LastMkt" - | Full_Field_TradingSessionID_Tag -> "TradingSessionID" - | Full_Field_TradingSessionSubID_Tag -> "TradingSessionSubID" - | Full_Field_TimeBracket_Tag -> "TimeBracket" - | Full_Field_LastCapacity_Tag -> "LastCapacity" + | Full_Field_SpreadProportion_Tag -> "SpreadProportion" + | Full_Field_OrderID_Tag -> "OrderID" + | Full_Field_ExecID_Tag -> "ExecID" + | Full_Field_ExecType_Tag -> "ExecType" + | Full_Field_OrdStatus_Tag -> "OrdStatus" | Full_Field_LeavesQty_Tag -> "LeavesQty" | Full_Field_CumQty_Tag -> "CumQty" - | Full_Field_AvgPx_Tag -> "AvgPx" - | Full_Field_DayOrderQty_Tag -> "DayOrderQty" - | Full_Field_DayCumQty_Tag -> "DayCumQty" - | Full_Field_DayAvgPx_Tag -> "DayAvgPx" - | Full_Field_GTBookingInst_Tag -> "GTBookingInst" - | Full_Field_TradeDate_Tag -> "TradeDate" - | Full_Field_TransactTime_Tag -> "TransactTime" - | Full_Field_ReportToExch_Tag -> "ReportToExch" - | Full_Field_GrossTradeAmt_Tag -> "GrossTradeAmt" - | Full_Field_NumDaysInterest_Tag -> "NumDaysInterest" - | Full_Field_ExDate_Tag -> "ExDate" - | Full_Field_AccruedInterestRate_Tag -> "AccruedInterestRate" - | Full_Field_AccruedInterestAmt_Tag -> "AccruedInterestAmt" - | Full_Field_InterestAtMaturity_Tag -> "InterestAtMaturity" - | Full_Field_EndAccruedInterestAmt_Tag -> "EndAccruedInterestAmt" - | Full_Field_StartCash_Tag -> "StartCash" - | Full_Field_EndCash_Tag -> "EndCash" - | Full_Field_TradedFlatSwitch_Tag -> "TradedFlatSwitch" - | Full_Field_BasisFeatureDate_Tag -> "BasisFeatureDate" - | Full_Field_BasisFeaturePrice_Tag -> "BasisFeaturePrice" - | Full_Field_Concession_Tag -> "Concession" - | Full_Field_TotalTakedown_Tag -> "TotalTakedown" - | Full_Field_NetMoney_Tag -> "NetMoney" - | Full_Field_SettlCurrAmt_Tag -> "SettlCurrAmt" - | Full_Field_SettlCurrency_Tag -> "SettlCurrency" - | Full_Field_SettlCurrFxRate_Tag -> "SettlCurrFxRate" - | Full_Field_SettlCurrFxRateCalc_Tag -> "SettlCurrFxRateCalc" - | Full_Field_HandlInst_Tag -> "HandlInst" - | Full_Field_MinQty_Tag -> "MinQty" - | Full_Field_MaxFloor_Tag -> "MaxFloor" - | Full_Field_PositionEffect_Tag -> "PositionEffect" - | Full_Field_MaxShow_Tag -> "MaxShow" - | Full_Field_BookingType_Tag -> "BookingType" | Full_Field_Text_Tag -> "Text" - | Full_Field_EncodedTextLen_Tag -> "EncodedTextLen" - | Full_Field_EncodedText_Tag -> "EncodedText" - | Full_Field_SettlDate2_Tag -> "SettlDate2" - | Full_Field_OrderQty2_Tag -> "OrderQty2" - | Full_Field_LastForwardPoints2_Tag -> "LastForwardPoints2" - | Full_Field_MultiLegReportingType_Tag -> "MultiLegReportingType" - | Full_Field_CancellationRights_Tag -> "CancellationRights" - | Full_Field_MoneyLaunderingStatus_Tag -> "MoneyLaunderingStatus" - | Full_Field_RegistID_Tag -> "RegistID" - | Full_Field_Designation_Tag -> "Designation" - | Full_Field_TransBkdTime_Tag -> "TransBkdTime" - | Full_Field_ExecValuationPoint_Tag -> "ExecValuationPoint" - | Full_Field_ExecPriceType_Tag -> "ExecPriceType" - | Full_Field_ExecPriceAdjustment_Tag -> "ExecPriceAdjustment" - | Full_Field_PriorityIndicator_Tag -> "PriorityIndicator" - | Full_Field_PriceImprovement_Tag -> "PriceImprovement" - | Full_Field_LastLiquidityInd_Tag -> "LastLiquidityInd" - | Full_Field_CopyMsgIndicator_Tag -> "CopyMsgIndicator" - | Full_Field_NoPartyIDs_Tag -> "NoPartyIDs" - | Full_Field_PartyID_Tag -> "PartyID" - | Full_Field_PartyIDSource_Tag -> "PartyIDSource" - | Full_Field_PartyRole_Tag -> "PartyRole" - | Full_Field_NoPartySubIDs_Tag -> "NoPartySubIDs" - | Full_Field_PartySubID_Tag -> "PartySubID" - | Full_Field_PartySubIDType_Tag -> "PartySubIDType" - | Full_Field_NoContraBrokers_Tag -> "NoContraBrokers" - | Full_Field_ContraBroker_Tag -> "ContraBroker" - | Full_Field_ContraTrader_Tag -> "ContraTrader" - | Full_Field_ContraTradeQty_Tag -> "ContraTradeQty" - | Full_Field_ContraTradeTime_Tag -> "ContraTradeTime" - | Full_Field_ContraLegRefID_Tag -> "ContraLegRefID" - | Full_Field_Symbol_Tag -> "Symbol" - | Full_Field_SymbolSfx_Tag -> "SymbolSfx" - | Full_Field_SecurityID_Tag -> "SecurityID" - | Full_Field_SecurityIDSource_Tag -> "SecurityIDSource" - | Full_Field_Product_Tag -> "Product" - | Full_Field_CFICode_Tag -> "CFICode" - | Full_Field_SecurityType_Tag -> "SecurityType" - | Full_Field_SecuritySubType_Tag -> "SecuritySubType" - | Full_Field_MaturityMonthYear_Tag -> "MaturityMonthYear" - | Full_Field_MaturityDate_Tag -> "MaturityDate" - | Full_Field_CouponPaymentDate_Tag -> "CouponPaymentDate" - | Full_Field_IssueDate_Tag -> "IssueDate" - | Full_Field_RepoCollateralSecurityType_Tag -> "RepoCollateralSecurityType" - | Full_Field_RepurchaseTerm_Tag -> "RepurchaseTerm" - | Full_Field_RepurchaseRate_Tag -> "RepurchaseRate" - | Full_Field_Factor_Tag -> "Factor" - | Full_Field_CreditRating_Tag -> "CreditRating" - | Full_Field_InstrRegistry_Tag -> "InstrRegistry" - | Full_Field_CountryOfIssue_Tag -> "CountryOfIssue" - | Full_Field_StateOrProvinceOfIssue_Tag -> "StateOrProvinceOfIssue" - | Full_Field_LocaleOfIssue_Tag -> "LocaleOfIssue" - | Full_Field_RedemptionDate_Tag -> "RedemptionDate" - | Full_Field_StrikePrice_Tag -> "StrikePrice" - | Full_Field_StrikeCurrency_Tag -> "StrikeCurrency" - | Full_Field_OptAttribute_Tag -> "OptAttribute" - | Full_Field_ContractMultiplier_Tag -> "ContractMultiplier" - | Full_Field_CouponRate_Tag -> "CouponRate" - | Full_Field_SecurityExchange_Tag -> "SecurityExchange" - | Full_Field_Issuer_Tag -> "Issuer" - | Full_Field_EncodedIssuerLen_Tag -> "EncodedIssuerLen" - | Full_Field_EncodedIssuer_Tag -> "EncodedIssuer" - | Full_Field_SecurityDesc_Tag -> "SecurityDesc" - | Full_Field_EncodedSecurityDescLen_Tag -> "EncodedSecurityDescLen" - | Full_Field_EncodedSecurityDesc_Tag -> "EncodedSecurityDesc" - | Full_Field_Pool_Tag -> "Pool" - | Full_Field_ContractSettlMonth_Tag -> "ContractSettlMonth" - | Full_Field_CPProgram_Tag -> "CPProgram" - | Full_Field_CPRegType_Tag -> "CPRegType" - | Full_Field_DatedDate_Tag -> "DatedDate" - | Full_Field_InterestAccrualDate_Tag -> "InterestAccrualDate" - | Full_Field_NoSecurityAltID_Tag -> "NoSecurityAltID" - | Full_Field_SecurityAltID_Tag -> "SecurityAltID" - | Full_Field_SecurityAltIDSource_Tag -> "SecurityAltIDSource" - | Full_Field_NoEvents_Tag -> "NoEvents" - | Full_Field_EventType_Tag -> "EventType" - | Full_Field_EventDate_Tag -> "EventDate" - | Full_Field_EventPx_Tag -> "EventPx" - | Full_Field_EventText_Tag -> "EventText" - | Full_Field_AgreementDesc_Tag -> "AgreementDesc" - | Full_Field_AgreementID_Tag -> "AgreementID" - | Full_Field_AgreementDate_Tag -> "AgreementDate" - | Full_Field_AgreementCurrency_Tag -> "AgreementCurrency" - | Full_Field_TerminationType_Tag -> "TerminationType" - | Full_Field_StartDate_Tag -> "StartDate" - | Full_Field_EndDate_Tag -> "EndDate" - | Full_Field_DeliveryType_Tag -> "DeliveryType" - | Full_Field_MarginRatio_Tag -> "MarginRatio" - | Full_Field_NoUnderlyings_Tag -> "NoUnderlyings" - | Full_Field_UnderlyingSymbol_Tag -> "UnderlyingSymbol" - | Full_Field_UnderlyingSymbolSfx_Tag -> "UnderlyingSymbolSfx" - | Full_Field_UnderlyingSecurityID_Tag -> "UnderlyingSecurityID" - | Full_Field_UnderlyingSecurityIDSource_Tag -> "UnderlyingSecurityIDSource" - | Full_Field_UnderlyingProduct_Tag -> "UnderlyingProduct" - | Full_Field_UnderlyingCFICode_Tag -> "UnderlyingCFICode" - | Full_Field_UnderlyingSecurityType_Tag -> "UnderlyingSecurityType" - | Full_Field_UnderlyingSecuritySubType_Tag -> "UnderlyingSecuritySubType" - | Full_Field_UnderlyingMaturityMonthYear_Tag -> "UnderlyingMaturityMonthYear" - | Full_Field_UnderlyingMaturityDate_Tag -> "UnderlyingMaturityDate" - | Full_Field_UnderlyingCouponPaymentDate_Tag -> "UnderlyingCouponPaymentDate" - | Full_Field_UnderlyingIssueDate_Tag -> "UnderlyingIssueDate" - | Full_Field_UnderlyingRepoCollateralSecurityType_Tag -> "UnderlyingRepoCollateralSecurityType" - | Full_Field_UnderlyingRepurchaseTerm_Tag -> "UnderlyingRepurchaseTerm" - | Full_Field_UnderlyingRepurchaseRate_Tag -> "UnderlyingRepurchaseRate" - | Full_Field_UnderlyingFactor_Tag -> "UnderlyingFactor" - | Full_Field_UnderlyingCreditRating_Tag -> "UnderlyingCreditRating" - | Full_Field_UnderlyingInstrRegistry_Tag -> "UnderlyingInstrRegistry" - | Full_Field_UnderlyingCountryOfIssue_Tag -> "UnderlyingCountryOfIssue" - | Full_Field_UnderlyingStateOrProvinceOfIssue_Tag -> "UnderlyingStateOrProvinceOfIssue" - | Full_Field_UnderlyingLocaleOfIssue_Tag -> "UnderlyingLocaleOfIssue" - | Full_Field_UnderlyingRedemptionDate_Tag -> "UnderlyingRedemptionDate" - | Full_Field_UnderlyingStrikePrice_Tag -> "UnderlyingStrikePrice" - | Full_Field_UnderlyingStrikeCurrency_Tag -> "UnderlyingStrikeCurrency" - | Full_Field_UnderlyingOptAttribute_Tag -> "UnderlyingOptAttribute" - | Full_Field_UnderlyingContractMultiplier_Tag -> "UnderlyingContractMultiplier" - | Full_Field_UnderlyingCouponRate_Tag -> "UnderlyingCouponRate" - | Full_Field_UnderlyingSecurityExchange_Tag -> "UnderlyingSecurityExchange" - | Full_Field_UnderlyingIssuer_Tag -> "UnderlyingIssuer" - | Full_Field_EncodedUnderlyingIssuerLen_Tag -> "EncodedUnderlyingIssuerLen" - | Full_Field_EncodedUnderlyingIssuer_Tag -> "EncodedUnderlyingIssuer" - | Full_Field_UnderlyingSecurityDesc_Tag -> "UnderlyingSecurityDesc" - | Full_Field_EncodedUnderlyingSecurityDescLen_Tag -> "EncodedUnderlyingSecurityDescLen" - | Full_Field_EncodedUnderlyingSecurityDesc_Tag -> "EncodedUnderlyingSecurityDesc" - | Full_Field_UnderlyingCPProgram_Tag -> "UnderlyingCPProgram" - | Full_Field_UnderlyingCPRegType_Tag -> "UnderlyingCPRegType" - | Full_Field_UnderlyingCurrency_Tag -> "UnderlyingCurrency" - | Full_Field_UnderlyingQty_Tag -> "UnderlyingQty" - | Full_Field_UnderlyingPx_Tag -> "UnderlyingPx" - | Full_Field_UnderlyingDirtyPrice_Tag -> "UnderlyingDirtyPrice" - | Full_Field_UnderlyingEndPrice_Tag -> "UnderlyingEndPrice" - | Full_Field_UnderlyingStartValue_Tag -> "UnderlyingStartValue" - | Full_Field_UnderlyingCurrentValue_Tag -> "UnderlyingCurrentValue" - | Full_Field_UnderlyingEndValue_Tag -> "UnderlyingEndValue" - | Full_Field_NoUnderlyingSecurityAltID_Tag -> "NoUnderlyingSecurityAltID" - | Full_Field_UnderlyingSecurityAltID_Tag -> "UnderlyingSecurityAltID" - | Full_Field_UnderlyingSecurityAltIDSource_Tag -> "UnderlyingSecurityAltIDSource" - | Full_Field_NoUnderlyingStips_Tag -> "NoUnderlyingStips" - | Full_Field_UnderlyingStipType_Tag -> "UnderlyingStipType" - | Full_Field_UnderlyingStipValue_Tag -> "UnderlyingStipValue" - | Full_Field_NoStipulations_Tag -> "NoStipulations" - | Full_Field_StipulationType_Tag -> "StipulationType" - | Full_Field_StipulationValue_Tag -> "StipulationValue" - | Full_Field_OrderQty_Tag -> "OrderQty" - | Full_Field_CashOrderQty_Tag -> "CashOrderQty" - | Full_Field_OrderPercent_Tag -> "OrderPercent" - | Full_Field_RoundingDirection_Tag -> "RoundingDirection" - | Full_Field_RoundingModulus_Tag -> "RoundingModulus" - | Full_Field_PegOffsetValue_Tag -> "PegOffsetValue" - | Full_Field_PegMoveType_Tag -> "PegMoveType" - | Full_Field_PegOffsetType_Tag -> "PegOffsetType" - | Full_Field_PegLimitType_Tag -> "PegLimitType" - | Full_Field_PegRoundDirection_Tag -> "PegRoundDirection" - | Full_Field_PegScope_Tag -> "PegScope" - | Full_Field_DiscretionInst_Tag -> "DiscretionInst" - | Full_Field_DiscretionOffsetValue_Tag -> "DiscretionOffsetValue" - | Full_Field_DiscretionMoveType_Tag -> "DiscretionMoveType" - | Full_Field_DiscretionOffsetType_Tag -> "DiscretionOffsetType" - | Full_Field_DiscretionLimitType_Tag -> "DiscretionLimitType" - | Full_Field_DiscretionRoundDirection_Tag -> "DiscretionRoundDirection" - | Full_Field_DiscretionScope_Tag -> "DiscretionScope" - | Full_Field_Commission_Tag -> "Commission" - | Full_Field_CommType_Tag -> "CommType" - | Full_Field_CommCurrency_Tag -> "CommCurrency" - | Full_Field_FundRenewWaiv_Tag -> "FundRenewWaiv" - | Full_Field_Spread_Tag -> "Spread" - | Full_Field_BenchmarkCurveCurrency_Tag -> "BenchmarkCurveCurrency" - | Full_Field_BenchmarkCurveName_Tag -> "BenchmarkCurveName" - | Full_Field_BenchmarkCurvePoint_Tag -> "BenchmarkCurvePoint" - | Full_Field_BenchmarkPrice_Tag -> "BenchmarkPrice" - | Full_Field_BenchmarkPriceType_Tag -> "BenchmarkPriceType" - | Full_Field_BenchmarkSecurityID_Tag -> "BenchmarkSecurityID" - | Full_Field_BenchmarkSecurityIDSource_Tag -> "BenchmarkSecurityIDSource" - | Full_Field_YieldType_Tag -> "YieldType" - | Full_Field_Yield_Tag -> "Yield" - | Full_Field_YieldCalcDate_Tag -> "YieldCalcDate" - | Full_Field_YieldRedemptionDate_Tag -> "YieldRedemptionDate" - | Full_Field_YieldRedemptionPrice_Tag -> "YieldRedemptionPrice" - | Full_Field_YieldRedemptionPriceType_Tag -> "YieldRedemptionPriceType" - | Full_Field_NoContAmts_Tag -> "NoContAmts" - | Full_Field_ContAmtType_Tag -> "ContAmtType" - | Full_Field_ContAmtValue_Tag -> "ContAmtValue" - | Full_Field_ContAmtCurr_Tag -> "ContAmtCurr" - | Full_Field_NoLegs_Tag -> "NoLegs" - | Full_Field_LegQty_Tag -> "LegQty" - | Full_Field_LegSwapType_Tag -> "LegSwapType" - | Full_Field_LegPositionEffect_Tag -> "LegPositionEffect" - | Full_Field_LegCoveredOrUncovered_Tag -> "LegCoveredOrUncovered" - | Full_Field_LegRefID_Tag -> "LegRefID" - | Full_Field_LegPrice_Tag -> "LegPrice" - | Full_Field_LegSettlType_Tag -> "LegSettlType" - | Full_Field_LegSettlDate_Tag -> "LegSettlDate" - | Full_Field_LegLastPx_Tag -> "LegLastPx" - | Full_Field_LegSymbol_Tag -> "LegSymbol" - | Full_Field_LegSymbolSfx_Tag -> "LegSymbolSfx" - | Full_Field_LegSecurityID_Tag -> "LegSecurityID" - | Full_Field_LegSecurityIDSource_Tag -> "LegSecurityIDSource" - | Full_Field_LegProduct_Tag -> "LegProduct" - | Full_Field_LegCFICode_Tag -> "LegCFICode" - | Full_Field_LegSecurityType_Tag -> "LegSecurityType" - | Full_Field_LegSecuritySubType_Tag -> "LegSecuritySubType" - | Full_Field_LegMaturityMonthYear_Tag -> "LegMaturityMonthYear" - | Full_Field_LegMaturityDate_Tag -> "LegMaturityDate" - | Full_Field_LegCouponPaymentDate_Tag -> "LegCouponPaymentDate" - | Full_Field_LegIssueDate_Tag -> "LegIssueDate" - | Full_Field_LegRepoCollateralSecurityType_Tag -> "LegRepoCollateralSecurityType" - | Full_Field_LegRepurchaseTerm_Tag -> "LegRepurchaseTerm" - | Full_Field_LegRepurchaseRate_Tag -> "LegRepurchaseRate" - | Full_Field_LegFactor_Tag -> "LegFactor" - | Full_Field_LegCreditRating_Tag -> "LegCreditRating" - | Full_Field_LegInstrRegistry_Tag -> "LegInstrRegistry" - | Full_Field_LegCountryOfIssue_Tag -> "LegCountryOfIssue" - | Full_Field_LegStateOrProvinceOfIssue_Tag -> "LegStateOrProvinceOfIssue" - | Full_Field_LegLocaleOfIssue_Tag -> "LegLocaleOfIssue" - | Full_Field_LegRedemptionDate_Tag -> "LegRedemptionDate" - | Full_Field_LegStrikePrice_Tag -> "LegStrikePrice" - | Full_Field_LegStrikeCurrency_Tag -> "LegStrikeCurrency" - | Full_Field_LegOptAttribute_Tag -> "LegOptAttribute" - | Full_Field_LegContractMultiplier_Tag -> "LegContractMultiplier" - | Full_Field_LegCouponRate_Tag -> "LegCouponRate" - | Full_Field_LegSecurityExchange_Tag -> "LegSecurityExchange" - | Full_Field_LegIssuer_Tag -> "LegIssuer" - | Full_Field_EncodedLegIssuerLen_Tag -> "EncodedLegIssuerLen" - | Full_Field_EncodedLegIssuer_Tag -> "EncodedLegIssuer" - | Full_Field_LegSecurityDesc_Tag -> "LegSecurityDesc" - | Full_Field_EncodedLegSecurityDescLen_Tag -> "EncodedLegSecurityDescLen" - | Full_Field_EncodedLegSecurityDesc_Tag -> "EncodedLegSecurityDesc" - | Full_Field_LegRatioQty_Tag -> "LegRatioQty" - | Full_Field_LegSide_Tag -> "LegSide" - | Full_Field_LegCurrency_Tag -> "LegCurrency" - | Full_Field_LegPool_Tag -> "LegPool" - | Full_Field_LegDatedDate_Tag -> "LegDatedDate" - | Full_Field_LegContractSettlMonth_Tag -> "LegContractSettlMonth" - | Full_Field_LegInterestAccrualDate_Tag -> "LegInterestAccrualDate" - | Full_Field_NoLegSecurityAltID_Tag -> "NoLegSecurityAltID" - | Full_Field_LegSecurityAltID_Tag -> "LegSecurityAltID" - | Full_Field_LegSecurityAltIDSource_Tag -> "LegSecurityAltIDSource" - | Full_Field_NoLegStipulations_Tag -> "NoLegStipulations" - | Full_Field_LegStipulationType_Tag -> "LegStipulationType" - | Full_Field_LegStipulationValue_Tag -> "LegStipulationValue" - | Full_Field_NoNestedPartyIDs_Tag -> "NoNestedPartyIDs" - | Full_Field_NestedPartyID_Tag -> "NestedPartyID" - | Full_Field_NestedPartyIDSource_Tag -> "NestedPartyIDSource" - | Full_Field_NestedPartyRole_Tag -> "NestedPartyRole" - | Full_Field_NoNestedPartySubIDs_Tag -> "NoNestedPartySubIDs" - | Full_Field_NestedPartySubID_Tag -> "NestedPartySubID" - | Full_Field_NestedPartySubIDType_Tag -> "NestedPartySubIDType" - | Full_Field_NoMiscFees_Tag -> "NoMiscFees" - | Full_Field_MiscFeeAmt_Tag -> "MiscFeeAmt" - | Full_Field_MiscFeeCurr_Tag -> "MiscFeeCurr" - | Full_Field_MiscFeeType_Tag -> "MiscFeeType" - | Full_Field_MiscFeeBasis_Tag -> "MiscFeeBasis" - | Full_Field_AllocID_Tag -> "AllocID" - | Full_Field_ExDestination_Tag -> "ExDestination" - | Full_Field_ProcessCode_Tag -> "ProcessCode" - | Full_Field_PrevClosePx_Tag -> "PrevClosePx" - | Full_Field_LocateReqd_Tag -> "LocateReqd" - | Full_Field_IOIID_Tag -> "IOIID" - | Full_Field_QuoteID_Tag -> "QuoteID" - | Full_Field_ForexReq_Tag -> "ForexReq" - | Full_Field_Price2_Tag -> "Price2" - | Full_Field_CoveredOrUncovered_Tag -> "CoveredOrUncovered" - | Full_Field_NoAllocs_Tag -> "NoAllocs" - | Full_Field_AllocAccount_Tag -> "AllocAccount" - | Full_Field_AllocAcctIDSource_Tag -> "AllocAcctIDSource" - | Full_Field_AllocSettlCurrency_Tag -> "AllocSettlCurrency" - | Full_Field_IndividualAllocID_Tag -> "IndividualAllocID" - | Full_Field_AllocQty_Tag -> "AllocQty" - | Full_Field_NoTradingSessions_Tag -> "NoTradingSessions" ) ;; @@ -410,4 +56,5 @@ let full_app_field_tag_opt_to_json (tag) : json = | Some tag -> (full_app_field_tag_to_json tag) ) ;; + [@@@logic] diff --git a/src-protocol-exts-pp/json_generator_utils.iml b/src-protocol-exts-pp/json_generator_utils.iml index ee885afc..efdde856 100644 --- a/src-protocol-exts-pp/json_generator_utils.iml +++ b/src-protocol-exts-pp/json_generator_utils.iml @@ -1,7 +1,9 @@ -(* Imandra Inc. copyright 2019 *) +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@require "yojson"] open Yojson.Basic;; + let assoc_filter_nulls (x) : json = `Assoc (List.filter (function (_,`Null) -> false |_ -> true ) x) @@ -9,8 +11,9 @@ let assoc_filter_nulls (x) : json = let rg_for_json (f) (lst) : json = (match lst with - | [] -> `Null + | [] -> (`List []) | lst -> (`List (List.map f lst)) ) ;; + [@@@logic] diff --git a/src-protocol-exts-pp/parse_app_enums.iml b/src-protocol-exts-pp/parse_app_enums.iml index 261c7e05..2c3dacc7 100644 --- a/src-protocol-exts-pp/parse_app_enums.iml +++ b/src-protocol-exts-pp/parse_app_enums.iml @@ -1,848 +1,12 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "../src-protocol-exts/full_app_enums.iml"] -[@@@import "../src-core-pp/parser_utils.iml"] +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-protocol-exts/full_app_enums.iml"] open Full_app_enums;; +[@@@import "../src-core-pp/parser_utils.iml"] open Parser_utils.Parser;; -let parse_week (str) = - (match str with - | "noweek" -> (Some (FIX_week_noweek)) - | "w1" -> (Some (FIX_week_w1)) - | "w2" -> (Some (FIX_week_w2)) - | "w3" -> (Some (FIX_week_w3)) - | "w4" -> (Some (FIX_week_w4)) - | "w5" -> (Some (FIX_week_w5)) - | _ -> (None) - ) -;; - -let parse_AccountType (str) = - (match str with - | "1" -> (Some (FIX_AccountType_CarriedCustomerSide)) - | "2" -> (Some (FIX_AccountType_CarriedNonCustomerSide)) - | "3" -> (Some (FIX_AccountType_HouseTrader)) - | "4" -> (Some (FIX_AccountType_FloorTrader)) - | "6" -> (Some (FIX_AccountType_CarriedNonCustomerSideCrossMargined)) - | "7" -> (Some (FIX_AccountType_HouseTraderCrossMargined)) - | "8" -> (Some (FIX_AccountType_JointBackOfficeAccount)) - | _ -> (None) - ) -;; - -let parse_AcctIDSource (str) = - (match str with - | "1" -> (Some (FIX_AcctIDSource_BIC)) - | "2" -> (Some (FIX_AcctIDSource_SIDCode)) - | "3" -> (Some (FIX_AcctIDSource_TFM)) - | "4" -> (Some (FIX_AcctIDSource_OMGEO)) - | "5" -> (Some (FIX_AcctIDSource_DTCCCode)) - | "99" -> (Some (FIX_AcctIDSource_Other)) - | _ -> (None) - ) -;; - -let parse_Adjustment (str) = - (match str with - | "1" -> (Some (FIX_Adjustment_Cancel)) - | "2" -> (Some (FIX_Adjustment_Error)) - | "3" -> (Some (FIX_Adjustment_Correction)) - | _ -> (None) - ) -;; - -let parse_AdjustmentType (str) = - (match str with - | "0" -> (Some (FIX_AdjustmentType_ProcessRequestAsMarginDisposition)) - | "1" -> (Some (FIX_AdjustmentType_DeltaPlus)) - | "2" -> (Some (FIX_AdjustmentType_DeltaMinus)) - | "3" -> (Some (FIX_AdjustmentType_Final)) - | _ -> (None) - ) -;; - -let parse_AdvSide (str) = - (match str with - | "B" -> (Some (FIX_AdvSide_Buy)) - | "S" -> (Some (FIX_AdvSide_Sell)) - | "X" -> (Some (FIX_AdvSide_Cross)) - | "T" -> (Some (FIX_AdvSide_Trade)) - | _ -> (None) - ) -;; - -let parse_AdvTransType (str) = - (match str with - | "N" -> (Some (FIX_AdvTransType_New)) - | "C" -> (Some (FIX_AdvTransType_Cancel)) - | "R" -> (Some (FIX_AdvTransType_Replace)) - | _ -> (None) - ) -;; - -let parse_AffirmStatus (str) = - (match str with - | "1" -> (Some (FIX_AffirmStatus_Received)) - | "2" -> (Some (FIX_AffirmStatus_ConfirmRejected)) - | "3" -> (Some (FIX_AffirmStatus_Affirmed)) - | _ -> (None) - ) -;; - -let parse_AggregatedBook (str) = - (match str with - | "Y" -> (Some (FIX_AggregatedBook_BookEntriesToBeAggregated)) - | "N" -> (Some (FIX_AggregatedBook_BookEntriesShouldNotBeAggregated)) - | _ -> (None) - ) -;; - -let parse_AllocAccountType (str) = - (match str with - | "1" -> (Some (FIX_AllocAccountType_CarriedCustomerSide)) - | "2" -> (Some (FIX_AllocAccountType_CarriedNonCustomerSide)) - | "3" -> (Some (FIX_AllocAccountType_HouseTrader)) - | "4" -> (Some (FIX_AllocAccountType_FloorTrader)) - | "6" -> (Some (FIX_AllocAccountType_CarriedNonCustomerSideCrossMargined)) - | "7" -> (Some (FIX_AllocAccountType_HouseTraderCrossMargined)) - | "8" -> (Some (FIX_AllocAccountType_JointBackOfficeAccount)) - | _ -> (None) - ) -;; - -let parse_AllocCancReplaceReason (str) = - (match str with - | "1" -> (Some (FIX_AllocCancReplaceReason_OriginalDetailsIncomplete)) - | "2" -> (Some (FIX_AllocCancReplaceReason_ChangeInUnderlyingOrderDetails)) - | "99" -> (Some (FIX_AllocCancReplaceReason_Other)) - | _ -> (None) - ) -;; - -let parse_AllocHandlInst (str) = - (match str with - | "1" -> (Some (FIX_AllocHandlInst_Match)) - | "2" -> (Some (FIX_AllocHandlInst_Forward)) - | "3" -> (Some (FIX_AllocHandlInst_ForwardAndMatch)) - | _ -> (None) - ) -;; - -let parse_AllocIntermedReqType (str) = - (match str with - | "1" -> (Some (FIX_AllocIntermedReqType_PendingAccept)) - | "2" -> (Some (FIX_AllocIntermedReqType_PendingRelease)) - | "3" -> (Some (FIX_AllocIntermedReqType_PendingReversal)) - | "4" -> (Some (FIX_AllocIntermedReqType_Accept)) - | "5" -> (Some (FIX_AllocIntermedReqType_BlockLevelReject)) - | "6" -> (Some (FIX_AllocIntermedReqType_AccountLevelReject)) - | _ -> (None) - ) -;; - -let parse_AllocLinkType (str) = - (match str with - | "0" -> (Some (FIX_AllocLinkType_FXNetting)) - | "1" -> (Some (FIX_AllocLinkType_FXSwap)) - | _ -> (None) - ) -;; - -let parse_AllocNoOrdersType (str) = - (match str with - | "0" -> (Some (FIX_AllocNoOrdersType_NotSpecified)) - | "1" -> (Some (FIX_AllocNoOrdersType_ExplicitListProvided)) - | _ -> (None) - ) -;; - -let parse_AllocRejCode (str) = - (match str with - | "0" -> (Some (FIX_AllocRejCode_UnknownAccount)) - | "1" -> (Some (FIX_AllocRejCode_IncorrectQuantity)) - | "2" -> (Some (FIX_AllocRejCode_IncorrectAveragegPrice)) - | "3" -> (Some (FIX_AllocRejCode_UnknownExecutingBrokerMnemonic)) - | "4" -> (Some (FIX_AllocRejCode_CommissionDifference)) - | "5" -> (Some (FIX_AllocRejCode_UnknownOrderID)) - | "6" -> (Some (FIX_AllocRejCode_UnknownListID)) - | "7" -> (Some (FIX_AllocRejCode_OtherSeeText)) - | "8" -> (Some (FIX_AllocRejCode_IncorrectAllocatedQuantity)) - | "9" -> (Some (FIX_AllocRejCode_CalculationDifference)) - | "10" -> (Some (FIX_AllocRejCode_UnknownOrStaleExecID)) - | "11" -> (Some (FIX_AllocRejCode_MismatchedData)) - | "12" -> (Some (FIX_AllocRejCode_UnknownClOrdID)) - | "13" -> (Some (FIX_AllocRejCode_WarehouseRequestRejected)) - | _ -> (None) - ) -;; - -let parse_AllocReportType (str) = - (match str with - | "3" -> (Some (FIX_AllocReportType_SellsideCalculatedUsingPreliminary)) - | "4" -> (Some (FIX_AllocReportType_SellsideCalculatedWithoutPreliminary)) - | "5" -> (Some (FIX_AllocReportType_WarehouseRecap)) - | "8" -> (Some (FIX_AllocReportType_RequestToIntermediary)) - | _ -> (None) - ) -;; - -let parse_AllocSettlInstType (str) = - (match str with - | "0" -> (Some (FIX_AllocSettlInstType_UseDefaultInstructions)) - | "1" -> (Some (FIX_AllocSettlInstType_DeriveFromParametersProvided)) - | "2" -> (Some (FIX_AllocSettlInstType_FullDetailsProvided)) - | "3" -> (Some (FIX_AllocSettlInstType_SSIDBIDsProvided)) - | "4" -> (Some (FIX_AllocSettlInstType_PhoneForInstructions)) - | _ -> (None) - ) -;; - -let parse_AllocStatus (str) = - (match str with - | "0" -> (Some (FIX_AllocStatus_Accepted)) - | "1" -> (Some (FIX_AllocStatus_BlockLevelReject)) - | "2" -> (Some (FIX_AllocStatus_AccountLevelReject)) - | "3" -> (Some (FIX_AllocStatus_Received)) - | "4" -> (Some (FIX_AllocStatus_Incomplete)) - | "5" -> (Some (FIX_AllocStatus_RejectedByIntermediary)) - | _ -> (None) - ) -;; - -let parse_AllocTransType (str) = - (match str with - | "0" -> (Some (FIX_AllocTransType_New)) - | "1" -> (Some (FIX_AllocTransType_Replace)) - | "2" -> (Some (FIX_AllocTransType_Cancel)) - | _ -> (None) - ) -;; - -let parse_AllocType (str) = - (match str with - | "1" -> (Some (FIX_AllocType_Calculated)) - | "2" -> (Some (FIX_AllocType_Preliminary)) - | "5" -> (Some (FIX_AllocType_ReadyToBook)) - | "7" -> (Some (FIX_AllocType_WarehouseInstruction)) - | "8" -> (Some (FIX_AllocType_RequestToIntermediary)) - | _ -> (None) - ) -;; - -let parse_ApplQueueAction (str) = - (match str with - | "0" -> (Some (FIX_ApplQueueAction_NoActionTaken)) - | "1" -> (Some (FIX_ApplQueueAction_QueueFlushed)) - | "2" -> (Some (FIX_ApplQueueAction_OverlayLast)) - | "3" -> (Some (FIX_ApplQueueAction_EndSession)) - | _ -> (None) - ) -;; - -let parse_ApplQueueResolution (str) = - (match str with - | "0" -> (Some (FIX_ApplQueueResolution_NoActionTaken)) - | "1" -> (Some (FIX_ApplQueueResolution_QueueFlushed)) - | "2" -> (Some (FIX_ApplQueueResolution_OverlayLast)) - | "3" -> (Some (FIX_ApplQueueResolution_EndSession)) - | _ -> (None) - ) -;; - -let parse_AssignmentMethod (str) = - (match str with - | "R" -> (Some (FIX_AssignmentMethod_Random)) - | "P" -> (Some (FIX_AssignmentMethod_ProRata)) - | _ -> (None) - ) -;; - -let parse_AvgPxIndicator (str) = - (match str with - | "0" -> (Some (FIX_AvgPxIndicator_NoAveragePricing)) - | "1" -> (Some (FIX_AvgPxIndicator_Trade)) - | "2" -> (Some (FIX_AvgPxIndicator_LastTrade)) - | _ -> (None) - ) -;; - -let parse_BasisPxType (str) = - (match str with - | "2" -> (Some (FIX_BasisPxType_ClosingPriceAtMorningSession)) - | "3" -> (Some (FIX_BasisPxType_ClosingPrice)) - | "4" -> (Some (FIX_BasisPxType_CurrentPrice)) - | "5" -> (Some (FIX_BasisPxType_SQ)) - | "6" -> (Some (FIX_BasisPxType_VWAPThroughADay)) - | "7" -> (Some (FIX_BasisPxType_VWAPThroughAMorningSession)) - | "8" -> (Some (FIX_BasisPxType_VWAPThroughAnAfternoonSession)) - | "9" -> (Some (FIX_BasisPxType_VWAPThroughADayExcept)) - | "A" -> (Some (FIX_BasisPxType_VWAPThroughAMorningSessionExcept)) - | "B" -> (Some (FIX_BasisPxType_VWAPThroughAnAfternoonSessionExcept)) - | "C" -> (Some (FIX_BasisPxType_Strike)) - | "D" -> (Some (FIX_BasisPxType_Open)) - | "Z" -> (Some (FIX_BasisPxType_Others)) - | _ -> (None) - ) -;; - -let parse_BidDescriptorType (str) = - (match str with - | "1" -> (Some (FIX_BidDescriptorType_Sector)) - | "2" -> (Some (FIX_BidDescriptorType_Country)) - | "3" -> (Some (FIX_BidDescriptorType_Index)) - | _ -> (None) - ) -;; - -let parse_BidRequestTransType (str) = - (match str with - | "N" -> (Some (FIX_BidRequestTransType_New)) - | "C" -> (Some (FIX_BidRequestTransType_Cancel)) - | _ -> (None) - ) -;; - -let parse_BidTradeType (str) = - (match str with - | "R" -> (Some (FIX_BidTradeType_RiskTrade)) - | "G" -> (Some (FIX_BidTradeType_VWAPGuarantee)) - | "A" -> (Some (FIX_BidTradeType_Agency)) - | "J" -> (Some (FIX_BidTradeType_GuaranteedClose)) - | _ -> (None) - ) -;; - -let parse_BidType (str) = - (match str with - | "1" -> (Some (FIX_BidType_NonDisclosed)) - | "2" -> (Some (FIX_BidType_Disclosed)) - | "3" -> (Some (FIX_BidType_NoBiddingProcess)) - | _ -> (None) - ) -;; - -let parse_BookingType (str) = - (match str with - | "0" -> (Some (FIX_BookingType_RegularBooking)) - | "1" -> (Some (FIX_BookingType_CFD)) - | "2" -> (Some (FIX_BookingType_TotalReturnSwap)) - | _ -> (None) - ) -;; - -let parse_BookingUnit (str) = - (match str with - | "0" -> (Some (FIX_BookingUnit_EachPartialExecutionIsABookableUnit)) - | "1" -> (Some (FIX_BookingUnit_AggregatePartialExecutionsOnThisOrder)) - | "2" -> (Some (FIX_BookingUnit_AggregateExecutionsForThisSymbol)) - | _ -> (None) - ) -;; - -let parse_CPProgram (str) = - (match str with - | "1" -> (Some (FIX_CPProgram_Program3a3)) - | "2" -> (Some (FIX_CPProgram_Program42)) - | "99" -> (Some (FIX_CPProgram_Other)) - | _ -> (None) - ) -;; - -let parse_CancellationRights (str) = - (match str with - | "Y" -> (Some (FIX_CancellationRights_Yes)) - | "N" -> (Some (FIX_CancellationRights_NoExecutionOnly)) - | "M" -> (Some (FIX_CancellationRights_NoWaiverAgreement)) - | "O" -> (Some (FIX_CancellationRights_NoInstitutional)) - | _ -> (None) - ) -;; - -let parse_CashMargin (str) = - (match str with - | "1" -> (Some (FIX_CashMargin_Cash)) - | "2" -> (Some (FIX_CashMargin_MarginOpen)) - | "3" -> (Some (FIX_CashMargin_MarginClose)) - | _ -> (None) - ) -;; - -let parse_ClearingFeeIndicator (str) = - (match str with - | "B" -> (Some (FIX_ClearingFeeIndicator_CBOEMember)) - | "C" -> (Some (FIX_ClearingFeeIndicator_NonMemberAndCustomer)) - | "E" -> (Some (FIX_ClearingFeeIndicator_EquityMemberAndClearingMember)) - | "F" -> (Some (FIX_ClearingFeeIndicator_FullAndAssociateMember)) - | "H" -> (Some (FIX_ClearingFeeIndicator_Firms106HAnd106J)) - | "I" -> (Some (FIX_ClearingFeeIndicator_GIM)) - | "L" -> (Some (FIX_ClearingFeeIndicator_Lessee106FEmployees)) - | "M" -> (Some (FIX_ClearingFeeIndicator_AllOtherOwnershipTypes)) - | "1" -> (Some (FIX_ClearingFeeIndicator_FirstYearDelegate)) - | "2" -> (Some (FIX_ClearingFeeIndicator_SecondYearDelegate)) - | "3" -> (Some (FIX_ClearingFeeIndicator_ThirdYearDelegate)) - | "4" -> (Some (FIX_ClearingFeeIndicator_FourthYearDelegate)) - | "5" -> (Some (FIX_ClearingFeeIndicator_FifthYearDelegate)) - | "9" -> (Some (FIX_ClearingFeeIndicator_SixthYearDelegate)) - | _ -> (None) - ) -;; - -let parse_ClearingInstruction (str) = - (match str with - | "0" -> (Some (FIX_ClearingInstruction_ProcessNormally)) - | "1" -> (Some (FIX_ClearingInstruction_ExcludeFromAllNetting)) - | "2" -> (Some (FIX_ClearingInstruction_BilateralNettingOnly)) - | "3" -> (Some (FIX_ClearingInstruction_ExClearing)) - | "4" -> (Some (FIX_ClearingInstruction_SpecialTrade)) - | "5" -> (Some (FIX_ClearingInstruction_MultilateralNetting)) - | "6" -> (Some (FIX_ClearingInstruction_ClearAgainstCentralCounterparty)) - | "7" -> (Some (FIX_ClearingInstruction_ExcludeFromCentralCounterparty)) - | "8" -> (Some (FIX_ClearingInstruction_ManualMode)) - | "9" -> (Some (FIX_ClearingInstruction_AutomaticPostingMode)) - | "10" -> (Some (FIX_ClearingInstruction_AutomaticGiveUpMode)) - | "11" -> (Some (FIX_ClearingInstruction_QualifiedServiceRepresentativeQSR)) - | "12" -> (Some (FIX_ClearingInstruction_CustomerTrade)) - | "13" -> (Some (FIX_ClearingInstruction_SelfClearing)) - | _ -> (None) - ) -;; - -let parse_CollAction (str) = - (match str with - | "0" -> (Some (FIX_CollAction_Retain)) - | "1" -> (Some (FIX_CollAction_Add)) - | "2" -> (Some (FIX_CollAction_Remove)) - | _ -> (None) - ) -;; - -let parse_CollAsgnReason (str) = - (match str with - | "0" -> (Some (FIX_CollAsgnReason_Initial)) - | "1" -> (Some (FIX_CollAsgnReason_Scheduled)) - | "2" -> (Some (FIX_CollAsgnReason_TimeWarning)) - | "3" -> (Some (FIX_CollAsgnReason_MarginDeficiency)) - | "4" -> (Some (FIX_CollAsgnReason_MarginExcess)) - | "5" -> (Some (FIX_CollAsgnReason_ForwardCollateralDemand)) - | "6" -> (Some (FIX_CollAsgnReason_EventOfDefault)) - | "7" -> (Some (FIX_CollAsgnReason_AdverseTaxEvent)) - | _ -> (None) - ) -;; - -let parse_CollAsgnRejectReason (str) = - (match str with - | "0" -> (Some (FIX_CollAsgnRejectReason_UnknownDeal)) - | "1" -> (Some (FIX_CollAsgnRejectReason_UnknownOrInvalidInstrument)) - | "2" -> (Some (FIX_CollAsgnRejectReason_UnauthorizedTransaction)) - | "3" -> (Some (FIX_CollAsgnRejectReason_InsufficientCollateral)) - | "4" -> (Some (FIX_CollAsgnRejectReason_InvalidTypeOfCollateral)) - | "5" -> (Some (FIX_CollAsgnRejectReason_ExcessiveSubstitution)) - | "99" -> (Some (FIX_CollAsgnRejectReason_Other)) - | _ -> (None) - ) -;; - -let parse_CollAsgnRespType (str) = - (match str with - | "0" -> (Some (FIX_CollAsgnRespType_Received)) - | "1" -> (Some (FIX_CollAsgnRespType_Accepted)) - | "2" -> (Some (FIX_CollAsgnRespType_Declined)) - | "3" -> (Some (FIX_CollAsgnRespType_Rejected)) - | _ -> (None) - ) -;; - -let parse_CollAsgnTransType (str) = - (match str with - | "0" -> (Some (FIX_CollAsgnTransType_New)) - | "1" -> (Some (FIX_CollAsgnTransType_Replace)) - | "2" -> (Some (FIX_CollAsgnTransType_Cancel)) - | "3" -> (Some (FIX_CollAsgnTransType_Release)) - | "4" -> (Some (FIX_CollAsgnTransType_Reverse)) - | _ -> (None) - ) -;; - -let parse_CollInquiryQualifier (str) = - (match str with - | "0" -> (Some (FIX_CollInquiryQualifier_TradeDate)) - | "1" -> (Some (FIX_CollInquiryQualifier_GCInstrument)) - | "2" -> (Some (FIX_CollInquiryQualifier_CollateralInstrument)) - | "3" -> (Some (FIX_CollInquiryQualifier_SubstitutionEligible)) - | "4" -> (Some (FIX_CollInquiryQualifier_NotAssigned)) - | "5" -> (Some (FIX_CollInquiryQualifier_PartiallyAssigned)) - | "6" -> (Some (FIX_CollInquiryQualifier_FullyAssigned)) - | "7" -> (Some (FIX_CollInquiryQualifier_OutstandingTrades)) - | _ -> (None) - ) -;; - -let parse_CollInquiryResult (str) = - (match str with - | "0" -> (Some (FIX_CollInquiryResult_Successful)) - | "1" -> (Some (FIX_CollInquiryResult_InvalidOrUnknownInstrument)) - | "2" -> (Some (FIX_CollInquiryResult_InvalidOrUnknownCollateralType)) - | "3" -> (Some (FIX_CollInquiryResult_InvalidParties)) - | "4" -> (Some (FIX_CollInquiryResult_InvalidTransportTypeRequested)) - | "5" -> (Some (FIX_CollInquiryResult_InvalidDestinationRequested)) - | "6" -> (Some (FIX_CollInquiryResult_NoCollateralFoundForTheTradeSpecified)) - | "7" -> (Some (FIX_CollInquiryResult_NoCollateralFoundForTheOrderSpecified)) - | "8" -> (Some (FIX_CollInquiryResult_CollateralInquiryTypeNotSupported)) - | "9" -> (Some (FIX_CollInquiryResult_UnauthorizedForCollateralInquiry)) - | "99" -> (Some (FIX_CollInquiryResult_Other)) - | _ -> (None) - ) -;; - -let parse_CollInquiryStatus (str) = - (match str with - | "0" -> (Some (FIX_CollInquiryStatus_Accepted)) - | "1" -> (Some (FIX_CollInquiryStatus_AcceptedWithWarnings)) - | "2" -> (Some (FIX_CollInquiryStatus_Completed)) - | "3" -> (Some (FIX_CollInquiryStatus_CompletedWithWarnings)) - | "4" -> (Some (FIX_CollInquiryStatus_Rejected)) - | _ -> (None) - ) -;; - -let parse_CollStatus (str) = - (match str with - | "0" -> (Some (FIX_CollStatus_Unassigned)) - | "1" -> (Some (FIX_CollStatus_PartiallyAssigned)) - | "2" -> (Some (FIX_CollStatus_AssignmentProposed)) - | "3" -> (Some (FIX_CollStatus_Assigned)) - | "4" -> (Some (FIX_CollStatus_Challenged)) - | _ -> (None) - ) -;; - -let parse_CommType (str) = - (match str with - | "1" -> (Some (FIX_CommType_PerUnit)) - | "2" -> (Some (FIX_CommType_Percent)) - | "3" -> (Some (FIX_CommType_Absolute)) - | "4" -> (Some (FIX_CommType_PercentageWaivedCashDiscount)) - | "5" -> (Some (FIX_CommType_PercentageWaivedEnhancedUnits)) - | "6" -> (Some (FIX_CommType_PointsPerBondOrContract)) - | _ -> (None) - ) -;; - -let parse_ConfirmRejReason (str) = - (match str with - | "1" -> (Some (FIX_ConfirmRejReason_MismatchedAccount)) - | "2" -> (Some (FIX_ConfirmRejReason_MissingSettlementInstructions)) - | "99" -> (Some (FIX_ConfirmRejReason_Other)) - | _ -> (None) - ) -;; - -let parse_ConfirmStatus (str) = - (match str with - | "1" -> (Some (FIX_ConfirmStatus_Received)) - | "2" -> (Some (FIX_ConfirmStatus_MismatchedAccount)) - | "3" -> (Some (FIX_ConfirmStatus_MissingSettlementInstructions)) - | "4" -> (Some (FIX_ConfirmStatus_Confirmed)) - | "5" -> (Some (FIX_ConfirmStatus_RequestRejected)) - | _ -> (None) - ) -;; - -let parse_ConfirmTransType (str) = - (match str with - | "0" -> (Some (FIX_ConfirmTransType_New)) - | "1" -> (Some (FIX_ConfirmTransType_Replace)) - | "2" -> (Some (FIX_ConfirmTransType_Cancel)) - | _ -> (None) - ) -;; - -let parse_ConfirmType (str) = - (match str with - | "1" -> (Some (FIX_ConfirmType_Status)) - | "2" -> (Some (FIX_ConfirmType_Confirmation)) - | "3" -> (Some (FIX_ConfirmType_ConfirmationRequestRejected)) - | _ -> (None) - ) -;; - -let parse_ContAmtType (str) = - (match str with - | "1" -> (Some (FIX_ContAmtType_CommissionAmount)) - | "2" -> (Some (FIX_ContAmtType_CommissionPercent)) - | "3" -> (Some (FIX_ContAmtType_InitialChargeAmount)) - | "4" -> (Some (FIX_ContAmtType_InitialChargePercent)) - | "5" -> (Some (FIX_ContAmtType_DiscountAmount)) - | "6" -> (Some (FIX_ContAmtType_DiscountPercent)) - | "7" -> (Some (FIX_ContAmtType_DilutionLevyAmount)) - | "8" -> (Some (FIX_ContAmtType_DilutionLevyPercent)) - | "9" -> (Some (FIX_ContAmtType_ExitChargeAmount)) - | "10" -> (Some (FIX_ContAmtType_ExitChargePercent)) - | "11" -> (Some (FIX_ContAmtType_FundBasedRenewalCommissionPercent)) - | "12" -> (Some (FIX_ContAmtType_ProjectedFundValue)) - | "13" -> (Some (FIX_ContAmtType_FundBasedRenewalCommissionOnOrder)) - | "14" -> (Some (FIX_ContAmtType_FundBasedRenewalCommissionOnFund)) - | "15" -> (Some (FIX_ContAmtType_NetSettlementAmount)) - | _ -> (None) - ) -;; - -let parse_inner_CorporateAction (str) = - (match str with - | "A" -> (Some (FIX_CorporateAction_ExDividend)) - | "B" -> (Some (FIX_CorporateAction_ExDistribution)) - | "C" -> (Some (FIX_CorporateAction_ExRights)) - | "D" -> (Some (FIX_CorporateAction_New)) - | "E" -> (Some (FIX_CorporateAction_ExInterest)) - | _ -> (None) - ) -;; - -let rec parse_CorporateAction_filter (f) = - (match f with - | [] -> [] - | h :: t -> ((match parse_inner_CorporateAction h with - | None -> (parse_CorporateAction_filter t) - | Some x -> (x :: (parse_CorporateAction_filter t)) - ) - ) - ) -;; - -let parse_CorporateAction (str) = - let x = split_to_list str ' ' in - Some (parse_CorporateAction_filter x) -;; -let parse_CoveredOrUncovered (str) = - (match str with - | "0" -> (Some (FIX_CoveredOrUncovered_Covered)) - | "1" -> (Some (FIX_CoveredOrUncovered_Uncovered)) - | _ -> (None) - ) -;; - -let parse_CrossPrioritization (str) = - (match str with - | "0" -> (Some (FIX_CrossPrioritization_FIXNone)) - | "1" -> (Some (FIX_CrossPrioritization_BuySideIsPrioritized)) - | "2" -> (Some (FIX_CrossPrioritization_SellSideIsPrioritized)) - | _ -> (None) - ) -;; - -let parse_CrossType (str) = - (match str with - | "1" -> (Some (FIX_CrossType_CrossAON)) - | "2" -> (Some (FIX_CrossType_CrossIOC)) - | "3" -> (Some (FIX_CrossType_CrossOneSide)) - | "4" -> (Some (FIX_CrossType_CrossSamePrice)) - | _ -> (None) - ) -;; - -let parse_CustOrderCapacity (str) = - (match str with - | "1" -> (Some (FIX_CustOrderCapacity_MemberTradingForTheirOwnAccount)) - | "2" -> (Some (FIX_CustOrderCapacity_ClearingFirmTradingForItsProprietaryAccount)) - | "3" -> (Some (FIX_CustOrderCapacity_MemberTradingForAnotherMember)) - | "4" -> (Some (FIX_CustOrderCapacity_AllOther)) - | _ -> (None) - ) -;; - -let parse_CxlRejReason (str) = - (match str with - | "0" -> (Some (FIX_CxlRejReason_TooLateToCancel)) - | "1" -> (Some (FIX_CxlRejReason_UnknownOrder)) - | "2" -> (Some (FIX_CxlRejReason_BrokerCredit)) - | "3" -> (Some (FIX_CxlRejReason_OrderAlreadyInPendingStatus)) - | "4" -> (Some (FIX_CxlRejReason_UnableToProcessOrderMassCancelRequest)) - | "5" -> (Some (FIX_CxlRejReason_OrigOrdModTime)) - | "6" -> (Some (FIX_CxlRejReason_DuplicateClOrdID)) - | "99" -> (Some (FIX_CxlRejReason_Other)) - | _ -> (None) - ) -;; - -let parse_CxlRejResponseTo (str) = - (match str with - | "1" -> (Some (FIX_CxlRejResponseTo_OrderCancelRequest)) - | "2" -> (Some (FIX_CxlRejResponseTo_OrderCancel)) - | _ -> (None) - ) -;; - -let parse_DKReason (str) = - (match str with - | "A" -> (Some (FIX_DKReason_UnknownSymbol)) - | "B" -> (Some (FIX_DKReason_WrongSide)) - | "C" -> (Some (FIX_DKReason_QuantityExceedsOrder)) - | "D" -> (Some (FIX_DKReason_NoMatchingOrder)) - | "E" -> (Some (FIX_DKReason_PriceExceedsLimit)) - | "F" -> (Some (FIX_DKReason_CalculationDifference)) - | "Z" -> (Some (FIX_DKReason_Other)) - | _ -> (None) - ) -;; - -let parse_DayBookingInst (str) = - (match str with - | "0" -> (Some (FIX_DayBookingInst_Auto)) - | "1" -> (Some (FIX_DayBookingInst_SpeakWithOrderInitiatorBeforeBooking)) - | "2" -> (Some (FIX_DayBookingInst_Accumulate)) - | _ -> (None) - ) -;; - -let parse_DeleteReason (str) = - (match str with - | "0" -> (Some (FIX_DeleteReason_Cancellation)) - | "1" -> (Some (FIX_DeleteReason_Error)) - | _ -> (None) - ) -;; - -let parse_DeliveryForm (str) = - (match str with - | "1" -> (Some (FIX_DeliveryForm_BookEntry)) - | "2" -> (Some (FIX_DeliveryForm_Bearer)) - | _ -> (None) - ) -;; - -let parse_DeliveryType (str) = - (match str with - | "0" -> (Some (FIX_DeliveryType_VersusPayment)) - | "1" -> (Some (FIX_DeliveryType_Free)) - | "2" -> (Some (FIX_DeliveryType_TriParty)) - | "3" -> (Some (FIX_DeliveryType_HoldInCustody)) - | _ -> (None) - ) -;; - -let parse_DiscretionInst (str) = - (match str with - | "0" -> (Some (FIX_DiscretionInst_RelatedToDisplayedPrice)) - | "1" -> (Some (FIX_DiscretionInst_RelatedToMarketPrice)) - | "2" -> (Some (FIX_DiscretionInst_RelatedToPrimaryPrice)) - | "3" -> (Some (FIX_DiscretionInst_RelatedToLocalPrimaryPrice)) - | "4" -> (Some (FIX_DiscretionInst_RelatedToMidpointPrice)) - | "5" -> (Some (FIX_DiscretionInst_RelatedToLastTradePrice)) - | "6" -> (Some (FIX_DiscretionInst_RelatedToVWAP)) - | _ -> (None) - ) -;; - -let parse_DiscretionLimitType (str) = - (match str with - | "0" -> (Some (FIX_DiscretionLimitType_OrBetter)) - | "1" -> (Some (FIX_DiscretionLimitType_Strict)) - | "2" -> (Some (FIX_DiscretionLimitType_OrWorse)) - | _ -> (None) - ) -;; - -let parse_DiscretionMoveType (str) = - (match str with - | "0" -> (Some (FIX_DiscretionMoveType_Floating)) - | "1" -> (Some (FIX_DiscretionMoveType_Fixed)) - | _ -> (None) - ) -;; - -let parse_DiscretionOffsetType (str) = - (match str with - | "0" -> (Some (FIX_DiscretionOffsetType_Price)) - | "1" -> (Some (FIX_DiscretionOffsetType_BasisPoints)) - | "2" -> (Some (FIX_DiscretionOffsetType_Ticks)) - | "3" -> (Some (FIX_DiscretionOffsetType_PriceTier)) - | _ -> (None) - ) -;; - -let parse_DiscretionRoundDirection (str) = - (match str with - | "1" -> (Some (FIX_DiscretionRoundDirection_MoreAggressive)) - | "2" -> (Some (FIX_DiscretionRoundDirection_MorePassive)) - | _ -> (None) - ) -;; - -let parse_DiscretionScope (str) = - (match str with - | "1" -> (Some (FIX_DiscretionScope_Local)) - | "2" -> (Some (FIX_DiscretionScope_National)) - | "3" -> (Some (FIX_DiscretionScope_Global)) - | "4" -> (Some (FIX_DiscretionScope_NationalExcludingLocal)) - | _ -> (None) - ) -;; - -let parse_DistribPaymentMethod (str) = - (match str with - | "1" -> (Some (FIX_DistribPaymentMethod_CREST)) - | "2" -> (Some (FIX_DistribPaymentMethod_NSCC)) - | "3" -> (Some (FIX_DistribPaymentMethod_Euroclear)) - | "4" -> (Some (FIX_DistribPaymentMethod_Clearstream)) - | "5" -> (Some (FIX_DistribPaymentMethod_Cheque)) - | "6" -> (Some (FIX_DistribPaymentMethod_TelegraphicTransfer)) - | "7" -> (Some (FIX_DistribPaymentMethod_FedWire)) - | "8" -> (Some (FIX_DistribPaymentMethod_DirectCredit)) - | "9" -> (Some (FIX_DistribPaymentMethod_ACHCredit)) - | "10" -> (Some (FIX_DistribPaymentMethod_BPAY)) - | "11" -> (Some (FIX_DistribPaymentMethod_HighValueClearingSystemHVACS)) - | "12" -> (Some (FIX_DistribPaymentMethod_ReinvestInFund)) - | _ -> (None) - ) -;; - -let parse_DlvyInstType (str) = - (match str with - | "S" -> (Some (FIX_DlvyInstType_Securities)) - | "C" -> (Some (FIX_DlvyInstType_Cash)) - | _ -> (None) - ) -;; - -let parse_DueToRelated (str) = - (match str with - | "Y" -> (Some (FIX_DueToRelated_RelatedToSecurityHalt)) - | "N" -> (Some (FIX_DueToRelated_NotRelatedToSecurityHalt)) - | _ -> (None) - ) -;; - -let parse_EmailType (str) = - (match str with - | "0" -> (Some (FIX_EmailType_New)) - | "1" -> (Some (FIX_EmailType_Reply)) - | "2" -> (Some (FIX_EmailType_AdminReply)) - | _ -> (None) - ) -;; - -let parse_EventType (str) = - (match str with - | "1" -> (Some (FIX_EventType_Put)) - | "2" -> (Some (FIX_EventType_Call)) - | "3" -> (Some (FIX_EventType_Tender)) - | "4" -> (Some (FIX_EventType_SinkingFundCall)) - | "99" -> (Some (FIX_EventType_Other)) - | _ -> (None) - ) -;; - -let parse_ExchangeForPhysical (str) = - (match str with - | "Y" -> (Some (FIX_ExchangeForPhysical_True)) - | "N" -> (Some (FIX_ExchangeForPhysical_False)) - | _ -> (None) - ) -;; - -let parse_inner_ExecInst (str) = +let parse_inner_ExecInst (str) = (match str with | "1" -> (Some (FIX_ExecInst_NotHeld)) | "2" -> (Some (FIX_ExecInst_Work)) @@ -876,1793 +40,132 @@ let parse_inner_ExecInst (str) = | "U" -> (Some (FIX_ExecInst_CustomerDisplayInstruction)) | "V" -> (Some (FIX_ExecInst_Netting)) | "W" -> (Some (FIX_ExecInst_PegToVWAP)) - | "X" -> (Some (FIX_ExecInst_TradeAlong)) - | "Y" -> (Some (FIX_ExecInst_TryToStop)) - | "Z" -> (Some (FIX_ExecInst_CancelIfNotBest)) - | "a" -> (Some (FIX_ExecInst_TrailingStopPeg)) - | "b" -> (Some (FIX_ExecInst_StrictLimit)) - | "c" -> (Some (FIX_ExecInst_IgnorePriceValidityChecks)) - | "d" -> (Some (FIX_ExecInst_PegToLimitPrice)) - | "e" -> (Some (FIX_ExecInst_WorkToTargetStrategy)) - | _ -> (None) - ) -;; - -let rec parse_ExecInst_filter (f) = - (match f with - | [] -> [] - | h :: t -> ((match parse_inner_ExecInst h with - | None -> (parse_ExecInst_filter t) - | Some x -> (x :: (parse_ExecInst_filter t)) - ) - ) - ) -;; - -let parse_ExecInst (str) = - let x = split_to_list str ' ' in - Some (parse_ExecInst_filter x) -;; - -let parse_ExecPriceType (str) = - (match str with - | "B" -> (Some (FIX_ExecPriceType_BidPrice)) - | "C" -> (Some (FIX_ExecPriceType_CreationPrice)) - | "D" -> (Some (FIX_ExecPriceType_CreationPricePlusAdjustmentPercent)) - | "E" -> (Some (FIX_ExecPriceType_CreationPricePlusAdjustmentAmount)) - | "O" -> (Some (FIX_ExecPriceType_OfferPrice)) - | "P" -> (Some (FIX_ExecPriceType_OfferPriceMinusAdjustmentPercent)) - | "Q" -> (Some (FIX_ExecPriceType_OfferPriceMinusAdjustmentAmount)) - | "S" -> (Some (FIX_ExecPriceType_SinglePrice)) - | _ -> (None) - ) -;; - -let parse_ExecRestatementReason (str) = - (match str with - | "0" -> (Some (FIX_ExecRestatementReason_GTCorporateAction)) - | "1" -> (Some (FIX_ExecRestatementReason_GTRenewal)) - | "2" -> (Some (FIX_ExecRestatementReason_VerbalChange)) - | "3" -> (Some (FIX_ExecRestatementReason_RepricingOfOrder)) - | "4" -> (Some (FIX_ExecRestatementReason_BrokerOption)) - | "5" -> (Some (FIX_ExecRestatementReason_PartialDeclineOfOrderQty)) - | "6" -> (Some (FIX_ExecRestatementReason_CancelOnTradingHalt)) - | "7" -> (Some (FIX_ExecRestatementReason_CancelOnSystemFailure)) - | "8" -> (Some (FIX_ExecRestatementReason_Market)) - | "9" -> (Some (FIX_ExecRestatementReason_Canceled)) - | "10" -> (Some (FIX_ExecRestatementReason_WarehouseRecap)) - | "99" -> (Some (FIX_ExecRestatementReason_Other)) - | _ -> (None) - ) -;; - -let parse_ExecType (str) = - (match str with - | "0" -> (Some (FIX_ExecType_New)) - | "3" -> (Some (FIX_ExecType_DoneForDay)) - | "4" -> (Some (FIX_ExecType_Canceled)) - | "5" -> (Some (FIX_ExecType_Replaced)) - | "6" -> (Some (FIX_ExecType_PendingCancel)) - | "7" -> (Some (FIX_ExecType_Stopped)) - | "8" -> (Some (FIX_ExecType_Rejected)) - | "9" -> (Some (FIX_ExecType_Suspended)) - | "A" -> (Some (FIX_ExecType_PendingNew)) - | "B" -> (Some (FIX_ExecType_Calculated)) - | "C" -> (Some (FIX_ExecType_Expired)) - | "D" -> (Some (FIX_ExecType_Restated)) - | "E" -> (Some (FIX_ExecType_PendingReplace)) - | "F" -> (Some (FIX_ExecType_Trade)) - | "G" -> (Some (FIX_ExecType_TradeCorrect)) - | "H" -> (Some (FIX_ExecType_TradeCancel)) - | "I" -> (Some (FIX_ExecType_OrderStatus)) - | _ -> (None) - ) -;; - -let parse_ExerciseMethod (str) = - (match str with - | "A" -> (Some (FIX_ExerciseMethod_Automatic)) - | "M" -> (Some (FIX_ExerciseMethod_Manual)) - | _ -> (None) - ) -;; - -let parse_ExpirationCycle (str) = - (match str with - | "0" -> (Some (FIX_ExpirationCycle_ExpireOnTradingSessionClose)) - | "1" -> (Some (FIX_ExpirationCycle_ExpireOnTradingSessionOpen)) - | _ -> (None) - ) -;; - -let parse_inner_FinancialStatus (str) = - (match str with - | "1" -> (Some (FIX_FinancialStatus_Bankrupt)) - | "2" -> (Some (FIX_FinancialStatus_PendingDelisting)) - | _ -> (None) - ) -;; - -let rec parse_FinancialStatus_filter (f) = - (match f with - | [] -> [] - | h :: t -> ((match parse_inner_FinancialStatus h with - | None -> (parse_FinancialStatus_filter t) - | Some x -> (x :: (parse_FinancialStatus_filter t)) - ) - ) - ) -;; - -let parse_FinancialStatus (str) = - let x = split_to_list str ' ' in - Some (parse_FinancialStatus_filter x) -;; - -let parse_ForexReq (str) = - (match str with - | "Y" -> (Some (FIX_ForexReq_ExecuteForexAfterSecurityTrade)) - | "N" -> (Some (FIX_ForexReq_DoNotExecuteForexAfterSecurityTrade)) - | _ -> (None) - ) -;; - -let parse_FundRenewWaiv (str) = - (match str with - | "Y" -> (Some (FIX_FundRenewWaiv_Yes)) - | "N" -> (Some (FIX_FundRenewWaiv_No)) - | _ -> (None) - ) -;; - -let parse_GTBookingInst (str) = - (match str with - | "0" -> (Some (FIX_GTBookingInst_BookOutAllTradesOnDayOfExecution)) - | "1" -> (Some (FIX_GTBookingInst_AccumulateUntilFilledOrExpired)) - | "2" -> (Some (FIX_GTBookingInst_AccumulateUntilVerballyNotifiedOtherwise)) - | _ -> (None) - ) -;; - -let parse_HaltReason (str) = - (match str with - | "I" -> (Some (FIX_HaltReason_OrderImbalance)) - | "X" -> (Some (FIX_HaltReason_EquipmentChangeover)) - | "P" -> (Some (FIX_HaltReason_NewsPending)) - | "D" -> (Some (FIX_HaltReason_NewsDissemination)) - | "E" -> (Some (FIX_HaltReason_OrderInflux)) - | "M" -> (Some (FIX_HaltReason_AdditionalInformation)) - | _ -> (None) - ) -;; - -let parse_HandlInst (str) = - (match str with - | "1" -> (Some (FIX_HandlInst_AutomatedExecutionNoIntervention)) - | "2" -> (Some (FIX_HandlInst_AutomatedExecutionInterventionOK)) - | "3" -> (Some (FIX_HandlInst_ManualOrder)) - | _ -> (None) - ) -;; - -let parse_IOINaturalFlag (str) = - (match str with - | "Y" -> (Some (FIX_IOINaturalFlag_Natural)) - | "N" -> (Some (FIX_IOINaturalFlag_NotNatural)) - | _ -> (None) - ) -;; - -let parse_IOIQltyInd (str) = - (match str with - | "L" -> (Some (FIX_IOIQltyInd_Low)) - | "M" -> (Some (FIX_IOIQltyInd_Medium)) - | "H" -> (Some (FIX_IOIQltyInd_High)) - | _ -> (None) - ) -;; - -let parse_IOIQty (str) = - (match str with - | "S" -> (Some (FIX_IOIQty_Small)) - | "M" -> (Some (FIX_IOIQty_Medium)) - | "L" -> (Some (FIX_IOIQty_Large)) - | _ -> (None) - ) -;; - -let parse_IOIQualifier (str) = - (match str with - | "A" -> (Some (FIX_IOIQualifier_AllOrNone)) - | "B" -> (Some (FIX_IOIQualifier_MarketOnClose)) - | "C" -> (Some (FIX_IOIQualifier_AtTheClose)) - | "D" -> (Some (FIX_IOIQualifier_VWAP)) - | "I" -> (Some (FIX_IOIQualifier_InTouchWith)) - | "L" -> (Some (FIX_IOIQualifier_Limit)) - | "M" -> (Some (FIX_IOIQualifier_MoreBehind)) - | "O" -> (Some (FIX_IOIQualifier_AtTheOpen)) - | "P" -> (Some (FIX_IOIQualifier_TakingAPosition)) - | "Q" -> (Some (FIX_IOIQualifier_AtTheMarket)) - | "R" -> (Some (FIX_IOIQualifier_ReadyToTrade)) - | "S" -> (Some (FIX_IOIQualifier_PortfolioShown)) - | "T" -> (Some (FIX_IOIQualifier_ThroughTheDay)) - | "V" -> (Some (FIX_IOIQualifier_Versus)) - | "W" -> (Some (FIX_IOIQualifier_Indication)) - | "X" -> (Some (FIX_IOIQualifier_CrossingOpportunity)) - | "Y" -> (Some (FIX_IOIQualifier_AtTheMidpoint)) - | "Z" -> (Some (FIX_IOIQualifier_PreOpen)) - | _ -> (None) - ) -;; - -let parse_IOITransType (str) = - (match str with - | "N" -> (Some (FIX_IOITransType_New)) - | "C" -> (Some (FIX_IOITransType_Cancel)) - | "R" -> (Some (FIX_IOITransType_Replace)) - | _ -> (None) - ) -;; - -let parse_InViewOfCommon (str) = - (match str with - | "Y" -> (Some (FIX_InViewOfCommon_HaltWasDueToCommonStockBeingHalted)) - | "N" -> (Some (FIX_InViewOfCommon_HaltWasNotRelatedToAHaltOfTheCommonStock)) - | _ -> (None) - ) -;; - -let parse_IncTaxInd (str) = - (match str with - | "1" -> (Some (FIX_IncTaxInd_Net)) - | "2" -> (Some (FIX_IncTaxInd_Gross)) - | _ -> (None) - ) -;; - -let parse_InstrAttribType (str) = - (match str with - | "1" -> (Some (FIX_InstrAttribType_Flat)) - | "2" -> (Some (FIX_InstrAttribType_ZeroCoupon)) - | "3" -> (Some (FIX_InstrAttribType_InterestBearing)) - | "4" -> (Some (FIX_InstrAttribType_NoPeriodicPayments)) - | "5" -> (Some (FIX_InstrAttribType_VariableRate)) - | "6" -> (Some (FIX_InstrAttribType_LessFeeForPut)) - | "7" -> (Some (FIX_InstrAttribType_SteppedCoupon)) - | "8" -> (Some (FIX_InstrAttribType_CouponPeriod)) - | "9" -> (Some (FIX_InstrAttribType_When)) - | "10" -> (Some (FIX_InstrAttribType_OriginalIssueDiscount)) - | "11" -> (Some (FIX_InstrAttribType_Callable)) - | "12" -> (Some (FIX_InstrAttribType_EscrowedToMaturity)) - | "13" -> (Some (FIX_InstrAttribType_EscrowedToRedemptionDate)) - | "14" -> (Some (FIX_InstrAttribType_PreRefunded)) - | "15" -> (Some (FIX_InstrAttribType_InDefault)) - | "16" -> (Some (FIX_InstrAttribType_Unrated)) - | "17" -> (Some (FIX_InstrAttribType_Taxable)) - | "18" -> (Some (FIX_InstrAttribType_Indexed)) - | "19" -> (Some (FIX_InstrAttribType_SubjectToAlternativeMinimumTax)) - | "20" -> (Some (FIX_InstrAttribType_OriginalIssueDiscountPrice)) - | "21" -> (Some (FIX_InstrAttribType_CallableBelowMaturityValue)) - | "22" -> (Some (FIX_InstrAttribType_CallableWithoutNotice)) - | "99" -> (Some (FIX_InstrAttribType_Text)) - | _ -> (None) - ) -;; - -let parse_LastCapacity (str) = - (match str with - | "1" -> (Some (FIX_LastCapacity_Agent)) - | "2" -> (Some (FIX_LastCapacity_CrossAsAgent)) - | "3" -> (Some (FIX_LastCapacity_CrossAsPrincipal)) - | "4" -> (Some (FIX_LastCapacity_Principal)) - | _ -> (None) - ) -;; - -let parse_LastFragment (str) = - (match str with - | "Y" -> (Some (FIX_LastFragment_LastMessage)) - | "N" -> (Some (FIX_LastFragment_NotLastMessage)) - | _ -> (None) - ) -;; - -let parse_LastLiquidityInd (str) = - (match str with - | "1" -> (Some (FIX_LastLiquidityInd_AddedLiquidity)) - | "2" -> (Some (FIX_LastLiquidityInd_RemovedLiquidity)) - | "3" -> (Some (FIX_LastLiquidityInd_LiquidityRoutedOut)) - | _ -> (None) - ) -;; - -let parse_LegSwapType (str) = - (match str with - | "1" -> (Some (FIX_LegSwapType_ParForPar)) - | "2" -> (Some (FIX_LegSwapType_ModifiedDuration)) - | "4" -> (Some (FIX_LegSwapType_Risk)) - | "5" -> (Some (FIX_LegSwapType_Proceeds)) - | _ -> (None) - ) -;; - -let parse_LegalConfirm (str) = - (match str with - | "Y" -> (Some (FIX_LegalConfirm_LegalConfirm)) - | "N" -> (Some (FIX_LegalConfirm_DoesNotConsituteALegalConfirm)) - | _ -> (None) - ) -;; - -let parse_LiquidityIndType (str) = - (match str with - | "1" -> (Some (FIX_LiquidityIndType_FiveDayMovingAverage)) - | "2" -> (Some (FIX_LiquidityIndType_TwentyDayMovingAverage)) - | "3" -> (Some (FIX_LiquidityIndType_NormalMarketSize)) - | "4" -> (Some (FIX_LiquidityIndType_Other)) - | _ -> (None) - ) -;; - -let parse_ListExecInstType (str) = - (match str with - | "1" -> (Some (FIX_ListExecInstType_Immediate)) - | "2" -> (Some (FIX_ListExecInstType_WaitForInstruction)) - | "3" -> (Some (FIX_ListExecInstType_SellDriven)) - | "4" -> (Some (FIX_ListExecInstType_BuyDrivenCashTopUp)) - | "5" -> (Some (FIX_ListExecInstType_BuyDrivenCashWithdraw)) - | _ -> (None) - ) -;; - -let parse_ListOrderStatus (str) = - (match str with - | "1" -> (Some (FIX_ListOrderStatus_InBiddingProcess)) - | "2" -> (Some (FIX_ListOrderStatus_ReceivedForExecution)) - | "3" -> (Some (FIX_ListOrderStatus_Executing)) - | "4" -> (Some (FIX_ListOrderStatus_Cancelling)) - | "5" -> (Some (FIX_ListOrderStatus_Alert)) - | "6" -> (Some (FIX_ListOrderStatus_AllDone)) - | "7" -> (Some (FIX_ListOrderStatus_Reject)) - | _ -> (None) - ) -;; - -let parse_ListStatusType (str) = - (match str with - | "1" -> (Some (FIX_ListStatusType_Ack)) - | "2" -> (Some (FIX_ListStatusType_Response)) - | "3" -> (Some (FIX_ListStatusType_Timed)) - | "4" -> (Some (FIX_ListStatusType_ExecStarted)) - | "5" -> (Some (FIX_ListStatusType_AllDone)) - | "6" -> (Some (FIX_ListStatusType_Alert)) - | _ -> (None) - ) -;; - -let parse_LocateReqd (str) = - (match str with - | "Y" -> (Some (FIX_LocateReqd_Yes)) - | "N" -> (Some (FIX_LocateReqd_No)) - | _ -> (None) - ) -;; - -let parse_MDEntryType (str) = - (match str with - | "0" -> (Some (FIX_MDEntryType_Bid)) - | "1" -> (Some (FIX_MDEntryType_Offer)) - | "2" -> (Some (FIX_MDEntryType_Trade)) - | "3" -> (Some (FIX_MDEntryType_IndexValue)) - | "4" -> (Some (FIX_MDEntryType_OpeningPrice)) - | "5" -> (Some (FIX_MDEntryType_ClosingPrice)) - | "6" -> (Some (FIX_MDEntryType_SettlementPrice)) - | "7" -> (Some (FIX_MDEntryType_TradingSessionHighPrice)) - | "8" -> (Some (FIX_MDEntryType_TradingSessionLowPrice)) - | "9" -> (Some (FIX_MDEntryType_TradingSessionVWAPPrice)) - | "A" -> (Some (FIX_MDEntryType_Imbalance)) - | "B" -> (Some (FIX_MDEntryType_TradeVolume)) - | "C" -> (Some (FIX_MDEntryType_OpenInterest)) - | _ -> (None) - ) -;; - -let parse_MDImplicitDelete (str) = - (match str with - | "Y" -> (Some (FIX_MDImplicitDelete_Yes)) - | "N" -> (Some (FIX_MDImplicitDelete_No)) - | _ -> (None) - ) -;; - -let parse_MDReqRejReason (str) = - (match str with - | "0" -> (Some (FIX_MDReqRejReason_UnknownSymbol)) - | "1" -> (Some (FIX_MDReqRejReason_DuplicateMDReqID)) - | "2" -> (Some (FIX_MDReqRejReason_InsufficientBandwidth)) - | "3" -> (Some (FIX_MDReqRejReason_InsufficientPermissions)) - | "4" -> (Some (FIX_MDReqRejReason_UnsupportedSubscriptionRequestType)) - | "5" -> (Some (FIX_MDReqRejReason_UnsupportedMarketDepth)) - | "6" -> (Some (FIX_MDReqRejReason_UnsupportedMDUpdateType)) - | "7" -> (Some (FIX_MDReqRejReason_UnsupportedAggregatedBook)) - | "8" -> (Some (FIX_MDReqRejReason_UnsupportedMDEntryType)) - | "9" -> (Some (FIX_MDReqRejReason_UnsupportedTradingSessionID)) - | "A" -> (Some (FIX_MDReqRejReason_UnsupportedScope)) - | "B" -> (Some (FIX_MDReqRejReason_UnsupportedOpenCloseSettleFlag)) - | "C" -> (Some (FIX_MDReqRejReason_UnsupportedMDImplicitDelete)) - | _ -> (None) - ) -;; - -let parse_MDUpdateAction (str) = - (match str with - | "0" -> (Some (FIX_MDUpdateAction_New)) - | "1" -> (Some (FIX_MDUpdateAction_Change)) - | "2" -> (Some (FIX_MDUpdateAction_Delete)) - | _ -> (None) - ) -;; - -let parse_MDUpdateType (str) = - (match str with - | "0" -> (Some (FIX_MDUpdateType_FullRefresh)) - | "1" -> (Some (FIX_MDUpdateType_IncrementalRefresh)) - | _ -> (None) - ) -;; - -let parse_MassCancelRejectReason (str) = - (match str with - | "0" -> (Some (FIX_MassCancelRejectReason_MassCancelNotSupported)) - | "1" -> (Some (FIX_MassCancelRejectReason_InvalidOrUnknownSecurity)) - | "2" -> (Some (FIX_MassCancelRejectReason_InvalidOrUnkownUnderlyingSecurity)) - | "3" -> (Some (FIX_MassCancelRejectReason_InvalidOrUnknownProduct)) - | "4" -> (Some (FIX_MassCancelRejectReason_InvalidOrUnknownCFICode)) - | "5" -> (Some (FIX_MassCancelRejectReason_InvalidOrUnknownSecurityType)) - | "6" -> (Some (FIX_MassCancelRejectReason_InvalidOrUnknownTradingSession)) - | "99" -> (Some (FIX_MassCancelRejectReason_Other)) - | _ -> (None) - ) -;; - -let parse_MassCancelRequestType (str) = - (match str with - | "1" -> (Some (FIX_MassCancelRequestType_CancelOrdersForASecurity)) - | "2" -> (Some (FIX_MassCancelRequestType_CancelOrdersForAnUnderlyingSecurity)) - | "3" -> (Some (FIX_MassCancelRequestType_CancelOrdersForAProduct)) - | "4" -> (Some (FIX_MassCancelRequestType_CancelOrdersForACFICode)) - | "5" -> (Some (FIX_MassCancelRequestType_CancelOrdersForASecurityType)) - | "6" -> (Some (FIX_MassCancelRequestType_CancelOrdersForATradingSession)) - | "7" -> (Some (FIX_MassCancelRequestType_CancelAllOrders)) - | _ -> (None) - ) -;; - -let parse_MassCancelResponse (str) = - (match str with - | "0" -> (Some (FIX_MassCancelResponse_CancelRequestRejected)) - | "1" -> (Some (FIX_MassCancelResponse_CancelOrdersForASecurity)) - | "2" -> (Some (FIX_MassCancelResponse_CancelOrdersForAnUnderlyingSecurity)) - | "3" -> (Some (FIX_MassCancelResponse_CancelOrdersForAProduct)) - | "4" -> (Some (FIX_MassCancelResponse_CancelOrdersForACFICode)) - | "5" -> (Some (FIX_MassCancelResponse_CancelOrdersForASecurityType)) - | "6" -> (Some (FIX_MassCancelResponse_CancelOrdersForATradingSession)) - | "7" -> (Some (FIX_MassCancelResponse_CancelAllOrders)) - | _ -> (None) - ) -;; - -let parse_MassStatusReqType (str) = - (match str with - | "1" -> (Some (FIX_MassStatusReqType_StatusForOrdersForASecurity)) - | "2" -> (Some (FIX_MassStatusReqType_StatusForOrdersForAnUnderlyingSecurity)) - | "3" -> (Some (FIX_MassStatusReqType_StatusForOrdersForAProduct)) - | "4" -> (Some (FIX_MassStatusReqType_StatusForOrdersForACFICode)) - | "5" -> (Some (FIX_MassStatusReqType_StatusForOrdersForASecurityType)) - | "6" -> (Some (FIX_MassStatusReqType_StatusForOrdersForATradingSession)) - | "7" -> (Some (FIX_MassStatusReqType_StatusForAllOrders)) - | "8" -> (Some (FIX_MassStatusReqType_StatusForOrdersForAPartyID)) - | _ -> (None) - ) -;; - -let parse_MatchStatus (str) = - (match str with - | "0" -> (Some (FIX_MatchStatus_Compared)) - | "1" -> (Some (FIX_MatchStatus_Uncompared)) - | "2" -> (Some (FIX_MatchStatus_AdvisoryOrAlert)) - | _ -> (None) - ) -;; - -let parse_MatchType (str) = - (match str with - | "A1" -> (Some (FIX_MatchType_ExactMatchPlus4BadgesExecTime)) - | "A2" -> (Some (FIX_MatchType_ExactMatchPlus4Badges)) - | "A3" -> (Some (FIX_MatchType_ExactMatchPlus2BadgesExecTime)) - | "A4" -> (Some (FIX_MatchType_ExactMatchPlus2Badges)) - | "A5" -> (Some (FIX_MatchType_ExactMatchPlusExecTime)) - | "AQ" -> (Some (FIX_MatchType_StampedAdvisoriesOrSpecialistAccepts)) - | "S1" -> (Some (FIX_MatchType_A1ExactMatchSummarizedQuantity)) - | "S2" -> (Some (FIX_MatchType_A2ExactMatchSummarizedQuantity)) - | "S3" -> (Some (FIX_MatchType_A3ExactMatchSummarizedQuantity)) - | "S4" -> (Some (FIX_MatchType_A4ExactMatchSummarizedQuantity)) - | "S5" -> (Some (FIX_MatchType_A5ExactMatchSummarizedQuantity)) - | "M1" -> (Some (FIX_MatchType_ExactMatchMinusBadgesTimes)) - | "M2" -> (Some (FIX_MatchType_SummarizedMatchMinusBadgesTimes)) - | "MT" -> (Some (FIX_MatchType_OCSLockedIn)) - | "M3" -> (Some (FIX_MatchType_ACTAcceptedTrade)) - | "M4" -> (Some (FIX_MatchType_ACTDefaultTrade)) - | "M5" -> (Some (FIX_MatchType_ACTDefaultAfterM2)) - | "M6" -> (Some (FIX_MatchType_ACTM6Match)) - | _ -> (None) - ) -;; - -let parse_MessageEncoding (str) = - (match str with - | "ISO-2022-JP" -> (Some (FIX_MessageEncoding_ISO2022JP)) - | "EUC-JP" -> (Some (FIX_MessageEncoding_EUCJP)) - | "Shift_JIS" -> (Some (FIX_MessageEncoding_ShiftJIS)) - | "UTF-8" -> (Some (FIX_MessageEncoding_UTF8)) - | _ -> (None) - ) -;; - -let parse_MiscFeeBasis (str) = - (match str with - | "0" -> (Some (FIX_MiscFeeBasis_Absolute)) - | "1" -> (Some (FIX_MiscFeeBasis_PerUnit)) - | "2" -> (Some (FIX_MiscFeeBasis_Percentage)) - | _ -> (None) - ) -;; - -let parse_MiscFeeType (str) = - (match str with - | "1" -> (Some (FIX_MiscFeeType_Regulatory)) - | "2" -> (Some (FIX_MiscFeeType_Tax)) - | "3" -> (Some (FIX_MiscFeeType_LocalCommission)) - | "4" -> (Some (FIX_MiscFeeType_ExchangeFees)) - | "5" -> (Some (FIX_MiscFeeType_Stamp)) - | "6" -> (Some (FIX_MiscFeeType_Levy)) - | "7" -> (Some (FIX_MiscFeeType_Other)) - | "8" -> (Some (FIX_MiscFeeType_Markup)) - | "9" -> (Some (FIX_MiscFeeType_ConsumptionTax)) - | "10" -> (Some (FIX_MiscFeeType_PerTransaction)) - | "11" -> (Some (FIX_MiscFeeType_Conversion)) - | "12" -> (Some (FIX_MiscFeeType_Agent)) - | _ -> (None) - ) -;; - -let parse_MoneyLaunderingStatus (str) = - (match str with - | "Y" -> (Some (FIX_MoneyLaunderingStatus_Passed)) - | "N" -> (Some (FIX_MoneyLaunderingStatus_NotChecked)) - | "1" -> (Some (FIX_MoneyLaunderingStatus_ExemptBelowLimit)) - | "2" -> (Some (FIX_MoneyLaunderingStatus_ExemptMoneyType)) - | "3" -> (Some (FIX_MoneyLaunderingStatus_ExemptAuthorised)) - | _ -> (None) - ) -;; - -let parse_MsgDirection (str) = - (match str with - | "S" -> (Some (FIX_MsgDirection_Send)) - | "R" -> (Some (FIX_MsgDirection_Receive)) - | _ -> (None) - ) -;; - -let parse_MultiLegReportingType (str) = - (match str with - | "1" -> (Some (FIX_MultiLegReportingType_SingleSecurity)) - | "2" -> (Some (FIX_MultiLegReportingType_IndividualLegOfAMultiLegSecurity)) - | "3" -> (Some (FIX_MultiLegReportingType_MultiLegSecurity)) - | _ -> (None) - ) -;; - -let parse_MultiLegRptTypeReq (str) = - (match str with - | "0" -> (Some (FIX_MultiLegRptTypeReq_ReportByMulitlegSecurityOnly)) - | "1" -> (Some (FIX_MultiLegRptTypeReq_ReportByMultilegSecurityAndInstrumentLegs)) - | "2" -> (Some (FIX_MultiLegRptTypeReq_ReportByInstrumentLegsOnly)) - | _ -> (None) - ) -;; - -let parse_NetGrossInd (str) = - (match str with - | "1" -> (Some (FIX_NetGrossInd_Net)) - | "2" -> (Some (FIX_NetGrossInd_Gross)) - | _ -> (None) - ) -;; - -let parse_NetworkRequestType (str) = - (match str with - | "1" -> (Some (FIX_NetworkRequestType_Snapshot)) - | "2" -> (Some (FIX_NetworkRequestType_Subscribe)) - | "4" -> (Some (FIX_NetworkRequestType_StopSubscribing)) - | "8" -> (Some (FIX_NetworkRequestType_LevelOfDetail)) - | _ -> (None) - ) -;; - -let parse_NetworkStatusResponseType (str) = - (match str with - | "1" -> (Some (FIX_NetworkStatusResponseType_Full)) - | "2" -> (Some (FIX_NetworkStatusResponseType_IncrementalUpdate)) - | _ -> (None) - ) -;; - -let parse_NoSides (str) = - (match str with - | "1" -> (Some (FIX_NoSides_OneSide)) - | "2" -> (Some (FIX_NoSides_BothSides)) - | _ -> (None) - ) -;; - -let parse_NotifyBrokerOfCredit (str) = - (match str with - | "Y" -> (Some (FIX_NotifyBrokerOfCredit_DetailsShouldBeCommunicated)) - | "N" -> (Some (FIX_NotifyBrokerOfCredit_DetailsShouldNotBeCommunicated)) - | _ -> (None) - ) -;; - -let parse_OddLot (str) = - (match str with - | "Y" -> (Some (FIX_OddLot_TreatAsOddLot)) - | "N" -> (Some (FIX_OddLot_TreatAsRoundLot)) - | _ -> (None) - ) -;; - -let parse_inner_OpenCloseSettlFlag (str) = - (match str with - | "0" -> (Some (FIX_OpenCloseSettlFlag_DailyOpen)) - | "1" -> (Some (FIX_OpenCloseSettlFlag_SessionOpen)) - | "2" -> (Some (FIX_OpenCloseSettlFlag_DeliverySettlementEntry)) - | "3" -> (Some (FIX_OpenCloseSettlFlag_ExpectedEntry)) - | "4" -> (Some (FIX_OpenCloseSettlFlag_EntryFromPreviousBusinessDay)) - | "5" -> (Some (FIX_OpenCloseSettlFlag_TheoreticalPriceValue)) - | _ -> (None) - ) -;; - -let rec parse_OpenCloseSettlFlag_filter (f) = - (match f with - | [] -> [] - | h :: t -> ((match parse_inner_OpenCloseSettlFlag h with - | None -> (parse_OpenCloseSettlFlag_filter t) - | Some x -> (x :: (parse_OpenCloseSettlFlag_filter t)) - ) - ) - ) -;; - -let parse_OpenCloseSettlFlag (str) = - let x = split_to_list str ' ' in - Some (parse_OpenCloseSettlFlag_filter x) -;; - -let parse_OrdRejReason (str) = - (match str with - | "0" -> (Some (FIX_OrdRejReason_BrokerCredit)) - | "1" -> (Some (FIX_OrdRejReason_UnknownSymbol)) - | "2" -> (Some (FIX_OrdRejReason_ExchangeClosed)) - | "3" -> (Some (FIX_OrdRejReason_OrderExceedsLimit)) - | "4" -> (Some (FIX_OrdRejReason_TooLateToEnter)) - | "5" -> (Some (FIX_OrdRejReason_UnknownOrder)) - | "6" -> (Some (FIX_OrdRejReason_DuplicateOrder)) - | "7" -> (Some (FIX_OrdRejReason_DuplicateOfAVerballyCommunicatedOrder)) - | "8" -> (Some (FIX_OrdRejReason_StaleOrder)) - | "9" -> (Some (FIX_OrdRejReason_TradeAlongRequired)) - | "10" -> (Some (FIX_OrdRejReason_InvalidInvestorID)) - | "11" -> (Some (FIX_OrdRejReason_UnsupportedOrderCharacteristic)) - | "13" -> (Some (FIX_OrdRejReason_IncorrectQuantity)) - | "14" -> (Some (FIX_OrdRejReason_IncorrectAllocatedQuantity)) - | "15" -> (Some (FIX_OrdRejReason_UnknownAccount)) - | "99" -> (Some (FIX_OrdRejReason_Other)) - | _ -> (None) - ) -;; - -let parse_OrdStatus (str) = - (match str with - | "0" -> (Some (FIX_OrdStatus_New)) - | "1" -> (Some (FIX_OrdStatus_PartiallyFilled)) - | "2" -> (Some (FIX_OrdStatus_Filled)) - | "3" -> (Some (FIX_OrdStatus_DoneForDay)) - | "4" -> (Some (FIX_OrdStatus_Canceled)) - | "6" -> (Some (FIX_OrdStatus_PendingCancel)) - | "7" -> (Some (FIX_OrdStatus_Stopped)) - | "8" -> (Some (FIX_OrdStatus_Rejected)) - | "9" -> (Some (FIX_OrdStatus_Suspended)) - | "A" -> (Some (FIX_OrdStatus_PendingNew)) - | "B" -> (Some (FIX_OrdStatus_Calculated)) - | "C" -> (Some (FIX_OrdStatus_Expired)) - | "D" -> (Some (FIX_OrdStatus_AcceptedForBidding)) - | "E" -> (Some (FIX_OrdStatus_PendingReplace)) - | "5" -> (Some (FIX_OrdStatus_Replaced)) - | _ -> (None) - ) -;; - -let parse_OrdType (str) = - (match str with - | "1" -> (Some (FIX_OrdType_Market)) - | "2" -> (Some (FIX_OrdType_Limit)) - | "3" -> (Some (FIX_OrdType_Stop)) - | "4" -> (Some (FIX_OrdType_StopLimit)) - | "6" -> (Some (FIX_OrdType_WithOrWithout)) - | "7" -> (Some (FIX_OrdType_LimitOrBetter)) - | "8" -> (Some (FIX_OrdType_LimitWithOrWithout)) - | "9" -> (Some (FIX_OrdType_OnBasis)) - | "D" -> (Some (FIX_OrdType_PreviouslyQuoted)) - | "E" -> (Some (FIX_OrdType_PreviouslyIndicated)) - | "G" -> (Some (FIX_OrdType_ForexSwap)) - | "I" -> (Some (FIX_OrdType_Funari)) - | "J" -> (Some (FIX_OrdType_MarketIfTouched)) - | "K" -> (Some (FIX_OrdType_MarketWithLeftOverAsLimit)) - | "L" -> (Some (FIX_OrdType_PreviousFundValuationPoint)) - | "M" -> (Some (FIX_OrdType_NextFundValuationPoint)) - | "P" -> (Some (FIX_OrdType_Pegged)) - | _ -> (None) - ) -;; - -let parse_OrderCapacity (str) = - (match str with - | "A" -> (Some (FIX_OrderCapacity_Agency)) - | "G" -> (Some (FIX_OrderCapacity_Proprietary)) - | "I" -> (Some (FIX_OrderCapacity_Individual)) - | "P" -> (Some (FIX_OrderCapacity_Principal)) - | "R" -> (Some (FIX_OrderCapacity_RisklessPrincipal)) - | "W" -> (Some (FIX_OrderCapacity_AgentForOtherMember)) - | _ -> (None) - ) -;; - -let parse_inner_OrderRestrictions (str) = - (match str with - | "1" -> (Some (FIX_OrderRestrictions_ProgramTrade)) - | "2" -> (Some (FIX_OrderRestrictions_IndexArbitrage)) - | "3" -> (Some (FIX_OrderRestrictions_NonIndexArbitrage)) - | "4" -> (Some (FIX_OrderRestrictions_CompetingMarketMaker)) - | "5" -> (Some (FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInSecurity)) - | "6" -> (Some (FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInUnderlying)) - | "7" -> (Some (FIX_OrderRestrictions_ForeignEntity)) - | "8" -> (Some (FIX_OrderRestrictions_ExternalMarketParticipant)) - | "9" -> (Some (FIX_OrderRestrictions_ExternalInterConnectedMarketLinkage)) - | "A" -> (Some (FIX_OrderRestrictions_RisklessArbitrage)) - | _ -> (None) - ) -;; - -let rec parse_OrderRestrictions_filter (f) = - (match f with - | [] -> [] - | h :: t -> ((match parse_inner_OrderRestrictions h with - | None -> (parse_OrderRestrictions_filter t) - | Some x -> (x :: (parse_OrderRestrictions_filter t)) - ) - ) - ) -;; - -let parse_OrderRestrictions (str) = - let x = split_to_list str ' ' in - Some (parse_OrderRestrictions_filter x) -;; - -let parse_OwnerType (str) = - (match str with - | "1" -> (Some (FIX_OwnerType_IndividualInvestor)) - | "2" -> (Some (FIX_OwnerType_PublicCompany)) - | "3" -> (Some (FIX_OwnerType_PrivateCompany)) - | "4" -> (Some (FIX_OwnerType_IndividualTrustee)) - | "5" -> (Some (FIX_OwnerType_CompanyTrustee)) - | "6" -> (Some (FIX_OwnerType_PensionPlan)) - | "7" -> (Some (FIX_OwnerType_CustodianUnderGiftsToMinorsAct)) - | "8" -> (Some (FIX_OwnerType_Trusts)) - | "9" -> (Some (FIX_OwnerType_Fiduciaries)) - | "10" -> (Some (FIX_OwnerType_NetworkingSubAccount)) - | "11" -> (Some (FIX_OwnerType_NonProfitOrganization)) - | "12" -> (Some (FIX_OwnerType_CorporateBody)) - | "13" -> (Some (FIX_OwnerType_Nominee)) - | _ -> (None) - ) -;; - -let parse_OwnershipType (str) = - (match str with - | "J" -> (Some (FIX_OwnershipType_JointInvestors)) - | "T" -> (Some (FIX_OwnershipType_TenantsInCommon)) - | "2" -> (Some (FIX_OwnershipType_JointTrustees)) - | _ -> (None) - ) -;; - -let parse_PartyIDSource (str) = - (match str with - | "B" -> (Some (FIX_PartyIDSource_BIC)) - | "C" -> (Some (FIX_PartyIDSource_GeneralIdentifier)) - | "D" -> (Some (FIX_PartyIDSource_Proprietary)) - | "E" -> (Some (FIX_PartyIDSource_ISOCountryCode)) - | "F" -> (Some (FIX_PartyIDSource_SettlementEntityLocation)) - | "G" -> (Some (FIX_PartyIDSource_MIC)) - | "H" -> (Some (FIX_PartyIDSource_CSDParticipant)) - | "1" -> (Some (FIX_PartyIDSource_KoreanInvestorID)) - | "2" -> (Some (FIX_PartyIDSource_TaiwaneseForeignInvestorID)) - | "3" -> (Some (FIX_PartyIDSource_TaiwaneseTradingAcct)) - | "4" -> (Some (FIX_PartyIDSource_MalaysianCentralDepository)) - | "5" -> (Some (FIX_PartyIDSource_ChineseInvestorID)) - | "6" -> (Some (FIX_PartyIDSource_UKNationalInsuranceOrPensionNumber)) - | "7" -> (Some (FIX_PartyIDSource_USSocialSecurityNumber)) - | "8" -> (Some (FIX_PartyIDSource_USEmployerOrTaxIDNumber)) - | "9" -> (Some (FIX_PartyIDSource_AustralianBusinessNumber)) - | "A" -> (Some (FIX_PartyIDSource_AustralianTaxFileNumber)) - | "I" -> (Some (FIX_PartyIDSource_ISITCAcronym)) - | _ -> (None) - ) -;; - -let parse_PartyRole (str) = - (match str with - | "1" -> (Some (FIX_PartyRole_ExecutingFirm)) - | "2" -> (Some (FIX_PartyRole_BrokerOfCredit)) - | "3" -> (Some (FIX_PartyRole_ClientID)) - | "4" -> (Some (FIX_PartyRole_ClearingFirm)) - | "5" -> (Some (FIX_PartyRole_InvestorID)) - | "6" -> (Some (FIX_PartyRole_IntroducingFirm)) - | "7" -> (Some (FIX_PartyRole_EnteringFirm)) - | "8" -> (Some (FIX_PartyRole_Locate)) - | "9" -> (Some (FIX_PartyRole_FundManagerClientID)) - | "10" -> (Some (FIX_PartyRole_SettlementLocation)) - | "11" -> (Some (FIX_PartyRole_OrderOriginationTrader)) - | "12" -> (Some (FIX_PartyRole_ExecutingTrader)) - | "13" -> (Some (FIX_PartyRole_OrderOriginationFirm)) - | "14" -> (Some (FIX_PartyRole_GiveupClearingFirm)) - | "15" -> (Some (FIX_PartyRole_CorrespondantClearingFirm)) - | "16" -> (Some (FIX_PartyRole_ExecutingSystem)) - | "17" -> (Some (FIX_PartyRole_ContraFirm)) - | "18" -> (Some (FIX_PartyRole_ContraClearingFirm)) - | "19" -> (Some (FIX_PartyRole_SponsoringFirm)) - | "20" -> (Some (FIX_PartyRole_UnderlyingContraFirm)) - | "21" -> (Some (FIX_PartyRole_ClearingOrganization)) - | "22" -> (Some (FIX_PartyRole_Exchange)) - | "24" -> (Some (FIX_PartyRole_CustomerAccount)) - | "25" -> (Some (FIX_PartyRole_CorrespondentClearingOrganization)) - | "26" -> (Some (FIX_PartyRole_CorrespondentBroker)) - | "27" -> (Some (FIX_PartyRole_Buyer)) - | "28" -> (Some (FIX_PartyRole_Custodian)) - | "29" -> (Some (FIX_PartyRole_Intermediary)) - | "30" -> (Some (FIX_PartyRole_Agent)) - | "31" -> (Some (FIX_PartyRole_SubCustodian)) - | "32" -> (Some (FIX_PartyRole_Beneficiary)) - | "33" -> (Some (FIX_PartyRole_InterestedParty)) - | "34" -> (Some (FIX_PartyRole_RegulatoryBody)) - | "35" -> (Some (FIX_PartyRole_LiquidityProvider)) - | "36" -> (Some (FIX_PartyRole_EnteringTrader)) - | "37" -> (Some (FIX_PartyRole_ContraTrader)) - | "38" -> (Some (FIX_PartyRole_PositionAccount)) - | _ -> (None) - ) -;; - -let parse_PartySubIDType (str) = - (match str with - | "1" -> (Some (FIX_PartySubIDType_Firm)) - | "2" -> (Some (FIX_PartySubIDType_Person)) - | "3" -> (Some (FIX_PartySubIDType_System)) - | "4" -> (Some (FIX_PartySubIDType_Application)) - | "5" -> (Some (FIX_PartySubIDType_FullLegalNameOfFirm)) - | "6" -> (Some (FIX_PartySubIDType_PostalAddress)) - | "7" -> (Some (FIX_PartySubIDType_PhoneNumber)) - | "8" -> (Some (FIX_PartySubIDType_EmailAddress)) - | "9" -> (Some (FIX_PartySubIDType_ContactName)) - | "10" -> (Some (FIX_PartySubIDType_SecuritiesAccountNumber)) - | "11" -> (Some (FIX_PartySubIDType_RegistrationNumber)) - | "12" -> (Some (FIX_PartySubIDType_RegisteredAddressForConfirmation)) - | "13" -> (Some (FIX_PartySubIDType_RegulatoryStatus)) - | "14" -> (Some (FIX_PartySubIDType_RegistrationName)) - | "15" -> (Some (FIX_PartySubIDType_CashAccountNumber)) - | "16" -> (Some (FIX_PartySubIDType_BIC)) - | "17" -> (Some (FIX_PartySubIDType_CSDParticipantMemberCode)) - | "18" -> (Some (FIX_PartySubIDType_RegisteredAddress)) - | "19" -> (Some (FIX_PartySubIDType_FundAccountName)) - | "20" -> (Some (FIX_PartySubIDType_TelexNumber)) - | "21" -> (Some (FIX_PartySubIDType_FaxNumber)) - | "22" -> (Some (FIX_PartySubIDType_SecuritiesAccountName)) - | "23" -> (Some (FIX_PartySubIDType_CashAccountName)) - | "24" -> (Some (FIX_PartySubIDType_Department)) - | "25" -> (Some (FIX_PartySubIDType_LocationDesk)) - | "26" -> (Some (FIX_PartySubIDType_PositionAccountType)) - | _ -> (None) - ) -;; - -let parse_PaymentMethod (str) = - (match str with - | "1" -> (Some (FIX_PaymentMethod_CREST)) - | "2" -> (Some (FIX_PaymentMethod_NSCC)) - | "3" -> (Some (FIX_PaymentMethod_Euroclear)) - | "4" -> (Some (FIX_PaymentMethod_Clearstream)) - | "5" -> (Some (FIX_PaymentMethod_Cheque)) - | "6" -> (Some (FIX_PaymentMethod_TelegraphicTransfer)) - | "7" -> (Some (FIX_PaymentMethod_FedWire)) - | "8" -> (Some (FIX_PaymentMethod_DebitCard)) - | "9" -> (Some (FIX_PaymentMethod_DirectDebit)) - | "10" -> (Some (FIX_PaymentMethod_DirectCredit)) - | "11" -> (Some (FIX_PaymentMethod_CreditCard)) - | "12" -> (Some (FIX_PaymentMethod_ACHDebit)) - | "13" -> (Some (FIX_PaymentMethod_ACHCredit)) - | "14" -> (Some (FIX_PaymentMethod_BPAY)) - | "15" -> (Some (FIX_PaymentMethod_HighValueClearingSystem)) - | _ -> (None) - ) -;; - -let parse_PegLimitType (str) = - (match str with - | "0" -> (Some (FIX_PegLimitType_OrBetter)) - | "1" -> (Some (FIX_PegLimitType_Strict)) - | "2" -> (Some (FIX_PegLimitType_OrWorse)) - | _ -> (None) - ) -;; - -let parse_PegMoveType (str) = - (match str with - | "0" -> (Some (FIX_PegMoveType_Floating)) - | "1" -> (Some (FIX_PegMoveType_Fixed)) - | _ -> (None) - ) -;; - -let parse_PegOffsetType (str) = - (match str with - | "0" -> (Some (FIX_PegOffsetType_Price)) - | "1" -> (Some (FIX_PegOffsetType_BasisPoints)) - | "2" -> (Some (FIX_PegOffsetType_Ticks)) - | "3" -> (Some (FIX_PegOffsetType_PriceTier)) - | _ -> (None) - ) -;; - -let parse_PegRoundDirection (str) = - (match str with - | "1" -> (Some (FIX_PegRoundDirection_MoreAggressive)) - | "2" -> (Some (FIX_PegRoundDirection_MorePassive)) - | _ -> (None) - ) -;; - -let parse_PegScope (str) = - (match str with - | "1" -> (Some (FIX_PegScope_Local)) - | "2" -> (Some (FIX_PegScope_National)) - | "3" -> (Some (FIX_PegScope_Global)) - | "4" -> (Some (FIX_PegScope_NationalExcludingLocal)) - | _ -> (None) - ) -;; - -let parse_PosAmtType (str) = - (match str with - | "FMTM" -> (Some (FIX_PosAmtType_FinalMarkToMarketAmount)) - | "IMTM" -> (Some (FIX_PosAmtType_IncrementalMarkToMarketAmount)) - | "TVAR" -> (Some (FIX_PosAmtType_TradeVariationAmount)) - | "SMTM" -> (Some (FIX_PosAmtType_StartOfDayMarkToMarketAmount)) - | "PREM" -> (Some (FIX_PosAmtType_PremiumAmount)) - | "CRES" -> (Some (FIX_PosAmtType_CashResidualAmount)) - | "CASH" -> (Some (FIX_PosAmtType_CashAmount)) - | "VADJ" -> (Some (FIX_PosAmtType_ValueAdjustedAmount)) - | _ -> (None) - ) -;; - -let parse_PosMaintAction (str) = - (match str with - | "1" -> (Some (FIX_PosMaintAction_New)) - | "2" -> (Some (FIX_PosMaintAction_Replace)) - | "3" -> (Some (FIX_PosMaintAction_Cancel)) - | _ -> (None) - ) -;; - -let parse_PosMaintResult (str) = - (match str with - | "0" -> (Some (FIX_PosMaintResult_SuccessfulCompletion)) - | "1" -> (Some (FIX_PosMaintResult_Rejected)) - | "99" -> (Some (FIX_PosMaintResult_Other)) - | _ -> (None) - ) -;; - -let parse_PosMaintStatus (str) = - (match str with - | "0" -> (Some (FIX_PosMaintStatus_Accepted)) - | "1" -> (Some (FIX_PosMaintStatus_AcceptedWithWarnings)) - | "2" -> (Some (FIX_PosMaintStatus_Rejected)) - | "3" -> (Some (FIX_PosMaintStatus_Completed)) - | "4" -> (Some (FIX_PosMaintStatus_CompletedWithWarnings)) - | _ -> (None) - ) -;; - -let parse_PosQtyStatus (str) = - (match str with - | "0" -> (Some (FIX_PosQtyStatus_Submitted)) - | "1" -> (Some (FIX_PosQtyStatus_Accepted)) - | "2" -> (Some (FIX_PosQtyStatus_Rejected)) - | _ -> (None) - ) -;; - -let parse_PosReqResult (str) = - (match str with - | "0" -> (Some (FIX_PosReqResult_ValidRequest)) - | "1" -> (Some (FIX_PosReqResult_InvalidOrUnsupportedRequest)) - | "2" -> (Some (FIX_PosReqResult_NoPositionsFoundThatMatchCriteria)) - | "3" -> (Some (FIX_PosReqResult_NotAuthorizedToRequestPositions)) - | "4" -> (Some (FIX_PosReqResult_RequestForPositionNotSupported)) - | "99" -> (Some (FIX_PosReqResult_Other)) - | _ -> (None) - ) -;; - -let parse_PosReqStatus (str) = - (match str with - | "0" -> (Some (FIX_PosReqStatus_Completed)) - | "1" -> (Some (FIX_PosReqStatus_CompletedWithWarnings)) - | "2" -> (Some (FIX_PosReqStatus_Rejected)) - | _ -> (None) - ) -;; - -let parse_PosReqType (str) = - (match str with - | "0" -> (Some (FIX_PosReqType_Positions)) - | "1" -> (Some (FIX_PosReqType_Trades)) - | "2" -> (Some (FIX_PosReqType_Exercises)) - | "3" -> (Some (FIX_PosReqType_Assignments)) - | _ -> (None) - ) -;; - -let parse_PosTransType (str) = - (match str with - | "1" -> (Some (FIX_PosTransType_Exercise)) - | "2" -> (Some (FIX_PosTransType_DoNotExercise)) - | "3" -> (Some (FIX_PosTransType_PositionAdjustment)) - | "4" -> (Some (FIX_PosTransType_PositionChangeSubmission)) - | "5" -> (Some (FIX_PosTransType_Pledge)) - | _ -> (None) - ) -;; - -let parse_PosType (str) = - (match str with - | "TQ" -> (Some (FIX_PosType_TransactionQuantity)) - | "IAS" -> (Some (FIX_PosType_IntraSpreadQty)) - | "IES" -> (Some (FIX_PosType_InterSpreadQty)) - | "FIN" -> (Some (FIX_PosType_EndOfDayQty)) - | "SOD" -> (Some (FIX_PosType_StartOfDayQty)) - | "EX" -> (Some (FIX_PosType_OptionExerciseQty)) - | "AS" -> (Some (FIX_PosType_OptionAssignment)) - | "TX" -> (Some (FIX_PosType_TransactionFromExercise)) - | "TA" -> (Some (FIX_PosType_TransactionFromAssignment)) - | "PIT" -> (Some (FIX_PosType_PitTradeQty)) - | "TRF" -> (Some (FIX_PosType_TransferTradeQty)) - | "ETR" -> (Some (FIX_PosType_ElectronicTradeQty)) - | "ALC" -> (Some (FIX_PosType_AllocationTradeQty)) - | "PA" -> (Some (FIX_PosType_AdjustmentQty)) - | "ASF" -> (Some (FIX_PosType_AsOfTradeQty)) - | "DLV" -> (Some (FIX_PosType_DeliveryQty)) - | "TOT" -> (Some (FIX_PosType_TotalTransactionQty)) - | "XM" -> (Some (FIX_PosType_CrossMarginQty)) - | "SPL" -> (Some (FIX_PosType_IntegralSplit)) - | _ -> (None) - ) -;; - -let parse_PositionEffect (str) = - (match str with - | "O" -> (Some (FIX_PositionEffect_Open)) - | "C" -> (Some (FIX_PositionEffect_Close)) - | "R" -> (Some (FIX_PositionEffect_Rolled)) - | "F" -> (Some (FIX_PositionEffect_FIFO)) - | _ -> (None) - ) -;; - -let parse_PossDupFlag (str) = - (match str with - | "Y" -> (Some (FIX_PossDupFlag_PossibleDuplicate)) - | "N" -> (Some (FIX_PossDupFlag_OriginalTransmission)) - | _ -> (None) - ) -;; - -let parse_PossResend (str) = - (match str with - | "Y" -> (Some (FIX_PossResend_PossibleResend)) - | "N" -> (Some (FIX_PossResend_OriginalTransmission)) - | _ -> (None) - ) -;; - -let parse_PreallocMethod (str) = - (match str with - | "0" -> (Some (FIX_PreallocMethod_ProRata)) - | "1" -> (Some (FIX_PreallocMethod_DoNotProRata)) - | _ -> (None) - ) -;; - -let parse_PreviouslyReported (str) = - (match str with - | "Y" -> (Some (FIX_PreviouslyReported_PerviouslyReportedToCounterparty)) - | "N" -> (Some (FIX_PreviouslyReported_NotReportedToCounterparty)) - | _ -> (None) - ) -;; - -let parse_PriceType (str) = - (match str with - | "1" -> (Some (FIX_PriceType_Percentage)) - | "2" -> (Some (FIX_PriceType_PerUnit)) - | "3" -> (Some (FIX_PriceType_FixedAmount)) - | "4" -> (Some (FIX_PriceType_Discount)) - | "5" -> (Some (FIX_PriceType_Premium)) - | "6" -> (Some (FIX_PriceType_Spread)) - | "7" -> (Some (FIX_PriceType_TEDPrice)) - | "8" -> (Some (FIX_PriceType_TEDYield)) - | "9" -> (Some (FIX_PriceType_Yield)) - | "10" -> (Some (FIX_PriceType_FixedCabinetTradePrice)) - | "11" -> (Some (FIX_PriceType_VariableCabinetTradePrice)) - | _ -> (None) - ) -;; - -let parse_PriorityIndicator (str) = - (match str with - | "0" -> (Some (FIX_PriorityIndicator_PriorityUnchanged)) - | "1" -> (Some (FIX_PriorityIndicator_LostPriorityAsResultOfOrderChange)) - | _ -> (None) - ) -;; - -let parse_ProcessCode (str) = - (match str with - | "0" -> (Some (FIX_ProcessCode_Regular)) - | "1" -> (Some (FIX_ProcessCode_SoftDollar)) - | "2" -> (Some (FIX_ProcessCode_StepIn)) - | "3" -> (Some (FIX_ProcessCode_StepOut)) - | "4" -> (Some (FIX_ProcessCode_SoftDollarStepIn)) - | "5" -> (Some (FIX_ProcessCode_SoftDollarStepOut)) - | "6" -> (Some (FIX_ProcessCode_PlanSponsor)) - | _ -> (None) - ) -;; - -let parse_Product (str) = - (match str with - | "1" -> (Some (FIX_Product_AGENCY)) - | "2" -> (Some (FIX_Product_COMMODITY)) - | "3" -> (Some (FIX_Product_CORPORATE)) - | "4" -> (Some (FIX_Product_CURRENCY)) - | "5" -> (Some (FIX_Product_EQUITY)) - | "6" -> (Some (FIX_Product_GOVERNMENT)) - | "7" -> (Some (FIX_Product_INDEX)) - | "8" -> (Some (FIX_Product_LOAN)) - | "9" -> (Some (FIX_Product_MONEYMARKET)) - | "10" -> (Some (FIX_Product_MORTGAGE)) - | "11" -> (Some (FIX_Product_MUNICIPAL)) - | "12" -> (Some (FIX_Product_OTHER)) - | "13" -> (Some (FIX_Product_FINANCING)) - | _ -> (None) - ) -;; - -let parse_ProgRptReqs (str) = - (match str with - | "1" -> (Some (FIX_ProgRptReqs_BuySideRequests)) - | "2" -> (Some (FIX_ProgRptReqs_SellSideSends)) - | "3" -> (Some (FIX_ProgRptReqs_RealTimeExecutionReports)) - | _ -> (None) - ) -;; - -let parse_PublishTrdIndicator (str) = - (match str with - | "Y" -> (Some (FIX_PublishTrdIndicator_ReportTrade)) - | "N" -> (Some (FIX_PublishTrdIndicator_DoNotReportTrade)) - | _ -> (None) - ) -;; - -let parse_PutOrCall (str) = - (match str with - | "0" -> (Some (FIX_PutOrCall_Put)) - | "1" -> (Some (FIX_PutOrCall_Call)) - | _ -> (None) - ) -;; - -let parse_QtyType (str) = - (match str with - | "0" -> (Some (FIX_QtyType_Units)) - | "1" -> (Some (FIX_QtyType_Contracts)) - | _ -> (None) - ) -;; - -let parse_QuoteCancelType (str) = - (match str with - | "1" -> (Some (FIX_QuoteCancelType_CancelForOneOrMoreSecurities)) - | "2" -> (Some (FIX_QuoteCancelType_CancelForSecurityType)) - | "3" -> (Some (FIX_QuoteCancelType_CancelForUnderlyingSecurity)) - | "4" -> (Some (FIX_QuoteCancelType_CancelAllQuotes)) - | _ -> (None) - ) -;; - -let parse_inner_QuoteCondition (str) = - (match str with - | "A" -> (Some (FIX_QuoteCondition_Open)) - | "B" -> (Some (FIX_QuoteCondition_Closed)) - | "C" -> (Some (FIX_QuoteCondition_ExchangeBest)) - | "D" -> (Some (FIX_QuoteCondition_ConsolidatedBest)) - | "E" -> (Some (FIX_QuoteCondition_Locked)) - | "F" -> (Some (FIX_QuoteCondition_Crossed)) - | "G" -> (Some (FIX_QuoteCondition_Depth)) - | "H" -> (Some (FIX_QuoteCondition_FastTrading)) - | "I" -> (Some (FIX_QuoteCondition_NonFirm)) - | _ -> (None) - ) -;; - -let rec parse_QuoteCondition_filter (f) = - (match f with - | [] -> [] - | h :: t -> ((match parse_inner_QuoteCondition h with - | None -> (parse_QuoteCondition_filter t) - | Some x -> (x :: (parse_QuoteCondition_filter t)) - ) - ) - ) -;; - -let parse_QuoteCondition (str) = - let x = split_to_list str ' ' in - Some (parse_QuoteCondition_filter x) -;; - -let parse_QuotePriceType (str) = - (match str with - | "1" -> (Some (FIX_QuotePriceType_Percent)) - | "2" -> (Some (FIX_QuotePriceType_PerShare)) - | "3" -> (Some (FIX_QuotePriceType_FixedAmount)) - | "4" -> (Some (FIX_QuotePriceType_Discount)) - | "5" -> (Some (FIX_QuotePriceType_Premium)) - | "6" -> (Some (FIX_QuotePriceType_Spread)) - | "7" -> (Some (FIX_QuotePriceType_TEDPrice)) - | "8" -> (Some (FIX_QuotePriceType_TEDYield)) - | "9" -> (Some (FIX_QuotePriceType_YieldSpread)) - | "10" -> (Some (FIX_QuotePriceType_Yield)) - | _ -> (None) - ) -;; - -let parse_QuoteRejectReason (str) = - (match str with - | "1" -> (Some (FIX_QuoteRejectReason_UnknownSymbol)) - | "2" -> (Some (FIX_QuoteRejectReason_Exchange)) - | "3" -> (Some (FIX_QuoteRejectReason_QuoteRequestExceedsLimit)) - | "4" -> (Some (FIX_QuoteRejectReason_TooLateToEnter)) - | "5" -> (Some (FIX_QuoteRejectReason_UnknownQuote)) - | "6" -> (Some (FIX_QuoteRejectReason_DuplicateQuote)) - | "7" -> (Some (FIX_QuoteRejectReason_InvalidBid)) - | "8" -> (Some (FIX_QuoteRejectReason_InvalidPrice)) - | "9" -> (Some (FIX_QuoteRejectReason_NotAuthorizedToQuoteSecurity)) - | "99" -> (Some (FIX_QuoteRejectReason_Other)) - | _ -> (None) - ) -;; - -let parse_QuoteRequestRejectReason (str) = - (match str with - | "1" -> (Some (FIX_QuoteRequestRejectReason_UnknownSymbol)) - | "2" -> (Some (FIX_QuoteRequestRejectReason_Exchange)) - | "3" -> (Some (FIX_QuoteRequestRejectReason_QuoteRequestExceedsLimit)) - | "4" -> (Some (FIX_QuoteRequestRejectReason_TooLateToEnter)) - | "5" -> (Some (FIX_QuoteRequestRejectReason_InvalidPrice)) - | "6" -> (Some (FIX_QuoteRequestRejectReason_NotAuthorizedToRequestQuote)) - | "7" -> (Some (FIX_QuoteRequestRejectReason_NoMatchForInquiry)) - | "8" -> (Some (FIX_QuoteRequestRejectReason_NoMarketForInstrument)) - | "9" -> (Some (FIX_QuoteRequestRejectReason_NoInventory)) - | "10" -> (Some (FIX_QuoteRequestRejectReason_Pass)) - | "99" -> (Some (FIX_QuoteRequestRejectReason_Other)) - | _ -> (None) - ) -;; - -let parse_QuoteRequestType (str) = - (match str with - | "1" -> (Some (FIX_QuoteRequestType_Manual)) - | "2" -> (Some (FIX_QuoteRequestType_Automatic)) - | _ -> (None) - ) -;; - -let parse_QuoteRespType (str) = - (match str with - | "1" -> (Some (FIX_QuoteRespType_Hit)) - | "2" -> (Some (FIX_QuoteRespType_Counter)) - | "3" -> (Some (FIX_QuoteRespType_Expired)) - | "4" -> (Some (FIX_QuoteRespType_Cover)) - | "5" -> (Some (FIX_QuoteRespType_DoneAway)) - | "6" -> (Some (FIX_QuoteRespType_Pass)) - | _ -> (None) - ) -;; - -let parse_QuoteResponseLevel (str) = - (match str with - | "0" -> (Some (FIX_QuoteResponseLevel_NoAcknowledgement)) - | "1" -> (Some (FIX_QuoteResponseLevel_AcknowledgeOnlyNegativeOrErroneousQuotes)) - | "2" -> (Some (FIX_QuoteResponseLevel_AcknowledgeEachQuoteMessage)) - | _ -> (None) - ) -;; - -let parse_QuoteStatus (str) = - (match str with - | "0" -> (Some (FIX_QuoteStatus_Accepted)) - | "1" -> (Some (FIX_QuoteStatus_CancelForSymbol)) - | "2" -> (Some (FIX_QuoteStatus_CanceledForSecurityType)) - | "3" -> (Some (FIX_QuoteStatus_CanceledForUnderlying)) - | "4" -> (Some (FIX_QuoteStatus_CanceledAll)) - | "5" -> (Some (FIX_QuoteStatus_Rejected)) - | "6" -> (Some (FIX_QuoteStatus_RemovedFromMarket)) - | "7" -> (Some (FIX_QuoteStatus_Expired)) - | "8" -> (Some (FIX_QuoteStatus_Query)) - | "9" -> (Some (FIX_QuoteStatus_QuoteNotFound)) - | "10" -> (Some (FIX_QuoteStatus_Pending)) - | "11" -> (Some (FIX_QuoteStatus_Pass)) - | "12" -> (Some (FIX_QuoteStatus_LockedMarketWarning)) - | "13" -> (Some (FIX_QuoteStatus_CrossMarketWarning)) - | "14" -> (Some (FIX_QuoteStatus_CanceledDueToLockMarket)) - | "15" -> (Some (FIX_QuoteStatus_CanceledDueToCrossMarket)) - | _ -> (None) - ) -;; - -let parse_QuoteType (str) = - (match str with - | "0" -> (Some (FIX_QuoteType_Indicative)) - | "1" -> (Some (FIX_QuoteType_Tradeable)) - | "2" -> (Some (FIX_QuoteType_RestrictedTradeable)) - | "3" -> (Some (FIX_QuoteType_Counter)) - | _ -> (None) - ) -;; - -let parse_RegistRejReasonCode (str) = - (match str with - | "1" -> (Some (FIX_RegistRejReasonCode_InvalidAccountType)) - | "2" -> (Some (FIX_RegistRejReasonCode_InvalidTaxExemptType)) - | "3" -> (Some (FIX_RegistRejReasonCode_InvalidOwnershipType)) - | "4" -> (Some (FIX_RegistRejReasonCode_NoRegDetails)) - | "5" -> (Some (FIX_RegistRejReasonCode_InvalidRegSeqNo)) - | "6" -> (Some (FIX_RegistRejReasonCode_InvalidRegDetails)) - | "7" -> (Some (FIX_RegistRejReasonCode_InvalidMailingDetails)) - | "8" -> (Some (FIX_RegistRejReasonCode_InvalidMailingInstructions)) - | "9" -> (Some (FIX_RegistRejReasonCode_InvalidInvestorID)) - | "10" -> (Some (FIX_RegistRejReasonCode_InvalidInvestorIDSource)) - | "11" -> (Some (FIX_RegistRejReasonCode_InvalidDateOfBirth)) - | "12" -> (Some (FIX_RegistRejReasonCode_InvalidCountry)) - | "13" -> (Some (FIX_RegistRejReasonCode_InvalidDistribInstns)) - | "14" -> (Some (FIX_RegistRejReasonCode_InvalidPercentage)) - | "15" -> (Some (FIX_RegistRejReasonCode_InvalidPaymentMethod)) - | "16" -> (Some (FIX_RegistRejReasonCode_InvalidAccountName)) - | "17" -> (Some (FIX_RegistRejReasonCode_InvalidAgentCode)) - | "18" -> (Some (FIX_RegistRejReasonCode_InvalidAccountNum)) - | "99" -> (Some (FIX_RegistRejReasonCode_Other)) - | _ -> (None) - ) -;; - -let parse_RegistStatus (str) = - (match str with - | "A" -> (Some (FIX_RegistStatus_Accepted)) - | "R" -> (Some (FIX_RegistStatus_Rejected)) - | "H" -> (Some (FIX_RegistStatus_Held)) - | "N" -> (Some (FIX_RegistStatus_Reminder)) - | _ -> (None) - ) -;; - -let parse_RegistTransType (str) = - (match str with - | "0" -> (Some (FIX_RegistTransType_New)) - | "1" -> (Some (FIX_RegistTransType_Replace)) - | "2" -> (Some (FIX_RegistTransType_Cancel)) - | _ -> (None) - ) -;; - -let parse_ReportToExch (str) = - (match str with - | "Y" -> (Some (FIX_ReportToExch_ReceiverReports)) - | "N" -> (Some (FIX_ReportToExch_SenderReports)) - | _ -> (None) - ) -;; - -let parse_ResetSeqNumFlag (str) = - (match str with - | "Y" -> (Some (FIX_ResetSeqNumFlag_Yes)) - | "N" -> (Some (FIX_ResetSeqNumFlag_No)) - | _ -> (None) - ) -;; - -let parse_ResponseTransportType (str) = - (match str with - | "0" -> (Some (FIX_ResponseTransportType_Inband)) - | "1" -> (Some (FIX_ResponseTransportType_OutOfBand)) - | _ -> (None) - ) -;; - -let parse_RoundingDirection (str) = - (match str with - | "0" -> (Some (FIX_RoundingDirection_RoundToNearest)) - | "1" -> (Some (FIX_RoundingDirection_RoundDown)) - | "2" -> (Some (FIX_RoundingDirection_RoundUp)) - | _ -> (None) - ) -;; - -let parse_RoutingType (str) = - (match str with - | "1" -> (Some (FIX_RoutingType_TargetFirm)) - | "2" -> (Some (FIX_RoutingType_TargetList)) - | "3" -> (Some (FIX_RoutingType_BlockFirm)) - | "4" -> (Some (FIX_RoutingType_BlockList)) - | _ -> (None) - ) -;; - -let parse_inner_Scope (str) = - (match str with - | "1" -> (Some (FIX_Scope_LocalMarket)) - | "2" -> (Some (FIX_Scope_National)) - | "3" -> (Some (FIX_Scope_Global)) - | _ -> (None) - ) -;; - -let rec parse_Scope_filter (f) = - (match f with - | [] -> [] - | h :: t -> ((match parse_inner_Scope h with - | None -> (parse_Scope_filter t) - | Some x -> (x :: (parse_Scope_filter t)) - ) - ) - ) -;; - -let parse_Scope (str) = - let x = split_to_list str ' ' in - Some (parse_Scope_filter x) -;; - -let parse_SecurityIDSource (str) = - (match str with - | "1" -> (Some (FIX_SecurityIDSource_CUSIP)) - | "2" -> (Some (FIX_SecurityIDSource_SEDOL)) - | "3" -> (Some (FIX_SecurityIDSource_QUIK)) - | "4" -> (Some (FIX_SecurityIDSource_ISINNumber)) - | "5" -> (Some (FIX_SecurityIDSource_RICCode)) - | "6" -> (Some (FIX_SecurityIDSource_ISOCurrencyCode)) - | "7" -> (Some (FIX_SecurityIDSource_ISOCountryCode)) - | "8" -> (Some (FIX_SecurityIDSource_ExchangeSymbol)) - | "9" -> (Some (FIX_SecurityIDSource_ConsolidatedTapeAssociation)) - | "A" -> (Some (FIX_SecurityIDSource_BloombergSymbol)) - | "B" -> (Some (FIX_SecurityIDSource_Wertpapier)) - | "C" -> (Some (FIX_SecurityIDSource_Dutch)) - | "D" -> (Some (FIX_SecurityIDSource_Valoren)) - | "E" -> (Some (FIX_SecurityIDSource_Sicovam)) - | "F" -> (Some (FIX_SecurityIDSource_Belgian)) - | "G" -> (Some (FIX_SecurityIDSource_Common)) - | "H" -> (Some (FIX_SecurityIDSource_ClearingHouse)) - | "I" -> (Some (FIX_SecurityIDSource_ISDAFpMLSpecification)) - | "J" -> (Some (FIX_SecurityIDSource_OptionPriceReportingAuthority)) - | _ -> (None) - ) -;; - -let parse_SecurityListRequestType (str) = - (match str with - | "0" -> (Some (FIX_SecurityListRequestType_Symbol)) - | "1" -> (Some (FIX_SecurityListRequestType_SecurityTypeAnd)) - | "2" -> (Some (FIX_SecurityListRequestType_Product)) - | "3" -> (Some (FIX_SecurityListRequestType_TradingSessionID)) - | "4" -> (Some (FIX_SecurityListRequestType_AllSecurities)) - | _ -> (None) - ) -;; - -let parse_SecurityRequestResult (str) = - (match str with - | "0" -> (Some (FIX_SecurityRequestResult_ValidRequest)) - | "1" -> (Some (FIX_SecurityRequestResult_InvalidOrUnsupportedRequest)) - | "2" -> (Some (FIX_SecurityRequestResult_NoInstrumentsFound)) - | "3" -> (Some (FIX_SecurityRequestResult_NotAuthorizedToRetrieveInstrumentData)) - | "4" -> (Some (FIX_SecurityRequestResult_InstrumentDataTemporarilyUnavailable)) - | "5" -> (Some (FIX_SecurityRequestResult_RequestForInstrumentDataNotSupported)) - | _ -> (None) - ) -;; - -let parse_SecurityRequestType (str) = - (match str with - | "0" -> (Some (FIX_SecurityRequestType_RequestSecurityIdentityAndSpecifications)) - | "1" -> (Some (FIX_SecurityRequestType_RequestSecurityIdentityForSpecifications)) - | "2" -> (Some (FIX_SecurityRequestType_RequestListSecurityTypes)) - | "3" -> (Some (FIX_SecurityRequestType_RequestListSecurities)) - | _ -> (None) - ) -;; - -let parse_SecurityResponseType (str) = - (match str with - | "1" -> (Some (FIX_SecurityResponseType_AcceptAsIs)) - | "2" -> (Some (FIX_SecurityResponseType_AcceptWithRevisions)) - | "5" -> (Some (FIX_SecurityResponseType_RejectSecurityProposal)) - | "6" -> (Some (FIX_SecurityResponseType_CannotMatchSelectionCriteria)) - | _ -> (None) - ) -;; - -let parse_SecurityTradingStatus (str) = - (match str with - | "1" -> (Some (FIX_SecurityTradingStatus_OpeningDelay)) - | "2" -> (Some (FIX_SecurityTradingStatus_TradingHalt)) - | "3" -> (Some (FIX_SecurityTradingStatus_Resume)) - | "4" -> (Some (FIX_SecurityTradingStatus_NoOpen)) - | "5" -> (Some (FIX_SecurityTradingStatus_PriceIndication)) - | "6" -> (Some (FIX_SecurityTradingStatus_TradingRangeIndication)) - | "7" -> (Some (FIX_SecurityTradingStatus_MarketImbalanceBuy)) - | "8" -> (Some (FIX_SecurityTradingStatus_MarketImbalanceSell)) - | "9" -> (Some (FIX_SecurityTradingStatus_MarketOnCloseImbalanceBuy)) - | "10" -> (Some (FIX_SecurityTradingStatus_MarketOnCloseImbalanceSell)) - | "12" -> (Some (FIX_SecurityTradingStatus_NoMarketImbalance)) - | "13" -> (Some (FIX_SecurityTradingStatus_NoMarketOnCloseImbalance)) - | "14" -> (Some (FIX_SecurityTradingStatus_ITSPreOpening)) - | "15" -> (Some (FIX_SecurityTradingStatus_NewPriceIndication)) - | "16" -> (Some (FIX_SecurityTradingStatus_TradeDisseminationTime)) - | "17" -> (Some (FIX_SecurityTradingStatus_ReadyToTrade)) - | "18" -> (Some (FIX_SecurityTradingStatus_NotAvailableForTrading)) - | "19" -> (Some (FIX_SecurityTradingStatus_NotTradedOnThisMarket)) - | "20" -> (Some (FIX_SecurityTradingStatus_UnknownOrInvalid)) - | "21" -> (Some (FIX_SecurityTradingStatus_PreOpen)) - | "22" -> (Some (FIX_SecurityTradingStatus_OpeningRotation)) - | "23" -> (Some (FIX_SecurityTradingStatus_FastMarket)) - | _ -> (None) - ) -;; - -let parse_SecurityType (str) = - (match str with - | "FUT" -> (Some (FIX_SecurityType_Future)) - | "OPT" -> (Some (FIX_SecurityType_Option)) - | "EUSUPRA" -> (Some (FIX_SecurityType_EuroSupranationalCoupons)) - | "FAC" -> (Some (FIX_SecurityType_FederalAgencyCoupon)) - | "FADN" -> (Some (FIX_SecurityType_FederalAgencyDiscountNote)) - | "PEF" -> (Some (FIX_SecurityType_PrivateExportFunding)) - | "SUPRA" -> (Some (FIX_SecurityType_USDSupranationalCoupons)) - | "CORP" -> (Some (FIX_SecurityType_CorporateBond)) - | "CPP" -> (Some (FIX_SecurityType_CorporatePrivatePlacement)) - | "CB" -> (Some (FIX_SecurityType_ConvertibleBond)) - | "DUAL" -> (Some (FIX_SecurityType_DualCurrency)) - | "EUCORP" -> (Some (FIX_SecurityType_EuroCorporateBond)) - | "XLINKD" -> (Some (FIX_SecurityType_IndexedLinked)) - | "STRUCT" -> (Some (FIX_SecurityType_StructuredNotes)) - | "YANK" -> (Some (FIX_SecurityType_YankeeCorporateBond)) - | "FOR" -> (Some (FIX_SecurityType_ForeignExchangeContract)) - | "CS" -> (Some (FIX_SecurityType_CommonStock)) - | "PS" -> (Some (FIX_SecurityType_PreferredStock)) - | "BRADY" -> (Some (FIX_SecurityType_BradyBond)) - | "EUSOV" -> (Some (FIX_SecurityType_EuroSovereigns)) - | "TBOND" -> (Some (FIX_SecurityType_USTreasuryBond)) - | "TINT" -> (Some (FIX_SecurityType_InterestStripFromAnyBondOrNote)) - | "TIPS" -> (Some (FIX_SecurityType_TreasuryInflationProtectedSecurities)) - | "TCAL" -> (Some (FIX_SecurityType_PrincipalStripOfACallableBondOrNote)) - | "TPRN" -> (Some (FIX_SecurityType_PrincipalStripFromANonCallableBondOrNote)) - | "UST" -> (Some (FIX_SecurityType_USTreasuryNoteOld)) - | "USTB" -> (Some (FIX_SecurityType_USTreasuryBillOld)) - | "TNOTE" -> (Some (FIX_SecurityType_USTreasuryNote)) - | "TBILL" -> (Some (FIX_SecurityType_USTreasuryBill)) - | "REPO" -> (Some (FIX_SecurityType_Repurchase)) - | "FORWARD" -> (Some (FIX_SecurityType_Forward)) - | "BUYSELL" -> (Some (FIX_SecurityType_BuySellback)) - | "SECLOAN" -> (Some (FIX_SecurityType_SecuritiesLoan)) - | "SECPLEDGE" -> (Some (FIX_SecurityType_SecuritiesPledge)) - | "TERM" -> (Some (FIX_SecurityType_TermLoan)) - | "RVLV" -> (Some (FIX_SecurityType_RevolverLoan)) - | "RVLVTRM" -> (Some (FIX_SecurityType_Revolver)) - | "BRIDGE" -> (Some (FIX_SecurityType_BridgeLoan)) - | "LOFC" -> (Some (FIX_SecurityType_LetterOfCredit)) - | "SWING" -> (Some (FIX_SecurityType_SwingLineFacility)) - | "DINP" -> (Some (FIX_SecurityType_DebtorInPossession)) - | "DEFLTED" -> (Some (FIX_SecurityType_Defaulted)) - | "WITHDRN" -> (Some (FIX_SecurityType_Withdrawn)) - | "REPLACD" -> (Some (FIX_SecurityType_Replaced)) - | "MATURED" -> (Some (FIX_SecurityType_Matured)) - | "AMENDED" -> (Some (FIX_SecurityType_Amended)) - | "RETIRED" -> (Some (FIX_SecurityType_Retired)) - | "BA" -> (Some (FIX_SecurityType_BankersAcceptance)) - | "BN" -> (Some (FIX_SecurityType_BankNotes)) - | "BOX" -> (Some (FIX_SecurityType_BillOfExchanges)) - | "CD" -> (Some (FIX_SecurityType_CertificateOfDeposit)) - | "CL" -> (Some (FIX_SecurityType_CallLoans)) - | "CP" -> (Some (FIX_SecurityType_CommercialPaper)) - | "DN" -> (Some (FIX_SecurityType_DepositNotes)) - | "EUCD" -> (Some (FIX_SecurityType_EuroCertificateOfDeposit)) - | "EUCP" -> (Some (FIX_SecurityType_EuroCommercialPaper)) - | "LQN" -> (Some (FIX_SecurityType_LiquidityNote)) - | "MTN" -> (Some (FIX_SecurityType_MediumTermNotes)) - | "ONITE" -> (Some (FIX_SecurityType_Overnight)) - | "PN" -> (Some (FIX_SecurityType_PromissoryNote)) - | "PZFJ" -> (Some (FIX_SecurityType_PlazosFijos)) - | "STN" -> (Some (FIX_SecurityType_ShortTermLoanNote)) - | "TD" -> (Some (FIX_SecurityType_TimeDeposit)) - | "XCN" -> (Some (FIX_SecurityType_ExtendedCommNote)) - | "YCD" -> (Some (FIX_SecurityType_YankeeCertificateOfDeposit)) - | "ABS" -> (Some (FIX_SecurityType_AssetBackedSecurities)) - | "CMBS" -> (Some (FIX_SecurityType_Corp)) - | "CMO" -> (Some (FIX_SecurityType_CollateralizedMortgageObligation)) - | "IET" -> (Some (FIX_SecurityType_IOETTEMortgage)) - | "MBS" -> (Some (FIX_SecurityType_MortgageBackedSecurities)) - | "MIO" -> (Some (FIX_SecurityType_MortgageInterestOnly)) - | "MPO" -> (Some (FIX_SecurityType_MortgagePrincipalOnly)) - | "MPP" -> (Some (FIX_SecurityType_MortgagePrivatePlacement)) - | "MPT" -> (Some (FIX_SecurityType_MiscellaneousPassThrough)) - | "PFAND" -> (Some (FIX_SecurityType_Pfandbriefe)) - | "TBA" -> (Some (FIX_SecurityType_ToBeAnnounced)) - | "AN" -> (Some (FIX_SecurityType_OtherAnticipationNotes)) - | "COFO" -> (Some (FIX_SecurityType_CertificateOfObligation)) - | "COFP" -> (Some (FIX_SecurityType_CertificateOfParticipation)) - | "GO" -> (Some (FIX_SecurityType_GeneralObligationBonds)) - | "MT" -> (Some (FIX_SecurityType_MandatoryTender)) - | "RAN" -> (Some (FIX_SecurityType_RevenueAnticipationNote)) - | "REV" -> (Some (FIX_SecurityType_RevenueBonds)) - | "SPCLA" -> (Some (FIX_SecurityType_SpecialAssessment)) - | "SPCLO" -> (Some (FIX_SecurityType_SpecialObligation)) - | "SPCLT" -> (Some (FIX_SecurityType_SpecialTax)) - | "TAN" -> (Some (FIX_SecurityType_TaxAnticipationNote)) - | "TAXA" -> (Some (FIX_SecurityType_TaxAllocation)) - | "TECP" -> (Some (FIX_SecurityType_TaxExemptCommercialPaper)) - | "TRAN" -> (Some (FIX_SecurityType_TaxRevenueAnticipationNote)) - | "VRDN" -> (Some (FIX_SecurityType_VariableRateDemandNote)) - | "WAR" -> (Some (FIX_SecurityType_Warrant)) - | "MF" -> (Some (FIX_SecurityType_MutualFund)) - | "MLEG" -> (Some (FIX_SecurityType_MultilegInstrument)) - | "NONE" -> (Some (FIX_SecurityType_NoSecurityType)) - | _ -> (None) - ) -;; - -let parse_SettlCurrFxRateCalc (str) = - (match str with - | "M" -> (Some (FIX_SettlCurrFxRateCalc_Multiply)) - | "D" -> (Some (FIX_SettlCurrFxRateCalc_Divide)) - | _ -> (None) - ) -;; - -let parse_SettlDeliveryType (str) = - (match str with - | "0" -> (Some (FIX_SettlDeliveryType_Versus)) - | "1" -> (Some (FIX_SettlDeliveryType_Free)) - | "2" -> (Some (FIX_SettlDeliveryType_TriParty)) - | "3" -> (Some (FIX_SettlDeliveryType_HoldInCustody)) - | _ -> (None) - ) -;; - -let parse_SettlInstMode (str) = - (match str with - | "1" -> (Some (FIX_SettlInstMode_StandingInstructionsProvided)) - | "4" -> (Some (FIX_SettlInstMode_SpecificOrderForASingleAccount)) - | "5" -> (Some (FIX_SettlInstMode_RequestReject)) - | _ -> (None) - ) -;; - -let parse_SettlInstReqRejCode (str) = - (match str with - | "0" -> (Some (FIX_SettlInstReqRejCode_UnableToProcessRequest)) - | "1" -> (Some (FIX_SettlInstReqRejCode_UnknownAccount)) - | "2" -> (Some (FIX_SettlInstReqRejCode_NoMatchingSettlementInstructionsFound)) - | "99" -> (Some (FIX_SettlInstReqRejCode_Other)) - | _ -> (None) + | "X" -> (Some (FIX_ExecInst_TradeAlong)) + | "Y" -> (Some (FIX_ExecInst_TryToStop)) + | "Z" -> (Some (FIX_ExecInst_CancelIfNotBest)) + | "a" -> (Some (FIX_ExecInst_TrailingStopPeg)) + | "b" -> (Some (FIX_ExecInst_StrictLimit)) + | "c" -> (Some (FIX_ExecInst_IgnorePriceValidityChecks)) + | "d" -> (Some (FIX_ExecInst_PegToLimitPrice)) + | "e" -> (Some (FIX_ExecInst_WorkToTargetStrategy)) + | s -> (Some (FIX_INVALID_ExecInst s)) ) ;; -let parse_SettlInstSource (str) = - (match str with - | "1" -> (Some (FIX_SettlInstSource_BrokerCredit)) - | "2" -> (Some (FIX_SettlInstSource_Institution)) - | "3" -> (Some (FIX_SettlInstSource_Investor)) - | _ -> (None) +let rec parse_ExecInst_filter (f) = + (match f with + | [] -> [] + | h :: t -> ((match parse_inner_ExecInst h with + | None -> (parse_ExecInst_filter t) + | Some x -> (x :: (parse_ExecInst_filter t)) + ) + ) ) ;; -let parse_SettlInstTransType (str) = - (match str with - | "N" -> (Some (FIX_SettlInstTransType_New)) - | "C" -> (Some (FIX_SettlInstTransType_Cancel)) - | "R" -> (Some (FIX_SettlInstTransType_Replace)) - | "T" -> (Some (FIX_SettlInstTransType_Restate)) - | _ -> (None) - ) +let parse_ExecInst (str) = + let x = split_to_list str ' ' + in + Some (parse_ExecInst_filter x) ;; -let parse_SettlPriceType (str) = +let parse_ExecType (str) = (match str with - | "1" -> (Some (FIX_SettlPriceType_Final)) - | "2" -> (Some (FIX_SettlPriceType_Theoretical)) - | _ -> (None) + | "0" -> (Some (FIX_ExecType_New)) + | "3" -> (Some (FIX_ExecType_DoneForDay)) + | "4" -> (Some (FIX_ExecType_Canceled)) + | "5" -> (Some (FIX_ExecType_Replaced)) + | "6" -> (Some (FIX_ExecType_PendingCancel)) + | "7" -> (Some (FIX_ExecType_Stopped)) + | "8" -> (Some (FIX_ExecType_Rejected)) + | "9" -> (Some (FIX_ExecType_Suspended)) + | "A" -> (Some (FIX_ExecType_PendingNew)) + | "B" -> (Some (FIX_ExecType_Calculated)) + | "C" -> (Some (FIX_ExecType_Expired)) + | "D" -> (Some (FIX_ExecType_Restated)) + | "E" -> (Some (FIX_ExecType_PendingReplace)) + | "F" -> (Some (FIX_ExecType_Trade)) + | "G" -> (Some (FIX_ExecType_TradeCorrect)) + | "H" -> (Some (FIX_ExecType_TradeCancel)) + | "I" -> (Some (FIX_ExecType_OrderStatus)) + | s -> (Some (FIX_INVALID_ExecType s)) ) ;; -let parse_SettlSessID (str) = +let parse_OrdStatus (str) = (match str with - | "ITD" -> (Some (FIX_SettlSessID_Intraday)) - | "RTH" -> (Some (FIX_SettlSessID_RegularTradingHours)) - | "ETH" -> (Some (FIX_SettlSessID_ElectronicTradingHours)) - | _ -> (None) + | "0" -> (Some (FIX_OrdStatus_New)) + | "1" -> (Some (FIX_OrdStatus_PartiallyFilled)) + | "2" -> (Some (FIX_OrdStatus_Filled)) + | "3" -> (Some (FIX_OrdStatus_DoneForDay)) + | "4" -> (Some (FIX_OrdStatus_Canceled)) + | "6" -> (Some (FIX_OrdStatus_PendingCancel)) + | "7" -> (Some (FIX_OrdStatus_Stopped)) + | "8" -> (Some (FIX_OrdStatus_Rejected)) + | "9" -> (Some (FIX_OrdStatus_Suspended)) + | "A" -> (Some (FIX_OrdStatus_PendingNew)) + | "B" -> (Some (FIX_OrdStatus_Calculated)) + | "C" -> (Some (FIX_OrdStatus_Expired)) + | "D" -> (Some (FIX_OrdStatus_AcceptedForBidding)) + | "E" -> (Some (FIX_OrdStatus_PendingReplace)) + | "5" -> (Some (FIX_OrdStatus_Replaced)) + | s -> (Some (FIX_INVALID_OrdStatus s)) ) ;; -let parse_SettlType (str) = +let parse_OrdType (str) = (match str with - | "0" -> (Some (FIX_SettlType_Regular)) - | "1" -> (Some (FIX_SettlType_Cash)) - | "2" -> (Some (FIX_SettlType_NextDay)) - | "3" -> (Some (FIX_SettlType_TPlus2)) - | "4" -> (Some (FIX_SettlType_TPlus3)) - | "5" -> (Some (FIX_SettlType_TPlus4)) - | "6" -> (Some (FIX_SettlType_Future)) - | "7" -> (Some (FIX_SettlType_WhenAndIfIssued)) - | "8" -> (Some (FIX_SettlType_SellersOption)) - | "9" -> (Some (FIX_SettlType_TPlus5)) - | _ -> (None) + | "1" -> (Some (FIX_OrdType_Market)) + | "2" -> (Some (FIX_OrdType_Limit)) + | "3" -> (Some (FIX_OrdType_Stop)) + | "4" -> (Some (FIX_OrdType_StopLimit)) + | "6" -> (Some (FIX_OrdType_WithOrWithout)) + | "7" -> (Some (FIX_OrdType_LimitOrBetter)) + | "8" -> (Some (FIX_OrdType_LimitWithOrWithout)) + | "9" -> (Some (FIX_OrdType_OnBasis)) + | "D" -> (Some (FIX_OrdType_PreviouslyQuoted)) + | "E" -> (Some (FIX_OrdType_PreviouslyIndicated)) + | "G" -> (Some (FIX_OrdType_ForexSwap)) + | "I" -> (Some (FIX_OrdType_Funari)) + | "J" -> (Some (FIX_OrdType_MarketIfTouched)) + | "K" -> (Some (FIX_OrdType_MarketWithLeftOverAsLimit)) + | "L" -> (Some (FIX_OrdType_PreviousFundValuationPoint)) + | "M" -> (Some (FIX_OrdType_NextFundValuationPoint)) + | "P" -> (Some (FIX_OrdType_Pegged)) + | "s" -> (Some (FIX_OrdType_StopSpread)) + | s -> (Some (FIX_INVALID_OrdType s)) ) ;; -let parse_ShortSaleReason (str) = +let parse_PartySubIDType (str) = (match str with - | "0" -> (Some (FIX_ShortSaleReason_DealerSoldShort)) - | "1" -> (Some (FIX_ShortSaleReason_DealerSoldShortExempt)) - | "2" -> (Some (FIX_ShortSaleReason_SellingCustomerSoldShort)) - | "3" -> (Some (FIX_ShortSaleReason_SellingCustomerSoldShortExempt)) - | "4" -> (Some (FIX_ShortSaleReason_QualifiedServiceRepresentative)) - | "5" -> (Some (FIX_ShortSaleReason_QSROrAGUContraSideSoldShortExempt)) - | _ -> (None) + | "1" -> (Some (FIX_PartySubIDType_Firm)) + | "2" -> (Some (FIX_PartySubIDType_Person)) + | "3" -> (Some (FIX_PartySubIDType_System)) + | "4" -> (Some (FIX_PartySubIDType_Application)) + | "5" -> (Some (FIX_PartySubIDType_FullLegalNameOfFirm)) + | "6" -> (Some (FIX_PartySubIDType_PostalAddress)) + | "7" -> (Some (FIX_PartySubIDType_PhoneNumber)) + | "8" -> (Some (FIX_PartySubIDType_EmailAddress)) + | "9" -> (Some (FIX_PartySubIDType_ContactName)) + | "10" -> (Some (FIX_PartySubIDType_SecuritiesAccountNumber)) + | "11" -> (Some (FIX_PartySubIDType_RegistrationNumber)) + | "12" -> (Some (FIX_PartySubIDType_RegisteredAddressForConfirmation)) + | "13" -> (Some (FIX_PartySubIDType_RegulatoryStatus)) + | "14" -> (Some (FIX_PartySubIDType_RegistrationName)) + | "15" -> (Some (FIX_PartySubIDType_CashAccountNumber)) + | "16" -> (Some (FIX_PartySubIDType_BIC)) + | "17" -> (Some (FIX_PartySubIDType_CSDParticipantMemberCode)) + | "18" -> (Some (FIX_PartySubIDType_RegisteredAddress)) + | "19" -> (Some (FIX_PartySubIDType_FundAccountName)) + | "20" -> (Some (FIX_PartySubIDType_TelexNumber)) + | "21" -> (Some (FIX_PartySubIDType_FaxNumber)) + | "22" -> (Some (FIX_PartySubIDType_SecuritiesAccountName)) + | "23" -> (Some (FIX_PartySubIDType_CashAccountName)) + | "24" -> (Some (FIX_PartySubIDType_Department)) + | "25" -> (Some (FIX_PartySubIDType_LocationDesk)) + | "26" -> (Some (FIX_PartySubIDType_PositionAccountType)) + | s -> (Some (FIX_INVALID_PartySubIDType s)) ) ;; @@ -2684,515 +187,8 @@ let parse_Side (str) = | "E" -> (Some (FIX_Side_Redeem)) | "F" -> (Some (FIX_Side_Lend)) | "G" -> (Some (FIX_Side_Borrow)) - | _ -> (None) - ) -;; - -let parse_SideMultiLegReportingType (str) = - (match str with - | "1" -> (Some (FIX_SideMultiLegReportingType_SingleSecurity)) - | "2" -> (Some (FIX_SideMultiLegReportingType_IndividualLegOfAMultilegSecurity)) - | "3" -> (Some (FIX_SideMultiLegReportingType_MultilegSecurity)) - | _ -> (None) - ) -;; - -let parse_SideValueInd (str) = - (match str with - | "1" -> (Some (FIX_SideValueInd_SideValue1)) - | "2" -> (Some (FIX_SideValueInd_SideValue2)) - | _ -> (None) - ) -;; - -let parse_SolicitedFlag (str) = - (match str with - | "Y" -> (Some (FIX_SolicitedFlag_WasSolicited)) - | "N" -> (Some (FIX_SolicitedFlag_WasNotSolicited)) - | _ -> (None) - ) -;; - -let parse_StandInstDbType (str) = - (match str with - | "0" -> (Some (FIX_StandInstDbType_Other)) - | "1" -> (Some (FIX_StandInstDbType_DTCSID)) - | "2" -> (Some (FIX_StandInstDbType_ThomsonALERT)) - | "3" -> (Some (FIX_StandInstDbType_AGlobalCustodian)) - | "4" -> (Some (FIX_StandInstDbType_AccountNet)) - | _ -> (None) - ) -;; - -let parse_StatusValue (str) = - (match str with - | "1" -> (Some (FIX_StatusValue_Connected)) - | "2" -> (Some (FIX_StatusValue_NotConnectedUnexpected)) - | "3" -> (Some (FIX_StatusValue_NotConnectedExpected)) - | "4" -> (Some (FIX_StatusValue_InProcess)) - | _ -> (None) - ) -;; - -let parse_StipulationType (str) = - (match str with - | "AMT" -> (Some (FIX_StipulationType_AlternativeMinimumTax)) - | "AUTOREINV" -> (Some (FIX_StipulationType_AutoReinvestment)) - | "BANKQUAL" -> (Some (FIX_StipulationType_BankQualified)) - | "BGNCON" -> (Some (FIX_StipulationType_BargainConditions)) - | "COUPON" -> (Some (FIX_StipulationType_CouponRange)) - | "CURRENCY" -> (Some (FIX_StipulationType_ISOCurrencyCode)) - | "CUSTOMDATE" -> (Some (FIX_StipulationType_CustomStart)) - | "GEOG" -> (Some (FIX_StipulationType_Geographics)) - | "HAIRCUT" -> (Some (FIX_StipulationType_ValuationDiscount)) - | "INSURED" -> (Some (FIX_StipulationType_Insured)) - | "ISSUE" -> (Some (FIX_StipulationType_IssueDate)) - | "ISSUER" -> (Some (FIX_StipulationType_Issuer)) - | "ISSUESIZE" -> (Some (FIX_StipulationType_IssueSizeRange)) - | "LOOKBACK" -> (Some (FIX_StipulationType_LookbackDays)) - | "LOT" -> (Some (FIX_StipulationType_ExplicitLotIdentifier)) - | "LOTVAR" -> (Some (FIX_StipulationType_LotVariance)) - | "MAT" -> (Some (FIX_StipulationType_MaturityYearAndMonth)) - | "MATURITY" -> (Some (FIX_StipulationType_MaturityRange)) - | "MAXSUBS" -> (Some (FIX_StipulationType_MaximumSubstitutions)) - | "MINQTY" -> (Some (FIX_StipulationType_MinimumQuantity)) - | "MININCR" -> (Some (FIX_StipulationType_MinimumIncrement)) - | "MINDNOM" -> (Some (FIX_StipulationType_MinimumDenomination)) - | "PAYFREQ" -> (Some (FIX_StipulationType_PaymentFrequency)) - | "PIECES" -> (Some (FIX_StipulationType_NumberOfPieces)) - | "PMAX" -> (Some (FIX_StipulationType_PoolsMaximum)) - | "PPM" -> (Some (FIX_StipulationType_PoolsPerMillion)) - | "PPL" -> (Some (FIX_StipulationType_PoolsPerLot)) - | "PPT" -> (Some (FIX_StipulationType_PoolsPerTrade)) - | "PRICE" -> (Some (FIX_StipulationType_PriceRange)) - | "PRICEFREQ" -> (Some (FIX_StipulationType_PricingFrequency)) - | "PROD" -> (Some (FIX_StipulationType_ProductionYear)) - | "PROTECT" -> (Some (FIX_StipulationType_CallProtection)) - | "PURPOSE" -> (Some (FIX_StipulationType_Purpose)) - | "PXSOURCE" -> (Some (FIX_StipulationType_BenchmarkPriceSource)) - | "RATING" -> (Some (FIX_StipulationType_RatingSourceAndRange)) - | "REDEMPTION" -> (Some (FIX_StipulationType_TypeOfRedemption)) - | "RESTRICTED" -> (Some (FIX_StipulationType_Restricted)) - | "SECTOR" -> (Some (FIX_StipulationType_MarketSector)) - | "SECTYPE" -> (Some (FIX_StipulationType_SecurityTypeIncludedOrExcluded)) - | "STRUCT" -> (Some (FIX_StipulationType_Structure)) - | "SUBSFREQ" -> (Some (FIX_StipulationType_SubstitutionsFrequency)) - | "SUBSLEFT" -> (Some (FIX_StipulationType_SubstitutionsLeft)) - | "TEXT" -> (Some (FIX_StipulationType_FreeformText)) - | "TRDVAR" -> (Some (FIX_StipulationType_TradeVariance)) - | "WAC" -> (Some (FIX_StipulationType_WeightedAverageCoupon)) - | "WAL" -> (Some (FIX_StipulationType_WeightedAverageLifeCoupon)) - | "WALA" -> (Some (FIX_StipulationType_WeightedAverageLoanAge)) - | "WAM" -> (Some (FIX_StipulationType_WeightedAverageMaturity)) - | "WHOLE" -> (Some (FIX_StipulationType_WholePool)) - | "YIELD" -> (Some (FIX_StipulationType_YieldRange)) - | _ -> (None) - ) -;; - -let parse_SubscriptionRequestType (str) = - (match str with - | "0" -> (Some (FIX_SubscriptionRequestType_Snapshot)) - | "1" -> (Some (FIX_SubscriptionRequestType_SnapshotAndUpdates)) - | "2" -> (Some (FIX_SubscriptionRequestType_DisablePreviousSnapshot)) - | _ -> (None) + | s -> (Some (FIX_INVALID_Side s)) ) ;; -let parse_TargetStrategy (str) = - (match str with - | "1" -> (Some (FIX_TargetStrategy_VWAP)) - | "2" -> (Some (FIX_TargetStrategy_Participate)) - | "3" -> (Some (FIX_TargetStrategy_MininizeMarketImpact)) - | _ -> (None) - ) -;; - -let parse_TaxAdvantageType (str) = - (match str with - | "0" -> (Some (FIX_TaxAdvantageType_FIXNone)) - | "1" -> (Some (FIX_TaxAdvantageType_MaxiISA)) - | "2" -> (Some (FIX_TaxAdvantageType_TESSA)) - | "3" -> (Some (FIX_TaxAdvantageType_MiniCashISA)) - | "4" -> (Some (FIX_TaxAdvantageType_MiniStocksAndSharesISA)) - | "5" -> (Some (FIX_TaxAdvantageType_MiniInsuranceISA)) - | "6" -> (Some (FIX_TaxAdvantageType_CurrentYearPayment)) - | "7" -> (Some (FIX_TaxAdvantageType_PriorYearPayment)) - | "8" -> (Some (FIX_TaxAdvantageType_AssetTransfer)) - | "9" -> (Some (FIX_TaxAdvantageType_EmployeePriorYear)) - | "10" -> (Some (FIX_TaxAdvantageType_EmployeeCurrentYear)) - | "11" -> (Some (FIX_TaxAdvantageType_EmployerPriorYear)) - | "12" -> (Some (FIX_TaxAdvantageType_EmployerCurrentYear)) - | "13" -> (Some (FIX_TaxAdvantageType_NonFundPrototypeIRA)) - | "14" -> (Some (FIX_TaxAdvantageType_NonFundQualifiedPlan)) - | "15" -> (Some (FIX_TaxAdvantageType_DefinedContributionPlan)) - | "16" -> (Some (FIX_TaxAdvantageType_IRA)) - | "17" -> (Some (FIX_TaxAdvantageType_IRARollover)) - | "18" -> (Some (FIX_TaxAdvantageType_KEOGH)) - | "19" -> (Some (FIX_TaxAdvantageType_ProfitSharingPlan)) - | "20" -> (Some (FIX_TaxAdvantageType_US401K)) - | "21" -> (Some (FIX_TaxAdvantageType_SelfDirectedIRA)) - | "22" -> (Some (FIX_TaxAdvantageType_US403b)) - | "23" -> (Some (FIX_TaxAdvantageType_US457)) - | "24" -> (Some (FIX_TaxAdvantageType_RothIRAPrototype)) - | "25" -> (Some (FIX_TaxAdvantageType_RothIRANonPrototype)) - | "26" -> (Some (FIX_TaxAdvantageType_RothConversionIRAPrototype)) - | "27" -> (Some (FIX_TaxAdvantageType_RothConversionIRANonPrototype)) - | "28" -> (Some (FIX_TaxAdvantageType_EducationIRAPrototype)) - | "29" -> (Some (FIX_TaxAdvantageType_EducationIRANonPrototype)) - | _ -> (None) - ) -;; - -let parse_TerminationType (str) = - (match str with - | "1" -> (Some (FIX_TerminationType_Overnight)) - | "2" -> (Some (FIX_TerminationType_Term)) - | "3" -> (Some (FIX_TerminationType_Flexible)) - | "4" -> (Some (FIX_TerminationType_Open)) - | _ -> (None) - ) -;; - -let parse_TestMessageIndicator (str) = - (match str with - | "Y" -> (Some (FIX_TestMessageIndicator_True)) - | "N" -> (Some (FIX_TestMessageIndicator_Fales)) - | _ -> (None) - ) -;; - -let parse_TickDirection (str) = - (match str with - | "0" -> (Some (FIX_TickDirection_PlusTick)) - | "1" -> (Some (FIX_TickDirection_ZeroPlusTick)) - | "2" -> (Some (FIX_TickDirection_MinusTick)) - | "3" -> (Some (FIX_TickDirection_ZeroMinusTick)) - | _ -> (None) - ) -;; - -let parse_TimeInForce (str) = - (match str with - | "0" -> (Some (FIX_TimeInForce_Day)) - | "1" -> (Some (FIX_TimeInForce_GoodTillCancel)) - | "2" -> (Some (FIX_TimeInForce_AtTheOpening)) - | "3" -> (Some (FIX_TimeInForce_ImmediateOrCancel)) - | "4" -> (Some (FIX_TimeInForce_FillOrKill)) - | "5" -> (Some (FIX_TimeInForce_GoodTillCrossing)) - | "6" -> (Some (FIX_TimeInForce_GoodTillDate)) - | "7" -> (Some (FIX_TimeInForce_AtTheClose)) - | _ -> (None) - ) -;; - -let parse_TradSesMethod (str) = - (match str with - | "1" -> (Some (FIX_TradSesMethod_Electronic)) - | "2" -> (Some (FIX_TradSesMethod_OpenOutcry)) - | "3" -> (Some (FIX_TradSesMethod_TwoParty)) - | _ -> (None) - ) -;; - -let parse_TradSesMode (str) = - (match str with - | "1" -> (Some (FIX_TradSesMode_Testing)) - | "2" -> (Some (FIX_TradSesMode_Simulated)) - | "3" -> (Some (FIX_TradSesMode_Production)) - | _ -> (None) - ) -;; - -let parse_TradSesStatus (str) = - (match str with - | "0" -> (Some (FIX_TradSesStatus_Unknown)) - | "1" -> (Some (FIX_TradSesStatus_Halted)) - | "2" -> (Some (FIX_TradSesStatus_Open)) - | "3" -> (Some (FIX_TradSesStatus_Closed)) - | "4" -> (Some (FIX_TradSesStatus_PreOpen)) - | "5" -> (Some (FIX_TradSesStatus_PreClose)) - | "6" -> (Some (FIX_TradSesStatus_RequestRejected)) - | _ -> (None) - ) -;; - -let parse_TradSesStatusRejReason (str) = - (match str with - | "1" -> (Some (FIX_TradSesStatusRejReason_UnknownOrInvalidTradingSessionID)) - | "99" -> (Some (FIX_TradSesStatusRejReason_Other)) - | _ -> (None) - ) -;; - -let parse_TradeAllocIndicator (str) = - (match str with - | "0" -> (Some (FIX_TradeAllocIndicator_AllocationNotRequired)) - | "1" -> (Some (FIX_TradeAllocIndicator_AllocationRequired)) - | "2" -> (Some (FIX_TradeAllocIndicator_UseAllocationProvidedWithTheTrade)) - | _ -> (None) - ) -;; - -let parse_inner_TradeCondition (str) = - (match str with - | "A" -> (Some (FIX_TradeCondition_Cash)) - | "B" -> (Some (FIX_TradeCondition_AveragePriceTrade)) - | "C" -> (Some (FIX_TradeCondition_CashTrade)) - | "D" -> (Some (FIX_TradeCondition_NextDay)) - | "E" -> (Some (FIX_TradeCondition_Opening)) - | "F" -> (Some (FIX_TradeCondition_IntradayTradeDetail)) - | "G" -> (Some (FIX_TradeCondition_Rule127Trade)) - | "H" -> (Some (FIX_TradeCondition_Rule155Trade)) - | "I" -> (Some (FIX_TradeCondition_SoldLast)) - | "J" -> (Some (FIX_TradeCondition_NextDayTrade)) - | "K" -> (Some (FIX_TradeCondition_Opened)) - | "L" -> (Some (FIX_TradeCondition_Seller)) - | "M" -> (Some (FIX_TradeCondition_Sold)) - | "N" -> (Some (FIX_TradeCondition_StoppedStock)) - | "P" -> (Some (FIX_TradeCondition_ImbalanceMoreBuyers)) - | "Q" -> (Some (FIX_TradeCondition_ImbalanceMoreSellers)) - | "R" -> (Some (FIX_TradeCondition_OpeningPrice)) - | _ -> (None) - ) -;; - -let rec parse_TradeCondition_filter (f) = - (match f with - | [] -> [] - | h :: t -> ((match parse_inner_TradeCondition h with - | None -> (parse_TradeCondition_filter t) - | Some x -> (x :: (parse_TradeCondition_filter t)) - ) - ) - ) -;; - -let parse_TradeCondition (str) = - let x = split_to_list str ' ' in - Some (parse_TradeCondition_filter x) -;; - -let parse_TradeReportRejectReason (str) = - (match str with - | "0" -> (Some (FIX_TradeReportRejectReason_Successful)) - | "1" -> (Some (FIX_TradeReportRejectReason_InvalidPartyOnformation)) - | "2" -> (Some (FIX_TradeReportRejectReason_UnknownInstrument)) - | "3" -> (Some (FIX_TradeReportRejectReason_UnauthorizedToReportTrades)) - | "4" -> (Some (FIX_TradeReportRejectReason_InvalidTradeType)) - | "99" -> (Some (FIX_TradeReportRejectReason_Other)) - | _ -> (None) - ) -;; - -let parse_TradeReportType (str) = - (match str with - | "0" -> (Some (FIX_TradeReportType_Submit)) - | "1" -> (Some (FIX_TradeReportType_Alleged)) - | "2" -> (Some (FIX_TradeReportType_Accept)) - | "3" -> (Some (FIX_TradeReportType_Decline)) - | "4" -> (Some (FIX_TradeReportType_Addendum)) - | "5" -> (Some (FIX_TradeReportType_No)) - | "6" -> (Some (FIX_TradeReportType_TradeReportCancel)) - | "7" -> (Some (FIX_TradeReportType_LockedIn)) - | _ -> (None) - ) -;; - -let parse_TradeRequestResult (str) = - (match str with - | "0" -> (Some (FIX_TradeRequestResult_Successful)) - | "1" -> (Some (FIX_TradeRequestResult_InvalidOrUnknownInstrument)) - | "2" -> (Some (FIX_TradeRequestResult_InvalidTypeOfTradeRequested)) - | "3" -> (Some (FIX_TradeRequestResult_InvalidParties)) - | "4" -> (Some (FIX_TradeRequestResult_InvalidTransportTypeRequested)) - | "5" -> (Some (FIX_TradeRequestResult_InvalidDestinationRequested)) - | "8" -> (Some (FIX_TradeRequestResult_TradeRequestTypeNotSupported)) - | "9" -> (Some (FIX_TradeRequestResult_NotAuthorized)) - | "99" -> (Some (FIX_TradeRequestResult_Other)) - | _ -> (None) - ) -;; - -let parse_TradeRequestStatus (str) = - (match str with - | "0" -> (Some (FIX_TradeRequestStatus_Accepted)) - | "1" -> (Some (FIX_TradeRequestStatus_Completed)) - | "2" -> (Some (FIX_TradeRequestStatus_Rejected)) - | _ -> (None) - ) -;; - -let parse_TradeRequestType (str) = - (match str with - | "0" -> (Some (FIX_TradeRequestType_AllTrades)) - | "1" -> (Some (FIX_TradeRequestType_MatchedTradesMatchingCriteria)) - | "2" -> (Some (FIX_TradeRequestType_UnmatchedTradesThatMatchCriteria)) - | "3" -> (Some (FIX_TradeRequestType_UnreportedTradesThatMatchCriteria)) - | "4" -> (Some (FIX_TradeRequestType_AdvisoriesThatMatchCriteria)) - | _ -> (None) - ) -;; - -let parse_TradedFlatSwitch (str) = - (match str with - | "Y" -> (Some (FIX_TradedFlatSwitch_TradedFlat)) - | "N" -> (Some (FIX_TradedFlatSwitch_NotTradedFlat)) - | _ -> (None) - ) -;; - -let parse_TrdRegTimestampType (str) = - (match str with - | "1" -> (Some (FIX_TrdRegTimestampType_ExecutionTime)) - | "2" -> (Some (FIX_TrdRegTimestampType_TimeIn)) - | "3" -> (Some (FIX_TrdRegTimestampType_TimeOut)) - | "4" -> (Some (FIX_TrdRegTimestampType_BrokerReceipt)) - | "5" -> (Some (FIX_TrdRegTimestampType_BrokerExecution)) - | _ -> (None) - ) -;; - -let parse_TrdRptStatus (str) = - (match str with - | "0" -> (Some (FIX_TrdRptStatus_Accepted)) - | "1" -> (Some (FIX_TrdRptStatus_Rejected)) - | _ -> (None) - ) -;; - -let parse_TrdType (str) = - (match str with - | "0" -> (Some (FIX_TrdType_RegularTrade)) - | "1" -> (Some (FIX_TrdType_BlockTrade)) - | "2" -> (Some (FIX_TrdType_EFP)) - | "3" -> (Some (FIX_TrdType_Transfer)) - | "4" -> (Some (FIX_TrdType_LateTrade)) - | "5" -> (Some (FIX_TrdType_TTrade)) - | "6" -> (Some (FIX_TrdType_WeightedAveragePriceTrade)) - | "7" -> (Some (FIX_TrdType_BunchedTrade)) - | "8" -> (Some (FIX_TrdType_LateBunchedTrade)) - | "9" -> (Some (FIX_TrdType_PriorReferencePriceTrade)) - | "10" -> (Some (FIX_TrdType_AfterHoursTrade)) - | _ -> (None) - ) -;; - -let parse_UnsolicitedIndicator (str) = - (match str with - | "Y" -> (Some (FIX_UnsolicitedIndicator_MessageIsBeingSentUnsolicited)) - | "N" -> (Some (FIX_UnsolicitedIndicator_MessageIsBeingSentAsAResultOfAPriorRequest)) - | _ -> (None) - ) -;; - -let parse_Urgency (str) = - (match str with - | "0" -> (Some (FIX_Urgency_Normal)) - | "1" -> (Some (FIX_Urgency_Flash)) - | "2" -> (Some (FIX_Urgency_Background)) - | _ -> (None) - ) -;; - -let parse_UserRequestType (str) = - (match str with - | "1" -> (Some (FIX_UserRequestType_LogOnUser)) - | "2" -> (Some (FIX_UserRequestType_LogOffUser)) - | "3" -> (Some (FIX_UserRequestType_ChangePasswordForUser)) - | "4" -> (Some (FIX_UserRequestType_RequestIndividualUserStatus)) - | _ -> (None) - ) -;; - -let parse_UserStatus (str) = - (match str with - | "1" -> (Some (FIX_UserStatus_LoggedIn)) - | "2" -> (Some (FIX_UserStatus_NotLoggedIn)) - | "3" -> (Some (FIX_UserStatus_UserNotRecognised)) - | "4" -> (Some (FIX_UserStatus_PasswordIncorrect)) - | "5" -> (Some (FIX_UserStatus_PasswordChanged)) - | "6" -> (Some (FIX_UserStatus_Other)) - | _ -> (None) - ) -;; - -let parse_WorkingIndicator (str) = - (match str with - | "Y" -> (Some (FIX_WorkingIndicator_Working)) - | "N" -> (Some (FIX_WorkingIndicator_NotWorking)) - | _ -> (None) - ) -;; - -let parse_YieldType (str) = - (match str with - | "AFTERTAX" -> (Some (FIX_YieldType_AfterTaxYield)) - | "ANNUAL" -> (Some (FIX_YieldType_AnnualYield)) - | "ATISSUE" -> (Some (FIX_YieldType_YieldAtIssue)) - | "AVGMATURITY" -> (Some (FIX_YieldType_YieldToAverageMaturity)) - | "BOOK" -> (Some (FIX_YieldType_BookYield)) - | "CALL" -> (Some (FIX_YieldType_YieldToNextCall)) - | "CHANGE" -> (Some (FIX_YieldType_YieldChangeSinceClose)) - | "CLOSE" -> (Some (FIX_YieldType_ClosingYield)) - | "COMPOUND" -> (Some (FIX_YieldType_CompoundYield)) - | "CURRENT" -> (Some (FIX_YieldType_CurrentYield)) - | "GROSS" -> (Some (FIX_YieldType_TrueGrossYield)) - | "GOVTEQUIV" -> (Some (FIX_YieldType_GvntEquivalentYield)) - | "INFLATION" -> (Some (FIX_YieldType_YieldWithInflationAssumption)) - | "INVERSEFLOATER" -> (Some (FIX_YieldType_InverseFloaterBondYield)) - | "LASTCLOSE" -> (Some (FIX_YieldType_MostRecentClosingYield)) - | "LASTMONTH" -> (Some (FIX_YieldType_ClosingYieldMostRecentMonth)) - | "LASTQUARTER" -> (Some (FIX_YieldType_ClosingYieldMostRecentQuarter)) - | "LASTYEAR" -> (Some (FIX_YieldType_ClosingYieldMostRecentYear)) - | "LONGAVGLIFE" -> (Some (FIX_YieldType_YieldToLongestAverageLife)) - | "MARK" -> (Some (FIX_YieldType_MarkToMarketYield)) - | "MATURITY" -> (Some (FIX_YieldType_YieldToMaturity)) - | "NEXTREFUND" -> (Some (FIX_YieldType_YieldToNextRefund)) - | "OPENAVG" -> (Some (FIX_YieldType_OpenAverageYield)) - | "PUT" -> (Some (FIX_YieldType_YieldToNextPut)) - | "PREVCLOSE" -> (Some (FIX_YieldType_PreviousCloseYield)) - | "PROCEEDS" -> (Some (FIX_YieldType_ProceedsYield)) - | "SEMIANNUAL" -> (Some (FIX_YieldType_SemiAnnualYield)) - | "SHORTAVGLIFE" -> (Some (FIX_YieldType_YieldToShortestAverageLife)) - | "SIMPLE" -> (Some (FIX_YieldType_SimpleYield)) - | "TAXEQUIV" -> (Some (FIX_YieldType_TaxEquivalentYield)) - | "TENDER" -> (Some (FIX_YieldType_YieldToTenderDate)) - | "TRUE" -> (Some (FIX_YieldType_TrueYield)) - | "VALUE1/32" -> (Some (FIX_YieldType_YieldValueOf132)) - | "WORST" -> (Some (FIX_YieldType_YieldToWorst)) - | _ -> (None) - ) -;; - -let parse_Currency (str) = - (match str with - | "EUR" -> (Some (FIX_Currency_EUR)) - | "GBP" -> (Some (FIX_Currency_GBP)) - | "USD" -> (Some (FIX_Currency_USD)) - | "CHF" -> (Some (FIX_Currency_CHF)) - | _ -> (None) - ) -;; - -let parse_Country (str) = - (match str with - | "DE" -> (Some (FIX_Country_DE)) - | "GB" -> (Some (FIX_Country_GB)) - | "US" -> (Some (FIX_Country_US)) - | _ -> (None) - ) -;; - -let parse_Exchange (str) = - (match str with - | "XLON" -> (Some (FIX_Exchange_XLON)) - | "XNYS" -> (Some (FIX_Exchange_XNYS)) - | "XNAS" -> (Some (FIX_Exchange_XNAS)) - | "XJAS" -> (Some (FIX_Exchange_XJAS)) - | "XSHG" -> (Some (FIX_Exchange_XSHG)) - | "SHSC" -> (Some (FIX_Exchange_SHSC)) - | _ -> (None) - ) -;; [@@@logic] diff --git a/src-protocol-exts-pp/parse_app_messages.iml b/src-protocol-exts-pp/parse_app_messages.iml index 1a4ed5d1..76f75d2f 100644 --- a/src-protocol-exts-pp/parse_app_messages.iml +++ b/src-protocol-exts-pp/parse_app_messages.iml @@ -1,380 +1,39 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "../src-protocol-exts/full_app_messages.iml"] -[@@@import "../src-protocol-exts/full_app_tags.iml"] -[@@@import "parse_app_enums.iml"] -[@@@import "parse_app_records.iml"] -[@@@import "../src-core-pp/parse_base_types.iml"] -[@@@import "../src-core-pp/parse_datetime.iml"] -[@@@import "../src-core-pp/parser_utils.iml"] +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-protocol-exts/full_app_messages.iml"] open Full_app_messages;; +[@@@import "../src-protocol-exts/full_app_tags.iml"] open Full_app_tags;; +[@@@import "../src-core/numeric.iml"] +open Numeric;; +[@@@import "parse_app_enums.iml"] open Parse_app_enums;; +[@@@import "parse_app_records.iml"] open Parse_app_records;; +[@@@import "../src-core-pp/parse_base_types.iml"] open Parse_base_types;; +[@@@import "../src-core-pp/parse_datetime.iml"] open Parse_datetime;; +[@@@import "../src-core-pp/parser_utils.iml"] open Parser_utils.Parser;; -let parse_ExecutionReport (msg) = - (repeating msg "453" parse_Parties (fun msg f_ExecutionReport_Parties -> repeating msg "382" parse_ContraGrp (fun msg f_ExecutionReport_ContraGrp -> repeating msg "711" parse_UndInstrmtGrp (fun msg f_ExecutionReport_UndInstrmtGrp -> repeating msg "232" parse_Stipulations (fun msg f_ExecutionReport_Stipulations -> repeating msg "518" parse_ContAmtGrp (fun msg f_ExecutionReport_ContAmtGrp -> repeating msg "555" parse_InstrmtLegExecGrp (fun msg f_ExecutionReport_InstrmtLegExecGrp -> repeating msg "136" parse_MiscFeesGrp (fun msg f_ExecutionReport_MiscFeesGrp -> check_duplicate_tags msg (fun () -> block msg parse_Instrument (fun msg f_ExecutionReport_Instrument -> block msg parse_FinancingDetails (fun msg f_ExecutionReport_FinancingDetails -> block msg parse_OrderQtyData (fun msg f_ExecutionReport_OrderQtyData -> block msg parse_PegInstructions (fun msg f_ExecutionReport_PegInstructions -> block msg parse_DiscretionInstructions (fun msg f_ExecutionReport_DiscretionInstructions -> block msg parse_CommissionData (fun msg f_ExecutionReport_CommissionData -> block msg parse_SpreadOrBenchmarkCurveData (fun msg f_ExecutionReport_SpreadOrBenchmarkCurveData -> block msg parse_YieldData (fun msg f_ExecutionReport_YieldData -> opt msg "37" parse_string (fun msg f_ExecutionReport_OrderID -> opt msg "198" parse_string (fun msg f_ExecutionReport_SecondaryOrderID -> opt msg "526" parse_string (fun msg f_ExecutionReport_SecondaryClOrdID -> opt msg "527" parse_string (fun msg f_ExecutionReport_SecondaryExecID -> opt msg "11" parse_string (fun msg f_ExecutionReport_ClOrdID -> opt msg "41" parse_string (fun msg f_ExecutionReport_OrigClOrdID -> opt msg "583" parse_string (fun msg f_ExecutionReport_ClOrdLinkID -> opt msg "693" parse_string (fun msg f_ExecutionReport_QuoteRespID -> opt msg "790" parse_string (fun msg f_ExecutionReport_OrdStatusReqID -> opt msg "584" parse_string (fun msg f_ExecutionReport_MassStatusReqID -> opt msg "911" parse_int (fun msg f_ExecutionReport_TotNumReports -> opt msg "912" parse_bool (fun msg f_ExecutionReport_LastRptRequested -> opt msg "229" parse_LocalMktDate (fun msg f_ExecutionReport_TradeOriginationDate -> opt msg "66" parse_string (fun msg f_ExecutionReport_ListID -> opt msg "548" parse_string (fun msg f_ExecutionReport_CrossID -> opt msg "551" parse_string (fun msg f_ExecutionReport_OrigCrossID -> opt msg "549" parse_CrossType (fun msg f_ExecutionReport_CrossType -> opt msg "17" parse_string (fun msg f_ExecutionReport_ExecID -> opt msg "19" parse_string (fun msg f_ExecutionReport_ExecRefID -> opt msg "150" parse_ExecType (fun msg f_ExecutionReport_ExecType -> opt msg "39" parse_OrdStatus (fun msg f_ExecutionReport_OrdStatus -> opt msg "636" parse_WorkingIndicator (fun msg f_ExecutionReport_WorkingIndicator -> opt msg "103" parse_OrdRejReason (fun msg f_ExecutionReport_OrdRejReason -> opt msg "378" parse_ExecRestatementReason (fun msg f_ExecutionReport_ExecRestatementReason -> opt msg "1" parse_string (fun msg f_ExecutionReport_Account -> opt msg "660" parse_AcctIDSource (fun msg f_ExecutionReport_AcctIDSource -> opt msg "581" parse_AccountType (fun msg f_ExecutionReport_AccountType -> opt msg "589" parse_DayBookingInst (fun msg f_ExecutionReport_DayBookingInst -> opt msg "590" parse_BookingUnit (fun msg f_ExecutionReport_BookingUnit -> opt msg "591" parse_PreallocMethod (fun msg f_ExecutionReport_PreallocMethod -> opt msg "63" parse_SettlType (fun msg f_ExecutionReport_SettlType -> opt msg "64" parse_LocalMktDate (fun msg f_ExecutionReport_SettlDate -> opt msg "544" parse_CashMargin (fun msg f_ExecutionReport_CashMargin -> opt msg "635" parse_ClearingFeeIndicator (fun msg f_ExecutionReport_ClearingFeeIndicator -> opt msg "54" parse_Side (fun msg f_ExecutionReport_Side -> opt msg "854" parse_QtyType (fun msg f_ExecutionReport_QtyType -> opt msg "40" parse_OrdType (fun msg f_ExecutionReport_OrdType -> opt msg "423" parse_PriceType (fun msg f_ExecutionReport_PriceType -> opt msg "44" parse_float (fun msg f_ExecutionReport_Price -> opt msg "99" parse_float (fun msg f_ExecutionReport_StopPx -> opt msg "839" parse_float (fun msg f_ExecutionReport_PeggedPrice -> opt msg "845" parse_float (fun msg f_ExecutionReport_DiscretionPrice -> opt msg "847" parse_TargetStrategy (fun msg f_ExecutionReport_TargetStrategy -> opt msg "848" parse_string (fun msg f_ExecutionReport_TargetStrategyParameters -> opt msg "849" parse_float (fun msg f_ExecutionReport_ParticipationRate -> opt msg "850" parse_float (fun msg f_ExecutionReport_TargetStrategyPerformance -> opt msg "15" parse_Currency (fun msg f_ExecutionReport_Currency -> opt msg "376" parse_string (fun msg f_ExecutionReport_ComplianceID -> opt msg "377" parse_SolicitedFlag (fun msg f_ExecutionReport_SolicitedFlag -> opt msg "59" parse_TimeInForce (fun msg f_ExecutionReport_TimeInForce -> opt msg "168" parse_UTCTimestamp_milli (fun msg f_ExecutionReport_EffectiveTime -> opt msg "432" parse_LocalMktDate (fun msg f_ExecutionReport_ExpireDate -> opt msg "126" parse_UTCTimestamp_milli (fun msg f_ExecutionReport_ExpireTime -> opt msg "18" parse_ExecInst (fun msg f_ExecutionReport_ExecInst -> opt msg "528" parse_OrderCapacity (fun msg f_ExecutionReport_OrderCapacity -> opt msg "529" parse_OrderRestrictions (fun msg f_ExecutionReport_OrderRestrictions -> opt msg "582" parse_CustOrderCapacity (fun msg f_ExecutionReport_CustOrderCapacity -> opt msg "32" parse_float (fun msg f_ExecutionReport_LastQty -> opt msg "652" parse_float (fun msg f_ExecutionReport_UnderlyingLastQty -> opt msg "31" parse_float (fun msg f_ExecutionReport_LastPx -> opt msg "651" parse_float (fun msg f_ExecutionReport_UnderlyingLastPx -> opt msg "669" parse_float (fun msg f_ExecutionReport_LastParPx -> opt msg "194" parse_float (fun msg f_ExecutionReport_LastSpotRate -> opt msg "195" parse_float (fun msg f_ExecutionReport_LastForwardPoints -> opt msg "30" parse_Exchange (fun msg f_ExecutionReport_LastMkt -> opt msg "336" parse_string (fun msg f_ExecutionReport_TradingSessionID -> opt msg "625" parse_string (fun msg f_ExecutionReport_TradingSessionSubID -> opt msg "943" parse_string (fun msg f_ExecutionReport_TimeBracket -> opt msg "29" parse_LastCapacity (fun msg f_ExecutionReport_LastCapacity -> opt msg "151" parse_float (fun msg f_ExecutionReport_LeavesQty -> opt msg "14" parse_float (fun msg f_ExecutionReport_CumQty -> opt msg "6" parse_float (fun msg f_ExecutionReport_AvgPx -> opt msg "424" parse_float (fun msg f_ExecutionReport_DayOrderQty -> opt msg "425" parse_float (fun msg f_ExecutionReport_DayCumQty -> opt msg "426" parse_float (fun msg f_ExecutionReport_DayAvgPx -> opt msg "427" parse_GTBookingInst (fun msg f_ExecutionReport_GTBookingInst -> opt msg "75" parse_LocalMktDate (fun msg f_ExecutionReport_TradeDate -> opt msg "60" parse_UTCTimestamp_milli (fun msg f_ExecutionReport_TransactTime -> opt msg "113" parse_ReportToExch (fun msg f_ExecutionReport_ReportToExch -> opt msg "381" parse_float (fun msg f_ExecutionReport_GrossTradeAmt -> opt msg "157" parse_int (fun msg f_ExecutionReport_NumDaysInterest -> opt msg "230" parse_LocalMktDate (fun msg f_ExecutionReport_ExDate -> opt msg "158" parse_float (fun msg f_ExecutionReport_AccruedInterestRate -> opt msg "159" parse_float (fun msg f_ExecutionReport_AccruedInterestAmt -> opt msg "738" parse_float (fun msg f_ExecutionReport_InterestAtMaturity -> opt msg "920" parse_float (fun msg f_ExecutionReport_EndAccruedInterestAmt -> opt msg "921" parse_float (fun msg f_ExecutionReport_StartCash -> opt msg "922" parse_float (fun msg f_ExecutionReport_EndCash -> opt msg "258" parse_TradedFlatSwitch (fun msg f_ExecutionReport_TradedFlatSwitch -> opt msg "259" parse_LocalMktDate (fun msg f_ExecutionReport_BasisFeatureDate -> opt msg "260" parse_float (fun msg f_ExecutionReport_BasisFeaturePrice -> opt msg "238" parse_float (fun msg f_ExecutionReport_Concession -> opt msg "237" parse_float (fun msg f_ExecutionReport_TotalTakedown -> opt msg "118" parse_float (fun msg f_ExecutionReport_NetMoney -> opt msg "119" parse_float (fun msg f_ExecutionReport_SettlCurrAmt -> opt msg "120" parse_Currency (fun msg f_ExecutionReport_SettlCurrency -> opt msg "155" parse_float (fun msg f_ExecutionReport_SettlCurrFxRate -> opt msg "156" parse_SettlCurrFxRateCalc (fun msg f_ExecutionReport_SettlCurrFxRateCalc -> opt msg "21" parse_HandlInst (fun msg f_ExecutionReport_HandlInst -> opt msg "110" parse_float (fun msg f_ExecutionReport_MinQty -> opt msg "111" parse_float (fun msg f_ExecutionReport_MaxFloor -> opt msg "77" parse_PositionEffect (fun msg f_ExecutionReport_PositionEffect -> opt msg "210" parse_float (fun msg f_ExecutionReport_MaxShow -> opt msg "775" parse_BookingType (fun msg f_ExecutionReport_BookingType -> opt msg "58" parse_string (fun msg f_ExecutionReport_Text -> opt msg "354" parse_int (fun msg f_ExecutionReport_EncodedTextLen -> opt msg "355" parse_string (fun msg f_ExecutionReport_EncodedText -> opt msg "193" parse_LocalMktDate (fun msg f_ExecutionReport_SettlDate2 -> opt msg "192" parse_float (fun msg f_ExecutionReport_OrderQty2 -> opt msg "641" parse_float (fun msg f_ExecutionReport_LastForwardPoints2 -> opt msg "442" parse_MultiLegReportingType (fun msg f_ExecutionReport_MultiLegReportingType -> opt msg "480" parse_CancellationRights (fun msg f_ExecutionReport_CancellationRights -> opt msg "481" parse_MoneyLaunderingStatus (fun msg f_ExecutionReport_MoneyLaunderingStatus -> opt msg "513" parse_string (fun msg f_ExecutionReport_RegistID -> opt msg "494" parse_string (fun msg f_ExecutionReport_Designation -> opt msg "483" parse_UTCTimestamp_milli (fun msg f_ExecutionReport_TransBkdTime -> opt msg "515" parse_UTCTimestamp_milli (fun msg f_ExecutionReport_ExecValuationPoint -> opt msg "484" parse_ExecPriceType (fun msg f_ExecutionReport_ExecPriceType -> opt msg "485" parse_float (fun msg f_ExecutionReport_ExecPriceAdjustment -> opt msg "638" parse_PriorityIndicator (fun msg f_ExecutionReport_PriorityIndicator -> opt msg "639" parse_float (fun msg f_ExecutionReport_PriceImprovement -> opt msg "851" parse_LastLiquidityInd (fun msg f_ExecutionReport_LastLiquidityInd -> opt msg "797" parse_bool (fun msg f_ExecutionReport_CopyMsgIndicator -> (ParseSuccess { - f_ExecutionReport_Parties = f_ExecutionReport_Parties; - f_ExecutionReport_ContraGrp = f_ExecutionReport_ContraGrp; - f_ExecutionReport_UndInstrmtGrp = f_ExecutionReport_UndInstrmtGrp; - f_ExecutionReport_Stipulations = f_ExecutionReport_Stipulations; - f_ExecutionReport_ContAmtGrp = f_ExecutionReport_ContAmtGrp; - f_ExecutionReport_InstrmtLegExecGrp = f_ExecutionReport_InstrmtLegExecGrp; - f_ExecutionReport_MiscFeesGrp = f_ExecutionReport_MiscFeesGrp; - f_ExecutionReport_Instrument = f_ExecutionReport_Instrument; - f_ExecutionReport_FinancingDetails = f_ExecutionReport_FinancingDetails; - f_ExecutionReport_OrderQtyData = f_ExecutionReport_OrderQtyData; - f_ExecutionReport_PegInstructions = f_ExecutionReport_PegInstructions; - f_ExecutionReport_DiscretionInstructions = f_ExecutionReport_DiscretionInstructions; - f_ExecutionReport_CommissionData = f_ExecutionReport_CommissionData; - f_ExecutionReport_SpreadOrBenchmarkCurveData = f_ExecutionReport_SpreadOrBenchmarkCurveData; - f_ExecutionReport_YieldData = f_ExecutionReport_YieldData; - f_ExecutionReport_OrderID = f_ExecutionReport_OrderID; - f_ExecutionReport_SecondaryOrderID = f_ExecutionReport_SecondaryOrderID; - f_ExecutionReport_SecondaryClOrdID = f_ExecutionReport_SecondaryClOrdID; - f_ExecutionReport_SecondaryExecID = f_ExecutionReport_SecondaryExecID; - f_ExecutionReport_ClOrdID = f_ExecutionReport_ClOrdID; - f_ExecutionReport_OrigClOrdID = f_ExecutionReport_OrigClOrdID; - f_ExecutionReport_ClOrdLinkID = f_ExecutionReport_ClOrdLinkID; - f_ExecutionReport_QuoteRespID = f_ExecutionReport_QuoteRespID; - f_ExecutionReport_OrdStatusReqID = f_ExecutionReport_OrdStatusReqID; - f_ExecutionReport_MassStatusReqID = f_ExecutionReport_MassStatusReqID; - f_ExecutionReport_TotNumReports = f_ExecutionReport_TotNumReports; - f_ExecutionReport_LastRptRequested = f_ExecutionReport_LastRptRequested; - f_ExecutionReport_TradeOriginationDate = f_ExecutionReport_TradeOriginationDate; - f_ExecutionReport_ListID = f_ExecutionReport_ListID; - f_ExecutionReport_CrossID = f_ExecutionReport_CrossID; - f_ExecutionReport_OrigCrossID = f_ExecutionReport_OrigCrossID; - f_ExecutionReport_CrossType = f_ExecutionReport_CrossType; - f_ExecutionReport_ExecID = f_ExecutionReport_ExecID; - f_ExecutionReport_ExecRefID = f_ExecutionReport_ExecRefID; - f_ExecutionReport_ExecType = f_ExecutionReport_ExecType; - f_ExecutionReport_OrdStatus = f_ExecutionReport_OrdStatus; - f_ExecutionReport_WorkingIndicator = f_ExecutionReport_WorkingIndicator; - f_ExecutionReport_OrdRejReason = f_ExecutionReport_OrdRejReason; - f_ExecutionReport_ExecRestatementReason = f_ExecutionReport_ExecRestatementReason; - f_ExecutionReport_Account = f_ExecutionReport_Account; - f_ExecutionReport_AcctIDSource = f_ExecutionReport_AcctIDSource; - f_ExecutionReport_AccountType = f_ExecutionReport_AccountType; - f_ExecutionReport_DayBookingInst = f_ExecutionReport_DayBookingInst; - f_ExecutionReport_BookingUnit = f_ExecutionReport_BookingUnit; - f_ExecutionReport_PreallocMethod = f_ExecutionReport_PreallocMethod; - f_ExecutionReport_SettlType = f_ExecutionReport_SettlType; - f_ExecutionReport_SettlDate = f_ExecutionReport_SettlDate; - f_ExecutionReport_CashMargin = f_ExecutionReport_CashMargin; - f_ExecutionReport_ClearingFeeIndicator = f_ExecutionReport_ClearingFeeIndicator; - f_ExecutionReport_Side = f_ExecutionReport_Side; - f_ExecutionReport_QtyType = f_ExecutionReport_QtyType; - f_ExecutionReport_OrdType = f_ExecutionReport_OrdType; - f_ExecutionReport_PriceType = f_ExecutionReport_PriceType; - f_ExecutionReport_Price = f_ExecutionReport_Price; - f_ExecutionReport_StopPx = f_ExecutionReport_StopPx; - f_ExecutionReport_PeggedPrice = f_ExecutionReport_PeggedPrice; - f_ExecutionReport_DiscretionPrice = f_ExecutionReport_DiscretionPrice; - f_ExecutionReport_TargetStrategy = f_ExecutionReport_TargetStrategy; - f_ExecutionReport_TargetStrategyParameters = f_ExecutionReport_TargetStrategyParameters; - f_ExecutionReport_ParticipationRate = f_ExecutionReport_ParticipationRate; - f_ExecutionReport_TargetStrategyPerformance = f_ExecutionReport_TargetStrategyPerformance; - f_ExecutionReport_Currency = f_ExecutionReport_Currency; - f_ExecutionReport_ComplianceID = f_ExecutionReport_ComplianceID; - f_ExecutionReport_SolicitedFlag = f_ExecutionReport_SolicitedFlag; - f_ExecutionReport_TimeInForce = f_ExecutionReport_TimeInForce; - f_ExecutionReport_EffectiveTime = f_ExecutionReport_EffectiveTime; - f_ExecutionReport_ExpireDate = f_ExecutionReport_ExpireDate; - f_ExecutionReport_ExpireTime = f_ExecutionReport_ExpireTime; - f_ExecutionReport_ExecInst = f_ExecutionReport_ExecInst; - f_ExecutionReport_OrderCapacity = f_ExecutionReport_OrderCapacity; - f_ExecutionReport_OrderRestrictions = f_ExecutionReport_OrderRestrictions; - f_ExecutionReport_CustOrderCapacity = f_ExecutionReport_CustOrderCapacity; - f_ExecutionReport_LastQty = f_ExecutionReport_LastQty; - f_ExecutionReport_UnderlyingLastQty = f_ExecutionReport_UnderlyingLastQty; - f_ExecutionReport_LastPx = f_ExecutionReport_LastPx; - f_ExecutionReport_UnderlyingLastPx = f_ExecutionReport_UnderlyingLastPx; - f_ExecutionReport_LastParPx = f_ExecutionReport_LastParPx; - f_ExecutionReport_LastSpotRate = f_ExecutionReport_LastSpotRate; - f_ExecutionReport_LastForwardPoints = f_ExecutionReport_LastForwardPoints; - f_ExecutionReport_LastMkt = f_ExecutionReport_LastMkt; - f_ExecutionReport_TradingSessionID = f_ExecutionReport_TradingSessionID; - f_ExecutionReport_TradingSessionSubID = f_ExecutionReport_TradingSessionSubID; - f_ExecutionReport_TimeBracket = f_ExecutionReport_TimeBracket; - f_ExecutionReport_LastCapacity = f_ExecutionReport_LastCapacity; - f_ExecutionReport_LeavesQty = f_ExecutionReport_LeavesQty; - f_ExecutionReport_CumQty = f_ExecutionReport_CumQty; - f_ExecutionReport_AvgPx = f_ExecutionReport_AvgPx; - f_ExecutionReport_DayOrderQty = f_ExecutionReport_DayOrderQty; - f_ExecutionReport_DayCumQty = f_ExecutionReport_DayCumQty; - f_ExecutionReport_DayAvgPx = f_ExecutionReport_DayAvgPx; - f_ExecutionReport_GTBookingInst = f_ExecutionReport_GTBookingInst; - f_ExecutionReport_TradeDate = f_ExecutionReport_TradeDate; - f_ExecutionReport_TransactTime = f_ExecutionReport_TransactTime; - f_ExecutionReport_ReportToExch = f_ExecutionReport_ReportToExch; - f_ExecutionReport_GrossTradeAmt = f_ExecutionReport_GrossTradeAmt; - f_ExecutionReport_NumDaysInterest = f_ExecutionReport_NumDaysInterest; - f_ExecutionReport_ExDate = f_ExecutionReport_ExDate; - f_ExecutionReport_AccruedInterestRate = f_ExecutionReport_AccruedInterestRate; - f_ExecutionReport_AccruedInterestAmt = f_ExecutionReport_AccruedInterestAmt; - f_ExecutionReport_InterestAtMaturity = f_ExecutionReport_InterestAtMaturity; - f_ExecutionReport_EndAccruedInterestAmt = f_ExecutionReport_EndAccruedInterestAmt; - f_ExecutionReport_StartCash = f_ExecutionReport_StartCash; - f_ExecutionReport_EndCash = f_ExecutionReport_EndCash; - f_ExecutionReport_TradedFlatSwitch = f_ExecutionReport_TradedFlatSwitch; - f_ExecutionReport_BasisFeatureDate = f_ExecutionReport_BasisFeatureDate; - f_ExecutionReport_BasisFeaturePrice = f_ExecutionReport_BasisFeaturePrice; - f_ExecutionReport_Concession = f_ExecutionReport_Concession; - f_ExecutionReport_TotalTakedown = f_ExecutionReport_TotalTakedown; - f_ExecutionReport_NetMoney = f_ExecutionReport_NetMoney; - f_ExecutionReport_SettlCurrAmt = f_ExecutionReport_SettlCurrAmt; - f_ExecutionReport_SettlCurrency = f_ExecutionReport_SettlCurrency; - f_ExecutionReport_SettlCurrFxRate = f_ExecutionReport_SettlCurrFxRate; - f_ExecutionReport_SettlCurrFxRateCalc = f_ExecutionReport_SettlCurrFxRateCalc; - f_ExecutionReport_HandlInst = f_ExecutionReport_HandlInst; - f_ExecutionReport_MinQty = f_ExecutionReport_MinQty; - f_ExecutionReport_MaxFloor = f_ExecutionReport_MaxFloor; - f_ExecutionReport_PositionEffect = f_ExecutionReport_PositionEffect; - f_ExecutionReport_MaxShow = f_ExecutionReport_MaxShow; - f_ExecutionReport_BookingType = f_ExecutionReport_BookingType; - f_ExecutionReport_Text = f_ExecutionReport_Text; - f_ExecutionReport_EncodedTextLen = f_ExecutionReport_EncodedTextLen; - f_ExecutionReport_EncodedText = f_ExecutionReport_EncodedText; - f_ExecutionReport_SettlDate2 = f_ExecutionReport_SettlDate2; - f_ExecutionReport_OrderQty2 = f_ExecutionReport_OrderQty2; - f_ExecutionReport_LastForwardPoints2 = f_ExecutionReport_LastForwardPoints2; - f_ExecutionReport_MultiLegReportingType = f_ExecutionReport_MultiLegReportingType; - f_ExecutionReport_CancellationRights = f_ExecutionReport_CancellationRights; - f_ExecutionReport_MoneyLaunderingStatus = f_ExecutionReport_MoneyLaunderingStatus; - f_ExecutionReport_RegistID = f_ExecutionReport_RegistID; - f_ExecutionReport_Designation = f_ExecutionReport_Designation; - f_ExecutionReport_TransBkdTime = f_ExecutionReport_TransBkdTime; - f_ExecutionReport_ExecValuationPoint = f_ExecutionReport_ExecValuationPoint; - f_ExecutionReport_ExecPriceType = f_ExecutionReport_ExecPriceType; - f_ExecutionReport_ExecPriceAdjustment = f_ExecutionReport_ExecPriceAdjustment; - f_ExecutionReport_PriorityIndicator = f_ExecutionReport_PriorityIndicator; - f_ExecutionReport_PriceImprovement = f_ExecutionReport_PriceImprovement; - f_ExecutionReport_LastLiquidityInd = f_ExecutionReport_LastLiquidityInd; - f_ExecutionReport_CopyMsgIndicator = f_ExecutionReport_CopyMsgIndicator - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - )) |> check_unknown_tags -;; let parse_NewOrderSingle (msg) = - (repeating msg "453" parse_Parties (fun msg f_NewOrderSingle_Parties -> repeating msg "78" parse_PreAllocGrp (fun msg f_NewOrderSingle_PreAllocGrp -> repeating msg "386" parse_TrdgSesGrp (fun msg f_NewOrderSingle_TrdgSesGrp -> repeating msg "711" parse_UndInstrmtGrp (fun msg f_NewOrderSingle_UndInstrmtGrp -> repeating msg "232" parse_Stipulations (fun msg f_NewOrderSingle_Stipulations -> check_duplicate_tags msg (fun () -> block msg parse_Instrument (fun msg f_NewOrderSingle_Instrument -> block msg parse_FinancingDetails (fun msg f_NewOrderSingle_FinancingDetails -> block msg parse_OrderQtyData (fun msg f_NewOrderSingle_OrderQtyData -> block msg parse_SpreadOrBenchmarkCurveData (fun msg f_NewOrderSingle_SpreadOrBenchmarkCurveData -> block msg parse_YieldData (fun msg f_NewOrderSingle_YieldData -> block msg parse_CommissionData (fun msg f_NewOrderSingle_CommissionData -> block msg parse_PegInstructions (fun msg f_NewOrderSingle_PegInstructions -> block msg parse_DiscretionInstructions (fun msg f_NewOrderSingle_DiscretionInstructions -> opt msg "11" parse_string (fun msg f_NewOrderSingle_ClOrdID -> opt msg "526" parse_string (fun msg f_NewOrderSingle_SecondaryClOrdID -> opt msg "583" parse_string (fun msg f_NewOrderSingle_ClOrdLinkID -> opt msg "229" parse_LocalMktDate (fun msg f_NewOrderSingle_TradeOriginationDate -> opt msg "75" parse_LocalMktDate (fun msg f_NewOrderSingle_TradeDate -> opt msg "1" parse_string (fun msg f_NewOrderSingle_Account -> opt msg "660" parse_AcctIDSource (fun msg f_NewOrderSingle_AcctIDSource -> opt msg "581" parse_AccountType (fun msg f_NewOrderSingle_AccountType -> opt msg "589" parse_DayBookingInst (fun msg f_NewOrderSingle_DayBookingInst -> opt msg "590" parse_BookingUnit (fun msg f_NewOrderSingle_BookingUnit -> opt msg "591" parse_PreallocMethod (fun msg f_NewOrderSingle_PreallocMethod -> opt msg "70" parse_string (fun msg f_NewOrderSingle_AllocID -> opt msg "63" parse_SettlType (fun msg f_NewOrderSingle_SettlType -> opt msg "64" parse_LocalMktDate (fun msg f_NewOrderSingle_SettlDate -> opt msg "544" parse_CashMargin (fun msg f_NewOrderSingle_CashMargin -> opt msg "635" parse_ClearingFeeIndicator (fun msg f_NewOrderSingle_ClearingFeeIndicator -> opt msg "21" parse_HandlInst (fun msg f_NewOrderSingle_HandlInst -> opt msg "18" parse_ExecInst (fun msg f_NewOrderSingle_ExecInst -> opt msg "110" parse_float (fun msg f_NewOrderSingle_MinQty -> opt msg "111" parse_float (fun msg f_NewOrderSingle_MaxFloor -> opt msg "100" parse_Exchange (fun msg f_NewOrderSingle_ExDestination -> opt msg "81" parse_ProcessCode (fun msg f_NewOrderSingle_ProcessCode -> opt msg "140" parse_float (fun msg f_NewOrderSingle_PrevClosePx -> opt msg "54" parse_Side (fun msg f_NewOrderSingle_Side -> opt msg "114" parse_LocateReqd (fun msg f_NewOrderSingle_LocateReqd -> opt msg "60" parse_UTCTimestamp_milli (fun msg f_NewOrderSingle_TransactTime -> opt msg "854" parse_QtyType (fun msg f_NewOrderSingle_QtyType -> opt msg "40" parse_OrdType (fun msg f_NewOrderSingle_OrdType -> opt msg "423" parse_PriceType (fun msg f_NewOrderSingle_PriceType -> opt msg "44" parse_float (fun msg f_NewOrderSingle_Price -> opt msg "99" parse_float (fun msg f_NewOrderSingle_StopPx -> opt msg "15" parse_Currency (fun msg f_NewOrderSingle_Currency -> opt msg "376" parse_string (fun msg f_NewOrderSingle_ComplianceID -> opt msg "377" parse_SolicitedFlag (fun msg f_NewOrderSingle_SolicitedFlag -> opt msg "23" parse_string (fun msg f_NewOrderSingle_IOIID -> opt msg "117" parse_string (fun msg f_NewOrderSingle_QuoteID -> opt msg "59" parse_TimeInForce (fun msg f_NewOrderSingle_TimeInForce -> opt msg "168" parse_UTCTimestamp_milli (fun msg f_NewOrderSingle_EffectiveTime -> opt msg "432" parse_LocalMktDate (fun msg f_NewOrderSingle_ExpireDate -> opt msg "126" parse_UTCTimestamp_milli (fun msg f_NewOrderSingle_ExpireTime -> opt msg "427" parse_GTBookingInst (fun msg f_NewOrderSingle_GTBookingInst -> opt msg "528" parse_OrderCapacity (fun msg f_NewOrderSingle_OrderCapacity -> opt msg "529" parse_OrderRestrictions (fun msg f_NewOrderSingle_OrderRestrictions -> opt msg "582" parse_CustOrderCapacity (fun msg f_NewOrderSingle_CustOrderCapacity -> opt msg "121" parse_ForexReq (fun msg f_NewOrderSingle_ForexReq -> opt msg "120" parse_Currency (fun msg f_NewOrderSingle_SettlCurrency -> opt msg "775" parse_BookingType (fun msg f_NewOrderSingle_BookingType -> opt msg "58" parse_string (fun msg f_NewOrderSingle_Text -> opt msg "354" parse_int (fun msg f_NewOrderSingle_EncodedTextLen -> opt msg "355" parse_string (fun msg f_NewOrderSingle_EncodedText -> opt msg "193" parse_LocalMktDate (fun msg f_NewOrderSingle_SettlDate2 -> opt msg "192" parse_float (fun msg f_NewOrderSingle_OrderQty2 -> opt msg "640" parse_float (fun msg f_NewOrderSingle_Price2 -> opt msg "77" parse_PositionEffect (fun msg f_NewOrderSingle_PositionEffect -> opt msg "203" parse_CoveredOrUncovered (fun msg f_NewOrderSingle_CoveredOrUncovered -> opt msg "210" parse_float (fun msg f_NewOrderSingle_MaxShow -> opt msg "847" parse_TargetStrategy (fun msg f_NewOrderSingle_TargetStrategy -> opt msg "848" parse_string (fun msg f_NewOrderSingle_TargetStrategyParameters -> opt msg "849" parse_float (fun msg f_NewOrderSingle_ParticipationRate -> opt msg "480" parse_CancellationRights (fun msg f_NewOrderSingle_CancellationRights -> opt msg "481" parse_MoneyLaunderingStatus (fun msg f_NewOrderSingle_MoneyLaunderingStatus -> opt msg "513" parse_string (fun msg f_NewOrderSingle_RegistID -> opt msg "494" parse_string (fun msg f_NewOrderSingle_Designation -> (ParseSuccess { + (repeating msg "453" parse_Parties (fun msg f_NewOrderSingle_Parties -> check_duplicate_tags msg (fun () -> block msg parse_OrderQtyData (fun msg f_NewOrderSingle_OrderQtyData -> opt msg "11" parse_string (fun msg f_NewOrderSingle_ClOrdID -> opt msg "1" parse_string (fun msg f_NewOrderSingle_Account -> opt msg "18" parse_ExecInst (fun msg f_NewOrderSingle_ExecInst -> opt msg "54" parse_Side (fun msg f_NewOrderSingle_Side -> opt msg "60" parse_UTCTimestamp_milli (fun msg f_NewOrderSingle_TransactTime -> opt msg "40" parse_OrdType (fun msg f_NewOrderSingle_OrdType -> opt msg "44" (fun x -> (match parse_float x with + | None -> None + | Some d -> (Some (float_Convert_6_2 d)) + ) + ) (fun msg f_NewOrderSingle_Price -> opt msg "10001" parse_float (fun msg f_NewOrderSingle_SpreadProportion -> (ParseSuccess { f_NewOrderSingle_Parties = f_NewOrderSingle_Parties; - f_NewOrderSingle_PreAllocGrp = f_NewOrderSingle_PreAllocGrp; - f_NewOrderSingle_TrdgSesGrp = f_NewOrderSingle_TrdgSesGrp; - f_NewOrderSingle_UndInstrmtGrp = f_NewOrderSingle_UndInstrmtGrp; - f_NewOrderSingle_Stipulations = f_NewOrderSingle_Stipulations; - f_NewOrderSingle_Instrument = f_NewOrderSingle_Instrument; - f_NewOrderSingle_FinancingDetails = f_NewOrderSingle_FinancingDetails; f_NewOrderSingle_OrderQtyData = f_NewOrderSingle_OrderQtyData; - f_NewOrderSingle_SpreadOrBenchmarkCurveData = f_NewOrderSingle_SpreadOrBenchmarkCurveData; - f_NewOrderSingle_YieldData = f_NewOrderSingle_YieldData; - f_NewOrderSingle_CommissionData = f_NewOrderSingle_CommissionData; - f_NewOrderSingle_PegInstructions = f_NewOrderSingle_PegInstructions; - f_NewOrderSingle_DiscretionInstructions = f_NewOrderSingle_DiscretionInstructions; f_NewOrderSingle_ClOrdID = f_NewOrderSingle_ClOrdID; - f_NewOrderSingle_SecondaryClOrdID = f_NewOrderSingle_SecondaryClOrdID; - f_NewOrderSingle_ClOrdLinkID = f_NewOrderSingle_ClOrdLinkID; - f_NewOrderSingle_TradeOriginationDate = f_NewOrderSingle_TradeOriginationDate; - f_NewOrderSingle_TradeDate = f_NewOrderSingle_TradeDate; f_NewOrderSingle_Account = f_NewOrderSingle_Account; - f_NewOrderSingle_AcctIDSource = f_NewOrderSingle_AcctIDSource; - f_NewOrderSingle_AccountType = f_NewOrderSingle_AccountType; - f_NewOrderSingle_DayBookingInst = f_NewOrderSingle_DayBookingInst; - f_NewOrderSingle_BookingUnit = f_NewOrderSingle_BookingUnit; - f_NewOrderSingle_PreallocMethod = f_NewOrderSingle_PreallocMethod; - f_NewOrderSingle_AllocID = f_NewOrderSingle_AllocID; - f_NewOrderSingle_SettlType = f_NewOrderSingle_SettlType; - f_NewOrderSingle_SettlDate = f_NewOrderSingle_SettlDate; - f_NewOrderSingle_CashMargin = f_NewOrderSingle_CashMargin; - f_NewOrderSingle_ClearingFeeIndicator = f_NewOrderSingle_ClearingFeeIndicator; - f_NewOrderSingle_HandlInst = f_NewOrderSingle_HandlInst; f_NewOrderSingle_ExecInst = f_NewOrderSingle_ExecInst; - f_NewOrderSingle_MinQty = f_NewOrderSingle_MinQty; - f_NewOrderSingle_MaxFloor = f_NewOrderSingle_MaxFloor; - f_NewOrderSingle_ExDestination = f_NewOrderSingle_ExDestination; - f_NewOrderSingle_ProcessCode = f_NewOrderSingle_ProcessCode; - f_NewOrderSingle_PrevClosePx = f_NewOrderSingle_PrevClosePx; f_NewOrderSingle_Side = f_NewOrderSingle_Side; - f_NewOrderSingle_LocateReqd = f_NewOrderSingle_LocateReqd; f_NewOrderSingle_TransactTime = f_NewOrderSingle_TransactTime; - f_NewOrderSingle_QtyType = f_NewOrderSingle_QtyType; f_NewOrderSingle_OrdType = f_NewOrderSingle_OrdType; - f_NewOrderSingle_PriceType = f_NewOrderSingle_PriceType; f_NewOrderSingle_Price = f_NewOrderSingle_Price; - f_NewOrderSingle_StopPx = f_NewOrderSingle_StopPx; - f_NewOrderSingle_Currency = f_NewOrderSingle_Currency; - f_NewOrderSingle_ComplianceID = f_NewOrderSingle_ComplianceID; - f_NewOrderSingle_SolicitedFlag = f_NewOrderSingle_SolicitedFlag; - f_NewOrderSingle_IOIID = f_NewOrderSingle_IOIID; - f_NewOrderSingle_QuoteID = f_NewOrderSingle_QuoteID; - f_NewOrderSingle_TimeInForce = f_NewOrderSingle_TimeInForce; - f_NewOrderSingle_EffectiveTime = f_NewOrderSingle_EffectiveTime; - f_NewOrderSingle_ExpireDate = f_NewOrderSingle_ExpireDate; - f_NewOrderSingle_ExpireTime = f_NewOrderSingle_ExpireTime; - f_NewOrderSingle_GTBookingInst = f_NewOrderSingle_GTBookingInst; - f_NewOrderSingle_OrderCapacity = f_NewOrderSingle_OrderCapacity; - f_NewOrderSingle_OrderRestrictions = f_NewOrderSingle_OrderRestrictions; - f_NewOrderSingle_CustOrderCapacity = f_NewOrderSingle_CustOrderCapacity; - f_NewOrderSingle_ForexReq = f_NewOrderSingle_ForexReq; - f_NewOrderSingle_SettlCurrency = f_NewOrderSingle_SettlCurrency; - f_NewOrderSingle_BookingType = f_NewOrderSingle_BookingType; - f_NewOrderSingle_Text = f_NewOrderSingle_Text; - f_NewOrderSingle_EncodedTextLen = f_NewOrderSingle_EncodedTextLen; - f_NewOrderSingle_EncodedText = f_NewOrderSingle_EncodedText; - f_NewOrderSingle_SettlDate2 = f_NewOrderSingle_SettlDate2; - f_NewOrderSingle_OrderQty2 = f_NewOrderSingle_OrderQty2; - f_NewOrderSingle_Price2 = f_NewOrderSingle_Price2; - f_NewOrderSingle_PositionEffect = f_NewOrderSingle_PositionEffect; - f_NewOrderSingle_CoveredOrUncovered = f_NewOrderSingle_CoveredOrUncovered; - f_NewOrderSingle_MaxShow = f_NewOrderSingle_MaxShow; - f_NewOrderSingle_TargetStrategy = f_NewOrderSingle_TargetStrategy; - f_NewOrderSingle_TargetStrategyParameters = f_NewOrderSingle_TargetStrategyParameters; - f_NewOrderSingle_ParticipationRate = f_NewOrderSingle_ParticipationRate; - f_NewOrderSingle_CancellationRights = f_NewOrderSingle_CancellationRights; - f_NewOrderSingle_MoneyLaunderingStatus = f_NewOrderSingle_MoneyLaunderingStatus; - f_NewOrderSingle_RegistID = f_NewOrderSingle_RegistID; - f_NewOrderSingle_Designation = f_NewOrderSingle_Designation + f_NewOrderSingle_SpreadProportion = f_NewOrderSingle_SpreadProportion },msg) ) ) @@ -386,61 +45,23 @@ let parse_NewOrderSingle (msg) = ) ) ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) + )) |> check_unknown_tags +;; + +let parse_ExecutionReport (msg) = + (repeating msg "453" parse_Parties (fun msg f_ExecutionReport_Parties -> check_duplicate_tags msg (fun () -> block msg parse_OrderQtyData (fun msg f_ExecutionReport_OrderQtyData -> opt msg "37" parse_string (fun msg f_ExecutionReport_OrderID -> opt msg "17" parse_string (fun msg f_ExecutionReport_ExecID -> opt msg "150" parse_ExecType (fun msg f_ExecutionReport_ExecType -> opt msg "39" parse_OrdStatus (fun msg f_ExecutionReport_OrdStatus -> opt msg "54" parse_Side (fun msg f_ExecutionReport_Side -> opt msg "18" parse_ExecInst (fun msg f_ExecutionReport_ExecInst -> opt msg "151" parse_float (fun msg f_ExecutionReport_LeavesQty -> opt msg "14" parse_float (fun msg f_ExecutionReport_CumQty -> opt msg "58" parse_string (fun msg f_ExecutionReport_Text -> (ParseSuccess { + f_ExecutionReport_Parties = f_ExecutionReport_Parties; + f_ExecutionReport_OrderQtyData = f_ExecutionReport_OrderQtyData; + f_ExecutionReport_OrderID = f_ExecutionReport_OrderID; + f_ExecutionReport_ExecID = f_ExecutionReport_ExecID; + f_ExecutionReport_ExecType = f_ExecutionReport_ExecType; + f_ExecutionReport_OrdStatus = f_ExecutionReport_OrdStatus; + f_ExecutionReport_Side = f_ExecutionReport_Side; + f_ExecutionReport_ExecInst = f_ExecutionReport_ExecInst; + f_ExecutionReport_LeavesQty = f_ExecutionReport_LeavesQty; + f_ExecutionReport_CumQty = f_ExecutionReport_CumQty; + f_ExecutionReport_Text = f_ExecutionReport_Text + },msg) ) ) ) @@ -457,10 +78,11 @@ let parse_NewOrderSingle (msg) = let parse_app_msg_data (msg_tag) (msg) = (match msg_tag with - | Full_Msg_ExecutionReport_Tag -> ((>>=) (parse_ExecutionReport msg) (fun f -> ParseSuccess (FIX_Full_Msg_ExecutionReport f) - )) | Full_Msg_NewOrderSingle_Tag -> ((>>=) (parse_NewOrderSingle msg) (fun f -> ParseSuccess (FIX_Full_Msg_NewOrderSingle f) )) + | Full_Msg_ExecutionReport_Tag -> ((>>=) (parse_ExecutionReport msg) (fun f -> ParseSuccess (FIX_Full_Msg_ExecutionReport f) + )) ) ;; + [@@@logic] diff --git a/src-protocol-exts-pp/parse_app_records.iml b/src-protocol-exts-pp/parse_app_records.iml index c60f9eda..6f22828d 100644 --- a/src-protocol-exts-pp/parse_app_records.iml +++ b/src-protocol-exts-pp/parse_app_records.iml @@ -1,9 +1,7 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] [@@@import "../src-protocol-exts/full_app_records.iml"] open Full_app_records;; -[@@@import "parse_app_enums.iml"] -open Parse_app_enums;; [@@@import "../src-core-pp/parse_base_types.iml"] open Parse_base_types;; [@@@import "../src-core-pp/parse_datetime.iml"] @@ -12,2687 +10,31 @@ open Parse_datetime;; open Parser_utils.Parser;; -let parse_UndSecAltIDGrp (msg) (f_UndSecAltIDGrp_NoUnderlyingSecurityAltID) = - opt msg "459" parse_string (fun msg f_UndSecAltIDGrp_UnderlyingSecurityAltIDSource -> opt msg "458" parse_string (fun msg f_UndSecAltIDGrp_UnderlyingSecurityAltID -> (ParseSuccess { - f_UndSecAltIDGrp_NoUnderlyingSecurityAltID = f_UndSecAltIDGrp_NoUnderlyingSecurityAltID; - f_UndSecAltIDGrp_UnderlyingSecurityAltID = f_UndSecAltIDGrp_UnderlyingSecurityAltID; - f_UndSecAltIDGrp_UnderlyingSecurityAltIDSource = f_UndSecAltIDGrp_UnderlyingSecurityAltIDSource - },msg) - ) - ) - [@@macro] -;; - -let parse_NstdPtys2SubGrp (msg) (f_NstdPtys2SubGrp_NoNested2PartySubIDs) = - opt msg "807" parse_int (fun msg f_NstdPtys2SubGrp_Nested2PartySubIDType -> opt msg "760" parse_string (fun msg f_NstdPtys2SubGrp_Nested2PartySubID -> (ParseSuccess { - f_NstdPtys2SubGrp_NoNested2PartySubIDs = f_NstdPtys2SubGrp_NoNested2PartySubIDs; - f_NstdPtys2SubGrp_Nested2PartySubID = f_NstdPtys2SubGrp_Nested2PartySubID; - f_NstdPtys2SubGrp_Nested2PartySubIDType = f_NstdPtys2SubGrp_Nested2PartySubIDType - },msg) - ) - ) - [@@macro] -;; - -let parse_ExecsGrp (msg) (f_ExecsGrp_NoExecs) = - opt msg "17" parse_string (fun msg f_ExecsGrp_ExecID -> (ParseSuccess { - f_ExecsGrp_NoExecs = f_ExecsGrp_NoExecs; - f_ExecsGrp_ExecID = f_ExecsGrp_ExecID - },msg) - ) - [@@macro] -;; - -let parse_MDReqGrp (msg) (f_MDReqGrp_NoMDEntryTypes) = - opt msg "269" parse_MDEntryType (fun msg f_MDReqGrp_MDEntryType -> (ParseSuccess { - f_MDReqGrp_NoMDEntryTypes = f_MDReqGrp_NoMDEntryTypes; - f_MDReqGrp_MDEntryType = f_MDReqGrp_MDEntryType - },msg) - ) - [@@macro] -;; - -let parse_RgstDistInstGrp (msg) (f_RgstDistInstGrp_NoDistribInsts) = - opt msg "502" parse_string (fun msg f_RgstDistInstGrp_CashDistribAgentAcctName -> opt msg "501" parse_string (fun msg f_RgstDistInstGrp_CashDistribPayRef -> opt msg "500" parse_string (fun msg f_RgstDistInstGrp_CashDistribAgentAcctNumber -> opt msg "499" parse_string (fun msg f_RgstDistInstGrp_CashDistribAgentCode -> opt msg "498" parse_string (fun msg f_RgstDistInstGrp_CashDistribAgentName -> opt msg "478" parse_Currency (fun msg f_RgstDistInstGrp_CashDistribCurr -> opt msg "512" parse_float (fun msg f_RgstDistInstGrp_DistribPercentage -> opt msg "477" parse_DistribPaymentMethod (fun msg f_RgstDistInstGrp_DistribPaymentMethod -> (ParseSuccess { - f_RgstDistInstGrp_NoDistribInsts = f_RgstDistInstGrp_NoDistribInsts; - f_RgstDistInstGrp_DistribPaymentMethod = f_RgstDistInstGrp_DistribPaymentMethod; - f_RgstDistInstGrp_DistribPercentage = f_RgstDistInstGrp_DistribPercentage; - f_RgstDistInstGrp_CashDistribCurr = f_RgstDistInstGrp_CashDistribCurr; - f_RgstDistInstGrp_CashDistribAgentName = f_RgstDistInstGrp_CashDistribAgentName; - f_RgstDistInstGrp_CashDistribAgentCode = f_RgstDistInstGrp_CashDistribAgentCode; - f_RgstDistInstGrp_CashDistribAgentAcctNumber = f_RgstDistInstGrp_CashDistribAgentAcctNumber; - f_RgstDistInstGrp_CashDistribPayRef = f_RgstDistInstGrp_CashDistribPayRef; - f_RgstDistInstGrp_CashDistribAgentAcctName = f_RgstDistInstGrp_CashDistribAgentAcctName - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_ContraGrp (msg) (f_ContraGrp_NoContraBrokers) = - opt msg "655" parse_string (fun msg f_ContraGrp_ContraLegRefID -> opt msg "438" parse_UTCTimestamp_milli (fun msg f_ContraGrp_ContraTradeTime -> opt msg "437" parse_float (fun msg f_ContraGrp_ContraTradeQty -> opt msg "337" parse_string (fun msg f_ContraGrp_ContraTrader -> opt msg "375" parse_string (fun msg f_ContraGrp_ContraBroker -> (ParseSuccess { - f_ContraGrp_NoContraBrokers = f_ContraGrp_NoContraBrokers; - f_ContraGrp_ContraBroker = f_ContraGrp_ContraBroker; - f_ContraGrp_ContraTrader = f_ContraGrp_ContraTrader; - f_ContraGrp_ContraTradeQty = f_ContraGrp_ContraTradeQty; - f_ContraGrp_ContraTradeTime = f_ContraGrp_ContraTradeTime; - f_ContraGrp_ContraLegRefID = f_ContraGrp_ContraLegRefID - },msg) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_LegSecAltIDGrp (msg) (f_LegSecAltIDGrp_NoLegSecurityAltID) = - opt msg "606" parse_string (fun msg f_LegSecAltIDGrp_LegSecurityAltIDSource -> opt msg "605" parse_string (fun msg f_LegSecAltIDGrp_LegSecurityAltID -> (ParseSuccess { - f_LegSecAltIDGrp_NoLegSecurityAltID = f_LegSecAltIDGrp_NoLegSecurityAltID; - f_LegSecAltIDGrp_LegSecurityAltID = f_LegSecAltIDGrp_LegSecurityAltID; - f_LegSecAltIDGrp_LegSecurityAltIDSource = f_LegSecAltIDGrp_LegSecurityAltIDSource - },msg) - ) - ) - [@@macro] -;; - -let parse_NstdPtys3SubGrp (msg) (f_NstdPtys3SubGrp_NoNested3PartySubIDs) = - opt msg "954" parse_int (fun msg f_NstdPtys3SubGrp_Nested3PartySubIDType -> opt msg "953" parse_string (fun msg f_NstdPtys3SubGrp_Nested3PartySubID -> (ParseSuccess { - f_NstdPtys3SubGrp_NoNested3PartySubIDs = f_NstdPtys3SubGrp_NoNested3PartySubIDs; - f_NstdPtys3SubGrp_Nested3PartySubID = f_NstdPtys3SubGrp_Nested3PartySubID; - f_NstdPtys3SubGrp_Nested3PartySubIDType = f_NstdPtys3SubGrp_Nested3PartySubIDType - },msg) - ) - ) - [@@macro] -;; - -let parse_FinancingDetails (msg) = - opt msg "898" parse_float (fun msg f_FinancingDetails_MarginRatio -> opt msg "919" parse_DeliveryType (fun msg f_FinancingDetails_DeliveryType -> opt msg "917" parse_LocalMktDate (fun msg f_FinancingDetails_EndDate -> opt msg "916" parse_LocalMktDate (fun msg f_FinancingDetails_StartDate -> opt msg "788" parse_TerminationType (fun msg f_FinancingDetails_TerminationType -> opt msg "918" parse_Currency (fun msg f_FinancingDetails_AgreementCurrency -> opt msg "915" parse_LocalMktDate (fun msg f_FinancingDetails_AgreementDate -> opt msg "914" parse_string (fun msg f_FinancingDetails_AgreementID -> opt msg "913" parse_string (fun msg f_FinancingDetails_AgreementDesc -> (ParseSuccess { - f_FinancingDetails_AgreementDesc = f_FinancingDetails_AgreementDesc; - f_FinancingDetails_AgreementID = f_FinancingDetails_AgreementID; - f_FinancingDetails_AgreementDate = f_FinancingDetails_AgreementDate; - f_FinancingDetails_AgreementCurrency = f_FinancingDetails_AgreementCurrency; - f_FinancingDetails_TerminationType = f_FinancingDetails_TerminationType; - f_FinancingDetails_StartDate = f_FinancingDetails_StartDate; - f_FinancingDetails_EndDate = f_FinancingDetails_EndDate; - f_FinancingDetails_DeliveryType = f_FinancingDetails_DeliveryType; - f_FinancingDetails_MarginRatio = f_FinancingDetails_MarginRatio - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_interval (msg) = - opt msg "" parse_Duration (fun msg f_interval_duration -> opt msg "" parse_UTCTimestamp_milli (fun msg f_interval_start_time -> (ParseSuccess { - f_interval_start_time = f_interval_start_time; - f_interval_duration = f_interval_duration - },msg) - ) - ) - [@@macro] -;; - -let parse_TrdCapDtGrp (msg) (f_TrdCapDtGrp_NoDates) = - opt msg "60" parse_UTCTimestamp_milli (fun msg f_TrdCapDtGrp_TransactTime -> opt msg "75" parse_LocalMktDate (fun msg f_TrdCapDtGrp_TradeDate -> (ParseSuccess { - f_TrdCapDtGrp_NoDates = f_TrdCapDtGrp_NoDates; - f_TrdCapDtGrp_TradeDate = f_TrdCapDtGrp_TradeDate; - f_TrdCapDtGrp_TransactTime = f_TrdCapDtGrp_TransactTime - },msg) - ) - ) - [@@macro] -;; - -let parse_PegInstructions (msg) = - opt msg "840" parse_PegScope (fun msg f_PegInstructions_PegScope -> opt msg "838" parse_PegRoundDirection (fun msg f_PegInstructions_PegRoundDirection -> opt msg "837" parse_PegLimitType (fun msg f_PegInstructions_PegLimitType -> opt msg "836" parse_PegOffsetType (fun msg f_PegInstructions_PegOffsetType -> opt msg "835" parse_PegMoveType (fun msg f_PegInstructions_PegMoveType -> opt msg "211" parse_float (fun msg f_PegInstructions_PegOffsetValue -> (ParseSuccess { - f_PegInstructions_PegOffsetValue = f_PegInstructions_PegOffsetValue; - f_PegInstructions_PegMoveType = f_PegInstructions_PegMoveType; - f_PegInstructions_PegOffsetType = f_PegInstructions_PegOffsetType; - f_PegInstructions_PegLimitType = f_PegInstructions_PegLimitType; - f_PegInstructions_PegRoundDirection = f_PegInstructions_PegRoundDirection; - f_PegInstructions_PegScope = f_PegInstructions_PegScope - },msg) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_BidCompReqGrp (msg) (f_BidCompReqGrp_NoBidComponents) = - opt msg "660" parse_AcctIDSource (fun msg f_BidCompReqGrp_AcctIDSource -> opt msg "1" parse_string (fun msg f_BidCompReqGrp_Account -> opt msg "64" parse_LocalMktDate (fun msg f_BidCompReqGrp_SettlDate -> opt msg "63" parse_SettlType (fun msg f_BidCompReqGrp_SettlType -> opt msg "430" parse_NetGrossInd (fun msg f_BidCompReqGrp_NetGrossInd -> opt msg "625" parse_string (fun msg f_BidCompReqGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_BidCompReqGrp_TradingSessionID -> opt msg "54" parse_Side (fun msg f_BidCompReqGrp_Side -> opt msg "66" parse_string (fun msg f_BidCompReqGrp_ListID -> (ParseSuccess { - f_BidCompReqGrp_NoBidComponents = f_BidCompReqGrp_NoBidComponents; - f_BidCompReqGrp_ListID = f_BidCompReqGrp_ListID; - f_BidCompReqGrp_Side = f_BidCompReqGrp_Side; - f_BidCompReqGrp_TradingSessionID = f_BidCompReqGrp_TradingSessionID; - f_BidCompReqGrp_TradingSessionSubID = f_BidCompReqGrp_TradingSessionSubID; - f_BidCompReqGrp_NetGrossInd = f_BidCompReqGrp_NetGrossInd; - f_BidCompReqGrp_SettlType = f_BidCompReqGrp_SettlType; - f_BidCompReqGrp_SettlDate = f_BidCompReqGrp_SettlDate; - f_BidCompReqGrp_Account = f_BidCompReqGrp_Account; - f_BidCompReqGrp_AcctIDSource = f_BidCompReqGrp_AcctIDSource - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_TrdCollGrp (msg) (f_TrdCollGrp_NoTrades) = - opt msg "818" parse_string (fun msg f_TrdCollGrp_SecondaryTradeReportID -> opt msg "571" parse_string (fun msg f_TrdCollGrp_TradeReportID -> (ParseSuccess { - f_TrdCollGrp_NoTrades = f_TrdCollGrp_NoTrades; - f_TrdCollGrp_TradeReportID = f_TrdCollGrp_TradeReportID; - f_TrdCollGrp_SecondaryTradeReportID = f_TrdCollGrp_SecondaryTradeReportID - },msg) - ) - ) - [@@macro] -;; - -let parse_AllocAckGrp (msg) (f_AllocAckGrp_NoAllocs) = - opt msg "361" parse_string (fun msg f_AllocAckGrp_EncodedAllocText -> opt msg "360" parse_int (fun msg f_AllocAckGrp_EncodedAllocTextLen -> opt msg "161" parse_string (fun msg f_AllocAckGrp_AllocText -> opt msg "776" parse_int (fun msg f_AllocAckGrp_IndividualAllocRejCode -> opt msg "467" parse_string (fun msg f_AllocAckGrp_IndividualAllocID -> opt msg "366" parse_float (fun msg f_AllocAckGrp_AllocPrice -> opt msg "661" parse_int (fun msg f_AllocAckGrp_AllocAcctIDSource -> opt msg "79" parse_string (fun msg f_AllocAckGrp_AllocAccount -> (ParseSuccess { - f_AllocAckGrp_NoAllocs = f_AllocAckGrp_NoAllocs; - f_AllocAckGrp_AllocAccount = f_AllocAckGrp_AllocAccount; - f_AllocAckGrp_AllocAcctIDSource = f_AllocAckGrp_AllocAcctIDSource; - f_AllocAckGrp_AllocPrice = f_AllocAckGrp_AllocPrice; - f_AllocAckGrp_IndividualAllocID = f_AllocAckGrp_IndividualAllocID; - f_AllocAckGrp_IndividualAllocRejCode = f_AllocAckGrp_IndividualAllocRejCode; - f_AllocAckGrp_AllocText = f_AllocAckGrp_AllocText; - f_AllocAckGrp_EncodedAllocTextLen = f_AllocAckGrp_EncodedAllocTextLen; - f_AllocAckGrp_EncodedAllocText = f_AllocAckGrp_EncodedAllocText - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_EvntGrp (msg) (f_EvntGrp_NoEvents) = - opt msg "868" parse_string (fun msg f_EvntGrp_EventText -> opt msg "867" parse_float (fun msg f_EvntGrp_EventPx -> opt msg "866" parse_LocalMktDate (fun msg f_EvntGrp_EventDate -> opt msg "865" parse_EventType (fun msg f_EvntGrp_EventType -> (ParseSuccess { - f_EvntGrp_NoEvents = f_EvntGrp_NoEvents; - f_EvntGrp_EventType = f_EvntGrp_EventType; - f_EvntGrp_EventDate = f_EvntGrp_EventDate; - f_EvntGrp_EventPx = f_EvntGrp_EventPx; - f_EvntGrp_EventText = f_EvntGrp_EventText - },msg) - ) - ) - ) - ) - [@@macro] -;; - -let parse_TrdgSesGrp (msg) (f_TrdgSesGrp_NoTradingSessions) = - opt msg "625" parse_string (fun msg f_TrdgSesGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_TrdgSesGrp_TradingSessionID -> (ParseSuccess { - f_TrdgSesGrp_NoTradingSessions = f_TrdgSesGrp_NoTradingSessions; - f_TrdgSesGrp_TradingSessionID = f_TrdgSesGrp_TradingSessionID; - f_TrdgSesGrp_TradingSessionSubID = f_TrdgSesGrp_TradingSessionSubID - },msg) - ) - ) - [@@macro] -;; - -let parse_AffectedOrdGrp (msg) (f_AffectedOrdGrp_NoAffectedOrders) = - opt msg "536" parse_string (fun msg f_AffectedOrdGrp_AffectedSecondaryOrderID -> opt msg "535" parse_string (fun msg f_AffectedOrdGrp_AffectedOrderID -> opt msg "41" parse_string (fun msg f_AffectedOrdGrp_OrigClOrdID -> (ParseSuccess { - f_AffectedOrdGrp_NoAffectedOrders = f_AffectedOrdGrp_NoAffectedOrders; - f_AffectedOrdGrp_OrigClOrdID = f_AffectedOrdGrp_OrigClOrdID; - f_AffectedOrdGrp_AffectedOrderID = f_AffectedOrdGrp_AffectedOrderID; - f_AffectedOrdGrp_AffectedSecondaryOrderID = f_AffectedOrdGrp_AffectedSecondaryOrderID - },msg) - ) - ) - ) - [@@macro] -;; - -let parse_SecTypesGrp (msg) (f_SecTypesGrp_NoSecurityTypes) = - opt msg "461" parse_string (fun msg f_SecTypesGrp_CFICode -> opt msg "460" parse_Product (fun msg f_SecTypesGrp_Product -> opt msg "762" parse_string (fun msg f_SecTypesGrp_SecuritySubType -> opt msg "167" parse_SecurityType (fun msg f_SecTypesGrp_SecurityType -> (ParseSuccess { - f_SecTypesGrp_NoSecurityTypes = f_SecTypesGrp_NoSecurityTypes; - f_SecTypesGrp_SecurityType = f_SecTypesGrp_SecurityType; - f_SecTypesGrp_SecuritySubType = f_SecTypesGrp_SecuritySubType; - f_SecTypesGrp_Product = f_SecTypesGrp_Product; - f_SecTypesGrp_CFICode = f_SecTypesGrp_CFICode - },msg) - ) - ) - ) - ) - [@@macro] -;; - -let parse_LogonMsgTypes (msg) (f_LogonMsgTypes_NoMsgTypes) = - opt msg "385" parse_MsgDirection (fun msg f_LogonMsgTypes_MsgDirection -> opt msg "372" parse_string (fun msg f_LogonMsgTypes_RefMsgType -> (ParseSuccess { - f_LogonMsgTypes_NoMsgTypes = f_LogonMsgTypes_NoMsgTypes; - f_LogonMsgTypes_RefMsgType = f_LogonMsgTypes_RefMsgType; - f_LogonMsgTypes_MsgDirection = f_LogonMsgTypes_MsgDirection - },msg) - ) - ) - [@@macro] -;; - -let parse_Stipulations (msg) (f_Stipulations_NoStipulations) = - opt msg "234" parse_string (fun msg f_Stipulations_StipulationValue -> opt msg "233" parse_StipulationType (fun msg f_Stipulations_StipulationType -> (ParseSuccess { - f_Stipulations_NoStipulations = f_Stipulations_NoStipulations; - f_Stipulations_StipulationType = f_Stipulations_StipulationType; - f_Stipulations_StipulationValue = f_Stipulations_StipulationValue - },msg) - ) - ) - [@@macro] -;; - -let parse_CommissionData (msg) = - opt msg "497" parse_FundRenewWaiv (fun msg f_CommissionData_FundRenewWaiv -> opt msg "479" parse_Currency (fun msg f_CommissionData_CommCurrency -> opt msg "13" parse_CommType (fun msg f_CommissionData_CommType -> opt msg "12" parse_float (fun msg f_CommissionData_Commission -> (ParseSuccess { - f_CommissionData_Commission = f_CommissionData_Commission; - f_CommissionData_CommType = f_CommissionData_CommType; - f_CommissionData_CommCurrency = f_CommissionData_CommCurrency; - f_CommissionData_FundRenewWaiv = f_CommissionData_FundRenewWaiv - },msg) - ) - ) - ) - ) - [@@macro] -;; - -let parse_CollInqQualGrp (msg) (f_CollInqQualGrp_NoCollInquiryQualifier) = - opt msg "896" parse_CollInquiryQualifier (fun msg f_CollInqQualGrp_CollInquiryQualifier -> (ParseSuccess { - f_CollInqQualGrp_NoCollInquiryQualifier = f_CollInqQualGrp_NoCollInquiryQualifier; - f_CollInqQualGrp_CollInquiryQualifier = f_CollInqQualGrp_CollInquiryQualifier - },msg) - ) - [@@macro] -;; - -let parse_YieldData (msg) = - opt msg "698" parse_int (fun msg f_YieldData_YieldRedemptionPriceType -> opt msg "697" parse_float (fun msg f_YieldData_YieldRedemptionPrice -> opt msg "696" parse_LocalMktDate (fun msg f_YieldData_YieldRedemptionDate -> opt msg "701" parse_LocalMktDate (fun msg f_YieldData_YieldCalcDate -> opt msg "236" parse_float (fun msg f_YieldData_Yield -> opt msg "235" parse_YieldType (fun msg f_YieldData_YieldType -> (ParseSuccess { - f_YieldData_YieldType = f_YieldData_YieldType; - f_YieldData_Yield = f_YieldData_Yield; - f_YieldData_YieldCalcDate = f_YieldData_YieldCalcDate; - f_YieldData_YieldRedemptionDate = f_YieldData_YieldRedemptionDate; - f_YieldData_YieldRedemptionPrice = f_YieldData_YieldRedemptionPrice; - f_YieldData_YieldRedemptionPriceType = f_YieldData_YieldRedemptionPriceType - },msg) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_MiscFeesGrp (msg) (f_MiscFeesGrp_NoMiscFees) = - opt msg "891" parse_MiscFeeBasis (fun msg f_MiscFeesGrp_MiscFeeBasis -> opt msg "139" parse_MiscFeeType (fun msg f_MiscFeesGrp_MiscFeeType -> opt msg "138" parse_Currency (fun msg f_MiscFeesGrp_MiscFeeCurr -> opt msg "137" parse_float (fun msg f_MiscFeesGrp_MiscFeeAmt -> (ParseSuccess { - f_MiscFeesGrp_NoMiscFees = f_MiscFeesGrp_NoMiscFees; - f_MiscFeesGrp_MiscFeeAmt = f_MiscFeesGrp_MiscFeeAmt; - f_MiscFeesGrp_MiscFeeCurr = f_MiscFeesGrp_MiscFeeCurr; - f_MiscFeesGrp_MiscFeeType = f_MiscFeesGrp_MiscFeeType; - f_MiscFeesGrp_MiscFeeBasis = f_MiscFeesGrp_MiscFeeBasis - },msg) - ) - ) - ) - ) - [@@macro] -;; - -let parse_MDRjctGrp (msg) (f_MDRjctGrp_NoAltMDSource) = - opt msg "817" parse_string (fun msg f_MDRjctGrp_AltMDSourceID -> (ParseSuccess { - f_MDRjctGrp_NoAltMDSource = f_MDRjctGrp_NoAltMDSource; - f_MDRjctGrp_AltMDSourceID = f_MDRjctGrp_AltMDSourceID - },msg) - ) - [@@macro] -;; - -let parse_TrdRegTimestamps (msg) (f_TrdRegTimestamps_NoTrdRegTimestamps) = - opt msg "771" parse_string (fun msg f_TrdRegTimestamps_TrdRegTimestampOrigin -> opt msg "770" parse_TrdRegTimestampType (fun msg f_TrdRegTimestamps_TrdRegTimestampType -> opt msg "769" parse_UTCTimestamp_milli (fun msg f_TrdRegTimestamps_TrdRegTimestamp -> (ParseSuccess { - f_TrdRegTimestamps_NoTrdRegTimestamps = f_TrdRegTimestamps_NoTrdRegTimestamps; - f_TrdRegTimestamps_TrdRegTimestamp = f_TrdRegTimestamps_TrdRegTimestamp; - f_TrdRegTimestamps_TrdRegTimestampType = f_TrdRegTimestamps_TrdRegTimestampType; - f_TrdRegTimestamps_TrdRegTimestampOrigin = f_TrdRegTimestamps_TrdRegTimestampOrigin - },msg) - ) - ) - ) - [@@macro] -;; - -let parse_LinesOfTextGrp (msg) (f_LinesOfTextGrp_NoLinesOfText) = - opt msg "355" parse_string (fun msg f_LinesOfTextGrp_EncodedText -> opt msg "354" parse_int (fun msg f_LinesOfTextGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_LinesOfTextGrp_Text -> (ParseSuccess { - f_LinesOfTextGrp_NoLinesOfText = f_LinesOfTextGrp_NoLinesOfText; - f_LinesOfTextGrp_Text = f_LinesOfTextGrp_Text; - f_LinesOfTextGrp_EncodedTextLen = f_LinesOfTextGrp_EncodedTextLen; - f_LinesOfTextGrp_EncodedText = f_LinesOfTextGrp_EncodedText - },msg) - ) - ) - ) - [@@macro] -;; - -let parse_ExecCollGrp (msg) (f_ExecCollGrp_NoExecs) = - opt msg "17" parse_string (fun msg f_ExecCollGrp_ExecID -> (ParseSuccess { - f_ExecCollGrp_NoExecs = f_ExecCollGrp_NoExecs; - f_ExecCollGrp_ExecID = f_ExecCollGrp_ExecID - },msg) - ) - [@@macro] -;; - -let parse_MDFullGrp (msg) (f_MDFullGrp_NoMDEntries) = - opt msg "355" parse_string (fun msg f_MDFullGrp_EncodedText -> opt msg "354" parse_int (fun msg f_MDFullGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_MDFullGrp_Text -> opt msg "811" parse_float (fun msg f_MDFullGrp_PriceDelta -> opt msg "546" parse_Scope (fun msg f_MDFullGrp_Scope -> opt msg "290" parse_int (fun msg f_MDFullGrp_MDEntryPositionNo -> opt msg "346" parse_int (fun msg f_MDFullGrp_NumberOfOrders -> opt msg "289" parse_string (fun msg f_MDFullGrp_MDEntrySeller -> opt msg "288" parse_string (fun msg f_MDFullGrp_MDEntryBuyer -> opt msg "299" parse_string (fun msg f_MDFullGrp_QuoteEntryID -> opt msg "37" parse_string (fun msg f_MDFullGrp_OrderID -> opt msg "287" parse_int (fun msg f_MDFullGrp_SellerDays -> opt msg "18" parse_ExecInst (fun msg f_MDFullGrp_ExecInst -> opt msg "110" parse_float (fun msg f_MDFullGrp_MinQty -> opt msg "126" parse_UTCTimestamp_milli (fun msg f_MDFullGrp_ExpireTime -> opt msg "432" parse_LocalMktDate (fun msg f_MDFullGrp_ExpireDate -> opt msg "59" parse_TimeInForce (fun msg f_MDFullGrp_TimeInForce -> opt msg "286" parse_OpenCloseSettlFlag (fun msg f_MDFullGrp_OpenCloseSettlFlag -> opt msg "284" parse_string (fun msg f_MDFullGrp_DeskID -> opt msg "283" parse_string (fun msg f_MDFullGrp_LocationID -> opt msg "282" parse_string (fun msg f_MDFullGrp_MDEntryOriginator -> opt msg "277" parse_TradeCondition (fun msg f_MDFullGrp_TradeCondition -> opt msg "276" parse_QuoteCondition (fun msg f_MDFullGrp_QuoteCondition -> opt msg "625" parse_string (fun msg f_MDFullGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_MDFullGrp_TradingSessionID -> opt msg "275" parse_Exchange (fun msg f_MDFullGrp_MDMkt -> opt msg "274" parse_TickDirection (fun msg f_MDFullGrp_TickDirection -> opt msg "273" parse_UTCTimeOnly_milli (fun msg f_MDFullGrp_MDEntryTime -> opt msg "272" parse_UTCDateOnly (fun msg f_MDFullGrp_MDEntryDate -> opt msg "271" parse_float (fun msg f_MDFullGrp_MDEntrySize -> opt msg "15" parse_Currency (fun msg f_MDFullGrp_Currency -> opt msg "270" parse_float (fun msg f_MDFullGrp_MDEntryPx -> opt msg "269" parse_MDEntryType (fun msg f_MDFullGrp_MDEntryType -> (ParseSuccess { - f_MDFullGrp_NoMDEntries = f_MDFullGrp_NoMDEntries; - f_MDFullGrp_MDEntryType = f_MDFullGrp_MDEntryType; - f_MDFullGrp_MDEntryPx = f_MDFullGrp_MDEntryPx; - f_MDFullGrp_Currency = f_MDFullGrp_Currency; - f_MDFullGrp_MDEntrySize = f_MDFullGrp_MDEntrySize; - f_MDFullGrp_MDEntryDate = f_MDFullGrp_MDEntryDate; - f_MDFullGrp_MDEntryTime = f_MDFullGrp_MDEntryTime; - f_MDFullGrp_TickDirection = f_MDFullGrp_TickDirection; - f_MDFullGrp_MDMkt = f_MDFullGrp_MDMkt; - f_MDFullGrp_TradingSessionID = f_MDFullGrp_TradingSessionID; - f_MDFullGrp_TradingSessionSubID = f_MDFullGrp_TradingSessionSubID; - f_MDFullGrp_QuoteCondition = f_MDFullGrp_QuoteCondition; - f_MDFullGrp_TradeCondition = f_MDFullGrp_TradeCondition; - f_MDFullGrp_MDEntryOriginator = f_MDFullGrp_MDEntryOriginator; - f_MDFullGrp_LocationID = f_MDFullGrp_LocationID; - f_MDFullGrp_DeskID = f_MDFullGrp_DeskID; - f_MDFullGrp_OpenCloseSettlFlag = f_MDFullGrp_OpenCloseSettlFlag; - f_MDFullGrp_TimeInForce = f_MDFullGrp_TimeInForce; - f_MDFullGrp_ExpireDate = f_MDFullGrp_ExpireDate; - f_MDFullGrp_ExpireTime = f_MDFullGrp_ExpireTime; - f_MDFullGrp_MinQty = f_MDFullGrp_MinQty; - f_MDFullGrp_ExecInst = f_MDFullGrp_ExecInst; - f_MDFullGrp_SellerDays = f_MDFullGrp_SellerDays; - f_MDFullGrp_OrderID = f_MDFullGrp_OrderID; - f_MDFullGrp_QuoteEntryID = f_MDFullGrp_QuoteEntryID; - f_MDFullGrp_MDEntryBuyer = f_MDFullGrp_MDEntryBuyer; - f_MDFullGrp_MDEntrySeller = f_MDFullGrp_MDEntrySeller; - f_MDFullGrp_NumberOfOrders = f_MDFullGrp_NumberOfOrders; - f_MDFullGrp_MDEntryPositionNo = f_MDFullGrp_MDEntryPositionNo; - f_MDFullGrp_Scope = f_MDFullGrp_Scope; - f_MDFullGrp_PriceDelta = f_MDFullGrp_PriceDelta; - f_MDFullGrp_Text = f_MDFullGrp_Text; - f_MDFullGrp_EncodedTextLen = f_MDFullGrp_EncodedTextLen; - f_MDFullGrp_EncodedText = f_MDFullGrp_EncodedText - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_CompIDStatGrp (msg) (f_CompIDStatGrp_NoCompIDs) = - opt msg "929" parse_string (fun msg f_CompIDStatGrp_StatusText -> opt msg "928" parse_StatusValue (fun msg f_CompIDStatGrp_StatusValue -> opt msg "284" parse_string (fun msg f_CompIDStatGrp_DeskID -> opt msg "283" parse_string (fun msg f_CompIDStatGrp_LocationID -> opt msg "931" parse_string (fun msg f_CompIDStatGrp_RefSubID -> opt msg "930" parse_string (fun msg f_CompIDStatGrp_RefCompID -> (ParseSuccess { - f_CompIDStatGrp_NoCompIDs = f_CompIDStatGrp_NoCompIDs; - f_CompIDStatGrp_RefCompID = f_CompIDStatGrp_RefCompID; - f_CompIDStatGrp_RefSubID = f_CompIDStatGrp_RefSubID; - f_CompIDStatGrp_LocationID = f_CompIDStatGrp_LocationID; - f_CompIDStatGrp_DeskID = f_CompIDStatGrp_DeskID; - f_CompIDStatGrp_StatusValue = f_CompIDStatGrp_StatusValue; - f_CompIDStatGrp_StatusText = f_CompIDStatGrp_StatusText - },msg) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_DiscretionInstructions (msg) = - opt msg "846" parse_DiscretionScope (fun msg f_DiscretionInstructions_DiscretionScope -> opt msg "844" parse_DiscretionRoundDirection (fun msg f_DiscretionInstructions_DiscretionRoundDirection -> opt msg "843" parse_DiscretionLimitType (fun msg f_DiscretionInstructions_DiscretionLimitType -> opt msg "842" parse_DiscretionOffsetType (fun msg f_DiscretionInstructions_DiscretionOffsetType -> opt msg "841" parse_DiscretionMoveType (fun msg f_DiscretionInstructions_DiscretionMoveType -> opt msg "389" parse_float (fun msg f_DiscretionInstructions_DiscretionOffsetValue -> opt msg "388" parse_DiscretionInst (fun msg f_DiscretionInstructions_DiscretionInst -> (ParseSuccess { - f_DiscretionInstructions_DiscretionInst = f_DiscretionInstructions_DiscretionInst; - f_DiscretionInstructions_DiscretionOffsetValue = f_DiscretionInstructions_DiscretionOffsetValue; - f_DiscretionInstructions_DiscretionMoveType = f_DiscretionInstructions_DiscretionMoveType; - f_DiscretionInstructions_DiscretionOffsetType = f_DiscretionInstructions_DiscretionOffsetType; - f_DiscretionInstructions_DiscretionLimitType = f_DiscretionInstructions_DiscretionLimitType; - f_DiscretionInstructions_DiscretionRoundDirection = f_DiscretionInstructions_DiscretionRoundDirection; - f_DiscretionInstructions_DiscretionScope = f_DiscretionInstructions_DiscretionScope - },msg) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_CompIDReqGrp (msg) (f_CompIDReqGrp_NoCompIDs) = - opt msg "284" parse_string (fun msg f_CompIDReqGrp_DeskID -> opt msg "283" parse_string (fun msg f_CompIDReqGrp_LocationID -> opt msg "931" parse_string (fun msg f_CompIDReqGrp_RefSubID -> opt msg "930" parse_string (fun msg f_CompIDReqGrp_RefCompID -> (ParseSuccess { - f_CompIDReqGrp_NoCompIDs = f_CompIDReqGrp_NoCompIDs; - f_CompIDReqGrp_RefCompID = f_CompIDReqGrp_RefCompID; - f_CompIDReqGrp_RefSubID = f_CompIDReqGrp_RefSubID; - f_CompIDReqGrp_LocationID = f_CompIDReqGrp_LocationID; - f_CompIDReqGrp_DeskID = f_CompIDReqGrp_DeskID - },msg) - ) - ) - ) - ) - [@@macro] -;; - -let parse_LegStipulations (msg) (f_LegStipulations_NoLegStipulations) = - opt msg "689" parse_string (fun msg f_LegStipulations_LegStipulationValue -> opt msg "688" parse_string (fun msg f_LegStipulations_LegStipulationType -> (ParseSuccess { - f_LegStipulations_NoLegStipulations = f_LegStipulations_NoLegStipulations; - f_LegStipulations_LegStipulationType = f_LegStipulations_LegStipulationType; - f_LegStipulations_LegStipulationValue = f_LegStipulations_LegStipulationValue - },msg) - ) - ) - [@@macro] -;; - -let parse_NstdPtysSubGrp (msg) (f_NstdPtysSubGrp_NoNestedPartySubIDs) = - opt msg "805" parse_int (fun msg f_NstdPtysSubGrp_NestedPartySubIDType -> opt msg "545" parse_string (fun msg f_NstdPtysSubGrp_NestedPartySubID -> (ParseSuccess { - f_NstdPtysSubGrp_NoNestedPartySubIDs = f_NstdPtysSubGrp_NoNestedPartySubIDs; - f_NstdPtysSubGrp_NestedPartySubID = f_NstdPtysSubGrp_NestedPartySubID; - f_NstdPtysSubGrp_NestedPartySubIDType = f_NstdPtysSubGrp_NestedPartySubIDType - },msg) - ) - ) - [@@macro] -;; - -let parse_SecAltIDGrp (msg) (f_SecAltIDGrp_NoSecurityAltID) = - opt msg "456" parse_string (fun msg f_SecAltIDGrp_SecurityAltIDSource -> opt msg "455" parse_string (fun msg f_SecAltIDGrp_SecurityAltID -> (ParseSuccess { - f_SecAltIDGrp_NoSecurityAltID = f_SecAltIDGrp_NoSecurityAltID; - f_SecAltIDGrp_SecurityAltID = f_SecAltIDGrp_SecurityAltID; - f_SecAltIDGrp_SecurityAltIDSource = f_SecAltIDGrp_SecurityAltIDSource - },msg) - ) - ) - [@@macro] -;; - -let parse_PtysSubGrp (msg) (f_PtysSubGrp_NoPartySubIDs) = - opt msg "803" parse_PartySubIDType (fun msg f_PtysSubGrp_PartySubIDType -> opt msg "523" parse_string (fun msg f_PtysSubGrp_PartySubID -> (ParseSuccess { - f_PtysSubGrp_NoPartySubIDs = f_PtysSubGrp_NoPartySubIDs; - f_PtysSubGrp_PartySubID = f_PtysSubGrp_PartySubID; - f_PtysSubGrp_PartySubIDType = f_PtysSubGrp_PartySubIDType - },msg) - ) - ) - [@@macro] -;; - -let parse_OrderQtyData (msg) = - opt msg "469" parse_float (fun msg f_OrderQtyData_RoundingModulus -> opt msg "468" parse_RoundingDirection (fun msg f_OrderQtyData_RoundingDirection -> opt msg "516" parse_float (fun msg f_OrderQtyData_OrderPercent -> opt msg "152" parse_float (fun msg f_OrderQtyData_CashOrderQty -> opt msg "38" parse_float (fun msg f_OrderQtyData_OrderQty -> (ParseSuccess { - f_OrderQtyData_OrderQty = f_OrderQtyData_OrderQty; - f_OrderQtyData_CashOrderQty = f_OrderQtyData_CashOrderQty; - f_OrderQtyData_OrderPercent = f_OrderQtyData_OrderPercent; - f_OrderQtyData_RoundingDirection = f_OrderQtyData_RoundingDirection; - f_OrderQtyData_RoundingModulus = f_OrderQtyData_RoundingModulus - },msg) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_IOIQualGrp (msg) (f_IOIQualGrp_NoIOIQualifiers) = - opt msg "104" parse_IOIQualifier (fun msg f_IOIQualGrp_IOIQualifier -> (ParseSuccess { - f_IOIQualGrp_NoIOIQualifiers = f_IOIQualGrp_NoIOIQualifiers; - f_IOIQualGrp_IOIQualifier = f_IOIQualGrp_IOIQualifier - },msg) - ) - [@@macro] -;; - -let parse_CpctyConfGrp (msg) (f_CpctyConfGrp_NoCapacities) = - opt msg "863" parse_float (fun msg f_CpctyConfGrp_OrderCapacityQty -> opt msg "529" parse_OrderRestrictions (fun msg f_CpctyConfGrp_OrderRestrictions -> opt msg "528" parse_OrderCapacity (fun msg f_CpctyConfGrp_OrderCapacity -> (ParseSuccess { - f_CpctyConfGrp_NoCapacities = f_CpctyConfGrp_NoCapacities; - f_CpctyConfGrp_OrderCapacity = f_CpctyConfGrp_OrderCapacity; - f_CpctyConfGrp_OrderRestrictions = f_CpctyConfGrp_OrderRestrictions; - f_CpctyConfGrp_OrderCapacityQty = f_CpctyConfGrp_OrderCapacityQty - },msg) - ) - ) - ) - [@@macro] -;; - -let parse_LegBenchmarkCurveData (msg) = - opt msg "680" parse_int (fun msg f_LegBenchmarkCurveData_LegBenchmarkPriceType -> opt msg "679" parse_float (fun msg f_LegBenchmarkCurveData_LegBenchmarkPrice -> opt msg "678" parse_string (fun msg f_LegBenchmarkCurveData_LegBenchmarkCurvePoint -> opt msg "677" parse_string (fun msg f_LegBenchmarkCurveData_LegBenchmarkCurveName -> opt msg "676" parse_Currency (fun msg f_LegBenchmarkCurveData_LegBenchmarkCurveCurrency -> (ParseSuccess { - f_LegBenchmarkCurveData_LegBenchmarkCurveCurrency = f_LegBenchmarkCurveData_LegBenchmarkCurveCurrency; - f_LegBenchmarkCurveData_LegBenchmarkCurveName = f_LegBenchmarkCurveData_LegBenchmarkCurveName; - f_LegBenchmarkCurveData_LegBenchmarkCurvePoint = f_LegBenchmarkCurveData_LegBenchmarkCurvePoint; - f_LegBenchmarkCurveData_LegBenchmarkPrice = f_LegBenchmarkCurveData_LegBenchmarkPrice; - f_LegBenchmarkCurveData_LegBenchmarkPriceType = f_LegBenchmarkCurveData_LegBenchmarkPriceType - },msg) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_RoutingGrp (msg) (f_RoutingGrp_NoRoutingIDs) = - opt msg "217" parse_string (fun msg f_RoutingGrp_RoutingID -> opt msg "216" parse_RoutingType (fun msg f_RoutingGrp_RoutingType -> (ParseSuccess { - f_RoutingGrp_NoRoutingIDs = f_RoutingGrp_NoRoutingIDs; - f_RoutingGrp_RoutingType = f_RoutingGrp_RoutingType; - f_RoutingGrp_RoutingID = f_RoutingGrp_RoutingID - },msg) - ) - ) - [@@macro] -;; - -let parse_BidDescReqGrp (msg) (f_BidDescReqGrp_NoBidDescriptors) = - opt msg "408" parse_float (fun msg f_BidDescReqGrp_ValueOfFutures -> opt msg "407" parse_float (fun msg f_BidDescReqGrp_OutsideIndexPct -> opt msg "406" parse_float (fun msg f_BidDescReqGrp_FairValue -> opt msg "405" parse_float (fun msg f_BidDescReqGrp_EFPTrackingError -> opt msg "403" parse_float (fun msg f_BidDescReqGrp_LiquidityPctHigh -> opt msg "402" parse_float (fun msg f_BidDescReqGrp_LiquidityPctLow -> opt msg "441" parse_int (fun msg f_BidDescReqGrp_LiquidityNumSecurities -> opt msg "404" parse_float (fun msg f_BidDescReqGrp_LiquidityValue -> opt msg "401" parse_SideValueInd (fun msg f_BidDescReqGrp_SideValueInd -> opt msg "400" parse_string (fun msg f_BidDescReqGrp_BidDescriptor -> opt msg "399" parse_BidDescriptorType (fun msg f_BidDescReqGrp_BidDescriptorType -> (ParseSuccess { - f_BidDescReqGrp_NoBidDescriptors = f_BidDescReqGrp_NoBidDescriptors; - f_BidDescReqGrp_BidDescriptorType = f_BidDescReqGrp_BidDescriptorType; - f_BidDescReqGrp_BidDescriptor = f_BidDescReqGrp_BidDescriptor; - f_BidDescReqGrp_SideValueInd = f_BidDescReqGrp_SideValueInd; - f_BidDescReqGrp_LiquidityValue = f_BidDescReqGrp_LiquidityValue; - f_BidDescReqGrp_LiquidityNumSecurities = f_BidDescReqGrp_LiquidityNumSecurities; - f_BidDescReqGrp_LiquidityPctLow = f_BidDescReqGrp_LiquidityPctLow; - f_BidDescReqGrp_LiquidityPctHigh = f_BidDescReqGrp_LiquidityPctHigh; - f_BidDescReqGrp_EFPTrackingError = f_BidDescReqGrp_EFPTrackingError; - f_BidDescReqGrp_FairValue = f_BidDescReqGrp_FairValue; - f_BidDescReqGrp_OutsideIndexPct = f_BidDescReqGrp_OutsideIndexPct; - f_BidDescReqGrp_ValueOfFutures = f_BidDescReqGrp_ValueOfFutures - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_ContAmtGrp (msg) (f_ContAmtGrp_NoContAmts) = - opt msg "521" parse_Currency (fun msg f_ContAmtGrp_ContAmtCurr -> opt msg "520" parse_float (fun msg f_ContAmtGrp_ContAmtValue -> opt msg "519" parse_ContAmtType (fun msg f_ContAmtGrp_ContAmtType -> (ParseSuccess { - f_ContAmtGrp_NoContAmts = f_ContAmtGrp_NoContAmts; - f_ContAmtGrp_ContAmtType = f_ContAmtGrp_ContAmtType; - f_ContAmtGrp_ContAmtValue = f_ContAmtGrp_ContAmtValue; - f_ContAmtGrp_ContAmtCurr = f_ContAmtGrp_ContAmtCurr - },msg) - ) - ) - ) - [@@macro] -;; - -let parse_ExecAllocGrp (msg) (f_ExecAllocGrp_NoExecs) = - opt msg "29" parse_LastCapacity (fun msg f_ExecAllocGrp_LastCapacity -> opt msg "669" parse_float (fun msg f_ExecAllocGrp_LastParPx -> opt msg "31" parse_float (fun msg f_ExecAllocGrp_LastPx -> opt msg "527" parse_string (fun msg f_ExecAllocGrp_SecondaryExecID -> opt msg "17" parse_string (fun msg f_ExecAllocGrp_ExecID -> opt msg "32" parse_float (fun msg f_ExecAllocGrp_LastQty -> (ParseSuccess { - f_ExecAllocGrp_NoExecs = f_ExecAllocGrp_NoExecs; - f_ExecAllocGrp_LastQty = f_ExecAllocGrp_LastQty; - f_ExecAllocGrp_ExecID = f_ExecAllocGrp_ExecID; - f_ExecAllocGrp_SecondaryExecID = f_ExecAllocGrp_SecondaryExecID; - f_ExecAllocGrp_LastPx = f_ExecAllocGrp_LastPx; - f_ExecAllocGrp_LastParPx = f_ExecAllocGrp_LastParPx; - f_ExecAllocGrp_LastCapacity = f_ExecAllocGrp_LastCapacity - },msg) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_QuotQualGrp (msg) (f_QuotQualGrp_NoQuoteQualifiers) = - opt msg "695" parse_char (fun msg f_QuotQualGrp_QuoteQualifier -> (ParseSuccess { - f_QuotQualGrp_NoQuoteQualifiers = f_QuotQualGrp_NoQuoteQualifiers; - f_QuotQualGrp_QuoteQualifier = f_QuotQualGrp_QuoteQualifier - },msg) - ) - [@@macro] -;; - -let parse_AttrbGrp (msg) (f_AttrbGrp_NoInstrAttrib) = - opt msg "872" parse_string (fun msg f_AttrbGrp_InstrAttribValue -> opt msg "871" parse_InstrAttribType (fun msg f_AttrbGrp_InstrAttribType -> (ParseSuccess { - f_AttrbGrp_NoInstrAttrib = f_AttrbGrp_NoInstrAttrib; - f_AttrbGrp_InstrAttribType = f_AttrbGrp_InstrAttribType; - f_AttrbGrp_InstrAttribValue = f_AttrbGrp_InstrAttribValue - },msg) - ) - ) - [@@macro] -;; - -let parse_ClrInstGrp (msg) (f_ClrInstGrp_NoClearingInstructions) = - opt msg "577" parse_ClearingInstruction (fun msg f_ClrInstGrp_ClearingInstruction -> (ParseSuccess { - f_ClrInstGrp_NoClearingInstructions = f_ClrInstGrp_NoClearingInstructions; - f_ClrInstGrp_ClearingInstruction = f_ClrInstGrp_ClearingInstruction - },msg) - ) - [@@macro] -;; - -let parse_PositionAmountData (msg) (f_PositionAmountData_NoPosAmt) = - opt msg "708" parse_float (fun msg f_PositionAmountData_PosAmt -> opt msg "707" parse_PosAmtType (fun msg f_PositionAmountData_PosAmtType -> (ParseSuccess { - f_PositionAmountData_NoPosAmt = f_PositionAmountData_NoPosAmt; - f_PositionAmountData_PosAmtType = f_PositionAmountData_PosAmtType; - f_PositionAmountData_PosAmt = f_PositionAmountData_PosAmt - },msg) - ) - ) - [@@macro] -;; - -let parse_OrdListStatGrp (msg) (f_OrdListStatGrp_NoOrders) = - opt msg "355" parse_string (fun msg f_OrdListStatGrp_EncodedText -> opt msg "354" parse_int (fun msg f_OrdListStatGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_OrdListStatGrp_Text -> opt msg "103" parse_OrdRejReason (fun msg f_OrdListStatGrp_OrdRejReason -> opt msg "6" parse_float (fun msg f_OrdListStatGrp_AvgPx -> opt msg "84" parse_float (fun msg f_OrdListStatGrp_CxlQty -> opt msg "151" parse_float (fun msg f_OrdListStatGrp_LeavesQty -> opt msg "636" parse_WorkingIndicator (fun msg f_OrdListStatGrp_WorkingIndicator -> opt msg "39" parse_OrdStatus (fun msg f_OrdListStatGrp_OrdStatus -> opt msg "14" parse_float (fun msg f_OrdListStatGrp_CumQty -> opt msg "526" parse_string (fun msg f_OrdListStatGrp_SecondaryClOrdID -> opt msg "11" parse_string (fun msg f_OrdListStatGrp_ClOrdID -> (ParseSuccess { - f_OrdListStatGrp_NoOrders = f_OrdListStatGrp_NoOrders; - f_OrdListStatGrp_ClOrdID = f_OrdListStatGrp_ClOrdID; - f_OrdListStatGrp_SecondaryClOrdID = f_OrdListStatGrp_SecondaryClOrdID; - f_OrdListStatGrp_CumQty = f_OrdListStatGrp_CumQty; - f_OrdListStatGrp_OrdStatus = f_OrdListStatGrp_OrdStatus; - f_OrdListStatGrp_WorkingIndicator = f_OrdListStatGrp_WorkingIndicator; - f_OrdListStatGrp_LeavesQty = f_OrdListStatGrp_LeavesQty; - f_OrdListStatGrp_CxlQty = f_OrdListStatGrp_CxlQty; - f_OrdListStatGrp_AvgPx = f_OrdListStatGrp_AvgPx; - f_OrdListStatGrp_OrdRejReason = f_OrdListStatGrp_OrdRejReason; - f_OrdListStatGrp_Text = f_OrdListStatGrp_Text; - f_OrdListStatGrp_EncodedTextLen = f_OrdListStatGrp_EncodedTextLen; - f_OrdListStatGrp_EncodedText = f_OrdListStatGrp_EncodedText - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_SpreadOrBenchmarkCurveData (msg) = - opt msg "761" parse_string (fun msg f_SpreadOrBenchmarkCurveData_BenchmarkSecurityIDSource -> opt msg "699" parse_string (fun msg f_SpreadOrBenchmarkCurveData_BenchmarkSecurityID -> opt msg "663" parse_int (fun msg f_SpreadOrBenchmarkCurveData_BenchmarkPriceType -> opt msg "662" parse_float (fun msg f_SpreadOrBenchmarkCurveData_BenchmarkPrice -> opt msg "222" parse_string (fun msg f_SpreadOrBenchmarkCurveData_BenchmarkCurvePoint -> opt msg "221" parse_string (fun msg f_SpreadOrBenchmarkCurveData_BenchmarkCurveName -> opt msg "220" parse_Currency (fun msg f_SpreadOrBenchmarkCurveData_BenchmarkCurveCurrency -> opt msg "218" parse_float (fun msg f_SpreadOrBenchmarkCurveData_Spread -> (ParseSuccess { - f_SpreadOrBenchmarkCurveData_Spread = f_SpreadOrBenchmarkCurveData_Spread; - f_SpreadOrBenchmarkCurveData_BenchmarkCurveCurrency = f_SpreadOrBenchmarkCurveData_BenchmarkCurveCurrency; - f_SpreadOrBenchmarkCurveData_BenchmarkCurveName = f_SpreadOrBenchmarkCurveData_BenchmarkCurveName; - f_SpreadOrBenchmarkCurveData_BenchmarkCurvePoint = f_SpreadOrBenchmarkCurveData_BenchmarkCurvePoint; - f_SpreadOrBenchmarkCurveData_BenchmarkPrice = f_SpreadOrBenchmarkCurveData_BenchmarkPrice; - f_SpreadOrBenchmarkCurveData_BenchmarkPriceType = f_SpreadOrBenchmarkCurveData_BenchmarkPriceType; - f_SpreadOrBenchmarkCurveData_BenchmarkSecurityID = f_SpreadOrBenchmarkCurveData_BenchmarkSecurityID; - f_SpreadOrBenchmarkCurveData_BenchmarkSecurityIDSource = f_SpreadOrBenchmarkCurveData_BenchmarkSecurityIDSource - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_UnderlyingStipulations (msg) (f_UnderlyingStipulations_NoUnderlyingStips) = - opt msg "889" parse_string (fun msg f_UnderlyingStipulations_UnderlyingStipValue -> opt msg "888" parse_string (fun msg f_UnderlyingStipulations_UnderlyingStipType -> (ParseSuccess { - f_UnderlyingStipulations_NoUnderlyingStips = f_UnderlyingStipulations_NoUnderlyingStips; - f_UnderlyingStipulations_UnderlyingStipType = f_UnderlyingStipulations_UnderlyingStipType; - f_UnderlyingStipulations_UnderlyingStipValue = f_UnderlyingStipulations_UnderlyingStipValue - },msg) - ) - ) - [@@macro] -;; - -let parse_SettlPtysSubGrp (msg) (f_SettlPtysSubGrp_NoSettlPartySubIDs) = - opt msg "786" parse_int (fun msg f_SettlPtysSubGrp_SettlPartySubIDType -> opt msg "785" parse_string (fun msg f_SettlPtysSubGrp_SettlPartySubID -> (ParseSuccess { - f_SettlPtysSubGrp_NoSettlPartySubIDs = f_SettlPtysSubGrp_NoSettlPartySubIDs; - f_SettlPtysSubGrp_SettlPartySubID = f_SettlPtysSubGrp_SettlPartySubID; - f_SettlPtysSubGrp_SettlPartySubIDType = f_SettlPtysSubGrp_SettlPartySubIDType - },msg) - ) - ) - [@@macro] -;; - -let parse_SettlParties (msg) (f_SettlParties_NoSettlPartyIDs) = - opt msg "784" parse_int (fun msg f_SettlParties_SettlPartyRole -> opt msg "783" parse_char (fun msg f_SettlParties_SettlPartyIDSource -> opt msg "782" parse_string (fun msg f_SettlParties_SettlPartyID -> repeating msg "801" parse_SettlPtysSubGrp (fun msg f_SettlParties_SettlPtysSubGrp -> (ParseSuccess { - f_SettlParties_SettlPtysSubGrp = f_SettlParties_SettlPtysSubGrp; - f_SettlParties_NoSettlPartyIDs = f_SettlParties_NoSettlPartyIDs; - f_SettlParties_SettlPartyID = f_SettlParties_SettlPartyID; - f_SettlParties_SettlPartyIDSource = f_SettlParties_SettlPartyIDSource; - f_SettlParties_SettlPartyRole = f_SettlParties_SettlPartyRole - },msg) - ) - ) - ) - ) - [@@macro] -;; - -let parse_InstrumentExtension (msg) = - opt msg "869" parse_float (fun msg f_InstrumentExtension_PctAtRisk -> opt msg "668" parse_DeliveryForm (fun msg f_InstrumentExtension_DeliveryForm -> repeating msg "870" parse_AttrbGrp (fun msg f_InstrumentExtension_AttrbGrp -> (ParseSuccess { - f_InstrumentExtension_AttrbGrp = f_InstrumentExtension_AttrbGrp; - f_InstrumentExtension_DeliveryForm = f_InstrumentExtension_DeliveryForm; - f_InstrumentExtension_PctAtRisk = f_InstrumentExtension_PctAtRisk - },msg) - ) - ) - ) - [@@macro] -;; - -let parse_Parties (msg) (f_Parties_NoPartyIDs) = - opt msg "452" parse_PartyRole (fun msg f_Parties_PartyRole -> opt msg "447" parse_PartyIDSource (fun msg f_Parties_PartyIDSource -> opt msg "448" parse_string (fun msg f_Parties_PartyID -> repeating msg "802" parse_PtysSubGrp (fun msg f_Parties_PtysSubGrp -> (ParseSuccess { - f_Parties_PtysSubGrp = f_Parties_PtysSubGrp; - f_Parties_NoPartyIDs = f_Parties_NoPartyIDs; - f_Parties_PartyID = f_Parties_PartyID; - f_Parties_PartyIDSource = f_Parties_PartyIDSource; - f_Parties_PartyRole = f_Parties_PartyRole - },msg) - ) - ) - ) - ) - [@@macro] -;; - -let parse_NestedParties (msg) (f_NestedParties_NoNestedPartyIDs) = - opt msg "538" parse_int (fun msg f_NestedParties_NestedPartyRole -> opt msg "525" parse_char (fun msg f_NestedParties_NestedPartyIDSource -> opt msg "524" parse_string (fun msg f_NestedParties_NestedPartyID -> repeating msg "804" parse_NstdPtysSubGrp (fun msg f_NestedParties_NstdPtysSubGrp -> (ParseSuccess { - f_NestedParties_NstdPtysSubGrp = f_NestedParties_NstdPtysSubGrp; - f_NestedParties_NoNestedPartyIDs = f_NestedParties_NoNestedPartyIDs; - f_NestedParties_NestedPartyID = f_NestedParties_NestedPartyID; - f_NestedParties_NestedPartyIDSource = f_NestedParties_NestedPartyIDSource; - f_NestedParties_NestedPartyRole = f_NestedParties_NestedPartyRole - },msg) - ) - ) - ) - ) - [@@macro] -;; - -let parse_BidCompRspGrp (msg) (f_BidCompRspGrp_NoBidComponents) = - opt msg "355" parse_string (fun msg f_BidCompRspGrp_EncodedText -> opt msg "354" parse_int (fun msg f_BidCompRspGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_BidCompRspGrp_Text -> opt msg "625" parse_string (fun msg f_BidCompRspGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_BidCompRspGrp_TradingSessionID -> opt msg "64" parse_LocalMktDate (fun msg f_BidCompRspGrp_SettlDate -> opt msg "63" parse_SettlType (fun msg f_BidCompRspGrp_SettlType -> opt msg "430" parse_NetGrossInd (fun msg f_BidCompRspGrp_NetGrossInd -> opt msg "406" parse_float (fun msg f_BidCompRspGrp_FairValue -> opt msg "423" parse_PriceType (fun msg f_BidCompRspGrp_PriceType -> opt msg "44" parse_float (fun msg f_BidCompRspGrp_Price -> opt msg "54" parse_Side (fun msg f_BidCompRspGrp_Side -> opt msg "421" parse_Country (fun msg f_BidCompRspGrp_Country -> opt msg "66" parse_string (fun msg f_BidCompRspGrp_ListID -> block msg parse_CommissionData (fun msg f_BidCompRspGrp_CommissionData -> (ParseSuccess { - f_BidCompRspGrp_CommissionData = f_BidCompRspGrp_CommissionData; - f_BidCompRspGrp_NoBidComponents = f_BidCompRspGrp_NoBidComponents; - f_BidCompRspGrp_ListID = f_BidCompRspGrp_ListID; - f_BidCompRspGrp_Country = f_BidCompRspGrp_Country; - f_BidCompRspGrp_Side = f_BidCompRspGrp_Side; - f_BidCompRspGrp_Price = f_BidCompRspGrp_Price; - f_BidCompRspGrp_PriceType = f_BidCompRspGrp_PriceType; - f_BidCompRspGrp_FairValue = f_BidCompRspGrp_FairValue; - f_BidCompRspGrp_NetGrossInd = f_BidCompRspGrp_NetGrossInd; - f_BidCompRspGrp_SettlType = f_BidCompRspGrp_SettlType; - f_BidCompRspGrp_SettlDate = f_BidCompRspGrp_SettlDate; - f_BidCompRspGrp_TradingSessionID = f_BidCompRspGrp_TradingSessionID; - f_BidCompRspGrp_TradingSessionSubID = f_BidCompRspGrp_TradingSessionSubID; - f_BidCompRspGrp_Text = f_BidCompRspGrp_Text; - f_BidCompRspGrp_EncodedTextLen = f_BidCompRspGrp_EncodedTextLen; - f_BidCompRspGrp_EncodedText = f_BidCompRspGrp_EncodedText - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_Instrument (msg) = - opt msg "874" parse_LocalMktDate (fun msg f_Instrument_InterestAccrualDate -> opt msg "873" parse_LocalMktDate (fun msg f_Instrument_DatedDate -> opt msg "876" parse_string (fun msg f_Instrument_CPRegType -> opt msg "875" parse_CPProgram (fun msg f_Instrument_CPProgram -> opt msg "667" parse_MonthYear (fun msg f_Instrument_ContractSettlMonth -> opt msg "691" parse_string (fun msg f_Instrument_Pool -> opt msg "351" parse_string (fun msg f_Instrument_EncodedSecurityDesc -> opt msg "350" parse_int (fun msg f_Instrument_EncodedSecurityDescLen -> opt msg "107" parse_string (fun msg f_Instrument_SecurityDesc -> opt msg "349" parse_string (fun msg f_Instrument_EncodedIssuer -> opt msg "348" parse_int (fun msg f_Instrument_EncodedIssuerLen -> opt msg "106" parse_string (fun msg f_Instrument_Issuer -> opt msg "207" parse_Exchange (fun msg f_Instrument_SecurityExchange -> opt msg "223" parse_float (fun msg f_Instrument_CouponRate -> opt msg "231" parse_float (fun msg f_Instrument_ContractMultiplier -> opt msg "206" parse_char (fun msg f_Instrument_OptAttribute -> opt msg "947" parse_Currency (fun msg f_Instrument_StrikeCurrency -> opt msg "202" parse_float (fun msg f_Instrument_StrikePrice -> opt msg "240" parse_LocalMktDate (fun msg f_Instrument_RedemptionDate -> opt msg "472" parse_string (fun msg f_Instrument_LocaleOfIssue -> opt msg "471" parse_string (fun msg f_Instrument_StateOrProvinceOfIssue -> opt msg "470" parse_Country (fun msg f_Instrument_CountryOfIssue -> opt msg "543" parse_string (fun msg f_Instrument_InstrRegistry -> opt msg "255" parse_string (fun msg f_Instrument_CreditRating -> opt msg "228" parse_float (fun msg f_Instrument_Factor -> opt msg "227" parse_float (fun msg f_Instrument_RepurchaseRate -> opt msg "226" parse_int (fun msg f_Instrument_RepurchaseTerm -> opt msg "239" parse_string (fun msg f_Instrument_RepoCollateralSecurityType -> opt msg "225" parse_LocalMktDate (fun msg f_Instrument_IssueDate -> opt msg "224" parse_LocalMktDate (fun msg f_Instrument_CouponPaymentDate -> opt msg "541" parse_LocalMktDate (fun msg f_Instrument_MaturityDate -> opt msg "200" parse_MonthYear (fun msg f_Instrument_MaturityMonthYear -> opt msg "762" parse_string (fun msg f_Instrument_SecuritySubType -> opt msg "167" parse_SecurityType (fun msg f_Instrument_SecurityType -> opt msg "461" parse_string (fun msg f_Instrument_CFICode -> opt msg "460" parse_Product (fun msg f_Instrument_Product -> opt msg "22" parse_SecurityIDSource (fun msg f_Instrument_SecurityIDSource -> opt msg "48" parse_string (fun msg f_Instrument_SecurityID -> opt msg "65" parse_string (fun msg f_Instrument_SymbolSfx -> opt msg "55" parse_string (fun msg f_Instrument_Symbol -> repeating msg "864" parse_EvntGrp (fun msg f_Instrument_EvntGrp -> repeating msg "454" parse_SecAltIDGrp (fun msg f_Instrument_SecAltIDGrp -> (ParseSuccess { - f_Instrument_SecAltIDGrp = f_Instrument_SecAltIDGrp; - f_Instrument_EvntGrp = f_Instrument_EvntGrp; - f_Instrument_Symbol = f_Instrument_Symbol; - f_Instrument_SymbolSfx = f_Instrument_SymbolSfx; - f_Instrument_SecurityID = f_Instrument_SecurityID; - f_Instrument_SecurityIDSource = f_Instrument_SecurityIDSource; - f_Instrument_Product = f_Instrument_Product; - f_Instrument_CFICode = f_Instrument_CFICode; - f_Instrument_SecurityType = f_Instrument_SecurityType; - f_Instrument_SecuritySubType = f_Instrument_SecuritySubType; - f_Instrument_MaturityMonthYear = f_Instrument_MaturityMonthYear; - f_Instrument_MaturityDate = f_Instrument_MaturityDate; - f_Instrument_CouponPaymentDate = f_Instrument_CouponPaymentDate; - f_Instrument_IssueDate = f_Instrument_IssueDate; - f_Instrument_RepoCollateralSecurityType = f_Instrument_RepoCollateralSecurityType; - f_Instrument_RepurchaseTerm = f_Instrument_RepurchaseTerm; - f_Instrument_RepurchaseRate = f_Instrument_RepurchaseRate; - f_Instrument_Factor = f_Instrument_Factor; - f_Instrument_CreditRating = f_Instrument_CreditRating; - f_Instrument_InstrRegistry = f_Instrument_InstrRegistry; - f_Instrument_CountryOfIssue = f_Instrument_CountryOfIssue; - f_Instrument_StateOrProvinceOfIssue = f_Instrument_StateOrProvinceOfIssue; - f_Instrument_LocaleOfIssue = f_Instrument_LocaleOfIssue; - f_Instrument_RedemptionDate = f_Instrument_RedemptionDate; - f_Instrument_StrikePrice = f_Instrument_StrikePrice; - f_Instrument_StrikeCurrency = f_Instrument_StrikeCurrency; - f_Instrument_OptAttribute = f_Instrument_OptAttribute; - f_Instrument_ContractMultiplier = f_Instrument_ContractMultiplier; - f_Instrument_CouponRate = f_Instrument_CouponRate; - f_Instrument_SecurityExchange = f_Instrument_SecurityExchange; - f_Instrument_Issuer = f_Instrument_Issuer; - f_Instrument_EncodedIssuerLen = f_Instrument_EncodedIssuerLen; - f_Instrument_EncodedIssuer = f_Instrument_EncodedIssuer; - f_Instrument_SecurityDesc = f_Instrument_SecurityDesc; - f_Instrument_EncodedSecurityDescLen = f_Instrument_EncodedSecurityDescLen; - f_Instrument_EncodedSecurityDesc = f_Instrument_EncodedSecurityDesc; - f_Instrument_Pool = f_Instrument_Pool; - f_Instrument_ContractSettlMonth = f_Instrument_ContractSettlMonth; - f_Instrument_CPProgram = f_Instrument_CPProgram; - f_Instrument_CPRegType = f_Instrument_CPRegType; - f_Instrument_DatedDate = f_Instrument_DatedDate; - f_Instrument_InterestAccrualDate = f_Instrument_InterestAccrualDate - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_NestedParties3 (msg) (f_NestedParties3_NoNested3PartyIDs) = - opt msg "951" parse_int (fun msg f_NestedParties3_Nested3PartyRole -> opt msg "950" parse_char (fun msg f_NestedParties3_Nested3PartyIDSource -> opt msg "949" parse_string (fun msg f_NestedParties3_Nested3PartyID -> repeating msg "952" parse_NstdPtys3SubGrp (fun msg f_NestedParties3_NstdPtys3SubGrp -> (ParseSuccess { - f_NestedParties3_NstdPtys3SubGrp = f_NestedParties3_NstdPtys3SubGrp; - f_NestedParties3_NoNested3PartyIDs = f_NestedParties3_NoNested3PartyIDs; - f_NestedParties3_Nested3PartyID = f_NestedParties3_Nested3PartyID; - f_NestedParties3_Nested3PartyIDSource = f_NestedParties3_Nested3PartyIDSource; - f_NestedParties3_Nested3PartyRole = f_NestedParties3_Nested3PartyRole - },msg) - ) - ) - ) - ) - [@@macro] -;; - -let parse_InstrumentLeg (msg) = - opt msg "956" parse_LocalMktDate (fun msg f_InstrumentLeg_LegInterestAccrualDate -> opt msg "955" parse_MonthYear (fun msg f_InstrumentLeg_LegContractSettlMonth -> opt msg "739" parse_LocalMktDate (fun msg f_InstrumentLeg_LegDatedDate -> opt msg "740" parse_string (fun msg f_InstrumentLeg_LegPool -> opt msg "556" parse_Currency (fun msg f_InstrumentLeg_LegCurrency -> opt msg "624" parse_char (fun msg f_InstrumentLeg_LegSide -> opt msg "623" parse_float (fun msg f_InstrumentLeg_LegRatioQty -> opt msg "622" parse_string (fun msg f_InstrumentLeg_EncodedLegSecurityDesc -> opt msg "621" parse_int (fun msg f_InstrumentLeg_EncodedLegSecurityDescLen -> opt msg "620" parse_string (fun msg f_InstrumentLeg_LegSecurityDesc -> opt msg "619" parse_string (fun msg f_InstrumentLeg_EncodedLegIssuer -> opt msg "618" parse_int (fun msg f_InstrumentLeg_EncodedLegIssuerLen -> opt msg "617" parse_string (fun msg f_InstrumentLeg_LegIssuer -> opt msg "616" parse_Exchange (fun msg f_InstrumentLeg_LegSecurityExchange -> opt msg "615" parse_float (fun msg f_InstrumentLeg_LegCouponRate -> opt msg "614" parse_float (fun msg f_InstrumentLeg_LegContractMultiplier -> opt msg "613" parse_char (fun msg f_InstrumentLeg_LegOptAttribute -> opt msg "942" parse_Currency (fun msg f_InstrumentLeg_LegStrikeCurrency -> opt msg "612" parse_float (fun msg f_InstrumentLeg_LegStrikePrice -> opt msg "254" parse_LocalMktDate (fun msg f_InstrumentLeg_LegRedemptionDate -> opt msg "598" parse_string (fun msg f_InstrumentLeg_LegLocaleOfIssue -> opt msg "597" parse_string (fun msg f_InstrumentLeg_LegStateOrProvinceOfIssue -> opt msg "596" parse_Country (fun msg f_InstrumentLeg_LegCountryOfIssue -> opt msg "599" parse_string (fun msg f_InstrumentLeg_LegInstrRegistry -> opt msg "257" parse_string (fun msg f_InstrumentLeg_LegCreditRating -> opt msg "253" parse_float (fun msg f_InstrumentLeg_LegFactor -> opt msg "252" parse_float (fun msg f_InstrumentLeg_LegRepurchaseRate -> opt msg "251" parse_int (fun msg f_InstrumentLeg_LegRepurchaseTerm -> opt msg "250" parse_string (fun msg f_InstrumentLeg_LegRepoCollateralSecurityType -> opt msg "249" parse_LocalMktDate (fun msg f_InstrumentLeg_LegIssueDate -> opt msg "248" parse_LocalMktDate (fun msg f_InstrumentLeg_LegCouponPaymentDate -> opt msg "611" parse_LocalMktDate (fun msg f_InstrumentLeg_LegMaturityDate -> opt msg "610" parse_MonthYear (fun msg f_InstrumentLeg_LegMaturityMonthYear -> opt msg "764" parse_string (fun msg f_InstrumentLeg_LegSecuritySubType -> opt msg "609" parse_string (fun msg f_InstrumentLeg_LegSecurityType -> opt msg "608" parse_string (fun msg f_InstrumentLeg_LegCFICode -> opt msg "607" parse_int (fun msg f_InstrumentLeg_LegProduct -> opt msg "603" parse_string (fun msg f_InstrumentLeg_LegSecurityIDSource -> opt msg "602" parse_string (fun msg f_InstrumentLeg_LegSecurityID -> opt msg "601" parse_string (fun msg f_InstrumentLeg_LegSymbolSfx -> opt msg "600" parse_string (fun msg f_InstrumentLeg_LegSymbol -> repeating msg "604" parse_LegSecAltIDGrp (fun msg f_InstrumentLeg_LegSecAltIDGrp -> (ParseSuccess { - f_InstrumentLeg_LegSecAltIDGrp = f_InstrumentLeg_LegSecAltIDGrp; - f_InstrumentLeg_LegSymbol = f_InstrumentLeg_LegSymbol; - f_InstrumentLeg_LegSymbolSfx = f_InstrumentLeg_LegSymbolSfx; - f_InstrumentLeg_LegSecurityID = f_InstrumentLeg_LegSecurityID; - f_InstrumentLeg_LegSecurityIDSource = f_InstrumentLeg_LegSecurityIDSource; - f_InstrumentLeg_LegProduct = f_InstrumentLeg_LegProduct; - f_InstrumentLeg_LegCFICode = f_InstrumentLeg_LegCFICode; - f_InstrumentLeg_LegSecurityType = f_InstrumentLeg_LegSecurityType; - f_InstrumentLeg_LegSecuritySubType = f_InstrumentLeg_LegSecuritySubType; - f_InstrumentLeg_LegMaturityMonthYear = f_InstrumentLeg_LegMaturityMonthYear; - f_InstrumentLeg_LegMaturityDate = f_InstrumentLeg_LegMaturityDate; - f_InstrumentLeg_LegCouponPaymentDate = f_InstrumentLeg_LegCouponPaymentDate; - f_InstrumentLeg_LegIssueDate = f_InstrumentLeg_LegIssueDate; - f_InstrumentLeg_LegRepoCollateralSecurityType = f_InstrumentLeg_LegRepoCollateralSecurityType; - f_InstrumentLeg_LegRepurchaseTerm = f_InstrumentLeg_LegRepurchaseTerm; - f_InstrumentLeg_LegRepurchaseRate = f_InstrumentLeg_LegRepurchaseRate; - f_InstrumentLeg_LegFactor = f_InstrumentLeg_LegFactor; - f_InstrumentLeg_LegCreditRating = f_InstrumentLeg_LegCreditRating; - f_InstrumentLeg_LegInstrRegistry = f_InstrumentLeg_LegInstrRegistry; - f_InstrumentLeg_LegCountryOfIssue = f_InstrumentLeg_LegCountryOfIssue; - f_InstrumentLeg_LegStateOrProvinceOfIssue = f_InstrumentLeg_LegStateOrProvinceOfIssue; - f_InstrumentLeg_LegLocaleOfIssue = f_InstrumentLeg_LegLocaleOfIssue; - f_InstrumentLeg_LegRedemptionDate = f_InstrumentLeg_LegRedemptionDate; - f_InstrumentLeg_LegStrikePrice = f_InstrumentLeg_LegStrikePrice; - f_InstrumentLeg_LegStrikeCurrency = f_InstrumentLeg_LegStrikeCurrency; - f_InstrumentLeg_LegOptAttribute = f_InstrumentLeg_LegOptAttribute; - f_InstrumentLeg_LegContractMultiplier = f_InstrumentLeg_LegContractMultiplier; - f_InstrumentLeg_LegCouponRate = f_InstrumentLeg_LegCouponRate; - f_InstrumentLeg_LegSecurityExchange = f_InstrumentLeg_LegSecurityExchange; - f_InstrumentLeg_LegIssuer = f_InstrumentLeg_LegIssuer; - f_InstrumentLeg_EncodedLegIssuerLen = f_InstrumentLeg_EncodedLegIssuerLen; - f_InstrumentLeg_EncodedLegIssuer = f_InstrumentLeg_EncodedLegIssuer; - f_InstrumentLeg_LegSecurityDesc = f_InstrumentLeg_LegSecurityDesc; - f_InstrumentLeg_EncodedLegSecurityDescLen = f_InstrumentLeg_EncodedLegSecurityDescLen; - f_InstrumentLeg_EncodedLegSecurityDesc = f_InstrumentLeg_EncodedLegSecurityDesc; - f_InstrumentLeg_LegRatioQty = f_InstrumentLeg_LegRatioQty; - f_InstrumentLeg_LegSide = f_InstrumentLeg_LegSide; - f_InstrumentLeg_LegCurrency = f_InstrumentLeg_LegCurrency; - f_InstrumentLeg_LegPool = f_InstrumentLeg_LegPool; - f_InstrumentLeg_LegDatedDate = f_InstrumentLeg_LegDatedDate; - f_InstrumentLeg_LegContractSettlMonth = f_InstrumentLeg_LegContractSettlMonth; - f_InstrumentLeg_LegInterestAccrualDate = f_InstrumentLeg_LegInterestAccrualDate - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_NestedParties2 (msg) (f_NestedParties2_NoNested2PartyIDs) = - opt msg "759" parse_int (fun msg f_NestedParties2_Nested2PartyRole -> opt msg "758" parse_char (fun msg f_NestedParties2_Nested2PartyIDSource -> opt msg "757" parse_string (fun msg f_NestedParties2_Nested2PartyID -> repeating msg "806" parse_NstdPtys2SubGrp (fun msg f_NestedParties2_NstdPtys2SubGrp -> (ParseSuccess { - f_NestedParties2_NstdPtys2SubGrp = f_NestedParties2_NstdPtys2SubGrp; - f_NestedParties2_NoNested2PartyIDs = f_NestedParties2_NoNested2PartyIDs; - f_NestedParties2_Nested2PartyID = f_NestedParties2_Nested2PartyID; - f_NestedParties2_Nested2PartyIDSource = f_NestedParties2_Nested2PartyIDSource; - f_NestedParties2_Nested2PartyRole = f_NestedParties2_Nested2PartyRole - },msg) - ) - ) - ) - ) - [@@macro] -;; - -let parse_UnderlyingInstrument (msg) = - opt msg "886" parse_float (fun msg f_UnderlyingInstrument_UnderlyingEndValue -> opt msg "885" parse_float (fun msg f_UnderlyingInstrument_UnderlyingCurrentValue -> opt msg "884" parse_float (fun msg f_UnderlyingInstrument_UnderlyingStartValue -> opt msg "883" parse_float (fun msg f_UnderlyingInstrument_UnderlyingEndPrice -> opt msg "882" parse_float (fun msg f_UnderlyingInstrument_UnderlyingDirtyPrice -> opt msg "810" parse_float (fun msg f_UnderlyingInstrument_UnderlyingPx -> opt msg "879" parse_float (fun msg f_UnderlyingInstrument_UnderlyingQty -> opt msg "318" parse_Currency (fun msg f_UnderlyingInstrument_UnderlyingCurrency -> opt msg "878" parse_string (fun msg f_UnderlyingInstrument_UnderlyingCPRegType -> opt msg "877" parse_string (fun msg f_UnderlyingInstrument_UnderlyingCPProgram -> opt msg "365" parse_string (fun msg f_UnderlyingInstrument_EncodedUnderlyingSecurityDesc -> opt msg "364" parse_int (fun msg f_UnderlyingInstrument_EncodedUnderlyingSecurityDescLen -> opt msg "307" parse_string (fun msg f_UnderlyingInstrument_UnderlyingSecurityDesc -> opt msg "363" parse_string (fun msg f_UnderlyingInstrument_EncodedUnderlyingIssuer -> opt msg "362" parse_int (fun msg f_UnderlyingInstrument_EncodedUnderlyingIssuerLen -> opt msg "306" parse_string (fun msg f_UnderlyingInstrument_UnderlyingIssuer -> opt msg "308" parse_Exchange (fun msg f_UnderlyingInstrument_UnderlyingSecurityExchange -> opt msg "435" parse_float (fun msg f_UnderlyingInstrument_UnderlyingCouponRate -> opt msg "436" parse_float (fun msg f_UnderlyingInstrument_UnderlyingContractMultiplier -> opt msg "317" parse_char (fun msg f_UnderlyingInstrument_UnderlyingOptAttribute -> opt msg "941" parse_Currency (fun msg f_UnderlyingInstrument_UnderlyingStrikeCurrency -> opt msg "316" parse_float (fun msg f_UnderlyingInstrument_UnderlyingStrikePrice -> opt msg "247" parse_LocalMktDate (fun msg f_UnderlyingInstrument_UnderlyingRedemptionDate -> opt msg "594" parse_string (fun msg f_UnderlyingInstrument_UnderlyingLocaleOfIssue -> opt msg "593" parse_string (fun msg f_UnderlyingInstrument_UnderlyingStateOrProvinceOfIssue -> opt msg "592" parse_Country (fun msg f_UnderlyingInstrument_UnderlyingCountryOfIssue -> opt msg "595" parse_string (fun msg f_UnderlyingInstrument_UnderlyingInstrRegistry -> opt msg "256" parse_string (fun msg f_UnderlyingInstrument_UnderlyingCreditRating -> opt msg "246" parse_float (fun msg f_UnderlyingInstrument_UnderlyingFactor -> opt msg "245" parse_float (fun msg f_UnderlyingInstrument_UnderlyingRepurchaseRate -> opt msg "244" parse_int (fun msg f_UnderlyingInstrument_UnderlyingRepurchaseTerm -> opt msg "243" parse_string (fun msg f_UnderlyingInstrument_UnderlyingRepoCollateralSecurityType -> opt msg "242" parse_LocalMktDate (fun msg f_UnderlyingInstrument_UnderlyingIssueDate -> opt msg "241" parse_LocalMktDate (fun msg f_UnderlyingInstrument_UnderlyingCouponPaymentDate -> opt msg "542" parse_LocalMktDate (fun msg f_UnderlyingInstrument_UnderlyingMaturityDate -> opt msg "313" parse_MonthYear (fun msg f_UnderlyingInstrument_UnderlyingMaturityMonthYear -> opt msg "763" parse_string (fun msg f_UnderlyingInstrument_UnderlyingSecuritySubType -> opt msg "310" parse_string (fun msg f_UnderlyingInstrument_UnderlyingSecurityType -> opt msg "463" parse_string (fun msg f_UnderlyingInstrument_UnderlyingCFICode -> opt msg "462" parse_int (fun msg f_UnderlyingInstrument_UnderlyingProduct -> opt msg "305" parse_string (fun msg f_UnderlyingInstrument_UnderlyingSecurityIDSource -> opt msg "309" parse_string (fun msg f_UnderlyingInstrument_UnderlyingSecurityID -> opt msg "312" parse_string (fun msg f_UnderlyingInstrument_UnderlyingSymbolSfx -> opt msg "311" parse_string (fun msg f_UnderlyingInstrument_UnderlyingSymbol -> repeating msg "887" parse_UnderlyingStipulations (fun msg f_UnderlyingInstrument_UnderlyingStipulations -> repeating msg "457" parse_UndSecAltIDGrp (fun msg f_UnderlyingInstrument_UndSecAltIDGrp -> (ParseSuccess { - f_UnderlyingInstrument_UndSecAltIDGrp = f_UnderlyingInstrument_UndSecAltIDGrp; - f_UnderlyingInstrument_UnderlyingStipulations = f_UnderlyingInstrument_UnderlyingStipulations; - f_UnderlyingInstrument_UnderlyingSymbol = f_UnderlyingInstrument_UnderlyingSymbol; - f_UnderlyingInstrument_UnderlyingSymbolSfx = f_UnderlyingInstrument_UnderlyingSymbolSfx; - f_UnderlyingInstrument_UnderlyingSecurityID = f_UnderlyingInstrument_UnderlyingSecurityID; - f_UnderlyingInstrument_UnderlyingSecurityIDSource = f_UnderlyingInstrument_UnderlyingSecurityIDSource; - f_UnderlyingInstrument_UnderlyingProduct = f_UnderlyingInstrument_UnderlyingProduct; - f_UnderlyingInstrument_UnderlyingCFICode = f_UnderlyingInstrument_UnderlyingCFICode; - f_UnderlyingInstrument_UnderlyingSecurityType = f_UnderlyingInstrument_UnderlyingSecurityType; - f_UnderlyingInstrument_UnderlyingSecuritySubType = f_UnderlyingInstrument_UnderlyingSecuritySubType; - f_UnderlyingInstrument_UnderlyingMaturityMonthYear = f_UnderlyingInstrument_UnderlyingMaturityMonthYear; - f_UnderlyingInstrument_UnderlyingMaturityDate = f_UnderlyingInstrument_UnderlyingMaturityDate; - f_UnderlyingInstrument_UnderlyingCouponPaymentDate = f_UnderlyingInstrument_UnderlyingCouponPaymentDate; - f_UnderlyingInstrument_UnderlyingIssueDate = f_UnderlyingInstrument_UnderlyingIssueDate; - f_UnderlyingInstrument_UnderlyingRepoCollateralSecurityType = f_UnderlyingInstrument_UnderlyingRepoCollateralSecurityType; - f_UnderlyingInstrument_UnderlyingRepurchaseTerm = f_UnderlyingInstrument_UnderlyingRepurchaseTerm; - f_UnderlyingInstrument_UnderlyingRepurchaseRate = f_UnderlyingInstrument_UnderlyingRepurchaseRate; - f_UnderlyingInstrument_UnderlyingFactor = f_UnderlyingInstrument_UnderlyingFactor; - f_UnderlyingInstrument_UnderlyingCreditRating = f_UnderlyingInstrument_UnderlyingCreditRating; - f_UnderlyingInstrument_UnderlyingInstrRegistry = f_UnderlyingInstrument_UnderlyingInstrRegistry; - f_UnderlyingInstrument_UnderlyingCountryOfIssue = f_UnderlyingInstrument_UnderlyingCountryOfIssue; - f_UnderlyingInstrument_UnderlyingStateOrProvinceOfIssue = f_UnderlyingInstrument_UnderlyingStateOrProvinceOfIssue; - f_UnderlyingInstrument_UnderlyingLocaleOfIssue = f_UnderlyingInstrument_UnderlyingLocaleOfIssue; - f_UnderlyingInstrument_UnderlyingRedemptionDate = f_UnderlyingInstrument_UnderlyingRedemptionDate; - f_UnderlyingInstrument_UnderlyingStrikePrice = f_UnderlyingInstrument_UnderlyingStrikePrice; - f_UnderlyingInstrument_UnderlyingStrikeCurrency = f_UnderlyingInstrument_UnderlyingStrikeCurrency; - f_UnderlyingInstrument_UnderlyingOptAttribute = f_UnderlyingInstrument_UnderlyingOptAttribute; - f_UnderlyingInstrument_UnderlyingContractMultiplier = f_UnderlyingInstrument_UnderlyingContractMultiplier; - f_UnderlyingInstrument_UnderlyingCouponRate = f_UnderlyingInstrument_UnderlyingCouponRate; - f_UnderlyingInstrument_UnderlyingSecurityExchange = f_UnderlyingInstrument_UnderlyingSecurityExchange; - f_UnderlyingInstrument_UnderlyingIssuer = f_UnderlyingInstrument_UnderlyingIssuer; - f_UnderlyingInstrument_EncodedUnderlyingIssuerLen = f_UnderlyingInstrument_EncodedUnderlyingIssuerLen; - f_UnderlyingInstrument_EncodedUnderlyingIssuer = f_UnderlyingInstrument_EncodedUnderlyingIssuer; - f_UnderlyingInstrument_UnderlyingSecurityDesc = f_UnderlyingInstrument_UnderlyingSecurityDesc; - f_UnderlyingInstrument_EncodedUnderlyingSecurityDescLen = f_UnderlyingInstrument_EncodedUnderlyingSecurityDescLen; - f_UnderlyingInstrument_EncodedUnderlyingSecurityDesc = f_UnderlyingInstrument_EncodedUnderlyingSecurityDesc; - f_UnderlyingInstrument_UnderlyingCPProgram = f_UnderlyingInstrument_UnderlyingCPProgram; - f_UnderlyingInstrument_UnderlyingCPRegType = f_UnderlyingInstrument_UnderlyingCPRegType; - f_UnderlyingInstrument_UnderlyingCurrency = f_UnderlyingInstrument_UnderlyingCurrency; - f_UnderlyingInstrument_UnderlyingQty = f_UnderlyingInstrument_UnderlyingQty; - f_UnderlyingInstrument_UnderlyingPx = f_UnderlyingInstrument_UnderlyingPx; - f_UnderlyingInstrument_UnderlyingDirtyPrice = f_UnderlyingInstrument_UnderlyingDirtyPrice; - f_UnderlyingInstrument_UnderlyingEndPrice = f_UnderlyingInstrument_UnderlyingEndPrice; - f_UnderlyingInstrument_UnderlyingStartValue = f_UnderlyingInstrument_UnderlyingStartValue; - f_UnderlyingInstrument_UnderlyingCurrentValue = f_UnderlyingInstrument_UnderlyingCurrentValue; - f_UnderlyingInstrument_UnderlyingEndValue = f_UnderlyingInstrument_UnderlyingEndValue - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_UndInstrmtGrp (msg) (f_UndInstrmtGrp_NoUnderlyings) = - block msg parse_UnderlyingInstrument (fun msg f_UndInstrmtGrp_UnderlyingInstrument -> (ParseSuccess { - f_UndInstrmtGrp_UnderlyingInstrument = f_UndInstrmtGrp_UnderlyingInstrument; - f_UndInstrmtGrp_NoUnderlyings = f_UndInstrmtGrp_NoUnderlyings - },msg) - ) - [@@macro] -;; - -let parse_UndInstrmtCollGrp (msg) (f_UndInstrmtCollGrp_NoUnderlyings) = - opt msg "944" parse_CollAction (fun msg f_UndInstrmtCollGrp_CollAction -> block msg parse_UnderlyingInstrument (fun msg f_UndInstrmtCollGrp_UnderlyingInstrument -> (ParseSuccess { - f_UndInstrmtCollGrp_UnderlyingInstrument = f_UndInstrmtCollGrp_UnderlyingInstrument; - f_UndInstrmtCollGrp_NoUnderlyings = f_UndInstrmtCollGrp_NoUnderlyings; - f_UndInstrmtCollGrp_CollAction = f_UndInstrmtCollGrp_CollAction - },msg) - ) - ) - [@@macro] -;; - -let parse_PosUndInstrmtGrp (msg) (f_PosUndInstrmtGrp_NoUnderlyings) = - opt msg "733" parse_int (fun msg f_PosUndInstrmtGrp_UnderlyingSettlPriceType -> opt msg "732" parse_float (fun msg f_PosUndInstrmtGrp_UnderlyingSettlPrice -> block msg parse_UnderlyingInstrument (fun msg f_PosUndInstrmtGrp_UnderlyingInstrument -> (ParseSuccess { - f_PosUndInstrmtGrp_UnderlyingInstrument = f_PosUndInstrmtGrp_UnderlyingInstrument; - f_PosUndInstrmtGrp_NoUnderlyings = f_PosUndInstrmtGrp_NoUnderlyings; - f_PosUndInstrmtGrp_UnderlyingSettlPrice = f_PosUndInstrmtGrp_UnderlyingSettlPrice; - f_PosUndInstrmtGrp_UnderlyingSettlPriceType = f_PosUndInstrmtGrp_UnderlyingSettlPriceType - },msg) - ) - ) - ) - [@@macro] -;; - -let parse_UndInstrmtStrkPxGrp (msg) (f_UndInstrmtStrkPxGrp_NoUnderlyings) = - opt msg "355" parse_string (fun msg f_UndInstrmtStrkPxGrp_EncodedText -> opt msg "354" parse_int (fun msg f_UndInstrmtStrkPxGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_UndInstrmtStrkPxGrp_Text -> opt msg "15" parse_Currency (fun msg f_UndInstrmtStrkPxGrp_Currency -> opt msg "44" parse_float (fun msg f_UndInstrmtStrkPxGrp_Price -> opt msg "54" parse_Side (fun msg f_UndInstrmtStrkPxGrp_Side -> opt msg "526" parse_string (fun msg f_UndInstrmtStrkPxGrp_SecondaryClOrdID -> opt msg "11" parse_string (fun msg f_UndInstrmtStrkPxGrp_ClOrdID -> opt msg "140" parse_float (fun msg f_UndInstrmtStrkPxGrp_PrevClosePx -> block msg parse_UnderlyingInstrument (fun msg f_UndInstrmtStrkPxGrp_UnderlyingInstrument -> (ParseSuccess { - f_UndInstrmtStrkPxGrp_UnderlyingInstrument = f_UndInstrmtStrkPxGrp_UnderlyingInstrument; - f_UndInstrmtStrkPxGrp_NoUnderlyings = f_UndInstrmtStrkPxGrp_NoUnderlyings; - f_UndInstrmtStrkPxGrp_PrevClosePx = f_UndInstrmtStrkPxGrp_PrevClosePx; - f_UndInstrmtStrkPxGrp_ClOrdID = f_UndInstrmtStrkPxGrp_ClOrdID; - f_UndInstrmtStrkPxGrp_SecondaryClOrdID = f_UndInstrmtStrkPxGrp_SecondaryClOrdID; - f_UndInstrmtStrkPxGrp_Side = f_UndInstrmtStrkPxGrp_Side; - f_UndInstrmtStrkPxGrp_Price = f_UndInstrmtStrkPxGrp_Price; - f_UndInstrmtStrkPxGrp_Currency = f_UndInstrmtStrkPxGrp_Currency; - f_UndInstrmtStrkPxGrp_Text = f_UndInstrmtStrkPxGrp_Text; - f_UndInstrmtStrkPxGrp_EncodedTextLen = f_UndInstrmtStrkPxGrp_EncodedTextLen; - f_UndInstrmtStrkPxGrp_EncodedText = f_UndInstrmtStrkPxGrp_EncodedText - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_TrdAllocGrp (msg) (f_TrdAllocGrp_NoAllocs) = - opt msg "80" parse_float (fun msg f_TrdAllocGrp_AllocQty -> opt msg "467" parse_string (fun msg f_TrdAllocGrp_IndividualAllocID -> opt msg "736" parse_Currency (fun msg f_TrdAllocGrp_AllocSettlCurrency -> opt msg "661" parse_int (fun msg f_TrdAllocGrp_AllocAcctIDSource -> opt msg "79" parse_string (fun msg f_TrdAllocGrp_AllocAccount -> repeating msg "756" parse_NestedParties2 (fun msg f_TrdAllocGrp_NestedParties2 -> (ParseSuccess { - f_TrdAllocGrp_NestedParties2 = f_TrdAllocGrp_NestedParties2; - f_TrdAllocGrp_NoAllocs = f_TrdAllocGrp_NoAllocs; - f_TrdAllocGrp_AllocAccount = f_TrdAllocGrp_AllocAccount; - f_TrdAllocGrp_AllocAcctIDSource = f_TrdAllocGrp_AllocAcctIDSource; - f_TrdAllocGrp_AllocSettlCurrency = f_TrdAllocGrp_AllocSettlCurrency; - f_TrdAllocGrp_IndividualAllocID = f_TrdAllocGrp_IndividualAllocID; - f_TrdAllocGrp_AllocQty = f_TrdAllocGrp_AllocQty - },msg) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_OrdAllocGrp (msg) (f_OrdAllocGrp_NoOrders) = - opt msg "800" parse_float (fun msg f_OrdAllocGrp_OrderBookingQty -> opt msg "799" parse_float (fun msg f_OrdAllocGrp_OrderAvgPx -> opt msg "38" parse_float (fun msg f_OrdAllocGrp_OrderQty -> opt msg "66" parse_string (fun msg f_OrdAllocGrp_ListID -> opt msg "526" parse_string (fun msg f_OrdAllocGrp_SecondaryClOrdID -> opt msg "198" parse_string (fun msg f_OrdAllocGrp_SecondaryOrderID -> opt msg "37" parse_string (fun msg f_OrdAllocGrp_OrderID -> opt msg "11" parse_string (fun msg f_OrdAllocGrp_ClOrdID -> repeating msg "756" parse_NestedParties2 (fun msg f_OrdAllocGrp_NestedParties2 -> (ParseSuccess { - f_OrdAllocGrp_NestedParties2 = f_OrdAllocGrp_NestedParties2; - f_OrdAllocGrp_NoOrders = f_OrdAllocGrp_NoOrders; - f_OrdAllocGrp_ClOrdID = f_OrdAllocGrp_ClOrdID; - f_OrdAllocGrp_OrderID = f_OrdAllocGrp_OrderID; - f_OrdAllocGrp_SecondaryOrderID = f_OrdAllocGrp_SecondaryOrderID; - f_OrdAllocGrp_SecondaryClOrdID = f_OrdAllocGrp_SecondaryClOrdID; - f_OrdAllocGrp_ListID = f_OrdAllocGrp_ListID; - f_OrdAllocGrp_OrderQty = f_OrdAllocGrp_OrderQty; - f_OrdAllocGrp_OrderAvgPx = f_OrdAllocGrp_OrderAvgPx; - f_OrdAllocGrp_OrderBookingQty = f_OrdAllocGrp_OrderBookingQty - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_LegPreAllocGrp (msg) (f_LegPreAllocGrp_NoLegAllocs) = - opt msg "675" parse_Currency (fun msg f_LegPreAllocGrp_LegSettlCurrency -> opt msg "674" parse_string (fun msg f_LegPreAllocGrp_LegAllocAcctIDSource -> opt msg "673" parse_float (fun msg f_LegPreAllocGrp_LegAllocQty -> opt msg "672" parse_string (fun msg f_LegPreAllocGrp_LegIndividualAllocID -> opt msg "671" parse_string (fun msg f_LegPreAllocGrp_LegAllocAccount -> repeating msg "756" parse_NestedParties2 (fun msg f_LegPreAllocGrp_NestedParties2 -> (ParseSuccess { - f_LegPreAllocGrp_NestedParties2 = f_LegPreAllocGrp_NestedParties2; - f_LegPreAllocGrp_NoLegAllocs = f_LegPreAllocGrp_NoLegAllocs; - f_LegPreAllocGrp_LegAllocAccount = f_LegPreAllocGrp_LegAllocAccount; - f_LegPreAllocGrp_LegIndividualAllocID = f_LegPreAllocGrp_LegIndividualAllocID; - f_LegPreAllocGrp_LegAllocQty = f_LegPreAllocGrp_LegAllocQty; - f_LegPreAllocGrp_LegAllocAcctIDSource = f_LegPreAllocGrp_LegAllocAcctIDSource; - f_LegPreAllocGrp_LegSettlCurrency = f_LegPreAllocGrp_LegSettlCurrency - },msg) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_InstrmtLegGrp (msg) (f_InstrmtLegGrp_NoLegs) = - block msg parse_InstrumentLeg (fun msg f_InstrmtLegGrp_InstrumentLeg -> (ParseSuccess { - f_InstrmtLegGrp_InstrumentLeg = f_InstrmtLegGrp_InstrumentLeg; - f_InstrmtLegGrp_NoLegs = f_InstrmtLegGrp_NoLegs - },msg) - ) - [@@macro] -;; - -let parse_InstrmtLegSecListGrp (msg) (f_InstrmtLegSecListGrp_NoLegs) = - opt msg "587" parse_char (fun msg f_InstrmtLegSecListGrp_LegSettlType -> opt msg "690" parse_LegSwapType (fun msg f_InstrmtLegSecListGrp_LegSwapType -> block msg parse_LegBenchmarkCurveData (fun msg f_InstrmtLegSecListGrp_LegBenchmarkCurveData -> block msg parse_InstrumentLeg (fun msg f_InstrmtLegSecListGrp_InstrumentLeg -> repeating msg "683" parse_LegStipulations (fun msg f_InstrmtLegSecListGrp_LegStipulations -> (ParseSuccess { - f_InstrmtLegSecListGrp_LegStipulations = f_InstrmtLegSecListGrp_LegStipulations; - f_InstrmtLegSecListGrp_InstrumentLeg = f_InstrmtLegSecListGrp_InstrumentLeg; - f_InstrmtLegSecListGrp_LegBenchmarkCurveData = f_InstrmtLegSecListGrp_LegBenchmarkCurveData; - f_InstrmtLegSecListGrp_NoLegs = f_InstrmtLegSecListGrp_NoLegs; - f_InstrmtLegSecListGrp_LegSwapType = f_InstrmtLegSecListGrp_LegSwapType; - f_InstrmtLegSecListGrp_LegSettlType = f_InstrmtLegSecListGrp_LegSettlType - },msg) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_InstrmtLegIOIGrp (msg) (f_InstrmtLegIOIGrp_NoLegs) = - opt msg "682" parse_string (fun msg f_InstrmtLegIOIGrp_LegIOIQty -> block msg parse_InstrumentLeg (fun msg f_InstrmtLegIOIGrp_InstrumentLeg -> repeating msg "683" parse_LegStipulations (fun msg f_InstrmtLegIOIGrp_LegStipulations -> (ParseSuccess { - f_InstrmtLegIOIGrp_LegStipulations = f_InstrmtLegIOIGrp_LegStipulations; - f_InstrmtLegIOIGrp_InstrumentLeg = f_InstrmtLegIOIGrp_InstrumentLeg; - f_InstrmtLegIOIGrp_NoLegs = f_InstrmtLegIOIGrp_NoLegs; - f_InstrmtLegIOIGrp_LegIOIQty = f_InstrmtLegIOIGrp_LegIOIQty - },msg) - ) - ) - ) - [@@macro] -;; - -let parse_PreAllocMlegGrp (msg) (f_PreAllocMlegGrp_NoAllocs) = - opt msg "80" parse_float (fun msg f_PreAllocMlegGrp_AllocQty -> opt msg "467" parse_string (fun msg f_PreAllocMlegGrp_IndividualAllocID -> opt msg "736" parse_Currency (fun msg f_PreAllocMlegGrp_AllocSettlCurrency -> opt msg "661" parse_int (fun msg f_PreAllocMlegGrp_AllocAcctIDSource -> opt msg "79" parse_string (fun msg f_PreAllocMlegGrp_AllocAccount -> repeating msg "948" parse_NestedParties3 (fun msg f_PreAllocMlegGrp_NestedParties3 -> (ParseSuccess { - f_PreAllocMlegGrp_NestedParties3 = f_PreAllocMlegGrp_NestedParties3; - f_PreAllocMlegGrp_NoAllocs = f_PreAllocMlegGrp_NoAllocs; - f_PreAllocMlegGrp_AllocAccount = f_PreAllocMlegGrp_AllocAccount; - f_PreAllocMlegGrp_AllocAcctIDSource = f_PreAllocMlegGrp_AllocAcctIDSource; - f_PreAllocMlegGrp_AllocSettlCurrency = f_PreAllocMlegGrp_AllocSettlCurrency; - f_PreAllocMlegGrp_IndividualAllocID = f_PreAllocMlegGrp_IndividualAllocID; - f_PreAllocMlegGrp_AllocQty = f_PreAllocMlegGrp_AllocQty - },msg) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_InstrmtStrkPxGrp (msg) (f_InstrmtStrkPxGrp_NoStrikes) = - block msg parse_Instrument (fun msg f_InstrmtStrkPxGrp_Instrument -> (ParseSuccess { - f_InstrmtStrkPxGrp_Instrument = f_InstrmtStrkPxGrp_Instrument; - f_InstrmtStrkPxGrp_NoStrikes = f_InstrmtStrkPxGrp_NoStrikes - },msg) - ) - [@@macro] -;; - -let parse_InstrmtGrp (msg) (f_InstrmtGrp_NoRelatedSym) = - block msg parse_Instrument (fun msg f_InstrmtGrp_Instrument -> (ParseSuccess { - f_InstrmtGrp_Instrument = f_InstrmtGrp_Instrument; - f_InstrmtGrp_NoRelatedSym = f_InstrmtGrp_NoRelatedSym - },msg) - ) - [@@macro] -;; - -let parse_QuotReqLegsGrp (msg) (f_QuotReqLegsGrp_NoLegs) = - opt msg "588" parse_LocalMktDate (fun msg f_QuotReqLegsGrp_LegSettlDate -> opt msg "587" parse_char (fun msg f_QuotReqLegsGrp_LegSettlType -> opt msg "690" parse_LegSwapType (fun msg f_QuotReqLegsGrp_LegSwapType -> opt msg "687" parse_float (fun msg f_QuotReqLegsGrp_LegQty -> block msg parse_LegBenchmarkCurveData (fun msg f_QuotReqLegsGrp_LegBenchmarkCurveData -> block msg parse_InstrumentLeg (fun msg f_QuotReqLegsGrp_InstrumentLeg -> repeating msg "539" parse_NestedParties (fun msg f_QuotReqLegsGrp_NestedParties -> repeating msg "683" parse_LegStipulations (fun msg f_QuotReqLegsGrp_LegStipulations -> (ParseSuccess { - f_QuotReqLegsGrp_LegStipulations = f_QuotReqLegsGrp_LegStipulations; - f_QuotReqLegsGrp_NestedParties = f_QuotReqLegsGrp_NestedParties; - f_QuotReqLegsGrp_InstrumentLeg = f_QuotReqLegsGrp_InstrumentLeg; - f_QuotReqLegsGrp_LegBenchmarkCurveData = f_QuotReqLegsGrp_LegBenchmarkCurveData; - f_QuotReqLegsGrp_NoLegs = f_QuotReqLegsGrp_NoLegs; - f_QuotReqLegsGrp_LegQty = f_QuotReqLegsGrp_LegQty; - f_QuotReqLegsGrp_LegSwapType = f_QuotReqLegsGrp_LegSwapType; - f_QuotReqLegsGrp_LegSettlType = f_QuotReqLegsGrp_LegSettlType; - f_QuotReqLegsGrp_LegSettlDate = f_QuotReqLegsGrp_LegSettlDate - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_RgstDtlsGrp (msg) (f_RgstDtlsGrp_NoRegistDtls) = - opt msg "475" parse_Country (fun msg f_RgstDtlsGrp_InvestorCountryOfResidence -> opt msg "486" parse_LocalMktDate (fun msg f_RgstDtlsGrp_DateOfBirth -> opt msg "522" parse_OwnerType (fun msg f_RgstDtlsGrp_OwnerType -> opt msg "482" parse_string (fun msg f_RgstDtlsGrp_MailingInst -> opt msg "474" parse_string (fun msg f_RgstDtlsGrp_MailingDtls -> opt msg "511" parse_string (fun msg f_RgstDtlsGrp_RegistEmail -> opt msg "509" parse_string (fun msg f_RgstDtlsGrp_RegistDtls -> repeating msg "539" parse_NestedParties (fun msg f_RgstDtlsGrp_NestedParties -> (ParseSuccess { - f_RgstDtlsGrp_NestedParties = f_RgstDtlsGrp_NestedParties; - f_RgstDtlsGrp_NoRegistDtls = f_RgstDtlsGrp_NoRegistDtls; - f_RgstDtlsGrp_RegistDtls = f_RgstDtlsGrp_RegistDtls; - f_RgstDtlsGrp_RegistEmail = f_RgstDtlsGrp_RegistEmail; - f_RgstDtlsGrp_MailingDtls = f_RgstDtlsGrp_MailingDtls; - f_RgstDtlsGrp_MailingInst = f_RgstDtlsGrp_MailingInst; - f_RgstDtlsGrp_OwnerType = f_RgstDtlsGrp_OwnerType; - f_RgstDtlsGrp_DateOfBirth = f_RgstDtlsGrp_DateOfBirth; - f_RgstDtlsGrp_InvestorCountryOfResidence = f_RgstDtlsGrp_InvestorCountryOfResidence - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_LegQuotGrp (msg) (f_LegQuotGrp_NoLegs) = - opt msg "684" parse_float (fun msg f_LegQuotGrp_LegOfferPx -> opt msg "681" parse_float (fun msg f_LegQuotGrp_LegBidPx -> opt msg "686" parse_int (fun msg f_LegQuotGrp_LegPriceType -> opt msg "588" parse_LocalMktDate (fun msg f_LegQuotGrp_LegSettlDate -> opt msg "587" parse_char (fun msg f_LegQuotGrp_LegSettlType -> opt msg "690" parse_LegSwapType (fun msg f_LegQuotGrp_LegSwapType -> opt msg "687" parse_float (fun msg f_LegQuotGrp_LegQty -> block msg parse_LegBenchmarkCurveData (fun msg f_LegQuotGrp_LegBenchmarkCurveData -> block msg parse_InstrumentLeg (fun msg f_LegQuotGrp_InstrumentLeg -> repeating msg "539" parse_NestedParties (fun msg f_LegQuotGrp_NestedParties -> repeating msg "683" parse_LegStipulations (fun msg f_LegQuotGrp_LegStipulations -> (ParseSuccess { - f_LegQuotGrp_LegStipulations = f_LegQuotGrp_LegStipulations; - f_LegQuotGrp_NestedParties = f_LegQuotGrp_NestedParties; - f_LegQuotGrp_InstrumentLeg = f_LegQuotGrp_InstrumentLeg; - f_LegQuotGrp_LegBenchmarkCurveData = f_LegQuotGrp_LegBenchmarkCurveData; - f_LegQuotGrp_NoLegs = f_LegQuotGrp_NoLegs; - f_LegQuotGrp_LegQty = f_LegQuotGrp_LegQty; - f_LegQuotGrp_LegSwapType = f_LegQuotGrp_LegSwapType; - f_LegQuotGrp_LegSettlType = f_LegQuotGrp_LegSettlType; - f_LegQuotGrp_LegSettlDate = f_LegQuotGrp_LegSettlDate; - f_LegQuotGrp_LegPriceType = f_LegQuotGrp_LegPriceType; - f_LegQuotGrp_LegBidPx = f_LegQuotGrp_LegBidPx; - f_LegQuotGrp_LegOfferPx = f_LegQuotGrp_LegOfferPx - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_LegQuotStatGrp (msg) (f_LegQuotStatGrp_NoLegs) = - opt msg "588" parse_LocalMktDate (fun msg f_LegQuotStatGrp_LegSettlDate -> opt msg "587" parse_char (fun msg f_LegQuotStatGrp_LegSettlType -> opt msg "690" parse_LegSwapType (fun msg f_LegQuotStatGrp_LegSwapType -> opt msg "687" parse_float (fun msg f_LegQuotStatGrp_LegQty -> block msg parse_InstrumentLeg (fun msg f_LegQuotStatGrp_InstrumentLeg -> repeating msg "539" parse_NestedParties (fun msg f_LegQuotStatGrp_NestedParties -> repeating msg "683" parse_LegStipulations (fun msg f_LegQuotStatGrp_LegStipulations -> (ParseSuccess { - f_LegQuotStatGrp_LegStipulations = f_LegQuotStatGrp_LegStipulations; - f_LegQuotStatGrp_NestedParties = f_LegQuotStatGrp_NestedParties; - f_LegQuotStatGrp_InstrumentLeg = f_LegQuotStatGrp_InstrumentLeg; - f_LegQuotStatGrp_NoLegs = f_LegQuotStatGrp_NoLegs; - f_LegQuotStatGrp_LegQty = f_LegQuotStatGrp_LegQty; - f_LegQuotStatGrp_LegSwapType = f_LegQuotStatGrp_LegSwapType; - f_LegQuotStatGrp_LegSettlType = f_LegQuotStatGrp_LegSettlType; - f_LegQuotStatGrp_LegSettlDate = f_LegQuotStatGrp_LegSettlDate - },msg) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_InstrmtLegExecGrp (msg) (f_InstrmtLegExecGrp_NoLegs) = - opt msg "637" parse_float (fun msg f_InstrmtLegExecGrp_LegLastPx -> opt msg "588" parse_LocalMktDate (fun msg f_InstrmtLegExecGrp_LegSettlDate -> opt msg "587" parse_char (fun msg f_InstrmtLegExecGrp_LegSettlType -> opt msg "566" parse_float (fun msg f_InstrmtLegExecGrp_LegPrice -> opt msg "654" parse_string (fun msg f_InstrmtLegExecGrp_LegRefID -> opt msg "565" parse_int (fun msg f_InstrmtLegExecGrp_LegCoveredOrUncovered -> opt msg "564" parse_char (fun msg f_InstrmtLegExecGrp_LegPositionEffect -> opt msg "690" parse_LegSwapType (fun msg f_InstrmtLegExecGrp_LegSwapType -> opt msg "687" parse_float (fun msg f_InstrmtLegExecGrp_LegQty -> block msg parse_InstrumentLeg (fun msg f_InstrmtLegExecGrp_InstrumentLeg -> repeating msg "539" parse_NestedParties (fun msg f_InstrmtLegExecGrp_NestedParties -> repeating msg "683" parse_LegStipulations (fun msg f_InstrmtLegExecGrp_LegStipulations -> (ParseSuccess { - f_InstrmtLegExecGrp_LegStipulations = f_InstrmtLegExecGrp_LegStipulations; - f_InstrmtLegExecGrp_NestedParties = f_InstrmtLegExecGrp_NestedParties; - f_InstrmtLegExecGrp_InstrumentLeg = f_InstrmtLegExecGrp_InstrumentLeg; - f_InstrmtLegExecGrp_NoLegs = f_InstrmtLegExecGrp_NoLegs; - f_InstrmtLegExecGrp_LegQty = f_InstrmtLegExecGrp_LegQty; - f_InstrmtLegExecGrp_LegSwapType = f_InstrmtLegExecGrp_LegSwapType; - f_InstrmtLegExecGrp_LegPositionEffect = f_InstrmtLegExecGrp_LegPositionEffect; - f_InstrmtLegExecGrp_LegCoveredOrUncovered = f_InstrmtLegExecGrp_LegCoveredOrUncovered; - f_InstrmtLegExecGrp_LegRefID = f_InstrmtLegExecGrp_LegRefID; - f_InstrmtLegExecGrp_LegPrice = f_InstrmtLegExecGrp_LegPrice; - f_InstrmtLegExecGrp_LegSettlType = f_InstrmtLegExecGrp_LegSettlType; - f_InstrmtLegExecGrp_LegSettlDate = f_InstrmtLegExecGrp_LegSettlDate; - f_InstrmtLegExecGrp_LegLastPx = f_InstrmtLegExecGrp_LegLastPx - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_PositionQty (msg) (f_PositionQty_NoPositions) = - opt msg "706" parse_PosQtyStatus (fun msg f_PositionQty_PosQtyStatus -> opt msg "705" parse_float (fun msg f_PositionQty_ShortQty -> opt msg "704" parse_float (fun msg f_PositionQty_LongQty -> opt msg "703" parse_PosType (fun msg f_PositionQty_PosType -> repeating msg "539" parse_NestedParties (fun msg f_PositionQty_NestedParties -> (ParseSuccess { - f_PositionQty_NestedParties = f_PositionQty_NestedParties; - f_PositionQty_NoPositions = f_PositionQty_NoPositions; - f_PositionQty_PosType = f_PositionQty_PosType; - f_PositionQty_LongQty = f_PositionQty_LongQty; - f_PositionQty_ShortQty = f_PositionQty_ShortQty; - f_PositionQty_PosQtyStatus = f_PositionQty_PosQtyStatus - },msg) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_TrdInstrmtLegGrp (msg) (f_TrdInstrmtLegGrp_NoLegs) = - opt msg "637" parse_float (fun msg f_TrdInstrmtLegGrp_LegLastPx -> opt msg "588" parse_LocalMktDate (fun msg f_TrdInstrmtLegGrp_LegSettlDate -> opt msg "587" parse_char (fun msg f_TrdInstrmtLegGrp_LegSettlType -> opt msg "566" parse_float (fun msg f_TrdInstrmtLegGrp_LegPrice -> opt msg "654" parse_string (fun msg f_TrdInstrmtLegGrp_LegRefID -> opt msg "565" parse_int (fun msg f_TrdInstrmtLegGrp_LegCoveredOrUncovered -> opt msg "564" parse_char (fun msg f_TrdInstrmtLegGrp_LegPositionEffect -> opt msg "690" parse_LegSwapType (fun msg f_TrdInstrmtLegGrp_LegSwapType -> opt msg "687" parse_float (fun msg f_TrdInstrmtLegGrp_LegQty -> block msg parse_InstrumentLeg (fun msg f_TrdInstrmtLegGrp_InstrumentLeg -> repeating msg "539" parse_NestedParties (fun msg f_TrdInstrmtLegGrp_NestedParties -> repeating msg "683" parse_LegStipulations (fun msg f_TrdInstrmtLegGrp_LegStipulations -> (ParseSuccess { - f_TrdInstrmtLegGrp_LegStipulations = f_TrdInstrmtLegGrp_LegStipulations; - f_TrdInstrmtLegGrp_NestedParties = f_TrdInstrmtLegGrp_NestedParties; - f_TrdInstrmtLegGrp_InstrumentLeg = f_TrdInstrmtLegGrp_InstrumentLeg; - f_TrdInstrmtLegGrp_NoLegs = f_TrdInstrmtLegGrp_NoLegs; - f_TrdInstrmtLegGrp_LegQty = f_TrdInstrmtLegGrp_LegQty; - f_TrdInstrmtLegGrp_LegSwapType = f_TrdInstrmtLegGrp_LegSwapType; - f_TrdInstrmtLegGrp_LegPositionEffect = f_TrdInstrmtLegGrp_LegPositionEffect; - f_TrdInstrmtLegGrp_LegCoveredOrUncovered = f_TrdInstrmtLegGrp_LegCoveredOrUncovered; - f_TrdInstrmtLegGrp_LegRefID = f_TrdInstrmtLegGrp_LegRefID; - f_TrdInstrmtLegGrp_LegPrice = f_TrdInstrmtLegGrp_LegPrice; - f_TrdInstrmtLegGrp_LegSettlType = f_TrdInstrmtLegGrp_LegSettlType; - f_TrdInstrmtLegGrp_LegSettlDate = f_TrdInstrmtLegGrp_LegSettlDate; - f_TrdInstrmtLegGrp_LegLastPx = f_TrdInstrmtLegGrp_LegLastPx - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_PreAllocGrp (msg) (f_PreAllocGrp_NoAllocs) = - opt msg "80" parse_float (fun msg f_PreAllocGrp_AllocQty -> opt msg "467" parse_string (fun msg f_PreAllocGrp_IndividualAllocID -> opt msg "736" parse_Currency (fun msg f_PreAllocGrp_AllocSettlCurrency -> opt msg "661" parse_int (fun msg f_PreAllocGrp_AllocAcctIDSource -> opt msg "79" parse_string (fun msg f_PreAllocGrp_AllocAccount -> repeating msg "539" parse_NestedParties (fun msg f_PreAllocGrp_NestedParties -> (ParseSuccess { - f_PreAllocGrp_NestedParties = f_PreAllocGrp_NestedParties; - f_PreAllocGrp_NoAllocs = f_PreAllocGrp_NoAllocs; - f_PreAllocGrp_AllocAccount = f_PreAllocGrp_AllocAccount; - f_PreAllocGrp_AllocAcctIDSource = f_PreAllocGrp_AllocAcctIDSource; - f_PreAllocGrp_AllocSettlCurrency = f_PreAllocGrp_AllocSettlCurrency; - f_PreAllocGrp_IndividualAllocID = f_PreAllocGrp_IndividualAllocID; - f_PreAllocGrp_AllocQty = f_PreAllocGrp_AllocQty - },msg) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_SideCrossOrdCxlGrp (msg) (f_SideCrossOrdCxlGrp_NoSides) = - opt msg "355" parse_string (fun msg f_SideCrossOrdCxlGrp_EncodedText -> opt msg "354" parse_int (fun msg f_SideCrossOrdCxlGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_SideCrossOrdCxlGrp_Text -> opt msg "376" parse_string (fun msg f_SideCrossOrdCxlGrp_ComplianceID -> opt msg "75" parse_LocalMktDate (fun msg f_SideCrossOrdCxlGrp_TradeDate -> opt msg "229" parse_LocalMktDate (fun msg f_SideCrossOrdCxlGrp_TradeOriginationDate -> opt msg "586" parse_UTCTimestamp_milli (fun msg f_SideCrossOrdCxlGrp_OrigOrdModTime -> opt msg "583" parse_string (fun msg f_SideCrossOrdCxlGrp_ClOrdLinkID -> opt msg "526" parse_string (fun msg f_SideCrossOrdCxlGrp_SecondaryClOrdID -> opt msg "11" parse_string (fun msg f_SideCrossOrdCxlGrp_ClOrdID -> opt msg "41" parse_string (fun msg f_SideCrossOrdCxlGrp_OrigClOrdID -> opt msg "54" parse_Side (fun msg f_SideCrossOrdCxlGrp_Side -> block msg parse_OrderQtyData (fun msg f_SideCrossOrdCxlGrp_OrderQtyData -> repeating msg "453" parse_Parties (fun msg f_SideCrossOrdCxlGrp_Parties -> (ParseSuccess { - f_SideCrossOrdCxlGrp_Parties = f_SideCrossOrdCxlGrp_Parties; - f_SideCrossOrdCxlGrp_OrderQtyData = f_SideCrossOrdCxlGrp_OrderQtyData; - f_SideCrossOrdCxlGrp_NoSides = f_SideCrossOrdCxlGrp_NoSides; - f_SideCrossOrdCxlGrp_Side = f_SideCrossOrdCxlGrp_Side; - f_SideCrossOrdCxlGrp_OrigClOrdID = f_SideCrossOrdCxlGrp_OrigClOrdID; - f_SideCrossOrdCxlGrp_ClOrdID = f_SideCrossOrdCxlGrp_ClOrdID; - f_SideCrossOrdCxlGrp_SecondaryClOrdID = f_SideCrossOrdCxlGrp_SecondaryClOrdID; - f_SideCrossOrdCxlGrp_ClOrdLinkID = f_SideCrossOrdCxlGrp_ClOrdLinkID; - f_SideCrossOrdCxlGrp_OrigOrdModTime = f_SideCrossOrdCxlGrp_OrigOrdModTime; - f_SideCrossOrdCxlGrp_TradeOriginationDate = f_SideCrossOrdCxlGrp_TradeOriginationDate; - f_SideCrossOrdCxlGrp_TradeDate = f_SideCrossOrdCxlGrp_TradeDate; - f_SideCrossOrdCxlGrp_ComplianceID = f_SideCrossOrdCxlGrp_ComplianceID; - f_SideCrossOrdCxlGrp_Text = f_SideCrossOrdCxlGrp_Text; - f_SideCrossOrdCxlGrp_EncodedTextLen = f_SideCrossOrdCxlGrp_EncodedTextLen; - f_SideCrossOrdCxlGrp_EncodedText = f_SideCrossOrdCxlGrp_EncodedText - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_DlvyInstGrp (msg) (f_DlvyInstGrp_NoDlvyInst) = - opt msg "787" parse_DlvyInstType (fun msg f_DlvyInstGrp_DlvyInstType -> opt msg "165" parse_SettlInstSource (fun msg f_DlvyInstGrp_SettlInstSource -> repeating msg "781" parse_SettlParties (fun msg f_DlvyInstGrp_SettlParties -> (ParseSuccess { - f_DlvyInstGrp_SettlParties = f_DlvyInstGrp_SettlParties; - f_DlvyInstGrp_NoDlvyInst = f_DlvyInstGrp_NoDlvyInst; - f_DlvyInstGrp_SettlInstSource = f_DlvyInstGrp_SettlInstSource; - f_DlvyInstGrp_DlvyInstType = f_DlvyInstGrp_DlvyInstType - },msg) - ) - ) - ) - [@@macro] -;; - -let parse_SettlInstructionsData (msg) = - opt msg "171" parse_string (fun msg f_SettlInstructionsData_StandInstDbID -> opt msg "170" parse_string (fun msg f_SettlInstructionsData_StandInstDbName -> opt msg "169" parse_StandInstDbType (fun msg f_SettlInstructionsData_StandInstDbType -> opt msg "172" parse_SettlDeliveryType (fun msg f_SettlInstructionsData_SettlDeliveryType -> repeating msg "85" parse_DlvyInstGrp (fun msg f_SettlInstructionsData_DlvyInstGrp -> (ParseSuccess { - f_SettlInstructionsData_DlvyInstGrp = f_SettlInstructionsData_DlvyInstGrp; - f_SettlInstructionsData_SettlDeliveryType = f_SettlInstructionsData_SettlDeliveryType; - f_SettlInstructionsData_StandInstDbType = f_SettlInstructionsData_StandInstDbType; - f_SettlInstructionsData_StandInstDbName = f_SettlInstructionsData_StandInstDbName; - f_SettlInstructionsData_StandInstDbID = f_SettlInstructionsData_StandInstDbID - },msg) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_SideCrossOrdModGrp (msg) (f_SideCrossOrdModGrp_NoSides) = - opt msg "659" parse_string (fun msg f_SideCrossOrdModGrp_SideComplianceID -> opt msg "377" parse_SolicitedFlag (fun msg f_SideCrossOrdModGrp_SolicitedFlag -> opt msg "635" parse_ClearingFeeIndicator (fun msg f_SideCrossOrdModGrp_ClearingFeeIndicator -> opt msg "544" parse_CashMargin (fun msg f_SideCrossOrdModGrp_CashMargin -> opt msg "203" parse_CoveredOrUncovered (fun msg f_SideCrossOrdModGrp_CoveredOrUncovered -> opt msg "77" parse_PositionEffect (fun msg f_SideCrossOrdModGrp_PositionEffect -> opt msg "355" parse_string (fun msg f_SideCrossOrdModGrp_EncodedText -> opt msg "354" parse_int (fun msg f_SideCrossOrdModGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_SideCrossOrdModGrp_Text -> opt msg "775" parse_BookingType (fun msg f_SideCrossOrdModGrp_BookingType -> opt msg "120" parse_Currency (fun msg f_SideCrossOrdModGrp_SettlCurrency -> opt msg "121" parse_ForexReq (fun msg f_SideCrossOrdModGrp_ForexReq -> opt msg "582" parse_CustOrderCapacity (fun msg f_SideCrossOrdModGrp_CustOrderCapacity -> opt msg "529" parse_OrderRestrictions (fun msg f_SideCrossOrdModGrp_OrderRestrictions -> opt msg "528" parse_OrderCapacity (fun msg f_SideCrossOrdModGrp_OrderCapacity -> opt msg "854" parse_QtyType (fun msg f_SideCrossOrdModGrp_QtyType -> opt msg "70" parse_string (fun msg f_SideCrossOrdModGrp_AllocID -> opt msg "591" parse_PreallocMethod (fun msg f_SideCrossOrdModGrp_PreallocMethod -> opt msg "590" parse_BookingUnit (fun msg f_SideCrossOrdModGrp_BookingUnit -> opt msg "589" parse_DayBookingInst (fun msg f_SideCrossOrdModGrp_DayBookingInst -> opt msg "581" parse_AccountType (fun msg f_SideCrossOrdModGrp_AccountType -> opt msg "660" parse_AcctIDSource (fun msg f_SideCrossOrdModGrp_AcctIDSource -> opt msg "1" parse_string (fun msg f_SideCrossOrdModGrp_Account -> opt msg "75" parse_LocalMktDate (fun msg f_SideCrossOrdModGrp_TradeDate -> opt msg "229" parse_LocalMktDate (fun msg f_SideCrossOrdModGrp_TradeOriginationDate -> opt msg "583" parse_string (fun msg f_SideCrossOrdModGrp_ClOrdLinkID -> opt msg "526" parse_string (fun msg f_SideCrossOrdModGrp_SecondaryClOrdID -> opt msg "11" parse_string (fun msg f_SideCrossOrdModGrp_ClOrdID -> opt msg "54" parse_Side (fun msg f_SideCrossOrdModGrp_Side -> block msg parse_CommissionData (fun msg f_SideCrossOrdModGrp_CommissionData -> block msg parse_OrderQtyData (fun msg f_SideCrossOrdModGrp_OrderQtyData -> repeating msg "78" parse_PreAllocGrp (fun msg f_SideCrossOrdModGrp_PreAllocGrp -> repeating msg "453" parse_Parties (fun msg f_SideCrossOrdModGrp_Parties -> (ParseSuccess { - f_SideCrossOrdModGrp_Parties = f_SideCrossOrdModGrp_Parties; - f_SideCrossOrdModGrp_PreAllocGrp = f_SideCrossOrdModGrp_PreAllocGrp; - f_SideCrossOrdModGrp_OrderQtyData = f_SideCrossOrdModGrp_OrderQtyData; - f_SideCrossOrdModGrp_CommissionData = f_SideCrossOrdModGrp_CommissionData; - f_SideCrossOrdModGrp_NoSides = f_SideCrossOrdModGrp_NoSides; - f_SideCrossOrdModGrp_Side = f_SideCrossOrdModGrp_Side; - f_SideCrossOrdModGrp_ClOrdID = f_SideCrossOrdModGrp_ClOrdID; - f_SideCrossOrdModGrp_SecondaryClOrdID = f_SideCrossOrdModGrp_SecondaryClOrdID; - f_SideCrossOrdModGrp_ClOrdLinkID = f_SideCrossOrdModGrp_ClOrdLinkID; - f_SideCrossOrdModGrp_TradeOriginationDate = f_SideCrossOrdModGrp_TradeOriginationDate; - f_SideCrossOrdModGrp_TradeDate = f_SideCrossOrdModGrp_TradeDate; - f_SideCrossOrdModGrp_Account = f_SideCrossOrdModGrp_Account; - f_SideCrossOrdModGrp_AcctIDSource = f_SideCrossOrdModGrp_AcctIDSource; - f_SideCrossOrdModGrp_AccountType = f_SideCrossOrdModGrp_AccountType; - f_SideCrossOrdModGrp_DayBookingInst = f_SideCrossOrdModGrp_DayBookingInst; - f_SideCrossOrdModGrp_BookingUnit = f_SideCrossOrdModGrp_BookingUnit; - f_SideCrossOrdModGrp_PreallocMethod = f_SideCrossOrdModGrp_PreallocMethod; - f_SideCrossOrdModGrp_AllocID = f_SideCrossOrdModGrp_AllocID; - f_SideCrossOrdModGrp_QtyType = f_SideCrossOrdModGrp_QtyType; - f_SideCrossOrdModGrp_OrderCapacity = f_SideCrossOrdModGrp_OrderCapacity; - f_SideCrossOrdModGrp_OrderRestrictions = f_SideCrossOrdModGrp_OrderRestrictions; - f_SideCrossOrdModGrp_CustOrderCapacity = f_SideCrossOrdModGrp_CustOrderCapacity; - f_SideCrossOrdModGrp_ForexReq = f_SideCrossOrdModGrp_ForexReq; - f_SideCrossOrdModGrp_SettlCurrency = f_SideCrossOrdModGrp_SettlCurrency; - f_SideCrossOrdModGrp_BookingType = f_SideCrossOrdModGrp_BookingType; - f_SideCrossOrdModGrp_Text = f_SideCrossOrdModGrp_Text; - f_SideCrossOrdModGrp_EncodedTextLen = f_SideCrossOrdModGrp_EncodedTextLen; - f_SideCrossOrdModGrp_EncodedText = f_SideCrossOrdModGrp_EncodedText; - f_SideCrossOrdModGrp_PositionEffect = f_SideCrossOrdModGrp_PositionEffect; - f_SideCrossOrdModGrp_CoveredOrUncovered = f_SideCrossOrdModGrp_CoveredOrUncovered; - f_SideCrossOrdModGrp_CashMargin = f_SideCrossOrdModGrp_CashMargin; - f_SideCrossOrdModGrp_ClearingFeeIndicator = f_SideCrossOrdModGrp_ClearingFeeIndicator; - f_SideCrossOrdModGrp_SolicitedFlag = f_SideCrossOrdModGrp_SolicitedFlag; - f_SideCrossOrdModGrp_SideComplianceID = f_SideCrossOrdModGrp_SideComplianceID - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_QuotEntryGrp (msg) (f_QuotEntryGrp_NoQuoteEntries) = - opt msg "15" parse_Currency (fun msg f_QuotEntryGrp_Currency -> opt msg "643" parse_float (fun msg f_QuotEntryGrp_OfferForwardPoints2 -> opt msg "642" parse_float (fun msg f_QuotEntryGrp_BidForwardPoints2 -> opt msg "192" parse_float (fun msg f_QuotEntryGrp_OrderQty2 -> opt msg "193" parse_LocalMktDate (fun msg f_QuotEntryGrp_SettlDate2 -> opt msg "40" parse_OrdType (fun msg f_QuotEntryGrp_OrdType -> opt msg "64" parse_LocalMktDate (fun msg f_QuotEntryGrp_SettlDate -> opt msg "625" parse_string (fun msg f_QuotEntryGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_QuotEntryGrp_TradingSessionID -> opt msg "60" parse_UTCTimestamp_milli (fun msg f_QuotEntryGrp_TransactTime -> opt msg "634" parse_float (fun msg f_QuotEntryGrp_OfferYield -> opt msg "633" parse_float (fun msg f_QuotEntryGrp_MidYield -> opt msg "632" parse_float (fun msg f_QuotEntryGrp_BidYield -> opt msg "631" parse_float (fun msg f_QuotEntryGrp_MidPx -> opt msg "191" parse_float (fun msg f_QuotEntryGrp_OfferForwardPoints -> opt msg "189" parse_float (fun msg f_QuotEntryGrp_BidForwardPoints -> opt msg "190" parse_float (fun msg f_QuotEntryGrp_OfferSpotRate -> opt msg "188" parse_float (fun msg f_QuotEntryGrp_BidSpotRate -> opt msg "62" parse_UTCTimestamp_milli (fun msg f_QuotEntryGrp_ValidUntilTime -> opt msg "135" parse_float (fun msg f_QuotEntryGrp_OfferSize -> opt msg "134" parse_float (fun msg f_QuotEntryGrp_BidSize -> opt msg "133" parse_float (fun msg f_QuotEntryGrp_OfferPx -> opt msg "132" parse_float (fun msg f_QuotEntryGrp_BidPx -> opt msg "299" parse_string (fun msg f_QuotEntryGrp_QuoteEntryID -> block msg parse_Instrument (fun msg f_QuotEntryGrp_Instrument -> repeating msg "555" parse_InstrmtLegGrp (fun msg f_QuotEntryGrp_InstrmtLegGrp -> (ParseSuccess { - f_QuotEntryGrp_InstrmtLegGrp = f_QuotEntryGrp_InstrmtLegGrp; - f_QuotEntryGrp_Instrument = f_QuotEntryGrp_Instrument; - f_QuotEntryGrp_NoQuoteEntries = f_QuotEntryGrp_NoQuoteEntries; - f_QuotEntryGrp_QuoteEntryID = f_QuotEntryGrp_QuoteEntryID; - f_QuotEntryGrp_BidPx = f_QuotEntryGrp_BidPx; - f_QuotEntryGrp_OfferPx = f_QuotEntryGrp_OfferPx; - f_QuotEntryGrp_BidSize = f_QuotEntryGrp_BidSize; - f_QuotEntryGrp_OfferSize = f_QuotEntryGrp_OfferSize; - f_QuotEntryGrp_ValidUntilTime = f_QuotEntryGrp_ValidUntilTime; - f_QuotEntryGrp_BidSpotRate = f_QuotEntryGrp_BidSpotRate; - f_QuotEntryGrp_OfferSpotRate = f_QuotEntryGrp_OfferSpotRate; - f_QuotEntryGrp_BidForwardPoints = f_QuotEntryGrp_BidForwardPoints; - f_QuotEntryGrp_OfferForwardPoints = f_QuotEntryGrp_OfferForwardPoints; - f_QuotEntryGrp_MidPx = f_QuotEntryGrp_MidPx; - f_QuotEntryGrp_BidYield = f_QuotEntryGrp_BidYield; - f_QuotEntryGrp_MidYield = f_QuotEntryGrp_MidYield; - f_QuotEntryGrp_OfferYield = f_QuotEntryGrp_OfferYield; - f_QuotEntryGrp_TransactTime = f_QuotEntryGrp_TransactTime; - f_QuotEntryGrp_TradingSessionID = f_QuotEntryGrp_TradingSessionID; - f_QuotEntryGrp_TradingSessionSubID = f_QuotEntryGrp_TradingSessionSubID; - f_QuotEntryGrp_SettlDate = f_QuotEntryGrp_SettlDate; - f_QuotEntryGrp_OrdType = f_QuotEntryGrp_OrdType; - f_QuotEntryGrp_SettlDate2 = f_QuotEntryGrp_SettlDate2; - f_QuotEntryGrp_OrderQty2 = f_QuotEntryGrp_OrderQty2; - f_QuotEntryGrp_BidForwardPoints2 = f_QuotEntryGrp_BidForwardPoints2; - f_QuotEntryGrp_OfferForwardPoints2 = f_QuotEntryGrp_OfferForwardPoints2; - f_QuotEntryGrp_Currency = f_QuotEntryGrp_Currency - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_QuotEntryAckGrp (msg) (f_QuotEntryAckGrp_NoQuoteEntries) = - opt msg "368" parse_int (fun msg f_QuotEntryAckGrp_QuoteEntryRejectReason -> opt msg "15" parse_Currency (fun msg f_QuotEntryAckGrp_Currency -> opt msg "643" parse_float (fun msg f_QuotEntryAckGrp_OfferForwardPoints2 -> opt msg "642" parse_float (fun msg f_QuotEntryAckGrp_BidForwardPoints2 -> opt msg "192" parse_float (fun msg f_QuotEntryAckGrp_OrderQty2 -> opt msg "193" parse_LocalMktDate (fun msg f_QuotEntryAckGrp_SettlDate2 -> opt msg "40" parse_OrdType (fun msg f_QuotEntryAckGrp_OrdType -> opt msg "64" parse_LocalMktDate (fun msg f_QuotEntryAckGrp_SettlDate -> opt msg "625" parse_string (fun msg f_QuotEntryAckGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_QuotEntryAckGrp_TradingSessionID -> opt msg "60" parse_UTCTimestamp_milli (fun msg f_QuotEntryAckGrp_TransactTime -> opt msg "634" parse_float (fun msg f_QuotEntryAckGrp_OfferYield -> opt msg "633" parse_float (fun msg f_QuotEntryAckGrp_MidYield -> opt msg "632" parse_float (fun msg f_QuotEntryAckGrp_BidYield -> opt msg "631" parse_float (fun msg f_QuotEntryAckGrp_MidPx -> opt msg "191" parse_float (fun msg f_QuotEntryAckGrp_OfferForwardPoints -> opt msg "189" parse_float (fun msg f_QuotEntryAckGrp_BidForwardPoints -> opt msg "190" parse_float (fun msg f_QuotEntryAckGrp_OfferSpotRate -> opt msg "188" parse_float (fun msg f_QuotEntryAckGrp_BidSpotRate -> opt msg "62" parse_UTCTimestamp_milli (fun msg f_QuotEntryAckGrp_ValidUntilTime -> opt msg "135" parse_float (fun msg f_QuotEntryAckGrp_OfferSize -> opt msg "134" parse_float (fun msg f_QuotEntryAckGrp_BidSize -> opt msg "133" parse_float (fun msg f_QuotEntryAckGrp_OfferPx -> opt msg "132" parse_float (fun msg f_QuotEntryAckGrp_BidPx -> opt msg "299" parse_string (fun msg f_QuotEntryAckGrp_QuoteEntryID -> block msg parse_Instrument (fun msg f_QuotEntryAckGrp_Instrument -> repeating msg "555" parse_InstrmtLegGrp (fun msg f_QuotEntryAckGrp_InstrmtLegGrp -> (ParseSuccess { - f_QuotEntryAckGrp_InstrmtLegGrp = f_QuotEntryAckGrp_InstrmtLegGrp; - f_QuotEntryAckGrp_Instrument = f_QuotEntryAckGrp_Instrument; - f_QuotEntryAckGrp_NoQuoteEntries = f_QuotEntryAckGrp_NoQuoteEntries; - f_QuotEntryAckGrp_QuoteEntryID = f_QuotEntryAckGrp_QuoteEntryID; - f_QuotEntryAckGrp_BidPx = f_QuotEntryAckGrp_BidPx; - f_QuotEntryAckGrp_OfferPx = f_QuotEntryAckGrp_OfferPx; - f_QuotEntryAckGrp_BidSize = f_QuotEntryAckGrp_BidSize; - f_QuotEntryAckGrp_OfferSize = f_QuotEntryAckGrp_OfferSize; - f_QuotEntryAckGrp_ValidUntilTime = f_QuotEntryAckGrp_ValidUntilTime; - f_QuotEntryAckGrp_BidSpotRate = f_QuotEntryAckGrp_BidSpotRate; - f_QuotEntryAckGrp_OfferSpotRate = f_QuotEntryAckGrp_OfferSpotRate; - f_QuotEntryAckGrp_BidForwardPoints = f_QuotEntryAckGrp_BidForwardPoints; - f_QuotEntryAckGrp_OfferForwardPoints = f_QuotEntryAckGrp_OfferForwardPoints; - f_QuotEntryAckGrp_MidPx = f_QuotEntryAckGrp_MidPx; - f_QuotEntryAckGrp_BidYield = f_QuotEntryAckGrp_BidYield; - f_QuotEntryAckGrp_MidYield = f_QuotEntryAckGrp_MidYield; - f_QuotEntryAckGrp_OfferYield = f_QuotEntryAckGrp_OfferYield; - f_QuotEntryAckGrp_TransactTime = f_QuotEntryAckGrp_TransactTime; - f_QuotEntryAckGrp_TradingSessionID = f_QuotEntryAckGrp_TradingSessionID; - f_QuotEntryAckGrp_TradingSessionSubID = f_QuotEntryAckGrp_TradingSessionSubID; - f_QuotEntryAckGrp_SettlDate = f_QuotEntryAckGrp_SettlDate; - f_QuotEntryAckGrp_OrdType = f_QuotEntryAckGrp_OrdType; - f_QuotEntryAckGrp_SettlDate2 = f_QuotEntryAckGrp_SettlDate2; - f_QuotEntryAckGrp_OrderQty2 = f_QuotEntryAckGrp_OrderQty2; - f_QuotEntryAckGrp_BidForwardPoints2 = f_QuotEntryAckGrp_BidForwardPoints2; - f_QuotEntryAckGrp_OfferForwardPoints2 = f_QuotEntryAckGrp_OfferForwardPoints2; - f_QuotEntryAckGrp_Currency = f_QuotEntryAckGrp_Currency; - f_QuotEntryAckGrp_QuoteEntryRejectReason = f_QuotEntryAckGrp_QuoteEntryRejectReason - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_RelSymDerivSecGrp (msg) (f_RelSymDerivSecGrp_NoRelatedSym) = - opt msg "355" parse_string (fun msg f_RelSymDerivSecGrp_EncodedText -> opt msg "354" parse_int (fun msg f_RelSymDerivSecGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_RelSymDerivSecGrp_Text -> opt msg "625" parse_string (fun msg f_RelSymDerivSecGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_RelSymDerivSecGrp_TradingSessionID -> opt msg "827" parse_ExpirationCycle (fun msg f_RelSymDerivSecGrp_ExpirationCycle -> opt msg "15" parse_Currency (fun msg f_RelSymDerivSecGrp_Currency -> block msg parse_InstrumentExtension (fun msg f_RelSymDerivSecGrp_InstrumentExtension -> block msg parse_Instrument (fun msg f_RelSymDerivSecGrp_Instrument -> repeating msg "555" parse_InstrmtLegGrp (fun msg f_RelSymDerivSecGrp_InstrmtLegGrp -> (ParseSuccess { - f_RelSymDerivSecGrp_InstrmtLegGrp = f_RelSymDerivSecGrp_InstrmtLegGrp; - f_RelSymDerivSecGrp_Instrument = f_RelSymDerivSecGrp_Instrument; - f_RelSymDerivSecGrp_InstrumentExtension = f_RelSymDerivSecGrp_InstrumentExtension; - f_RelSymDerivSecGrp_NoRelatedSym = f_RelSymDerivSecGrp_NoRelatedSym; - f_RelSymDerivSecGrp_Currency = f_RelSymDerivSecGrp_Currency; - f_RelSymDerivSecGrp_ExpirationCycle = f_RelSymDerivSecGrp_ExpirationCycle; - f_RelSymDerivSecGrp_TradingSessionID = f_RelSymDerivSecGrp_TradingSessionID; - f_RelSymDerivSecGrp_TradingSessionSubID = f_RelSymDerivSecGrp_TradingSessionSubID; - f_RelSymDerivSecGrp_Text = f_RelSymDerivSecGrp_Text; - f_RelSymDerivSecGrp_EncodedTextLen = f_RelSymDerivSecGrp_EncodedTextLen; - f_RelSymDerivSecGrp_EncodedText = f_RelSymDerivSecGrp_EncodedText - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_LegOrdGrp (msg) (f_LegOrdGrp_NoLegs) = - opt msg "588" parse_LocalMktDate (fun msg f_LegOrdGrp_LegSettlDate -> opt msg "587" parse_char (fun msg f_LegOrdGrp_LegSettlType -> opt msg "566" parse_float (fun msg f_LegOrdGrp_LegPrice -> opt msg "654" parse_string (fun msg f_LegOrdGrp_LegRefID -> opt msg "565" parse_int (fun msg f_LegOrdGrp_LegCoveredOrUncovered -> opt msg "564" parse_char (fun msg f_LegOrdGrp_LegPositionEffect -> opt msg "690" parse_LegSwapType (fun msg f_LegOrdGrp_LegSwapType -> opt msg "687" parse_float (fun msg f_LegOrdGrp_LegQty -> block msg parse_InstrumentLeg (fun msg f_LegOrdGrp_InstrumentLeg -> repeating msg "539" parse_NestedParties (fun msg f_LegOrdGrp_NestedParties -> repeating msg "670" parse_LegPreAllocGrp (fun msg f_LegOrdGrp_LegPreAllocGrp -> repeating msg "683" parse_LegStipulations (fun msg f_LegOrdGrp_LegStipulations -> (ParseSuccess { - f_LegOrdGrp_LegStipulations = f_LegOrdGrp_LegStipulations; - f_LegOrdGrp_LegPreAllocGrp = f_LegOrdGrp_LegPreAllocGrp; - f_LegOrdGrp_NestedParties = f_LegOrdGrp_NestedParties; - f_LegOrdGrp_InstrumentLeg = f_LegOrdGrp_InstrumentLeg; - f_LegOrdGrp_NoLegs = f_LegOrdGrp_NoLegs; - f_LegOrdGrp_LegQty = f_LegOrdGrp_LegQty; - f_LegOrdGrp_LegSwapType = f_LegOrdGrp_LegSwapType; - f_LegOrdGrp_LegPositionEffect = f_LegOrdGrp_LegPositionEffect; - f_LegOrdGrp_LegCoveredOrUncovered = f_LegOrdGrp_LegCoveredOrUncovered; - f_LegOrdGrp_LegRefID = f_LegOrdGrp_LegRefID; - f_LegOrdGrp_LegPrice = f_LegOrdGrp_LegPrice; - f_LegOrdGrp_LegSettlType = f_LegOrdGrp_LegSettlType; - f_LegOrdGrp_LegSettlDate = f_LegOrdGrp_LegSettlDate - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_TrdCapRptSideGrp (msg) (f_TrdCapRptSideGrp_NoSides) = - opt msg "70" parse_string (fun msg f_TrdCapRptSideGrp_AllocID -> opt msg "591" parse_PreallocMethod (fun msg f_TrdCapRptSideGrp_PreallocMethod -> opt msg "826" parse_TradeAllocIndicator (fun msg f_TrdCapRptSideGrp_TradeAllocIndicator -> opt msg "825" parse_string (fun msg f_TrdCapRptSideGrp_ExchangeRule -> opt msg "752" parse_SideMultiLegReportingType (fun msg f_TrdCapRptSideGrp_SideMultiLegReportingType -> opt msg "355" parse_string (fun msg f_TrdCapRptSideGrp_EncodedText -> opt msg "354" parse_int (fun msg f_TrdCapRptSideGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_TrdCapRptSideGrp_Text -> opt msg "77" parse_PositionEffect (fun msg f_TrdCapRptSideGrp_PositionEffect -> opt msg "156" parse_SettlCurrFxRateCalc (fun msg f_TrdCapRptSideGrp_SettlCurrFxRateCalc -> opt msg "155" parse_float (fun msg f_TrdCapRptSideGrp_SettlCurrFxRate -> opt msg "120" parse_Currency (fun msg f_TrdCapRptSideGrp_SettlCurrency -> opt msg "119" parse_float (fun msg f_TrdCapRptSideGrp_SettlCurrAmt -> opt msg "118" parse_float (fun msg f_TrdCapRptSideGrp_NetMoney -> opt msg "237" parse_float (fun msg f_TrdCapRptSideGrp_TotalTakedown -> opt msg "238" parse_float (fun msg f_TrdCapRptSideGrp_Concession -> opt msg "922" parse_float (fun msg f_TrdCapRptSideGrp_EndCash -> opt msg "921" parse_float (fun msg f_TrdCapRptSideGrp_StartCash -> opt msg "920" parse_float (fun msg f_TrdCapRptSideGrp_EndAccruedInterestAmt -> opt msg "738" parse_float (fun msg f_TrdCapRptSideGrp_InterestAtMaturity -> opt msg "159" parse_float (fun msg f_TrdCapRptSideGrp_AccruedInterestAmt -> opt msg "158" parse_float (fun msg f_TrdCapRptSideGrp_AccruedInterestRate -> opt msg "230" parse_LocalMktDate (fun msg f_TrdCapRptSideGrp_ExDate -> opt msg "157" parse_int (fun msg f_TrdCapRptSideGrp_NumDaysInterest -> opt msg "381" parse_float (fun msg f_TrdCapRptSideGrp_GrossTradeAmt -> opt msg "943" parse_string (fun msg f_TrdCapRptSideGrp_TimeBracket -> opt msg "625" parse_string (fun msg f_TrdCapRptSideGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_TrdCapRptSideGrp_TradingSessionID -> opt msg "483" parse_UTCTimestamp_milli (fun msg f_TrdCapRptSideGrp_TransBkdTime -> opt msg "18" parse_ExecInst (fun msg f_TrdCapRptSideGrp_ExecInst -> opt msg "40" parse_OrdType (fun msg f_TrdCapRptSideGrp_OrdType -> opt msg "582" parse_CustOrderCapacity (fun msg f_TrdCapRptSideGrp_CustOrderCapacity -> opt msg "529" parse_OrderRestrictions (fun msg f_TrdCapRptSideGrp_OrderRestrictions -> opt msg "528" parse_OrderCapacity (fun msg f_TrdCapRptSideGrp_OrderCapacity -> opt msg "377" parse_SolicitedFlag (fun msg f_TrdCapRptSideGrp_SolicitedFlag -> opt msg "376" parse_string (fun msg f_TrdCapRptSideGrp_ComplianceID -> opt msg "15" parse_Currency (fun msg f_TrdCapRptSideGrp_Currency -> opt msg "821" parse_string (fun msg f_TrdCapRptSideGrp_OrderInputDevice -> opt msg "579" parse_string (fun msg f_TrdCapRptSideGrp_TradeInputDevice -> opt msg "578" parse_string (fun msg f_TrdCapRptSideGrp_TradeInputSource -> opt msg "575" parse_OddLot (fun msg f_TrdCapRptSideGrp_OddLot -> opt msg "81" parse_ProcessCode (fun msg f_TrdCapRptSideGrp_ProcessCode -> opt msg "581" parse_AccountType (fun msg f_TrdCapRptSideGrp_AccountType -> opt msg "660" parse_AcctIDSource (fun msg f_TrdCapRptSideGrp_AcctIDSource -> opt msg "1" parse_string (fun msg f_TrdCapRptSideGrp_Account -> opt msg "66" parse_string (fun msg f_TrdCapRptSideGrp_ListID -> opt msg "526" parse_string (fun msg f_TrdCapRptSideGrp_SecondaryClOrdID -> opt msg "11" parse_string (fun msg f_TrdCapRptSideGrp_ClOrdID -> opt msg "198" parse_string (fun msg f_TrdCapRptSideGrp_SecondaryOrderID -> opt msg "37" parse_string (fun msg f_TrdCapRptSideGrp_OrderID -> opt msg "54" parse_Side (fun msg f_TrdCapRptSideGrp_Side -> block msg parse_CommissionData (fun msg f_TrdCapRptSideGrp_CommissionData -> repeating msg "78" parse_TrdAllocGrp (fun msg f_TrdCapRptSideGrp_TrdAllocGrp -> repeating msg "136" parse_MiscFeesGrp (fun msg f_TrdCapRptSideGrp_MiscFeesGrp -> repeating msg "232" parse_Stipulations (fun msg f_TrdCapRptSideGrp_Stipulations -> repeating msg "518" parse_ContAmtGrp (fun msg f_TrdCapRptSideGrp_ContAmtGrp -> repeating msg "576" parse_ClrInstGrp (fun msg f_TrdCapRptSideGrp_ClrInstGrp -> repeating msg "453" parse_Parties (fun msg f_TrdCapRptSideGrp_Parties -> (ParseSuccess { - f_TrdCapRptSideGrp_Parties = f_TrdCapRptSideGrp_Parties; - f_TrdCapRptSideGrp_ClrInstGrp = f_TrdCapRptSideGrp_ClrInstGrp; - f_TrdCapRptSideGrp_ContAmtGrp = f_TrdCapRptSideGrp_ContAmtGrp; - f_TrdCapRptSideGrp_Stipulations = f_TrdCapRptSideGrp_Stipulations; - f_TrdCapRptSideGrp_MiscFeesGrp = f_TrdCapRptSideGrp_MiscFeesGrp; - f_TrdCapRptSideGrp_TrdAllocGrp = f_TrdCapRptSideGrp_TrdAllocGrp; - f_TrdCapRptSideGrp_CommissionData = f_TrdCapRptSideGrp_CommissionData; - f_TrdCapRptSideGrp_NoSides = f_TrdCapRptSideGrp_NoSides; - f_TrdCapRptSideGrp_Side = f_TrdCapRptSideGrp_Side; - f_TrdCapRptSideGrp_OrderID = f_TrdCapRptSideGrp_OrderID; - f_TrdCapRptSideGrp_SecondaryOrderID = f_TrdCapRptSideGrp_SecondaryOrderID; - f_TrdCapRptSideGrp_ClOrdID = f_TrdCapRptSideGrp_ClOrdID; - f_TrdCapRptSideGrp_SecondaryClOrdID = f_TrdCapRptSideGrp_SecondaryClOrdID; - f_TrdCapRptSideGrp_ListID = f_TrdCapRptSideGrp_ListID; - f_TrdCapRptSideGrp_Account = f_TrdCapRptSideGrp_Account; - f_TrdCapRptSideGrp_AcctIDSource = f_TrdCapRptSideGrp_AcctIDSource; - f_TrdCapRptSideGrp_AccountType = f_TrdCapRptSideGrp_AccountType; - f_TrdCapRptSideGrp_ProcessCode = f_TrdCapRptSideGrp_ProcessCode; - f_TrdCapRptSideGrp_OddLot = f_TrdCapRptSideGrp_OddLot; - f_TrdCapRptSideGrp_TradeInputSource = f_TrdCapRptSideGrp_TradeInputSource; - f_TrdCapRptSideGrp_TradeInputDevice = f_TrdCapRptSideGrp_TradeInputDevice; - f_TrdCapRptSideGrp_OrderInputDevice = f_TrdCapRptSideGrp_OrderInputDevice; - f_TrdCapRptSideGrp_Currency = f_TrdCapRptSideGrp_Currency; - f_TrdCapRptSideGrp_ComplianceID = f_TrdCapRptSideGrp_ComplianceID; - f_TrdCapRptSideGrp_SolicitedFlag = f_TrdCapRptSideGrp_SolicitedFlag; - f_TrdCapRptSideGrp_OrderCapacity = f_TrdCapRptSideGrp_OrderCapacity; - f_TrdCapRptSideGrp_OrderRestrictions = f_TrdCapRptSideGrp_OrderRestrictions; - f_TrdCapRptSideGrp_CustOrderCapacity = f_TrdCapRptSideGrp_CustOrderCapacity; - f_TrdCapRptSideGrp_OrdType = f_TrdCapRptSideGrp_OrdType; - f_TrdCapRptSideGrp_ExecInst = f_TrdCapRptSideGrp_ExecInst; - f_TrdCapRptSideGrp_TransBkdTime = f_TrdCapRptSideGrp_TransBkdTime; - f_TrdCapRptSideGrp_TradingSessionID = f_TrdCapRptSideGrp_TradingSessionID; - f_TrdCapRptSideGrp_TradingSessionSubID = f_TrdCapRptSideGrp_TradingSessionSubID; - f_TrdCapRptSideGrp_TimeBracket = f_TrdCapRptSideGrp_TimeBracket; - f_TrdCapRptSideGrp_GrossTradeAmt = f_TrdCapRptSideGrp_GrossTradeAmt; - f_TrdCapRptSideGrp_NumDaysInterest = f_TrdCapRptSideGrp_NumDaysInterest; - f_TrdCapRptSideGrp_ExDate = f_TrdCapRptSideGrp_ExDate; - f_TrdCapRptSideGrp_AccruedInterestRate = f_TrdCapRptSideGrp_AccruedInterestRate; - f_TrdCapRptSideGrp_AccruedInterestAmt = f_TrdCapRptSideGrp_AccruedInterestAmt; - f_TrdCapRptSideGrp_InterestAtMaturity = f_TrdCapRptSideGrp_InterestAtMaturity; - f_TrdCapRptSideGrp_EndAccruedInterestAmt = f_TrdCapRptSideGrp_EndAccruedInterestAmt; - f_TrdCapRptSideGrp_StartCash = f_TrdCapRptSideGrp_StartCash; - f_TrdCapRptSideGrp_EndCash = f_TrdCapRptSideGrp_EndCash; - f_TrdCapRptSideGrp_Concession = f_TrdCapRptSideGrp_Concession; - f_TrdCapRptSideGrp_TotalTakedown = f_TrdCapRptSideGrp_TotalTakedown; - f_TrdCapRptSideGrp_NetMoney = f_TrdCapRptSideGrp_NetMoney; - f_TrdCapRptSideGrp_SettlCurrAmt = f_TrdCapRptSideGrp_SettlCurrAmt; - f_TrdCapRptSideGrp_SettlCurrency = f_TrdCapRptSideGrp_SettlCurrency; - f_TrdCapRptSideGrp_SettlCurrFxRate = f_TrdCapRptSideGrp_SettlCurrFxRate; - f_TrdCapRptSideGrp_SettlCurrFxRateCalc = f_TrdCapRptSideGrp_SettlCurrFxRateCalc; - f_TrdCapRptSideGrp_PositionEffect = f_TrdCapRptSideGrp_PositionEffect; - f_TrdCapRptSideGrp_Text = f_TrdCapRptSideGrp_Text; - f_TrdCapRptSideGrp_EncodedTextLen = f_TrdCapRptSideGrp_EncodedTextLen; - f_TrdCapRptSideGrp_EncodedText = f_TrdCapRptSideGrp_EncodedText; - f_TrdCapRptSideGrp_SideMultiLegReportingType = f_TrdCapRptSideGrp_SideMultiLegReportingType; - f_TrdCapRptSideGrp_ExchangeRule = f_TrdCapRptSideGrp_ExchangeRule; - f_TrdCapRptSideGrp_TradeAllocIndicator = f_TrdCapRptSideGrp_TradeAllocIndicator; - f_TrdCapRptSideGrp_PreallocMethod = f_TrdCapRptSideGrp_PreallocMethod; - f_TrdCapRptSideGrp_AllocID = f_TrdCapRptSideGrp_AllocID - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_SecListGrp (msg) (f_SecListGrp_NoRelatedSym) = - opt msg "355" parse_string (fun msg f_SecListGrp_EncodedText -> opt msg "354" parse_int (fun msg f_SecListGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_SecListGrp_Text -> opt msg "827" parse_ExpirationCycle (fun msg f_SecListGrp_ExpirationCycle -> opt msg "625" parse_string (fun msg f_SecListGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_SecListGrp_TradingSessionID -> opt msg "562" parse_float (fun msg f_SecListGrp_MinTradeVol -> opt msg "561" parse_float (fun msg f_SecListGrp_RoundLot -> opt msg "15" parse_Currency (fun msg f_SecListGrp_Currency -> block msg parse_YieldData (fun msg f_SecListGrp_YieldData -> block msg parse_SpreadOrBenchmarkCurveData (fun msg f_SecListGrp_SpreadOrBenchmarkCurveData -> block msg parse_FinancingDetails (fun msg f_SecListGrp_FinancingDetails -> block msg parse_InstrumentExtension (fun msg f_SecListGrp_InstrumentExtension -> block msg parse_Instrument (fun msg f_SecListGrp_Instrument -> repeating msg "555" parse_InstrmtLegSecListGrp (fun msg f_SecListGrp_InstrmtLegSecListGrp -> repeating msg "232" parse_Stipulations (fun msg f_SecListGrp_Stipulations -> repeating msg "711" parse_UndInstrmtGrp (fun msg f_SecListGrp_UndInstrmtGrp -> (ParseSuccess { - f_SecListGrp_UndInstrmtGrp = f_SecListGrp_UndInstrmtGrp; - f_SecListGrp_Stipulations = f_SecListGrp_Stipulations; - f_SecListGrp_InstrmtLegSecListGrp = f_SecListGrp_InstrmtLegSecListGrp; - f_SecListGrp_Instrument = f_SecListGrp_Instrument; - f_SecListGrp_InstrumentExtension = f_SecListGrp_InstrumentExtension; - f_SecListGrp_FinancingDetails = f_SecListGrp_FinancingDetails; - f_SecListGrp_SpreadOrBenchmarkCurveData = f_SecListGrp_SpreadOrBenchmarkCurveData; - f_SecListGrp_YieldData = f_SecListGrp_YieldData; - f_SecListGrp_NoRelatedSym = f_SecListGrp_NoRelatedSym; - f_SecListGrp_Currency = f_SecListGrp_Currency; - f_SecListGrp_RoundLot = f_SecListGrp_RoundLot; - f_SecListGrp_MinTradeVol = f_SecListGrp_MinTradeVol; - f_SecListGrp_TradingSessionID = f_SecListGrp_TradingSessionID; - f_SecListGrp_TradingSessionSubID = f_SecListGrp_TradingSessionSubID; - f_SecListGrp_ExpirationCycle = f_SecListGrp_ExpirationCycle; - f_SecListGrp_Text = f_SecListGrp_Text; - f_SecListGrp_EncodedTextLen = f_SecListGrp_EncodedTextLen; - f_SecListGrp_EncodedText = f_SecListGrp_EncodedText - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_QuotReqGrp (msg) (f_QuotReqGrp_NoRelatedSym) = - opt msg "640" parse_float (fun msg f_QuotReqGrp_Price2 -> opt msg "44" parse_float (fun msg f_QuotReqGrp_Price -> opt msg "423" parse_PriceType (fun msg f_QuotReqGrp_PriceType -> opt msg "60" parse_UTCTimestamp_milli (fun msg f_QuotReqGrp_TransactTime -> opt msg "126" parse_UTCTimestamp_milli (fun msg f_QuotReqGrp_ExpireTime -> opt msg "62" parse_UTCTimestamp_milli (fun msg f_QuotReqGrp_ValidUntilTime -> opt msg "40" parse_OrdType (fun msg f_QuotReqGrp_OrdType -> opt msg "692" parse_QuotePriceType (fun msg f_QuotReqGrp_QuotePriceType -> opt msg "581" parse_AccountType (fun msg f_QuotReqGrp_AccountType -> opt msg "660" parse_AcctIDSource (fun msg f_QuotReqGrp_AcctIDSource -> opt msg "1" parse_string (fun msg f_QuotReqGrp_Account -> opt msg "15" parse_Currency (fun msg f_QuotReqGrp_Currency -> opt msg "192" parse_float (fun msg f_QuotReqGrp_OrderQty2 -> opt msg "193" parse_LocalMktDate (fun msg f_QuotReqGrp_SettlDate2 -> opt msg "64" parse_LocalMktDate (fun msg f_QuotReqGrp_SettlDate -> opt msg "63" parse_SettlType (fun msg f_QuotReqGrp_SettlType -> opt msg "854" parse_QtyType (fun msg f_QuotReqGrp_QtyType -> opt msg "54" parse_Side (fun msg f_QuotReqGrp_Side -> opt msg "229" parse_LocalMktDate (fun msg f_QuotReqGrp_TradeOriginationDate -> opt msg "625" parse_string (fun msg f_QuotReqGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_QuotReqGrp_TradingSessionID -> opt msg "537" parse_QuoteType (fun msg f_QuotReqGrp_QuoteType -> opt msg "303" parse_QuoteRequestType (fun msg f_QuotReqGrp_QuoteRequestType -> opt msg "140" parse_float (fun msg f_QuotReqGrp_PrevClosePx -> block msg parse_YieldData (fun msg f_QuotReqGrp_YieldData -> block msg parse_SpreadOrBenchmarkCurveData (fun msg f_QuotReqGrp_SpreadOrBenchmarkCurveData -> block msg parse_OrderQtyData (fun msg f_QuotReqGrp_OrderQtyData -> block msg parse_FinancingDetails (fun msg f_QuotReqGrp_FinancingDetails -> block msg parse_Instrument (fun msg f_QuotReqGrp_Instrument -> repeating msg "453" parse_Parties (fun msg f_QuotReqGrp_Parties -> repeating msg "735" parse_QuotQualGrp (fun msg f_QuotReqGrp_QuotQualGrp -> repeating msg "555" parse_QuotReqLegsGrp (fun msg f_QuotReqGrp_QuotReqLegsGrp -> repeating msg "232" parse_Stipulations (fun msg f_QuotReqGrp_Stipulations -> repeating msg "711" parse_UndInstrmtGrp (fun msg f_QuotReqGrp_UndInstrmtGrp -> (ParseSuccess { - f_QuotReqGrp_UndInstrmtGrp = f_QuotReqGrp_UndInstrmtGrp; - f_QuotReqGrp_Stipulations = f_QuotReqGrp_Stipulations; - f_QuotReqGrp_QuotReqLegsGrp = f_QuotReqGrp_QuotReqLegsGrp; - f_QuotReqGrp_QuotQualGrp = f_QuotReqGrp_QuotQualGrp; - f_QuotReqGrp_Parties = f_QuotReqGrp_Parties; - f_QuotReqGrp_Instrument = f_QuotReqGrp_Instrument; - f_QuotReqGrp_FinancingDetails = f_QuotReqGrp_FinancingDetails; - f_QuotReqGrp_OrderQtyData = f_QuotReqGrp_OrderQtyData; - f_QuotReqGrp_SpreadOrBenchmarkCurveData = f_QuotReqGrp_SpreadOrBenchmarkCurveData; - f_QuotReqGrp_YieldData = f_QuotReqGrp_YieldData; - f_QuotReqGrp_NoRelatedSym = f_QuotReqGrp_NoRelatedSym; - f_QuotReqGrp_PrevClosePx = f_QuotReqGrp_PrevClosePx; - f_QuotReqGrp_QuoteRequestType = f_QuotReqGrp_QuoteRequestType; - f_QuotReqGrp_QuoteType = f_QuotReqGrp_QuoteType; - f_QuotReqGrp_TradingSessionID = f_QuotReqGrp_TradingSessionID; - f_QuotReqGrp_TradingSessionSubID = f_QuotReqGrp_TradingSessionSubID; - f_QuotReqGrp_TradeOriginationDate = f_QuotReqGrp_TradeOriginationDate; - f_QuotReqGrp_Side = f_QuotReqGrp_Side; - f_QuotReqGrp_QtyType = f_QuotReqGrp_QtyType; - f_QuotReqGrp_SettlType = f_QuotReqGrp_SettlType; - f_QuotReqGrp_SettlDate = f_QuotReqGrp_SettlDate; - f_QuotReqGrp_SettlDate2 = f_QuotReqGrp_SettlDate2; - f_QuotReqGrp_OrderQty2 = f_QuotReqGrp_OrderQty2; - f_QuotReqGrp_Currency = f_QuotReqGrp_Currency; - f_QuotReqGrp_Account = f_QuotReqGrp_Account; - f_QuotReqGrp_AcctIDSource = f_QuotReqGrp_AcctIDSource; - f_QuotReqGrp_AccountType = f_QuotReqGrp_AccountType; - f_QuotReqGrp_QuotePriceType = f_QuotReqGrp_QuotePriceType; - f_QuotReqGrp_OrdType = f_QuotReqGrp_OrdType; - f_QuotReqGrp_ValidUntilTime = f_QuotReqGrp_ValidUntilTime; - f_QuotReqGrp_ExpireTime = f_QuotReqGrp_ExpireTime; - f_QuotReqGrp_TransactTime = f_QuotReqGrp_TransactTime; - f_QuotReqGrp_PriceType = f_QuotReqGrp_PriceType; - f_QuotReqGrp_Price = f_QuotReqGrp_Price; - f_QuotReqGrp_Price2 = f_QuotReqGrp_Price2 - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_MDIncGrp (msg) (f_MDIncGrp_NoMDEntries) = - opt msg "355" parse_string (fun msg f_MDIncGrp_EncodedText -> opt msg "354" parse_int (fun msg f_MDIncGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_MDIncGrp_Text -> opt msg "451" parse_float (fun msg f_MDIncGrp_NetChgPrevDay -> opt msg "811" parse_float (fun msg f_MDIncGrp_PriceDelta -> opt msg "546" parse_Scope (fun msg f_MDIncGrp_Scope -> opt msg "290" parse_int (fun msg f_MDIncGrp_MDEntryPositionNo -> opt msg "346" parse_int (fun msg f_MDIncGrp_NumberOfOrders -> opt msg "289" parse_string (fun msg f_MDIncGrp_MDEntrySeller -> opt msg "288" parse_string (fun msg f_MDIncGrp_MDEntryBuyer -> opt msg "299" parse_string (fun msg f_MDIncGrp_QuoteEntryID -> opt msg "37" parse_string (fun msg f_MDIncGrp_OrderID -> opt msg "287" parse_int (fun msg f_MDIncGrp_SellerDays -> opt msg "18" parse_ExecInst (fun msg f_MDIncGrp_ExecInst -> opt msg "110" parse_float (fun msg f_MDIncGrp_MinQty -> opt msg "126" parse_UTCTimestamp_milli (fun msg f_MDIncGrp_ExpireTime -> opt msg "432" parse_LocalMktDate (fun msg f_MDIncGrp_ExpireDate -> opt msg "59" parse_TimeInForce (fun msg f_MDIncGrp_TimeInForce -> opt msg "286" parse_OpenCloseSettlFlag (fun msg f_MDIncGrp_OpenCloseSettlFlag -> opt msg "284" parse_string (fun msg f_MDIncGrp_DeskID -> opt msg "283" parse_string (fun msg f_MDIncGrp_LocationID -> opt msg "282" parse_string (fun msg f_MDIncGrp_MDEntryOriginator -> opt msg "277" parse_TradeCondition (fun msg f_MDIncGrp_TradeCondition -> opt msg "276" parse_QuoteCondition (fun msg f_MDIncGrp_QuoteCondition -> opt msg "625" parse_string (fun msg f_MDIncGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_MDIncGrp_TradingSessionID -> opt msg "275" parse_Exchange (fun msg f_MDIncGrp_MDMkt -> opt msg "274" parse_TickDirection (fun msg f_MDIncGrp_TickDirection -> opt msg "273" parse_UTCTimeOnly_milli (fun msg f_MDIncGrp_MDEntryTime -> opt msg "272" parse_UTCDateOnly (fun msg f_MDIncGrp_MDEntryDate -> opt msg "271" parse_float (fun msg f_MDIncGrp_MDEntrySize -> opt msg "15" parse_Currency (fun msg f_MDIncGrp_Currency -> opt msg "270" parse_float (fun msg f_MDIncGrp_MDEntryPx -> opt msg "292" parse_CorporateAction (fun msg f_MDIncGrp_CorporateAction -> opt msg "291" parse_FinancialStatus (fun msg f_MDIncGrp_FinancialStatus -> opt msg "280" parse_string (fun msg f_MDIncGrp_MDEntryRefID -> opt msg "278" parse_string (fun msg f_MDIncGrp_MDEntryID -> opt msg "269" parse_MDEntryType (fun msg f_MDIncGrp_MDEntryType -> opt msg "285" parse_DeleteReason (fun msg f_MDIncGrp_DeleteReason -> opt msg "279" parse_MDUpdateAction (fun msg f_MDIncGrp_MDUpdateAction -> block msg parse_Instrument (fun msg f_MDIncGrp_Instrument -> repeating msg "555" parse_InstrmtLegGrp (fun msg f_MDIncGrp_InstrmtLegGrp -> repeating msg "711" parse_UndInstrmtGrp (fun msg f_MDIncGrp_UndInstrmtGrp -> (ParseSuccess { - f_MDIncGrp_UndInstrmtGrp = f_MDIncGrp_UndInstrmtGrp; - f_MDIncGrp_InstrmtLegGrp = f_MDIncGrp_InstrmtLegGrp; - f_MDIncGrp_Instrument = f_MDIncGrp_Instrument; - f_MDIncGrp_NoMDEntries = f_MDIncGrp_NoMDEntries; - f_MDIncGrp_MDUpdateAction = f_MDIncGrp_MDUpdateAction; - f_MDIncGrp_DeleteReason = f_MDIncGrp_DeleteReason; - f_MDIncGrp_MDEntryType = f_MDIncGrp_MDEntryType; - f_MDIncGrp_MDEntryID = f_MDIncGrp_MDEntryID; - f_MDIncGrp_MDEntryRefID = f_MDIncGrp_MDEntryRefID; - f_MDIncGrp_FinancialStatus = f_MDIncGrp_FinancialStatus; - f_MDIncGrp_CorporateAction = f_MDIncGrp_CorporateAction; - f_MDIncGrp_MDEntryPx = f_MDIncGrp_MDEntryPx; - f_MDIncGrp_Currency = f_MDIncGrp_Currency; - f_MDIncGrp_MDEntrySize = f_MDIncGrp_MDEntrySize; - f_MDIncGrp_MDEntryDate = f_MDIncGrp_MDEntryDate; - f_MDIncGrp_MDEntryTime = f_MDIncGrp_MDEntryTime; - f_MDIncGrp_TickDirection = f_MDIncGrp_TickDirection; - f_MDIncGrp_MDMkt = f_MDIncGrp_MDMkt; - f_MDIncGrp_TradingSessionID = f_MDIncGrp_TradingSessionID; - f_MDIncGrp_TradingSessionSubID = f_MDIncGrp_TradingSessionSubID; - f_MDIncGrp_QuoteCondition = f_MDIncGrp_QuoteCondition; - f_MDIncGrp_TradeCondition = f_MDIncGrp_TradeCondition; - f_MDIncGrp_MDEntryOriginator = f_MDIncGrp_MDEntryOriginator; - f_MDIncGrp_LocationID = f_MDIncGrp_LocationID; - f_MDIncGrp_DeskID = f_MDIncGrp_DeskID; - f_MDIncGrp_OpenCloseSettlFlag = f_MDIncGrp_OpenCloseSettlFlag; - f_MDIncGrp_TimeInForce = f_MDIncGrp_TimeInForce; - f_MDIncGrp_ExpireDate = f_MDIncGrp_ExpireDate; - f_MDIncGrp_ExpireTime = f_MDIncGrp_ExpireTime; - f_MDIncGrp_MinQty = f_MDIncGrp_MinQty; - f_MDIncGrp_ExecInst = f_MDIncGrp_ExecInst; - f_MDIncGrp_SellerDays = f_MDIncGrp_SellerDays; - f_MDIncGrp_OrderID = f_MDIncGrp_OrderID; - f_MDIncGrp_QuoteEntryID = f_MDIncGrp_QuoteEntryID; - f_MDIncGrp_MDEntryBuyer = f_MDIncGrp_MDEntryBuyer; - f_MDIncGrp_MDEntrySeller = f_MDIncGrp_MDEntrySeller; - f_MDIncGrp_NumberOfOrders = f_MDIncGrp_NumberOfOrders; - f_MDIncGrp_MDEntryPositionNo = f_MDIncGrp_MDEntryPositionNo; - f_MDIncGrp_Scope = f_MDIncGrp_Scope; - f_MDIncGrp_PriceDelta = f_MDIncGrp_PriceDelta; - f_MDIncGrp_NetChgPrevDay = f_MDIncGrp_NetChgPrevDay; - f_MDIncGrp_Text = f_MDIncGrp_Text; - f_MDIncGrp_EncodedTextLen = f_MDIncGrp_EncodedTextLen; - f_MDIncGrp_EncodedText = f_MDIncGrp_EncodedText - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_InstrmtMDReqGrp (msg) (f_InstrmtMDReqGrp_NoRelatedSym) = - block msg parse_Instrument (fun msg f_InstrmtMDReqGrp_Instrument -> repeating msg "555" parse_InstrmtLegGrp (fun msg f_InstrmtMDReqGrp_InstrmtLegGrp -> repeating msg "711" parse_UndInstrmtGrp (fun msg f_InstrmtMDReqGrp_UndInstrmtGrp -> (ParseSuccess { - f_InstrmtMDReqGrp_UndInstrmtGrp = f_InstrmtMDReqGrp_UndInstrmtGrp; - f_InstrmtMDReqGrp_InstrmtLegGrp = f_InstrmtMDReqGrp_InstrmtLegGrp; - f_InstrmtMDReqGrp_Instrument = f_InstrmtMDReqGrp_Instrument; - f_InstrmtMDReqGrp_NoRelatedSym = f_InstrmtMDReqGrp_NoRelatedSym - },msg) - ) - ) - ) - [@@macro] -;; - -let parse_QuotCxlEntriesGrp (msg) (f_QuotCxlEntriesGrp_NoQuoteEntries) = - block msg parse_FinancingDetails (fun msg f_QuotCxlEntriesGrp_FinancingDetails -> block msg parse_Instrument (fun msg f_QuotCxlEntriesGrp_Instrument -> repeating msg "555" parse_InstrmtLegGrp (fun msg f_QuotCxlEntriesGrp_InstrmtLegGrp -> repeating msg "711" parse_UndInstrmtGrp (fun msg f_QuotCxlEntriesGrp_UndInstrmtGrp -> (ParseSuccess { - f_QuotCxlEntriesGrp_UndInstrmtGrp = f_QuotCxlEntriesGrp_UndInstrmtGrp; - f_QuotCxlEntriesGrp_InstrmtLegGrp = f_QuotCxlEntriesGrp_InstrmtLegGrp; - f_QuotCxlEntriesGrp_Instrument = f_QuotCxlEntriesGrp_Instrument; - f_QuotCxlEntriesGrp_FinancingDetails = f_QuotCxlEntriesGrp_FinancingDetails; - f_QuotCxlEntriesGrp_NoQuoteEntries = f_QuotCxlEntriesGrp_NoQuoteEntries - },msg) - ) - ) - ) - ) - [@@macro] -;; - -let parse_ListOrdGrp (msg) (f_ListOrdGrp_NoOrders) = - opt msg "494" parse_string (fun msg f_ListOrdGrp_Designation -> opt msg "849" parse_float (fun msg f_ListOrdGrp_ParticipationRate -> opt msg "848" parse_string (fun msg f_ListOrdGrp_TargetStrategyParameters -> opt msg "847" parse_TargetStrategy (fun msg f_ListOrdGrp_TargetStrategy -> opt msg "210" parse_float (fun msg f_ListOrdGrp_MaxShow -> opt msg "203" parse_CoveredOrUncovered (fun msg f_ListOrdGrp_CoveredOrUncovered -> opt msg "77" parse_PositionEffect (fun msg f_ListOrdGrp_PositionEffect -> opt msg "640" parse_float (fun msg f_ListOrdGrp_Price2 -> opt msg "192" parse_float (fun msg f_ListOrdGrp_OrderQty2 -> opt msg "193" parse_LocalMktDate (fun msg f_ListOrdGrp_SettlDate2 -> opt msg "355" parse_string (fun msg f_ListOrdGrp_EncodedText -> opt msg "354" parse_int (fun msg f_ListOrdGrp_EncodedTextLen -> opt msg "58" parse_string (fun msg f_ListOrdGrp_Text -> opt msg "775" parse_BookingType (fun msg f_ListOrdGrp_BookingType -> opt msg "120" parse_Currency (fun msg f_ListOrdGrp_SettlCurrency -> opt msg "121" parse_ForexReq (fun msg f_ListOrdGrp_ForexReq -> opt msg "582" parse_CustOrderCapacity (fun msg f_ListOrdGrp_CustOrderCapacity -> opt msg "529" parse_OrderRestrictions (fun msg f_ListOrdGrp_OrderRestrictions -> opt msg "528" parse_OrderCapacity (fun msg f_ListOrdGrp_OrderCapacity -> opt msg "427" parse_GTBookingInst (fun msg f_ListOrdGrp_GTBookingInst -> opt msg "126" parse_UTCTimestamp_milli (fun msg f_ListOrdGrp_ExpireTime -> opt msg "432" parse_LocalMktDate (fun msg f_ListOrdGrp_ExpireDate -> opt msg "168" parse_UTCTimestamp_milli (fun msg f_ListOrdGrp_EffectiveTime -> opt msg "59" parse_TimeInForce (fun msg f_ListOrdGrp_TimeInForce -> opt msg "117" parse_string (fun msg f_ListOrdGrp_QuoteID -> opt msg "23" parse_string (fun msg f_ListOrdGrp_IOIID -> opt msg "377" parse_SolicitedFlag (fun msg f_ListOrdGrp_SolicitedFlag -> opt msg "376" parse_string (fun msg f_ListOrdGrp_ComplianceID -> opt msg "15" parse_Currency (fun msg f_ListOrdGrp_Currency -> opt msg "99" parse_float (fun msg f_ListOrdGrp_StopPx -> opt msg "44" parse_float (fun msg f_ListOrdGrp_Price -> opt msg "423" parse_PriceType (fun msg f_ListOrdGrp_PriceType -> opt msg "40" parse_OrdType (fun msg f_ListOrdGrp_OrdType -> opt msg "854" parse_QtyType (fun msg f_ListOrdGrp_QtyType -> opt msg "60" parse_UTCTimestamp_milli (fun msg f_ListOrdGrp_TransactTime -> opt msg "114" parse_LocateReqd (fun msg f_ListOrdGrp_LocateReqd -> opt msg "401" parse_SideValueInd (fun msg f_ListOrdGrp_SideValueInd -> opt msg "54" parse_Side (fun msg f_ListOrdGrp_Side -> opt msg "140" parse_float (fun msg f_ListOrdGrp_PrevClosePx -> opt msg "81" parse_ProcessCode (fun msg f_ListOrdGrp_ProcessCode -> opt msg "100" parse_Exchange (fun msg f_ListOrdGrp_ExDestination -> opt msg "111" parse_float (fun msg f_ListOrdGrp_MaxFloor -> opt msg "110" parse_float (fun msg f_ListOrdGrp_MinQty -> opt msg "18" parse_ExecInst (fun msg f_ListOrdGrp_ExecInst -> opt msg "21" parse_HandlInst (fun msg f_ListOrdGrp_HandlInst -> opt msg "635" parse_ClearingFeeIndicator (fun msg f_ListOrdGrp_ClearingFeeIndicator -> opt msg "544" parse_CashMargin (fun msg f_ListOrdGrp_CashMargin -> opt msg "64" parse_LocalMktDate (fun msg f_ListOrdGrp_SettlDate -> opt msg "63" parse_SettlType (fun msg f_ListOrdGrp_SettlType -> opt msg "591" parse_PreallocMethod (fun msg f_ListOrdGrp_PreallocMethod -> opt msg "70" parse_string (fun msg f_ListOrdGrp_AllocID -> opt msg "590" parse_BookingUnit (fun msg f_ListOrdGrp_BookingUnit -> opt msg "589" parse_DayBookingInst (fun msg f_ListOrdGrp_DayBookingInst -> opt msg "581" parse_AccountType (fun msg f_ListOrdGrp_AccountType -> opt msg "660" parse_AcctIDSource (fun msg f_ListOrdGrp_AcctIDSource -> opt msg "1" parse_string (fun msg f_ListOrdGrp_Account -> opt msg "75" parse_LocalMktDate (fun msg f_ListOrdGrp_TradeDate -> opt msg "229" parse_LocalMktDate (fun msg f_ListOrdGrp_TradeOriginationDate -> opt msg "160" parse_SettlInstMode (fun msg f_ListOrdGrp_SettlInstMode -> opt msg "583" parse_string (fun msg f_ListOrdGrp_ClOrdLinkID -> opt msg "67" parse_int (fun msg f_ListOrdGrp_ListSeqNo -> opt msg "526" parse_string (fun msg f_ListOrdGrp_SecondaryClOrdID -> opt msg "11" parse_string (fun msg f_ListOrdGrp_ClOrdID -> block msg parse_DiscretionInstructions (fun msg f_ListOrdGrp_DiscretionInstructions -> block msg parse_PegInstructions (fun msg f_ListOrdGrp_PegInstructions -> block msg parse_CommissionData (fun msg f_ListOrdGrp_CommissionData -> block msg parse_YieldData (fun msg f_ListOrdGrp_YieldData -> block msg parse_SpreadOrBenchmarkCurveData (fun msg f_ListOrdGrp_SpreadOrBenchmarkCurveData -> block msg parse_OrderQtyData (fun msg f_ListOrdGrp_OrderQtyData -> block msg parse_Instrument (fun msg f_ListOrdGrp_Instrument -> repeating msg "232" parse_Stipulations (fun msg f_ListOrdGrp_Stipulations -> repeating msg "711" parse_UndInstrmtGrp (fun msg f_ListOrdGrp_UndInstrmtGrp -> repeating msg "386" parse_TrdgSesGrp (fun msg f_ListOrdGrp_TrdgSesGrp -> repeating msg "78" parse_PreAllocGrp (fun msg f_ListOrdGrp_PreAllocGrp -> repeating msg "453" parse_Parties (fun msg f_ListOrdGrp_Parties -> (ParseSuccess { - f_ListOrdGrp_Parties = f_ListOrdGrp_Parties; - f_ListOrdGrp_PreAllocGrp = f_ListOrdGrp_PreAllocGrp; - f_ListOrdGrp_TrdgSesGrp = f_ListOrdGrp_TrdgSesGrp; - f_ListOrdGrp_UndInstrmtGrp = f_ListOrdGrp_UndInstrmtGrp; - f_ListOrdGrp_Stipulations = f_ListOrdGrp_Stipulations; - f_ListOrdGrp_Instrument = f_ListOrdGrp_Instrument; - f_ListOrdGrp_OrderQtyData = f_ListOrdGrp_OrderQtyData; - f_ListOrdGrp_SpreadOrBenchmarkCurveData = f_ListOrdGrp_SpreadOrBenchmarkCurveData; - f_ListOrdGrp_YieldData = f_ListOrdGrp_YieldData; - f_ListOrdGrp_CommissionData = f_ListOrdGrp_CommissionData; - f_ListOrdGrp_PegInstructions = f_ListOrdGrp_PegInstructions; - f_ListOrdGrp_DiscretionInstructions = f_ListOrdGrp_DiscretionInstructions; - f_ListOrdGrp_NoOrders = f_ListOrdGrp_NoOrders; - f_ListOrdGrp_ClOrdID = f_ListOrdGrp_ClOrdID; - f_ListOrdGrp_SecondaryClOrdID = f_ListOrdGrp_SecondaryClOrdID; - f_ListOrdGrp_ListSeqNo = f_ListOrdGrp_ListSeqNo; - f_ListOrdGrp_ClOrdLinkID = f_ListOrdGrp_ClOrdLinkID; - f_ListOrdGrp_SettlInstMode = f_ListOrdGrp_SettlInstMode; - f_ListOrdGrp_TradeOriginationDate = f_ListOrdGrp_TradeOriginationDate; - f_ListOrdGrp_TradeDate = f_ListOrdGrp_TradeDate; - f_ListOrdGrp_Account = f_ListOrdGrp_Account; - f_ListOrdGrp_AcctIDSource = f_ListOrdGrp_AcctIDSource; - f_ListOrdGrp_AccountType = f_ListOrdGrp_AccountType; - f_ListOrdGrp_DayBookingInst = f_ListOrdGrp_DayBookingInst; - f_ListOrdGrp_BookingUnit = f_ListOrdGrp_BookingUnit; - f_ListOrdGrp_AllocID = f_ListOrdGrp_AllocID; - f_ListOrdGrp_PreallocMethod = f_ListOrdGrp_PreallocMethod; - f_ListOrdGrp_SettlType = f_ListOrdGrp_SettlType; - f_ListOrdGrp_SettlDate = f_ListOrdGrp_SettlDate; - f_ListOrdGrp_CashMargin = f_ListOrdGrp_CashMargin; - f_ListOrdGrp_ClearingFeeIndicator = f_ListOrdGrp_ClearingFeeIndicator; - f_ListOrdGrp_HandlInst = f_ListOrdGrp_HandlInst; - f_ListOrdGrp_ExecInst = f_ListOrdGrp_ExecInst; - f_ListOrdGrp_MinQty = f_ListOrdGrp_MinQty; - f_ListOrdGrp_MaxFloor = f_ListOrdGrp_MaxFloor; - f_ListOrdGrp_ExDestination = f_ListOrdGrp_ExDestination; - f_ListOrdGrp_ProcessCode = f_ListOrdGrp_ProcessCode; - f_ListOrdGrp_PrevClosePx = f_ListOrdGrp_PrevClosePx; - f_ListOrdGrp_Side = f_ListOrdGrp_Side; - f_ListOrdGrp_SideValueInd = f_ListOrdGrp_SideValueInd; - f_ListOrdGrp_LocateReqd = f_ListOrdGrp_LocateReqd; - f_ListOrdGrp_TransactTime = f_ListOrdGrp_TransactTime; - f_ListOrdGrp_QtyType = f_ListOrdGrp_QtyType; - f_ListOrdGrp_OrdType = f_ListOrdGrp_OrdType; - f_ListOrdGrp_PriceType = f_ListOrdGrp_PriceType; - f_ListOrdGrp_Price = f_ListOrdGrp_Price; - f_ListOrdGrp_StopPx = f_ListOrdGrp_StopPx; - f_ListOrdGrp_Currency = f_ListOrdGrp_Currency; - f_ListOrdGrp_ComplianceID = f_ListOrdGrp_ComplianceID; - f_ListOrdGrp_SolicitedFlag = f_ListOrdGrp_SolicitedFlag; - f_ListOrdGrp_IOIID = f_ListOrdGrp_IOIID; - f_ListOrdGrp_QuoteID = f_ListOrdGrp_QuoteID; - f_ListOrdGrp_TimeInForce = f_ListOrdGrp_TimeInForce; - f_ListOrdGrp_EffectiveTime = f_ListOrdGrp_EffectiveTime; - f_ListOrdGrp_ExpireDate = f_ListOrdGrp_ExpireDate; - f_ListOrdGrp_ExpireTime = f_ListOrdGrp_ExpireTime; - f_ListOrdGrp_GTBookingInst = f_ListOrdGrp_GTBookingInst; - f_ListOrdGrp_OrderCapacity = f_ListOrdGrp_OrderCapacity; - f_ListOrdGrp_OrderRestrictions = f_ListOrdGrp_OrderRestrictions; - f_ListOrdGrp_CustOrderCapacity = f_ListOrdGrp_CustOrderCapacity; - f_ListOrdGrp_ForexReq = f_ListOrdGrp_ForexReq; - f_ListOrdGrp_SettlCurrency = f_ListOrdGrp_SettlCurrency; - f_ListOrdGrp_BookingType = f_ListOrdGrp_BookingType; - f_ListOrdGrp_Text = f_ListOrdGrp_Text; - f_ListOrdGrp_EncodedTextLen = f_ListOrdGrp_EncodedTextLen; - f_ListOrdGrp_EncodedText = f_ListOrdGrp_EncodedText; - f_ListOrdGrp_SettlDate2 = f_ListOrdGrp_SettlDate2; - f_ListOrdGrp_OrderQty2 = f_ListOrdGrp_OrderQty2; - f_ListOrdGrp_Price2 = f_ListOrdGrp_Price2; - f_ListOrdGrp_PositionEffect = f_ListOrdGrp_PositionEffect; - f_ListOrdGrp_CoveredOrUncovered = f_ListOrdGrp_CoveredOrUncovered; - f_ListOrdGrp_MaxShow = f_ListOrdGrp_MaxShow; - f_ListOrdGrp_TargetStrategy = f_ListOrdGrp_TargetStrategy; - f_ListOrdGrp_TargetStrategyParameters = f_ListOrdGrp_TargetStrategyParameters; - f_ListOrdGrp_ParticipationRate = f_ListOrdGrp_ParticipationRate; - f_ListOrdGrp_Designation = f_ListOrdGrp_Designation - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_RFQReqGrp (msg) (f_RFQReqGrp_NoRelatedSym) = - opt msg "625" parse_string (fun msg f_RFQReqGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_RFQReqGrp_TradingSessionID -> opt msg "537" parse_QuoteType (fun msg f_RFQReqGrp_QuoteType -> opt msg "303" parse_QuoteRequestType (fun msg f_RFQReqGrp_QuoteRequestType -> opt msg "140" parse_float (fun msg f_RFQReqGrp_PrevClosePx -> block msg parse_Instrument (fun msg f_RFQReqGrp_Instrument -> repeating msg "555" parse_InstrmtLegGrp (fun msg f_RFQReqGrp_InstrmtLegGrp -> repeating msg "711" parse_UndInstrmtGrp (fun msg f_RFQReqGrp_UndInstrmtGrp -> (ParseSuccess { - f_RFQReqGrp_UndInstrmtGrp = f_RFQReqGrp_UndInstrmtGrp; - f_RFQReqGrp_InstrmtLegGrp = f_RFQReqGrp_InstrmtLegGrp; - f_RFQReqGrp_Instrument = f_RFQReqGrp_Instrument; - f_RFQReqGrp_NoRelatedSym = f_RFQReqGrp_NoRelatedSym; - f_RFQReqGrp_PrevClosePx = f_RFQReqGrp_PrevClosePx; - f_RFQReqGrp_QuoteRequestType = f_RFQReqGrp_QuoteRequestType; - f_RFQReqGrp_QuoteType = f_RFQReqGrp_QuoteType; - f_RFQReqGrp_TradingSessionID = f_RFQReqGrp_TradingSessionID; - f_RFQReqGrp_TradingSessionSubID = f_RFQReqGrp_TradingSessionSubID - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_QuotReqRjctGrp (msg) (f_QuotReqRjctGrp_NoRelatedSym) = - opt msg "640" parse_float (fun msg f_QuotReqRjctGrp_Price2 -> opt msg "44" parse_float (fun msg f_QuotReqRjctGrp_Price -> opt msg "423" parse_PriceType (fun msg f_QuotReqRjctGrp_PriceType -> opt msg "60" parse_UTCTimestamp_milli (fun msg f_QuotReqRjctGrp_TransactTime -> opt msg "126" parse_UTCTimestamp_milli (fun msg f_QuotReqRjctGrp_ExpireTime -> opt msg "40" parse_OrdType (fun msg f_QuotReqRjctGrp_OrdType -> opt msg "692" parse_QuotePriceType (fun msg f_QuotReqRjctGrp_QuotePriceType -> opt msg "581" parse_AccountType (fun msg f_QuotReqRjctGrp_AccountType -> opt msg "660" parse_AcctIDSource (fun msg f_QuotReqRjctGrp_AcctIDSource -> opt msg "1" parse_string (fun msg f_QuotReqRjctGrp_Account -> opt msg "15" parse_Currency (fun msg f_QuotReqRjctGrp_Currency -> opt msg "192" parse_float (fun msg f_QuotReqRjctGrp_OrderQty2 -> opt msg "193" parse_LocalMktDate (fun msg f_QuotReqRjctGrp_SettlDate2 -> opt msg "64" parse_LocalMktDate (fun msg f_QuotReqRjctGrp_SettlDate -> opt msg "63" parse_SettlType (fun msg f_QuotReqRjctGrp_SettlType -> opt msg "854" parse_QtyType (fun msg f_QuotReqRjctGrp_QtyType -> opt msg "54" parse_Side (fun msg f_QuotReqRjctGrp_Side -> opt msg "229" parse_LocalMktDate (fun msg f_QuotReqRjctGrp_TradeOriginationDate -> opt msg "625" parse_string (fun msg f_QuotReqRjctGrp_TradingSessionSubID -> opt msg "336" parse_string (fun msg f_QuotReqRjctGrp_TradingSessionID -> opt msg "537" parse_QuoteType (fun msg f_QuotReqRjctGrp_QuoteType -> opt msg "303" parse_QuoteRequestType (fun msg f_QuotReqRjctGrp_QuoteRequestType -> opt msg "140" parse_float (fun msg f_QuotReqRjctGrp_PrevClosePx -> block msg parse_YieldData (fun msg f_QuotReqRjctGrp_YieldData -> block msg parse_SpreadOrBenchmarkCurveData (fun msg f_QuotReqRjctGrp_SpreadOrBenchmarkCurveData -> block msg parse_OrderQtyData (fun msg f_QuotReqRjctGrp_OrderQtyData -> block msg parse_FinancingDetails (fun msg f_QuotReqRjctGrp_FinancingDetails -> block msg parse_Instrument (fun msg f_QuotReqRjctGrp_Instrument -> repeating msg "453" parse_Parties (fun msg f_QuotReqRjctGrp_Parties -> repeating msg "735" parse_QuotQualGrp (fun msg f_QuotReqRjctGrp_QuotQualGrp -> repeating msg "555" parse_QuotReqLegsGrp (fun msg f_QuotReqRjctGrp_QuotReqLegsGrp -> repeating msg "232" parse_Stipulations (fun msg f_QuotReqRjctGrp_Stipulations -> repeating msg "711" parse_UndInstrmtGrp (fun msg f_QuotReqRjctGrp_UndInstrmtGrp -> (ParseSuccess { - f_QuotReqRjctGrp_UndInstrmtGrp = f_QuotReqRjctGrp_UndInstrmtGrp; - f_QuotReqRjctGrp_Stipulations = f_QuotReqRjctGrp_Stipulations; - f_QuotReqRjctGrp_QuotReqLegsGrp = f_QuotReqRjctGrp_QuotReqLegsGrp; - f_QuotReqRjctGrp_QuotQualGrp = f_QuotReqRjctGrp_QuotQualGrp; - f_QuotReqRjctGrp_Parties = f_QuotReqRjctGrp_Parties; - f_QuotReqRjctGrp_Instrument = f_QuotReqRjctGrp_Instrument; - f_QuotReqRjctGrp_FinancingDetails = f_QuotReqRjctGrp_FinancingDetails; - f_QuotReqRjctGrp_OrderQtyData = f_QuotReqRjctGrp_OrderQtyData; - f_QuotReqRjctGrp_SpreadOrBenchmarkCurveData = f_QuotReqRjctGrp_SpreadOrBenchmarkCurveData; - f_QuotReqRjctGrp_YieldData = f_QuotReqRjctGrp_YieldData; - f_QuotReqRjctGrp_NoRelatedSym = f_QuotReqRjctGrp_NoRelatedSym; - f_QuotReqRjctGrp_PrevClosePx = f_QuotReqRjctGrp_PrevClosePx; - f_QuotReqRjctGrp_QuoteRequestType = f_QuotReqRjctGrp_QuoteRequestType; - f_QuotReqRjctGrp_QuoteType = f_QuotReqRjctGrp_QuoteType; - f_QuotReqRjctGrp_TradingSessionID = f_QuotReqRjctGrp_TradingSessionID; - f_QuotReqRjctGrp_TradingSessionSubID = f_QuotReqRjctGrp_TradingSessionSubID; - f_QuotReqRjctGrp_TradeOriginationDate = f_QuotReqRjctGrp_TradeOriginationDate; - f_QuotReqRjctGrp_Side = f_QuotReqRjctGrp_Side; - f_QuotReqRjctGrp_QtyType = f_QuotReqRjctGrp_QtyType; - f_QuotReqRjctGrp_SettlType = f_QuotReqRjctGrp_SettlType; - f_QuotReqRjctGrp_SettlDate = f_QuotReqRjctGrp_SettlDate; - f_QuotReqRjctGrp_SettlDate2 = f_QuotReqRjctGrp_SettlDate2; - f_QuotReqRjctGrp_OrderQty2 = f_QuotReqRjctGrp_OrderQty2; - f_QuotReqRjctGrp_Currency = f_QuotReqRjctGrp_Currency; - f_QuotReqRjctGrp_Account = f_QuotReqRjctGrp_Account; - f_QuotReqRjctGrp_AcctIDSource = f_QuotReqRjctGrp_AcctIDSource; - f_QuotReqRjctGrp_AccountType = f_QuotReqRjctGrp_AccountType; - f_QuotReqRjctGrp_QuotePriceType = f_QuotReqRjctGrp_QuotePriceType; - f_QuotReqRjctGrp_OrdType = f_QuotReqRjctGrp_OrdType; - f_QuotReqRjctGrp_ExpireTime = f_QuotReqRjctGrp_ExpireTime; - f_QuotReqRjctGrp_TransactTime = f_QuotReqRjctGrp_TransactTime; - f_QuotReqRjctGrp_PriceType = f_QuotReqRjctGrp_PriceType; - f_QuotReqRjctGrp_Price = f_QuotReqRjctGrp_Price; - f_QuotReqRjctGrp_Price2 = f_QuotReqRjctGrp_Price2 - },msg) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_QuotSetAckGrp (msg) (f_QuotSetAckGrp_NoQuoteSets) = - opt msg "893" parse_LastFragment (fun msg f_QuotSetAckGrp_LastFragment -> opt msg "304" parse_int (fun msg f_QuotSetAckGrp_TotNoQuoteEntries -> opt msg "302" parse_string (fun msg f_QuotSetAckGrp_QuoteSetID -> block msg parse_UnderlyingInstrument (fun msg f_QuotSetAckGrp_UnderlyingInstrument -> repeating msg "295" parse_QuotEntryAckGrp (fun msg f_QuotSetAckGrp_QuotEntryAckGrp -> (ParseSuccess { - f_QuotSetAckGrp_QuotEntryAckGrp = f_QuotSetAckGrp_QuotEntryAckGrp; - f_QuotSetAckGrp_UnderlyingInstrument = f_QuotSetAckGrp_UnderlyingInstrument; - f_QuotSetAckGrp_NoQuoteSets = f_QuotSetAckGrp_NoQuoteSets; - f_QuotSetAckGrp_QuoteSetID = f_QuotSetAckGrp_QuoteSetID; - f_QuotSetAckGrp_TotNoQuoteEntries = f_QuotSetAckGrp_TotNoQuoteEntries; - f_QuotSetAckGrp_LastFragment = f_QuotSetAckGrp_LastFragment - },msg) - ) - ) - ) - ) - ) - [@@macro] -;; - -let parse_QuotSetGrp (msg) (f_QuotSetGrp_NoQuoteSets) = - opt msg "893" parse_LastFragment (fun msg f_QuotSetGrp_LastFragment -> opt msg "304" parse_int (fun msg f_QuotSetGrp_TotNoQuoteEntries -> opt msg "367" parse_UTCTimestamp_milli (fun msg f_QuotSetGrp_QuoteSetValidUntilTime -> opt msg "302" parse_string (fun msg f_QuotSetGrp_QuoteSetID -> block msg parse_UnderlyingInstrument (fun msg f_QuotSetGrp_UnderlyingInstrument -> repeating msg "295" parse_QuotEntryGrp (fun msg f_QuotSetGrp_QuotEntryGrp -> (ParseSuccess { - f_QuotSetGrp_QuotEntryGrp = f_QuotSetGrp_QuotEntryGrp; - f_QuotSetGrp_UnderlyingInstrument = f_QuotSetGrp_UnderlyingInstrument; - f_QuotSetGrp_NoQuoteSets = f_QuotSetGrp_NoQuoteSets; - f_QuotSetGrp_QuoteSetID = f_QuotSetGrp_QuoteSetID; - f_QuotSetGrp_QuoteSetValidUntilTime = f_QuotSetGrp_QuoteSetValidUntilTime; - f_QuotSetGrp_TotNoQuoteEntries = f_QuotSetGrp_TotNoQuoteEntries; - f_QuotSetGrp_LastFragment = f_QuotSetGrp_LastFragment +let parse_OrderQtyData (msg) = + opt msg "38" parse_float (fun msg f_OrderQtyData_OrderQty -> (ParseSuccess { + f_OrderQtyData_OrderQty = f_OrderQtyData_OrderQty },msg) ) - ) - ) - ) - ) - ) - [@@macro] ;; -let parse_AllocGrp (msg) (f_AllocGrp_NoAllocs) = - opt msg "780" parse_AllocSettlInstType (fun msg f_AllocGrp_AllocSettlInstType -> opt msg "741" parse_float (fun msg f_AllocGrp_AllocInterestAtMaturity -> opt msg "742" parse_float (fun msg f_AllocGrp_AllocAccruedInterestAmt -> opt msg "156" parse_SettlCurrFxRateCalc (fun msg f_AllocGrp_SettlCurrFxRateCalc -> opt msg "155" parse_float (fun msg f_AllocGrp_SettlCurrFxRate -> opt msg "736" parse_Currency (fun msg f_AllocGrp_AllocSettlCurrency -> opt msg "120" parse_Currency (fun msg f_AllocGrp_SettlCurrency -> opt msg "737" parse_float (fun msg f_AllocGrp_AllocSettlCurrAmt -> opt msg "119" parse_float (fun msg f_AllocGrp_SettlCurrAmt -> opt msg "154" parse_float (fun msg f_AllocGrp_AllocNetMoney -> opt msg "153" parse_float (fun msg f_AllocGrp_AllocAvgPx -> opt msg "361" parse_string (fun msg f_AllocGrp_EncodedAllocText -> opt msg "360" parse_int (fun msg f_AllocGrp_EncodedAllocTextLen -> opt msg "161" parse_string (fun msg f_AllocGrp_AllocText -> opt msg "209" parse_AllocHandlInst (fun msg f_AllocGrp_AllocHandlInst -> opt msg "208" parse_NotifyBrokerOfCredit (fun msg f_AllocGrp_NotifyBrokerOfCredit -> opt msg "81" parse_ProcessCode (fun msg f_AllocGrp_ProcessCode -> opt msg "467" parse_string (fun msg f_AllocGrp_IndividualAllocID -> opt msg "80" parse_float (fun msg f_AllocGrp_AllocQty -> opt msg "366" parse_float (fun msg f_AllocGrp_AllocPrice -> opt msg "573" parse_MatchStatus (fun msg f_AllocGrp_MatchStatus -> opt msg "661" parse_int (fun msg f_AllocGrp_AllocAcctIDSource -> opt msg "79" parse_string (fun msg f_AllocGrp_AllocAccount -> block msg parse_SettlInstructionsData (fun msg f_AllocGrp_SettlInstructionsData -> block msg parse_CommissionData (fun msg f_AllocGrp_CommissionData -> repeating msg "576" parse_ClrInstGrp (fun msg f_AllocGrp_ClrInstGrp -> repeating msg "136" parse_MiscFeesGrp (fun msg f_AllocGrp_MiscFeesGrp -> repeating msg "539" parse_NestedParties (fun msg f_AllocGrp_NestedParties -> (ParseSuccess { - f_AllocGrp_NestedParties = f_AllocGrp_NestedParties; - f_AllocGrp_MiscFeesGrp = f_AllocGrp_MiscFeesGrp; - f_AllocGrp_ClrInstGrp = f_AllocGrp_ClrInstGrp; - f_AllocGrp_CommissionData = f_AllocGrp_CommissionData; - f_AllocGrp_SettlInstructionsData = f_AllocGrp_SettlInstructionsData; - f_AllocGrp_NoAllocs = f_AllocGrp_NoAllocs; - f_AllocGrp_AllocAccount = f_AllocGrp_AllocAccount; - f_AllocGrp_AllocAcctIDSource = f_AllocGrp_AllocAcctIDSource; - f_AllocGrp_MatchStatus = f_AllocGrp_MatchStatus; - f_AllocGrp_AllocPrice = f_AllocGrp_AllocPrice; - f_AllocGrp_AllocQty = f_AllocGrp_AllocQty; - f_AllocGrp_IndividualAllocID = f_AllocGrp_IndividualAllocID; - f_AllocGrp_ProcessCode = f_AllocGrp_ProcessCode; - f_AllocGrp_NotifyBrokerOfCredit = f_AllocGrp_NotifyBrokerOfCredit; - f_AllocGrp_AllocHandlInst = f_AllocGrp_AllocHandlInst; - f_AllocGrp_AllocText = f_AllocGrp_AllocText; - f_AllocGrp_EncodedAllocTextLen = f_AllocGrp_EncodedAllocTextLen; - f_AllocGrp_EncodedAllocText = f_AllocGrp_EncodedAllocText; - f_AllocGrp_AllocAvgPx = f_AllocGrp_AllocAvgPx; - f_AllocGrp_AllocNetMoney = f_AllocGrp_AllocNetMoney; - f_AllocGrp_SettlCurrAmt = f_AllocGrp_SettlCurrAmt; - f_AllocGrp_AllocSettlCurrAmt = f_AllocGrp_AllocSettlCurrAmt; - f_AllocGrp_SettlCurrency = f_AllocGrp_SettlCurrency; - f_AllocGrp_AllocSettlCurrency = f_AllocGrp_AllocSettlCurrency; - f_AllocGrp_SettlCurrFxRate = f_AllocGrp_SettlCurrFxRate; - f_AllocGrp_SettlCurrFxRateCalc = f_AllocGrp_SettlCurrFxRateCalc; - f_AllocGrp_AllocAccruedInterestAmt = f_AllocGrp_AllocAccruedInterestAmt; - f_AllocGrp_AllocInterestAtMaturity = f_AllocGrp_AllocInterestAtMaturity; - f_AllocGrp_AllocSettlInstType = f_AllocGrp_AllocSettlInstType +let parse_PtysSubGrp (msg) (f_PtysSubGrp_NoPartySubIDs) = + opt msg "523" parse_string (fun msg f_PtysSubGrp_PartySubID -> (ParseSuccess { + f_PtysSubGrp_NoPartySubIDs = f_PtysSubGrp_NoPartySubIDs; + f_PtysSubGrp_PartySubID = f_PtysSubGrp_PartySubID },msg) ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] ;; -let parse_SettlInstGrp (msg) (f_SettlInstGrp_NoSettlInst) = - opt msg "505" parse_string (fun msg f_SettlInstGrp_PaymentRemitterID -> opt msg "504" parse_LocalMktDate (fun msg f_SettlInstGrp_PaymentDate -> opt msg "491" parse_string (fun msg f_SettlInstGrp_CardIssNum -> opt msg "490" parse_LocalMktDate (fun msg f_SettlInstGrp_CardExpDate -> opt msg "503" parse_LocalMktDate (fun msg f_SettlInstGrp_CardStartDate -> opt msg "489" parse_string (fun msg f_SettlInstGrp_CardNumber -> opt msg "488" parse_string (fun msg f_SettlInstGrp_CardHolderName -> opt msg "476" parse_string (fun msg f_SettlInstGrp_PaymentRef -> opt msg "492" parse_PaymentMethod (fun msg f_SettlInstGrp_PaymentMethod -> opt msg "779" parse_UTCTimestamp_milli (fun msg f_SettlInstGrp_LastUpdateTime -> opt msg "126" parse_UTCTimestamp_milli (fun msg f_SettlInstGrp_ExpireTime -> opt msg "168" parse_UTCTimestamp_milli (fun msg f_SettlInstGrp_EffectiveTime -> opt msg "461" parse_string (fun msg f_SettlInstGrp_CFICode -> opt msg "167" parse_SecurityType (fun msg f_SettlInstGrp_SecurityType -> opt msg "460" parse_Product (fun msg f_SettlInstGrp_Product -> opt msg "54" parse_Side (fun msg f_SettlInstGrp_Side -> opt msg "214" parse_string (fun msg f_SettlInstGrp_SettlInstRefID -> opt msg "163" parse_SettlInstTransType (fun msg f_SettlInstGrp_SettlInstTransType -> opt msg "162" parse_string (fun msg f_SettlInstGrp_SettlInstID -> block msg parse_SettlInstructionsData (fun msg f_SettlInstGrp_SettlInstructionsData -> repeating msg "453" parse_Parties (fun msg f_SettlInstGrp_Parties -> (ParseSuccess { - f_SettlInstGrp_Parties = f_SettlInstGrp_Parties; - f_SettlInstGrp_SettlInstructionsData = f_SettlInstGrp_SettlInstructionsData; - f_SettlInstGrp_NoSettlInst = f_SettlInstGrp_NoSettlInst; - f_SettlInstGrp_SettlInstID = f_SettlInstGrp_SettlInstID; - f_SettlInstGrp_SettlInstTransType = f_SettlInstGrp_SettlInstTransType; - f_SettlInstGrp_SettlInstRefID = f_SettlInstGrp_SettlInstRefID; - f_SettlInstGrp_Side = f_SettlInstGrp_Side; - f_SettlInstGrp_Product = f_SettlInstGrp_Product; - f_SettlInstGrp_SecurityType = f_SettlInstGrp_SecurityType; - f_SettlInstGrp_CFICode = f_SettlInstGrp_CFICode; - f_SettlInstGrp_EffectiveTime = f_SettlInstGrp_EffectiveTime; - f_SettlInstGrp_ExpireTime = f_SettlInstGrp_ExpireTime; - f_SettlInstGrp_LastUpdateTime = f_SettlInstGrp_LastUpdateTime; - f_SettlInstGrp_PaymentMethod = f_SettlInstGrp_PaymentMethod; - f_SettlInstGrp_PaymentRef = f_SettlInstGrp_PaymentRef; - f_SettlInstGrp_CardHolderName = f_SettlInstGrp_CardHolderName; - f_SettlInstGrp_CardNumber = f_SettlInstGrp_CardNumber; - f_SettlInstGrp_CardStartDate = f_SettlInstGrp_CardStartDate; - f_SettlInstGrp_CardExpDate = f_SettlInstGrp_CardExpDate; - f_SettlInstGrp_CardIssNum = f_SettlInstGrp_CardIssNum; - f_SettlInstGrp_PaymentDate = f_SettlInstGrp_PaymentDate; - f_SettlInstGrp_PaymentRemitterID = f_SettlInstGrp_PaymentRemitterID +let parse_Parties (msg) (f_Parties_NoPartyIDs) = + opt msg "10002" parse_int (fun msg f_Parties_PartyIndex -> opt msg "448" parse_string (fun msg f_Parties_PartyID -> repeating msg "802" parse_PtysSubGrp (fun msg f_Parties_PtysSubGrp -> (ParseSuccess { + f_Parties_PtysSubGrp = f_Parties_PtysSubGrp; + f_Parties_NoPartyIDs = f_Parties_NoPartyIDs; + f_Parties_PartyID = f_Parties_PartyID; + f_Parties_PartyIndex = f_Parties_PartyIndex },msg) ) ) ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - ) - [@@macro] ;; [@@@logic] diff --git a/src-protocol-exts-pp/parse_app_tags.iml b/src-protocol-exts-pp/parse_app_tags.iml index 3522e628..cacf4c74 100644 --- a/src-protocol-exts-pp/parse_app_tags.iml +++ b/src-protocol-exts-pp/parse_app_tags.iml @@ -1,392 +1,36 @@ -(* Imandra Inc. copyright 2019 *) -[@@@import "../src-protocol-exts/full_app_tags.iml"] +(* Imandra Inc. copyright 2021 *) [@@@program] +[@@@import "../src-protocol-exts/full_app_tags.iml"] open Full_app_tags;; + let parse_app_msg_tag (tag) = (match tag with - | "8" -> (Some (Full_Msg_ExecutionReport_Tag)) | "D" -> (Some (Full_Msg_NewOrderSingle_Tag)) + | "8" -> (Some (Full_Msg_ExecutionReport_Tag)) | _ -> (None) ) ;; let parse_app_field_tag (tag) = (match tag with - | "37" -> (Some (Full_Field_OrderID_Tag)) - | "198" -> (Some (Full_Field_SecondaryOrderID_Tag)) - | "526" -> (Some (Full_Field_SecondaryClOrdID_Tag)) - | "527" -> (Some (Full_Field_SecondaryExecID_Tag)) | "11" -> (Some (Full_Field_ClOrdID_Tag)) - | "41" -> (Some (Full_Field_OrigClOrdID_Tag)) - | "583" -> (Some (Full_Field_ClOrdLinkID_Tag)) - | "693" -> (Some (Full_Field_QuoteRespID_Tag)) - | "790" -> (Some (Full_Field_OrdStatusReqID_Tag)) - | "584" -> (Some (Full_Field_MassStatusReqID_Tag)) - | "911" -> (Some (Full_Field_TotNumReports_Tag)) - | "912" -> (Some (Full_Field_LastRptRequested_Tag)) - | "229" -> (Some (Full_Field_TradeOriginationDate_Tag)) - | "66" -> (Some (Full_Field_ListID_Tag)) - | "548" -> (Some (Full_Field_CrossID_Tag)) - | "551" -> (Some (Full_Field_OrigCrossID_Tag)) - | "549" -> (Some (Full_Field_CrossType_Tag)) - | "17" -> (Some (Full_Field_ExecID_Tag)) - | "19" -> (Some (Full_Field_ExecRefID_Tag)) - | "150" -> (Some (Full_Field_ExecType_Tag)) - | "39" -> (Some (Full_Field_OrdStatus_Tag)) - | "636" -> (Some (Full_Field_WorkingIndicator_Tag)) - | "103" -> (Some (Full_Field_OrdRejReason_Tag)) - | "378" -> (Some (Full_Field_ExecRestatementReason_Tag)) | "1" -> (Some (Full_Field_Account_Tag)) - | "660" -> (Some (Full_Field_AcctIDSource_Tag)) - | "581" -> (Some (Full_Field_AccountType_Tag)) - | "589" -> (Some (Full_Field_DayBookingInst_Tag)) - | "590" -> (Some (Full_Field_BookingUnit_Tag)) - | "591" -> (Some (Full_Field_PreallocMethod_Tag)) - | "63" -> (Some (Full_Field_SettlType_Tag)) - | "64" -> (Some (Full_Field_SettlDate_Tag)) - | "544" -> (Some (Full_Field_CashMargin_Tag)) - | "635" -> (Some (Full_Field_ClearingFeeIndicator_Tag)) + | "18" -> (Some (Full_Field_ExecInst_Tag)) | "54" -> (Some (Full_Field_Side_Tag)) - | "854" -> (Some (Full_Field_QtyType_Tag)) + | "60" -> (Some (Full_Field_TransactTime_Tag)) | "40" -> (Some (Full_Field_OrdType_Tag)) - | "423" -> (Some (Full_Field_PriceType_Tag)) | "44" -> (Some (Full_Field_Price_Tag)) - | "99" -> (Some (Full_Field_StopPx_Tag)) - | "839" -> (Some (Full_Field_PeggedPrice_Tag)) - | "845" -> (Some (Full_Field_DiscretionPrice_Tag)) - | "847" -> (Some (Full_Field_TargetStrategy_Tag)) - | "848" -> (Some (Full_Field_TargetStrategyParameters_Tag)) - | "849" -> (Some (Full_Field_ParticipationRate_Tag)) - | "850" -> (Some (Full_Field_TargetStrategyPerformance_Tag)) - | "15" -> (Some (Full_Field_Currency_Tag)) - | "376" -> (Some (Full_Field_ComplianceID_Tag)) - | "377" -> (Some (Full_Field_SolicitedFlag_Tag)) - | "59" -> (Some (Full_Field_TimeInForce_Tag)) - | "168" -> (Some (Full_Field_EffectiveTime_Tag)) - | "432" -> (Some (Full_Field_ExpireDate_Tag)) - | "126" -> (Some (Full_Field_ExpireTime_Tag)) - | "18" -> (Some (Full_Field_ExecInst_Tag)) - | "528" -> (Some (Full_Field_OrderCapacity_Tag)) - | "529" -> (Some (Full_Field_OrderRestrictions_Tag)) - | "582" -> (Some (Full_Field_CustOrderCapacity_Tag)) - | "32" -> (Some (Full_Field_LastQty_Tag)) - | "652" -> (Some (Full_Field_UnderlyingLastQty_Tag)) - | "31" -> (Some (Full_Field_LastPx_Tag)) - | "651" -> (Some (Full_Field_UnderlyingLastPx_Tag)) - | "669" -> (Some (Full_Field_LastParPx_Tag)) - | "194" -> (Some (Full_Field_LastSpotRate_Tag)) - | "195" -> (Some (Full_Field_LastForwardPoints_Tag)) - | "30" -> (Some (Full_Field_LastMkt_Tag)) - | "336" -> (Some (Full_Field_TradingSessionID_Tag)) - | "625" -> (Some (Full_Field_TradingSessionSubID_Tag)) - | "943" -> (Some (Full_Field_TimeBracket_Tag)) - | "29" -> (Some (Full_Field_LastCapacity_Tag)) + | "10001" -> (Some (Full_Field_SpreadProportion_Tag)) + | "37" -> (Some (Full_Field_OrderID_Tag)) + | "17" -> (Some (Full_Field_ExecID_Tag)) + | "150" -> (Some (Full_Field_ExecType_Tag)) + | "39" -> (Some (Full_Field_OrdStatus_Tag)) | "151" -> (Some (Full_Field_LeavesQty_Tag)) | "14" -> (Some (Full_Field_CumQty_Tag)) - | "6" -> (Some (Full_Field_AvgPx_Tag)) - | "424" -> (Some (Full_Field_DayOrderQty_Tag)) - | "425" -> (Some (Full_Field_DayCumQty_Tag)) - | "426" -> (Some (Full_Field_DayAvgPx_Tag)) - | "427" -> (Some (Full_Field_GTBookingInst_Tag)) - | "75" -> (Some (Full_Field_TradeDate_Tag)) - | "60" -> (Some (Full_Field_TransactTime_Tag)) - | "113" -> (Some (Full_Field_ReportToExch_Tag)) - | "381" -> (Some (Full_Field_GrossTradeAmt_Tag)) - | "157" -> (Some (Full_Field_NumDaysInterest_Tag)) - | "230" -> (Some (Full_Field_ExDate_Tag)) - | "158" -> (Some (Full_Field_AccruedInterestRate_Tag)) - | "159" -> (Some (Full_Field_AccruedInterestAmt_Tag)) - | "738" -> (Some (Full_Field_InterestAtMaturity_Tag)) - | "920" -> (Some (Full_Field_EndAccruedInterestAmt_Tag)) - | "921" -> (Some (Full_Field_StartCash_Tag)) - | "922" -> (Some (Full_Field_EndCash_Tag)) - | "258" -> (Some (Full_Field_TradedFlatSwitch_Tag)) - | "259" -> (Some (Full_Field_BasisFeatureDate_Tag)) - | "260" -> (Some (Full_Field_BasisFeaturePrice_Tag)) - | "238" -> (Some (Full_Field_Concession_Tag)) - | "237" -> (Some (Full_Field_TotalTakedown_Tag)) - | "118" -> (Some (Full_Field_NetMoney_Tag)) - | "119" -> (Some (Full_Field_SettlCurrAmt_Tag)) - | "120" -> (Some (Full_Field_SettlCurrency_Tag)) - | "155" -> (Some (Full_Field_SettlCurrFxRate_Tag)) - | "156" -> (Some (Full_Field_SettlCurrFxRateCalc_Tag)) - | "21" -> (Some (Full_Field_HandlInst_Tag)) - | "110" -> (Some (Full_Field_MinQty_Tag)) - | "111" -> (Some (Full_Field_MaxFloor_Tag)) - | "77" -> (Some (Full_Field_PositionEffect_Tag)) - | "210" -> (Some (Full_Field_MaxShow_Tag)) - | "775" -> (Some (Full_Field_BookingType_Tag)) | "58" -> (Some (Full_Field_Text_Tag)) - | "354" -> (Some (Full_Field_EncodedTextLen_Tag)) - | "355" -> (Some (Full_Field_EncodedText_Tag)) - | "193" -> (Some (Full_Field_SettlDate2_Tag)) - | "192" -> (Some (Full_Field_OrderQty2_Tag)) - | "641" -> (Some (Full_Field_LastForwardPoints2_Tag)) - | "442" -> (Some (Full_Field_MultiLegReportingType_Tag)) - | "480" -> (Some (Full_Field_CancellationRights_Tag)) - | "481" -> (Some (Full_Field_MoneyLaunderingStatus_Tag)) - | "513" -> (Some (Full_Field_RegistID_Tag)) - | "494" -> (Some (Full_Field_Designation_Tag)) - | "483" -> (Some (Full_Field_TransBkdTime_Tag)) - | "515" -> (Some (Full_Field_ExecValuationPoint_Tag)) - | "484" -> (Some (Full_Field_ExecPriceType_Tag)) - | "485" -> (Some (Full_Field_ExecPriceAdjustment_Tag)) - | "638" -> (Some (Full_Field_PriorityIndicator_Tag)) - | "639" -> (Some (Full_Field_PriceImprovement_Tag)) - | "851" -> (Some (Full_Field_LastLiquidityInd_Tag)) - | "797" -> (Some (Full_Field_CopyMsgIndicator_Tag)) - | "453" -> (Some (Full_Field_NoPartyIDs_Tag)) - | "448" -> (Some (Full_Field_PartyID_Tag)) - | "447" -> (Some (Full_Field_PartyIDSource_Tag)) - | "452" -> (Some (Full_Field_PartyRole_Tag)) - | "802" -> (Some (Full_Field_NoPartySubIDs_Tag)) - | "523" -> (Some (Full_Field_PartySubID_Tag)) - | "803" -> (Some (Full_Field_PartySubIDType_Tag)) - | "382" -> (Some (Full_Field_NoContraBrokers_Tag)) - | "375" -> (Some (Full_Field_ContraBroker_Tag)) - | "337" -> (Some (Full_Field_ContraTrader_Tag)) - | "437" -> (Some (Full_Field_ContraTradeQty_Tag)) - | "438" -> (Some (Full_Field_ContraTradeTime_Tag)) - | "655" -> (Some (Full_Field_ContraLegRefID_Tag)) - | "55" -> (Some (Full_Field_Symbol_Tag)) - | "65" -> (Some (Full_Field_SymbolSfx_Tag)) - | "48" -> (Some (Full_Field_SecurityID_Tag)) - | "22" -> (Some (Full_Field_SecurityIDSource_Tag)) - | "460" -> (Some (Full_Field_Product_Tag)) - | "461" -> (Some (Full_Field_CFICode_Tag)) - | "167" -> (Some (Full_Field_SecurityType_Tag)) - | "762" -> (Some (Full_Field_SecuritySubType_Tag)) - | "200" -> (Some (Full_Field_MaturityMonthYear_Tag)) - | "541" -> (Some (Full_Field_MaturityDate_Tag)) - | "224" -> (Some (Full_Field_CouponPaymentDate_Tag)) - | "225" -> (Some (Full_Field_IssueDate_Tag)) - | "239" -> (Some (Full_Field_RepoCollateralSecurityType_Tag)) - | "226" -> (Some (Full_Field_RepurchaseTerm_Tag)) - | "227" -> (Some (Full_Field_RepurchaseRate_Tag)) - | "228" -> (Some (Full_Field_Factor_Tag)) - | "255" -> (Some (Full_Field_CreditRating_Tag)) - | "543" -> (Some (Full_Field_InstrRegistry_Tag)) - | "470" -> (Some (Full_Field_CountryOfIssue_Tag)) - | "471" -> (Some (Full_Field_StateOrProvinceOfIssue_Tag)) - | "472" -> (Some (Full_Field_LocaleOfIssue_Tag)) - | "240" -> (Some (Full_Field_RedemptionDate_Tag)) - | "202" -> (Some (Full_Field_StrikePrice_Tag)) - | "947" -> (Some (Full_Field_StrikeCurrency_Tag)) - | "206" -> (Some (Full_Field_OptAttribute_Tag)) - | "231" -> (Some (Full_Field_ContractMultiplier_Tag)) - | "223" -> (Some (Full_Field_CouponRate_Tag)) - | "207" -> (Some (Full_Field_SecurityExchange_Tag)) - | "106" -> (Some (Full_Field_Issuer_Tag)) - | "348" -> (Some (Full_Field_EncodedIssuerLen_Tag)) - | "349" -> (Some (Full_Field_EncodedIssuer_Tag)) - | "107" -> (Some (Full_Field_SecurityDesc_Tag)) - | "350" -> (Some (Full_Field_EncodedSecurityDescLen_Tag)) - | "351" -> (Some (Full_Field_EncodedSecurityDesc_Tag)) - | "691" -> (Some (Full_Field_Pool_Tag)) - | "667" -> (Some (Full_Field_ContractSettlMonth_Tag)) - | "875" -> (Some (Full_Field_CPProgram_Tag)) - | "876" -> (Some (Full_Field_CPRegType_Tag)) - | "873" -> (Some (Full_Field_DatedDate_Tag)) - | "874" -> (Some (Full_Field_InterestAccrualDate_Tag)) - | "454" -> (Some (Full_Field_NoSecurityAltID_Tag)) - | "455" -> (Some (Full_Field_SecurityAltID_Tag)) - | "456" -> (Some (Full_Field_SecurityAltIDSource_Tag)) - | "864" -> (Some (Full_Field_NoEvents_Tag)) - | "865" -> (Some (Full_Field_EventType_Tag)) - | "866" -> (Some (Full_Field_EventDate_Tag)) - | "867" -> (Some (Full_Field_EventPx_Tag)) - | "868" -> (Some (Full_Field_EventText_Tag)) - | "913" -> (Some (Full_Field_AgreementDesc_Tag)) - | "914" -> (Some (Full_Field_AgreementID_Tag)) - | "915" -> (Some (Full_Field_AgreementDate_Tag)) - | "918" -> (Some (Full_Field_AgreementCurrency_Tag)) - | "788" -> (Some (Full_Field_TerminationType_Tag)) - | "916" -> (Some (Full_Field_StartDate_Tag)) - | "917" -> (Some (Full_Field_EndDate_Tag)) - | "919" -> (Some (Full_Field_DeliveryType_Tag)) - | "898" -> (Some (Full_Field_MarginRatio_Tag)) - | "711" -> (Some (Full_Field_NoUnderlyings_Tag)) - | "311" -> (Some (Full_Field_UnderlyingSymbol_Tag)) - | "312" -> (Some (Full_Field_UnderlyingSymbolSfx_Tag)) - | "309" -> (Some (Full_Field_UnderlyingSecurityID_Tag)) - | "305" -> (Some (Full_Field_UnderlyingSecurityIDSource_Tag)) - | "462" -> (Some (Full_Field_UnderlyingProduct_Tag)) - | "463" -> (Some (Full_Field_UnderlyingCFICode_Tag)) - | "310" -> (Some (Full_Field_UnderlyingSecurityType_Tag)) - | "763" -> (Some (Full_Field_UnderlyingSecuritySubType_Tag)) - | "313" -> (Some (Full_Field_UnderlyingMaturityMonthYear_Tag)) - | "542" -> (Some (Full_Field_UnderlyingMaturityDate_Tag)) - | "241" -> (Some (Full_Field_UnderlyingCouponPaymentDate_Tag)) - | "242" -> (Some (Full_Field_UnderlyingIssueDate_Tag)) - | "243" -> (Some (Full_Field_UnderlyingRepoCollateralSecurityType_Tag)) - | "244" -> (Some (Full_Field_UnderlyingRepurchaseTerm_Tag)) - | "245" -> (Some (Full_Field_UnderlyingRepurchaseRate_Tag)) - | "246" -> (Some (Full_Field_UnderlyingFactor_Tag)) - | "256" -> (Some (Full_Field_UnderlyingCreditRating_Tag)) - | "595" -> (Some (Full_Field_UnderlyingInstrRegistry_Tag)) - | "592" -> (Some (Full_Field_UnderlyingCountryOfIssue_Tag)) - | "593" -> (Some (Full_Field_UnderlyingStateOrProvinceOfIssue_Tag)) - | "594" -> (Some (Full_Field_UnderlyingLocaleOfIssue_Tag)) - | "247" -> (Some (Full_Field_UnderlyingRedemptionDate_Tag)) - | "316" -> (Some (Full_Field_UnderlyingStrikePrice_Tag)) - | "941" -> (Some (Full_Field_UnderlyingStrikeCurrency_Tag)) - | "317" -> (Some (Full_Field_UnderlyingOptAttribute_Tag)) - | "436" -> (Some (Full_Field_UnderlyingContractMultiplier_Tag)) - | "435" -> (Some (Full_Field_UnderlyingCouponRate_Tag)) - | "308" -> (Some (Full_Field_UnderlyingSecurityExchange_Tag)) - | "306" -> (Some (Full_Field_UnderlyingIssuer_Tag)) - | "362" -> (Some (Full_Field_EncodedUnderlyingIssuerLen_Tag)) - | "363" -> (Some (Full_Field_EncodedUnderlyingIssuer_Tag)) - | "307" -> (Some (Full_Field_UnderlyingSecurityDesc_Tag)) - | "364" -> (Some (Full_Field_EncodedUnderlyingSecurityDescLen_Tag)) - | "365" -> (Some (Full_Field_EncodedUnderlyingSecurityDesc_Tag)) - | "877" -> (Some (Full_Field_UnderlyingCPProgram_Tag)) - | "878" -> (Some (Full_Field_UnderlyingCPRegType_Tag)) - | "318" -> (Some (Full_Field_UnderlyingCurrency_Tag)) - | "879" -> (Some (Full_Field_UnderlyingQty_Tag)) - | "810" -> (Some (Full_Field_UnderlyingPx_Tag)) - | "882" -> (Some (Full_Field_UnderlyingDirtyPrice_Tag)) - | "883" -> (Some (Full_Field_UnderlyingEndPrice_Tag)) - | "884" -> (Some (Full_Field_UnderlyingStartValue_Tag)) - | "885" -> (Some (Full_Field_UnderlyingCurrentValue_Tag)) - | "886" -> (Some (Full_Field_UnderlyingEndValue_Tag)) - | "457" -> (Some (Full_Field_NoUnderlyingSecurityAltID_Tag)) - | "458" -> (Some (Full_Field_UnderlyingSecurityAltID_Tag)) - | "459" -> (Some (Full_Field_UnderlyingSecurityAltIDSource_Tag)) - | "887" -> (Some (Full_Field_NoUnderlyingStips_Tag)) - | "888" -> (Some (Full_Field_UnderlyingStipType_Tag)) - | "889" -> (Some (Full_Field_UnderlyingStipValue_Tag)) - | "232" -> (Some (Full_Field_NoStipulations_Tag)) - | "233" -> (Some (Full_Field_StipulationType_Tag)) - | "234" -> (Some (Full_Field_StipulationValue_Tag)) - | "38" -> (Some (Full_Field_OrderQty_Tag)) - | "152" -> (Some (Full_Field_CashOrderQty_Tag)) - | "516" -> (Some (Full_Field_OrderPercent_Tag)) - | "468" -> (Some (Full_Field_RoundingDirection_Tag)) - | "469" -> (Some (Full_Field_RoundingModulus_Tag)) - | "211" -> (Some (Full_Field_PegOffsetValue_Tag)) - | "835" -> (Some (Full_Field_PegMoveType_Tag)) - | "836" -> (Some (Full_Field_PegOffsetType_Tag)) - | "837" -> (Some (Full_Field_PegLimitType_Tag)) - | "838" -> (Some (Full_Field_PegRoundDirection_Tag)) - | "840" -> (Some (Full_Field_PegScope_Tag)) - | "388" -> (Some (Full_Field_DiscretionInst_Tag)) - | "389" -> (Some (Full_Field_DiscretionOffsetValue_Tag)) - | "841" -> (Some (Full_Field_DiscretionMoveType_Tag)) - | "842" -> (Some (Full_Field_DiscretionOffsetType_Tag)) - | "843" -> (Some (Full_Field_DiscretionLimitType_Tag)) - | "844" -> (Some (Full_Field_DiscretionRoundDirection_Tag)) - | "846" -> (Some (Full_Field_DiscretionScope_Tag)) - | "12" -> (Some (Full_Field_Commission_Tag)) - | "13" -> (Some (Full_Field_CommType_Tag)) - | "479" -> (Some (Full_Field_CommCurrency_Tag)) - | "497" -> (Some (Full_Field_FundRenewWaiv_Tag)) - | "218" -> (Some (Full_Field_Spread_Tag)) - | "220" -> (Some (Full_Field_BenchmarkCurveCurrency_Tag)) - | "221" -> (Some (Full_Field_BenchmarkCurveName_Tag)) - | "222" -> (Some (Full_Field_BenchmarkCurvePoint_Tag)) - | "662" -> (Some (Full_Field_BenchmarkPrice_Tag)) - | "663" -> (Some (Full_Field_BenchmarkPriceType_Tag)) - | "699" -> (Some (Full_Field_BenchmarkSecurityID_Tag)) - | "761" -> (Some (Full_Field_BenchmarkSecurityIDSource_Tag)) - | "235" -> (Some (Full_Field_YieldType_Tag)) - | "236" -> (Some (Full_Field_Yield_Tag)) - | "701" -> (Some (Full_Field_YieldCalcDate_Tag)) - | "696" -> (Some (Full_Field_YieldRedemptionDate_Tag)) - | "697" -> (Some (Full_Field_YieldRedemptionPrice_Tag)) - | "698" -> (Some (Full_Field_YieldRedemptionPriceType_Tag)) - | "518" -> (Some (Full_Field_NoContAmts_Tag)) - | "519" -> (Some (Full_Field_ContAmtType_Tag)) - | "520" -> (Some (Full_Field_ContAmtValue_Tag)) - | "521" -> (Some (Full_Field_ContAmtCurr_Tag)) - | "555" -> (Some (Full_Field_NoLegs_Tag)) - | "687" -> (Some (Full_Field_LegQty_Tag)) - | "690" -> (Some (Full_Field_LegSwapType_Tag)) - | "564" -> (Some (Full_Field_LegPositionEffect_Tag)) - | "565" -> (Some (Full_Field_LegCoveredOrUncovered_Tag)) - | "654" -> (Some (Full_Field_LegRefID_Tag)) - | "566" -> (Some (Full_Field_LegPrice_Tag)) - | "587" -> (Some (Full_Field_LegSettlType_Tag)) - | "588" -> (Some (Full_Field_LegSettlDate_Tag)) - | "637" -> (Some (Full_Field_LegLastPx_Tag)) - | "600" -> (Some (Full_Field_LegSymbol_Tag)) - | "601" -> (Some (Full_Field_LegSymbolSfx_Tag)) - | "602" -> (Some (Full_Field_LegSecurityID_Tag)) - | "603" -> (Some (Full_Field_LegSecurityIDSource_Tag)) - | "607" -> (Some (Full_Field_LegProduct_Tag)) - | "608" -> (Some (Full_Field_LegCFICode_Tag)) - | "609" -> (Some (Full_Field_LegSecurityType_Tag)) - | "764" -> (Some (Full_Field_LegSecuritySubType_Tag)) - | "610" -> (Some (Full_Field_LegMaturityMonthYear_Tag)) - | "611" -> (Some (Full_Field_LegMaturityDate_Tag)) - | "248" -> (Some (Full_Field_LegCouponPaymentDate_Tag)) - | "249" -> (Some (Full_Field_LegIssueDate_Tag)) - | "250" -> (Some (Full_Field_LegRepoCollateralSecurityType_Tag)) - | "251" -> (Some (Full_Field_LegRepurchaseTerm_Tag)) - | "252" -> (Some (Full_Field_LegRepurchaseRate_Tag)) - | "253" -> (Some (Full_Field_LegFactor_Tag)) - | "257" -> (Some (Full_Field_LegCreditRating_Tag)) - | "599" -> (Some (Full_Field_LegInstrRegistry_Tag)) - | "596" -> (Some (Full_Field_LegCountryOfIssue_Tag)) - | "597" -> (Some (Full_Field_LegStateOrProvinceOfIssue_Tag)) - | "598" -> (Some (Full_Field_LegLocaleOfIssue_Tag)) - | "254" -> (Some (Full_Field_LegRedemptionDate_Tag)) - | "612" -> (Some (Full_Field_LegStrikePrice_Tag)) - | "942" -> (Some (Full_Field_LegStrikeCurrency_Tag)) - | "613" -> (Some (Full_Field_LegOptAttribute_Tag)) - | "614" -> (Some (Full_Field_LegContractMultiplier_Tag)) - | "615" -> (Some (Full_Field_LegCouponRate_Tag)) - | "616" -> (Some (Full_Field_LegSecurityExchange_Tag)) - | "617" -> (Some (Full_Field_LegIssuer_Tag)) - | "618" -> (Some (Full_Field_EncodedLegIssuerLen_Tag)) - | "619" -> (Some (Full_Field_EncodedLegIssuer_Tag)) - | "620" -> (Some (Full_Field_LegSecurityDesc_Tag)) - | "621" -> (Some (Full_Field_EncodedLegSecurityDescLen_Tag)) - | "622" -> (Some (Full_Field_EncodedLegSecurityDesc_Tag)) - | "623" -> (Some (Full_Field_LegRatioQty_Tag)) - | "624" -> (Some (Full_Field_LegSide_Tag)) - | "556" -> (Some (Full_Field_LegCurrency_Tag)) - | "740" -> (Some (Full_Field_LegPool_Tag)) - | "739" -> (Some (Full_Field_LegDatedDate_Tag)) - | "955" -> (Some (Full_Field_LegContractSettlMonth_Tag)) - | "956" -> (Some (Full_Field_LegInterestAccrualDate_Tag)) - | "604" -> (Some (Full_Field_NoLegSecurityAltID_Tag)) - | "605" -> (Some (Full_Field_LegSecurityAltID_Tag)) - | "606" -> (Some (Full_Field_LegSecurityAltIDSource_Tag)) - | "683" -> (Some (Full_Field_NoLegStipulations_Tag)) - | "688" -> (Some (Full_Field_LegStipulationType_Tag)) - | "689" -> (Some (Full_Field_LegStipulationValue_Tag)) - | "539" -> (Some (Full_Field_NoNestedPartyIDs_Tag)) - | "524" -> (Some (Full_Field_NestedPartyID_Tag)) - | "525" -> (Some (Full_Field_NestedPartyIDSource_Tag)) - | "538" -> (Some (Full_Field_NestedPartyRole_Tag)) - | "804" -> (Some (Full_Field_NoNestedPartySubIDs_Tag)) - | "545" -> (Some (Full_Field_NestedPartySubID_Tag)) - | "805" -> (Some (Full_Field_NestedPartySubIDType_Tag)) - | "136" -> (Some (Full_Field_NoMiscFees_Tag)) - | "137" -> (Some (Full_Field_MiscFeeAmt_Tag)) - | "138" -> (Some (Full_Field_MiscFeeCurr_Tag)) - | "139" -> (Some (Full_Field_MiscFeeType_Tag)) - | "891" -> (Some (Full_Field_MiscFeeBasis_Tag)) - | "70" -> (Some (Full_Field_AllocID_Tag)) - | "100" -> (Some (Full_Field_ExDestination_Tag)) - | "81" -> (Some (Full_Field_ProcessCode_Tag)) - | "140" -> (Some (Full_Field_PrevClosePx_Tag)) - | "114" -> (Some (Full_Field_LocateReqd_Tag)) - | "23" -> (Some (Full_Field_IOIID_Tag)) - | "117" -> (Some (Full_Field_QuoteID_Tag)) - | "121" -> (Some (Full_Field_ForexReq_Tag)) - | "640" -> (Some (Full_Field_Price2_Tag)) - | "203" -> (Some (Full_Field_CoveredOrUncovered_Tag)) - | "78" -> (Some (Full_Field_NoAllocs_Tag)) - | "79" -> (Some (Full_Field_AllocAccount_Tag)) - | "661" -> (Some (Full_Field_AllocAcctIDSource_Tag)) - | "736" -> (Some (Full_Field_AllocSettlCurrency_Tag)) - | "467" -> (Some (Full_Field_IndividualAllocID_Tag)) - | "80" -> (Some (Full_Field_AllocQty_Tag)) - | "386" -> (Some (Full_Field_NoTradingSessions_Tag)) | _ -> (None) ) ;; + [@@@logic] diff --git a/src-protocol-exts/dune b/src-protocol-exts/dune index d22fd393..7c835346 100644 --- a/src-protocol-exts/dune +++ b/src-protocol-exts/dune @@ -1,7 +1,7 @@ (library - (name protocol_exts) - (public_name fix-engine.protocol_exts) - (wrapped false) - (flags - (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) - (libraries imandra-prelude core)) + (name protocol_exts) + (public_name fix-engine.protocol_exts) + (wrapped false) + (flags (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) + (libraries imandra-prelude core core_time_defaults) +) diff --git a/src-protocol-exts/full_app_enums.iml b/src-protocol-exts/full_app_enums.iml index 958a7680..fd6d70c6 100644 --- a/src-protocol-exts/full_app_enums.iml +++ b/src-protocol-exts/full_app_enums.iml @@ -1,683 +1,9 @@ -(* Imandra Inc. copyright 2019 *) +(* Imandra Inc. copyright 2021 *) -type fix_week = - | FIX_week_noweek - | FIX_week_w1 - | FIX_week_w2 - | FIX_week_w3 - | FIX_week_w4 - | FIX_week_w5 -;; - -(** Type of account associated with an order*) -type fix_accounttype = - | FIX_AccountType_CarriedCustomerSide - | FIX_AccountType_CarriedNonCustomerSide - | FIX_AccountType_HouseTrader - | FIX_AccountType_FloorTrader - | FIX_AccountType_CarriedNonCustomerSideCrossMargined - | FIX_AccountType_HouseTraderCrossMargined - | FIX_AccountType_JointBackOfficeAccount -;; - -(** Used to identify the source of the Account (1) code. This is especially useful if the account is a new account that the Respondent may not have setup yet in their system.*) -type fix_acctidsource = - | FIX_AcctIDSource_BIC - | FIX_AcctIDSource_SIDCode - | FIX_AcctIDSource_TFM - | FIX_AcctIDSource_OMGEO - | FIX_AcctIDSource_DTCCCode - | FIX_AcctIDSource_Other -;; - -(** Identifies the type of adjustment*) -type fix_adjustment = - | FIX_Adjustment_Cancel - | FIX_Adjustment_Error - | FIX_Adjustment_Correction -;; - -(** Type of adjustment to be applied, used for PCS & PAJ*) -type fix_adjustmenttype = - | FIX_AdjustmentType_ProcessRequestAsMarginDisposition - | FIX_AdjustmentType_DeltaPlus - | FIX_AdjustmentType_DeltaMinus - | FIX_AdjustmentType_Final -;; - -(** Broker's side of advertised trade*) -type fix_advside = - | FIX_AdvSide_Buy - | FIX_AdvSide_Sell - | FIX_AdvSide_Cross - | FIX_AdvSide_Trade -;; - -(** Identifies advertisement message transaction type*) -type fix_advtranstype = - | FIX_AdvTransType_New - | FIX_AdvTransType_Cancel - | FIX_AdvTransType_Replace -;; - -(** Identifies the status of the ConfirmationAck*) -type fix_affirmstatus = - | FIX_AffirmStatus_Received - | FIX_AffirmStatus_ConfirmRejected - | FIX_AffirmStatus_Affirmed -;; - -(** Specifies whether or not book entries should be aggregated.*) -type fix_aggregatedbook = - | FIX_AggregatedBook_BookEntriesToBeAggregated - | FIX_AggregatedBook_BookEntriesShouldNotBeAggregated -;; - -(** Type of account associated with a confirmation or other trade-level message*) -type fix_allocaccounttype = - | FIX_AllocAccountType_CarriedCustomerSide - | FIX_AllocAccountType_CarriedNonCustomerSide - | FIX_AllocAccountType_HouseTrader - | FIX_AllocAccountType_FloorTrader - | FIX_AllocAccountType_CarriedNonCustomerSideCrossMargined - | FIX_AllocAccountType_HouseTraderCrossMargined - | FIX_AllocAccountType_JointBackOfficeAccount -;; - -(** Reason for cancelling or replacing an Allocation Instruction or Allocation Report message*) -type fix_alloccancreplacereason = - | FIX_AllocCancReplaceReason_OriginalDetailsIncomplete - | FIX_AllocCancReplaceReason_ChangeInUnderlyingOrderDetails - | FIX_AllocCancReplaceReason_Other -;; - -(** Indicates how the receiver (i.e. third party) of Allocation message should handle/process the account details*) -type fix_allochandlinst = - | FIX_AllocHandlInst_Match - | FIX_AllocHandlInst_Forward - | FIX_AllocHandlInst_ForwardAndMatch -;; - -(** Response to allocation to be communicated to a counterparty through an intermediary, i.e. clearing house. Used in conjunction with AllocType = "Request to Intermediary" and AllocReportType = "Request to Intermediary"*) -type fix_allocintermedreqtype = - | FIX_AllocIntermedReqType_PendingAccept - | FIX_AllocIntermedReqType_PendingRelease - | FIX_AllocIntermedReqType_PendingReversal - | FIX_AllocIntermedReqType_Accept - | FIX_AllocIntermedReqType_BlockLevelReject - | FIX_AllocIntermedReqType_AccountLevelReject -;; - -(** Identifies the type of Allocation linkage when AllocLinkID (96) is used.*) -type fix_alloclinktype = - | FIX_AllocLinkType_FXNetting - | FIX_AllocLinkType_FXSwap -;; - -(** Indicates how the orders being booked and allocated by an Allocation Instruction or Allocation Report message are identified, i.e. by explicit definition in the NoOrders group or not.*) -type fix_allocnoorderstype = - | FIX_AllocNoOrdersType_NotSpecified - | FIX_AllocNoOrdersType_ExplicitListProvided -;; - -(** Identifies reason for rejection*) -type fix_allocrejcode = - | FIX_AllocRejCode_UnknownAccount - | FIX_AllocRejCode_IncorrectQuantity - | FIX_AllocRejCode_IncorrectAveragegPrice - | FIX_AllocRejCode_UnknownExecutingBrokerMnemonic - | FIX_AllocRejCode_CommissionDifference - | FIX_AllocRejCode_UnknownOrderID - | FIX_AllocRejCode_UnknownListID - | FIX_AllocRejCode_OtherSeeText - | FIX_AllocRejCode_IncorrectAllocatedQuantity - | FIX_AllocRejCode_CalculationDifference - | FIX_AllocRejCode_UnknownOrStaleExecID - | FIX_AllocRejCode_MismatchedData - | FIX_AllocRejCode_UnknownClOrdID - | FIX_AllocRejCode_WarehouseRequestRejected -;; - -(** Describes the specific type or purpose of an Allocation Report message*) -type fix_allocreporttype = - | FIX_AllocReportType_SellsideCalculatedUsingPreliminary - | FIX_AllocReportType_SellsideCalculatedWithoutPreliminary - | FIX_AllocReportType_WarehouseRecap - | FIX_AllocReportType_RequestToIntermediary -;; - -(** Used to indicate whether settlement instructions are provided on an allocation instruction message, and if not, how they are to be derived*) -type fix_allocsettlinsttype = - | FIX_AllocSettlInstType_UseDefaultInstructions - | FIX_AllocSettlInstType_DeriveFromParametersProvided - | FIX_AllocSettlInstType_FullDetailsProvided - | FIX_AllocSettlInstType_SSIDBIDsProvided - | FIX_AllocSettlInstType_PhoneForInstructions -;; - -(** Identifies status of allocation*) -type fix_allocstatus = - | FIX_AllocStatus_Accepted - | FIX_AllocStatus_BlockLevelReject - | FIX_AllocStatus_AccountLevelReject - | FIX_AllocStatus_Received - | FIX_AllocStatus_Incomplete - | FIX_AllocStatus_RejectedByIntermediary -;; - -(** Identifies allocation transaction type - *** SOME VALUES HAVE BEEN REPLACED - See "Replaced Features and Supported Approach" ****) -type fix_alloctranstype = - | FIX_AllocTransType_New - | FIX_AllocTransType_Replace - | FIX_AllocTransType_Cancel -;; - -(** Describes the specific type or purpose of an Allocation message (i.e. "Buyside Calculated")*) -type fix_alloctype = - | FIX_AllocType_Calculated - | FIX_AllocType_Preliminary - | FIX_AllocType_ReadyToBook - | FIX_AllocType_WarehouseInstruction - | FIX_AllocType_RequestToIntermediary -;; - -(** Action to take to resolve an application message queue (backlog).*) -type fix_applqueueaction = - | FIX_ApplQueueAction_NoActionTaken - | FIX_ApplQueueAction_QueueFlushed - | FIX_ApplQueueAction_OverlayLast - | FIX_ApplQueueAction_EndSession -;; - -(** Resolution taken when ApplQueueDepth (813) exceeds ApplQueueMax (812) or system specified maximum queue size.*) -type fix_applqueueresolution = - | FIX_ApplQueueResolution_NoActionTaken - | FIX_ApplQueueResolution_QueueFlushed - | FIX_ApplQueueResolution_OverlayLast - | FIX_ApplQueueResolution_EndSession -;; - -(** Method under which assignment was conducted*) -type fix_assignmentmethod = - | FIX_AssignmentMethod_Random - | FIX_AssignmentMethod_ProRata -;; - -(** Average Pricing Indicator*) -type fix_avgpxindicator = - | FIX_AvgPxIndicator_NoAveragePricing - | FIX_AvgPxIndicator_Trade - | FIX_AvgPxIndicator_LastTrade -;; - -(** Code to represent the basis price type*) -type fix_basispxtype = - | FIX_BasisPxType_ClosingPriceAtMorningSession - | FIX_BasisPxType_ClosingPrice - | FIX_BasisPxType_CurrentPrice - | FIX_BasisPxType_SQ - | FIX_BasisPxType_VWAPThroughADay - | FIX_BasisPxType_VWAPThroughAMorningSession - | FIX_BasisPxType_VWAPThroughAnAfternoonSession - | FIX_BasisPxType_VWAPThroughADayExcept - | FIX_BasisPxType_VWAPThroughAMorningSessionExcept - | FIX_BasisPxType_VWAPThroughAnAfternoonSessionExcept - | FIX_BasisPxType_Strike - | FIX_BasisPxType_Open - | FIX_BasisPxType_Others -;; - -(** Code to identify the type of BidDescriptor (400)*) -type fix_biddescriptortype = - | FIX_BidDescriptorType_Sector - | FIX_BidDescriptorType_Country - | FIX_BidDescriptorType_Index -;; - -(** Identifies the Bid Request message type*) -type fix_bidrequesttranstype = - | FIX_BidRequestTransType_New - | FIX_BidRequestTransType_Cancel -;; - -(** Code to represent the type of trade*) -type fix_bidtradetype = - | FIX_BidTradeType_RiskTrade - | FIX_BidTradeType_VWAPGuarantee - | FIX_BidTradeType_Agency - | FIX_BidTradeType_GuaranteedClose -;; - -(** Code to identify the type of Bid Request*) -type fix_bidtype = - | FIX_BidType_NonDisclosed - | FIX_BidType_Disclosed - | FIX_BidType_NoBiddingProcess -;; - -(** Method for booking out this order. Used when notifying a broker that an order to be settled by that broker is to be booked out as an OTC derivative (e.g. CFD or similar).*) -type fix_bookingtype = - | FIX_BookingType_RegularBooking - | FIX_BookingType_CFD - | FIX_BookingType_TotalReturnSwap -;; - -(** Indicates what constitutes a bookable unit.*) -type fix_bookingunit = - | FIX_BookingUnit_EachPartialExecutionIsABookableUnit - | FIX_BookingUnit_AggregatePartialExecutionsOnThisOrder - | FIX_BookingUnit_AggregateExecutionsForThisSymbol -;; - -(** The program under which a commercial paper is issued*) -type fix_cpprogram = - | FIX_CPProgram_Program3a3 - | FIX_CPProgram_Program42 - | FIX_CPProgram_Other -;; - -(** For CIV – A one character code identifying whether Cancellation rights/Cooling off period applies*) -type fix_cancellationrights = - | FIX_CancellationRights_Yes - | FIX_CancellationRights_NoExecutionOnly - | FIX_CancellationRights_NoWaiverAgreement - | FIX_CancellationRights_NoInstitutional -;; - -(** Identifies whether an order is a margin order or a non-margin order. This is primarily used when sending orders to Japanese exchanges to indicate sell margin or buy to cover. The same tag could be assigned also by buy-side to indicate the intent to sell or buy margin and the sell-side to accept or reject (base on some validation criteria) the margin request.*) -type fix_cashmargin = - | FIX_CashMargin_Cash - | FIX_CashMargin_MarginOpen - | FIX_CashMargin_MarginClose -;; - -(** Indicates type of fee being assessed of the customer for trade executions at an exchange. Applicable for futures markets only at this time. - (Values source CBOT, CME, NYBOT, and NYMEX):*) -type fix_clearingfeeindicator = - | FIX_ClearingFeeIndicator_CBOEMember - | FIX_ClearingFeeIndicator_NonMemberAndCustomer - | FIX_ClearingFeeIndicator_EquityMemberAndClearingMember - | FIX_ClearingFeeIndicator_FullAndAssociateMember - | FIX_ClearingFeeIndicator_Firms106HAnd106J - | FIX_ClearingFeeIndicator_GIM - | FIX_ClearingFeeIndicator_Lessee106FEmployees - | FIX_ClearingFeeIndicator_AllOtherOwnershipTypes - | FIX_ClearingFeeIndicator_FirstYearDelegate - | FIX_ClearingFeeIndicator_SecondYearDelegate - | FIX_ClearingFeeIndicator_ThirdYearDelegate - | FIX_ClearingFeeIndicator_FourthYearDelegate - | FIX_ClearingFeeIndicator_FifthYearDelegate - | FIX_ClearingFeeIndicator_SixthYearDelegate -;; - -(** Eligibility of this trade for clearing and central counterparty processing*) -type fix_clearinginstruction = - | FIX_ClearingInstruction_ProcessNormally - | FIX_ClearingInstruction_ExcludeFromAllNetting - | FIX_ClearingInstruction_BilateralNettingOnly - | FIX_ClearingInstruction_ExClearing - | FIX_ClearingInstruction_SpecialTrade - | FIX_ClearingInstruction_MultilateralNetting - | FIX_ClearingInstruction_ClearAgainstCentralCounterparty - | FIX_ClearingInstruction_ExcludeFromCentralCounterparty - | FIX_ClearingInstruction_ManualMode - | FIX_ClearingInstruction_AutomaticPostingMode - | FIX_ClearingInstruction_AutomaticGiveUpMode - | FIX_ClearingInstruction_QualifiedServiceRepresentativeQSR - | FIX_ClearingInstruction_CustomerTrade - | FIX_ClearingInstruction_SelfClearing -;; - -(** Action proposed for an Underlying Instrument instance*) -type fix_collaction = - | FIX_CollAction_Retain - | FIX_CollAction_Add - | FIX_CollAction_Remove -;; - -(** Reason for Collateral Assignment*) -type fix_collasgnreason = - | FIX_CollAsgnReason_Initial - | FIX_CollAsgnReason_Scheduled - | FIX_CollAsgnReason_TimeWarning - | FIX_CollAsgnReason_MarginDeficiency - | FIX_CollAsgnReason_MarginExcess - | FIX_CollAsgnReason_ForwardCollateralDemand - | FIX_CollAsgnReason_EventOfDefault - | FIX_CollAsgnReason_AdverseTaxEvent -;; - -(** Collateral Assignment Reject Reason*) -type fix_collasgnrejectreason = - | FIX_CollAsgnRejectReason_UnknownDeal - | FIX_CollAsgnRejectReason_UnknownOrInvalidInstrument - | FIX_CollAsgnRejectReason_UnauthorizedTransaction - | FIX_CollAsgnRejectReason_InsufficientCollateral - | FIX_CollAsgnRejectReason_InvalidTypeOfCollateral - | FIX_CollAsgnRejectReason_ExcessiveSubstitution - | FIX_CollAsgnRejectReason_Other -;; - -(** Collateral Assignment Response Type*) -type fix_collasgnresptype = - | FIX_CollAsgnRespType_Received - | FIX_CollAsgnRespType_Accepted - | FIX_CollAsgnRespType_Declined - | FIX_CollAsgnRespType_Rejected -;; - -(** Collateral Assignment Transaction Type*) -type fix_collasgntranstype = - | FIX_CollAsgnTransType_New - | FIX_CollAsgnTransType_Replace - | FIX_CollAsgnTransType_Cancel - | FIX_CollAsgnTransType_Release - | FIX_CollAsgnTransType_Reverse -;; - -(** Collateral inquiry qualifiers:*) -type fix_collinquiryqualifier = - | FIX_CollInquiryQualifier_TradeDate - | FIX_CollInquiryQualifier_GCInstrument - | FIX_CollInquiryQualifier_CollateralInstrument - | FIX_CollInquiryQualifier_SubstitutionEligible - | FIX_CollInquiryQualifier_NotAssigned - | FIX_CollInquiryQualifier_PartiallyAssigned - | FIX_CollInquiryQualifier_FullyAssigned - | FIX_CollInquiryQualifier_OutstandingTrades -;; - -(** Result returned in response to Collateral Inquiry - 4000+ Reserved and available for bi-laterally agreed upon user-defined values*) -type fix_collinquiryresult = - | FIX_CollInquiryResult_Successful - | FIX_CollInquiryResult_InvalidOrUnknownInstrument - | FIX_CollInquiryResult_InvalidOrUnknownCollateralType - | FIX_CollInquiryResult_InvalidParties - | FIX_CollInquiryResult_InvalidTransportTypeRequested - | FIX_CollInquiryResult_InvalidDestinationRequested - | FIX_CollInquiryResult_NoCollateralFoundForTheTradeSpecified - | FIX_CollInquiryResult_NoCollateralFoundForTheOrderSpecified - | FIX_CollInquiryResult_CollateralInquiryTypeNotSupported - | FIX_CollInquiryResult_UnauthorizedForCollateralInquiry - | FIX_CollInquiryResult_Other -;; - -(** Status of Collateral Inquiry*) -type fix_collinquirystatus = - | FIX_CollInquiryStatus_Accepted - | FIX_CollInquiryStatus_AcceptedWithWarnings - | FIX_CollInquiryStatus_Completed - | FIX_CollInquiryStatus_CompletedWithWarnings - | FIX_CollInquiryStatus_Rejected -;; - -(** Collateral Status*) -type fix_collstatus = - | FIX_CollStatus_Unassigned - | FIX_CollStatus_PartiallyAssigned - | FIX_CollStatus_AssignmentProposed - | FIX_CollStatus_Assigned - | FIX_CollStatus_Challenged -;; - -(** Commission type*) -type fix_commtype = - | FIX_CommType_PerUnit - | FIX_CommType_Percent - | FIX_CommType_Absolute - | FIX_CommType_PercentageWaivedCashDiscount - | FIX_CommType_PercentageWaivedEnhancedUnits - | FIX_CommType_PointsPerBondOrContract -;; - -(** Identifies the reason for rejecting a Confirmation*) -type fix_confirmrejreason = - | FIX_ConfirmRejReason_MismatchedAccount - | FIX_ConfirmRejReason_MissingSettlementInstructions - | FIX_ConfirmRejReason_Other -;; - -(** Identifies the status of the Confirmation.*) -type fix_confirmstatus = - | FIX_ConfirmStatus_Received - | FIX_ConfirmStatus_MismatchedAccount - | FIX_ConfirmStatus_MissingSettlementInstructions - | FIX_ConfirmStatus_Confirmed - | FIX_ConfirmStatus_RequestRejected -;; - -(** Identifies the Confirmation transaction type*) -type fix_confirmtranstype = - | FIX_ConfirmTransType_New - | FIX_ConfirmTransType_Replace - | FIX_ConfirmTransType_Cancel -;; - -(** Identifies the type of Confirmation message being sent*) -type fix_confirmtype = - | FIX_ConfirmType_Status - | FIX_ConfirmType_Confirmation - | FIX_ConfirmType_ConfirmationRequestRejected -;; - -(** Type of ContAmtValue (520). - NOTE That Commission Amount / % in Contract Amounts is the commission actually charged, rather than the commission instructions given in Fields 2/3.*) -type fix_contamttype = - | FIX_ContAmtType_CommissionAmount - | FIX_ContAmtType_CommissionPercent - | FIX_ContAmtType_InitialChargeAmount - | FIX_ContAmtType_InitialChargePercent - | FIX_ContAmtType_DiscountAmount - | FIX_ContAmtType_DiscountPercent - | FIX_ContAmtType_DilutionLevyAmount - | FIX_ContAmtType_DilutionLevyPercent - | FIX_ContAmtType_ExitChargeAmount - | FIX_ContAmtType_ExitChargePercent - | FIX_ContAmtType_FundBasedRenewalCommissionPercent - | FIX_ContAmtType_ProjectedFundValue - | FIX_ContAmtType_FundBasedRenewalCommissionOnOrder - | FIX_ContAmtType_FundBasedRenewalCommissionOnFund - | FIX_ContAmtType_NetSettlementAmount -;; - -(** Identifies the type of Corporate Action*) -type fix_corporateaction = - | FIX_CorporateAction_ExDividend - | FIX_CorporateAction_ExDistribution - | FIX_CorporateAction_ExRights - | FIX_CorporateAction_New - | FIX_CorporateAction_ExInterest -;; - -(** Used for derivative products, such as options*) -type fix_coveredoruncovered = - | FIX_CoveredOrUncovered_Covered - | FIX_CoveredOrUncovered_Uncovered -;; - -(** Indicates if one side or the other of a cross order should be prioritized. - The definition of prioritization is left to the market. In some markets prioritization means which side of the cross order is applied to the market first. In other markets – prioritization may mean that the prioritized side is fully executed (sometimes referred to as the side being protected).*) -type fix_crossprioritization = - | FIX_CrossPrioritization_FIXNone - | FIX_CrossPrioritization_BuySideIsPrioritized - | FIX_CrossPrioritization_SellSideIsPrioritized -;; - -(** Type of cross being submitted to a market*) -type fix_crosstype = - | FIX_CrossType_CrossAON - | FIX_CrossType_CrossIOC - | FIX_CrossType_CrossOneSide - | FIX_CrossType_CrossSamePrice -;; - -(** Capacity of customer placing the order - Primarily used by futures exchanges to indicate the CTICode (customer type indicator) as required by the US CFTC (Commodity Futures Trading Commission).*) -type fix_custordercapacity = - | FIX_CustOrderCapacity_MemberTradingForTheirOwnAccount - | FIX_CustOrderCapacity_ClearingFirmTradingForItsProprietaryAccount - | FIX_CustOrderCapacity_MemberTradingForAnotherMember - | FIX_CustOrderCapacity_AllOther -;; - -(** Code to identify reason for cancel rejection*) -type fix_cxlrejreason = - | FIX_CxlRejReason_TooLateToCancel - | FIX_CxlRejReason_UnknownOrder - | FIX_CxlRejReason_BrokerCredit - | FIX_CxlRejReason_OrderAlreadyInPendingStatus - | FIX_CxlRejReason_UnableToProcessOrderMassCancelRequest - | FIX_CxlRejReason_OrigOrdModTime - | FIX_CxlRejReason_DuplicateClOrdID - | FIX_CxlRejReason_Other -;; - -(** Identifies the type of request that a Cancel Reject is in response to*) -type fix_cxlrejresponseto = - | FIX_CxlRejResponseTo_OrderCancelRequest - | FIX_CxlRejResponseTo_OrderCancel -;; - -(** Reason for execution rejection*) -type fix_dkreason = - | FIX_DKReason_UnknownSymbol - | FIX_DKReason_WrongSide - | FIX_DKReason_QuantityExceedsOrder - | FIX_DKReason_NoMatchingOrder - | FIX_DKReason_PriceExceedsLimit - | FIX_DKReason_CalculationDifference - | FIX_DKReason_Other -;; - -(** Indicates whether or not automatic booking can occur.*) -type fix_daybookinginst = - | FIX_DayBookingInst_Auto - | FIX_DayBookingInst_SpeakWithOrderInitiatorBeforeBooking - | FIX_DayBookingInst_Accumulate -;; - -(** Reason for deletion*) -type fix_deletereason = - | FIX_DeleteReason_Cancellation - | FIX_DeleteReason_Error -;; - -(** Identifies the form of delivery*) -type fix_deliveryform = - | FIX_DeliveryForm_BookEntry - | FIX_DeliveryForm_Bearer -;; - -(** Identifies type of settlement*) -type fix_deliverytype = - | FIX_DeliveryType_VersusPayment - | FIX_DeliveryType_Free - | FIX_DeliveryType_TriParty - | FIX_DeliveryType_HoldInCustody -;; - -(** Code to identify the price a DiscretionOffsetValue (389) is related to and should be mathematically added to*) -type fix_discretioninst = - | FIX_DiscretionInst_RelatedToDisplayedPrice - | FIX_DiscretionInst_RelatedToMarketPrice - | FIX_DiscretionInst_RelatedToPrimaryPrice - | FIX_DiscretionInst_RelatedToLocalPrimaryPrice - | FIX_DiscretionInst_RelatedToMidpointPrice - | FIX_DiscretionInst_RelatedToLastTradePrice - | FIX_DiscretionInst_RelatedToVWAP -;; - -(** Type of Discretion Limit*) -type fix_discretionlimittype = - | FIX_DiscretionLimitType_OrBetter - | FIX_DiscretionLimitType_Strict - | FIX_DiscretionLimitType_OrWorse -;; - -(** Describes whether discretionay price is static or floats*) -type fix_discretionmovetype = - | FIX_DiscretionMoveType_Floating - | FIX_DiscretionMoveType_Fixed -;; - -(** Type of Discretion Offset value*) -type fix_discretionoffsettype = - | FIX_DiscretionOffsetType_Price - | FIX_DiscretionOffsetType_BasisPoints - | FIX_DiscretionOffsetType_Ticks - | FIX_DiscretionOffsetType_PriceTier -;; - -(** If the calculated discretionary price is not a valid tick price, specifies whether to round the price to be more or less aggressive*) -type fix_discretionrounddirection = - | FIX_DiscretionRoundDirection_MoreAggressive - | FIX_DiscretionRoundDirection_MorePassive -;; - -(** The scope of the discretion*) -type fix_discretionscope = - | FIX_DiscretionScope_Local - | FIX_DiscretionScope_National - | FIX_DiscretionScope_Global - | FIX_DiscretionScope_NationalExcludingLocal -;; - -(** A code identifying the payment method for a (fractional) distribution. - 13 through 998 are reserved for future use - Values above 000 are available for use by private agreement among counterparties*) -type fix_distribpaymentmethod = - | FIX_DistribPaymentMethod_CREST - | FIX_DistribPaymentMethod_NSCC - | FIX_DistribPaymentMethod_Euroclear - | FIX_DistribPaymentMethod_Clearstream - | FIX_DistribPaymentMethod_Cheque - | FIX_DistribPaymentMethod_TelegraphicTransfer - | FIX_DistribPaymentMethod_FedWire - | FIX_DistribPaymentMethod_DirectCredit - | FIX_DistribPaymentMethod_ACHCredit - | FIX_DistribPaymentMethod_BPAY - | FIX_DistribPaymentMethod_HighValueClearingSystemHVACS - | FIX_DistribPaymentMethod_ReinvestInFund -;; - -(** Used to indicate whether a delivery instruction is used for securities or cash settlement*) -type fix_dlvyinsttype = - | FIX_DlvyInstType_Securities - | FIX_DlvyInstType_Cash -;; - -(** Indicates whether or not the halt was due to the Related Security being halted.*) -type fix_duetorelated = - | FIX_DueToRelated_RelatedToSecurityHalt - | FIX_DueToRelated_NotRelatedToSecurityHalt -;; - -(** Email message type*) -type fix_emailtype = - | FIX_EmailType_New - | FIX_EmailType_Reply - | FIX_EmailType_AdminReply -;; - -(** Code to represent the type of event*) -type fix_eventtype = - | FIX_EventType_Put - | FIX_EventType_Call - | FIX_EventType_Tender - | FIX_EventType_SinkingFundCall - | FIX_EventType_Other -;; - -(** Indicates whether or not to exchange for phsyical.*) -type fix_exchangeforphysical = - | FIX_ExchangeForPhysical_True - | FIX_ExchangeForPhysical_False -;; (** Instructions for order handling on exchange trading floor. If more than one instruction is applicable to an order, this field can contain multiple instructions separated by space.*) -type fix_execinst = +type (** Instructions for order handling on exchange trading floor. If more than one instruction is applicable to an order, this field can contain multiple instructions separated by space.*) +fix_execinst = | FIX_ExecInst_NotHeld | FIX_ExecInst_Work | FIX_ExecInst_GoAlong @@ -718,39 +44,14 @@ type fix_execinst = | FIX_ExecInst_IgnorePriceValidityChecks | FIX_ExecInst_PegToLimitPrice | FIX_ExecInst_WorkToTargetStrategy -;; - -(** For CIV - Identifies how the execution price LastPx (3) was calculated from the fund unit/share price(s) calculated at the fund valuation point*) -type fix_execpricetype = - | FIX_ExecPriceType_BidPrice - | FIX_ExecPriceType_CreationPrice - | FIX_ExecPriceType_CreationPricePlusAdjustmentPercent - | FIX_ExecPriceType_CreationPricePlusAdjustmentAmount - | FIX_ExecPriceType_OfferPrice - | FIX_ExecPriceType_OfferPriceMinusAdjustmentPercent - | FIX_ExecPriceType_OfferPriceMinusAdjustmentAmount - | FIX_ExecPriceType_SinglePrice -;; - -(** Code to identify reason for an ExecutionRpt message sent with ExecType=Restated or used when communicating an unsolicited cancel.*) -type fix_execrestatementreason = - | FIX_ExecRestatementReason_GTCorporateAction - | FIX_ExecRestatementReason_GTRenewal - | FIX_ExecRestatementReason_VerbalChange - | FIX_ExecRestatementReason_RepricingOfOrder - | FIX_ExecRestatementReason_BrokerOption - | FIX_ExecRestatementReason_PartialDeclineOfOrderQty - | FIX_ExecRestatementReason_CancelOnTradingHalt - | FIX_ExecRestatementReason_CancelOnSystemFailure - | FIX_ExecRestatementReason_Market - | FIX_ExecRestatementReason_Canceled - | FIX_ExecRestatementReason_WarehouseRecap - | FIX_ExecRestatementReason_Other + | FIX_INVALID_ExecInst of string ;; (** Describes the specific ExecutionRpt (i.e. Pending Cancel) while OrdStatus (39) will always identify the current order status (i.e. Partially Filled) *** SOME VALUES HAVE BEEN REPLACED - See "Replaced Features and Supported Approach" ****) -type fix_exectype = +type (** Describes the specific ExecutionRpt (i.e. Pending Cancel) while OrdStatus (39) will always identify the current order status (i.e. Partially Filled) + *** SOME VALUES HAVE BEEN REPLACED - See "Replaced Features and Supported Approach" ****) +fix_exectype = | FIX_ExecType_New | FIX_ExecType_DoneForDay | FIX_ExecType_Canceled @@ -768,492 +69,16 @@ type fix_exectype = | FIX_ExecType_TradeCorrect | FIX_ExecType_TradeCancel | FIX_ExecType_OrderStatus -;; - -(** Exercise Method used to in performing assignment*) -type fix_exercisemethod = - | FIX_ExerciseMethod_Automatic - | FIX_ExerciseMethod_Manual -;; - -(** Part of trading cycle when an instrument expires. Field is applicable for derivatives.*) -type fix_expirationcycle = - | FIX_ExpirationCycle_ExpireOnTradingSessionClose - | FIX_ExpirationCycle_ExpireOnTradingSessionOpen -;; - -(** Identifies a firm’s financial status*) -type fix_financialstatus = - | FIX_FinancialStatus_Bankrupt - | FIX_FinancialStatus_PendingDelisting -;; - -(** Indicates request for forex accommodation trade to be executed along with security transaction.*) -type fix_forexreq = - | FIX_ForexReq_ExecuteForexAfterSecurityTrade - | FIX_ForexReq_DoNotExecuteForexAfterSecurityTrade -;; - -(** A one character code identifying whether the Fund based renewal commission is to be waived.*) -type fix_fundrenewwaiv = - | FIX_FundRenewWaiv_Yes - | FIX_FundRenewWaiv_No -;; - -(** Code to identify whether to book out executions on a part-filled GT order on the day of execution or to accumulate*) -type fix_gtbookinginst = - | FIX_GTBookingInst_BookOutAllTradesOnDayOfExecution - | FIX_GTBookingInst_AccumulateUntilFilledOrExpired - | FIX_GTBookingInst_AccumulateUntilVerballyNotifiedOtherwise -;; - -(** Denotes the reason for the Opening Delay or Trading Halt*) -type fix_haltreason = - | FIX_HaltReason_OrderImbalance - | FIX_HaltReason_EquipmentChangeover - | FIX_HaltReason_NewsPending - | FIX_HaltReason_NewsDissemination - | FIX_HaltReason_OrderInflux - | FIX_HaltReason_AdditionalInformation -;; - -(** Instructions for order handling on Broker trading floor*) -type fix_handlinst = - | FIX_HandlInst_AutomatedExecutionNoIntervention - | FIX_HandlInst_AutomatedExecutionInterventionOK - | FIX_HandlInst_ManualOrder -;; - -(** Indicates that IOI is the result of an existing agency order or a facilitation position resulting from an agency order, not from principal trading or order solicitation activity.*) -type fix_ioinaturalflag = - | FIX_IOINaturalFlag_Natural - | FIX_IOINaturalFlag_NotNatural -;; - -(** Relative quality of indication*) -type fix_ioiqltyind = - | FIX_IOIQltyInd_Low - | FIX_IOIQltyInd_Medium - | FIX_IOIQltyInd_High -;; - -(** Quantity (e.g. number of shares) in numeric form or relative size.*) -type fix_ioiqty = - | FIX_IOIQty_Small - | FIX_IOIQty_Medium - | FIX_IOIQty_Large -;; - -(** Code to qualify IOI use*) -type fix_ioiqualifier = - | FIX_IOIQualifier_AllOrNone - | FIX_IOIQualifier_MarketOnClose - | FIX_IOIQualifier_AtTheClose - | FIX_IOIQualifier_VWAP - | FIX_IOIQualifier_InTouchWith - | FIX_IOIQualifier_Limit - | FIX_IOIQualifier_MoreBehind - | FIX_IOIQualifier_AtTheOpen - | FIX_IOIQualifier_TakingAPosition - | FIX_IOIQualifier_AtTheMarket - | FIX_IOIQualifier_ReadyToTrade - | FIX_IOIQualifier_PortfolioShown - | FIX_IOIQualifier_ThroughTheDay - | FIX_IOIQualifier_Versus - | FIX_IOIQualifier_Indication - | FIX_IOIQualifier_CrossingOpportunity - | FIX_IOIQualifier_AtTheMidpoint - | FIX_IOIQualifier_PreOpen -;; - -(** Identifies IOI message transaction type*) -type fix_ioitranstype = - | FIX_IOITransType_New - | FIX_IOITransType_Cancel - | FIX_IOITransType_Replace -;; - -(** Indicates whether or not the halt was due to Common Stock trading being halted.*) -type fix_inviewofcommon = - | FIX_InViewOfCommon_HaltWasDueToCommonStockBeingHalted - | FIX_InViewOfCommon_HaltWasNotRelatedToAHaltOfTheCommonStock -;; - -(** Code to represent whether value is net (inclusive of tax) or gross*) -type fix_inctaxind = - | FIX_IncTaxInd_Net - | FIX_IncTaxInd_Gross -;; - -(** Code to represent the type of instrument attribute*) -type fix_instrattribtype = - | FIX_InstrAttribType_Flat - | FIX_InstrAttribType_ZeroCoupon - | FIX_InstrAttribType_InterestBearing - | FIX_InstrAttribType_NoPeriodicPayments - | FIX_InstrAttribType_VariableRate - | FIX_InstrAttribType_LessFeeForPut - | FIX_InstrAttribType_SteppedCoupon - | FIX_InstrAttribType_CouponPeriod - | FIX_InstrAttribType_When - | FIX_InstrAttribType_OriginalIssueDiscount - | FIX_InstrAttribType_Callable - | FIX_InstrAttribType_EscrowedToMaturity - | FIX_InstrAttribType_EscrowedToRedemptionDate - | FIX_InstrAttribType_PreRefunded - | FIX_InstrAttribType_InDefault - | FIX_InstrAttribType_Unrated - | FIX_InstrAttribType_Taxable - | FIX_InstrAttribType_Indexed - | FIX_InstrAttribType_SubjectToAlternativeMinimumTax - | FIX_InstrAttribType_OriginalIssueDiscountPrice - | FIX_InstrAttribType_CallableBelowMaturityValue - | FIX_InstrAttribType_CallableWithoutNotice - | FIX_InstrAttribType_Text -;; - -(** Broker capacity in order execution*) -type fix_lastcapacity = - | FIX_LastCapacity_Agent - | FIX_LastCapacity_CrossAsAgent - | FIX_LastCapacity_CrossAsPrincipal - | FIX_LastCapacity_Principal -;; - -(** Indicates whether this message is the last in a sequence of messages for those messages that support fragmentation, such as Allocation Instruction, Mass Quote, Security List, Derivative Security List*) -type fix_lastfragment = - | FIX_LastFragment_LastMessage - | FIX_LastFragment_NotLastMessage -;; - -(** Indicator to identify whether this fill was a result of a liquidity provider providing or liquidity taker taking the liquidity. Applicable only for OrdStatus of Partial or Filled.*) -type fix_lastliquidityind = - | FIX_LastLiquidityInd_AddedLiquidity - | FIX_LastLiquidityInd_RemovedLiquidity - | FIX_LastLiquidityInd_LiquidityRoutedOut -;; - -(** For Fixed Income, used instead of LegQty (687) or LegOrderQty (685) to requests the respondent to calculate the quantity based on the quantity on the opposite side of the swap.*) -type fix_legswaptype = - | FIX_LegSwapType_ParForPar - | FIX_LegSwapType_ModifiedDuration - | FIX_LegSwapType_Risk - | FIX_LegSwapType_Proceeds -;; - -(** Indicates that this message is to serve as the final and legal confirmation.*) -type fix_legalconfirm = - | FIX_LegalConfirm_LegalConfirm - | FIX_LegalConfirm_DoesNotConsituteALegalConfirm -;; - -(** Code to identify the type of liquidity indicator*) -type fix_liquidityindtype = - | FIX_LiquidityIndType_FiveDayMovingAverage - | FIX_LiquidityIndType_TwentyDayMovingAverage - | FIX_LiquidityIndType_NormalMarketSize - | FIX_LiquidityIndType_Other -;; - -(** Identifies the type of ListExecInst (69)*) -type fix_listexecinsttype = - | FIX_ListExecInstType_Immediate - | FIX_ListExecInstType_WaitForInstruction - | FIX_ListExecInstType_SellDriven - | FIX_ListExecInstType_BuyDrivenCashTopUp - | FIX_ListExecInstType_BuyDrivenCashWithdraw -;; - -(** Code to represent the status of a list order*) -type fix_listorderstatus = - | FIX_ListOrderStatus_InBiddingProcess - | FIX_ListOrderStatus_ReceivedForExecution - | FIX_ListOrderStatus_Executing - | FIX_ListOrderStatus_Cancelling - | FIX_ListOrderStatus_Alert - | FIX_ListOrderStatus_AllDone - | FIX_ListOrderStatus_Reject -;; - -(** Code to represent the status type*) -type fix_liststatustype = - | FIX_ListStatusType_Ack - | FIX_ListStatusType_Response - | FIX_ListStatusType_Timed - | FIX_ListStatusType_ExecStarted - | FIX_ListStatusType_AllDone - | FIX_ListStatusType_Alert -;; - -(** Indicates whether the broker is to locate the stock in conjunction with a short sell order.*) -type fix_locatereqd = - | FIX_LocateReqd_Yes - | FIX_LocateReqd_No -;; - -(** Type Market Data entry*) -type fix_mdentrytype = - | FIX_MDEntryType_Bid - | FIX_MDEntryType_Offer - | FIX_MDEntryType_Trade - | FIX_MDEntryType_IndexValue - | FIX_MDEntryType_OpeningPrice - | FIX_MDEntryType_ClosingPrice - | FIX_MDEntryType_SettlementPrice - | FIX_MDEntryType_TradingSessionHighPrice - | FIX_MDEntryType_TradingSessionLowPrice - | FIX_MDEntryType_TradingSessionVWAPPrice - | FIX_MDEntryType_Imbalance - | FIX_MDEntryType_TradeVolume - | FIX_MDEntryType_OpenInterest -;; - -(** Defines how a server handles distribution of a truncated book. Defaults to broker option.*) -type fix_mdimplicitdelete = - | FIX_MDImplicitDelete_Yes - | FIX_MDImplicitDelete_No -;; - -(** Reason for the rejection of a Market Data request*) -type fix_mdreqrejreason = - | FIX_MDReqRejReason_UnknownSymbol - | FIX_MDReqRejReason_DuplicateMDReqID - | FIX_MDReqRejReason_InsufficientBandwidth - | FIX_MDReqRejReason_InsufficientPermissions - | FIX_MDReqRejReason_UnsupportedSubscriptionRequestType - | FIX_MDReqRejReason_UnsupportedMarketDepth - | FIX_MDReqRejReason_UnsupportedMDUpdateType - | FIX_MDReqRejReason_UnsupportedAggregatedBook - | FIX_MDReqRejReason_UnsupportedMDEntryType - | FIX_MDReqRejReason_UnsupportedTradingSessionID - | FIX_MDReqRejReason_UnsupportedScope - | FIX_MDReqRejReason_UnsupportedOpenCloseSettleFlag - | FIX_MDReqRejReason_UnsupportedMDImplicitDelete -;; - -(** Type of Market Data update action*) -type fix_mdupdateaction = - | FIX_MDUpdateAction_New - | FIX_MDUpdateAction_Change - | FIX_MDUpdateAction_Delete -;; - -(** Specifies the type of Market Data update*) -type fix_mdupdatetype = - | FIX_MDUpdateType_FullRefresh - | FIX_MDUpdateType_IncrementalRefresh -;; - -(** Reason Order Mass Cancel Request was rejected*) -type fix_masscancelrejectreason = - | FIX_MassCancelRejectReason_MassCancelNotSupported - | FIX_MassCancelRejectReason_InvalidOrUnknownSecurity - | FIX_MassCancelRejectReason_InvalidOrUnkownUnderlyingSecurity - | FIX_MassCancelRejectReason_InvalidOrUnknownProduct - | FIX_MassCancelRejectReason_InvalidOrUnknownCFICode - | FIX_MassCancelRejectReason_InvalidOrUnknownSecurityType - | FIX_MassCancelRejectReason_InvalidOrUnknownTradingSession - | FIX_MassCancelRejectReason_Other -;; - -(** Specifies scope of Order Mass Cancel Request*) -type fix_masscancelrequesttype = - | FIX_MassCancelRequestType_CancelOrdersForASecurity - | FIX_MassCancelRequestType_CancelOrdersForAnUnderlyingSecurity - | FIX_MassCancelRequestType_CancelOrdersForAProduct - | FIX_MassCancelRequestType_CancelOrdersForACFICode - | FIX_MassCancelRequestType_CancelOrdersForASecurityType - | FIX_MassCancelRequestType_CancelOrdersForATradingSession - | FIX_MassCancelRequestType_CancelAllOrders -;; - -(** Specifies the action taken by counterparty order handling system as a result of the Order Mass Cancel Request*) -type fix_masscancelresponse = - | FIX_MassCancelResponse_CancelRequestRejected - | FIX_MassCancelResponse_CancelOrdersForASecurity - | FIX_MassCancelResponse_CancelOrdersForAnUnderlyingSecurity - | FIX_MassCancelResponse_CancelOrdersForAProduct - | FIX_MassCancelResponse_CancelOrdersForACFICode - | FIX_MassCancelResponse_CancelOrdersForASecurityType - | FIX_MassCancelResponse_CancelOrdersForATradingSession - | FIX_MassCancelResponse_CancelAllOrders -;; - -(** Mass Status Request Type*) -type fix_massstatusreqtype = - | FIX_MassStatusReqType_StatusForOrdersForASecurity - | FIX_MassStatusReqType_StatusForOrdersForAnUnderlyingSecurity - | FIX_MassStatusReqType_StatusForOrdersForAProduct - | FIX_MassStatusReqType_StatusForOrdersForACFICode - | FIX_MassStatusReqType_StatusForOrdersForASecurityType - | FIX_MassStatusReqType_StatusForOrdersForATradingSession - | FIX_MassStatusReqType_StatusForAllOrders - | FIX_MassStatusReqType_StatusForOrdersForAPartyID -;; - -(** The status of this trade with respect to matching or comparison*) -type fix_matchstatus = - | FIX_MatchStatus_Compared - | FIX_MatchStatus_Uncompared - | FIX_MatchStatus_AdvisoryOrAlert -;; - -(** The point in the matching process at which this trade was matched*) -type fix_matchtype = - | FIX_MatchType_ExactMatchPlus4BadgesExecTime - | FIX_MatchType_ExactMatchPlus4Badges - | FIX_MatchType_ExactMatchPlus2BadgesExecTime - | FIX_MatchType_ExactMatchPlus2Badges - | FIX_MatchType_ExactMatchPlusExecTime - | FIX_MatchType_StampedAdvisoriesOrSpecialistAccepts - | FIX_MatchType_A1ExactMatchSummarizedQuantity - | FIX_MatchType_A2ExactMatchSummarizedQuantity - | FIX_MatchType_A3ExactMatchSummarizedQuantity - | FIX_MatchType_A4ExactMatchSummarizedQuantity - | FIX_MatchType_A5ExactMatchSummarizedQuantity - | FIX_MatchType_ExactMatchMinusBadgesTimes - | FIX_MatchType_SummarizedMatchMinusBadgesTimes - | FIX_MatchType_OCSLockedIn - | FIX_MatchType_ACTAcceptedTrade - | FIX_MatchType_ACTDefaultTrade - | FIX_MatchType_ACTDefaultAfterM2 - | FIX_MatchType_ACTM6Match -;; - -(** Type of message encoding (non-ASCII (non-English) characters) used in a message’s "Encoded" fields.*) -type fix_messageencoding = - | FIX_MessageEncoding_ISO2022JP - | FIX_MessageEncoding_EUCJP - | FIX_MessageEncoding_ShiftJIS - | FIX_MessageEncoding_UTF8 -;; - -(** Defines the unit for a miscellaneous fee.*) -type fix_miscfeebasis = - | FIX_MiscFeeBasis_Absolute - | FIX_MiscFeeBasis_PerUnit - | FIX_MiscFeeBasis_Percentage -;; - -(** Indicates type of miscellaneous fee*) -type fix_miscfeetype = - | FIX_MiscFeeType_Regulatory - | FIX_MiscFeeType_Tax - | FIX_MiscFeeType_LocalCommission - | FIX_MiscFeeType_ExchangeFees - | FIX_MiscFeeType_Stamp - | FIX_MiscFeeType_Levy - | FIX_MiscFeeType_Other - | FIX_MiscFeeType_Markup - | FIX_MiscFeeType_ConsumptionTax - | FIX_MiscFeeType_PerTransaction - | FIX_MiscFeeType_Conversion - | FIX_MiscFeeType_Agent -;; - -(** A one character code identifying Money laundering status*) -type fix_moneylaunderingstatus = - | FIX_MoneyLaunderingStatus_Passed - | FIX_MoneyLaunderingStatus_NotChecked - | FIX_MoneyLaunderingStatus_ExemptBelowLimit - | FIX_MoneyLaunderingStatus_ExemptMoneyType - | FIX_MoneyLaunderingStatus_ExemptAuthorised -;; - -(** Specifies the direction of the messsage*) -type fix_msgdirection = - | FIX_MsgDirection_Send - | FIX_MsgDirection_Receive -;; - -(** Used to indicate what an Execution Report represents (e.g. used with multi-leg securities, such as option strategies, spreads, etc.).*) -type fix_multilegreportingtype = - | FIX_MultiLegReportingType_SingleSecurity - | FIX_MultiLegReportingType_IndividualLegOfAMultiLegSecurity - | FIX_MultiLegReportingType_MultiLegSecurity -;; - -(** Indicates the method of execution reporting requested by issuer of the order*) -type fix_multilegrpttypereq = - | FIX_MultiLegRptTypeReq_ReportByMulitlegSecurityOnly - | FIX_MultiLegRptTypeReq_ReportByMultilegSecurityAndInstrumentLegs - | FIX_MultiLegRptTypeReq_ReportByInstrumentLegsOnly -;; - -(** Code to represent whether value is net (inclusive of tax) or gross*) -type fix_netgrossind = - | FIX_NetGrossInd_Net - | FIX_NetGrossInd_Gross -;; - -(** Indicates the type and level of details required for a Network Status Request Message - Boolean logic applies EG If you want to subscribe for changes to certain id’s then UserRequestType =0 (8+2), Snapshot for certain ID’s = 9 (8+)*) -type fix_networkrequesttype = - | FIX_NetworkRequestType_Snapshot - | FIX_NetworkRequestType_Subscribe - | FIX_NetworkRequestType_StopSubscribing - | FIX_NetworkRequestType_LevelOfDetail -;; - -(** Indicates the type of Network Response Message*) -type fix_networkstatusresponsetype = - | FIX_NetworkStatusResponseType_Full - | FIX_NetworkStatusResponseType_IncrementalUpdate -;; - -(** Number of Side repeating group instances.*) -type fix_nosides = - | FIX_NoSides_OneSide - | FIX_NoSides_BothSides -;; - -(** Indicates whether or not details should be communicated to BrokerOfCredit (i.e. step-in broker).*) -type fix_notifybrokerofcredit = - | FIX_NotifyBrokerOfCredit_DetailsShouldBeCommunicated - | FIX_NotifyBrokerOfCredit_DetailsShouldNotBeCommunicated -;; - -(** This trade is to be treated as an odd lot*) -type fix_oddlot = - | FIX_OddLot_TreatAsOddLot - | FIX_OddLot_TreatAsRoundLot -;; - -(** Flag that identifies a market data entry - (Prior to FIX 4.3 this field was of type char)*) -type fix_openclosesettlflag = - | FIX_OpenCloseSettlFlag_DailyOpen - | FIX_OpenCloseSettlFlag_SessionOpen - | FIX_OpenCloseSettlFlag_DeliverySettlementEntry - | FIX_OpenCloseSettlFlag_ExpectedEntry - | FIX_OpenCloseSettlFlag_EntryFromPreviousBusinessDay - | FIX_OpenCloseSettlFlag_TheoreticalPriceValue -;; - -(** Code to identify reason for order rejection.*) -type fix_ordrejreason = - | FIX_OrdRejReason_BrokerCredit - | FIX_OrdRejReason_UnknownSymbol - | FIX_OrdRejReason_ExchangeClosed - | FIX_OrdRejReason_OrderExceedsLimit - | FIX_OrdRejReason_TooLateToEnter - | FIX_OrdRejReason_UnknownOrder - | FIX_OrdRejReason_DuplicateOrder - | FIX_OrdRejReason_DuplicateOfAVerballyCommunicatedOrder - | FIX_OrdRejReason_StaleOrder - | FIX_OrdRejReason_TradeAlongRequired - | FIX_OrdRejReason_InvalidInvestorID - | FIX_OrdRejReason_UnsupportedOrderCharacteristic - | FIX_OrdRejReason_IncorrectQuantity - | FIX_OrdRejReason_IncorrectAllocatedQuantity - | FIX_OrdRejReason_UnknownAccount - | FIX_OrdRejReason_Other + | FIX_INVALID_ExecType of string ;; (** Identifies current status of order. *** SOME VALUES HAVE BEEN REPLACED - See "Replaced Features and Supported Approach" *** (see Volume : "Glossary" for value definitions)*) -type fix_ordstatus = +type (** Identifies current status of order. + *** SOME VALUES HAVE BEEN REPLACED - See "Replaced Features and Supported Approach" *** + (see Volume : "Glossary" for value definitions)*) +fix_ordstatus = | FIX_OrdStatus_New | FIX_OrdStatus_PartiallyFilled | FIX_OrdStatus_Filled @@ -1269,12 +94,16 @@ type fix_ordstatus = | FIX_OrdStatus_AcceptedForBidding | FIX_OrdStatus_PendingReplace | FIX_OrdStatus_Replaced + | FIX_INVALID_OrdStatus of string ;; (** Order type *** SOME VALUES ARE NO LONGER USED - See "Deprecated (Phased-out) Features and Supported Approach" *** (see Volume : "Glossary" for value definitions)*) -type fix_ordtype = +type (** Order type + *** SOME VALUES ARE NO LONGER USED - See "Deprecated (Phased-out) Features and Supported Approach" *** + (see Volume : "Glossary" for value definitions)*) +fix_ordtype = | FIX_OrdType_Market | FIX_OrdType_Limit | FIX_OrdType_Stop @@ -1292,126 +121,15 @@ type fix_ordtype = | FIX_OrdType_PreviousFundValuationPoint | FIX_OrdType_NextFundValuationPoint | FIX_OrdType_Pegged -;; - -(** Designates the capacity of the firm placing the order - (as of FIX 4.3, this field replaced Rule80A (tag 47) --used in conjunction with OrderRestrictions (529) field) - (see Volume : "Glossary" for value definitions)*) -type fix_ordercapacity = - | FIX_OrderCapacity_Agency - | FIX_OrderCapacity_Proprietary - | FIX_OrderCapacity_Individual - | FIX_OrderCapacity_Principal - | FIX_OrderCapacity_RisklessPrincipal - | FIX_OrderCapacity_AgentForOtherMember -;; - -(** Restrictions associated with an order. If more than one restriction is applicable to an order, this field can contain multiple instructions separated by space.*) -type fix_orderrestrictions = - | FIX_OrderRestrictions_ProgramTrade - | FIX_OrderRestrictions_IndexArbitrage - | FIX_OrderRestrictions_NonIndexArbitrage - | FIX_OrderRestrictions_CompetingMarketMaker - | FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInSecurity - | FIX_OrderRestrictions_ActingAsMarketMakerOrSpecialistInUnderlying - | FIX_OrderRestrictions_ForeignEntity - | FIX_OrderRestrictions_ExternalMarketParticipant - | FIX_OrderRestrictions_ExternalInterConnectedMarketLinkage - | FIX_OrderRestrictions_RisklessArbitrage -;; - -(** Identifies the type of owner*) -type fix_ownertype = - | FIX_OwnerType_IndividualInvestor - | FIX_OwnerType_PublicCompany - | FIX_OwnerType_PrivateCompany - | FIX_OwnerType_IndividualTrustee - | FIX_OwnerType_CompanyTrustee - | FIX_OwnerType_PensionPlan - | FIX_OwnerType_CustodianUnderGiftsToMinorsAct - | FIX_OwnerType_Trusts - | FIX_OwnerType_Fiduciaries - | FIX_OwnerType_NetworkingSubAccount - | FIX_OwnerType_NonProfitOrganization - | FIX_OwnerType_CorporateBody - | FIX_OwnerType_Nominee -;; - -(** The relationship between Registration parties.*) -type fix_ownershiptype = - | FIX_OwnershipType_JointInvestors - | FIX_OwnershipType_TenantsInCommon - | FIX_OwnershipType_JointTrustees -;; - -(** Identifies class or source of the PartyID (448) value. Required if PartyID is specified. Note: applicable values depend upon PartyRole (452) specified. - See "Appendix 6-G – Use of Component Block"*) -type fix_partyidsource = - | FIX_PartyIDSource_BIC - | FIX_PartyIDSource_GeneralIdentifier - | FIX_PartyIDSource_Proprietary - | FIX_PartyIDSource_ISOCountryCode - | FIX_PartyIDSource_SettlementEntityLocation - | FIX_PartyIDSource_MIC - | FIX_PartyIDSource_CSDParticipant - | FIX_PartyIDSource_KoreanInvestorID - | FIX_PartyIDSource_TaiwaneseForeignInvestorID - | FIX_PartyIDSource_TaiwaneseTradingAcct - | FIX_PartyIDSource_MalaysianCentralDepository - | FIX_PartyIDSource_ChineseInvestorID - | FIX_PartyIDSource_UKNationalInsuranceOrPensionNumber - | FIX_PartyIDSource_USSocialSecurityNumber - | FIX_PartyIDSource_USEmployerOrTaxIDNumber - | FIX_PartyIDSource_AustralianBusinessNumber - | FIX_PartyIDSource_AustralianTaxFileNumber - | FIX_PartyIDSource_ISITCAcronym -;; - -(** Identifies the type or role of the PartyID (448) specified. - See "Appendix 6-G – Use of Component Block"*) -type fix_partyrole = - | FIX_PartyRole_ExecutingFirm - | FIX_PartyRole_BrokerOfCredit - | FIX_PartyRole_ClientID - | FIX_PartyRole_ClearingFirm - | FIX_PartyRole_InvestorID - | FIX_PartyRole_IntroducingFirm - | FIX_PartyRole_EnteringFirm - | FIX_PartyRole_Locate - | FIX_PartyRole_FundManagerClientID - | FIX_PartyRole_SettlementLocation - | FIX_PartyRole_OrderOriginationTrader - | FIX_PartyRole_ExecutingTrader - | FIX_PartyRole_OrderOriginationFirm - | FIX_PartyRole_GiveupClearingFirm - | FIX_PartyRole_CorrespondantClearingFirm - | FIX_PartyRole_ExecutingSystem - | FIX_PartyRole_ContraFirm - | FIX_PartyRole_ContraClearingFirm - | FIX_PartyRole_SponsoringFirm - | FIX_PartyRole_UnderlyingContraFirm - | FIX_PartyRole_ClearingOrganization - | FIX_PartyRole_Exchange - | FIX_PartyRole_CustomerAccount - | FIX_PartyRole_CorrespondentClearingOrganization - | FIX_PartyRole_CorrespondentBroker - | FIX_PartyRole_Buyer - | FIX_PartyRole_Custodian - | FIX_PartyRole_Intermediary - | FIX_PartyRole_Agent - | FIX_PartyRole_SubCustodian - | FIX_PartyRole_Beneficiary - | FIX_PartyRole_InterestedParty - | FIX_PartyRole_RegulatoryBody - | FIX_PartyRole_LiquidityProvider - | FIX_PartyRole_EnteringTrader - | FIX_PartyRole_ContraTrader - | FIX_PartyRole_PositionAccount + | FIX_OrdType_StopSpread + | FIX_INVALID_OrdType of string ;; (** Type of PartySubID (523) value 4000+ = Reserved and available for bi-laterally agreed upon user defined values*) -type fix_partysubidtype = +type (** Type of PartySubID (523) value + 4000+ = Reserved and available for bi-laterally agreed upon user defined values*) +fix_partysubidtype = | FIX_PartySubIDType_Firm | FIX_PartySubIDType_Person | FIX_PartySubIDType_System @@ -1438,744 +156,12 @@ type fix_partysubidtype = | FIX_PartySubIDType_Department | FIX_PartySubIDType_LocationDesk | FIX_PartySubIDType_PositionAccountType -;; - -(** A code identifying the Settlement payment method. - 16 through 998 are reserved for future use - Values above 000 are available for use by private agreement among counterparties*) -type fix_paymentmethod = - | FIX_PaymentMethod_CREST - | FIX_PaymentMethod_NSCC - | FIX_PaymentMethod_Euroclear - | FIX_PaymentMethod_Clearstream - | FIX_PaymentMethod_Cheque - | FIX_PaymentMethod_TelegraphicTransfer - | FIX_PaymentMethod_FedWire - | FIX_PaymentMethod_DebitCard - | FIX_PaymentMethod_DirectDebit - | FIX_PaymentMethod_DirectCredit - | FIX_PaymentMethod_CreditCard - | FIX_PaymentMethod_ACHDebit - | FIX_PaymentMethod_ACHCredit - | FIX_PaymentMethod_BPAY - | FIX_PaymentMethod_HighValueClearingSystem -;; - -(** Type of Peg Limit*) -type fix_peglimittype = - | FIX_PegLimitType_OrBetter - | FIX_PegLimitType_Strict - | FIX_PegLimitType_OrWorse -;; - -(** Describes whether peg is static or floats*) -type fix_pegmovetype = - | FIX_PegMoveType_Floating - | FIX_PegMoveType_Fixed -;; - -(** Type of Peg Offset value*) -type fix_pegoffsettype = - | FIX_PegOffsetType_Price - | FIX_PegOffsetType_BasisPoints - | FIX_PegOffsetType_Ticks - | FIX_PegOffsetType_PriceTier -;; - -(** If the calculated peg price is not a valid tick price, specifies whether to round the price to be more or less aggressive*) -type fix_pegrounddirection = - | FIX_PegRoundDirection_MoreAggressive - | FIX_PegRoundDirection_MorePassive -;; - -(** The scope of the peg*) -type fix_pegscope = - | FIX_PegScope_Local - | FIX_PegScope_National - | FIX_PegScope_Global - | FIX_PegScope_NationalExcludingLocal -;; - -(** Type of Position amount*) -type fix_posamttype = - | FIX_PosAmtType_FinalMarkToMarketAmount - | FIX_PosAmtType_IncrementalMarkToMarketAmount - | FIX_PosAmtType_TradeVariationAmount - | FIX_PosAmtType_StartOfDayMarkToMarketAmount - | FIX_PosAmtType_PremiumAmount - | FIX_PosAmtType_CashResidualAmount - | FIX_PosAmtType_CashAmount - | FIX_PosAmtType_ValueAdjustedAmount -;; - -(** Maintenance Action to be performed*) -type fix_posmaintaction = - | FIX_PosMaintAction_New - | FIX_PosMaintAction_Replace - | FIX_PosMaintAction_Cancel -;; - -(** Result of Position Maintenance Request.*) -type fix_posmaintresult = - | FIX_PosMaintResult_SuccessfulCompletion - | FIX_PosMaintResult_Rejected - | FIX_PosMaintResult_Other -;; - -(** Status of Position Maintenance Request*) -type fix_posmaintstatus = - | FIX_PosMaintStatus_Accepted - | FIX_PosMaintStatus_AcceptedWithWarnings - | FIX_PosMaintStatus_Rejected - | FIX_PosMaintStatus_Completed - | FIX_PosMaintStatus_CompletedWithWarnings -;; - -(** Status of this position*) -type fix_posqtystatus = - | FIX_PosQtyStatus_Submitted - | FIX_PosQtyStatus_Accepted - | FIX_PosQtyStatus_Rejected -;; - -(** Result of Request for Position - 4000+ Reserved and available for bi-laterally agreed upon user-defined values*) -type fix_posreqresult = - | FIX_PosReqResult_ValidRequest - | FIX_PosReqResult_InvalidOrUnsupportedRequest - | FIX_PosReqResult_NoPositionsFoundThatMatchCriteria - | FIX_PosReqResult_NotAuthorizedToRequestPositions - | FIX_PosReqResult_RequestForPositionNotSupported - | FIX_PosReqResult_Other -;; - -(** Status of Request for Positions*) -type fix_posreqstatus = - | FIX_PosReqStatus_Completed - | FIX_PosReqStatus_CompletedWithWarnings - | FIX_PosReqStatus_Rejected -;; - -(** Unique identifier for the position maintenance request as assigned by the submitter*) -type fix_posreqtype = - | FIX_PosReqType_Positions - | FIX_PosReqType_Trades - | FIX_PosReqType_Exercises - | FIX_PosReqType_Assignments -;; - -(** Identifies the type of position transaction*) -type fix_postranstype = - | FIX_PosTransType_Exercise - | FIX_PosTransType_DoNotExercise - | FIX_PosTransType_PositionAdjustment - | FIX_PosTransType_PositionChangeSubmission - | FIX_PosTransType_Pledge -;; - -(** Used to identify the type of quantity that is being returned*) -type fix_postype = - | FIX_PosType_TransactionQuantity - | FIX_PosType_IntraSpreadQty - | FIX_PosType_InterSpreadQty - | FIX_PosType_EndOfDayQty - | FIX_PosType_StartOfDayQty - | FIX_PosType_OptionExerciseQty - | FIX_PosType_OptionAssignment - | FIX_PosType_TransactionFromExercise - | FIX_PosType_TransactionFromAssignment - | FIX_PosType_PitTradeQty - | FIX_PosType_TransferTradeQty - | FIX_PosType_ElectronicTradeQty - | FIX_PosType_AllocationTradeQty - | FIX_PosType_AdjustmentQty - | FIX_PosType_AsOfTradeQty - | FIX_PosType_DeliveryQty - | FIX_PosType_TotalTransactionQty - | FIX_PosType_CrossMarginQty - | FIX_PosType_IntegralSplit -;; - -(** Indicates whether the resulting position after a trade should be an opening position or closing position. Used for omnibus accounting - where accounts are held on a gross basis instead of being netted together.*) -type fix_positioneffect = - | FIX_PositionEffect_Open - | FIX_PositionEffect_Close - | FIX_PositionEffect_Rolled - | FIX_PositionEffect_FIFO -;; - -(** Indicates possible retransmission of message with this sequence number*) -type fix_possdupflag = - | FIX_PossDupFlag_PossibleDuplicate - | FIX_PossDupFlag_OriginalTransmission -;; - -(** Indicates that message may contain information that has been sent under another sequence number.*) -type fix_possresend = - | FIX_PossResend_PossibleResend - | FIX_PossResend_OriginalTransmission -;; - -(** Indicates the method of preallocation.*) -type fix_preallocmethod = - | FIX_PreallocMethod_ProRata - | FIX_PreallocMethod_DoNotProRata -;; - -(** Indicates if the trade capture report was previously reported to the counterparty*) -type fix_previouslyreported = - | FIX_PreviouslyReported_PerviouslyReportedToCounterparty - | FIX_PreviouslyReported_NotReportedToCounterparty -;; - -(** Code to represent the price type*) -type fix_pricetype = - | FIX_PriceType_Percentage - | FIX_PriceType_PerUnit - | FIX_PriceType_FixedAmount - | FIX_PriceType_Discount - | FIX_PriceType_Premium - | FIX_PriceType_Spread - | FIX_PriceType_TEDPrice - | FIX_PriceType_TEDYield - | FIX_PriceType_Yield - | FIX_PriceType_FixedCabinetTradePrice - | FIX_PriceType_VariableCabinetTradePrice -;; - -(** Indicates if a Cancel/Replace has caused an order to lose book priority*) -type fix_priorityindicator = - | FIX_PriorityIndicator_PriorityUnchanged - | FIX_PriorityIndicator_LostPriorityAsResultOfOrderChange -;; - -(** Processing code for sub-account. Absence of this field in AllocAccount (79) / AllocPrice (366) /AllocQty (80) / ProcessCode instance indicates regular trade.*) -type fix_processcode = - | FIX_ProcessCode_Regular - | FIX_ProcessCode_SoftDollar - | FIX_ProcessCode_StepIn - | FIX_ProcessCode_StepOut - | FIX_ProcessCode_SoftDollarStepIn - | FIX_ProcessCode_SoftDollarStepOut - | FIX_ProcessCode_PlanSponsor -;; - -(** Indicates the type of product the security is associated with. See also the CFICode (46) and SecurityType (67) fields.*) -type fix_product = - | FIX_Product_AGENCY - | FIX_Product_COMMODITY - | FIX_Product_CORPORATE - | FIX_Product_CURRENCY - | FIX_Product_EQUITY - | FIX_Product_GOVERNMENT - | FIX_Product_INDEX - | FIX_Product_LOAN - | FIX_Product_MONEYMARKET - | FIX_Product_MORTGAGE - | FIX_Product_MUNICIPAL - | FIX_Product_OTHER - | FIX_Product_FINANCING -;; - -(** Code to identify the desired frequency of progress reports*) -type fix_progrptreqs = - | FIX_ProgRptReqs_BuySideRequests - | FIX_ProgRptReqs_SellSideSends - | FIX_ProgRptReqs_RealTimeExecutionReports -;; - -(** Indicates if a trade should be reported via a market reporting service.*) -type fix_publishtrdindicator = - | FIX_PublishTrdIndicator_ReportTrade - | FIX_PublishTrdIndicator_DoNotReportTrade -;; - -(** Indicates whether an Option is for a put or call*) -type fix_putorcall = - | FIX_PutOrCall_Put - | FIX_PutOrCall_Call -;; - -(** Type of quantity specified in a quantity field*) -type fix_qtytype = - | FIX_QtyType_Units - | FIX_QtyType_Contracts -;; - -(** Identifies the type of quote cancel.*) -type fix_quotecanceltype = - | FIX_QuoteCancelType_CancelForOneOrMoreSecurities - | FIX_QuoteCancelType_CancelForSecurityType - | FIX_QuoteCancelType_CancelForUnderlyingSecurity - | FIX_QuoteCancelType_CancelAllQuotes -;; - -(** Space-delimited list of conditions describing a quote*) -type fix_quotecondition = - | FIX_QuoteCondition_Open - | FIX_QuoteCondition_Closed - | FIX_QuoteCondition_ExchangeBest - | FIX_QuoteCondition_ConsolidatedBest - | FIX_QuoteCondition_Locked - | FIX_QuoteCondition_Crossed - | FIX_QuoteCondition_Depth - | FIX_QuoteCondition_FastTrading - | FIX_QuoteCondition_NonFirm -;; - -(** Code to represent price type requested in Quote*) -type fix_quotepricetype = - | FIX_QuotePriceType_Percent - | FIX_QuotePriceType_PerShare - | FIX_QuotePriceType_FixedAmount - | FIX_QuotePriceType_Discount - | FIX_QuotePriceType_Premium - | FIX_QuotePriceType_Spread - | FIX_QuotePriceType_TEDPrice - | FIX_QuotePriceType_TEDYield - | FIX_QuotePriceType_YieldSpread - | FIX_QuotePriceType_Yield -;; - -(** Reason Quote was rejected*) -type fix_quoterejectreason = - | FIX_QuoteRejectReason_UnknownSymbol - | FIX_QuoteRejectReason_Exchange - | FIX_QuoteRejectReason_QuoteRequestExceedsLimit - | FIX_QuoteRejectReason_TooLateToEnter - | FIX_QuoteRejectReason_UnknownQuote - | FIX_QuoteRejectReason_DuplicateQuote - | FIX_QuoteRejectReason_InvalidBid - | FIX_QuoteRejectReason_InvalidPrice - | FIX_QuoteRejectReason_NotAuthorizedToQuoteSecurity - | FIX_QuoteRejectReason_Other -;; - -(** Reason Quote was rejected:*) -type fix_quoterequestrejectreason = - | FIX_QuoteRequestRejectReason_UnknownSymbol - | FIX_QuoteRequestRejectReason_Exchange - | FIX_QuoteRequestRejectReason_QuoteRequestExceedsLimit - | FIX_QuoteRequestRejectReason_TooLateToEnter - | FIX_QuoteRequestRejectReason_InvalidPrice - | FIX_QuoteRequestRejectReason_NotAuthorizedToRequestQuote - | FIX_QuoteRequestRejectReason_NoMatchForInquiry - | FIX_QuoteRequestRejectReason_NoMarketForInstrument - | FIX_QuoteRequestRejectReason_NoInventory - | FIX_QuoteRequestRejectReason_Pass - | FIX_QuoteRequestRejectReason_Other -;; - -(** Indicates the type of Quote Request being generated*) -type fix_quoterequesttype = - | FIX_QuoteRequestType_Manual - | FIX_QuoteRequestType_Automatic -;; - -(** Identifies the type of Quote Response*) -type fix_quoteresptype = - | FIX_QuoteRespType_Hit - | FIX_QuoteRespType_Counter - | FIX_QuoteRespType_Expired - | FIX_QuoteRespType_Cover - | FIX_QuoteRespType_DoneAway - | FIX_QuoteRespType_Pass -;; - -(** Level of Response requested from receiver of quote messages.*) -type fix_quoteresponselevel = - | FIX_QuoteResponseLevel_NoAcknowledgement - | FIX_QuoteResponseLevel_AcknowledgeOnlyNegativeOrErroneousQuotes - | FIX_QuoteResponseLevel_AcknowledgeEachQuoteMessage -;; - -(** Identifies the status of the quote acknowledgement*) -type fix_quotestatus = - | FIX_QuoteStatus_Accepted - | FIX_QuoteStatus_CancelForSymbol - | FIX_QuoteStatus_CanceledForSecurityType - | FIX_QuoteStatus_CanceledForUnderlying - | FIX_QuoteStatus_CanceledAll - | FIX_QuoteStatus_Rejected - | FIX_QuoteStatus_RemovedFromMarket - | FIX_QuoteStatus_Expired - | FIX_QuoteStatus_Query - | FIX_QuoteStatus_QuoteNotFound - | FIX_QuoteStatus_Pending - | FIX_QuoteStatus_Pass - | FIX_QuoteStatus_LockedMarketWarning - | FIX_QuoteStatus_CrossMarketWarning - | FIX_QuoteStatus_CanceledDueToLockMarket - | FIX_QuoteStatus_CanceledDueToCrossMarket -;; - -(** Identifies the type of quote. - An indicative quote is used to inform a counterparty of a market. An indicative quote does not result directly in a trade. - A tradeable quote is submitted to a market and will result directly in a trade against other orders and quotes in a market. - A restricted tradeable quote is submitted to a market and within a certain restriction (possibly based upon price or quantity) will automatically trade against orders. Order that do not comply with restrictions are sent to the quote issuer who can choose to accept or decline the order. - A counter quote is used in the negotiation model. See Volume 7 – Product: Fixed Income for example usage.*) -type fix_quotetype = - | FIX_QuoteType_Indicative - | FIX_QuoteType_Tradeable - | FIX_QuoteType_RestrictedTradeable - | FIX_QuoteType_Counter -;; - -(** Reason(s) why Registration Instructions has been rejected. - The reason may be further amplified in the RegistRejReasonCode field. - Possible values of reason code include:*) -type fix_registrejreasoncode = - | FIX_RegistRejReasonCode_InvalidAccountType - | FIX_RegistRejReasonCode_InvalidTaxExemptType - | FIX_RegistRejReasonCode_InvalidOwnershipType - | FIX_RegistRejReasonCode_NoRegDetails - | FIX_RegistRejReasonCode_InvalidRegSeqNo - | FIX_RegistRejReasonCode_InvalidRegDetails - | FIX_RegistRejReasonCode_InvalidMailingDetails - | FIX_RegistRejReasonCode_InvalidMailingInstructions - | FIX_RegistRejReasonCode_InvalidInvestorID - | FIX_RegistRejReasonCode_InvalidInvestorIDSource - | FIX_RegistRejReasonCode_InvalidDateOfBirth - | FIX_RegistRejReasonCode_InvalidCountry - | FIX_RegistRejReasonCode_InvalidDistribInstns - | FIX_RegistRejReasonCode_InvalidPercentage - | FIX_RegistRejReasonCode_InvalidPaymentMethod - | FIX_RegistRejReasonCode_InvalidAccountName - | FIX_RegistRejReasonCode_InvalidAgentCode - | FIX_RegistRejReasonCode_InvalidAccountNum - | FIX_RegistRejReasonCode_Other -;; - -(** Registration status as returned by the broker or (for CIV) the fund manager*) -type fix_registstatus = - | FIX_RegistStatus_Accepted - | FIX_RegistStatus_Rejected - | FIX_RegistStatus_Held - | FIX_RegistStatus_Reminder -;; - -(** Identifies Registration Instructions transaction type*) -type fix_registtranstype = - | FIX_RegistTransType_New - | FIX_RegistTransType_Replace - | FIX_RegistTransType_Cancel -;; - -(** Identifies party of trade responsible for exchange reporting.*) -type fix_reporttoexch = - | FIX_ReportToExch_ReceiverReports - | FIX_ReportToExch_SenderReports -;; - -(** Indicates that the both sides of the FIX session should reset sequence numbers.*) -type fix_resetseqnumflag = - | FIX_ResetSeqNumFlag_Yes - | FIX_ResetSeqNumFlag_No -;; - -(** Identifies how the response to the request should be transmitted*) -type fix_responsetransporttype = - | FIX_ResponseTransportType_Inband - | FIX_ResponseTransportType_OutOfBand -;; - -(** Specifies which direction to round For CIV – indicates whether or not the quantity of shares/units is to be rounded and in which direction where CashOrdQty (52) or (for CIV only) OrderPercent (56) are specified on an order. - The default is for rounding to be at the discretion of the executing broker or fund manager. - e.g. for an order specifying CashOrdQty or OrderPercent if the calculated number of shares/units was 325.76 and RoundingModulus (469) was 0 – "round down" would give 320 units, "round up" would give 330 units and "round to nearest" would give 320 units.*) -type fix_roundingdirection = - | FIX_RoundingDirection_RoundToNearest - | FIX_RoundingDirection_RoundDown - | FIX_RoundingDirection_RoundUp -;; - -(** Indicates the type of RoutingID (27) specified*) -type fix_routingtype = - | FIX_RoutingType_TargetFirm - | FIX_RoutingType_TargetList - | FIX_RoutingType_BlockFirm - | FIX_RoutingType_BlockList -;; - -(** Defines the scope of a data element*) -type fix_scope = - | FIX_Scope_LocalMarket - | FIX_Scope_National - | FIX_Scope_Global -;; - -(** Identifies class or source of the SecurityID (48) value. Required if SecurityID is specified.*) -type fix_securityidsource = - | FIX_SecurityIDSource_CUSIP - | FIX_SecurityIDSource_SEDOL - | FIX_SecurityIDSource_QUIK - | FIX_SecurityIDSource_ISINNumber - | FIX_SecurityIDSource_RICCode - | FIX_SecurityIDSource_ISOCurrencyCode - | FIX_SecurityIDSource_ISOCountryCode - | FIX_SecurityIDSource_ExchangeSymbol - | FIX_SecurityIDSource_ConsolidatedTapeAssociation - | FIX_SecurityIDSource_BloombergSymbol - | FIX_SecurityIDSource_Wertpapier - | FIX_SecurityIDSource_Dutch - | FIX_SecurityIDSource_Valoren - | FIX_SecurityIDSource_Sicovam - | FIX_SecurityIDSource_Belgian - | FIX_SecurityIDSource_Common - | FIX_SecurityIDSource_ClearingHouse - | FIX_SecurityIDSource_ISDAFpMLSpecification - | FIX_SecurityIDSource_OptionPriceReportingAuthority -;; - -(** Identifies the type/criteria of Security List Request*) -type fix_securitylistrequesttype = - | FIX_SecurityListRequestType_Symbol - | FIX_SecurityListRequestType_SecurityTypeAnd - | FIX_SecurityListRequestType_Product - | FIX_SecurityListRequestType_TradingSessionID - | FIX_SecurityListRequestType_AllSecurities -;; - -(** The results returned to a Security Request message*) -type fix_securityrequestresult = - | FIX_SecurityRequestResult_ValidRequest - | FIX_SecurityRequestResult_InvalidOrUnsupportedRequest - | FIX_SecurityRequestResult_NoInstrumentsFound - | FIX_SecurityRequestResult_NotAuthorizedToRetrieveInstrumentData - | FIX_SecurityRequestResult_InstrumentDataTemporarilyUnavailable - | FIX_SecurityRequestResult_RequestForInstrumentDataNotSupported -;; - -(** Type of Security Definition Request.*) -type fix_securityrequesttype = - | FIX_SecurityRequestType_RequestSecurityIdentityAndSpecifications - | FIX_SecurityRequestType_RequestSecurityIdentityForSpecifications - | FIX_SecurityRequestType_RequestListSecurityTypes - | FIX_SecurityRequestType_RequestListSecurities -;; - -(** Type of Security Definition message response*) -type fix_securityresponsetype = - | FIX_SecurityResponseType_AcceptAsIs - | FIX_SecurityResponseType_AcceptWithRevisions - | FIX_SecurityResponseType_RejectSecurityProposal - | FIX_SecurityResponseType_CannotMatchSelectionCriteria -;; - -(** Identifies the trading status applicable to the transaction*) -type fix_securitytradingstatus = - | FIX_SecurityTradingStatus_OpeningDelay - | FIX_SecurityTradingStatus_TradingHalt - | FIX_SecurityTradingStatus_Resume - | FIX_SecurityTradingStatus_NoOpen - | FIX_SecurityTradingStatus_PriceIndication - | FIX_SecurityTradingStatus_TradingRangeIndication - | FIX_SecurityTradingStatus_MarketImbalanceBuy - | FIX_SecurityTradingStatus_MarketImbalanceSell - | FIX_SecurityTradingStatus_MarketOnCloseImbalanceBuy - | FIX_SecurityTradingStatus_MarketOnCloseImbalanceSell - | FIX_SecurityTradingStatus_NoMarketImbalance - | FIX_SecurityTradingStatus_NoMarketOnCloseImbalance - | FIX_SecurityTradingStatus_ITSPreOpening - | FIX_SecurityTradingStatus_NewPriceIndication - | FIX_SecurityTradingStatus_TradeDisseminationTime - | FIX_SecurityTradingStatus_ReadyToTrade - | FIX_SecurityTradingStatus_NotAvailableForTrading - | FIX_SecurityTradingStatus_NotTradedOnThisMarket - | FIX_SecurityTradingStatus_UnknownOrInvalid - | FIX_SecurityTradingStatus_PreOpen - | FIX_SecurityTradingStatus_OpeningRotation - | FIX_SecurityTradingStatus_FastMarket -;; - -(** Indicates type of security. See also the Product (460) and CFICode (46) fields. It is recommended that CFICode be used instead of SecurityType for non-Fixed Income instruments. - Example values (grouped by Product field value) (Note: additional values may be used by mutual agreement of the counterparties): - * Identify the Issuer in the "Issuer" field(06) - *** REPLACED values - See "Replaced Features and Supported Approach" *** - NOTE: Additional values may be used by mutual agreement of the counterparties)*) -type fix_securitytype = - | FIX_SecurityType_Future - | FIX_SecurityType_Option - | FIX_SecurityType_EuroSupranationalCoupons - | FIX_SecurityType_FederalAgencyCoupon - | FIX_SecurityType_FederalAgencyDiscountNote - | FIX_SecurityType_PrivateExportFunding - | FIX_SecurityType_USDSupranationalCoupons - | FIX_SecurityType_CorporateBond - | FIX_SecurityType_CorporatePrivatePlacement - | FIX_SecurityType_ConvertibleBond - | FIX_SecurityType_DualCurrency - | FIX_SecurityType_EuroCorporateBond - | FIX_SecurityType_IndexedLinked - | FIX_SecurityType_StructuredNotes - | FIX_SecurityType_YankeeCorporateBond - | FIX_SecurityType_ForeignExchangeContract - | FIX_SecurityType_CommonStock - | FIX_SecurityType_PreferredStock - | FIX_SecurityType_BradyBond - | FIX_SecurityType_EuroSovereigns - | FIX_SecurityType_USTreasuryBond - | FIX_SecurityType_InterestStripFromAnyBondOrNote - | FIX_SecurityType_TreasuryInflationProtectedSecurities - | FIX_SecurityType_PrincipalStripOfACallableBondOrNote - | FIX_SecurityType_PrincipalStripFromANonCallableBondOrNote - | FIX_SecurityType_USTreasuryNoteOld - | FIX_SecurityType_USTreasuryBillOld - | FIX_SecurityType_USTreasuryNote - | FIX_SecurityType_USTreasuryBill - | FIX_SecurityType_Repurchase - | FIX_SecurityType_Forward - | FIX_SecurityType_BuySellback - | FIX_SecurityType_SecuritiesLoan - | FIX_SecurityType_SecuritiesPledge - | FIX_SecurityType_TermLoan - | FIX_SecurityType_RevolverLoan - | FIX_SecurityType_Revolver - | FIX_SecurityType_BridgeLoan - | FIX_SecurityType_LetterOfCredit - | FIX_SecurityType_SwingLineFacility - | FIX_SecurityType_DebtorInPossession - | FIX_SecurityType_Defaulted - | FIX_SecurityType_Withdrawn - | FIX_SecurityType_Replaced - | FIX_SecurityType_Matured - | FIX_SecurityType_Amended - | FIX_SecurityType_Retired - | FIX_SecurityType_BankersAcceptance - | FIX_SecurityType_BankNotes - | FIX_SecurityType_BillOfExchanges - | FIX_SecurityType_CertificateOfDeposit - | FIX_SecurityType_CallLoans - | FIX_SecurityType_CommercialPaper - | FIX_SecurityType_DepositNotes - | FIX_SecurityType_EuroCertificateOfDeposit - | FIX_SecurityType_EuroCommercialPaper - | FIX_SecurityType_LiquidityNote - | FIX_SecurityType_MediumTermNotes - | FIX_SecurityType_Overnight - | FIX_SecurityType_PromissoryNote - | FIX_SecurityType_PlazosFijos - | FIX_SecurityType_ShortTermLoanNote - | FIX_SecurityType_TimeDeposit - | FIX_SecurityType_ExtendedCommNote - | FIX_SecurityType_YankeeCertificateOfDeposit - | FIX_SecurityType_AssetBackedSecurities - | FIX_SecurityType_Corp - | FIX_SecurityType_CollateralizedMortgageObligation - | FIX_SecurityType_IOETTEMortgage - | FIX_SecurityType_MortgageBackedSecurities - | FIX_SecurityType_MortgageInterestOnly - | FIX_SecurityType_MortgagePrincipalOnly - | FIX_SecurityType_MortgagePrivatePlacement - | FIX_SecurityType_MiscellaneousPassThrough - | FIX_SecurityType_Pfandbriefe - | FIX_SecurityType_ToBeAnnounced - | FIX_SecurityType_OtherAnticipationNotes - | FIX_SecurityType_CertificateOfObligation - | FIX_SecurityType_CertificateOfParticipation - | FIX_SecurityType_GeneralObligationBonds - | FIX_SecurityType_MandatoryTender - | FIX_SecurityType_RevenueAnticipationNote - | FIX_SecurityType_RevenueBonds - | FIX_SecurityType_SpecialAssessment - | FIX_SecurityType_SpecialObligation - | FIX_SecurityType_SpecialTax - | FIX_SecurityType_TaxAnticipationNote - | FIX_SecurityType_TaxAllocation - | FIX_SecurityType_TaxExemptCommercialPaper - | FIX_SecurityType_TaxRevenueAnticipationNote - | FIX_SecurityType_VariableRateDemandNote - | FIX_SecurityType_Warrant - | FIX_SecurityType_MutualFund - | FIX_SecurityType_MultilegInstrument - | FIX_SecurityType_NoSecurityType -;; - -(** Specifies whether or not SettlCurrFxRate (55) should be multiplied or divided*) -type fix_settlcurrfxratecalc = - | FIX_SettlCurrFxRateCalc_Multiply - | FIX_SettlCurrFxRateCalc_Divide -;; - -(** Identifies type of settlement*) -type fix_settldeliverytype = - | FIX_SettlDeliveryType_Versus - | FIX_SettlDeliveryType_Free - | FIX_SettlDeliveryType_TriParty - | FIX_SettlDeliveryType_HoldInCustody -;; - -(** Indicates mode used for Settlement Instructions message. - *** SOME VALUES HAVE BEEN REPLACED - See "Replaced Features and Supported Approach" ****) -type fix_settlinstmode = - | FIX_SettlInstMode_StandingInstructionsProvided - | FIX_SettlInstMode_SpecificOrderForASingleAccount - | FIX_SettlInstMode_RequestReject -;; - -(** Identifies reason for rejection (of a settlement instruction request message)*) -type fix_settlinstreqrejcode = - | FIX_SettlInstReqRejCode_UnableToProcessRequest - | FIX_SettlInstReqRejCode_UnknownAccount - | FIX_SettlInstReqRejCode_NoMatchingSettlementInstructionsFound - | FIX_SettlInstReqRejCode_Other -;; - -(** Indicates source of Settlement Instructions*) -type fix_settlinstsource = - | FIX_SettlInstSource_BrokerCredit - | FIX_SettlInstSource_Institution - | FIX_SettlInstSource_Investor -;; - -(** Settlement Instructions message transaction type*) -type fix_settlinsttranstype = - | FIX_SettlInstTransType_New - | FIX_SettlInstTransType_Cancel - | FIX_SettlInstTransType_Replace - | FIX_SettlInstTransType_Restate -;; - -(** Type of settlement price*) -type fix_settlpricetype = - | FIX_SettlPriceType_Final - | FIX_SettlPriceType_Theoretical -;; - -(** Identifies a specific settlement session*) -type fix_settlsessid = - | FIX_SettlSessID_Intraday - | FIX_SettlSessID_RegularTradingHours - | FIX_SettlSessID_ElectronicTradingHours -;; - -(** Indicates order settlement period. If present, SettlDate (64) overrides this field. If both SettlType (63) and SettDate (64) are omitted, the default for SettlType (63) is 0 (Regular) - Regular is defined as the default settlement period for the particular security on the exchange of execution. - In Fixed Income the contents of this field may influence the instrument definition if the SecurityID (48) is ambiguous. In the US an active Treasury offering may be re-opened, and for a time one CUSIP will apply to both the current and "when-issued" securities. Supplying a value of "7" clarifies the instrument description; any other value or the absence of this field should cause the respondent to default to the active issue.*) -type fix_settltype = - | FIX_SettlType_Regular - | FIX_SettlType_Cash - | FIX_SettlType_NextDay - | FIX_SettlType_TPlus2 - | FIX_SettlType_TPlus3 - | FIX_SettlType_TPlus4 - | FIX_SettlType_Future - | FIX_SettlType_WhenAndIfIssued - | FIX_SettlType_SellersOption - | FIX_SettlType_TPlus5 -;; - -(** Reason for short sale*) -type fix_shortsalereason = - | FIX_ShortSaleReason_DealerSoldShort - | FIX_ShortSaleReason_DealerSoldShortExempt - | FIX_ShortSaleReason_SellingCustomerSoldShort - | FIX_ShortSaleReason_SellingCustomerSoldShortExempt - | FIX_ShortSaleReason_QualifiedServiceRepresentative - | FIX_ShortSaleReason_QSROrAGUContraSideSoldShortExempt + | FIX_INVALID_PartySubIDType of string ;; (** Side of order*) -type fix_side = +type (** Side of order*) +fix_side = | FIX_Side_Buy | FIX_Side_Sell | FIX_Side_BuyMinus @@ -2192,428 +178,6 @@ type fix_side = | FIX_Side_Redeem | FIX_Side_Lend | FIX_Side_Borrow + | FIX_INVALID_Side of string ;; -(** Used to indicate if the side being reported on Trade Capture Report represents a leg of a multileg instrument or a single security*) -type fix_sidemultilegreportingtype = - | FIX_SideMultiLegReportingType_SingleSecurity - | FIX_SideMultiLegReportingType_IndividualLegOfAMultilegSecurity - | FIX_SideMultiLegReportingType_MultilegSecurity -;; - -(** Code to identify which "SideValue" the value refers to. SideValue and SideValue2 are used as opposed to Buy or Sell so that the basket can be quoted either way as Buy or Sell.*) -type fix_sidevalueind = - | FIX_SideValueInd_SideValue1 - | FIX_SideValueInd_SideValue2 -;; - -(** Indicates whether or not the order was solicited.*) -type fix_solicitedflag = - | FIX_SolicitedFlag_WasSolicited - | FIX_SolicitedFlag_WasNotSolicited -;; - -(** Identifies the Standing Instruction database used*) -type fix_standinstdbtype = - | FIX_StandInstDbType_Other - | FIX_StandInstDbType_DTCSID - | FIX_StandInstDbType_ThomsonALERT - | FIX_StandInstDbType_AGlobalCustodian - | FIX_StandInstDbType_AccountNet -;; - -(** Indicates the status of a network connection*) -type fix_statusvalue = - | FIX_StatusValue_Connected - | FIX_StatusValue_NotConnectedUnexpected - | FIX_StatusValue_NotConnectedExpected - | FIX_StatusValue_InProcess -;; - -(** Type of Stipulation*) -type fix_stipulationtype = - | FIX_StipulationType_AlternativeMinimumTax - | FIX_StipulationType_AutoReinvestment - | FIX_StipulationType_BankQualified - | FIX_StipulationType_BargainConditions - | FIX_StipulationType_CouponRange - | FIX_StipulationType_ISOCurrencyCode - | FIX_StipulationType_CustomStart - | FIX_StipulationType_Geographics - | FIX_StipulationType_ValuationDiscount - | FIX_StipulationType_Insured - | FIX_StipulationType_IssueDate - | FIX_StipulationType_Issuer - | FIX_StipulationType_IssueSizeRange - | FIX_StipulationType_LookbackDays - | FIX_StipulationType_ExplicitLotIdentifier - | FIX_StipulationType_LotVariance - | FIX_StipulationType_MaturityYearAndMonth - | FIX_StipulationType_MaturityRange - | FIX_StipulationType_MaximumSubstitutions - | FIX_StipulationType_MinimumQuantity - | FIX_StipulationType_MinimumIncrement - | FIX_StipulationType_MinimumDenomination - | FIX_StipulationType_PaymentFrequency - | FIX_StipulationType_NumberOfPieces - | FIX_StipulationType_PoolsMaximum - | FIX_StipulationType_PoolsPerMillion - | FIX_StipulationType_PoolsPerLot - | FIX_StipulationType_PoolsPerTrade - | FIX_StipulationType_PriceRange - | FIX_StipulationType_PricingFrequency - | FIX_StipulationType_ProductionYear - | FIX_StipulationType_CallProtection - | FIX_StipulationType_Purpose - | FIX_StipulationType_BenchmarkPriceSource - | FIX_StipulationType_RatingSourceAndRange - | FIX_StipulationType_TypeOfRedemption - | FIX_StipulationType_Restricted - | FIX_StipulationType_MarketSector - | FIX_StipulationType_SecurityTypeIncludedOrExcluded - | FIX_StipulationType_Structure - | FIX_StipulationType_SubstitutionsFrequency - | FIX_StipulationType_SubstitutionsLeft - | FIX_StipulationType_FreeformText - | FIX_StipulationType_TradeVariance - | FIX_StipulationType_WeightedAverageCoupon - | FIX_StipulationType_WeightedAverageLifeCoupon - | FIX_StipulationType_WeightedAverageLoanAge - | FIX_StipulationType_WeightedAverageMaturity - | FIX_StipulationType_WholePool - | FIX_StipulationType_YieldRange -;; - -(** Subscription Request Type*) -type fix_subscriptionrequesttype = - | FIX_SubscriptionRequestType_Snapshot - | FIX_SubscriptionRequestType_SnapshotAndUpdates - | FIX_SubscriptionRequestType_DisablePreviousSnapshot -;; - -(** The target strategy of the order - 1000+ = Reserved and available for bi-laterally agreed upon user defined values*) -type fix_targetstrategy = - | FIX_TargetStrategy_VWAP - | FIX_TargetStrategy_Participate - | FIX_TargetStrategy_MininizeMarketImpact -;; - -(** For CIV - a code identifying the type of tax exempt account in which purchased shares/units are to be held*) -type fix_taxadvantagetype = - | FIX_TaxAdvantageType_FIXNone - | FIX_TaxAdvantageType_MaxiISA - | FIX_TaxAdvantageType_TESSA - | FIX_TaxAdvantageType_MiniCashISA - | FIX_TaxAdvantageType_MiniStocksAndSharesISA - | FIX_TaxAdvantageType_MiniInsuranceISA - | FIX_TaxAdvantageType_CurrentYearPayment - | FIX_TaxAdvantageType_PriorYearPayment - | FIX_TaxAdvantageType_AssetTransfer - | FIX_TaxAdvantageType_EmployeePriorYear - | FIX_TaxAdvantageType_EmployeeCurrentYear - | FIX_TaxAdvantageType_EmployerPriorYear - | FIX_TaxAdvantageType_EmployerCurrentYear - | FIX_TaxAdvantageType_NonFundPrototypeIRA - | FIX_TaxAdvantageType_NonFundQualifiedPlan - | FIX_TaxAdvantageType_DefinedContributionPlan - | FIX_TaxAdvantageType_IRA - | FIX_TaxAdvantageType_IRARollover - | FIX_TaxAdvantageType_KEOGH - | FIX_TaxAdvantageType_ProfitSharingPlan - | FIX_TaxAdvantageType_US401K - | FIX_TaxAdvantageType_SelfDirectedIRA - | FIX_TaxAdvantageType_US403b - | FIX_TaxAdvantageType_US457 - | FIX_TaxAdvantageType_RothIRAPrototype - | FIX_TaxAdvantageType_RothIRANonPrototype - | FIX_TaxAdvantageType_RothConversionIRAPrototype - | FIX_TaxAdvantageType_RothConversionIRANonPrototype - | FIX_TaxAdvantageType_EducationIRAPrototype - | FIX_TaxAdvantageType_EducationIRANonPrototype -;; - -(** Type of financing termination*) -type fix_terminationtype = - | FIX_TerminationType_Overnight - | FIX_TerminationType_Term - | FIX_TerminationType_Flexible - | FIX_TerminationType_Open -;; - -(** Indicates whether or not this FIX Session is a "test" vs. "production" connection. Useful for preventing "accidents".*) -type fix_testmessageindicator = - | FIX_TestMessageIndicator_True - | FIX_TestMessageIndicator_Fales -;; - -(** Direction of the "tick"*) -type fix_tickdirection = - | FIX_TickDirection_PlusTick - | FIX_TickDirection_ZeroPlusTick - | FIX_TickDirection_MinusTick - | FIX_TickDirection_ZeroMinusTick -;; - -(** Specifies how long the order remains in effect. Absence of this field is interpreted as DAY.*) -type fix_timeinforce = - | FIX_TimeInForce_Day - | FIX_TimeInForce_GoodTillCancel - | FIX_TimeInForce_AtTheOpening - | FIX_TimeInForce_ImmediateOrCancel - | FIX_TimeInForce_FillOrKill - | FIX_TimeInForce_GoodTillCrossing - | FIX_TimeInForce_GoodTillDate - | FIX_TimeInForce_AtTheClose -;; - -(** Method of trading*) -type fix_tradsesmethod = - | FIX_TradSesMethod_Electronic - | FIX_TradSesMethod_OpenOutcry - | FIX_TradSesMethod_TwoParty -;; - -(** Trading Session Mode*) -type fix_tradsesmode = - | FIX_TradSesMode_Testing - | FIX_TradSesMode_Simulated - | FIX_TradSesMode_Production -;; - -(** State of the trading session*) -type fix_tradsesstatus = - | FIX_TradSesStatus_Unknown - | FIX_TradSesStatus_Halted - | FIX_TradSesStatus_Open - | FIX_TradSesStatus_Closed - | FIX_TradSesStatus_PreOpen - | FIX_TradSesStatus_PreClose - | FIX_TradSesStatus_RequestRejected -;; - -(** Indicates the reason a Trading Session Status Request was rejected*) -type fix_tradsesstatusrejreason = - | FIX_TradSesStatusRejReason_UnknownOrInvalidTradingSessionID - | FIX_TradSesStatusRejReason_Other -;; - -(** Identifies how the trade is to be allocated*) -type fix_tradeallocindicator = - | FIX_TradeAllocIndicator_AllocationNotRequired - | FIX_TradeAllocIndicator_AllocationRequired - | FIX_TradeAllocIndicator_UseAllocationProvidedWithTheTrade -;; - -(** Space-delimited list of conditions describing a trade*) -type fix_tradecondition = - | FIX_TradeCondition_Cash - | FIX_TradeCondition_AveragePriceTrade - | FIX_TradeCondition_CashTrade - | FIX_TradeCondition_NextDay - | FIX_TradeCondition_Opening - | FIX_TradeCondition_IntradayTradeDetail - | FIX_TradeCondition_Rule127Trade - | FIX_TradeCondition_Rule155Trade - | FIX_TradeCondition_SoldLast - | FIX_TradeCondition_NextDayTrade - | FIX_TradeCondition_Opened - | FIX_TradeCondition_Seller - | FIX_TradeCondition_Sold - | FIX_TradeCondition_StoppedStock - | FIX_TradeCondition_ImbalanceMoreBuyers - | FIX_TradeCondition_ImbalanceMoreSellers - | FIX_TradeCondition_OpeningPrice -;; - -(** Reason Trade Capture Request was rejected. - 4000+ Reserved and available for bi-laterally agreed upon user-defined values*) -type fix_tradereportrejectreason = - | FIX_TradeReportRejectReason_Successful - | FIX_TradeReportRejectReason_InvalidPartyOnformation - | FIX_TradeReportRejectReason_UnknownInstrument - | FIX_TradeReportRejectReason_UnauthorizedToReportTrades - | FIX_TradeReportRejectReason_InvalidTradeType - | FIX_TradeReportRejectReason_Other -;; - -(** Type of Trade Report*) -type fix_tradereporttype = - | FIX_TradeReportType_Submit - | FIX_TradeReportType_Alleged - | FIX_TradeReportType_Accept - | FIX_TradeReportType_Decline - | FIX_TradeReportType_Addendum - | FIX_TradeReportType_No - | FIX_TradeReportType_TradeReportCancel - | FIX_TradeReportType_LockedIn -;; - -(** Result of Trade Request - 4000+ Reserved and available for bi-laterally agreed upon user-defined values*) -type fix_traderequestresult = - | FIX_TradeRequestResult_Successful - | FIX_TradeRequestResult_InvalidOrUnknownInstrument - | FIX_TradeRequestResult_InvalidTypeOfTradeRequested - | FIX_TradeRequestResult_InvalidParties - | FIX_TradeRequestResult_InvalidTransportTypeRequested - | FIX_TradeRequestResult_InvalidDestinationRequested - | FIX_TradeRequestResult_TradeRequestTypeNotSupported - | FIX_TradeRequestResult_NotAuthorized - | FIX_TradeRequestResult_Other -;; - -(** Status of Trade Request.*) -type fix_traderequeststatus = - | FIX_TradeRequestStatus_Accepted - | FIX_TradeRequestStatus_Completed - | FIX_TradeRequestStatus_Rejected -;; - -(** Type of Trade Capture Report*) -type fix_traderequesttype = - | FIX_TradeRequestType_AllTrades - | FIX_TradeRequestType_MatchedTradesMatchingCriteria - | FIX_TradeRequestType_UnmatchedTradesThatMatchCriteria - | FIX_TradeRequestType_UnreportedTradesThatMatchCriteria - | FIX_TradeRequestType_AdvisoriesThatMatchCriteria -;; - -(** Driver and part of trade in the event that the Security Master file was wrong at the point of entry - (Note tag # was reserved in FIX 4.1, added in FIX 4.3)*) -type fix_tradedflatswitch = - | FIX_TradedFlatSwitch_TradedFlat - | FIX_TradedFlatSwitch_NotTradedFlat -;; - -(** Traded / Regulatory timestamp type - Note of Applicability: values are required in US futures markets by the CFTC to support computerized trade reconstruction. - (see Volume : "Glossary" for value definitions)*) -type fix_trdregtimestamptype = - | FIX_TrdRegTimestampType_ExecutionTime - | FIX_TrdRegTimestampType_TimeIn - | FIX_TrdRegTimestampType_TimeOut - | FIX_TrdRegTimestampType_BrokerReceipt - | FIX_TrdRegTimestampType_BrokerExecution -;; - -(** Trade Report Status*) -type fix_trdrptstatus = - | FIX_TrdRptStatus_Accepted - | FIX_TrdRptStatus_Rejected -;; - -(** Type of Trade*) -type fix_trdtype = - | FIX_TrdType_RegularTrade - | FIX_TrdType_BlockTrade - | FIX_TrdType_EFP - | FIX_TrdType_Transfer - | FIX_TrdType_LateTrade - | FIX_TrdType_TTrade - | FIX_TrdType_WeightedAveragePriceTrade - | FIX_TrdType_BunchedTrade - | FIX_TrdType_LateBunchedTrade - | FIX_TrdType_PriorReferencePriceTrade - | FIX_TrdType_AfterHoursTrade -;; - -(** Indicates whether or not message is being sent as a result of a subscription request or not.*) -type fix_unsolicitedindicator = - | FIX_UnsolicitedIndicator_MessageIsBeingSentUnsolicited - | FIX_UnsolicitedIndicator_MessageIsBeingSentAsAResultOfAPriorRequest -;; - -(** Urgency flag*) -type fix_urgency = - | FIX_Urgency_Normal - | FIX_Urgency_Flash - | FIX_Urgency_Background -;; - -(** Indicates the action required by a User Request Message*) -type fix_userrequesttype = - | FIX_UserRequestType_LogOnUser - | FIX_UserRequestType_LogOffUser - | FIX_UserRequestType_ChangePasswordForUser - | FIX_UserRequestType_RequestIndividualUserStatus -;; - -(** Indicates the status of a user*) -type fix_userstatus = - | FIX_UserStatus_LoggedIn - | FIX_UserStatus_NotLoggedIn - | FIX_UserStatus_UserNotRecognised - | FIX_UserStatus_PasswordIncorrect - | FIX_UserStatus_PasswordChanged - | FIX_UserStatus_Other -;; - -(** Indicates if the order is currently being worked. Applicable only for OrdStatus = "New". For open outcry markets this indicates that the order is being worked in the crowd. For electronic markets it indicates that the order has transitioned from a contingent order to a market order.*) -type fix_workingindicator = - | FIX_WorkingIndicator_Working - | FIX_WorkingIndicator_NotWorking -;; - -(** Type of yield*) -type fix_yieldtype = - | FIX_YieldType_AfterTaxYield - | FIX_YieldType_AnnualYield - | FIX_YieldType_YieldAtIssue - | FIX_YieldType_YieldToAverageMaturity - | FIX_YieldType_BookYield - | FIX_YieldType_YieldToNextCall - | FIX_YieldType_YieldChangeSinceClose - | FIX_YieldType_ClosingYield - | FIX_YieldType_CompoundYield - | FIX_YieldType_CurrentYield - | FIX_YieldType_TrueGrossYield - | FIX_YieldType_GvntEquivalentYield - | FIX_YieldType_YieldWithInflationAssumption - | FIX_YieldType_InverseFloaterBondYield - | FIX_YieldType_MostRecentClosingYield - | FIX_YieldType_ClosingYieldMostRecentMonth - | FIX_YieldType_ClosingYieldMostRecentQuarter - | FIX_YieldType_ClosingYieldMostRecentYear - | FIX_YieldType_YieldToLongestAverageLife - | FIX_YieldType_MarkToMarketYield - | FIX_YieldType_YieldToMaturity - | FIX_YieldType_YieldToNextRefund - | FIX_YieldType_OpenAverageYield - | FIX_YieldType_YieldToNextPut - | FIX_YieldType_PreviousCloseYield - | FIX_YieldType_ProceedsYield - | FIX_YieldType_SemiAnnualYield - | FIX_YieldType_YieldToShortestAverageLife - | FIX_YieldType_SimpleYield - | FIX_YieldType_TaxEquivalentYield - | FIX_YieldType_YieldToTenderDate - | FIX_YieldType_TrueYield - | FIX_YieldType_YieldValueOf132 - | FIX_YieldType_YieldToWorst -;; - -(** three letter code from ISO4217*) -type fix_currency = - | FIX_Currency_EUR - | FIX_Currency_GBP - | FIX_Currency_USD - | FIX_Currency_CHF -;; - -(** 2 letter country code - ISO 3166 *) -type fix_country = - | FIX_Country_DE - | FIX_Country_GB - | FIX_Country_US -;; - -(** ISO 10383 Market Identifier Code*) -type fix_exchange = - | FIX_Exchange_XLON - | FIX_Exchange_XNYS - | FIX_Exchange_XNAS - | FIX_Exchange_XJAS - | FIX_Exchange_XSHG - | FIX_Exchange_SHSC -;; \ No newline at end of file diff --git a/src-protocol-exts/full_app_messages.iml b/src-protocol-exts/full_app_messages.iml index 83c463c3..e6423169 100644 --- a/src-protocol-exts/full_app_messages.iml +++ b/src-protocol-exts/full_app_messages.iml @@ -1,14 +1,38 @@ -(* Imandra Inc. copyright 2019 *) +(* Imandra Inc. copyright 2021 *) [@@@import "../src-core/datetime.iml"] -[@@@import "full_app_enums.iml"] -[@@@import "full_app_records.iml"] -[@@@import "full_app_tags.iml"] -[@@@import "../src-core/numeric.iml"] open Datetime;; +[@@@import "full_app_enums.iml"] open Full_app_enums;; +[@@@import "full_app_records.iml"] open Full_app_records;; +[@@@import "full_app_tags.iml"] open Full_app_tags;; +[@@@import "../src-core/numeric.iml"] open Numeric;; +[@@@import "../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; + + +(** The new order message type is used by institutions wishing to electronically submit securities and forex orders to a broker for execution.*) +type full_fix_newordersingle_data = { +(** Unique identifier of the order as assigned by institution or by the intermediary (CIV term, not a hub/service bureau) with closest association with the investor.*) + f_NewOrderSingle_ClOrdID : string option; +(** Insert here the set of "Parties" (firm identification) fields defined in "Common Components of Application Messages"*) + f_NewOrderSingle_Parties : fix_rg_parties; + f_NewOrderSingle_Account : string option; +(** Can contain multiple instructions, space delimited. If OrdType=P, exactly one of the following values (ExecInst = L, R, M, P, O, T, W, a, d) must be specified.*) + f_NewOrderSingle_ExecInst : fix_execinst list option; + f_NewOrderSingle_Side : fix_side option; +(** Time this order request was initiated/released by the trader, trading system, or intermediary.*) + f_NewOrderSingle_TransactTime : fix_utctimestamp_milli option; +(** Insert here the set of "OrderQtyData" fields defined in "Common Components of Application Messages"*) + f_NewOrderSingle_OrderQtyData : fix_orderqtydata; + f_NewOrderSingle_OrdType : fix_ordtype option; +(** Required for limit OrdTypes. For F/X orders, should be the "all-in" rate (spot rate adjusted for forward points). Can be used to specify a limit price for a pegged order, previously indicated, etc.*) + f_NewOrderSingle_Price : fix_float_2 option; + f_NewOrderSingle_SpreadProportion : fix_float option +} +;; (** The execution report message is used to: 1. Confirm the receipt of an order @@ -19,381 +43,46 @@ open Numeric;; 6. Reject orders 7. Report post-trade fees calculations associated with a trade*) type full_fix_executionreport_data = { - (** OrderID is required to be unique for each chain of orders.*) +(** OrderID is required to be unique for each chain of orders.*) f_ExecutionReport_OrderID : string option; - (** Can be used to provide order id used by exchange or executing system.*) - f_ExecutionReport_SecondaryOrderID : string option; - f_ExecutionReport_SecondaryClOrdID : string option; - f_ExecutionReport_SecondaryExecID : string option; - (** Required for executions against electronically submitted orders which were assigned an ID by the institution or intermediary. Not required for orders manually entered by the broker or fund manager (for CIV orders).*) - f_ExecutionReport_ClOrdID : string option; - (** Conditionally required for response to an electronic Cancel or Cancel/Replace request (ExecType=PendingCancel, Replace, or Canceled). ClOrdID of the previous accepted order (NOT the initial order of the day) when canceling or replacing an order.*) - f_ExecutionReport_OrigClOrdID : string option; - f_ExecutionReport_ClOrdLinkID : string option; - (** Required if responding to a QuoteResponse message. Echo back the Initiator’s value specified in the message.*) - f_ExecutionReport_QuoteRespID : string option; - (** Required if responding to and if provided on the Order Status Request message. Echo back the value provided by the requester.*) - f_ExecutionReport_OrdStatusReqID : string option; - (** Required if responding to a Order Mass Status Request. Echo back the value provided by the requester.*) - f_ExecutionReport_MassStatusReqID : string option; - (** Can be used when responding to an Order Mass Status Request to identify the total number of Execution Reports which will be returned.*) - f_ExecutionReport_TotNumReports : int option; - (** Can be used when responding to an Order Mass Status Request to indicate that this is the last Execution Reports which will be returned as a result of the request.*) - f_ExecutionReport_LastRptRequested : bool option; - (** Insert here the set of "Parties" (firm identification) fields defined in "Common Components of Application Messages"*) +(** Insert here the set of "Parties" (firm identification) fields defined in "Common Components of Application Messages"*) f_ExecutionReport_Parties : fix_rg_parties; - f_ExecutionReport_TradeOriginationDate : fix_localmktdate option; - (** Number of ContraBrokers repeating group instances.*) - f_ExecutionReport_ContraGrp : fix_rg_contragrp; - (** Required for executions against orders which were submitted as part of a list.*) - f_ExecutionReport_ListID : string option; - (** CrossID for the replacement order*) - f_ExecutionReport_CrossID : string option; - (** Must match original cross order. Same order chaining mechanism as ClOrdID/OrigClOrdID with single order Cancel/Replace.*) - f_ExecutionReport_OrigCrossID : string option; - f_ExecutionReport_CrossType : fix_crosstype option; - (** Unique identifier of execution message as assigned by sell-side (broker, exchange, ECN) (will be 0 (zero) forExecType=I (Order Status)).*) +(** Unique identifier of execution message as assigned by sell-side (broker, exchange, ECN) (will be 0 (zero) forExecType=I (Order Status)).*) f_ExecutionReport_ExecID : string option; - (** Required for Trade Cancel and Trade Correct ExecType messages*) - f_ExecutionReport_ExecRefID : string option; - (** Describes the purpose of the execution report.*) +(** Describes the purpose of the execution report.*) f_ExecutionReport_ExecType : fix_exectype option; - (** Describes the current state of a CHAIN of orders, same scope as OrderQty, CumQty, LeavesQty, and AvgPx*) +(** Describes the current state of a CHAIN of orders, same scope as OrderQty, CumQty, LeavesQty, and AvgPx*) f_ExecutionReport_OrdStatus : fix_ordstatus option; - (** For optional use with OrdStatus = 0 (New)*) - f_ExecutionReport_WorkingIndicator : fix_workingindicator option; - (** For optional use with ExecType = 8 (Rejected)*) - f_ExecutionReport_OrdRejReason : fix_ordrejreason option; - (** Required for ExecType = D (Restated).*) - f_ExecutionReport_ExecRestatementReason : fix_execrestatementreason option; - (** Required for executions against electronically submitted orders which were assigned an account by the institution or intermediary*) - f_ExecutionReport_Account : string option; - f_ExecutionReport_AcctIDSource : fix_acctidsource option; - (** Specifies type of account*) - f_ExecutionReport_AccountType : fix_accounttype option; - f_ExecutionReport_DayBookingInst : fix_daybookinginst option; - f_ExecutionReport_BookingUnit : fix_bookingunit option; - f_ExecutionReport_PreallocMethod : fix_preallocmethod option; - f_ExecutionReport_SettlType : fix_settltype option; - (** Takes precedence over SettlType value and conditionally required/omitted for specific SettlType values.*) - f_ExecutionReport_SettlDate : fix_localmktdate option; - f_ExecutionReport_CashMargin : fix_cashmargin option; - f_ExecutionReport_ClearingFeeIndicator : fix_clearingfeeindicator option; - (** Insert here the set of "Instrument" (symbology) fields defined in "Common Components of Application Messages"*) - f_ExecutionReport_Instrument : fix_instrument; - (** Insert here the set of "FinancingDetails" (symbology) fields defined in "Common Components of Application Messages"*) - f_ExecutionReport_FinancingDetails : fix_financingdetails; - (** Number of underlyings*) - f_ExecutionReport_UndInstrmtGrp : fix_rg_undinstrmtgrp; f_ExecutionReport_Side : fix_side option; - (** Insert here the set of "Stipulations" (repeating group of Fixed Income stipulations) fields defined in "Common Components of Application Messages"*) - f_ExecutionReport_Stipulations : fix_rg_stipulations; - f_ExecutionReport_QtyType : fix_qtytype option; - (** Insert here the set of "OrderQtyData" fields defined in "Common Components of Application Messages" - **Note: OrderQty field is required for Single Instrument Orders unless rejecting or acknowledging an order for a CashOrderQty or PercentOrder.*) +(** Insert here the set of "OrderQtyData" fields defined in "Common Components of Application Messages" + **Note: OrderQty field is required for Single Instrument Orders unless rejecting or acknowledging an order for a CashOrderQty or PercentOrder.*) f_ExecutionReport_OrderQtyData : fix_orderqtydata; - f_ExecutionReport_OrdType : fix_ordtype option; - f_ExecutionReport_PriceType : fix_pricetype option; - (** Required if specified on the order*) - f_ExecutionReport_Price : fix_float_6 option; - (** Required if specified on the order*) - f_ExecutionReport_StopPx : fix_float_6 option; - (** Insert here the set of "PegInstruction" fields defined in "Common Components of Application Messages"*) - f_ExecutionReport_PegInstructions : fix_peginstructions; - (** Insert here the set of "DiscretionInstruction" fields defined in "Common Components of Application Messages"*) - f_ExecutionReport_DiscretionInstructions : fix_discretioninstructions; - (** The current price the order is pegged at*) - f_ExecutionReport_PeggedPrice : fix_float_6 option; - (** The current discretionary price of the order*) - f_ExecutionReport_DiscretionPrice : fix_float_6 option; - (** The target strategy of the order*) - f_ExecutionReport_TargetStrategy : fix_targetstrategy option; - (** For further specification of the TargetStrategy*) - f_ExecutionReport_TargetStrategyParameters : string option; - (** Mandatory for a TargetStrategy=Participate order and specifies the target particpation rate. - For other order types optionally specifies a volume limit (i.e. do not be more than this percent of the market volume)*) - f_ExecutionReport_ParticipationRate : fix_float_6 option; - (** For communication of the performance of the order versus the target strategy*) - f_ExecutionReport_TargetStrategyPerformance : fix_float option; - f_ExecutionReport_Currency : fix_currency option; - f_ExecutionReport_ComplianceID : string option; - f_ExecutionReport_SolicitedFlag : fix_solicitedflag option; - (** Absence of this field indicates Day order*) - f_ExecutionReport_TimeInForce : fix_timeinforce option; - (** Time specified on the order at which the order should be considered valid*) - f_ExecutionReport_EffectiveTime : fix_utctimestamp_milli option; - (** Conditionally required if TimeInForce = GTD and ExpireTime is not specified.*) - f_ExecutionReport_ExpireDate : fix_localmktdate option; - (** Conditionally required if TimeInForce = GTD and ExpireDate is not specified.*) - f_ExecutionReport_ExpireTime : fix_utctimestamp_milli option; - (** Can contain multiple instructions, space delimited.*) +(** Can contain multiple instructions, space delimited.*) f_ExecutionReport_ExecInst : fix_execinst list option; - f_ExecutionReport_OrderCapacity : fix_ordercapacity option; - f_ExecutionReport_OrderRestrictions : fix_orderrestrictions list option; - f_ExecutionReport_CustOrderCapacity : fix_custordercapacity option; - (** Quantity (e.g. shares) bought/sold on this (last) fill. Required if ExecType = Trade or Trade Correct. - If ExecType=Stopped, represents the quantity stopped/guaranteed/protected for.*) - f_ExecutionReport_LastQty : fix_float_6 option; - f_ExecutionReport_UnderlyingLastQty : fix_float_6 option; - (** Price of this (last) fill. Required if ExecType = Trade or Trade Correct. - Should represent the "all-in" (LastSpotRate + LastForwardPoints) rate for F/X orders. ). - If ExecType=Stopped, represents the price stopped/guaranteed/protected at.*) - f_ExecutionReport_LastPx : fix_float_6 option; - f_ExecutionReport_UnderlyingLastPx : fix_float_6 option; - (** Last price expressed in percent-of-par. Conditionally required for Fixed Income trades when LastPx is expressed in Yield, Spread, Discount or any other price type that is not percent-of-par.*) - f_ExecutionReport_LastParPx : fix_float_6 option; - (** Applicable for F/X orders*) - f_ExecutionReport_LastSpotRate : fix_float_6 option; - (** Applicable for F/X orders*) - f_ExecutionReport_LastForwardPoints : fix_float_6 option; - (** If ExecType = Trade (F), indicates the market where the trade was executed. If ExecType = New (0), indicates the market where the order was routed.*) - f_ExecutionReport_LastMkt : fix_exchange option; - f_ExecutionReport_TradingSessionID : string option; - f_ExecutionReport_TradingSessionSubID : string option; - f_ExecutionReport_TimeBracket : string option; - f_ExecutionReport_LastCapacity : fix_lastcapacity option; - (** Quantity open for further execution. If the OrdStatus is Canceled, DoneForTheDay, Expired, Calculated, or Rejected (in which case the order is no longer active) then LeavesQty could be 0, otherwise LeavesQty = OrderQty - CumQty.*) +(** Quantity open for further execution. If the OrdStatus is Canceled, DoneForTheDay, Expired, Calculated, or Rejected (in which case the order is no longer active) then LeavesQty could be 0, otherwise LeavesQty = OrderQty - CumQty.*) f_ExecutionReport_LeavesQty : fix_float_6 option; - (** Currently executed quantity for chain of orders.*) +(** Currently executed quantity for chain of orders.*) f_ExecutionReport_CumQty : fix_float_6 option; - f_ExecutionReport_AvgPx : fix_float_6 option; - (** For GT orders on days following the day of the first trade.*) - f_ExecutionReport_DayOrderQty : fix_float_6 option; - (** For GT orders on days following the day of the first trade.*) - f_ExecutionReport_DayCumQty : fix_float_6 option; - (** For GT orders on days following the day of the first trade.*) - f_ExecutionReport_DayAvgPx : fix_float_6 option; - (** States whether executions are booked out or accumulated on a partially filled GT order*) - f_ExecutionReport_GTBookingInst : fix_gtbookinginst option; - (** Used when reporting other than current day trades.*) - f_ExecutionReport_TradeDate : fix_localmktdate option; - (** Time the transaction represented by this ExecutionReport occurred*) - f_ExecutionReport_TransactTime : fix_utctimestamp_milli option; - f_ExecutionReport_ReportToExch : fix_reporttoexch option; - (** Insert here the set of "CommissionData" fields defined in "Common Components of Application Messages" - Note: On a fill/partial fill messages, it represents value for that fill/partial fill. On ExecType=Calculated, it represents cumulative value for the order. Monetary commission values are expressed in the currency reflected by the Currency field.*) - f_ExecutionReport_CommissionData : fix_commissiondata; - (** Insert here the set of "SpreadOrBenchmarkCurveData" (Fixed Income spread or benchmark curve) fields defined in "Common Components of Application Messages"*) - f_ExecutionReport_SpreadOrBenchmarkCurveData : fix_spreadorbenchmarkcurvedata; - (** Insert here the set of "YieldData" (yield-related) fields defined in "Common Components of Application Messages"*) - f_ExecutionReport_YieldData : fix_yielddata; - f_ExecutionReport_GrossTradeAmt : fix_float_6 option; - f_ExecutionReport_NumDaysInterest : int option; - f_ExecutionReport_ExDate : fix_localmktdate option; - f_ExecutionReport_AccruedInterestRate : fix_float_6 option; - f_ExecutionReport_AccruedInterestAmt : fix_float_6 option; - (** For fixed income products which pay lump-sum interest at maturity.*) - f_ExecutionReport_InterestAtMaturity : fix_float_6 option; - (** For repurchase agreements the accrued interest on termination.*) - f_ExecutionReport_EndAccruedInterestAmt : fix_float_6 option; - (** For repurchase agreements the start (dirty) cash consideration*) - f_ExecutionReport_StartCash : fix_float_6 option; - (** For repurchase agreements the end (dirty) cash consideration*) - f_ExecutionReport_EndCash : fix_float_6 option; - f_ExecutionReport_TradedFlatSwitch : fix_tradedflatswitch option; - f_ExecutionReport_BasisFeatureDate : fix_localmktdate option; - f_ExecutionReport_BasisFeaturePrice : fix_float_6 option; - f_ExecutionReport_Concession : fix_float_6 option; - f_ExecutionReport_TotalTakedown : fix_float_6 option; - (** Note: On a fill/partial fill messages, it represents value for that fill/partial fill, on ExecType=Calculated, it represents cumulative value for the order. Value expressed in the currency reflected by the Currency field.*) - f_ExecutionReport_NetMoney : fix_float_6 option; - (** Used to report results of forex accommodation trade*) - f_ExecutionReport_SettlCurrAmt : fix_float_6 option; - (** Used to report results of forex accommodation trade*) - f_ExecutionReport_SettlCurrency : fix_currency option; - (** Foreign exchange rate used to compute SettlCurrAmt from Currency to SettlCurrency*) - f_ExecutionReport_SettlCurrFxRate : fix_float option; - (** Specifies whether the SettlCurrFxRate should be multiplied or divided*) - f_ExecutionReport_SettlCurrFxRateCalc : fix_settlcurrfxratecalc option; - f_ExecutionReport_HandlInst : fix_handlinst option; - f_ExecutionReport_MinQty : fix_float_6 option; - f_ExecutionReport_MaxFloor : fix_float_6 option; - (** For use in derivatives omnibus accounting*) - f_ExecutionReport_PositionEffect : fix_positioneffect option; - f_ExecutionReport_MaxShow : fix_float_6 option; - (** Method for booking out this order. Used when notifying a broker that an order to be settled by that broker is to be booked out as an OTC derivative (e.g. CFD or similar). Absence of this field implies regular booking.*) - f_ExecutionReport_BookingType : fix_bookingtype option; - f_ExecutionReport_Text : string option; - (** Must be set if EncodedText field is specified and must immediately precede it.*) - f_ExecutionReport_EncodedTextLen : int option; - (** Encoded (non-ASCII characters) representation of the Text field in the encoded format specified via the MessageEncoding field.*) - f_ExecutionReport_EncodedText : string option; - (** Can be used with OrdType = "Forex - Swap" to specify the "value date" for the future portion of a F/X swap.*) - f_ExecutionReport_SettlDate2 : fix_localmktdate option; - (** Can be used with OrdType = "Forex - Swap" to specify the order quantity for the future portion of a F/X swap.*) - f_ExecutionReport_OrderQty2 : fix_float_6 option; - (** Can be used with OrdType = "Forex - Swap" to specify the forward points (added to LastSpotRate) for the future portion of a F/X swap.*) - f_ExecutionReport_LastForwardPoints2 : fix_float_6 option; - (** Default is a single security if not specified.*) - f_ExecutionReport_MultiLegReportingType : fix_multilegreportingtype option; - (** For CIV - Optional*) - f_ExecutionReport_CancellationRights : fix_cancellationrights option; - f_ExecutionReport_MoneyLaunderingStatus : fix_moneylaunderingstatus option; - (** Reference to Registration Instructions message for this Order.*) - f_ExecutionReport_RegistID : string option; - (** Supplementary registration information for this Order*) - f_ExecutionReport_Designation : string option; - (** For CIV - Optional*) - f_ExecutionReport_TransBkdTime : fix_utctimestamp_milli option; - (** For CIV - Optional*) - f_ExecutionReport_ExecValuationPoint : fix_utctimestamp_milli option; - (** For CIV - Optional*) - f_ExecutionReport_ExecPriceType : fix_execpricetype option; - (** For CIV - Optional*) - f_ExecutionReport_ExecPriceAdjustment : fix_float option; - f_ExecutionReport_PriorityIndicator : fix_priorityindicator option; - f_ExecutionReport_PriceImprovement : fix_float_6 option; - (** Applicable only on OrdStatus of Partial or Filled.*) - f_ExecutionReport_LastLiquidityInd : fix_lastliquidityind option; - (** Number of contract details in this message (number of repeating groups to follow)*) - f_ExecutionReport_ContAmtGrp : fix_rg_contamtgrp; - (** Number of legs - Identifies a Multi-leg Execution if present and non-zero.*) - f_ExecutionReport_InstrmtLegExecGrp : fix_rg_instrmtlegexecgrp; - f_ExecutionReport_CopyMsgIndicator : bool option; - (** Required if any miscellaneous fees are reported. Indicates number of repeating entries. Repeating group. - ** Nested Repeating Group follows ***) - f_ExecutionReport_MiscFeesGrp : fix_rg_miscfeesgrp -} -;; - -(** The new order message type is used by institutions wishing to electronically submit securities and forex orders to a broker for execution.*) -type full_fix_newordersingle_data = { - (** Unique identifier of the order as assigned by institution or by the intermediary (CIV term, not a hub/service bureau) with closest association with the investor.*) - f_NewOrderSingle_ClOrdID : string option; - f_NewOrderSingle_SecondaryClOrdID : string option; - f_NewOrderSingle_ClOrdLinkID : string option; - (** Insert here the set of "Parties" (firm identification) fields defined in "Common Components of Application Messages"*) - f_NewOrderSingle_Parties : fix_rg_parties; - f_NewOrderSingle_TradeOriginationDate : fix_localmktdate option; - f_NewOrderSingle_TradeDate : fix_localmktdate option; - f_NewOrderSingle_Account : string option; - f_NewOrderSingle_AcctIDSource : fix_acctidsource option; - (** Type of account associated with the order (Origin)*) - f_NewOrderSingle_AccountType : fix_accounttype option; - f_NewOrderSingle_DayBookingInst : fix_daybookinginst option; - f_NewOrderSingle_BookingUnit : fix_bookingunit option; - f_NewOrderSingle_PreallocMethod : fix_preallocmethod option; - (** Used to assign an overall allocation id to the block of preallocations*) - f_NewOrderSingle_AllocID : string option; - (** Number of repeating groups for pre-trade allocation*) - f_NewOrderSingle_PreAllocGrp : fix_rg_preallocgrp; - f_NewOrderSingle_SettlType : fix_settltype option; - (** Takes precedence over SettlType value and conditionally required/omitted for specific SettlType values.*) - f_NewOrderSingle_SettlDate : fix_localmktdate option; - f_NewOrderSingle_CashMargin : fix_cashmargin option; - f_NewOrderSingle_ClearingFeeIndicator : fix_clearingfeeindicator option; - f_NewOrderSingle_HandlInst : fix_handlinst option; - (** Can contain multiple instructions, space delimited. If OrdType=P, exactly one of the following values (ExecInst = L, R, M, P, O, T, W, a, d) must be specified.*) - f_NewOrderSingle_ExecInst : fix_execinst list option; - f_NewOrderSingle_MinQty : fix_float_6 option; - f_NewOrderSingle_MaxFloor : fix_float_6 option; - f_NewOrderSingle_ExDestination : fix_exchange option; - (** Specifies the number of repeating TradingSessionIDs*) - f_NewOrderSingle_TrdgSesGrp : fix_rg_trdgsesgrp; - (** Used to identify soft trades at order entry.*) - f_NewOrderSingle_ProcessCode : fix_processcode option; - (** Insert here the set of "Instrument" (symbology) fields defined in "Common Components of Application Messages"*) - f_NewOrderSingle_Instrument : fix_instrument; - (** Insert here the set of "FinancingDetails" (symbology) fields defined in "Common Components of Application Messages"*) - f_NewOrderSingle_FinancingDetails : fix_financingdetails; - (** Number of underlyings*) - f_NewOrderSingle_UndInstrmtGrp : fix_rg_undinstrmtgrp; - (** Useful for verifying security identification*) - f_NewOrderSingle_PrevClosePx : fix_float_6 option; - f_NewOrderSingle_Side : fix_side option; - (** Required for short sell orders*) - f_NewOrderSingle_LocateReqd : fix_locatereqd option; - (** Time this order request was initiated/released by the trader, trading system, or intermediary.*) - f_NewOrderSingle_TransactTime : fix_utctimestamp_milli option; - (** Insert here the set of "Stipulations" (repeating group of Fixed Income stipulations) fields defined in "Common Components of Application Messages"*) - f_NewOrderSingle_Stipulations : fix_rg_stipulations; - f_NewOrderSingle_QtyType : fix_qtytype option; - (** Insert here the set of "OrderQtyData" fields defined in "Common Components of Application Messages"*) - f_NewOrderSingle_OrderQtyData : fix_orderqtydata; - f_NewOrderSingle_OrdType : fix_ordtype option; - f_NewOrderSingle_PriceType : fix_pricetype option; - (** Required for limit OrdTypes. For F/X orders, should be the "all-in" rate (spot rate adjusted for forward points). Can be used to specify a limit price for a pegged order, previously indicated, etc.*) - f_NewOrderSingle_Price : fix_float_6 option; - (** Required for OrdType = "Stop" or OrdType = "Stop limit".*) - f_NewOrderSingle_StopPx : fix_float_6 option; - (** Insert here the set of "SpreadOrBenchmarkCurveData" (Fixed Income spread or benchmark curve) fields defined in "Common Components of Application Messages"*) - f_NewOrderSingle_SpreadOrBenchmarkCurveData : fix_spreadorbenchmarkcurvedata; - (** Insert here the set of "YieldData" (yield-related) fields defined in "Common Components of Application Messages"*) - f_NewOrderSingle_YieldData : fix_yielddata; - f_NewOrderSingle_Currency : fix_currency option; - f_NewOrderSingle_ComplianceID : string option; - f_NewOrderSingle_SolicitedFlag : fix_solicitedflag option; - (** Required for Previously Indicated Orders (OrdType=E)*) - f_NewOrderSingle_IOIID : string option; - (** Required for Previously Quoted Orders (OrdType=D)*) - f_NewOrderSingle_QuoteID : string option; - (** Absence of this field indicates Day order*) - f_NewOrderSingle_TimeInForce : fix_timeinforce option; - (** Can specify the time at which the order should be considered valid*) - f_NewOrderSingle_EffectiveTime : fix_utctimestamp_milli option; - (** Conditionally required if TimeInForce = GTD and ExpireTime is not specified.*) - f_NewOrderSingle_ExpireDate : fix_localmktdate option; - (** Conditionally required if TimeInForce = GTD and ExpireDate is not specified.*) - f_NewOrderSingle_ExpireTime : fix_utctimestamp_milli option; - (** States whether executions are booked out or accumulated on a partially filled GT order*) - f_NewOrderSingle_GTBookingInst : fix_gtbookinginst option; - (** Insert here the set of "CommissionData" fields defined in "Common Components of Application Messages"*) - f_NewOrderSingle_CommissionData : fix_commissiondata; - f_NewOrderSingle_OrderCapacity : fix_ordercapacity option; - f_NewOrderSingle_OrderRestrictions : fix_orderrestrictions list option; - f_NewOrderSingle_CustOrderCapacity : fix_custordercapacity option; - (** Indicates that broker is requested to execute a Forex accommodation trade in conjunction with the security trade.*) - f_NewOrderSingle_ForexReq : fix_forexreq option; - (** Required if ForexReq = Y.*) - f_NewOrderSingle_SettlCurrency : fix_currency option; - (** Method for booking out this order. Used when notifying a broker that an order to be settled by that broker is to be booked out as an OTC derivative (e.g. CFD or similar). Absence of this field implies regular booking.*) - f_NewOrderSingle_BookingType : fix_bookingtype option; - f_NewOrderSingle_Text : string option; - (** Must be set if EncodedText field is specified and must immediately precede it.*) - f_NewOrderSingle_EncodedTextLen : int option; - (** Encoded (non-ASCII characters) representation of the Text field in the encoded format specified via the MessageEncoding field.*) - f_NewOrderSingle_EncodedText : string option; - (** Can be used with OrdType = "Forex - Swap" to specify the "value date" for the future portion of a F/X swap.*) - f_NewOrderSingle_SettlDate2 : fix_localmktdate option; - (** Can be used with OrdType = "Forex - Swap" to specify the order quantity for the future portion of a F/X swap.*) - f_NewOrderSingle_OrderQty2 : fix_float_6 option; - (** Can be used with OrdType = "Forex - Swap" to specify the price for the future portion of a F/X swap which is also a limit order. For F/X orders, should be the "all-in" rate (spot rate adjusted for forward points).*) - f_NewOrderSingle_Price2 : fix_float_6 option; - (** For use in derivatives omnibus accounting*) - f_NewOrderSingle_PositionEffect : fix_positioneffect option; - (** For use with derivatives, such as options*) - f_NewOrderSingle_CoveredOrUncovered : fix_coveredoruncovered option; - f_NewOrderSingle_MaxShow : fix_float_6 option; - (** Insert here the set of "PegInstruction" fields defined in "Common Components of Application Messages"*) - f_NewOrderSingle_PegInstructions : fix_peginstructions; - (** Insert here the set of "DiscretionInstruction" fields defined in "Common Components of Application Messages"*) - f_NewOrderSingle_DiscretionInstructions : fix_discretioninstructions; - (** The target strategy of the order*) - f_NewOrderSingle_TargetStrategy : fix_targetstrategy option; - (** For further specification of the TargetStrategy*) - f_NewOrderSingle_TargetStrategyParameters : string option; - (** Mandatory for a TargetStrategy=Participate order and specifies the target particpation rate. - For other order types optionally specifies a volume limit (i.e. do not be more than this percent of the market volume)*) - f_NewOrderSingle_ParticipationRate : fix_float_6 option; - (** For CIV - Optional*) - f_NewOrderSingle_CancellationRights : fix_cancellationrights option; - f_NewOrderSingle_MoneyLaunderingStatus : fix_moneylaunderingstatus option; - (** Reference to Registration Instructions message for this Order.*) - f_NewOrderSingle_RegistID : string option; - (** Supplementary registration information for this Order*) - f_NewOrderSingle_Designation : string option + f_ExecutionReport_Text : string option } ;; type full_app_msg_data = - | FIX_Full_Msg_ExecutionReport of full_fix_executionreport_data | FIX_Full_Msg_NewOrderSingle of full_fix_newordersingle_data + | FIX_Full_Msg_ExecutionReport of full_fix_executionreport_data ;; let get_full_app_msg_tag (msg : full_app_msg_data) = (match msg with - | FIX_Full_Msg_ExecutionReport _ -> Full_Msg_ExecutionReport_Tag | FIX_Full_Msg_NewOrderSingle _ -> Full_Msg_NewOrderSingle_Tag + | FIX_Full_Msg_ExecutionReport _ -> Full_Msg_ExecutionReport_Tag ) ;; + +let is_full_message_inbound (msg : full_app_msg_data) = + (match msg with + | FIX_Full_Msg_NewOrderSingle _ -> true + | FIX_Full_Msg_ExecutionReport _ -> false + ) +;; + diff --git a/src-protocol-exts/full_app_records.iml b/src-protocol-exts/full_app_records.iml index 10987ddb..def10b0f 100644 --- a/src-protocol-exts/full_app_records.iml +++ b/src-protocol-exts/full_app_records.iml @@ -1,2034 +1,44 @@ -(* Imandra Inc. copyright 2019 *) +(* Imandra Inc. copyright 2021 *) [@@@import "../src-core/datetime.iml"] -[@@@import "full_app_enums.iml"] +open Datetime;; [@@@import "../src-core/numeric.iml"] open Numeric;; -open Datetime;; -open Full_app_enums;; - -type fix_rg_inner_logonmsgtypes = { - (** Specifies the number of repeating RefMsgTypes specified*) - f_LogonMsgTypes_NoMsgTypes : int option; - (** Specifies a specific, supported MsgType. Required if NoMsgTypes is > 0. Should be specified from the point of view of the sender of the Logon message*) - f_LogonMsgTypes_RefMsgType : string option; - (** Indicates direction (send vs. receive) of a supported MsgType. Required if NoMsgTypes is > 0. Should be specified from the point of view of the sender of the Logon message*) - f_LogonMsgTypes_MsgDirection : fix_msgdirection option -} -;; - -type fix_rg_logonmsgtypes = fix_rg_inner_logonmsgtypes list -;; - -type fix_rg_inner_mdreqgrp = { - f_MDReqGrp_NoMDEntryTypes : int option; - f_MDReqGrp_MDEntryType : fix_mdentrytype option -} -;; - -type fix_rg_mdreqgrp = fix_rg_inner_mdreqgrp list -;; - -type fix_rg_inner_underlyingstipulations = { - f_UnderlyingStipulations_NoUnderlyingStips : int option; - (** Required if NoUnderlyingStips >0*) - f_UnderlyingStipulations_UnderlyingStipType : string option; - f_UnderlyingStipulations_UnderlyingStipValue : string option -} -;; - -type fix_rg_underlyingstipulations = fix_rg_inner_underlyingstipulations list -;; - -type fix_rg_inner_evntgrp = { - f_EvntGrp_NoEvents : int option; - f_EvntGrp_EventType : fix_eventtype option; - f_EvntGrp_EventDate : fix_localmktdate option; - f_EvntGrp_EventPx : fix_float_6 option; - f_EvntGrp_EventText : string option -} -;; - -type fix_rg_evntgrp = fix_rg_inner_evntgrp list -;; - -type fix_rg_inner_mdfullgrp = { - f_MDFullGrp_NoMDEntries : int option; - f_MDFullGrp_MDEntryType : fix_mdentrytype option; - f_MDFullGrp_MDEntryPx : fix_float_6 option; - f_MDFullGrp_Currency : fix_currency option; - f_MDFullGrp_MDEntrySize : fix_float_6 option; - f_MDFullGrp_MDEntryDate : fix_utcdateonly option; - f_MDFullGrp_MDEntryTime : fix_utctimeonly_milli option; - f_MDFullGrp_TickDirection : fix_tickdirection option; - f_MDFullGrp_MDMkt : fix_exchange option; - f_MDFullGrp_TradingSessionID : string option; - f_MDFullGrp_TradingSessionSubID : string option; - f_MDFullGrp_QuoteCondition : fix_quotecondition list option; - f_MDFullGrp_TradeCondition : fix_tradecondition list option; - f_MDFullGrp_MDEntryOriginator : string option; - f_MDFullGrp_LocationID : string option; - f_MDFullGrp_DeskID : string option; - f_MDFullGrp_OpenCloseSettlFlag : fix_openclosesettlflag list option; - f_MDFullGrp_TimeInForce : fix_timeinforce option; - f_MDFullGrp_ExpireDate : fix_localmktdate option; - f_MDFullGrp_ExpireTime : fix_utctimestamp_milli option; - f_MDFullGrp_MinQty : fix_float_6 option; - f_MDFullGrp_ExecInst : fix_execinst list option; - f_MDFullGrp_SellerDays : int option; - f_MDFullGrp_OrderID : string option; - f_MDFullGrp_QuoteEntryID : string option; - f_MDFullGrp_MDEntryBuyer : string option; - f_MDFullGrp_MDEntrySeller : string option; - f_MDFullGrp_NumberOfOrders : int option; - f_MDFullGrp_MDEntryPositionNo : int option; - f_MDFullGrp_Scope : fix_scope list option; - f_MDFullGrp_PriceDelta : fix_float option; - f_MDFullGrp_Text : string option; - f_MDFullGrp_EncodedTextLen : int option; - f_MDFullGrp_EncodedText : string option -} -;; - -type fix_rg_mdfullgrp = fix_rg_inner_mdfullgrp list -;; - -type fix_rg_inner_undsecaltidgrp = { - f_UndSecAltIDGrp_NoUnderlyingSecurityAltID : int option; - f_UndSecAltIDGrp_UnderlyingSecurityAltID : string option; - f_UndSecAltIDGrp_UnderlyingSecurityAltIDSource : string option -} -;; - -type fix_rg_undsecaltidgrp = fix_rg_inner_undsecaltidgrp list -;; - -type fix_rg_inner_linesoftextgrp = { - f_LinesOfTextGrp_NoLinesOfText : int option; - f_LinesOfTextGrp_Text : string option; - f_LinesOfTextGrp_EncodedTextLen : int option; - f_LinesOfTextGrp_EncodedText : string option -} -;; - -type fix_rg_linesoftextgrp = fix_rg_inner_linesoftextgrp list -;; - -type fix_rg_inner_legsecaltidgrp = { - f_LegSecAltIDGrp_NoLegSecurityAltID : int option; - f_LegSecAltIDGrp_LegSecurityAltID : string option; - f_LegSecAltIDGrp_LegSecurityAltIDSource : string option -} -;; - -type fix_rg_legsecaltidgrp = fix_rg_inner_legsecaltidgrp list -;; - -type fix_spreadorbenchmarkcurvedata = { - (** For Fixed Income*) - f_SpreadOrBenchmarkCurveData_Spread : fix_float_6 option; - f_SpreadOrBenchmarkCurveData_BenchmarkCurveCurrency : fix_currency option; - f_SpreadOrBenchmarkCurveData_BenchmarkCurveName : string option; - f_SpreadOrBenchmarkCurveData_BenchmarkCurvePoint : string option; - f_SpreadOrBenchmarkCurveData_BenchmarkPrice : fix_float_6 option; - (** Must be present if BenchmarkPrice is used.*) - f_SpreadOrBenchmarkCurveData_BenchmarkPriceType : int option; - (** The identifier of the benchmark security, e.g. Treasury against Corporate bond.*) - f_SpreadOrBenchmarkCurveData_BenchmarkSecurityID : string option; - (** Source of BenchmarkSecurityID. If not specified, then ID Source is understood to be the same as that in the Instrument block.*) - f_SpreadOrBenchmarkCurveData_BenchmarkSecurityIDSource : string option -} -;; - -type fix_rg_inner_miscfeesgrp = { - f_MiscFeesGrp_NoMiscFees : int option; - f_MiscFeesGrp_MiscFeeAmt : fix_float_6 option; - f_MiscFeesGrp_MiscFeeCurr : fix_currency option; - f_MiscFeesGrp_MiscFeeType : fix_miscfeetype option; - f_MiscFeesGrp_MiscFeeBasis : fix_miscfeebasis option -} -;; - -type fix_rg_miscfeesgrp = fix_rg_inner_miscfeesgrp list -;; - -type fix_rg_inner_trdgsesgrp = { - f_TrdgSesGrp_NoTradingSessions : int option; - f_TrdgSesGrp_TradingSessionID : string option; - f_TrdgSesGrp_TradingSessionSubID : string option -} -;; - -type fix_rg_trdgsesgrp = fix_rg_inner_trdgsesgrp list -;; - -type fix_rg_inner_contragrp = { - f_ContraGrp_NoContraBrokers : int option; - f_ContraGrp_ContraBroker : string option; - f_ContraGrp_ContraTrader : string option; - f_ContraGrp_ContraTradeQty : fix_float_6 option; - f_ContraGrp_ContraTradeTime : fix_utctimestamp_milli option; - f_ContraGrp_ContraLegRefID : string option -} -;; - -type fix_rg_contragrp = fix_rg_inner_contragrp list -;; - -type fix_rg_inner_bidcompreqgrp = { - f_BidCompReqGrp_NoBidComponents : int option; - f_BidCompReqGrp_ListID : string option; - f_BidCompReqGrp_Side : fix_side option; - f_BidCompReqGrp_TradingSessionID : string option; - f_BidCompReqGrp_TradingSessionSubID : string option; - f_BidCompReqGrp_NetGrossInd : fix_netgrossind option; - f_BidCompReqGrp_SettlType : fix_settltype option; - f_BidCompReqGrp_SettlDate : fix_localmktdate option; - f_BidCompReqGrp_Account : string option; - f_BidCompReqGrp_AcctIDSource : fix_acctidsource option -} -;; - -type fix_rg_bidcompreqgrp = fix_rg_inner_bidcompreqgrp list -;; - -type fix_rg_inner_contamtgrp = { - f_ContAmtGrp_NoContAmts : int option; - f_ContAmtGrp_ContAmtType : fix_contamttype option; - f_ContAmtGrp_ContAmtValue : fix_float option; - f_ContAmtGrp_ContAmtCurr : fix_currency option -} -;; - -type fix_rg_contamtgrp = fix_rg_inner_contamtgrp list -;; - -type fix_rg_inner_collinqqualgrp = { - f_CollInqQualGrp_NoCollInquiryQualifier : int option; - f_CollInqQualGrp_CollInquiryQualifier : fix_collinquiryqualifier option -} -;; +[@@@import "../src-core-time-defaults/time_defaults.iml"] +open Time_defaults;; -type fix_rg_collinqqualgrp = fix_rg_inner_collinqqualgrp list -;; - -type fix_rg_inner_execsgrp = { - f_ExecsGrp_NoExecs : int option; - f_ExecsGrp_ExecID : string option -} -;; - -type fix_rg_execsgrp = fix_rg_inner_execsgrp list -;; - -type fix_rg_inner_allocackgrp = { - f_AllocAckGrp_NoAllocs : int option; - f_AllocAckGrp_AllocAccount : string option; - f_AllocAckGrp_AllocAcctIDSource : int option; - f_AllocAckGrp_AllocPrice : fix_float_6 option; - f_AllocAckGrp_IndividualAllocID : string option; - f_AllocAckGrp_IndividualAllocRejCode : int option; - f_AllocAckGrp_AllocText : string option; - f_AllocAckGrp_EncodedAllocTextLen : int option; - f_AllocAckGrp_EncodedAllocText : string option -} -;; - -type fix_rg_allocackgrp = fix_rg_inner_allocackgrp list -;; - -type fix_discretioninstructions = { - (** What the discretionary price is related to (e.g. primary price, display price etc)*) - f_DiscretionInstructions_DiscretionInst : fix_discretioninst option; - (** Amount (signed) added to the "related to" price specified via DiscretionInst, in the context of DiscretionOffsetType*) - f_DiscretionInstructions_DiscretionOffsetValue : fix_float option; - (** Describes whether discretion price is static/fixed or floats*) - f_DiscretionInstructions_DiscretionMoveType : fix_discretionmovetype option; - (** Type of Discretion Offset (e.g. price offset, tick offset etc)*) - f_DiscretionInstructions_DiscretionOffsetType : fix_discretionoffsettype option; - (** Specifies the nature of the resulting discretion price (e.g. or better limit, strict limit etc)*) - f_DiscretionInstructions_DiscretionLimitType : fix_discretionlimittype option; - (** If the calculated discretion price is not a valid tick price, specifies how to round the price (e.g. to be more or less aggressive)*) - f_DiscretionInstructions_DiscretionRoundDirection : fix_discretionrounddirection option; - (** The scope of "related to" price of the discretion (e.g. local, global etc)*) - f_DiscretionInstructions_DiscretionScope : fix_discretionscope option -} -;; - -type fix_rg_inner_positionamountdata = { - (** Number of Position Amount entries*) - f_PositionAmountData_NoPosAmt : int option; - f_PositionAmountData_PosAmtType : fix_posamttype option; - f_PositionAmountData_PosAmt : fix_float_6 option -} -;; - -type fix_rg_positionamountdata = fix_rg_inner_positionamountdata list -;; - -type fix_rg_inner_mdrjctgrp = { - f_MDRjctGrp_NoAltMDSource : int option; - f_MDRjctGrp_AltMDSourceID : string option -} -;; - -type fix_rg_mdrjctgrp = fix_rg_inner_mdrjctgrp list -;; - -type fix_rg_inner_attrbgrp = { - f_AttrbGrp_NoInstrAttrib : int option; - f_AttrbGrp_InstrAttribType : fix_instrattribtype option; - f_AttrbGrp_InstrAttribValue : string option -} -;; - -type fix_rg_attrbgrp = fix_rg_inner_attrbgrp list -;; - -type fix_rg_inner_trdregtimestamps = { - f_TrdRegTimestamps_NoTrdRegTimestamps : int option; - (** Required if NoTrdRegTimestamps > 1*) - f_TrdRegTimestamps_TrdRegTimestamp : fix_utctimestamp_milli option; - (** Required if NoTrdRegTimestamps > 1*) - f_TrdRegTimestamps_TrdRegTimestampType : fix_trdregtimestamptype option; - (** Optional*) - f_TrdRegTimestamps_TrdRegTimestampOrigin : string option -} -;; - -type fix_rg_trdregtimestamps = fix_rg_inner_trdregtimestamps list -;; - -type fix_rg_inner_routinggrp = { - f_RoutingGrp_NoRoutingIDs : int option; - f_RoutingGrp_RoutingType : fix_routingtype option; - f_RoutingGrp_RoutingID : string option -} -;; - -type fix_rg_routinggrp = fix_rg_inner_routinggrp list -;; - -type fix_rg_inner_cpctyconfgrp = { - f_CpctyConfGrp_NoCapacities : int option; - f_CpctyConfGrp_OrderCapacity : fix_ordercapacity option; - f_CpctyConfGrp_OrderRestrictions : fix_orderrestrictions list option; - f_CpctyConfGrp_OrderCapacityQty : fix_float_6 option -} -;; - -type fix_rg_cpctyconfgrp = fix_rg_inner_cpctyconfgrp list -;; - -type fix_yielddata = { - f_YieldData_YieldType : fix_yieldtype option; - f_YieldData_Yield : fix_float_6 option; - f_YieldData_YieldCalcDate : fix_localmktdate option; - f_YieldData_YieldRedemptionDate : fix_localmktdate option; - f_YieldData_YieldRedemptionPrice : fix_float_6 option; - f_YieldData_YieldRedemptionPriceType : int option -} -;; - -type fix_rg_inner_compidstatgrp = { - f_CompIDStatGrp_NoCompIDs : int option; - f_CompIDStatGrp_RefCompID : string option; - f_CompIDStatGrp_RefSubID : string option; - f_CompIDStatGrp_LocationID : string option; - f_CompIDStatGrp_DeskID : string option; - f_CompIDStatGrp_StatusValue : fix_statusvalue option; - f_CompIDStatGrp_StatusText : string option -} -;; - -type fix_rg_compidstatgrp = fix_rg_inner_compidstatgrp list -;; - -type fix_rg_inner_nstdptys3subgrp = { - f_NstdPtys3SubGrp_NoNested3PartySubIDs : int option; - f_NstdPtys3SubGrp_Nested3PartySubID : string option; - f_NstdPtys3SubGrp_Nested3PartySubIDType : int option -} -;; - -type fix_rg_nstdptys3subgrp = fix_rg_inner_nstdptys3subgrp list -;; - -type fix_rg_inner_clrinstgrp = { - f_ClrInstGrp_NoClearingInstructions : int option; - f_ClrInstGrp_ClearingInstruction : fix_clearinginstruction option -} -;; - -type fix_rg_clrinstgrp = fix_rg_inner_clrinstgrp list -;; - -type fix_rg_inner_nstdptys2subgrp = { - f_NstdPtys2SubGrp_NoNested2PartySubIDs : int option; - f_NstdPtys2SubGrp_Nested2PartySubID : string option; - f_NstdPtys2SubGrp_Nested2PartySubIDType : int option -} -;; - -type fix_rg_nstdptys2subgrp = fix_rg_inner_nstdptys2subgrp list -;; - -type fix_rg_inner_affectedordgrp = { - f_AffectedOrdGrp_NoAffectedOrders : int option; - f_AffectedOrdGrp_OrigClOrdID : string option; - f_AffectedOrdGrp_AffectedOrderID : string option; - f_AffectedOrdGrp_AffectedSecondaryOrderID : string option -} -;; - -type fix_rg_affectedordgrp = fix_rg_inner_affectedordgrp list -;; - -type fix_financingdetails = { - (** The full name of the base standard agreement, annexes and amendments in place between the principals and applicable to this deal*) - f_FinancingDetails_AgreementDesc : string option; - (** A common reference to the applicable standing agreement between the principals*) - f_FinancingDetails_AgreementID : string option; - (** A reference to the date the underlying agreement was executed.*) - f_FinancingDetails_AgreementDate : fix_localmktdate option; - (** Currency of the underlying agreement.*) - f_FinancingDetails_AgreementCurrency : fix_currency option; - (** For Repos the timing or method for terminating the agreement.*) - f_FinancingDetails_TerminationType : fix_terminationtype option; - (** Settlement date of the beginning of the deal*) - f_FinancingDetails_StartDate : fix_localmktdate option; - (** Repayment / repurchase date*) - f_FinancingDetails_EndDate : fix_localmktdate option; - (** Delivery or custody arrangement for the underlying securities*) - f_FinancingDetails_DeliveryType : fix_deliverytype option; - (** Percentage of cash value that underlying security collateral must meet.*) - f_FinancingDetails_MarginRatio : fix_float_6 option -} -;; - -type fix_rg_inner_trdcapdtgrp = { - f_TrdCapDtGrp_NoDates : int option; - f_TrdCapDtGrp_TradeDate : fix_localmktdate option; - f_TrdCapDtGrp_TransactTime : fix_utctimestamp_milli option -} -;; - -type fix_rg_trdcapdtgrp = fix_rg_inner_trdcapdtgrp list -;; type fix_orderqtydata = { - (** One of CashOrderQty, OrderQty, or (for CIV only) OrderPercent is required. Note that unless otherwise specified, only one of CashOrderQty, OrderQty, or OrderPercent should be specified.*) - f_OrderQtyData_OrderQty : fix_float_6 option; - (** One of CashOrderQty, OrderQty, or (for CIV only) OrderPercent is required. Note that unless otherwise specified, only one of CashOrderQty, OrderQty, or OrderPercent should be specified. Specifies the approximate "monetary quantity" for the order. Broker is responsible for converting and calculating OrderQty in tradeable units (e.g. shares) for subsequent messages.*) - f_OrderQtyData_CashOrderQty : fix_float_6 option; - (** For CIV - Optional. One of CashOrderQty, OrderQty or (for CIV only) OrderPercent is required. Note that unless otherwise specified, only one of CashOrderQty, OrderQty, or OrderPercent should be specified.*) - f_OrderQtyData_OrderPercent : fix_float_6 option; - (** For CIV - Optional*) - f_OrderQtyData_RoundingDirection : fix_roundingdirection option; - (** For CIV - Optional*) - f_OrderQtyData_RoundingModulus : fix_float option -} -;; - -type fix_rg_inner_trdcollgrp = { - f_TrdCollGrp_NoTrades : int option; - f_TrdCollGrp_TradeReportID : string option; - f_TrdCollGrp_SecondaryTradeReportID : string option -} -;; - -type fix_rg_trdcollgrp = fix_rg_inner_trdcollgrp list -;; - -type fix_peginstructions = { - (** Amount (signed) added to the peg for a pegged order in the context of the PegOffsetType*) - f_PegInstructions_PegOffsetValue : fix_float option; - (** Describes whether peg is static/fixed or floats*) - f_PegInstructions_PegMoveType : fix_pegmovetype option; - (** Type of Peg Offset (e.g. price offset, tick offset etc)*) - f_PegInstructions_PegOffsetType : fix_pegoffsettype option; - (** Specifies nature of resulting pegged price (e.g. or better limit, strict limit etc)*) - f_PegInstructions_PegLimitType : fix_peglimittype option; - (** If the calculated peg price is not a valid tick price, specifies how to round the price (e.g. be more or less aggressive)*) - f_PegInstructions_PegRoundDirection : fix_pegrounddirection option; - (** The scope of the "related to" price of the peg (e.g. local, global etc)*) - f_PegInstructions_PegScope : fix_pegscope option -} -;; - -type fix_interval = { - f_interval_start_time : fix_utctimestamp_milli option; - f_interval_duration : fix_duration option -} -;; - -type fix_rg_inner_rgstdistinstgrp = { - f_RgstDistInstGrp_NoDistribInsts : int option; - f_RgstDistInstGrp_DistribPaymentMethod : fix_distribpaymentmethod option; - f_RgstDistInstGrp_DistribPercentage : fix_float_6 option; - f_RgstDistInstGrp_CashDistribCurr : fix_currency option; - f_RgstDistInstGrp_CashDistribAgentName : string option; - f_RgstDistInstGrp_CashDistribAgentCode : string option; - f_RgstDistInstGrp_CashDistribAgentAcctNumber : string option; - f_RgstDistInstGrp_CashDistribPayRef : string option; - f_RgstDistInstGrp_CashDistribAgentAcctName : string option -} -;; - -type fix_rg_rgstdistinstgrp = fix_rg_inner_rgstdistinstgrp list -;; - -type fix_rg_inner_execcollgrp = { - f_ExecCollGrp_NoExecs : int option; - f_ExecCollGrp_ExecID : string option -} -;; - -type fix_rg_execcollgrp = fix_rg_inner_execcollgrp list -;; - -type fix_rg_inner_compidreqgrp = { - f_CompIDReqGrp_NoCompIDs : int option; - f_CompIDReqGrp_RefCompID : string option; - f_CompIDReqGrp_RefSubID : string option; - f_CompIDReqGrp_LocationID : string option; - f_CompIDReqGrp_DeskID : string option -} -;; - -type fix_rg_compidreqgrp = fix_rg_inner_compidreqgrp list -;; - -type fix_rg_inner_nstdptyssubgrp = { - f_NstdPtysSubGrp_NoNestedPartySubIDs : int option; - f_NstdPtysSubGrp_NestedPartySubID : string option; - f_NstdPtysSubGrp_NestedPartySubIDType : int option -} -;; - -type fix_rg_nstdptyssubgrp = fix_rg_inner_nstdptyssubgrp list -;; - -type fix_rg_inner_stipulations = { - f_Stipulations_NoStipulations : int option; - (** Required if NoStipulations >0*) - f_Stipulations_StipulationType : fix_stipulationtype option; - f_Stipulations_StipulationValue : string option -} -;; - -type fix_rg_stipulations = fix_rg_inner_stipulations list -;; - -type fix_rg_inner_ioiqualgrp = { - f_IOIQualGrp_NoIOIQualifiers : int option; - f_IOIQualGrp_IOIQualifier : fix_ioiqualifier option -} -;; - -type fix_rg_ioiqualgrp = fix_rg_inner_ioiqualgrp list -;; - -type fix_legbenchmarkcurvedata = { - f_LegBenchmarkCurveData_LegBenchmarkCurveCurrency : fix_currency option; - f_LegBenchmarkCurveData_LegBenchmarkCurveName : string option; - f_LegBenchmarkCurveData_LegBenchmarkCurvePoint : string option; - f_LegBenchmarkCurveData_LegBenchmarkPrice : fix_float_6 option; - f_LegBenchmarkCurveData_LegBenchmarkPriceType : int option -} -;; - -type fix_rg_inner_execallocgrp = { - f_ExecAllocGrp_NoExecs : int option; - f_ExecAllocGrp_LastQty : fix_float_6 option; - f_ExecAllocGrp_ExecID : string option; - f_ExecAllocGrp_SecondaryExecID : string option; - f_ExecAllocGrp_LastPx : fix_float_6 option; - f_ExecAllocGrp_LastParPx : fix_float_6 option; - f_ExecAllocGrp_LastCapacity : fix_lastcapacity option -} -;; - -type fix_rg_execallocgrp = fix_rg_inner_execallocgrp list -;; - -type fix_commissiondata = { - f_CommissionData_Commission : fix_float_6 option; - f_CommissionData_CommType : fix_commtype option; - (** For CIV - Optional*) - f_CommissionData_CommCurrency : fix_currency option; - (** For CIV - Optional*) - f_CommissionData_FundRenewWaiv : fix_fundrenewwaiv option +(** One of CashOrderQty, OrderQty, or (for CIV only) OrderPercent is required. Note that unless otherwise specified, only one of CashOrderQty, OrderQty, or OrderPercent should be specified.*) + f_OrderQtyData_OrderQty : fix_float_6 option } ;; type fix_rg_inner_ptyssubgrp = { f_PtysSubGrp_NoPartySubIDs : int option; - f_PtysSubGrp_PartySubID : string option; - f_PtysSubGrp_PartySubIDType : fix_partysubidtype option + f_PtysSubGrp_PartySubID : string option } ;; type fix_rg_ptyssubgrp = fix_rg_inner_ptyssubgrp list ;; -type fix_rg_inner_settlptyssubgrp = { - f_SettlPtysSubGrp_NoSettlPartySubIDs : int option; - f_SettlPtysSubGrp_SettlPartySubID : string option; - f_SettlPtysSubGrp_SettlPartySubIDType : int option -} -;; - -type fix_rg_settlptyssubgrp = fix_rg_inner_settlptyssubgrp list -;; - -type fix_rg_inner_sectypesgrp = { - f_SecTypesGrp_NoSecurityTypes : int option; - f_SecTypesGrp_SecurityType : fix_securitytype option; - f_SecTypesGrp_SecuritySubType : string option; - f_SecTypesGrp_Product : fix_product option; - f_SecTypesGrp_CFICode : string option -} -;; - -type fix_rg_sectypesgrp = fix_rg_inner_sectypesgrp list -;; - -type fix_rg_inner_quotqualgrp = { - f_QuotQualGrp_NoQuoteQualifiers : int option; - f_QuotQualGrp_QuoteQualifier : string option -} -;; - -type fix_rg_quotqualgrp = fix_rg_inner_quotqualgrp list -;; - -type fix_rg_inner_biddescreqgrp = { - f_BidDescReqGrp_NoBidDescriptors : int option; - f_BidDescReqGrp_BidDescriptorType : fix_biddescriptortype option; - f_BidDescReqGrp_BidDescriptor : string option; - f_BidDescReqGrp_SideValueInd : fix_sidevalueind option; - f_BidDescReqGrp_LiquidityValue : fix_float_6 option; - f_BidDescReqGrp_LiquidityNumSecurities : int option; - f_BidDescReqGrp_LiquidityPctLow : fix_float_6 option; - f_BidDescReqGrp_LiquidityPctHigh : fix_float_6 option; - f_BidDescReqGrp_EFPTrackingError : fix_float_6 option; - f_BidDescReqGrp_FairValue : fix_float_6 option; - f_BidDescReqGrp_OutsideIndexPct : fix_float_6 option; - f_BidDescReqGrp_ValueOfFutures : fix_float_6 option -} -;; - -type fix_rg_biddescreqgrp = fix_rg_inner_biddescreqgrp list -;; - -type fix_rg_inner_secaltidgrp = { - f_SecAltIDGrp_NoSecurityAltID : int option; - f_SecAltIDGrp_SecurityAltID : string option; - f_SecAltIDGrp_SecurityAltIDSource : string option -} -;; - -type fix_rg_secaltidgrp = fix_rg_inner_secaltidgrp list -;; - -type fix_rg_inner_ordliststatgrp = { - f_OrdListStatGrp_NoOrders : int option; - f_OrdListStatGrp_ClOrdID : string option; - f_OrdListStatGrp_SecondaryClOrdID : string option; - f_OrdListStatGrp_CumQty : fix_float_6 option; - f_OrdListStatGrp_OrdStatus : fix_ordstatus option; - f_OrdListStatGrp_WorkingIndicator : fix_workingindicator option; - f_OrdListStatGrp_LeavesQty : fix_float_6 option; - f_OrdListStatGrp_CxlQty : fix_float_6 option; - f_OrdListStatGrp_AvgPx : fix_float_6 option; - f_OrdListStatGrp_OrdRejReason : fix_ordrejreason option; - f_OrdListStatGrp_Text : string option; - f_OrdListStatGrp_EncodedTextLen : int option; - f_OrdListStatGrp_EncodedText : string option -} -;; - -type fix_rg_ordliststatgrp = fix_rg_inner_ordliststatgrp list -;; - -type fix_rg_inner_legstipulations = { - f_LegStipulations_NoLegStipulations : int option; - (** Required if NoLegStipulations >0*) - f_LegStipulations_LegStipulationType : string option; - f_LegStipulations_LegStipulationValue : string option -} -;; - -type fix_rg_legstipulations = fix_rg_inner_legstipulations list -;; - -type fix_rg_inner_settlparties = { - (** Repeating group below should contain unique combinations of SettlPartyID, SettlPartyIDSource, and SettlPartyRole*) - f_SettlParties_NoSettlPartyIDs : int option; - (** Used to identify source of SettlPartyID. Required if SettlPartyIDSource is specified. Required if NoSettlPartyIDs > 0.*) - f_SettlParties_SettlPartyID : string option; - (** Used to identify class source of SettlPartyID value (e.g. BIC). Required if SettlPartyID is specified. Required if NoSettlPartyIDs > 0.*) - f_SettlParties_SettlPartyIDSource : string option; - (** Identifies the type of SettlPartyID (e.g. Executing Broker). Required if NoSettlPartyIDs > 0.*) - f_SettlParties_SettlPartyRole : int option; - (** Repeating group of SettlParty sub-identifiers.*) - f_SettlParties_SettlPtysSubGrp : fix_rg_settlptyssubgrp -} -;; - -type fix_rg_settlparties = fix_rg_inner_settlparties list -;; - type fix_rg_inner_parties = { - (** Repeating group below should contain unique combinations of PartyID, PartyIDSource, and PartyRole*) +(** Repeating group below should contain unique combinations of PartyID, PartyIDSource, and PartyRole*) f_Parties_NoPartyIDs : int option; - (** Used to identify source of PartyID. Required if PartyIDSource is specified. Required if NoPartyIDs > 0.*) +(** Used to identify source of PartyID. Required if PartyIDSource is specified. Required if NoPartyIDs > 0.*) f_Parties_PartyID : string option; - (** Used to identify class source of PartyID value (e.g. BIC). Required if PartyID is specified. Required if NoPartyIDs > 0.*) - f_Parties_PartyIDSource : fix_partyidsource option; - (** Identifies the type of PartyID (e.g. Executing Broker). Required if NoPartyIDs > 0.*) - f_Parties_PartyRole : fix_partyrole option; - (** Repeating group of Party sub-identifiers.*) - f_Parties_PtysSubGrp : fix_rg_ptyssubgrp +(** Repeating group of Party sub-identifiers.*) + f_Parties_PtysSubGrp : fix_rg_ptyssubgrp; + f_Parties_PartyIndex : int option } ;; type fix_rg_parties = fix_rg_inner_parties list ;; -type fix_rg_inner_bidcomprspgrp = { - f_BidCompRspGrp_NoBidComponents : int option; - f_BidCompRspGrp_CommissionData : fix_commissiondata; - f_BidCompRspGrp_ListID : string option; - f_BidCompRspGrp_Country : fix_country option; - f_BidCompRspGrp_Side : fix_side option; - f_BidCompRspGrp_Price : fix_float_6 option; - f_BidCompRspGrp_PriceType : fix_pricetype option; - f_BidCompRspGrp_FairValue : fix_float_6 option; - f_BidCompRspGrp_NetGrossInd : fix_netgrossind option; - f_BidCompRspGrp_SettlType : fix_settltype option; - f_BidCompRspGrp_SettlDate : fix_localmktdate option; - f_BidCompRspGrp_TradingSessionID : string option; - f_BidCompRspGrp_TradingSessionSubID : string option; - f_BidCompRspGrp_Text : string option; - f_BidCompRspGrp_EncodedTextLen : int option; - f_BidCompRspGrp_EncodedText : string option -} -;; - -type fix_rg_bidcomprspgrp = fix_rg_inner_bidcomprspgrp list -;; - -type fix_rg_inner_nestedparties = { - (** Repeating group below should contain unique combinations of NestedPartyID, NestedPartyIDSource, and NestedPartyRole*) - f_NestedParties_NoNestedPartyIDs : int option; - (** Used to identify source of NestedPartyID. Required if NestedPartyIDSource is specified. Required if NoNestedPartyIDs > 0.*) - f_NestedParties_NestedPartyID : string option; - (** Used to identify class source of NestedPartyID value (e.g. BIC). Required if NestedPartyID is specified. Required if NoNestedPartyIDs > 0.*) - f_NestedParties_NestedPartyIDSource : string option; - (** Identifies the type of NestedPartyID (e.g. Executing Broker). Required if NoNestedPartyIDs > 0.*) - f_NestedParties_NestedPartyRole : int option; - (** Repeating group of NestedParty sub-identifiers.*) - f_NestedParties_NstdPtysSubGrp : fix_rg_nstdptyssubgrp -} -;; - -type fix_rg_nestedparties = fix_rg_inner_nestedparties list -;; - -type fix_rg_inner_nestedparties2 = { - (** Repeating group below should contain unique combinations of Nested2PartyID, Nested2PartyIDSource, and Nested2PartyRole*) - f_NestedParties2_NoNested2PartyIDs : int option; - (** Used to identify source of Nested2PartyID. Required if Nested2PartyIDSource is specified. Required if NoNested2PartyIDs > 0.*) - f_NestedParties2_Nested2PartyID : string option; - (** Used to identify class source of Nested2PartyID value (e.g. BIC). Required if Nested2PartyID is specified. Required if NoNested2PartyIDs > 0.*) - f_NestedParties2_Nested2PartyIDSource : string option; - (** Identifies the type of Nested2PartyID (e.g. Executing Broker). Required if NoNested2PartyIDs > 0.*) - f_NestedParties2_Nested2PartyRole : int option; - (** Repeating group of Nested2Party sub-identifiers.*) - f_NestedParties2_NstdPtys2SubGrp : fix_rg_nstdptys2subgrp -} -;; - -type fix_rg_nestedparties2 = fix_rg_inner_nestedparties2 list -;; - -type fix_rg_inner_nestedparties3 = { - (** Repeating group below should contain unique combinations of Nested3PartyID, Nested3PartyIDSource, and Nested3PartyRole*) - f_NestedParties3_NoNested3PartyIDs : int option; - (** Used to identify source of Nested3PartyID. Required if Nested3PartyIDSource is specified. Required if NoNested3PartyIDs > 0.*) - f_NestedParties3_Nested3PartyID : string option; - (** Used to identify class source of Nested3PartyID value (e.g. BIC). Required if Nested3PartyID is specified. Required if NoNested3PartyIDs > 0.*) - f_NestedParties3_Nested3PartyIDSource : string option; - (** Identifies the type of Nested3PartyID (e.g. Executing Broker). Required if NoNested3PartyIDs > 0.*) - f_NestedParties3_Nested3PartyRole : int option; - (** Repeating group of Nested3Party sub-identifiers.*) - f_NestedParties3_NstdPtys3SubGrp : fix_rg_nstdptys3subgrp -} -;; - -type fix_rg_nestedparties3 = fix_rg_inner_nestedparties3 list -;; - -type fix_instrumentextension = { - (** Identifies the form of delivery.*) - f_InstrumentExtension_DeliveryForm : fix_deliveryform option; - (** Percent at risk due to lowest possible call.*) - f_InstrumentExtension_PctAtRisk : fix_float_6 option; - (** Number of repeating InstrAttrib group entries.*) - f_InstrumentExtension_AttrbGrp : fix_rg_attrbgrp -} -;; - -type fix_instrumentleg = { - f_InstrumentLeg_LegSymbol : string option; - f_InstrumentLeg_LegSymbolSfx : string option; - f_InstrumentLeg_LegSecurityID : string option; - f_InstrumentLeg_LegSecurityIDSource : string option; - f_InstrumentLeg_LegSecAltIDGrp : fix_rg_legsecaltidgrp; - f_InstrumentLeg_LegProduct : int option; - f_InstrumentLeg_LegCFICode : string option; - f_InstrumentLeg_LegSecurityType : string option; - f_InstrumentLeg_LegSecuritySubType : string option; - f_InstrumentLeg_LegMaturityMonthYear : fix_monthyear option; - f_InstrumentLeg_LegMaturityDate : fix_localmktdate option; - f_InstrumentLeg_LegCouponPaymentDate : fix_localmktdate option; - f_InstrumentLeg_LegIssueDate : fix_localmktdate option; - (** (Deprecated, not applicable/used for Repos)*) - f_InstrumentLeg_LegRepoCollateralSecurityType : string option; - (** (Deprecated, not applicable/used for Repos)*) - f_InstrumentLeg_LegRepurchaseTerm : int option; - (** (Deprecated, not applicable/used for Repos)*) - f_InstrumentLeg_LegRepurchaseRate : fix_float_6 option; - f_InstrumentLeg_LegFactor : fix_float option; - f_InstrumentLeg_LegCreditRating : string option; - f_InstrumentLeg_LegInstrRegistry : string option; - f_InstrumentLeg_LegCountryOfIssue : fix_country option; - f_InstrumentLeg_LegStateOrProvinceOfIssue : string option; - f_InstrumentLeg_LegLocaleOfIssue : string option; - (** (Deprecated, use YieldRedemptionDate (696) in component block)*) - f_InstrumentLeg_LegRedemptionDate : fix_localmktdate option; - f_InstrumentLeg_LegStrikePrice : fix_float_6 option; - f_InstrumentLeg_LegStrikeCurrency : fix_currency option; - f_InstrumentLeg_LegOptAttribute : string option; - f_InstrumentLeg_LegContractMultiplier : fix_float option; - f_InstrumentLeg_LegCouponRate : fix_float_6 option; - f_InstrumentLeg_LegSecurityExchange : fix_exchange option; - f_InstrumentLeg_LegIssuer : string option; - f_InstrumentLeg_EncodedLegIssuerLen : int option; - f_InstrumentLeg_EncodedLegIssuer : string option; - f_InstrumentLeg_LegSecurityDesc : string option; - f_InstrumentLeg_EncodedLegSecurityDescLen : int option; - f_InstrumentLeg_EncodedLegSecurityDesc : string option; - (** Specific to the (not in )*) - f_InstrumentLeg_LegRatioQty : fix_float option; - (** Specific to the (not in )*) - f_InstrumentLeg_LegSide : string option; - (** Specific to the (not in )*) - f_InstrumentLeg_LegCurrency : fix_currency option; - (** Identifies MBS / ABS pool*) - f_InstrumentLeg_LegPool : string option; - f_InstrumentLeg_LegDatedDate : fix_localmktdate option; - f_InstrumentLeg_LegContractSettlMonth : fix_monthyear option; - f_InstrumentLeg_LegInterestAccrualDate : fix_localmktdate option -} -;; - -type fix_instrument = { - (** Common, "human understood" representation of the security. SecurityID value can be specified if no symbol exists (e.g. non-exchange traded Collective Investment Vehicles) - Use "[N/A]" for products which do not have a symbol.*) - f_Instrument_Symbol : string option; - (** Used in Fixed Income with a value of "WI" to indicate "When Issued" for a security to be reissued under an old CUSIP or ISIN or with a value of "CD" to indicate a EUCP with lump-sum interest rather than discount price.*) - f_Instrument_SymbolSfx : string option; - (** Takes precedence in identifying security to counterparty over SecurityAltID block. Requires SecurityIDSource if specified.*) - f_Instrument_SecurityID : string option; - (** Required if SecurityID is specified.*) - f_Instrument_SecurityIDSource : fix_securityidsource option; - (** Number of alternate Security Identifiers*) - f_Instrument_SecAltIDGrp : fix_rg_secaltidgrp; - (** Indicates the type of product the security is associated with (high-level category)*) - f_Instrument_Product : fix_product option; - (** Indicates the type of security using ISO 10962 standard, Classification of Financial Instruments (CFI code) values. It is recommended that CFICode be used instead of SecurityType for non-Fixed Income instruments.*) - f_Instrument_CFICode : string option; - (** It is recommended that CFICode be used instead of SecurityType for non-Fixed Income instruments. - Required for Fixed Income. Refer to Volume 7 - Fixed Income - Futures and Options should be specified using the CFICode[461] field instead of SecurityType[167] (Refer to Volume 7 - Recommendations and Guidelines for Futures and Options Markets.)*) - f_Instrument_SecurityType : fix_securitytype option; - (** Sub-type qualification/identification of the SecurityType (e.g. for SecurityType="MLEG"). If specified, SecurityType is required.*) - f_Instrument_SecuritySubType : string option; - (** Specifies the month and year of maturity. Applicable for standardized derivatives which are typically only referenced by month and year (e.g. S&P futures). Note MaturityDate (a full date) can also be specified.*) - f_Instrument_MaturityMonthYear : fix_monthyear option; - (** Specifies date of maturity (a full date). Note that standardized derivatives which are typically only referenced by month and year (e.g. S&P futures).may use MaturityMonthYear and/or this field. - When using MaturityMonthYear, it is recommended that markets and sell sides report the MaturityDate on all outbound messages as a means of data enrichment.*) - f_Instrument_MaturityDate : fix_localmktdate option; - (** Date interest is to be paid. Used in identifying Corporate Bond issues.*) - f_Instrument_CouponPaymentDate : fix_localmktdate option; - (** Date instrument was issued. For Fixed Income IOIs for new issues, specifies the issue date.*) - f_Instrument_IssueDate : fix_localmktdate option; - (** (Deprecated, use UnderlyingSecurityType (310) )*) - f_Instrument_RepoCollateralSecurityType : string option; - (** (Deprecated, use TerminationType (788) )*) - f_Instrument_RepurchaseTerm : int option; - (** (Deprecated, use Price (44) )*) - f_Instrument_RepurchaseRate : fix_float_6 option; - (** For Fixed Income: Amortization Factor for deriving Current face from Original face for ABS or MBS securities, note the fraction may be greater than, equal to or less than 1. In TIPS securities this is the Inflation index. - Qty * Factor * Price = Gross Trade Amount - For Derivatives: Contract Value Factor by which price must be adjusted to determine the true nominal value of one futures/options contract. - (Qty * Price) * Factor = Nominal Value*) - f_Instrument_Factor : fix_float option; - f_Instrument_CreditRating : string option; - (** The location at which records of ownership are maintained for this instrument, and at which ownership changes must be recorded. Can be used in conjunction with ISIN to address ISIN uniqueness issues.*) - f_Instrument_InstrRegistry : string option; - (** ISO Country code of instrument issue (e.g. the country portion typically used in ISIN). Can be used in conjunction with non-ISIN SecurityID (e.g. CUSIP for Municipal Bonds without ISIN) to provide uniqueness.*) - f_Instrument_CountryOfIssue : fix_country option; - (** A two-character state or province abbreviation.*) - f_Instrument_StateOrProvinceOfIssue : string option; - (** The three-character IATA code for a locale (e.g. airport code for Municipal Bonds).*) - f_Instrument_LocaleOfIssue : string option; - (** (Deprecated, use YieldRedemptionDate (696) in component block)*) - f_Instrument_RedemptionDate : fix_localmktdate option; - (** Used for derivatives, such as options and covered warrants*) - f_Instrument_StrikePrice : fix_float_6 option; - (** Used for derivatives*) - f_Instrument_StrikeCurrency : fix_currency option; - (** Used for derivatives, such as options and covered warrants to indicate a versioning of the contract when required due to corporate actions to the underlying. Should not be used to indicate type of option - use the CFICode[461] for this purpose.*) - f_Instrument_OptAttribute : string option; - (** For Fixed Income, Convertible Bonds, Derivatives, etc. Note: If used, quantities should be expressed in the "nominal" (e.g. contracts vs. shares) amount.*) - f_Instrument_ContractMultiplier : fix_float option; - (** For Fixed Income.*) - f_Instrument_CouponRate : fix_float_6 option; - (** Can be used to identify the security.*) - f_Instrument_SecurityExchange : fix_exchange option; - f_Instrument_Issuer : string option; - (** Must be set if EncodedIssuer field is specified and must immediately precede it.*) - f_Instrument_EncodedIssuerLen : int option; - (** Encoded (non-ASCII characters) representation of the Issuer field in the encoded format specified via the MessageEncoding field.*) - f_Instrument_EncodedIssuer : string option; - f_Instrument_SecurityDesc : string option; - (** Must be set if EncodedSecurityDesc field is specified and must immediately precede it.*) - f_Instrument_EncodedSecurityDescLen : int option; - (** Encoded (non-ASCII characters) representation of the SecurityDesc field in the encoded format specified via the MessageEncoding field.*) - f_Instrument_EncodedSecurityDesc : string option; - (** Identifies MBS / ABS pool*) - f_Instrument_Pool : string option; - (** Must be present for MBS/TBA*) - f_Instrument_ContractSettlMonth : fix_monthyear option; - (** The program under which a commercial paper is issued*) - f_Instrument_CPProgram : fix_cpprogram option; - (** The registration type of a commercial paper issuance*) - f_Instrument_CPRegType : string option; - (** Number of repeating EventType group entries.*) - f_Instrument_EvntGrp : fix_rg_evntgrp; - (** If different from IssueDate*) - f_Instrument_DatedDate : fix_localmktdate option; - (** If different from IssueDate and DatedDate*) - f_Instrument_InterestAccrualDate : fix_localmktdate option -} -;; - -type fix_underlyinginstrument = { - f_UnderlyingInstrument_UnderlyingSymbol : string option; - f_UnderlyingInstrument_UnderlyingSymbolSfx : string option; - f_UnderlyingInstrument_UnderlyingSecurityID : string option; - f_UnderlyingInstrument_UnderlyingSecurityIDSource : string option; - f_UnderlyingInstrument_UndSecAltIDGrp : fix_rg_undsecaltidgrp; - f_UnderlyingInstrument_UnderlyingProduct : int option; - f_UnderlyingInstrument_UnderlyingCFICode : string option; - f_UnderlyingInstrument_UnderlyingSecurityType : string option; - f_UnderlyingInstrument_UnderlyingSecuritySubType : string option; - f_UnderlyingInstrument_UnderlyingMaturityMonthYear : fix_monthyear option; - f_UnderlyingInstrument_UnderlyingMaturityDate : fix_localmktdate option; - f_UnderlyingInstrument_UnderlyingCouponPaymentDate : fix_localmktdate option; - f_UnderlyingInstrument_UnderlyingIssueDate : fix_localmktdate option; - (** (Deprecated, not applicable/used for Repos)*) - f_UnderlyingInstrument_UnderlyingRepoCollateralSecurityType : string option; - (** (Deprecated, not applicable/used for Repos)*) - f_UnderlyingInstrument_UnderlyingRepurchaseTerm : int option; - (** (Deprecated, not applicable/used for Repos)*) - f_UnderlyingInstrument_UnderlyingRepurchaseRate : fix_float_6 option; - f_UnderlyingInstrument_UnderlyingFactor : fix_float option; - f_UnderlyingInstrument_UnderlyingCreditRating : string option; - f_UnderlyingInstrument_UnderlyingInstrRegistry : string option; - f_UnderlyingInstrument_UnderlyingCountryOfIssue : fix_country option; - f_UnderlyingInstrument_UnderlyingStateOrProvinceOfIssue : string option; - f_UnderlyingInstrument_UnderlyingLocaleOfIssue : string option; - (** (Deprecated, use YieldRedemptionDate (696) in component block)*) - f_UnderlyingInstrument_UnderlyingRedemptionDate : fix_localmktdate option; - f_UnderlyingInstrument_UnderlyingStrikePrice : fix_float_6 option; - f_UnderlyingInstrument_UnderlyingStrikeCurrency : fix_currency option; - f_UnderlyingInstrument_UnderlyingOptAttribute : string option; - f_UnderlyingInstrument_UnderlyingContractMultiplier : fix_float option; - f_UnderlyingInstrument_UnderlyingCouponRate : fix_float_6 option; - f_UnderlyingInstrument_UnderlyingSecurityExchange : fix_exchange option; - f_UnderlyingInstrument_UnderlyingIssuer : string option; - f_UnderlyingInstrument_EncodedUnderlyingIssuerLen : int option; - f_UnderlyingInstrument_EncodedUnderlyingIssuer : string option; - f_UnderlyingInstrument_UnderlyingSecurityDesc : string option; - f_UnderlyingInstrument_EncodedUnderlyingSecurityDescLen : int option; - f_UnderlyingInstrument_EncodedUnderlyingSecurityDesc : string option; - f_UnderlyingInstrument_UnderlyingCPProgram : string option; - f_UnderlyingInstrument_UnderlyingCPRegType : string option; - (** Specific to the (not in )*) - f_UnderlyingInstrument_UnderlyingCurrency : fix_currency option; - (** Specific to the (not in ) - Unit amount of the underlying security (par, shares, currency, etc.)*) - f_UnderlyingInstrument_UnderlyingQty : fix_float_6 option; - (** Specific to the (not in ) - In a financing deal clean price (percent-of-par or per unit) of the underlying security or basket.*) - f_UnderlyingInstrument_UnderlyingPx : fix_float_6 option; - (** Specific to the (not in ) - In a financing deal price (percent-of-par or per unit) of the underlying security or basket. "Dirty" means it includes accrued interest*) - f_UnderlyingInstrument_UnderlyingDirtyPrice : fix_float_6 option; - (** Specific to the (not in ) - In a financing deal price (percent-of-par or per unit) of the underlying security or basket at the end of the agreement.*) - f_UnderlyingInstrument_UnderlyingEndPrice : fix_float_6 option; - (** Specific to the (not in ) - Currency value attributed to this collateral at the start of the agreement*) - f_UnderlyingInstrument_UnderlyingStartValue : fix_float_6 option; - (** Specific to the (not in ) - Currency value currently attributed to this collateral*) - f_UnderlyingInstrument_UnderlyingCurrentValue : fix_float_6 option; - (** Specific to the (not in ) - Currency value attributed to this collateral at the end of the agreement*) - f_UnderlyingInstrument_UnderlyingEndValue : fix_float_6 option; - (** Specific to the (not in ) - Insert here the contents of the Component Block*) - f_UnderlyingInstrument_UnderlyingStipulations : fix_rg_underlyingstipulations -} -;; - -type fix_rg_inner_undinstrmtcollgrp = { - f_UndInstrmtCollGrp_NoUnderlyings : int option; - f_UndInstrmtCollGrp_UnderlyingInstrument : fix_underlyinginstrument; - f_UndInstrmtCollGrp_CollAction : fix_collaction option -} -;; - -type fix_rg_undinstrmtcollgrp = fix_rg_inner_undinstrmtcollgrp list -;; - -type fix_rg_inner_posundinstrmtgrp = { - f_PosUndInstrmtGrp_NoUnderlyings : int option; - f_PosUndInstrmtGrp_UnderlyingInstrument : fix_underlyinginstrument; - f_PosUndInstrmtGrp_UnderlyingSettlPrice : fix_float_6 option; - f_PosUndInstrmtGrp_UnderlyingSettlPriceType : int option -} -;; - -type fix_rg_posundinstrmtgrp = fix_rg_inner_posundinstrmtgrp list -;; - -type fix_rg_inner_undinstrmtgrp = { - f_UndInstrmtGrp_NoUnderlyings : int option; - f_UndInstrmtGrp_UnderlyingInstrument : fix_underlyinginstrument -} -;; - -type fix_rg_undinstrmtgrp = fix_rg_inner_undinstrmtgrp list -;; - -type fix_rg_inner_undinstrmtstrkpxgrp = { - f_UndInstrmtStrkPxGrp_NoUnderlyings : int option; - f_UndInstrmtStrkPxGrp_UnderlyingInstrument : fix_underlyinginstrument; - f_UndInstrmtStrkPxGrp_PrevClosePx : fix_float_6 option; - f_UndInstrmtStrkPxGrp_ClOrdID : string option; - f_UndInstrmtStrkPxGrp_SecondaryClOrdID : string option; - f_UndInstrmtStrkPxGrp_Side : fix_side option; - f_UndInstrmtStrkPxGrp_Price : fix_float_6 option; - f_UndInstrmtStrkPxGrp_Currency : fix_currency option; - f_UndInstrmtStrkPxGrp_Text : string option; - f_UndInstrmtStrkPxGrp_EncodedTextLen : int option; - f_UndInstrmtStrkPxGrp_EncodedText : string option -} -;; - -type fix_rg_undinstrmtstrkpxgrp = fix_rg_inner_undinstrmtstrkpxgrp list -;; - -type fix_rg_inner_instrmtgrp = { - f_InstrmtGrp_NoRelatedSym : int option; - f_InstrmtGrp_Instrument : fix_instrument -} -;; - -type fix_rg_instrmtgrp = fix_rg_inner_instrmtgrp list -;; - -type fix_rg_inner_instrmtstrkpxgrp = { - f_InstrmtStrkPxGrp_NoStrikes : int option; - f_InstrmtStrkPxGrp_Instrument : fix_instrument -} -;; - -type fix_rg_instrmtstrkpxgrp = fix_rg_inner_instrmtstrkpxgrp list -;; - -type fix_rg_inner_instrmtlegseclistgrp = { - f_InstrmtLegSecListGrp_NoLegs : int option; - f_InstrmtLegSecListGrp_InstrumentLeg : fix_instrumentleg; - f_InstrmtLegSecListGrp_LegSwapType : fix_legswaptype option; - f_InstrmtLegSecListGrp_LegSettlType : string option; - f_InstrmtLegSecListGrp_LegStipulations : fix_rg_legstipulations; - f_InstrmtLegSecListGrp_LegBenchmarkCurveData : fix_legbenchmarkcurvedata -} -;; - -type fix_rg_instrmtlegseclistgrp = fix_rg_inner_instrmtlegseclistgrp list -;; - -type fix_rg_inner_instrmtleggrp = { - f_InstrmtLegGrp_NoLegs : int option; - f_InstrmtLegGrp_InstrumentLeg : fix_instrumentleg -} -;; - -type fix_rg_instrmtleggrp = fix_rg_inner_instrmtleggrp list -;; - -type fix_rg_inner_instrmtlegioigrp = { - f_InstrmtLegIOIGrp_NoLegs : int option; - f_InstrmtLegIOIGrp_InstrumentLeg : fix_instrumentleg; - f_InstrmtLegIOIGrp_LegIOIQty : string option; - f_InstrmtLegIOIGrp_LegStipulations : fix_rg_legstipulations -} -;; - -type fix_rg_instrmtlegioigrp = fix_rg_inner_instrmtlegioigrp list -;; - -type fix_rg_inner_preallocmleggrp = { - f_PreAllocMlegGrp_NoAllocs : int option; - f_PreAllocMlegGrp_AllocAccount : string option; - f_PreAllocMlegGrp_AllocAcctIDSource : int option; - f_PreAllocMlegGrp_AllocSettlCurrency : fix_currency option; - f_PreAllocMlegGrp_IndividualAllocID : string option; - f_PreAllocMlegGrp_NestedParties3 : fix_rg_nestedparties3; - f_PreAllocMlegGrp_AllocQty : fix_float_6 option -} -;; - -type fix_rg_preallocmleggrp = fix_rg_inner_preallocmleggrp list -;; - -type fix_rg_inner_trdallocgrp = { - f_TrdAllocGrp_NoAllocs : int option; - f_TrdAllocGrp_AllocAccount : string option; - f_TrdAllocGrp_AllocAcctIDSource : int option; - f_TrdAllocGrp_AllocSettlCurrency : fix_currency option; - f_TrdAllocGrp_IndividualAllocID : string option; - f_TrdAllocGrp_NestedParties2 : fix_rg_nestedparties2; - f_TrdAllocGrp_AllocQty : fix_float_6 option -} -;; - -type fix_rg_trdallocgrp = fix_rg_inner_trdallocgrp list -;; - -type fix_rg_inner_legpreallocgrp = { - f_LegPreAllocGrp_NoLegAllocs : int option; - f_LegPreAllocGrp_LegAllocAccount : string option; - f_LegPreAllocGrp_LegIndividualAllocID : string option; - f_LegPreAllocGrp_NestedParties2 : fix_rg_nestedparties2; - f_LegPreAllocGrp_LegAllocQty : fix_float_6 option; - f_LegPreAllocGrp_LegAllocAcctIDSource : string option; - f_LegPreAllocGrp_LegSettlCurrency : fix_currency option -} -;; - -type fix_rg_legpreallocgrp = fix_rg_inner_legpreallocgrp list -;; - -type fix_rg_inner_ordallocgrp = { - f_OrdAllocGrp_NoOrders : int option; - f_OrdAllocGrp_ClOrdID : string option; - f_OrdAllocGrp_OrderID : string option; - f_OrdAllocGrp_SecondaryOrderID : string option; - f_OrdAllocGrp_SecondaryClOrdID : string option; - f_OrdAllocGrp_ListID : string option; - f_OrdAllocGrp_NestedParties2 : fix_rg_nestedparties2; - f_OrdAllocGrp_OrderQty : fix_float_6 option; - f_OrdAllocGrp_OrderAvgPx : fix_float_6 option; - f_OrdAllocGrp_OrderBookingQty : fix_float_6 option -} -;; - -type fix_rg_ordallocgrp = fix_rg_inner_ordallocgrp list -;; - -type fix_rg_inner_legquotstatgrp = { - f_LegQuotStatGrp_NoLegs : int option; - f_LegQuotStatGrp_InstrumentLeg : fix_instrumentleg; - f_LegQuotStatGrp_LegQty : fix_float_6 option; - f_LegQuotStatGrp_LegSwapType : fix_legswaptype option; - f_LegQuotStatGrp_LegSettlType : string option; - f_LegQuotStatGrp_LegSettlDate : fix_localmktdate option; - f_LegQuotStatGrp_LegStipulations : fix_rg_legstipulations; - f_LegQuotStatGrp_NestedParties : fix_rg_nestedparties -} -;; - -type fix_rg_legquotstatgrp = fix_rg_inner_legquotstatgrp list -;; - -type fix_rg_inner_preallocgrp = { - f_PreAllocGrp_NoAllocs : int option; - f_PreAllocGrp_AllocAccount : string option; - f_PreAllocGrp_AllocAcctIDSource : int option; - f_PreAllocGrp_AllocSettlCurrency : fix_currency option; - f_PreAllocGrp_IndividualAllocID : string option; - f_PreAllocGrp_NestedParties : fix_rg_nestedparties; - f_PreAllocGrp_AllocQty : fix_float_6 option -} -;; - -type fix_rg_preallocgrp = fix_rg_inner_preallocgrp list -;; - -type fix_rg_inner_rgstdtlsgrp = { - f_RgstDtlsGrp_NoRegistDtls : int option; - f_RgstDtlsGrp_RegistDtls : string option; - f_RgstDtlsGrp_RegistEmail : string option; - f_RgstDtlsGrp_MailingDtls : string option; - f_RgstDtlsGrp_MailingInst : string option; - f_RgstDtlsGrp_NestedParties : fix_rg_nestedparties; - f_RgstDtlsGrp_OwnerType : fix_ownertype option; - f_RgstDtlsGrp_DateOfBirth : fix_localmktdate option; - f_RgstDtlsGrp_InvestorCountryOfResidence : fix_country option -} -;; - -type fix_rg_rgstdtlsgrp = fix_rg_inner_rgstdtlsgrp list -;; - -type fix_rg_inner_instrmtlegexecgrp = { - f_InstrmtLegExecGrp_NoLegs : int option; - f_InstrmtLegExecGrp_InstrumentLeg : fix_instrumentleg; - f_InstrmtLegExecGrp_LegQty : fix_float_6 option; - f_InstrmtLegExecGrp_LegSwapType : fix_legswaptype option; - f_InstrmtLegExecGrp_LegStipulations : fix_rg_legstipulations; - f_InstrmtLegExecGrp_LegPositionEffect : string option; - f_InstrmtLegExecGrp_LegCoveredOrUncovered : int option; - f_InstrmtLegExecGrp_NestedParties : fix_rg_nestedparties; - f_InstrmtLegExecGrp_LegRefID : string option; - f_InstrmtLegExecGrp_LegPrice : fix_float_6 option; - f_InstrmtLegExecGrp_LegSettlType : string option; - f_InstrmtLegExecGrp_LegSettlDate : fix_localmktdate option; - f_InstrmtLegExecGrp_LegLastPx : fix_float_6 option -} -;; - -type fix_rg_instrmtlegexecgrp = fix_rg_inner_instrmtlegexecgrp list -;; - -type fix_rg_inner_legquotgrp = { - f_LegQuotGrp_NoLegs : int option; - f_LegQuotGrp_InstrumentLeg : fix_instrumentleg; - f_LegQuotGrp_LegQty : fix_float_6 option; - f_LegQuotGrp_LegSwapType : fix_legswaptype option; - f_LegQuotGrp_LegSettlType : string option; - f_LegQuotGrp_LegSettlDate : fix_localmktdate option; - f_LegQuotGrp_LegStipulations : fix_rg_legstipulations; - f_LegQuotGrp_NestedParties : fix_rg_nestedparties; - f_LegQuotGrp_LegPriceType : int option; - f_LegQuotGrp_LegBidPx : fix_float_6 option; - f_LegQuotGrp_LegOfferPx : fix_float_6 option; - f_LegQuotGrp_LegBenchmarkCurveData : fix_legbenchmarkcurvedata -} -;; - -type fix_rg_legquotgrp = fix_rg_inner_legquotgrp list -;; - -type fix_rg_inner_quotreqlegsgrp = { - f_QuotReqLegsGrp_NoLegs : int option; - f_QuotReqLegsGrp_InstrumentLeg : fix_instrumentleg; - f_QuotReqLegsGrp_LegQty : fix_float_6 option; - f_QuotReqLegsGrp_LegSwapType : fix_legswaptype option; - f_QuotReqLegsGrp_LegSettlType : string option; - f_QuotReqLegsGrp_LegSettlDate : fix_localmktdate option; - f_QuotReqLegsGrp_LegStipulations : fix_rg_legstipulations; - f_QuotReqLegsGrp_NestedParties : fix_rg_nestedparties; - f_QuotReqLegsGrp_LegBenchmarkCurveData : fix_legbenchmarkcurvedata -} -;; - -type fix_rg_quotreqlegsgrp = fix_rg_inner_quotreqlegsgrp list -;; - -type fix_rg_inner_positionqty = { - f_PositionQty_NoPositions : int option; - (** Required if NoPositions > 1*) - f_PositionQty_PosType : fix_postype option; - f_PositionQty_LongQty : fix_float_6 option; - f_PositionQty_ShortQty : fix_float_6 option; - f_PositionQty_PosQtyStatus : fix_posqtystatus option; - (** Optional repeating group - used to associate or distribute position to a specific party other than the party that currently owns the position.*) - f_PositionQty_NestedParties : fix_rg_nestedparties -} -;; - -type fix_rg_positionqty = fix_rg_inner_positionqty list -;; - -type fix_rg_inner_trdinstrmtleggrp = { - f_TrdInstrmtLegGrp_NoLegs : int option; - f_TrdInstrmtLegGrp_InstrumentLeg : fix_instrumentleg; - f_TrdInstrmtLegGrp_LegQty : fix_float_6 option; - f_TrdInstrmtLegGrp_LegSwapType : fix_legswaptype option; - f_TrdInstrmtLegGrp_LegStipulations : fix_rg_legstipulations; - f_TrdInstrmtLegGrp_LegPositionEffect : string option; - f_TrdInstrmtLegGrp_LegCoveredOrUncovered : int option; - f_TrdInstrmtLegGrp_NestedParties : fix_rg_nestedparties; - f_TrdInstrmtLegGrp_LegRefID : string option; - f_TrdInstrmtLegGrp_LegPrice : fix_float_6 option; - f_TrdInstrmtLegGrp_LegSettlType : string option; - f_TrdInstrmtLegGrp_LegSettlDate : fix_localmktdate option; - f_TrdInstrmtLegGrp_LegLastPx : fix_float_6 option -} -;; - -type fix_rg_trdinstrmtleggrp = fix_rg_inner_trdinstrmtleggrp list -;; - -type fix_rg_inner_sidecrossordcxlgrp = { - f_SideCrossOrdCxlGrp_NoSides : int option; - f_SideCrossOrdCxlGrp_Side : fix_side option; - f_SideCrossOrdCxlGrp_OrigClOrdID : string option; - f_SideCrossOrdCxlGrp_ClOrdID : string option; - f_SideCrossOrdCxlGrp_SecondaryClOrdID : string option; - f_SideCrossOrdCxlGrp_ClOrdLinkID : string option; - f_SideCrossOrdCxlGrp_OrigOrdModTime : fix_utctimestamp_milli option; - f_SideCrossOrdCxlGrp_Parties : fix_rg_parties; - f_SideCrossOrdCxlGrp_TradeOriginationDate : fix_localmktdate option; - f_SideCrossOrdCxlGrp_TradeDate : fix_localmktdate option; - f_SideCrossOrdCxlGrp_OrderQtyData : fix_orderqtydata; - f_SideCrossOrdCxlGrp_ComplianceID : string option; - f_SideCrossOrdCxlGrp_Text : string option; - f_SideCrossOrdCxlGrp_EncodedTextLen : int option; - f_SideCrossOrdCxlGrp_EncodedText : string option -} -;; - -type fix_rg_sidecrossordcxlgrp = fix_rg_inner_sidecrossordcxlgrp list -;; - -type fix_rg_inner_dlvyinstgrp = { - f_DlvyInstGrp_NoDlvyInst : int option; - f_DlvyInstGrp_SettlInstSource : fix_settlinstsource option; - f_DlvyInstGrp_DlvyInstType : fix_dlvyinsttype option; - f_DlvyInstGrp_SettlParties : fix_rg_settlparties -} -;; - -type fix_rg_dlvyinstgrp = fix_rg_inner_dlvyinstgrp list -;; - -type fix_settlinstructionsdata = { - (** Required if AllocSettlInstType = 1 or 2*) - f_SettlInstructionsData_SettlDeliveryType : fix_settldeliverytype option; - (** Required if AllocSettlInstType = 3 (should not be populated otherwise)*) - f_SettlInstructionsData_StandInstDbType : fix_standinstdbtype option; - (** Required if AllocSettlInstType = 3 (should not be populated otherwise)*) - f_SettlInstructionsData_StandInstDbName : string option; - (** Identifier used within the StandInstDbType - Required if AllocSettlInstType = 3 (should not be populated otherwise)*) - f_SettlInstructionsData_StandInstDbID : string option; - (** Required (and must be > 0) if AllocSettlInstType = 2 (should not be populated otherwise)*) - f_SettlInstructionsData_DlvyInstGrp : fix_rg_dlvyinstgrp -} -;; - -type fix_rg_inner_sidecrossordmodgrp = { - f_SideCrossOrdModGrp_NoSides : int option; - f_SideCrossOrdModGrp_Side : fix_side option; - f_SideCrossOrdModGrp_ClOrdID : string option; - f_SideCrossOrdModGrp_SecondaryClOrdID : string option; - f_SideCrossOrdModGrp_ClOrdLinkID : string option; - f_SideCrossOrdModGrp_Parties : fix_rg_parties; - f_SideCrossOrdModGrp_TradeOriginationDate : fix_localmktdate option; - f_SideCrossOrdModGrp_TradeDate : fix_localmktdate option; - f_SideCrossOrdModGrp_Account : string option; - f_SideCrossOrdModGrp_AcctIDSource : fix_acctidsource option; - f_SideCrossOrdModGrp_AccountType : fix_accounttype option; - f_SideCrossOrdModGrp_DayBookingInst : fix_daybookinginst option; - f_SideCrossOrdModGrp_BookingUnit : fix_bookingunit option; - f_SideCrossOrdModGrp_PreallocMethod : fix_preallocmethod option; - f_SideCrossOrdModGrp_AllocID : string option; - f_SideCrossOrdModGrp_PreAllocGrp : fix_rg_preallocgrp; - f_SideCrossOrdModGrp_QtyType : fix_qtytype option; - f_SideCrossOrdModGrp_OrderQtyData : fix_orderqtydata; - f_SideCrossOrdModGrp_CommissionData : fix_commissiondata; - f_SideCrossOrdModGrp_OrderCapacity : fix_ordercapacity option; - f_SideCrossOrdModGrp_OrderRestrictions : fix_orderrestrictions list option; - f_SideCrossOrdModGrp_CustOrderCapacity : fix_custordercapacity option; - f_SideCrossOrdModGrp_ForexReq : fix_forexreq option; - f_SideCrossOrdModGrp_SettlCurrency : fix_currency option; - f_SideCrossOrdModGrp_BookingType : fix_bookingtype option; - f_SideCrossOrdModGrp_Text : string option; - f_SideCrossOrdModGrp_EncodedTextLen : int option; - f_SideCrossOrdModGrp_EncodedText : string option; - f_SideCrossOrdModGrp_PositionEffect : fix_positioneffect option; - f_SideCrossOrdModGrp_CoveredOrUncovered : fix_coveredoruncovered option; - f_SideCrossOrdModGrp_CashMargin : fix_cashmargin option; - f_SideCrossOrdModGrp_ClearingFeeIndicator : fix_clearingfeeindicator option; - f_SideCrossOrdModGrp_SolicitedFlag : fix_solicitedflag option; - f_SideCrossOrdModGrp_SideComplianceID : string option -} -;; - -type fix_rg_sidecrossordmodgrp = fix_rg_inner_sidecrossordmodgrp list -;; - -type fix_rg_inner_legordgrp = { - f_LegOrdGrp_NoLegs : int option; - f_LegOrdGrp_InstrumentLeg : fix_instrumentleg; - f_LegOrdGrp_LegQty : fix_float_6 option; - f_LegOrdGrp_LegSwapType : fix_legswaptype option; - f_LegOrdGrp_LegStipulations : fix_rg_legstipulations; - f_LegOrdGrp_LegPreAllocGrp : fix_rg_legpreallocgrp; - f_LegOrdGrp_LegPositionEffect : string option; - f_LegOrdGrp_LegCoveredOrUncovered : int option; - f_LegOrdGrp_NestedParties : fix_rg_nestedparties; - f_LegOrdGrp_LegRefID : string option; - f_LegOrdGrp_LegPrice : fix_float_6 option; - f_LegOrdGrp_LegSettlType : string option; - f_LegOrdGrp_LegSettlDate : fix_localmktdate option -} -;; - -type fix_rg_legordgrp = fix_rg_inner_legordgrp list -;; - -type fix_rg_inner_trdcaprptsidegrp = { - f_TrdCapRptSideGrp_NoSides : int option; - f_TrdCapRptSideGrp_Side : fix_side option; - f_TrdCapRptSideGrp_OrderID : string option; - f_TrdCapRptSideGrp_SecondaryOrderID : string option; - f_TrdCapRptSideGrp_ClOrdID : string option; - f_TrdCapRptSideGrp_SecondaryClOrdID : string option; - f_TrdCapRptSideGrp_ListID : string option; - f_TrdCapRptSideGrp_Parties : fix_rg_parties; - f_TrdCapRptSideGrp_Account : string option; - f_TrdCapRptSideGrp_AcctIDSource : fix_acctidsource option; - f_TrdCapRptSideGrp_AccountType : fix_accounttype option; - f_TrdCapRptSideGrp_ProcessCode : fix_processcode option; - f_TrdCapRptSideGrp_OddLot : fix_oddlot option; - f_TrdCapRptSideGrp_ClrInstGrp : fix_rg_clrinstgrp; - f_TrdCapRptSideGrp_TradeInputSource : string option; - f_TrdCapRptSideGrp_TradeInputDevice : string option; - f_TrdCapRptSideGrp_OrderInputDevice : string option; - f_TrdCapRptSideGrp_Currency : fix_currency option; - f_TrdCapRptSideGrp_ComplianceID : string option; - f_TrdCapRptSideGrp_SolicitedFlag : fix_solicitedflag option; - f_TrdCapRptSideGrp_OrderCapacity : fix_ordercapacity option; - f_TrdCapRptSideGrp_OrderRestrictions : fix_orderrestrictions list option; - f_TrdCapRptSideGrp_CustOrderCapacity : fix_custordercapacity option; - f_TrdCapRptSideGrp_OrdType : fix_ordtype option; - f_TrdCapRptSideGrp_ExecInst : fix_execinst list option; - f_TrdCapRptSideGrp_TransBkdTime : fix_utctimestamp_milli option; - f_TrdCapRptSideGrp_TradingSessionID : string option; - f_TrdCapRptSideGrp_TradingSessionSubID : string option; - f_TrdCapRptSideGrp_TimeBracket : string option; - f_TrdCapRptSideGrp_CommissionData : fix_commissiondata; - f_TrdCapRptSideGrp_GrossTradeAmt : fix_float_6 option; - f_TrdCapRptSideGrp_NumDaysInterest : int option; - f_TrdCapRptSideGrp_ExDate : fix_localmktdate option; - f_TrdCapRptSideGrp_AccruedInterestRate : fix_float_6 option; - f_TrdCapRptSideGrp_AccruedInterestAmt : fix_float_6 option; - f_TrdCapRptSideGrp_InterestAtMaturity : fix_float_6 option; - f_TrdCapRptSideGrp_EndAccruedInterestAmt : fix_float_6 option; - f_TrdCapRptSideGrp_StartCash : fix_float_6 option; - f_TrdCapRptSideGrp_EndCash : fix_float_6 option; - f_TrdCapRptSideGrp_Concession : fix_float_6 option; - f_TrdCapRptSideGrp_TotalTakedown : fix_float_6 option; - f_TrdCapRptSideGrp_NetMoney : fix_float_6 option; - f_TrdCapRptSideGrp_SettlCurrAmt : fix_float_6 option; - f_TrdCapRptSideGrp_SettlCurrency : fix_currency option; - f_TrdCapRptSideGrp_SettlCurrFxRate : fix_float option; - f_TrdCapRptSideGrp_SettlCurrFxRateCalc : fix_settlcurrfxratecalc option; - f_TrdCapRptSideGrp_PositionEffect : fix_positioneffect option; - f_TrdCapRptSideGrp_Text : string option; - f_TrdCapRptSideGrp_EncodedTextLen : int option; - f_TrdCapRptSideGrp_EncodedText : string option; - f_TrdCapRptSideGrp_SideMultiLegReportingType : fix_sidemultilegreportingtype option; - f_TrdCapRptSideGrp_ContAmtGrp : fix_rg_contamtgrp; - f_TrdCapRptSideGrp_Stipulations : fix_rg_stipulations; - f_TrdCapRptSideGrp_MiscFeesGrp : fix_rg_miscfeesgrp; - f_TrdCapRptSideGrp_ExchangeRule : string option; - f_TrdCapRptSideGrp_TradeAllocIndicator : fix_tradeallocindicator option; - f_TrdCapRptSideGrp_PreallocMethod : fix_preallocmethod option; - f_TrdCapRptSideGrp_AllocID : string option; - f_TrdCapRptSideGrp_TrdAllocGrp : fix_rg_trdallocgrp -} -;; - -type fix_rg_trdcaprptsidegrp = fix_rg_inner_trdcaprptsidegrp list -;; - -type fix_rg_inner_relsymderivsecgrp = { - f_RelSymDerivSecGrp_NoRelatedSym : int option; - f_RelSymDerivSecGrp_Instrument : fix_instrument; - f_RelSymDerivSecGrp_Currency : fix_currency option; - f_RelSymDerivSecGrp_ExpirationCycle : fix_expirationcycle option; - f_RelSymDerivSecGrp_InstrumentExtension : fix_instrumentextension; - f_RelSymDerivSecGrp_InstrmtLegGrp : fix_rg_instrmtleggrp; - f_RelSymDerivSecGrp_TradingSessionID : string option; - f_RelSymDerivSecGrp_TradingSessionSubID : string option; - f_RelSymDerivSecGrp_Text : string option; - f_RelSymDerivSecGrp_EncodedTextLen : int option; - f_RelSymDerivSecGrp_EncodedText : string option -} -;; - -type fix_rg_relsymderivsecgrp = fix_rg_inner_relsymderivsecgrp list -;; - -type fix_rg_inner_quotentrygrp = { - f_QuotEntryGrp_NoQuoteEntries : int option; - f_QuotEntryGrp_QuoteEntryID : string option; - f_QuotEntryGrp_Instrument : fix_instrument; - f_QuotEntryGrp_InstrmtLegGrp : fix_rg_instrmtleggrp; - f_QuotEntryGrp_BidPx : fix_float_6 option; - f_QuotEntryGrp_OfferPx : fix_float_6 option; - f_QuotEntryGrp_BidSize : fix_float_6 option; - f_QuotEntryGrp_OfferSize : fix_float_6 option; - f_QuotEntryGrp_ValidUntilTime : fix_utctimestamp_milli option; - f_QuotEntryGrp_BidSpotRate : fix_float_6 option; - f_QuotEntryGrp_OfferSpotRate : fix_float_6 option; - f_QuotEntryGrp_BidForwardPoints : fix_float_6 option; - f_QuotEntryGrp_OfferForwardPoints : fix_float_6 option; - f_QuotEntryGrp_MidPx : fix_float_6 option; - f_QuotEntryGrp_BidYield : fix_float_6 option; - f_QuotEntryGrp_MidYield : fix_float_6 option; - f_QuotEntryGrp_OfferYield : fix_float_6 option; - f_QuotEntryGrp_TransactTime : fix_utctimestamp_milli option; - f_QuotEntryGrp_TradingSessionID : string option; - f_QuotEntryGrp_TradingSessionSubID : string option; - f_QuotEntryGrp_SettlDate : fix_localmktdate option; - f_QuotEntryGrp_OrdType : fix_ordtype option; - f_QuotEntryGrp_SettlDate2 : fix_localmktdate option; - f_QuotEntryGrp_OrderQty2 : fix_float_6 option; - f_QuotEntryGrp_BidForwardPoints2 : fix_float_6 option; - f_QuotEntryGrp_OfferForwardPoints2 : fix_float_6 option; - f_QuotEntryGrp_Currency : fix_currency option -} -;; - -type fix_rg_quotentrygrp = fix_rg_inner_quotentrygrp list -;; - -type fix_rg_inner_quotentryackgrp = { - f_QuotEntryAckGrp_NoQuoteEntries : int option; - f_QuotEntryAckGrp_QuoteEntryID : string option; - f_QuotEntryAckGrp_Instrument : fix_instrument; - f_QuotEntryAckGrp_InstrmtLegGrp : fix_rg_instrmtleggrp; - f_QuotEntryAckGrp_BidPx : fix_float_6 option; - f_QuotEntryAckGrp_OfferPx : fix_float_6 option; - f_QuotEntryAckGrp_BidSize : fix_float_6 option; - f_QuotEntryAckGrp_OfferSize : fix_float_6 option; - f_QuotEntryAckGrp_ValidUntilTime : fix_utctimestamp_milli option; - f_QuotEntryAckGrp_BidSpotRate : fix_float_6 option; - f_QuotEntryAckGrp_OfferSpotRate : fix_float_6 option; - f_QuotEntryAckGrp_BidForwardPoints : fix_float_6 option; - f_QuotEntryAckGrp_OfferForwardPoints : fix_float_6 option; - f_QuotEntryAckGrp_MidPx : fix_float_6 option; - f_QuotEntryAckGrp_BidYield : fix_float_6 option; - f_QuotEntryAckGrp_MidYield : fix_float_6 option; - f_QuotEntryAckGrp_OfferYield : fix_float_6 option; - f_QuotEntryAckGrp_TransactTime : fix_utctimestamp_milli option; - f_QuotEntryAckGrp_TradingSessionID : string option; - f_QuotEntryAckGrp_TradingSessionSubID : string option; - f_QuotEntryAckGrp_SettlDate : fix_localmktdate option; - f_QuotEntryAckGrp_OrdType : fix_ordtype option; - f_QuotEntryAckGrp_SettlDate2 : fix_localmktdate option; - f_QuotEntryAckGrp_OrderQty2 : fix_float_6 option; - f_QuotEntryAckGrp_BidForwardPoints2 : fix_float_6 option; - f_QuotEntryAckGrp_OfferForwardPoints2 : fix_float_6 option; - f_QuotEntryAckGrp_Currency : fix_currency option; - f_QuotEntryAckGrp_QuoteEntryRejectReason : int option -} -;; - -type fix_rg_quotentryackgrp = fix_rg_inner_quotentryackgrp list -;; - -type fix_rg_inner_listordgrp = { - f_ListOrdGrp_NoOrders : int option; - f_ListOrdGrp_ClOrdID : string option; - f_ListOrdGrp_SecondaryClOrdID : string option; - f_ListOrdGrp_ListSeqNo : int option; - f_ListOrdGrp_ClOrdLinkID : string option; - f_ListOrdGrp_SettlInstMode : fix_settlinstmode option; - f_ListOrdGrp_Parties : fix_rg_parties; - f_ListOrdGrp_TradeOriginationDate : fix_localmktdate option; - f_ListOrdGrp_TradeDate : fix_localmktdate option; - f_ListOrdGrp_Account : string option; - f_ListOrdGrp_AcctIDSource : fix_acctidsource option; - f_ListOrdGrp_AccountType : fix_accounttype option; - f_ListOrdGrp_DayBookingInst : fix_daybookinginst option; - f_ListOrdGrp_BookingUnit : fix_bookingunit option; - f_ListOrdGrp_AllocID : string option; - f_ListOrdGrp_PreallocMethod : fix_preallocmethod option; - f_ListOrdGrp_PreAllocGrp : fix_rg_preallocgrp; - f_ListOrdGrp_SettlType : fix_settltype option; - f_ListOrdGrp_SettlDate : fix_localmktdate option; - f_ListOrdGrp_CashMargin : fix_cashmargin option; - f_ListOrdGrp_ClearingFeeIndicator : fix_clearingfeeindicator option; - f_ListOrdGrp_HandlInst : fix_handlinst option; - f_ListOrdGrp_ExecInst : fix_execinst list option; - f_ListOrdGrp_MinQty : fix_float_6 option; - f_ListOrdGrp_MaxFloor : fix_float_6 option; - f_ListOrdGrp_ExDestination : fix_exchange option; - f_ListOrdGrp_TrdgSesGrp : fix_rg_trdgsesgrp; - f_ListOrdGrp_ProcessCode : fix_processcode option; - f_ListOrdGrp_Instrument : fix_instrument; - f_ListOrdGrp_UndInstrmtGrp : fix_rg_undinstrmtgrp; - f_ListOrdGrp_PrevClosePx : fix_float_6 option; - f_ListOrdGrp_Side : fix_side option; - f_ListOrdGrp_SideValueInd : fix_sidevalueind option; - f_ListOrdGrp_LocateReqd : fix_locatereqd option; - f_ListOrdGrp_TransactTime : fix_utctimestamp_milli option; - f_ListOrdGrp_Stipulations : fix_rg_stipulations; - f_ListOrdGrp_QtyType : fix_qtytype option; - f_ListOrdGrp_OrderQtyData : fix_orderqtydata; - f_ListOrdGrp_OrdType : fix_ordtype option; - f_ListOrdGrp_PriceType : fix_pricetype option; - f_ListOrdGrp_Price : fix_float_6 option; - f_ListOrdGrp_StopPx : fix_float_6 option; - f_ListOrdGrp_SpreadOrBenchmarkCurveData : fix_spreadorbenchmarkcurvedata; - f_ListOrdGrp_YieldData : fix_yielddata; - f_ListOrdGrp_Currency : fix_currency option; - f_ListOrdGrp_ComplianceID : string option; - f_ListOrdGrp_SolicitedFlag : fix_solicitedflag option; - f_ListOrdGrp_IOIID : string option; - f_ListOrdGrp_QuoteID : string option; - f_ListOrdGrp_TimeInForce : fix_timeinforce option; - f_ListOrdGrp_EffectiveTime : fix_utctimestamp_milli option; - f_ListOrdGrp_ExpireDate : fix_localmktdate option; - f_ListOrdGrp_ExpireTime : fix_utctimestamp_milli option; - f_ListOrdGrp_GTBookingInst : fix_gtbookinginst option; - f_ListOrdGrp_CommissionData : fix_commissiondata; - f_ListOrdGrp_OrderCapacity : fix_ordercapacity option; - f_ListOrdGrp_OrderRestrictions : fix_orderrestrictions list option; - f_ListOrdGrp_CustOrderCapacity : fix_custordercapacity option; - f_ListOrdGrp_ForexReq : fix_forexreq option; - f_ListOrdGrp_SettlCurrency : fix_currency option; - f_ListOrdGrp_BookingType : fix_bookingtype option; - f_ListOrdGrp_Text : string option; - f_ListOrdGrp_EncodedTextLen : int option; - f_ListOrdGrp_EncodedText : string option; - f_ListOrdGrp_SettlDate2 : fix_localmktdate option; - f_ListOrdGrp_OrderQty2 : fix_float_6 option; - f_ListOrdGrp_Price2 : fix_float_6 option; - f_ListOrdGrp_PositionEffect : fix_positioneffect option; - f_ListOrdGrp_CoveredOrUncovered : fix_coveredoruncovered option; - f_ListOrdGrp_MaxShow : fix_float_6 option; - f_ListOrdGrp_PegInstructions : fix_peginstructions; - f_ListOrdGrp_DiscretionInstructions : fix_discretioninstructions; - f_ListOrdGrp_TargetStrategy : fix_targetstrategy option; - f_ListOrdGrp_TargetStrategyParameters : string option; - f_ListOrdGrp_ParticipationRate : fix_float_6 option; - f_ListOrdGrp_Designation : string option -} -;; - -type fix_rg_listordgrp = fix_rg_inner_listordgrp list -;; - -type fix_rg_inner_quotreqrjctgrp = { - f_QuotReqRjctGrp_NoRelatedSym : int option; - f_QuotReqRjctGrp_Instrument : fix_instrument; - f_QuotReqRjctGrp_FinancingDetails : fix_financingdetails; - f_QuotReqRjctGrp_UndInstrmtGrp : fix_rg_undinstrmtgrp; - f_QuotReqRjctGrp_PrevClosePx : fix_float_6 option; - f_QuotReqRjctGrp_QuoteRequestType : fix_quoterequesttype option; - f_QuotReqRjctGrp_QuoteType : fix_quotetype option; - f_QuotReqRjctGrp_TradingSessionID : string option; - f_QuotReqRjctGrp_TradingSessionSubID : string option; - f_QuotReqRjctGrp_TradeOriginationDate : fix_localmktdate option; - f_QuotReqRjctGrp_Side : fix_side option; - f_QuotReqRjctGrp_QtyType : fix_qtytype option; - f_QuotReqRjctGrp_OrderQtyData : fix_orderqtydata; - f_QuotReqRjctGrp_SettlType : fix_settltype option; - f_QuotReqRjctGrp_SettlDate : fix_localmktdate option; - f_QuotReqRjctGrp_SettlDate2 : fix_localmktdate option; - f_QuotReqRjctGrp_OrderQty2 : fix_float_6 option; - f_QuotReqRjctGrp_Currency : fix_currency option; - f_QuotReqRjctGrp_Stipulations : fix_rg_stipulations; - f_QuotReqRjctGrp_Account : string option; - f_QuotReqRjctGrp_AcctIDSource : fix_acctidsource option; - f_QuotReqRjctGrp_AccountType : fix_accounttype option; - f_QuotReqRjctGrp_QuotReqLegsGrp : fix_rg_quotreqlegsgrp; - f_QuotReqRjctGrp_QuotQualGrp : fix_rg_quotqualgrp; - f_QuotReqRjctGrp_QuotePriceType : fix_quotepricetype option; - f_QuotReqRjctGrp_OrdType : fix_ordtype option; - f_QuotReqRjctGrp_ExpireTime : fix_utctimestamp_milli option; - f_QuotReqRjctGrp_TransactTime : fix_utctimestamp_milli option; - f_QuotReqRjctGrp_SpreadOrBenchmarkCurveData : fix_spreadorbenchmarkcurvedata; - f_QuotReqRjctGrp_PriceType : fix_pricetype option; - f_QuotReqRjctGrp_Price : fix_float_6 option; - f_QuotReqRjctGrp_Price2 : fix_float_6 option; - f_QuotReqRjctGrp_YieldData : fix_yielddata; - f_QuotReqRjctGrp_Parties : fix_rg_parties -} -;; - -type fix_rg_quotreqrjctgrp = fix_rg_inner_quotreqrjctgrp list -;; - -type fix_rg_inner_rfqreqgrp = { - f_RFQReqGrp_NoRelatedSym : int option; - f_RFQReqGrp_Instrument : fix_instrument; - f_RFQReqGrp_UndInstrmtGrp : fix_rg_undinstrmtgrp; - f_RFQReqGrp_InstrmtLegGrp : fix_rg_instrmtleggrp; - f_RFQReqGrp_PrevClosePx : fix_float_6 option; - f_RFQReqGrp_QuoteRequestType : fix_quoterequesttype option; - f_RFQReqGrp_QuoteType : fix_quotetype option; - f_RFQReqGrp_TradingSessionID : string option; - f_RFQReqGrp_TradingSessionSubID : string option -} -;; - -type fix_rg_rfqreqgrp = fix_rg_inner_rfqreqgrp list -;; - -type fix_rg_inner_instrmtmdreqgrp = { - f_InstrmtMDReqGrp_NoRelatedSym : int option; - f_InstrmtMDReqGrp_Instrument : fix_instrument; - f_InstrmtMDReqGrp_UndInstrmtGrp : fix_rg_undinstrmtgrp; - f_InstrmtMDReqGrp_InstrmtLegGrp : fix_rg_instrmtleggrp -} -;; - -type fix_rg_instrmtmdreqgrp = fix_rg_inner_instrmtmdreqgrp list -;; - -type fix_rg_inner_mdincgrp = { - f_MDIncGrp_NoMDEntries : int option; - f_MDIncGrp_MDUpdateAction : fix_mdupdateaction option; - f_MDIncGrp_DeleteReason : fix_deletereason option; - f_MDIncGrp_MDEntryType : fix_mdentrytype option; - f_MDIncGrp_MDEntryID : string option; - f_MDIncGrp_MDEntryRefID : string option; - f_MDIncGrp_Instrument : fix_instrument; - f_MDIncGrp_UndInstrmtGrp : fix_rg_undinstrmtgrp; - f_MDIncGrp_InstrmtLegGrp : fix_rg_instrmtleggrp; - f_MDIncGrp_FinancialStatus : fix_financialstatus list option; - f_MDIncGrp_CorporateAction : fix_corporateaction list option; - f_MDIncGrp_MDEntryPx : fix_float_6 option; - f_MDIncGrp_Currency : fix_currency option; - f_MDIncGrp_MDEntrySize : fix_float_6 option; - f_MDIncGrp_MDEntryDate : fix_utcdateonly option; - f_MDIncGrp_MDEntryTime : fix_utctimeonly_milli option; - f_MDIncGrp_TickDirection : fix_tickdirection option; - f_MDIncGrp_MDMkt : fix_exchange option; - f_MDIncGrp_TradingSessionID : string option; - f_MDIncGrp_TradingSessionSubID : string option; - f_MDIncGrp_QuoteCondition : fix_quotecondition list option; - f_MDIncGrp_TradeCondition : fix_tradecondition list option; - f_MDIncGrp_MDEntryOriginator : string option; - f_MDIncGrp_LocationID : string option; - f_MDIncGrp_DeskID : string option; - f_MDIncGrp_OpenCloseSettlFlag : fix_openclosesettlflag list option; - f_MDIncGrp_TimeInForce : fix_timeinforce option; - f_MDIncGrp_ExpireDate : fix_localmktdate option; - f_MDIncGrp_ExpireTime : fix_utctimestamp_milli option; - f_MDIncGrp_MinQty : fix_float_6 option; - f_MDIncGrp_ExecInst : fix_execinst list option; - f_MDIncGrp_SellerDays : int option; - f_MDIncGrp_OrderID : string option; - f_MDIncGrp_QuoteEntryID : string option; - f_MDIncGrp_MDEntryBuyer : string option; - f_MDIncGrp_MDEntrySeller : string option; - f_MDIncGrp_NumberOfOrders : int option; - f_MDIncGrp_MDEntryPositionNo : int option; - f_MDIncGrp_Scope : fix_scope list option; - f_MDIncGrp_PriceDelta : fix_float option; - f_MDIncGrp_NetChgPrevDay : fix_float_6 option; - f_MDIncGrp_Text : string option; - f_MDIncGrp_EncodedTextLen : int option; - f_MDIncGrp_EncodedText : string option -} -;; - -type fix_rg_mdincgrp = fix_rg_inner_mdincgrp list -;; - -type fix_rg_inner_seclistgrp = { - f_SecListGrp_NoRelatedSym : int option; - f_SecListGrp_Instrument : fix_instrument; - f_SecListGrp_InstrumentExtension : fix_instrumentextension; - f_SecListGrp_FinancingDetails : fix_financingdetails; - f_SecListGrp_UndInstrmtGrp : fix_rg_undinstrmtgrp; - f_SecListGrp_Currency : fix_currency option; - f_SecListGrp_Stipulations : fix_rg_stipulations; - f_SecListGrp_InstrmtLegSecListGrp : fix_rg_instrmtlegseclistgrp; - f_SecListGrp_SpreadOrBenchmarkCurveData : fix_spreadorbenchmarkcurvedata; - f_SecListGrp_YieldData : fix_yielddata; - f_SecListGrp_RoundLot : fix_float_6 option; - f_SecListGrp_MinTradeVol : fix_float_6 option; - f_SecListGrp_TradingSessionID : string option; - f_SecListGrp_TradingSessionSubID : string option; - f_SecListGrp_ExpirationCycle : fix_expirationcycle option; - f_SecListGrp_Text : string option; - f_SecListGrp_EncodedTextLen : int option; - f_SecListGrp_EncodedText : string option -} -;; - -type fix_rg_seclistgrp = fix_rg_inner_seclistgrp list -;; - -type fix_rg_inner_quotreqgrp = { - f_QuotReqGrp_NoRelatedSym : int option; - f_QuotReqGrp_Instrument : fix_instrument; - f_QuotReqGrp_FinancingDetails : fix_financingdetails; - f_QuotReqGrp_UndInstrmtGrp : fix_rg_undinstrmtgrp; - f_QuotReqGrp_PrevClosePx : fix_float_6 option; - f_QuotReqGrp_QuoteRequestType : fix_quoterequesttype option; - f_QuotReqGrp_QuoteType : fix_quotetype option; - f_QuotReqGrp_TradingSessionID : string option; - f_QuotReqGrp_TradingSessionSubID : string option; - f_QuotReqGrp_TradeOriginationDate : fix_localmktdate option; - f_QuotReqGrp_Side : fix_side option; - f_QuotReqGrp_QtyType : fix_qtytype option; - f_QuotReqGrp_OrderQtyData : fix_orderqtydata; - f_QuotReqGrp_SettlType : fix_settltype option; - f_QuotReqGrp_SettlDate : fix_localmktdate option; - f_QuotReqGrp_SettlDate2 : fix_localmktdate option; - f_QuotReqGrp_OrderQty2 : fix_float_6 option; - f_QuotReqGrp_Currency : fix_currency option; - f_QuotReqGrp_Stipulations : fix_rg_stipulations; - f_QuotReqGrp_Account : string option; - f_QuotReqGrp_AcctIDSource : fix_acctidsource option; - f_QuotReqGrp_AccountType : fix_accounttype option; - f_QuotReqGrp_QuotReqLegsGrp : fix_rg_quotreqlegsgrp; - f_QuotReqGrp_QuotQualGrp : fix_rg_quotqualgrp; - f_QuotReqGrp_QuotePriceType : fix_quotepricetype option; - f_QuotReqGrp_OrdType : fix_ordtype option; - f_QuotReqGrp_ValidUntilTime : fix_utctimestamp_milli option; - f_QuotReqGrp_ExpireTime : fix_utctimestamp_milli option; - f_QuotReqGrp_TransactTime : fix_utctimestamp_milli option; - f_QuotReqGrp_SpreadOrBenchmarkCurveData : fix_spreadorbenchmarkcurvedata; - f_QuotReqGrp_PriceType : fix_pricetype option; - f_QuotReqGrp_Price : fix_float_6 option; - f_QuotReqGrp_Price2 : fix_float_6 option; - f_QuotReqGrp_YieldData : fix_yielddata; - f_QuotReqGrp_Parties : fix_rg_parties -} -;; - -type fix_rg_quotreqgrp = fix_rg_inner_quotreqgrp list -;; - -type fix_rg_inner_quotcxlentriesgrp = { - f_QuotCxlEntriesGrp_NoQuoteEntries : int option; - f_QuotCxlEntriesGrp_Instrument : fix_instrument; - f_QuotCxlEntriesGrp_FinancingDetails : fix_financingdetails; - f_QuotCxlEntriesGrp_UndInstrmtGrp : fix_rg_undinstrmtgrp; - f_QuotCxlEntriesGrp_InstrmtLegGrp : fix_rg_instrmtleggrp -} -;; - -type fix_rg_quotcxlentriesgrp = fix_rg_inner_quotcxlentriesgrp list -;; - -type fix_rg_inner_quotsetackgrp = { - f_QuotSetAckGrp_NoQuoteSets : int option; - f_QuotSetAckGrp_QuoteSetID : string option; - f_QuotSetAckGrp_UnderlyingInstrument : fix_underlyinginstrument; - f_QuotSetAckGrp_TotNoQuoteEntries : int option; - f_QuotSetAckGrp_LastFragment : fix_lastfragment option; - f_QuotSetAckGrp_QuotEntryAckGrp : fix_rg_quotentryackgrp -} -;; - -type fix_rg_quotsetackgrp = fix_rg_inner_quotsetackgrp list -;; - -type fix_rg_inner_quotsetgrp = { - f_QuotSetGrp_NoQuoteSets : int option; - f_QuotSetGrp_QuoteSetID : string option; - f_QuotSetGrp_UnderlyingInstrument : fix_underlyinginstrument; - f_QuotSetGrp_QuoteSetValidUntilTime : fix_utctimestamp_milli option; - f_QuotSetGrp_TotNoQuoteEntries : int option; - f_QuotSetGrp_LastFragment : fix_lastfragment option; - f_QuotSetGrp_QuotEntryGrp : fix_rg_quotentrygrp -} -;; - -type fix_rg_quotsetgrp = fix_rg_inner_quotsetgrp list -;; - -type fix_rg_inner_settlinstgrp = { - f_SettlInstGrp_NoSettlInst : int option; - f_SettlInstGrp_SettlInstID : string option; - f_SettlInstGrp_SettlInstTransType : fix_settlinsttranstype option; - f_SettlInstGrp_SettlInstRefID : string option; - f_SettlInstGrp_Parties : fix_rg_parties; - f_SettlInstGrp_Side : fix_side option; - f_SettlInstGrp_Product : fix_product option; - f_SettlInstGrp_SecurityType : fix_securitytype option; - f_SettlInstGrp_CFICode : string option; - f_SettlInstGrp_EffectiveTime : fix_utctimestamp_milli option; - f_SettlInstGrp_ExpireTime : fix_utctimestamp_milli option; - f_SettlInstGrp_LastUpdateTime : fix_utctimestamp_milli option; - f_SettlInstGrp_SettlInstructionsData : fix_settlinstructionsdata; - f_SettlInstGrp_PaymentMethod : fix_paymentmethod option; - f_SettlInstGrp_PaymentRef : string option; - f_SettlInstGrp_CardHolderName : string option; - f_SettlInstGrp_CardNumber : string option; - f_SettlInstGrp_CardStartDate : fix_localmktdate option; - f_SettlInstGrp_CardExpDate : fix_localmktdate option; - f_SettlInstGrp_CardIssNum : string option; - f_SettlInstGrp_PaymentDate : fix_localmktdate option; - f_SettlInstGrp_PaymentRemitterID : string option -} -;; - -type fix_rg_settlinstgrp = fix_rg_inner_settlinstgrp list -;; - -type fix_rg_inner_allocgrp = { - f_AllocGrp_NoAllocs : int option; - f_AllocGrp_AllocAccount : string option; - f_AllocGrp_AllocAcctIDSource : int option; - f_AllocGrp_MatchStatus : fix_matchstatus option; - f_AllocGrp_AllocPrice : fix_float_6 option; - f_AllocGrp_AllocQty : fix_float_6 option; - f_AllocGrp_IndividualAllocID : string option; - f_AllocGrp_ProcessCode : fix_processcode option; - f_AllocGrp_NestedParties : fix_rg_nestedparties; - f_AllocGrp_NotifyBrokerOfCredit : fix_notifybrokerofcredit option; - f_AllocGrp_AllocHandlInst : fix_allochandlinst option; - f_AllocGrp_AllocText : string option; - f_AllocGrp_EncodedAllocTextLen : int option; - f_AllocGrp_EncodedAllocText : string option; - f_AllocGrp_CommissionData : fix_commissiondata; - f_AllocGrp_AllocAvgPx : fix_float_6 option; - f_AllocGrp_AllocNetMoney : fix_float_6 option; - f_AllocGrp_SettlCurrAmt : fix_float_6 option; - f_AllocGrp_AllocSettlCurrAmt : fix_float_6 option; - f_AllocGrp_SettlCurrency : fix_currency option; - f_AllocGrp_AllocSettlCurrency : fix_currency option; - f_AllocGrp_SettlCurrFxRate : fix_float option; - f_AllocGrp_SettlCurrFxRateCalc : fix_settlcurrfxratecalc option; - f_AllocGrp_AllocAccruedInterestAmt : fix_float_6 option; - f_AllocGrp_AllocInterestAtMaturity : fix_float_6 option; - f_AllocGrp_MiscFeesGrp : fix_rg_miscfeesgrp; - f_AllocGrp_ClrInstGrp : fix_rg_clrinstgrp; - f_AllocGrp_AllocSettlInstType : fix_allocsettlinsttype option; - f_AllocGrp_SettlInstructionsData : fix_settlinstructionsdata -} -;; - -type fix_rg_allocgrp = fix_rg_inner_allocgrp list -;; - type full_fix_app_record_data = - | FIX_Record_LogonMsgTypes of fix_rg_logonmsgtypes - | FIX_Record_MDReqGrp of fix_rg_mdreqgrp - | FIX_Record_UnderlyingStipulations of fix_rg_underlyingstipulations - | FIX_Record_EvntGrp of fix_rg_evntgrp - | FIX_Record_MDFullGrp of fix_rg_mdfullgrp - | FIX_Record_UndSecAltIDGrp of fix_rg_undsecaltidgrp - | FIX_Record_LinesOfTextGrp of fix_rg_linesoftextgrp - | FIX_Record_LegSecAltIDGrp of fix_rg_legsecaltidgrp - | FIX_Record_SpreadOrBenchmarkCurveData of fix_spreadorbenchmarkcurvedata - | FIX_Record_MiscFeesGrp of fix_rg_miscfeesgrp - | FIX_Record_TrdgSesGrp of fix_rg_trdgsesgrp - | FIX_Record_ContraGrp of fix_rg_contragrp - | FIX_Record_BidCompReqGrp of fix_rg_bidcompreqgrp - | FIX_Record_ContAmtGrp of fix_rg_contamtgrp - | FIX_Record_CollInqQualGrp of fix_rg_collinqqualgrp - | FIX_Record_ExecsGrp of fix_rg_execsgrp - | FIX_Record_AllocAckGrp of fix_rg_allocackgrp - | FIX_Record_DiscretionInstructions of fix_discretioninstructions - | FIX_Record_PositionAmountData of fix_rg_positionamountdata - | FIX_Record_MDRjctGrp of fix_rg_mdrjctgrp - | FIX_Record_AttrbGrp of fix_rg_attrbgrp - | FIX_Record_TrdRegTimestamps of fix_rg_trdregtimestamps - | FIX_Record_RoutingGrp of fix_rg_routinggrp - | FIX_Record_CpctyConfGrp of fix_rg_cpctyconfgrp - | FIX_Record_YieldData of fix_yielddata - | FIX_Record_CompIDStatGrp of fix_rg_compidstatgrp - | FIX_Record_NstdPtys3SubGrp of fix_rg_nstdptys3subgrp - | FIX_Record_ClrInstGrp of fix_rg_clrinstgrp - | FIX_Record_NstdPtys2SubGrp of fix_rg_nstdptys2subgrp - | FIX_Record_AffectedOrdGrp of fix_rg_affectedordgrp - | FIX_Record_FinancingDetails of fix_financingdetails - | FIX_Record_TrdCapDtGrp of fix_rg_trdcapdtgrp | FIX_Record_OrderQtyData of fix_orderqtydata - | FIX_Record_TrdCollGrp of fix_rg_trdcollgrp - | FIX_Record_PegInstructions of fix_peginstructions - | FIX_Record_interval of fix_interval - | FIX_Record_RgstDistInstGrp of fix_rg_rgstdistinstgrp - | FIX_Record_ExecCollGrp of fix_rg_execcollgrp - | FIX_Record_CompIDReqGrp of fix_rg_compidreqgrp - | FIX_Record_NstdPtysSubGrp of fix_rg_nstdptyssubgrp - | FIX_Record_Stipulations of fix_rg_stipulations - | FIX_Record_IOIQualGrp of fix_rg_ioiqualgrp - | FIX_Record_LegBenchmarkCurveData of fix_legbenchmarkcurvedata - | FIX_Record_ExecAllocGrp of fix_rg_execallocgrp - | FIX_Record_CommissionData of fix_commissiondata | FIX_Record_PtysSubGrp of fix_rg_ptyssubgrp - | FIX_Record_SettlPtysSubGrp of fix_rg_settlptyssubgrp - | FIX_Record_SecTypesGrp of fix_rg_sectypesgrp - | FIX_Record_QuotQualGrp of fix_rg_quotqualgrp - | FIX_Record_BidDescReqGrp of fix_rg_biddescreqgrp - | FIX_Record_SecAltIDGrp of fix_rg_secaltidgrp - | FIX_Record_OrdListStatGrp of fix_rg_ordliststatgrp - | FIX_Record_LegStipulations of fix_rg_legstipulations - | FIX_Record_SettlParties of fix_rg_settlparties | FIX_Record_Parties of fix_rg_parties - | FIX_Record_BidCompRspGrp of fix_rg_bidcomprspgrp - | FIX_Record_NestedParties of fix_rg_nestedparties - | FIX_Record_NestedParties2 of fix_rg_nestedparties2 - | FIX_Record_NestedParties3 of fix_rg_nestedparties3 - | FIX_Record_InstrumentExtension of fix_instrumentextension - | FIX_Record_InstrumentLeg of fix_instrumentleg - | FIX_Record_Instrument of fix_instrument - | FIX_Record_UnderlyingInstrument of fix_underlyinginstrument - | FIX_Record_UndInstrmtCollGrp of fix_rg_undinstrmtcollgrp - | FIX_Record_PosUndInstrmtGrp of fix_rg_posundinstrmtgrp - | FIX_Record_UndInstrmtGrp of fix_rg_undinstrmtgrp - | FIX_Record_UndInstrmtStrkPxGrp of fix_rg_undinstrmtstrkpxgrp - | FIX_Record_InstrmtGrp of fix_rg_instrmtgrp - | FIX_Record_InstrmtStrkPxGrp of fix_rg_instrmtstrkpxgrp - | FIX_Record_InstrmtLegSecListGrp of fix_rg_instrmtlegseclistgrp - | FIX_Record_InstrmtLegGrp of fix_rg_instrmtleggrp - | FIX_Record_InstrmtLegIOIGrp of fix_rg_instrmtlegioigrp - | FIX_Record_PreAllocMlegGrp of fix_rg_preallocmleggrp - | FIX_Record_TrdAllocGrp of fix_rg_trdallocgrp - | FIX_Record_LegPreAllocGrp of fix_rg_legpreallocgrp - | FIX_Record_OrdAllocGrp of fix_rg_ordallocgrp - | FIX_Record_LegQuotStatGrp of fix_rg_legquotstatgrp - | FIX_Record_PreAllocGrp of fix_rg_preallocgrp - | FIX_Record_RgstDtlsGrp of fix_rg_rgstdtlsgrp - | FIX_Record_InstrmtLegExecGrp of fix_rg_instrmtlegexecgrp - | FIX_Record_LegQuotGrp of fix_rg_legquotgrp - | FIX_Record_QuotReqLegsGrp of fix_rg_quotreqlegsgrp - | FIX_Record_PositionQty of fix_rg_positionqty - | FIX_Record_TrdInstrmtLegGrp of fix_rg_trdinstrmtleggrp - | FIX_Record_SideCrossOrdCxlGrp of fix_rg_sidecrossordcxlgrp - | FIX_Record_DlvyInstGrp of fix_rg_dlvyinstgrp - | FIX_Record_SettlInstructionsData of fix_settlinstructionsdata - | FIX_Record_SideCrossOrdModGrp of fix_rg_sidecrossordmodgrp - | FIX_Record_LegOrdGrp of fix_rg_legordgrp - | FIX_Record_TrdCapRptSideGrp of fix_rg_trdcaprptsidegrp - | FIX_Record_RelSymDerivSecGrp of fix_rg_relsymderivsecgrp - | FIX_Record_QuotEntryGrp of fix_rg_quotentrygrp - | FIX_Record_QuotEntryAckGrp of fix_rg_quotentryackgrp - | FIX_Record_ListOrdGrp of fix_rg_listordgrp - | FIX_Record_QuotReqRjctGrp of fix_rg_quotreqrjctgrp - | FIX_Record_RFQReqGrp of fix_rg_rfqreqgrp - | FIX_Record_InstrmtMDReqGrp of fix_rg_instrmtmdreqgrp - | FIX_Record_MDIncGrp of fix_rg_mdincgrp - | FIX_Record_SecListGrp of fix_rg_seclistgrp - | FIX_Record_QuotReqGrp of fix_rg_quotreqgrp - | FIX_Record_QuotCxlEntriesGrp of fix_rg_quotcxlentriesgrp - | FIX_Record_QuotSetAckGrp of fix_rg_quotsetackgrp - | FIX_Record_QuotSetGrp of fix_rg_quotsetgrp - | FIX_Record_SettlInstGrp of fix_rg_settlinstgrp - | FIX_Record_AllocGrp of fix_rg_allocgrp ;; + diff --git a/src-protocol-exts/full_app_tags.iml b/src-protocol-exts/full_app_tags.iml index 2045711c..b669148a 100644 --- a/src-protocol-exts/full_app_tags.iml +++ b/src-protocol-exts/full_app_tags.iml @@ -1,382 +1,28 @@ -(* Imandra Inc. copyright 2019 *) +(* Imandra Inc. copyright 2021 *) + type full_app_msg_tag = - | Full_Msg_ExecutionReport_Tag | Full_Msg_NewOrderSingle_Tag + | Full_Msg_ExecutionReport_Tag ;; type full_app_field_tag = - | Full_Field_OrderID_Tag - | Full_Field_SecondaryOrderID_Tag - | Full_Field_SecondaryClOrdID_Tag - | Full_Field_SecondaryExecID_Tag | Full_Field_ClOrdID_Tag - | Full_Field_OrigClOrdID_Tag - | Full_Field_ClOrdLinkID_Tag - | Full_Field_QuoteRespID_Tag - | Full_Field_OrdStatusReqID_Tag - | Full_Field_MassStatusReqID_Tag - | Full_Field_TotNumReports_Tag - | Full_Field_LastRptRequested_Tag - | Full_Field_TradeOriginationDate_Tag - | Full_Field_ListID_Tag - | Full_Field_CrossID_Tag - | Full_Field_OrigCrossID_Tag - | Full_Field_CrossType_Tag - | Full_Field_ExecID_Tag - | Full_Field_ExecRefID_Tag - | Full_Field_ExecType_Tag - | Full_Field_OrdStatus_Tag - | Full_Field_WorkingIndicator_Tag - | Full_Field_OrdRejReason_Tag - | Full_Field_ExecRestatementReason_Tag + | Full_Field_Parties_Tag | Full_Field_Account_Tag - | Full_Field_AcctIDSource_Tag - | Full_Field_AccountType_Tag - | Full_Field_DayBookingInst_Tag - | Full_Field_BookingUnit_Tag - | Full_Field_PreallocMethod_Tag - | Full_Field_SettlType_Tag - | Full_Field_SettlDate_Tag - | Full_Field_CashMargin_Tag - | Full_Field_ClearingFeeIndicator_Tag + | Full_Field_ExecInst_Tag | Full_Field_Side_Tag - | Full_Field_QtyType_Tag + | Full_Field_TransactTime_Tag + | Full_Field_OrderQtyData_Tag | Full_Field_OrdType_Tag - | Full_Field_PriceType_Tag | Full_Field_Price_Tag - | Full_Field_StopPx_Tag - | Full_Field_PeggedPrice_Tag - | Full_Field_DiscretionPrice_Tag - | Full_Field_TargetStrategy_Tag - | Full_Field_TargetStrategyParameters_Tag - | Full_Field_ParticipationRate_Tag - | Full_Field_TargetStrategyPerformance_Tag - | Full_Field_Currency_Tag - | Full_Field_ComplianceID_Tag - | Full_Field_SolicitedFlag_Tag - | Full_Field_TimeInForce_Tag - | Full_Field_EffectiveTime_Tag - | Full_Field_ExpireDate_Tag - | Full_Field_ExpireTime_Tag - | Full_Field_ExecInst_Tag - | Full_Field_OrderCapacity_Tag - | Full_Field_OrderRestrictions_Tag - | Full_Field_CustOrderCapacity_Tag - | Full_Field_LastQty_Tag - | Full_Field_UnderlyingLastQty_Tag - | Full_Field_LastPx_Tag - | Full_Field_UnderlyingLastPx_Tag - | Full_Field_LastParPx_Tag - | Full_Field_LastSpotRate_Tag - | Full_Field_LastForwardPoints_Tag - | Full_Field_LastMkt_Tag - | Full_Field_TradingSessionID_Tag - | Full_Field_TradingSessionSubID_Tag - | Full_Field_TimeBracket_Tag - | Full_Field_LastCapacity_Tag + | Full_Field_SpreadProportion_Tag + | Full_Field_OrderID_Tag + | Full_Field_ExecID_Tag + | Full_Field_ExecType_Tag + | Full_Field_OrdStatus_Tag | Full_Field_LeavesQty_Tag | Full_Field_CumQty_Tag - | Full_Field_AvgPx_Tag - | Full_Field_DayOrderQty_Tag - | Full_Field_DayCumQty_Tag - | Full_Field_DayAvgPx_Tag - | Full_Field_GTBookingInst_Tag - | Full_Field_TradeDate_Tag - | Full_Field_TransactTime_Tag - | Full_Field_ReportToExch_Tag - | Full_Field_GrossTradeAmt_Tag - | Full_Field_NumDaysInterest_Tag - | Full_Field_ExDate_Tag - | Full_Field_AccruedInterestRate_Tag - | Full_Field_AccruedInterestAmt_Tag - | Full_Field_InterestAtMaturity_Tag - | Full_Field_EndAccruedInterestAmt_Tag - | Full_Field_StartCash_Tag - | Full_Field_EndCash_Tag - | Full_Field_TradedFlatSwitch_Tag - | Full_Field_BasisFeatureDate_Tag - | Full_Field_BasisFeaturePrice_Tag - | Full_Field_Concession_Tag - | Full_Field_TotalTakedown_Tag - | Full_Field_NetMoney_Tag - | Full_Field_SettlCurrAmt_Tag - | Full_Field_SettlCurrency_Tag - | Full_Field_SettlCurrFxRate_Tag - | Full_Field_SettlCurrFxRateCalc_Tag - | Full_Field_HandlInst_Tag - | Full_Field_MinQty_Tag - | Full_Field_MaxFloor_Tag - | Full_Field_PositionEffect_Tag - | Full_Field_MaxShow_Tag - | Full_Field_BookingType_Tag | Full_Field_Text_Tag - | Full_Field_EncodedTextLen_Tag - | Full_Field_EncodedText_Tag - | Full_Field_SettlDate2_Tag - | Full_Field_OrderQty2_Tag - | Full_Field_LastForwardPoints2_Tag - | Full_Field_MultiLegReportingType_Tag - | Full_Field_CancellationRights_Tag - | Full_Field_MoneyLaunderingStatus_Tag - | Full_Field_RegistID_Tag - | Full_Field_Designation_Tag - | Full_Field_TransBkdTime_Tag - | Full_Field_ExecValuationPoint_Tag - | Full_Field_ExecPriceType_Tag - | Full_Field_ExecPriceAdjustment_Tag - | Full_Field_PriorityIndicator_Tag - | Full_Field_PriceImprovement_Tag - | Full_Field_LastLiquidityInd_Tag - | Full_Field_CopyMsgIndicator_Tag - | Full_Field_NoPartyIDs_Tag - | Full_Field_PartyID_Tag - | Full_Field_PartyIDSource_Tag - | Full_Field_PartyRole_Tag - | Full_Field_NoPartySubIDs_Tag - | Full_Field_PartySubID_Tag - | Full_Field_PartySubIDType_Tag - | Full_Field_NoContraBrokers_Tag - | Full_Field_ContraBroker_Tag - | Full_Field_ContraTrader_Tag - | Full_Field_ContraTradeQty_Tag - | Full_Field_ContraTradeTime_Tag - | Full_Field_ContraLegRefID_Tag - | Full_Field_Symbol_Tag - | Full_Field_SymbolSfx_Tag - | Full_Field_SecurityID_Tag - | Full_Field_SecurityIDSource_Tag - | Full_Field_Product_Tag - | Full_Field_CFICode_Tag - | Full_Field_SecurityType_Tag - | Full_Field_SecuritySubType_Tag - | Full_Field_MaturityMonthYear_Tag - | Full_Field_MaturityDate_Tag - | Full_Field_CouponPaymentDate_Tag - | Full_Field_IssueDate_Tag - | Full_Field_RepoCollateralSecurityType_Tag - | Full_Field_RepurchaseTerm_Tag - | Full_Field_RepurchaseRate_Tag - | Full_Field_Factor_Tag - | Full_Field_CreditRating_Tag - | Full_Field_InstrRegistry_Tag - | Full_Field_CountryOfIssue_Tag - | Full_Field_StateOrProvinceOfIssue_Tag - | Full_Field_LocaleOfIssue_Tag - | Full_Field_RedemptionDate_Tag - | Full_Field_StrikePrice_Tag - | Full_Field_StrikeCurrency_Tag - | Full_Field_OptAttribute_Tag - | Full_Field_ContractMultiplier_Tag - | Full_Field_CouponRate_Tag - | Full_Field_SecurityExchange_Tag - | Full_Field_Issuer_Tag - | Full_Field_EncodedIssuerLen_Tag - | Full_Field_EncodedIssuer_Tag - | Full_Field_SecurityDesc_Tag - | Full_Field_EncodedSecurityDescLen_Tag - | Full_Field_EncodedSecurityDesc_Tag - | Full_Field_Pool_Tag - | Full_Field_ContractSettlMonth_Tag - | Full_Field_CPProgram_Tag - | Full_Field_CPRegType_Tag - | Full_Field_DatedDate_Tag - | Full_Field_InterestAccrualDate_Tag - | Full_Field_NoSecurityAltID_Tag - | Full_Field_SecurityAltID_Tag - | Full_Field_SecurityAltIDSource_Tag - | Full_Field_NoEvents_Tag - | Full_Field_EventType_Tag - | Full_Field_EventDate_Tag - | Full_Field_EventPx_Tag - | Full_Field_EventText_Tag - | Full_Field_AgreementDesc_Tag - | Full_Field_AgreementID_Tag - | Full_Field_AgreementDate_Tag - | Full_Field_AgreementCurrency_Tag - | Full_Field_TerminationType_Tag - | Full_Field_StartDate_Tag - | Full_Field_EndDate_Tag - | Full_Field_DeliveryType_Tag - | Full_Field_MarginRatio_Tag - | Full_Field_NoUnderlyings_Tag - | Full_Field_UnderlyingSymbol_Tag - | Full_Field_UnderlyingSymbolSfx_Tag - | Full_Field_UnderlyingSecurityID_Tag - | Full_Field_UnderlyingSecurityIDSource_Tag - | Full_Field_UnderlyingProduct_Tag - | Full_Field_UnderlyingCFICode_Tag - | Full_Field_UnderlyingSecurityType_Tag - | Full_Field_UnderlyingSecuritySubType_Tag - | Full_Field_UnderlyingMaturityMonthYear_Tag - | Full_Field_UnderlyingMaturityDate_Tag - | Full_Field_UnderlyingCouponPaymentDate_Tag - | Full_Field_UnderlyingIssueDate_Tag - | Full_Field_UnderlyingRepoCollateralSecurityType_Tag - | Full_Field_UnderlyingRepurchaseTerm_Tag - | Full_Field_UnderlyingRepurchaseRate_Tag - | Full_Field_UnderlyingFactor_Tag - | Full_Field_UnderlyingCreditRating_Tag - | Full_Field_UnderlyingInstrRegistry_Tag - | Full_Field_UnderlyingCountryOfIssue_Tag - | Full_Field_UnderlyingStateOrProvinceOfIssue_Tag - | Full_Field_UnderlyingLocaleOfIssue_Tag - | Full_Field_UnderlyingRedemptionDate_Tag - | Full_Field_UnderlyingStrikePrice_Tag - | Full_Field_UnderlyingStrikeCurrency_Tag - | Full_Field_UnderlyingOptAttribute_Tag - | Full_Field_UnderlyingContractMultiplier_Tag - | Full_Field_UnderlyingCouponRate_Tag - | Full_Field_UnderlyingSecurityExchange_Tag - | Full_Field_UnderlyingIssuer_Tag - | Full_Field_EncodedUnderlyingIssuerLen_Tag - | Full_Field_EncodedUnderlyingIssuer_Tag - | Full_Field_UnderlyingSecurityDesc_Tag - | Full_Field_EncodedUnderlyingSecurityDescLen_Tag - | Full_Field_EncodedUnderlyingSecurityDesc_Tag - | Full_Field_UnderlyingCPProgram_Tag - | Full_Field_UnderlyingCPRegType_Tag - | Full_Field_UnderlyingCurrency_Tag - | Full_Field_UnderlyingQty_Tag - | Full_Field_UnderlyingPx_Tag - | Full_Field_UnderlyingDirtyPrice_Tag - | Full_Field_UnderlyingEndPrice_Tag - | Full_Field_UnderlyingStartValue_Tag - | Full_Field_UnderlyingCurrentValue_Tag - | Full_Field_UnderlyingEndValue_Tag - | Full_Field_NoUnderlyingSecurityAltID_Tag - | Full_Field_UnderlyingSecurityAltID_Tag - | Full_Field_UnderlyingSecurityAltIDSource_Tag - | Full_Field_NoUnderlyingStips_Tag - | Full_Field_UnderlyingStipType_Tag - | Full_Field_UnderlyingStipValue_Tag - | Full_Field_NoStipulations_Tag - | Full_Field_StipulationType_Tag - | Full_Field_StipulationValue_Tag - | Full_Field_OrderQty_Tag - | Full_Field_CashOrderQty_Tag - | Full_Field_OrderPercent_Tag - | Full_Field_RoundingDirection_Tag - | Full_Field_RoundingModulus_Tag - | Full_Field_PegOffsetValue_Tag - | Full_Field_PegMoveType_Tag - | Full_Field_PegOffsetType_Tag - | Full_Field_PegLimitType_Tag - | Full_Field_PegRoundDirection_Tag - | Full_Field_PegScope_Tag - | Full_Field_DiscretionInst_Tag - | Full_Field_DiscretionOffsetValue_Tag - | Full_Field_DiscretionMoveType_Tag - | Full_Field_DiscretionOffsetType_Tag - | Full_Field_DiscretionLimitType_Tag - | Full_Field_DiscretionRoundDirection_Tag - | Full_Field_DiscretionScope_Tag - | Full_Field_Commission_Tag - | Full_Field_CommType_Tag - | Full_Field_CommCurrency_Tag - | Full_Field_FundRenewWaiv_Tag - | Full_Field_Spread_Tag - | Full_Field_BenchmarkCurveCurrency_Tag - | Full_Field_BenchmarkCurveName_Tag - | Full_Field_BenchmarkCurvePoint_Tag - | Full_Field_BenchmarkPrice_Tag - | Full_Field_BenchmarkPriceType_Tag - | Full_Field_BenchmarkSecurityID_Tag - | Full_Field_BenchmarkSecurityIDSource_Tag - | Full_Field_YieldType_Tag - | Full_Field_Yield_Tag - | Full_Field_YieldCalcDate_Tag - | Full_Field_YieldRedemptionDate_Tag - | Full_Field_YieldRedemptionPrice_Tag - | Full_Field_YieldRedemptionPriceType_Tag - | Full_Field_NoContAmts_Tag - | Full_Field_ContAmtType_Tag - | Full_Field_ContAmtValue_Tag - | Full_Field_ContAmtCurr_Tag - | Full_Field_NoLegs_Tag - | Full_Field_LegQty_Tag - | Full_Field_LegSwapType_Tag - | Full_Field_LegPositionEffect_Tag - | Full_Field_LegCoveredOrUncovered_Tag - | Full_Field_LegRefID_Tag - | Full_Field_LegPrice_Tag - | Full_Field_LegSettlType_Tag - | Full_Field_LegSettlDate_Tag - | Full_Field_LegLastPx_Tag - | Full_Field_LegSymbol_Tag - | Full_Field_LegSymbolSfx_Tag - | Full_Field_LegSecurityID_Tag - | Full_Field_LegSecurityIDSource_Tag - | Full_Field_LegProduct_Tag - | Full_Field_LegCFICode_Tag - | Full_Field_LegSecurityType_Tag - | Full_Field_LegSecuritySubType_Tag - | Full_Field_LegMaturityMonthYear_Tag - | Full_Field_LegMaturityDate_Tag - | Full_Field_LegCouponPaymentDate_Tag - | Full_Field_LegIssueDate_Tag - | Full_Field_LegRepoCollateralSecurityType_Tag - | Full_Field_LegRepurchaseTerm_Tag - | Full_Field_LegRepurchaseRate_Tag - | Full_Field_LegFactor_Tag - | Full_Field_LegCreditRating_Tag - | Full_Field_LegInstrRegistry_Tag - | Full_Field_LegCountryOfIssue_Tag - | Full_Field_LegStateOrProvinceOfIssue_Tag - | Full_Field_LegLocaleOfIssue_Tag - | Full_Field_LegRedemptionDate_Tag - | Full_Field_LegStrikePrice_Tag - | Full_Field_LegStrikeCurrency_Tag - | Full_Field_LegOptAttribute_Tag - | Full_Field_LegContractMultiplier_Tag - | Full_Field_LegCouponRate_Tag - | Full_Field_LegSecurityExchange_Tag - | Full_Field_LegIssuer_Tag - | Full_Field_EncodedLegIssuerLen_Tag - | Full_Field_EncodedLegIssuer_Tag - | Full_Field_LegSecurityDesc_Tag - | Full_Field_EncodedLegSecurityDescLen_Tag - | Full_Field_EncodedLegSecurityDesc_Tag - | Full_Field_LegRatioQty_Tag - | Full_Field_LegSide_Tag - | Full_Field_LegCurrency_Tag - | Full_Field_LegPool_Tag - | Full_Field_LegDatedDate_Tag - | Full_Field_LegContractSettlMonth_Tag - | Full_Field_LegInterestAccrualDate_Tag - | Full_Field_NoLegSecurityAltID_Tag - | Full_Field_LegSecurityAltID_Tag - | Full_Field_LegSecurityAltIDSource_Tag - | Full_Field_NoLegStipulations_Tag - | Full_Field_LegStipulationType_Tag - | Full_Field_LegStipulationValue_Tag - | Full_Field_NoNestedPartyIDs_Tag - | Full_Field_NestedPartyID_Tag - | Full_Field_NestedPartyIDSource_Tag - | Full_Field_NestedPartyRole_Tag - | Full_Field_NoNestedPartySubIDs_Tag - | Full_Field_NestedPartySubID_Tag - | Full_Field_NestedPartySubIDType_Tag - | Full_Field_NoMiscFees_Tag - | Full_Field_MiscFeeAmt_Tag - | Full_Field_MiscFeeCurr_Tag - | Full_Field_MiscFeeType_Tag - | Full_Field_MiscFeeBasis_Tag - | Full_Field_AllocID_Tag - | Full_Field_ExDestination_Tag - | Full_Field_ProcessCode_Tag - | Full_Field_PrevClosePx_Tag - | Full_Field_LocateReqd_Tag - | Full_Field_IOIID_Tag - | Full_Field_QuoteID_Tag - | Full_Field_ForexReq_Tag - | Full_Field_Price2_Tag - | Full_Field_CoveredOrUncovered_Tag - | Full_Field_NoAllocs_Tag - | Full_Field_AllocAccount_Tag - | Full_Field_AllocAcctIDSource_Tag - | Full_Field_AllocSettlCurrency_Tag - | Full_Field_IndividualAllocID_Tag - | Full_Field_AllocQty_Tag - | Full_Field_NoTradingSessions_Tag ;; + diff --git a/src-protocol-pp/full_admin_messages_decoder.iml b/src-protocol-pp/full_admin_messages_decoder.iml index c7ec27a1..13250056 100644 --- a/src-protocol-pp/full_admin_messages_decoder.iml +++ b/src-protocol-pp/full_admin_messages_decoder.iml @@ -8,8 +8,8 @@ open Datetime_json;; open Full_admin_enums_decoder;; [@@@import "../src-protocol/full_admin_messages.iml"] open Full_admin_messages;; -[@@@import "../src-protocol-exts-pp/full_app_tags_decoder.iml"] -open Full_app_tags_decoder;; +[@@@import "full_message_tags_decoder.iml"] +open Full_message_tags_decoder;; module D = Decoders_yojson.Basic.Decode;; @@ -22,111 +22,88 @@ let full_msg_heartbeat_decoder : full_msg_heartbeat_data D.decoder = let full_msg_types_inner_rg_decoder : full_msg_types_inner_rg D.decoder = let open D in - field "mtps_ref_msg_type" full_app_msg_tag_of_json >>= fun mtps_ref_msg_type -> + field "mtps_ref_msg_type" full_msg_tag_of_json >>= fun mtps_ref_msg_type -> field "mtps_direction" full_admin_enum_fix_msgdirection_decoder >>= fun mtps_direction -> D.succeed {mtps_ref_msg_type;mtps_direction} ;; - - -(* -(** Repeating group for supported messages passed in Logon *) -type full_msg_types_inner_rg = { - mtps_ref_msg_type : full_msg_tag; (** Tag 372: Specifies a specific, supported MsgType <35>. *) - mtps_direction : fix_msgdirection (** Tag 385: Indicates direction (send vs. receive) from the point of view of the sender. *) -} -;; - -(** Logon message data. *) -type full_msg_logon_data = { - ln_encrypt_method : fix_encryption_method; (** Tag 98 *) - ln_heartbeat_interval : fix_duration; (** Tag 108 *) - ln_raw_data_length : int option; (** Tag 95 *) - ln_raw_data : string option; (** Tag 96 *) - ln_reset_seq_num_flag : bool option; (** Tag 141 *) - ln_next_expected_msg_seq_num : int option; (** Tag 789 *) - ln_max_message_size : int option; (** Tag 383 *) - - ln_test_message_indicator : bool option; (** Tag 464 *) - ln_username : string option; (** Tag 553 *) - ln_password : string option; (** Tag 554 *) - - ln_msg_types : full_msg_types_inner_rg list (** Repeating group at tag 384 *) -} -;; - -(** Logoff message data. *) -type full_msg_logoff_data = { - lo_encoded_text_len : int option; (** Tag 354 *) - lo_encoded_text : string option; (** Tag 355 *) -} +(* +(** *) +let full_msg_logon_to_json x = + [ ( "EncryptMethod" , encryption_method_to_json x.ln_encrypt_method ) + ; ( "HeartBtInt" , duration_to_json x.ln_heartbeat_interval ) + ; ( "RawDataLength" , int_opt_to_json x.ln_raw_data_length ) + ; ( "RawData" , string_opt_to_json x.ln_raw_data ) + ; ( "ResetSeqNumFlag" , bool_opt_to_json x.ln_reset_seq_num_flag ) + ; ( "NextExpectedMsgSeqNum", int_opt_to_json x.ln_next_expected_msg_seq_num ) + ; ( "MaxMessageSize" , int_opt_to_json x.ln_max_message_size ) + ; ( "TestMessageIndicator" , bool_opt_to_json x.ln_test_message_indicator ) + ; ( "Username" , string_opt_to_json x.ln_username ) + ; ( "Password" , string_opt_to_json x.ln_password ) + ; ( "MsgTypes" , rg msg_type_to_json x.ln_msg_types ) + ] |> assoc_filter_nulls ;; -(** Resend Request message data. *) -type full_msg_resend_request_data = { - rr_begin_seq_num : int; (** Tag 7 *) - rr_end_seq_num : int; (** Tag 16 *) -} +(** *) +let full_msg_logoff_to_json x = + [ ( "EncodedText" , int_opt_to_json x.lo_encoded_text_len ) + ; ( "EncodedTextLen" , string_opt_to_json x.lo_encoded_text ) + ] |> assoc_filter_nulls ;; -(** Reject message data. *) -type full_msg_reject_data = { - sr_ref_seq_num : int; (** Tag 45. MsgSeqNum of rejected message. *) - sr_ref_tag_id : full_field_tag option; (** Tag 371. The tag number of the FIX field being referenced.*) - sr_ref_msg_type : full_msg_tag option; (** Tag 372. The MsgType of the FIX message being referenced.*) - sr_session_reject_reason : fix_session_reject_reason option; (** Tag 373. Code to identify reason for a session-level Reject <3> message.*) - sr_text : string option; (** Tag 58. Where possible, message to explain reason for rejection.*) - sr_encoded_text_len : int option; (** Tag 354. Encoded text length. *) - sr_encoded_text : string option; (** Tag 354. Encoded text. *) -} +(** *) +let full_msg_resend_request_to_json x = + [ ( "BeginSeqNo", int_to_json x.rr_begin_seq_num ) + ; ( "EndSeqNo" , int_to_json x.rr_end_seq_num ) + ] |> assoc_filter_nulls ;; -(** Sequence Reset message data. *) -type full_msg_sequence_reset_data = { - seqr_new_seq_no : int; (** Tag 36 *) - seqr_gap_fill_flag : fix_gapfillflag option; (** Tag 123 *) -} +(** *) +let full_msg_reject_to_json x = + [ ( "RefSeqNum" , int_to_json x.sr_ref_seq_num ) + ; ( "RefTagID" , full_field_tag_opt_to_json x.sr_ref_tag_id ) + ; ( "RefMsgType" , full_msg_tag_opt_to_json x.sr_ref_msg_type ) + ; ( "SessionRejectReason" , session_reject_reason_opt_to_json x.sr_session_reject_reason ) + ; ( "Text" , string_opt_to_json x.sr_text ) + ; ( "EncodedTextLen" , int_opt_to_json x.sr_encoded_text_len ) + ; ( "EncodedText" , string_opt_to_json x.sr_encoded_text ) + ] |> assoc_filter_nulls ;; -(** Test Request message data. *) -type full_msg_test_request_data = { - test_req_id : string; (** Tag 112 *) -} +(** *) +let full_msg_sequence_reset_to_json x = + [ ( "Sequence_Reset_GapFillFlag" , int_to_json x.seqr_new_seq_no ) + ; ( "Sequence_Reset_NewSeqNo" , gapFillFlag_opt_to_json x.seqr_gap_fill_flag ) + ] |> assoc_filter_nulls ;; -(** Business Reject message data. *) -type full_msg_business_reject_data = { - br_ref_seq_num : int; (** Tag 45. MsgSeqNum of rejected message. *) - br_ref_msg_type : full_msg_tag; (** Tag 372. The MsgType of the FIX message being referenced.*) - br_ref_field_id : full_field_tag option; (** Tag 379. The business-level field on the message being referenced.*) - br_business_reject_reason : fix_business_reject_reason; (** Tag 380. Code to identify reason for a BusinessReject message.*) - br_text : string option; (** Tag 58. Where possible, message to explain reason for rejection.*) - br_encoded_text_len : int option; (** Tag 354. Encoded text length. *) - br_encoded_text : string option; (** Tag 354. Encoded text. *) -} +(** *) +let full_msg_test_request_to_json x = + [ ( "Test_Request_TestReqID_Tag" , string_to_json x.test_req_id ) + ] |> assoc_filter_nulls ;; -(** Top-level full administrative message data type. *) -type full_admin_msg_data = - | Full_Msg_Heartbeat of full_msg_heartbeat_data - | Full_Msg_Logon of full_msg_logon_data - | Full_Msg_Logoff of full_msg_logoff_data - | Full_Msg_Reject of full_msg_reject_data - | Full_Msg_Business_Reject of full_msg_business_reject_data - | Full_Msg_Resend_Request of full_msg_resend_request_data - | Full_Msg_Sequence_Reset of full_msg_sequence_reset_data - | Full_Msg_Test_Request of full_msg_test_request_data +(** *) +let full_msg_business_reject_to_json x = + [ ( "RefSeqNum" , int_to_json x.br_ref_seq_num ) + ; ( "RefMsgType" , full_msg_tag_to_json x.br_ref_msg_type ) + ; ( "BusinessRejectRefID" , full_field_tag_opt_to_json x.br_ref_field_id ) + ; ( "BusinessRejectReason" , business_reject_reason_to_json x.br_business_reject_reason) + ; ( "Text" , string_opt_to_json x.br_text ) + ; ( "EncodedTextLen" , int_opt_to_json x.br_encoded_text_len ) + ; ( "EncodedText" , string_opt_to_json x.br_encoded_text ) + ] |> assoc_filter_nulls ;; -(** Get the message tag code, given the admin message data*) -let get_full_admin_msg_tag ( msg : full_admin_msg_data ) = - match msg with - | Full_Msg_Heartbeat _ -> Full_Msg_Heartbeat_Tag - | Full_Msg_Logon _ -> Full_Msg_Logon_Tag - | Full_Msg_Logoff _ -> Full_Msg_Logoff_Tag - | Full_Msg_Reject _ -> Full_Msg_Reject_Tag - | Full_Msg_Business_Reject _ -> Full_Msg_Business_Reject_Tag - | Full_Msg_Resend_Request _ -> Full_Msg_Resend_Request_Tag - | Full_Msg_Sequence_Reset _ -> Full_Msg_Sequence_Reset_Tag - | Full_Msg_Test_Request _ -> Full_Msg_Test_Request_Tag +(** *) +let full_admin_msg_to_json x : json = match x with + | Full_Msg_Heartbeat x -> `Assoc [ ( "Heartbeat" , full_msg_heartbeat_to_json x ) ] + | Full_Msg_Logon x -> `Assoc [ ( "Logon" , full_msg_logon_to_json x ) ] + | Full_Msg_Logoff x -> `Assoc [ ( "Logoff" , full_msg_logoff_to_json x ) ] + | Full_Msg_Reject x -> `Assoc [ ( "Reject" , full_msg_reject_to_json x ) ] + | Full_Msg_Business_Reject x -> `Assoc [ ( "Business_Reject" , full_msg_business_reject_to_json x ) ] + | Full_Msg_Resend_Request x -> `Assoc [ ( "Resend_Request" , full_msg_resend_request_to_json x ) ] + | Full_Msg_Sequence_Reset x -> `Assoc [ ( "Sequence_Reset" , full_msg_sequence_reset_to_json x ) ] + | Full_Msg_Test_Request x -> `Assoc [ ( "Test_Request" , full_msg_test_request_to_json x ) ] ;; -*) \ No newline at end of file +[@@@logic] +*) diff --git a/src-protocol-pp/full_message_tags_decoder.iml b/src-protocol-pp/full_message_tags_decoder.iml new file mode 100644 index 00000000..0a4f6d6c --- /dev/null +++ b/src-protocol-pp/full_message_tags_decoder.iml @@ -0,0 +1,42 @@ +(* Imandra Inc. copyright 2021 *) +[@@@program] +[@@@require "decoders-yojson"] +[@@@import "../src-protocol/full_message_tags.iml"] +[@@@import "full_admin_tags_decoder.iml"] +[@@@import "../src-protocol-exts-pp/full_app_messages_decoder.iml"] +[@@@import "../src-protocol-exts-pp/full_app_tags_decoder.iml"] + +open Full_admin_tags_decoder +open Full_message_tags +open Full_app_messages_decoder +open Full_app_tags_decoder + +module D = Decoders_yojson.Basic.Decode;; + +let full_msg_tag_of_json : full_msg_tag D.decoder = + let open D in + single_field @@ function + | "Full_Admin_Msg_Tag" -> + (full_admin_msg_tag_of_json >>= + fun x -> D.succeed (Full_Admin_Msg_Tag x)) + | "Full_App_Msg_Tag" -> + (full_app_msg_tag_of_json >>= + fun x -> D.succeed (Full_App_Msg_Tag x)) + | "Full_Msg_Unknown_Tag" -> string >>= fun x -> + D.succeed (Full_Msg_Unknown_Tag x) + | x -> D.fail @@ "Unknown full message tag " ^ x +;; + +let full_field_tag_to_json : full_field_tag D.decoder = + let open D in + single_field @@ function + | "Full_Admin_Field_Tag" -> + (full_admin_field_tag_of_json >>= + fun x -> D.succeed (Full_Admin_Field_Tag x)) + | "Full_App_Field_Tag" -> + (full_app_field_tag_of_json >>= + fun x -> D.succeed (Full_App_Field_Tag x)) + | "Full_Field_Unknown_Tag" -> string >>= fun x -> + D.succeed (Full_Field_Unknown_Tag x) + | x -> D.fail @@ "Unknown full message tag " ^ x +;; diff --git a/src-protocol-pp/full_message_tags_json.iml b/src-protocol-pp/full_message_tags_json.iml index 6fe1b768..75c785ee 100644 --- a/src-protocol-pp/full_message_tags_json.iml +++ b/src-protocol-pp/full_message_tags_json.iml @@ -17,9 +17,9 @@ open Full_admin_tags_json;; let full_msg_tag_to_json = function - | Full_Admin_Msg_Tag x -> full_admin_msg_tag_to_json x - | Full_App_Msg_Tag x -> full_app_msg_tag_to_json x - | Full_Msg_Unknown_Tag x -> `String x + | Full_Admin_Msg_Tag x -> `Assoc [("Full_Admin_Msg_Tag",full_admin_msg_tag_to_json x)] + | Full_App_Msg_Tag x -> `Assoc [("Full_App_Msg_Tag",full_app_msg_tag_to_json x)] + | Full_Msg_Unknown_Tag x -> `Assoc [("Full_Msg_Unknown_Tag",`String x)] ;; @@ -30,9 +30,9 @@ let full_msg_tag_opt_to_json = function let full_field_tag_to_json = function - | Full_Admin_Field_Tag x -> full_admin_field_tag_to_json x - | Full_App_Field_Tag x -> full_app_field_tag_to_json x - | Full_Field_Unknown_Tag x -> `String x + | Full_Admin_Field_Tag x -> `Assoc [("Full_Admin_Field_Tag",full_admin_field_tag_to_json x)] + | Full_App_Field_Tag x -> `Assoc [("Full_App_Field_Tag",full_app_field_tag_to_json x)] + | Full_Field_Unknown_Tag x -> `Assoc [("Full_Field_Unknown_Tag",`String x)] ;; diff --git a/vgs/templates/basis_files.iml b/vgs/templates/basis_files.iml index 0f1fa486..a897093b 100644 --- a/vgs/templates/basis_files.iml +++ b/vgs/templates/basis_files.iml @@ -1,23 +1,774 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] -[@@@import "validation_functions.iml"] -open Validation_functions;; let basis () = - (@) ("Datetime.utctimeonly_GreaterThanEqual_micro_milli" :: ("Time_defaults.utctimestamp_GreaterThanEqual" :: ("Time_defaults.utctimeonly_GreaterThanEqual" :: ("Datetime.utctimestamp_GreaterThan_milli_milli" :: ("Time_defaults.convert_utctimestamp_utcdateonly" :: ("Datetime.utctimestamp_GreaterThan_milli_micro" :: ("Time_defaults.utctimestamp_LessThanEqual" :: ("Datetime.utctimestamp_LessThanEqual_milli_milli" :: ("Datetime.convert_utctimestamp_milli_micro" :: ("Datetime.utctimeonly_LessThanEqual_milli_micro" :: ("Datetime.utctimeonly_LessThan_micro_milli" :: ("Datetime.convert_utctimestamp_micro_utctimeonly_milli" :: ("Datetime.make_duration" :: ("Datetime.utctimestamp_LessThanEqual_milli_micro" :: ("Datetime.is_valid_utctimeonly_milli" :: ("Datetime.utctimeonly_LessThan_micro_micro" :: ("Datetime.convert_utctimestamp_micro_utctimeonly_micro" :: ("Datetime.convert_utctimestamp_milli_utctimeonly_milli" :: ("Datetime.normalise_utctimeonly_milli" :: ("Datetime.utctimeonly_GreaterThan_milli_milli" :: ("Datetime.convert_utctimestamp_milli_utctimeonly_micro" :: ("Time_defaults.is_valid_utctimestamp" :: ("Datetime.normalise_utctimeonly_micro" :: ("Time_defaults.normalise_utctimestamp" :: ("Datetime.convert_utctimestamp_micro_monthyear" :: ("Datetime.convert_utctimeonly_milli_micro" :: ("Datetime.make_utctimestamp_micro" :: ("Time_defaults.utctimeonly_LessThan" :: ("Datetime.convert_utctimestamp_micro_utcdateonly" :: ("Datetime.make_utctimestamp_micro_utctimeonly_micro_utcdateonly" :: ("Datetime.make_utctimestamp_milli" :: ("Datetime.utctimestamp_micro_duration_Add" :: ("Datetime.utctimeonly_GreaterThan_milli_micro" :: ("Time_defaults.convert_utctimestamp_localmktdate" :: ("Time_defaults.make_utctimestamp" :: ("Time_defaults.utctimeonly_Equal" :: ("Datetime.utctimeonly_GreaterThan_micro_milli" :: ("Datetime.convert_utctimestamp_milli_utcdateonly" :: ("Datetime.utctimeonly_GreaterThan_micro_micro" :: ("Datetime.utctimeonly_Equal_micro_micro" :: ("Datetime.utctimestamp_Equal_milli_milli" :: ("Datetime.is_valid_utctimeonly_micro" :: ("Time_defaults.make_utctimeonly" :: ("Datetime.utctimeonly_LessThanEqual_milli_milli" :: ("Datetime.duration_utctimestamp_milli_Add" :: ("Datetime.utctimestamp_Equal_micro_milli" :: ("abs" :: ("Datetime.duration_utctimestamp_micro_Add" :: ("Datetime.utctimeonly_Equal_milli_micro" :: ("Datetime.is_valid_utctimestamp_milli" :: ("Datetime.utctimestamp_Equal_micro_micro" :: ("Datetime.utctimestamp_Equal_milli_micro" :: ("Time_defaults.is_valid_utctimeonly" :: ("Time_defaults.utctimeonly_GreaterThan" :: ("Datetime.utctimeonly_Equal_micro_milli" :: ("Datetime.convert_utctimestamp_milli_localmktdate" :: ("Datetime.utctimeonly_Equal_milli_milli" :: ("Time_defaults.make_utctimestamp_utctimeonly_utcdateonly" :: ("Datetime.utctimestamp_LessThanEqual_micro_milli" :: ("Datetime.utctimestamp_GreaterThan_micro_milli" :: ("Time_defaults.utctimestamp_Equal" :: ("Datetime.utctimeonly_LessThanEqual_micro_milli" :: ("Datetime.is_valid_utctimestamp_micro" :: ("Datetime.make_localmktdate" :: ("Datetime.normalise_utctimestamp_milli" :: ("Datetime.convert_utctimestamp_micro_milli" :: ("Datetime.make_utcdateonly" :: ("Datetime.make_utctimeonly_micro" :: ("Datetime.utctimestamp_GreaterThan_micro_micro" :: ("Datetime.make_utctimeonly_milli" :: ("Datetime.utctimeonly_LessThan_milli_micro" :: ("Datetime.normalise_utctimestamp_micro" :: ("Datetime.utctimeonly_LessThanEqual_micro_micro" :: ("Datetime.utctimestamp_LessThanEqual_micro_micro" :: ("Datetime.utctimeonly_LessThan_milli_milli" :: ("Datetime.convert_utctimeonly_micro_milli" :: ("Datetime.utctimestamp_GreaterThanEqual_micro_micro" :: ("Datetime.utctimestamp_milli_duration_Add" :: ("Time_defaults.normalise_utctimeonly" :: ("Time_defaults.utctimeonly_LessThanEqual" :: ("Time_defaults.utctimestamp_GreaterThan" :: ("Datetime.utctimestamp_LessThan_micro_milli" :: ("Time_defaults.utctimestamp_LessThan" :: ("Datetime.utctimestamp_GreaterThanEqual_milli_micro" :: ("Datetime.utctimestamp_GreaterThanEqual_milli_milli" :: ("Datetime.utctimestamp_GreaterThanEqual_micro_milli" :: ("Datetime.convert_utctimestamp_micro_localmktdate" :: ("Datetime.convert_utctimestamp_milli_monthyear" :: ("Datetime.make_monthyear" :: ("Datetime.make_utctimestamp_milli_utctimeonly_milli_utcdateonly" :: ("Datetime.utctimestamp_LessThan_milli_milli" :: ("Time_defaults.convert_utctimestamp_monthyear" :: ("Datetime.utctimeonly_GreaterThanEqual_milli_milli" :: ("Datetime.utctimeonly_GreaterThanEqual_micro_micro" :: ("Time_defaults.convert_utctimestamp_utctimeonly" :: ("Datetime.utctimestamp_LessThan_milli_micro" :: ("Datetime.utctimeonly_GreaterThanEqual_milli_micro" :: ("Datetime.utctimestamp_LessThan_micro_micro" :: [])))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) (List.map (fun x -> fst x - ) validation_functions) - [@@macro] + [("Msg_check_fields.check_field_mod_f_NewOrderSingle_ClOrdID"); + ("Msg_minimal_invalid.check_fields_minimal_invalid_NewOrderSingle_0"); + ("Msg_check_fields.check_field_mod_f_NewOrderSingle_OrdType"); + ("Msg_minimal_invalid.check_fields_minimal_invalid_NewOrderSingle_3"); + ("Msg_check_fields.check_field_mod_f_NewOrderSingle_SpreadProportion"); + ("Msg_minimal_invalid.check_fields_minimal_invalid_NewOrderSingle_5"); + ("Msg_check_fields.check_field_mod_f_NewOrderSingle_Parties"); + ("Msg_minimal_invalid.check_fields_minimal_invalid_NewOrderSingle_9"); + ("Msg_check_validate.validate_NewOrderSingle_0"); + ("Msg_minimal_invalid.check_validate_minimal_invalid_NewOrderSingle_0"); + ("Msg_check_validate.validate_NewOrderSingle_1"); + ("Msg_minimal_invalid.check_validate_minimal_invalid_NewOrderSingle_1"); + ("Msg_check_validate.validate_NewOrderSingle_2"); + ("Msg_minimal_invalid.check_validate_minimal_invalid_NewOrderSingle_2"); + ("Msg_check_validate.validate_NewOrderSingle_3"); + ("Msg_minimal_invalid.check_validate_minimal_invalid_NewOrderSingle_3"); + ("Act_checks.is_valid_action_fill"); + ("Act_checks.is_valid_action_bookState"); + ("Model_repeating_groups.rg_count_ptyssubgrp"); + ("Model_repeating_groups.rg_count_parties"); + ("Time_defaults.make_utctimestamp"); + ("Datetime.make_utctimestamp_milli"); + ("Datetime.make_utctimestamp_micro"); + ("Time_defaults.is_valid_utctimestamp"); + ("Datetime.is_valid_utctimestamp_milli"); + ("Datetime.is_valid_utctimestamp_micro"); + ("Time_defaults.utctimestamp_Equal"); + ("Datetime.utctimestamp_Equal_milli_milli"); + ("Datetime.utctimestamp_Equal_micro_milli"); + ("Datetime.utctimestamp_Equal_milli_micro"); + ("Datetime.utctimestamp_Equal_micro_micro"); + ("Time_defaults.utctimestamp_GreaterThan"); + ("Datetime.utctimestamp_GreaterThan_milli_milli"); + ("Datetime.utctimestamp_GreaterThan_micro_milli"); + ("Datetime.utctimestamp_GreaterThan_milli_micro"); + ("Datetime.utctimestamp_GreaterThan_micro_micro"); + ("Time_defaults.utctimestamp_GreaterThanEqual"); + ("Datetime.utctimestamp_GreaterThanEqual_milli_milli"); + ("Datetime.utctimestamp_GreaterThanEqual_micro_milli"); + ("Datetime.utctimestamp_GreaterThanEqual_milli_micro"); + ("Datetime.utctimestamp_GreaterThanEqual_micro_micro"); + ("Time_defaults.utctimestamp_LessThan"); + ("Datetime.utctimestamp_LessThan_milli_milli"); + ("Datetime.utctimestamp_LessThan_micro_milli"); + ("Datetime.utctimestamp_LessThan_milli_micro"); + ("Datetime.utctimestamp_LessThan_micro_micro"); + ("Time_defaults.utctimestamp_LessThanEqual"); + ("Datetime.utctimestamp_LessThanEqual_milli_milli"); + ("Datetime.utctimestamp_LessThanEqual_micro_milli"); + ("Datetime.utctimestamp_LessThanEqual_milli_micro"); + ("Datetime.utctimestamp_LessThanEqual_micro_micro"); + ("Time_defaults.normalise_utctimestamp"); + ("Datetime.normalise_utctimestamp_milli"); + ("Datetime.normalise_utctimestamp_micro"); + ("Time_defaults.make_utctimestamp_utctimeonly_utcdateonly"); + ("Datetime.make_utctimestamp_milli_utctimeonly_milli_utcdateonly"); + ("Datetime.make_utctimestamp_micro_utctimeonly_micro_utcdateonly"); + ("Datetime.utctimestamp_milli_duration_Add"); + ("Datetime.utctimestamp_micro_duration_Add"); + ("Datetime.duration_utctimestamp_milli_Add"); + ("Datetime.duration_utctimestamp_micro_Add"); + ("Datetime.convert_utctimestamp_milli_micro"); + ("Datetime.convert_utctimestamp_micro_milli"); + ("Time_defaults.make_utctimeonly"); + ("Datetime.make_utctimeonly_milli"); + ("Datetime.make_utctimeonly_micro"); + ("Time_defaults.is_valid_utctimeonly"); + ("Datetime.is_valid_utctimeonly_milli"); + ("Datetime.is_valid_utctimeonly_micro"); + ("Time_defaults.utctimeonly_Equal"); + ("Datetime.utctimeonly_Equal_milli_milli"); + ("Datetime.utctimeonly_Equal_micro_milli"); + ("Datetime.utctimeonly_Equal_milli_micro"); + ("Datetime.utctimeonly_Equal_micro_micro"); + ("Time_defaults.utctimeonly_GreaterThan"); + ("Datetime.utctimeonly_GreaterThan_milli_milli"); + ("Datetime.utctimeonly_GreaterThan_micro_milli"); + ("Datetime.utctimeonly_GreaterThan_milli_micro"); + ("Datetime.utctimeonly_GreaterThan_micro_micro"); + ("Time_defaults.utctimeonly_GreaterThanEqual"); + ("Datetime.utctimeonly_GreaterThanEqual_milli_milli"); + ("Datetime.utctimeonly_GreaterThanEqual_micro_milli"); + ("Datetime.utctimeonly_GreaterThanEqual_milli_micro"); + ("Datetime.utctimeonly_GreaterThanEqual_micro_micro"); + ("Time_defaults.utctimeonly_LessThan"); + ("Datetime.utctimeonly_LessThan_milli_milli"); + ("Datetime.utctimeonly_LessThan_micro_milli"); + ("Datetime.utctimeonly_LessThan_milli_micro"); + ("Datetime.utctimeonly_LessThan_micro_micro"); + ("Time_defaults.utctimeonly_LessThanEqual"); + ("Datetime.utctimeonly_LessThanEqual_milli_milli"); + ("Datetime.utctimeonly_LessThanEqual_micro_milli"); + ("Datetime.utctimeonly_LessThanEqual_milli_micro"); + ("Datetime.utctimeonly_LessThanEqual_micro_micro"); + ("Time_defaults.normalise_utctimeonly"); + ("Datetime.normalise_utctimeonly_milli"); + ("Datetime.normalise_utctimeonly_micro"); + ("Datetime.convert_utctimeonly_milli_micro"); + ("Datetime.convert_utctimeonly_micro_milli"); + ("Datetime.convert_utctimestamp_micro_utctimeonly_micro"); + ("Datetime.convert_utctimestamp_micro_utctimeonly_milli"); + ("Datetime.convert_utctimestamp_milli_utctimeonly_micro"); + ("Datetime.convert_utctimestamp_milli_utctimeonly_milli"); + ("Time_defaults.convert_utctimestamp_utctimeonly"); + ("Datetime.convert_utctimestamp_micro_monthyear"); + ("Datetime.convert_utctimestamp_milli_monthyear"); + ("Time_defaults.convert_utctimestamp_monthyear"); + ("Datetime.make_monthyear"); + ("Datetime.is_valid_monthyear"); + ("Datetime.monthyear_GreaterThan"); + ("Datetime.monthyear_LessThan"); + ("Datetime.monthyear_Equal"); + ("Datetime.monthyear_GreaterThanEqual"); + ("Datetime.monthyear_LessThanEqual"); + ("Datetime.convert_utctimestamp_micro_localmktdate"); + ("Datetime.convert_utctimestamp_milli_localmktdate"); + ("Time_defaults.convert_utctimestamp_localmktdate"); + ("Datetime.make_localmktdate"); + ("Datetime.is_valid_localmktdate"); + ("Datetime.localmktdate_GreaterThan"); + ("Datetime.localmktdate_LessThan"); + ("Datetime.localmktdate_Equal"); + ("Datetime.localmktdate_GreaterThanEqual"); + ("Datetime.localmktdate_LessThanEqual"); + ("Datetime.convert_utctimestamp_micro_utcdateonly"); + ("Datetime.convert_utctimestamp_milli_utcdateonly"); + ("Time_defaults.convert_utctimestamp_utcdateonly"); + ("Datetime.make_utcdateonly"); + ("Datetime.is_valid_utcdateonly"); + ("Datetime.utcdateonly_GreaterThan"); + ("Datetime.utcdateonly_LessThan"); + ("Datetime.utcdateonly_Equal"); + ("Datetime.utcdateonly_GreaterThanEqual"); + ("Datetime.utcdateonly_LessThanEqual"); + ("Datetime.make_duration"); + ("Datetime.is_valid_duration"); + ("Datetime.duration_GreaterThan"); + ("Datetime.duration_LessThan"); + ("Datetime.duration_Equal"); + ("Datetime.duration_GreaterThanEqual"); + ("Datetime.duration_LessThanEqual"); + ("abs"); + ("Ambiguous_default_funcs.amb_func_execinst_set")] ;; let numerics () = - "Numeric.float_GreaterThan_1_3" :: ("Numeric.float_GreaterThan_1_2" :: ("Numeric.float_GreaterThan_1_5" :: ("Numeric.float_GreaterThan_1_4" :: ("Numeric.float_GreaterThan_1_1" :: ("Numeric.float_GreaterThan_1_0" :: ("Numeric.float_equal_precision_3_6" :: ("Numeric.float_GreaterThanEqual_4_0" :: ("Numeric.float_equal_precision_3_5" :: ("Numeric.float_equal_precision_3_4" :: ("Numeric.float_GreaterThanEqual_4_3" :: ("Numeric.float_GreaterThanEqual_4_4" :: ("Numeric.float_GreaterThanEqual_4_1" :: ("Numeric.float_GreaterThanEqual_4_2" :: ("Numeric.float_GreaterThanEqual_4_5" :: ("Numeric.float_GreaterThanEqual_4_6" :: ("Numeric.float_equal_precision_3_3" :: ("Numeric.float_equal_precision_3_2" :: ("Numeric.float_equal_precision_3_1" :: ("Numeric.float_equal_precision_3_0" :: ("Numeric.float_Div_5_5" :: ("Numeric.float_GreaterThan_1_6" :: ("Numeric.float_Div_5_4" :: ("Numeric.float_Div_5_6" :: ("Numeric.float_Div_5_1" :: ("Numeric.float_Div_5_0" :: ("Numeric.float_Div_5_3" :: ("Numeric.float_Div_5_2" :: ("Numeric.float_GreaterThan_2_2" :: ("Numeric.float_GreaterThan_2_1" :: ("Numeric.float_GreaterThan_2_4" :: ("Numeric.float_GreaterThan_2_3" :: ("Numeric.float_GreaterThan_2_0" :: ("Numeric.float_GreaterThanEqual_3_0" :: ("Numeric.float_equal_precision_4_6" :: ("Numeric.float_GreaterThanEqual_3_1" :: ("Numeric.float_equal_precision_4_5" :: ("Numeric.float_equal_precision_4_4" :: ("Numeric.float_equal_precision_4_3" :: ("Numeric.float_GreaterThanEqual_3_4" :: ("Numeric.float_GreaterThanEqual_3_5" :: ("Numeric.float_GreaterThanEqual_3_2" :: ("Numeric.float_GreaterThanEqual_3_3" :: ("Numeric.float_GreaterThanEqual_3_6" :: ("Numeric.float_equal_precision_4_2" :: ("Numeric.float_equal_precision_4_1" :: ("Numeric.float_equal_precision_4_0" :: ("Numeric.float_GreaterThan_2_6" :: ("Numeric.float_Div_4_6" :: ("Numeric.float_GreaterThan_2_5" :: ("Numeric.float_Div_4_5" :: ("Numeric.float_Div_4_2" :: ("Numeric.float_Div_4_1" :: ("Numeric.float_Div_4_4" :: ("Numeric.float_Div_4_3" :: ("Numeric.float_Div_4_0" :: ("Numeric.float_GreaterThan_3_1" :: ("Numeric.float_GreaterThan_3_0" :: ("Numeric.float_GreaterThan_3_3" :: ("Numeric.float_GreaterThan_3_2" :: ("Numeric.float_Add_5_1" :: ("Numeric.float_equal_precision_5_5" :: ("Numeric.float_Mult_6_2" :: ("Numeric.float_Add_5_0" :: ("Numeric.float_equal_precision_5_4" :: ("Numeric.float_Mult_6_3" :: ("Numeric.float_Add_5_3" :: ("Numeric.float_equal_precision_5_3" :: ("Numeric.float_Mult_6_0" :: ("Numeric.float_Add_5_2" :: ("Numeric.float_equal_precision_5_2" :: ("Numeric.float_Mult_6_1" :: ("Numeric.float_GreaterThanEqual_6_1" :: ("Numeric.float_GreaterThanEqual_6_2" :: ("Numeric.float_equal_precision_5_6" :: ("Numeric.float_GreaterThanEqual_6_0" :: ("Numeric.float_GreaterThanEqual_6_5" :: ("Numeric.float_GreaterThanEqual_6_6" :: ("Numeric.float_GreaterThanEqual_6_3" :: ("Numeric.float_GreaterThanEqual_6_4" :: ("Numeric.float_equal_precision_5_1" :: ("Numeric.float_Add_5_5" :: ("Numeric.float_equal_precision_5_0" :: ("Numeric.float_Add_5_4" :: ("Numeric.float_Add_5_6" :: ("Numeric.float_Mult_6_6" :: ("Numeric.float_Mult_6_4" :: ("Numeric.float_Mult_6_5" :: ("Numeric.float_Convert_5_2" :: ("Numeric.float_Convert_5_3" :: ("Numeric.float_Convert_5_4" :: ("Numeric.float_Convert_5_5" :: ("Numeric.float_GreaterThan_3_5" :: ("Numeric.float_Convert_5_6" :: ("Numeric.float_GreaterThan_3_4" :: ("Numeric.float_GreaterThan_3_6" :: ("Numeric.float_Neg_4" :: ("Numeric.float_Neg_3" :: ("Numeric.float_Convert_5_0" :: ("Numeric.float_Neg_6" :: ("Numeric.float_Neg_5" :: ("Numeric.float_Convert_5_1" :: ("Numeric.float_GreaterThan_4_0" :: ("Numeric.float_GreaterThan_4_2" :: ("Numeric.float_GreaterThan_4_1" :: ("Numeric.float_Mult_5_3" :: ("Numeric.float_Add_6_0" :: ("Numeric.float_equal_precision_6_4" :: ("Numeric.float_Mult_5_4" :: ("Numeric.float_equal_precision_6_3" :: ("Numeric.float_Mult_5_1" :: ("Numeric.float_Add_6_2" :: ("Numeric.float_equal_precision_6_2" :: ("Numeric.float_Mult_5_2" :: ("Numeric.float_Add_6_1" :: ("Numeric.float_equal_precision_6_1" :: ("Numeric.float_GreaterThanEqual_5_2" :: ("Numeric.float_Mult_5_0" :: ("Numeric.float_GreaterThanEqual_5_3" :: ("Numeric.float_GreaterThanEqual_5_0" :: ("Numeric.float_equal_precision_6_6" :: ("Numeric.float_GreaterThanEqual_5_1" :: ("Numeric.float_equal_precision_6_5" :: ("Numeric.float_GreaterThanEqual_5_6" :: ("Numeric.float_GreaterThanEqual_5_4" :: ("Numeric.float_GreaterThanEqual_5_5" :: ("Numeric.float_equal_precision_6_0" :: ("Numeric.float_Add_6_4" :: ("Numeric.float_Add_6_3" :: ("Numeric.float_Add_6_6" :: ("Numeric.float_Add_6_5" :: ("Numeric.float_Mult_5_5" :: ("Numeric.float_Mult_5_6" :: ("Numeric.float_Convert_6_1" :: ("Numeric.float_Convert_6_2" :: ("Numeric.float_Convert_6_3" :: ("Numeric.float_Convert_6_4" :: ("Numeric.float_GreaterThan_4_4" :: ("Numeric.float_Div_6_4" :: ("Numeric.float_Convert_6_5" :: ("Numeric.float_GreaterThan_4_3" :: ("Numeric.float_Div_6_3" :: ("Numeric.float_Convert_6_6" :: ("Numeric.float_GreaterThan_4_6" :: ("Numeric.float_Div_6_6" :: ("Numeric.float_GreaterThan_4_5" :: ("Numeric.float_Div_6_5" :: ("Numeric.float_Div_6_0" :: ("Numeric.float_Div_6_2" :: ("Numeric.float_Div_6_1" :: ("Numeric.float_Convert_6_0" :: ("Numeric.float_GreaterThan_5_1" :: ("Numeric.float_GreaterThan_5_0" :: ("Numeric.float_LessThanEqual_6_6" :: ("Numeric.float_LessThanEqual_6_5" :: ("Numeric.float_LessThanEqual_6_4" :: ("Numeric.float_LessThanEqual_6_3" :: ("Numeric.float_LessThanEqual_6_2" :: ("Numeric.float_GreaterThanEqual_0_3" :: ("Numeric.float_Mult_4_4" :: ("Numeric.float_GreaterThanEqual_0_4" :: ("Numeric.float_Mult_4_5" :: ("Numeric.float_GreaterThanEqual_0_1" :: ("Numeric.float_Mult_4_2" :: ("Numeric.float_GreaterThanEqual_0_2" :: ("Numeric.float_Mult_4_3" :: ("Numeric.float_Mult_4_0" :: ("Numeric.float_Mult_4_1" :: ("Numeric.float_GreaterThanEqual_0_5" :: ("Numeric.float_GreaterThanEqual_0_6" :: ("Numeric.float_Equal_6_3" :: ("Numeric.float_Equal_6_2" :: ("Numeric.float_Equal_6_1" :: ("Numeric.float_Equal_6_0" :: ("Numeric.float_Equal_6_6" :: ("Numeric.float_Equal_6_5" :: ("Numeric.float_Equal_6_4" :: ("Numeric.float_GreaterThanEqual_0_0" :: ("Numeric.float_Mult_4_6" :: ("Numeric.float_LessThanEqual_6_1" :: ("Numeric.float_GreaterThan_5_6" :: ("Numeric.float_LessThanEqual_6_0" :: ("Numeric.float_GreaterThan_5_3" :: ("Numeric.float_GreaterThan_5_2" :: ("Numeric.float_GreaterThan_5_5" :: ("Numeric.float_GreaterThan_5_4" :: ("Numeric.float_GreaterThan_6_0" :: ("Numeric.float_Mult_3_5" :: ("Numeric.float_Mult_3_6" :: ("Numeric.float_Mult_3_3" :: ("Numeric.float_Mult_3_4" :: ("Numeric.float_Mult_3_1" :: ("Numeric.float_Equal_5_0" :: ("Numeric.float_Mult_3_2" :: ("Numeric.float_Mult_3_0" :: ("Numeric.float_Equal_5_4" :: ("Numeric.float_Equal_5_3" :: ("Numeric.float_Equal_5_2" :: ("Numeric.float_Equal_5_1" :: ("Numeric.float_Equal_5_6" :: ("Numeric.float_Equal_5_5" :: ("Numeric.float_LessThan_6_6" :: ("Numeric.float_LessThan_6_2" :: ("Numeric.float_LessThan_6_3" :: ("Numeric.float_LessThan_6_4" :: ("Numeric.float_LessThan_6_5" :: ("Numeric.float_LessThan_6_0" :: ("Numeric.float_LessThan_6_1" :: ("Numeric.float_GreaterThan_6_6" :: ("Numeric.float_GreaterThan_6_5" :: ("Numeric.float_GreaterThan_6_2" :: ("Numeric.float_GreaterThan_6_1" :: ("Numeric.float_GreaterThan_6_4" :: ("Numeric.float_GreaterThan_6_3" :: ("Numeric.float_Sub_5_6" :: ("Numeric.float_Sub_5_5" :: ("Numeric.float_Sub_5_0" :: ("Numeric.float_Sub_5_4" :: ("Numeric.float_Sub_5_3" :: ("Numeric.float_Sub_5_2" :: ("Numeric.float_Sub_5_1" :: ("Numeric.float_GreaterThanEqual_2_1" :: ("Numeric.float_Mult_2_6" :: ("Numeric.float_GreaterThanEqual_2_2" :: ("Numeric.float_Mult_2_4" :: ("Numeric.float_GreaterThanEqual_2_0" :: ("Numeric.float_Mult_2_5" :: ("Numeric.float_Mult_2_2" :: ("Numeric.float_GreaterThanEqual_2_5" :: ("Numeric.float_Mult_2_3" :: ("Numeric.float_GreaterThanEqual_2_6" :: ("Numeric.float_Mult_2_0" :: ("Numeric.float_GreaterThanEqual_2_3" :: ("Numeric.float_Mult_2_1" :: ("Numeric.float_GreaterThanEqual_2_4" :: ("Numeric.float_LessThan_5_3" :: ("Numeric.float_LessThan_5_4" :: ("Numeric.float_LessThan_5_5" :: ("Numeric.float_LessThan_5_6" :: ("Numeric.float_LessThan_5_0" :: ("Numeric.float_LessThan_5_1" :: ("Numeric.float_LessThan_5_2" :: ("Numeric.float_Sub_6_6" :: ("Numeric.float_Sub_6_5" :: ("Numeric.float_Sub_6_4" :: ("Numeric.float_Sub_6_3" :: ("Numeric.float_Sub_6_2" :: ("Numeric.float_Sub_6_1" :: ("Numeric.float_Sub_6_0" :: ("Numeric.float_GreaterThanEqual_1_2" :: ("Numeric.float_GreaterThanEqual_1_3" :: ("Numeric.float_GreaterThanEqual_1_0" :: ("Numeric.float_Mult_1_5" :: ("Numeric.float_GreaterThanEqual_1_1" :: ("Numeric.float_Mult_1_6" :: ("Numeric.float_Mult_1_3" :: ("Numeric.float_GreaterThanEqual_1_6" :: ("Numeric.float_Mult_1_4" :: ("Numeric.float_Mult_1_1" :: ("Numeric.float_GreaterThanEqual_1_4" :: ("Numeric.float_Mult_1_2" :: ("Numeric.float_GreaterThanEqual_1_5" :: ("Numeric.float_Mult_1_0" :: ("Numeric.float_LessThan_4_4" :: ("Numeric.float_LessThan_4_5" :: ("Numeric.float_LessThan_4_6" :: ("Numeric.float_LessThan_4_0" :: ("Numeric.float_LessThan_4_1" :: ("Numeric.float_LessThan_4_2" :: ("Numeric.float_LessThan_4_3" :: ("Numeric.float_Sub_3_2" :: ("Numeric.float_Sub_3_1" :: ("Numeric.float_Sub_3_0" :: ("Numeric.float_Sub_3_6" :: ("Numeric.float_Sub_3_5" :: ("Numeric.float_Sub_3_4" :: ("Numeric.float_LessThanEqual_2_6" :: ("Numeric.float_Sub_3_3" :: ("Numeric.float_Mult_0_6" :: ("Numeric.float_Mult_0_4" :: ("Numeric.float_Equal_2_3" :: ("Numeric.float_Mult_0_5" :: ("Numeric.float_Equal_2_2" :: ("Numeric.float_Mult_0_2" :: ("Numeric.float_Equal_2_1" :: ("Numeric.float_Mult_0_3" :: ("Numeric.float_Equal_2_0" :: ("Numeric.float_Mult_0_0" :: ("Numeric.float_higher_precision_4_3" :: ("Numeric.float_Mult_0_1" :: ("Numeric.float_Equal_2_6" :: ("Numeric.float_higher_precision_4_2" :: ("Numeric.float_Equal_2_5" :: ("Numeric.float_higher_precision_4_1" :: ("Numeric.float_Equal_2_4" :: ("Numeric.float_higher_precision_4_0" :: ("Numeric.float_higher_precision_4_6" :: ("Numeric.float_higher_precision_4_5" :: ("Numeric.float_higher_precision_4_4" :: ("Numeric.float_LessThan_3_5" :: ("Numeric.float_LessThan_3_6" :: ("Numeric.float_LessThan_3_1" :: ("Numeric.float_LessThan_3_2" :: ("Numeric.float_LessThan_3_3" :: ("Numeric.float_LessThan_3_4" :: ("Numeric.float_LessThan_3_0" :: ("Numeric.float_LessThanEqual_2_5" :: ("Numeric.float_LessThanEqual_2_4" :: ("Numeric.float_LessThanEqual_2_3" :: ("Numeric.float_LessThanEqual_2_2" :: ("Numeric.float_LessThanEqual_2_1" :: ("Numeric.float_LessThanEqual_2_0" :: ("Numeric.float_Sub_4_6" :: ("Numeric.float_Sub_4_1" :: ("Numeric.float_Sub_4_0" :: ("Numeric.float_Sub_4_5" :: ("Numeric.float_Sub_4_4" :: ("Numeric.float_LessThanEqual_3_6" :: ("Numeric.float_Sub_4_3" :: ("Numeric.float_LessThanEqual_3_5" :: ("Numeric.float_Sub_4_2" :: ("Numeric.float_Add_0_6" :: ("Numeric.float_Equal_1_0" :: ("Numeric.float_Add_0_5" :: ("Numeric.float_Add_0_2" :: ("Numeric.float_Equal_1_4" :: ("Numeric.float_Add_0_1" :: ("Numeric.float_Equal_1_3" :: ("Numeric.float_Add_0_4" :: ("Numeric.float_Equal_1_2" :: ("Numeric.float_Add_0_3" :: ("Numeric.float_Equal_1_1" :: ("Numeric.float_higher_precision_5_2" :: ("Numeric.float_higher_precision_5_1" :: ("Numeric.float_Equal_1_6" :: ("Numeric.float_higher_precision_5_0" :: ("Numeric.float_Equal_1_5" :: ("Numeric.float_higher_precision_5_6" :: ("Numeric.float_higher_precision_5_5" :: ("Numeric.float_higher_precision_5_4" :: ("Numeric.float_higher_precision_5_3" :: ("Numeric.float_LessThan_2_6" :: ("Numeric.float_LessThan_2_2" :: ("Numeric.float_LessThan_2_3" :: ("Numeric.float_LessThan_2_4" :: ("Numeric.float_LessThan_2_5" :: ("Numeric.float_LessThan_2_0" :: ("Numeric.float_LessThan_2_1" :: ("Numeric.float_LessThanEqual_3_4" :: ("Numeric.float_LessThanEqual_3_3" :: ("Numeric.float_LessThanEqual_3_2" :: ("Numeric.float_LessThanEqual_3_1" :: ("Numeric.float_LessThanEqual_3_0" :: ("Numeric.float_Convert_0_0" :: ("Numeric.float_Convert_0_1" :: ("Numeric.float_Convert_0_2" :: ("Numeric.float_Convert_0_3" :: ("Numeric.float_Convert_0_4" :: ("Numeric.float_Convert_0_5" :: ("Numeric.float_Convert_0_6" :: ("Numeric.float_Sub_1_4" :: ("Numeric.float_Sub_1_3" :: ("Numeric.float_Sub_1_2" :: ("Numeric.float_Sub_1_1" :: ("Numeric.float_LessThanEqual_4_6" :: ("Numeric.float_Sub_1_6" :: ("Numeric.float_LessThanEqual_4_5" :: ("Numeric.float_Sub_1_5" :: ("Numeric.float_LessThanEqual_4_4" :: ("Numeric.float_is_one_0" :: ("Numeric.float_is_one_1" :: ("Numeric.float_Equal_4_1" :: ("Numeric.float_Equal_4_0" :: ("Numeric.float_Equal_4_5" :: ("Numeric.float_is_one_6" :: ("Numeric.float_higher_precision_6_1" :: ("Numeric.float_Equal_4_4" :: ("Numeric.float_higher_precision_6_0" :: ("Numeric.float_Equal_4_3" :: ("Numeric.float_Equal_4_2" :: ("Numeric.float_is_one_2" :: ("Numeric.float_higher_precision_6_5" :: ("Numeric.float_is_one_3" :: ("Numeric.float_higher_precision_6_4" :: ("Numeric.float_is_one_4" :: ("Numeric.float_higher_precision_6_3" :: ("Numeric.float_Equal_4_6" :: ("Numeric.float_is_one_5" :: ("Numeric.float_higher_precision_6_2" :: ("Numeric.float_higher_precision_6_6" :: ("Numeric.float_LessThan_1_3" :: ("Numeric.float_LessThan_1_4" :: ("Numeric.float_LessThan_1_5" :: ("Numeric.float_LessThan_1_6" :: ("Numeric.float_LessThan_1_0" :: ("Numeric.float_LessThan_1_1" :: ("Numeric.float_LessThan_1_2" :: ("Numeric.float_LessThanEqual_4_3" :: ("Numeric.float_LessThanEqual_4_2" :: ("Numeric.float_LessThanEqual_4_1" :: ("Numeric.float_LessThanEqual_4_0" :: ("Numeric.float_Sub_1_0" :: ("Numeric.float_Sub_2_3" :: ("Numeric.float_Sub_2_2" :: ("Numeric.float_Sub_2_1" :: ("Numeric.float_Sub_2_0" :: ("Numeric.float_LessThanEqual_5_6" :: ("Numeric.float_Sub_2_6" :: ("Numeric.float_LessThanEqual_5_5" :: ("Numeric.float_Sub_2_5" :: ("Numeric.float_LessThanEqual_5_4" :: ("Numeric.float_Sub_2_4" :: ("Numeric.float_LessThanEqual_5_3" :: ("Numeric.float_Equal_3_2" :: ("Numeric.float_Equal_3_1" :: ("Numeric.float_Equal_3_0" :: ("Numeric.float_Equal_3_6" :: ("Numeric.float_Equal_3_5" :: ("Numeric.float_Equal_3_4" :: ("Numeric.float_Equal_3_3" :: ("Numeric.float_LessThan_0_4" :: ("Numeric.float_Create_3" :: ("Numeric.float_LessThan_0_5" :: ("Numeric.float_Create_4" :: ("Numeric.float_LessThan_0_6" :: ("Numeric.float_Create_5" :: ("Numeric.float_Create_6" :: ("Numeric.float_LessThan_0_0" :: ("Numeric.float_Create_0" :: ("Numeric.float_LessThan_0_1" :: ("Numeric.float_LessThan_0_2" :: ("Numeric.float_Create_1" :: ("Numeric.float_LessThan_0_3" :: ("Numeric.float_Create_2" :: ("Numeric.float_LessThanEqual_5_2" :: ("Numeric.float_LessThanEqual_5_1" :: ("Numeric.float_LessThanEqual_5_0" :: ("Numeric.float_Add_3_3" :: ("Numeric.float_Add_3_2" :: ("Numeric.float_Add_3_5" :: ("Numeric.float_Add_3_4" :: ("Numeric.float_higher_precision_0_3" :: ("Numeric.float_higher_precision_0_2" :: ("Numeric.float_higher_precision_0_1" :: ("Numeric.float_Add_3_1" :: ("Numeric.float_higher_precision_0_0" :: ("Numeric.float_Add_3_0" :: ("Numeric.float_higher_precision_0_6" :: ("Numeric.float_higher_precision_0_5" :: ("Numeric.float_higher_precision_0_4" :: ("Numeric.float_Add_3_6" :: ("Numeric.float_Convert_3_4" :: ("Numeric.float_Convert_3_5" :: ("Numeric.float_Convert_3_6" :: ("Numeric.float_Div_1_5" :: ("Numeric.float_Div_1_4" :: ("Numeric.float_Div_1_6" :: ("Numeric.float_Div_1_1" :: ("Numeric.float_Convert_3_0" :: ("Numeric.float_Div_1_0" :: ("Numeric.float_Convert_3_1" :: ("Numeric.float_Div_1_3" :: ("Numeric.float_Convert_3_2" :: ("Numeric.float_Div_1_2" :: ("Numeric.float_Convert_3_3" :: ("Numeric.float_Neg_0" :: ("Numeric.float_Neg_2" :: ("Numeric.float_Neg_1" :: ("Numeric.float_Sub_0_5" :: ("Numeric.float_Sub_0_4" :: ("Numeric.float_Sub_0_3" :: ("Numeric.float_Sub_0_2" :: ("Numeric.float_Sub_0_6" :: ("Numeric.float_Add_4_2" :: ("Numeric.float_Add_4_1" :: ("Numeric.float_Add_4_4" :: ("Numeric.float_Add_4_3" :: ("Numeric.float_higher_precision_1_2" :: ("Numeric.float_higher_precision_1_1" :: ("Numeric.float_higher_precision_1_0" :: ("Numeric.float_Add_4_0" :: ("Numeric.float_equal_precision_0_2" :: ("Numeric.float_higher_precision_1_6" :: ("Numeric.float_equal_precision_0_1" :: ("Numeric.float_higher_precision_1_5" :: ("Numeric.float_equal_precision_0_0" :: ("Numeric.float_higher_precision_1_4" :: ("Numeric.float_higher_precision_1_3" :: ("Numeric.float_equal_precision_0_6" :: ("Numeric.float_Add_4_6" :: ("Numeric.float_equal_precision_0_5" :: ("Numeric.float_Add_4_5" :: ("Numeric.float_equal_precision_0_4" :: ("Numeric.float_equal_precision_0_3" :: ("Numeric.float_Div_0_0" :: ("Numeric.float_Convert_4_3" :: ("Numeric.float_Convert_4_4" :: ("Numeric.float_Convert_4_5" :: ("Numeric.float_Convert_4_6" :: ("Numeric.float_Sub_0_1" :: ("Numeric.float_Sub_0_0" :: ("Numeric.float_Div_0_6" :: ("Numeric.float_Div_0_5" :: ("Numeric.float_Div_0_2" :: ("Numeric.float_Div_0_1" :: ("Numeric.float_Convert_4_0" :: ("Numeric.float_Div_0_4" :: ("Numeric.float_Convert_4_1" :: ("Numeric.float_Div_0_3" :: ("Numeric.float_Convert_4_2" :: ("Numeric.float_is_zero_2" :: ("Numeric.float_is_zero_3" :: ("Numeric.float_is_zero_4" :: ("Numeric.float_is_zero_5" :: ("Numeric.float_is_zero_0" :: ("Numeric.float_is_zero_1" :: ("Numeric.float_Equal_0_1" :: ("Numeric.float_Add_1_5" :: ("Numeric.float_Equal_0_0" :: ("Numeric.float_Add_1_4" :: ("Numeric.float_Add_1_6" :: ("Numeric.float_equal_precision_1_6" :: ("Numeric.float_Equal_0_5" :: ("Numeric.float_Add_1_1" :: ("Numeric.float_higher_precision_2_1" :: ("Numeric.float_Equal_0_4" :: ("Numeric.float_Add_1_0" :: ("Numeric.float_higher_precision_2_0" :: ("Numeric.float_Equal_0_3" :: ("Numeric.float_Add_1_3" :: ("Numeric.float_Equal_0_2" :: ("Numeric.float_Add_1_2" :: ("Numeric.float_equal_precision_1_1" :: ("Numeric.float_higher_precision_2_5" :: ("Numeric.float_equal_precision_1_0" :: ("Numeric.float_higher_precision_2_4" :: ("Numeric.float_higher_precision_2_3" :: ("Numeric.float_Equal_0_6" :: ("Numeric.float_higher_precision_2_2" :: ("Numeric.float_equal_precision_1_5" :: ("Numeric.float_is_zero_6" :: ("Numeric.float_equal_precision_1_4" :: ("Numeric.float_equal_precision_1_3" :: ("Numeric.float_equal_precision_1_2" :: ("Numeric.float_higher_precision_2_6" :: ("Numeric.float_Add_0_0" :: ("Numeric.float_Convert_1_6" :: ("Numeric.float_LessThanEqual_0_6" :: ("Numeric.float_LessThanEqual_0_5" :: ("Numeric.float_LessThanEqual_0_4" :: ("Numeric.float_LessThanEqual_0_3" :: ("Numeric.float_LessThanEqual_0_2" :: ("Numeric.float_Div_3_6" :: ("Numeric.float_LessThanEqual_0_1" :: ("Numeric.float_LessThanEqual_0_0" :: ("Numeric.float_Div_3_3" :: ("Numeric.float_Div_3_2" :: ("Numeric.float_Convert_1_0" :: ("Numeric.float_Div_3_5" :: ("Numeric.float_Convert_1_1" :: ("Numeric.float_Div_3_4" :: ("Numeric.float_Convert_1_2" :: ("Numeric.float_Convert_1_3" :: ("Numeric.float_Convert_1_4" :: ("Numeric.float_Div_3_1" :: ("Numeric.float_Convert_1_5" :: ("Numeric.float_Div_3_0" :: ("Numeric.float_GreaterThan_0_4" :: ("Numeric.float_GreaterThan_0_3" :: ("Numeric.float_GreaterThan_0_6" :: ("Numeric.float_GreaterThan_0_5" :: ("Numeric.float_GreaterThan_0_0" :: ("Numeric.float_GreaterThan_0_2" :: ("Numeric.float_GreaterThan_0_1" :: ("Numeric.float_Add_2_4" :: ("Numeric.float_Add_2_3" :: ("Numeric.float_Add_2_6" :: ("Numeric.float_equal_precision_2_6" :: ("Numeric.float_Add_2_5" :: ("Numeric.float_equal_precision_2_5" :: ("Numeric.float_Add_2_0" :: ("Numeric.float_higher_precision_3_0" :: ("Numeric.float_Add_2_2" :: ("Numeric.float_Add_2_1" :: ("Numeric.float_equal_precision_2_0" :: ("Numeric.float_higher_precision_3_4" :: ("Numeric.float_higher_precision_3_3" :: ("Numeric.float_higher_precision_3_2" :: ("Numeric.float_higher_precision_3_1" :: ("Numeric.float_equal_precision_2_4" :: ("Numeric.float_equal_precision_2_3" :: ("Numeric.float_equal_precision_2_2" :: ("Numeric.float_higher_precision_3_6" :: ("Numeric.float_equal_precision_2_1" :: ("Numeric.float_higher_precision_3_5" :: ("Numeric.float_LessThanEqual_1_6" :: ("Numeric.float_Convert_2_5" :: ("Numeric.float_LessThanEqual_1_5" :: ("Numeric.float_Convert_2_6" :: ("Numeric.float_LessThanEqual_1_4" :: ("Numeric.float_LessThanEqual_1_3" :: ("Numeric.float_LessThanEqual_1_2" :: ("Numeric.float_LessThanEqual_1_1" :: ("Numeric.float_LessThanEqual_1_0" :: ("Numeric.float_Div_2_4" :: ("Numeric.float_Div_2_3" :: ("Numeric.float_Div_2_6" :: ("Numeric.float_Convert_2_0" :: ("Numeric.float_Div_2_5" :: ("Numeric.float_Div_2_0" :: ("Numeric.float_Convert_2_1" :: ("Numeric.float_Convert_2_2" :: ("Numeric.float_Div_2_2" :: ("Numeric.float_Convert_2_3" :: ("Numeric.float_Div_2_1" :: ("Numeric.float_Convert_2_4" :: []))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) - [@@macro] + [("Numeric.float_Create_0"); + ("Numeric.float_Neg_0"); + ("Numeric.float_is_zero_0"); + ("Numeric.float_is_one_0"); + ("Numeric.float_Convert_0_0"); + ("Numeric.float_Add_0_0"); + ("Numeric.float_Mult_0_0"); + ("Numeric.float_Sub_0_0"); + ("Numeric.float_Div_0_0"); + ("Numeric.float_GreaterThan_0_0"); + ("Numeric.float_LessThan_0_0"); + ("Numeric.float_GreaterThanEqual_0_0"); + ("Numeric.float_LessThanEqual_0_0"); + ("Numeric.float_Equal_0_0"); + ("Numeric.float_higher_precision_0_0"); + ("Numeric.float_equal_precision_0_0"); + ("Numeric.float_Convert_0_1"); + ("Numeric.float_Add_0_1"); + ("Numeric.float_Mult_0_1"); + ("Numeric.float_Sub_0_1"); + ("Numeric.float_Div_0_1"); + ("Numeric.float_GreaterThan_0_1"); + ("Numeric.float_LessThan_0_1"); + ("Numeric.float_GreaterThanEqual_0_1"); + ("Numeric.float_LessThanEqual_0_1"); + ("Numeric.float_Equal_0_1"); + ("Numeric.float_higher_precision_0_1"); + ("Numeric.float_equal_precision_0_1"); + ("Numeric.float_Convert_0_2"); + ("Numeric.float_Add_0_2"); + ("Numeric.float_Mult_0_2"); + ("Numeric.float_Sub_0_2"); + ("Numeric.float_Div_0_2"); + ("Numeric.float_GreaterThan_0_2"); + ("Numeric.float_LessThan_0_2"); + ("Numeric.float_GreaterThanEqual_0_2"); + ("Numeric.float_LessThanEqual_0_2"); + ("Numeric.float_Equal_0_2"); + ("Numeric.float_higher_precision_0_2"); + ("Numeric.float_equal_precision_0_2"); + ("Numeric.float_Convert_0_3"); + ("Numeric.float_Add_0_3"); + ("Numeric.float_Mult_0_3"); + ("Numeric.float_Sub_0_3"); + ("Numeric.float_Div_0_3"); + ("Numeric.float_GreaterThan_0_3"); + ("Numeric.float_LessThan_0_3"); + ("Numeric.float_GreaterThanEqual_0_3"); + ("Numeric.float_LessThanEqual_0_3"); + ("Numeric.float_Equal_0_3"); + ("Numeric.float_higher_precision_0_3"); + ("Numeric.float_equal_precision_0_3"); + ("Numeric.float_Convert_0_4"); + ("Numeric.float_Add_0_4"); + ("Numeric.float_Mult_0_4"); + ("Numeric.float_Sub_0_4"); + ("Numeric.float_Div_0_4"); + ("Numeric.float_GreaterThan_0_4"); + ("Numeric.float_LessThan_0_4"); + ("Numeric.float_GreaterThanEqual_0_4"); + ("Numeric.float_LessThanEqual_0_4"); + ("Numeric.float_Equal_0_4"); + ("Numeric.float_higher_precision_0_4"); + ("Numeric.float_equal_precision_0_4"); + ("Numeric.float_Convert_0_5"); + ("Numeric.float_Add_0_5"); + ("Numeric.float_Mult_0_5"); + ("Numeric.float_Sub_0_5"); + ("Numeric.float_Div_0_5"); + ("Numeric.float_GreaterThan_0_5"); + ("Numeric.float_LessThan_0_5"); + ("Numeric.float_GreaterThanEqual_0_5"); + ("Numeric.float_LessThanEqual_0_5"); + ("Numeric.float_Equal_0_5"); + ("Numeric.float_higher_precision_0_5"); + ("Numeric.float_equal_precision_0_5"); + ("Numeric.float_Convert_0_6"); + ("Numeric.float_Add_0_6"); + ("Numeric.float_Mult_0_6"); + ("Numeric.float_Sub_0_6"); + ("Numeric.float_Div_0_6"); + ("Numeric.float_GreaterThan_0_6"); + ("Numeric.float_LessThan_0_6"); + ("Numeric.float_GreaterThanEqual_0_6"); + ("Numeric.float_LessThanEqual_0_6"); + ("Numeric.float_Equal_0_6"); + ("Numeric.float_higher_precision_0_6"); + ("Numeric.float_equal_precision_0_6"); + ("Numeric.float_Create_1"); + ("Numeric.float_Neg_1"); + ("Numeric.float_is_zero_1"); + ("Numeric.float_is_one_1"); + ("Numeric.float_Convert_1_0"); + ("Numeric.float_Add_1_0"); + ("Numeric.float_Mult_1_0"); + ("Numeric.float_Sub_1_0"); + ("Numeric.float_Div_1_0"); + ("Numeric.float_GreaterThan_1_0"); + ("Numeric.float_LessThan_1_0"); + ("Numeric.float_GreaterThanEqual_1_0"); + ("Numeric.float_LessThanEqual_1_0"); + ("Numeric.float_Equal_1_0"); + ("Numeric.float_higher_precision_1_0"); + ("Numeric.float_equal_precision_1_0"); + ("Numeric.float_Convert_1_1"); + ("Numeric.float_Add_1_1"); + ("Numeric.float_Mult_1_1"); + ("Numeric.float_Sub_1_1"); + ("Numeric.float_Div_1_1"); + ("Numeric.float_GreaterThan_1_1"); + ("Numeric.float_LessThan_1_1"); + ("Numeric.float_GreaterThanEqual_1_1"); + ("Numeric.float_LessThanEqual_1_1"); + ("Numeric.float_Equal_1_1"); + ("Numeric.float_higher_precision_1_1"); + ("Numeric.float_equal_precision_1_1"); + ("Numeric.float_Convert_1_2"); + ("Numeric.float_Add_1_2"); + ("Numeric.float_Mult_1_2"); + ("Numeric.float_Sub_1_2"); + ("Numeric.float_Div_1_2"); + ("Numeric.float_GreaterThan_1_2"); + ("Numeric.float_LessThan_1_2"); + ("Numeric.float_GreaterThanEqual_1_2"); + ("Numeric.float_LessThanEqual_1_2"); + ("Numeric.float_Equal_1_2"); + ("Numeric.float_higher_precision_1_2"); + ("Numeric.float_equal_precision_1_2"); + ("Numeric.float_Convert_1_3"); + ("Numeric.float_Add_1_3"); + ("Numeric.float_Mult_1_3"); + ("Numeric.float_Sub_1_3"); + ("Numeric.float_Div_1_3"); + ("Numeric.float_GreaterThan_1_3"); + ("Numeric.float_LessThan_1_3"); + ("Numeric.float_GreaterThanEqual_1_3"); + ("Numeric.float_LessThanEqual_1_3"); + ("Numeric.float_Equal_1_3"); + ("Numeric.float_higher_precision_1_3"); + ("Numeric.float_equal_precision_1_3"); + ("Numeric.float_Convert_1_4"); + ("Numeric.float_Add_1_4"); + ("Numeric.float_Mult_1_4"); + ("Numeric.float_Sub_1_4"); + ("Numeric.float_Div_1_4"); + ("Numeric.float_GreaterThan_1_4"); + ("Numeric.float_LessThan_1_4"); + ("Numeric.float_GreaterThanEqual_1_4"); + ("Numeric.float_LessThanEqual_1_4"); + ("Numeric.float_Equal_1_4"); + ("Numeric.float_higher_precision_1_4"); + ("Numeric.float_equal_precision_1_4"); + ("Numeric.float_Convert_1_5"); + ("Numeric.float_Add_1_5"); + ("Numeric.float_Mult_1_5"); + ("Numeric.float_Sub_1_5"); + ("Numeric.float_Div_1_5"); + ("Numeric.float_GreaterThan_1_5"); + ("Numeric.float_LessThan_1_5"); + ("Numeric.float_GreaterThanEqual_1_5"); + ("Numeric.float_LessThanEqual_1_5"); + ("Numeric.float_Equal_1_5"); + ("Numeric.float_higher_precision_1_5"); + ("Numeric.float_equal_precision_1_5"); + ("Numeric.float_Convert_1_6"); + ("Numeric.float_Add_1_6"); + ("Numeric.float_Mult_1_6"); + ("Numeric.float_Sub_1_6"); + ("Numeric.float_Div_1_6"); + ("Numeric.float_GreaterThan_1_6"); + ("Numeric.float_LessThan_1_6"); + ("Numeric.float_GreaterThanEqual_1_6"); + ("Numeric.float_LessThanEqual_1_6"); + ("Numeric.float_Equal_1_6"); + ("Numeric.float_higher_precision_1_6"); + ("Numeric.float_equal_precision_1_6"); + ("Numeric.float_Create_2"); + ("Numeric.float_Neg_2"); + ("Numeric.float_is_zero_2"); + ("Numeric.float_is_one_2"); + ("Numeric.float_Convert_2_0"); + ("Numeric.float_Add_2_0"); + ("Numeric.float_Mult_2_0"); + ("Numeric.float_Sub_2_0"); + ("Numeric.float_Div_2_0"); + ("Numeric.float_GreaterThan_2_0"); + ("Numeric.float_LessThan_2_0"); + ("Numeric.float_GreaterThanEqual_2_0"); + ("Numeric.float_LessThanEqual_2_0"); + ("Numeric.float_Equal_2_0"); + ("Numeric.float_higher_precision_2_0"); + ("Numeric.float_equal_precision_2_0"); + ("Numeric.float_Convert_2_1"); + ("Numeric.float_Add_2_1"); + ("Numeric.float_Mult_2_1"); + ("Numeric.float_Sub_2_1"); + ("Numeric.float_Div_2_1"); + ("Numeric.float_GreaterThan_2_1"); + ("Numeric.float_LessThan_2_1"); + ("Numeric.float_GreaterThanEqual_2_1"); + ("Numeric.float_LessThanEqual_2_1"); + ("Numeric.float_Equal_2_1"); + ("Numeric.float_higher_precision_2_1"); + ("Numeric.float_equal_precision_2_1"); + ("Numeric.float_Convert_2_2"); + ("Numeric.float_Add_2_2"); + ("Numeric.float_Mult_2_2"); + ("Numeric.float_Sub_2_2"); + ("Numeric.float_Div_2_2"); + ("Numeric.float_GreaterThan_2_2"); + ("Numeric.float_LessThan_2_2"); + ("Numeric.float_GreaterThanEqual_2_2"); + ("Numeric.float_LessThanEqual_2_2"); + ("Numeric.float_Equal_2_2"); + ("Numeric.float_higher_precision_2_2"); + ("Numeric.float_equal_precision_2_2"); + ("Numeric.float_Convert_2_3"); + ("Numeric.float_Add_2_3"); + ("Numeric.float_Mult_2_3"); + ("Numeric.float_Sub_2_3"); + ("Numeric.float_Div_2_3"); + ("Numeric.float_GreaterThan_2_3"); + ("Numeric.float_LessThan_2_3"); + ("Numeric.float_GreaterThanEqual_2_3"); + ("Numeric.float_LessThanEqual_2_3"); + ("Numeric.float_Equal_2_3"); + ("Numeric.float_higher_precision_2_3"); + ("Numeric.float_equal_precision_2_3"); + ("Numeric.float_Convert_2_4"); + ("Numeric.float_Add_2_4"); + ("Numeric.float_Mult_2_4"); + ("Numeric.float_Sub_2_4"); + ("Numeric.float_Div_2_4"); + ("Numeric.float_GreaterThan_2_4"); + ("Numeric.float_LessThan_2_4"); + ("Numeric.float_GreaterThanEqual_2_4"); + ("Numeric.float_LessThanEqual_2_4"); + ("Numeric.float_Equal_2_4"); + ("Numeric.float_higher_precision_2_4"); + ("Numeric.float_equal_precision_2_4"); + ("Numeric.float_Convert_2_5"); + ("Numeric.float_Add_2_5"); + ("Numeric.float_Mult_2_5"); + ("Numeric.float_Sub_2_5"); + ("Numeric.float_Div_2_5"); + ("Numeric.float_GreaterThan_2_5"); + ("Numeric.float_LessThan_2_5"); + ("Numeric.float_GreaterThanEqual_2_5"); + ("Numeric.float_LessThanEqual_2_5"); + ("Numeric.float_Equal_2_5"); + ("Numeric.float_higher_precision_2_5"); + ("Numeric.float_equal_precision_2_5"); + ("Numeric.float_Convert_2_6"); + ("Numeric.float_Add_2_6"); + ("Numeric.float_Mult_2_6"); + ("Numeric.float_Sub_2_6"); + ("Numeric.float_Div_2_6"); + ("Numeric.float_GreaterThan_2_6"); + ("Numeric.float_LessThan_2_6"); + ("Numeric.float_GreaterThanEqual_2_6"); + ("Numeric.float_LessThanEqual_2_6"); + ("Numeric.float_Equal_2_6"); + ("Numeric.float_higher_precision_2_6"); + ("Numeric.float_equal_precision_2_6"); + ("Numeric.float_Create_3"); + ("Numeric.float_Neg_3"); + ("Numeric.float_is_zero_3"); + ("Numeric.float_is_one_3"); + ("Numeric.float_Convert_3_0"); + ("Numeric.float_Add_3_0"); + ("Numeric.float_Mult_3_0"); + ("Numeric.float_Sub_3_0"); + ("Numeric.float_Div_3_0"); + ("Numeric.float_GreaterThan_3_0"); + ("Numeric.float_LessThan_3_0"); + ("Numeric.float_GreaterThanEqual_3_0"); + ("Numeric.float_LessThanEqual_3_0"); + ("Numeric.float_Equal_3_0"); + ("Numeric.float_higher_precision_3_0"); + ("Numeric.float_equal_precision_3_0"); + ("Numeric.float_Convert_3_1"); + ("Numeric.float_Add_3_1"); + ("Numeric.float_Mult_3_1"); + ("Numeric.float_Sub_3_1"); + ("Numeric.float_Div_3_1"); + ("Numeric.float_GreaterThan_3_1"); + ("Numeric.float_LessThan_3_1"); + ("Numeric.float_GreaterThanEqual_3_1"); + ("Numeric.float_LessThanEqual_3_1"); + ("Numeric.float_Equal_3_1"); + ("Numeric.float_higher_precision_3_1"); + ("Numeric.float_equal_precision_3_1"); + ("Numeric.float_Convert_3_2"); + ("Numeric.float_Add_3_2"); + ("Numeric.float_Mult_3_2"); + ("Numeric.float_Sub_3_2"); + ("Numeric.float_Div_3_2"); + ("Numeric.float_GreaterThan_3_2"); + ("Numeric.float_LessThan_3_2"); + ("Numeric.float_GreaterThanEqual_3_2"); + ("Numeric.float_LessThanEqual_3_2"); + ("Numeric.float_Equal_3_2"); + ("Numeric.float_higher_precision_3_2"); + ("Numeric.float_equal_precision_3_2"); + ("Numeric.float_Convert_3_3"); + ("Numeric.float_Add_3_3"); + ("Numeric.float_Mult_3_3"); + ("Numeric.float_Sub_3_3"); + ("Numeric.float_Div_3_3"); + ("Numeric.float_GreaterThan_3_3"); + ("Numeric.float_LessThan_3_3"); + ("Numeric.float_GreaterThanEqual_3_3"); + ("Numeric.float_LessThanEqual_3_3"); + ("Numeric.float_Equal_3_3"); + ("Numeric.float_higher_precision_3_3"); + ("Numeric.float_equal_precision_3_3"); + ("Numeric.float_Convert_3_4"); + ("Numeric.float_Add_3_4"); + ("Numeric.float_Mult_3_4"); + ("Numeric.float_Sub_3_4"); + ("Numeric.float_Div_3_4"); + ("Numeric.float_GreaterThan_3_4"); + ("Numeric.float_LessThan_3_4"); + ("Numeric.float_GreaterThanEqual_3_4"); + ("Numeric.float_LessThanEqual_3_4"); + ("Numeric.float_Equal_3_4"); + ("Numeric.float_higher_precision_3_4"); + ("Numeric.float_equal_precision_3_4"); + ("Numeric.float_Convert_3_5"); + ("Numeric.float_Add_3_5"); + ("Numeric.float_Mult_3_5"); + ("Numeric.float_Sub_3_5"); + ("Numeric.float_Div_3_5"); + ("Numeric.float_GreaterThan_3_5"); + ("Numeric.float_LessThan_3_5"); + ("Numeric.float_GreaterThanEqual_3_5"); + ("Numeric.float_LessThanEqual_3_5"); + ("Numeric.float_Equal_3_5"); + ("Numeric.float_higher_precision_3_5"); + ("Numeric.float_equal_precision_3_5"); + ("Numeric.float_Convert_3_6"); + ("Numeric.float_Add_3_6"); + ("Numeric.float_Mult_3_6"); + ("Numeric.float_Sub_3_6"); + ("Numeric.float_Div_3_6"); + ("Numeric.float_GreaterThan_3_6"); + ("Numeric.float_LessThan_3_6"); + ("Numeric.float_GreaterThanEqual_3_6"); + ("Numeric.float_LessThanEqual_3_6"); + ("Numeric.float_Equal_3_6"); + ("Numeric.float_higher_precision_3_6"); + ("Numeric.float_equal_precision_3_6"); + ("Numeric.float_Create_4"); + ("Numeric.float_Neg_4"); + ("Numeric.float_is_zero_4"); + ("Numeric.float_is_one_4"); + ("Numeric.float_Convert_4_0"); + ("Numeric.float_Add_4_0"); + ("Numeric.float_Mult_4_0"); + ("Numeric.float_Sub_4_0"); + ("Numeric.float_Div_4_0"); + ("Numeric.float_GreaterThan_4_0"); + ("Numeric.float_LessThan_4_0"); + ("Numeric.float_GreaterThanEqual_4_0"); + ("Numeric.float_LessThanEqual_4_0"); + ("Numeric.float_Equal_4_0"); + ("Numeric.float_higher_precision_4_0"); + ("Numeric.float_equal_precision_4_0"); + ("Numeric.float_Convert_4_1"); + ("Numeric.float_Add_4_1"); + ("Numeric.float_Mult_4_1"); + ("Numeric.float_Sub_4_1"); + ("Numeric.float_Div_4_1"); + ("Numeric.float_GreaterThan_4_1"); + ("Numeric.float_LessThan_4_1"); + ("Numeric.float_GreaterThanEqual_4_1"); + ("Numeric.float_LessThanEqual_4_1"); + ("Numeric.float_Equal_4_1"); + ("Numeric.float_higher_precision_4_1"); + ("Numeric.float_equal_precision_4_1"); + ("Numeric.float_Convert_4_2"); + ("Numeric.float_Add_4_2"); + ("Numeric.float_Mult_4_2"); + ("Numeric.float_Sub_4_2"); + ("Numeric.float_Div_4_2"); + ("Numeric.float_GreaterThan_4_2"); + ("Numeric.float_LessThan_4_2"); + ("Numeric.float_GreaterThanEqual_4_2"); + ("Numeric.float_LessThanEqual_4_2"); + ("Numeric.float_Equal_4_2"); + ("Numeric.float_higher_precision_4_2"); + ("Numeric.float_equal_precision_4_2"); + ("Numeric.float_Convert_4_3"); + ("Numeric.float_Add_4_3"); + ("Numeric.float_Mult_4_3"); + ("Numeric.float_Sub_4_3"); + ("Numeric.float_Div_4_3"); + ("Numeric.float_GreaterThan_4_3"); + ("Numeric.float_LessThan_4_3"); + ("Numeric.float_GreaterThanEqual_4_3"); + ("Numeric.float_LessThanEqual_4_3"); + ("Numeric.float_Equal_4_3"); + ("Numeric.float_higher_precision_4_3"); + ("Numeric.float_equal_precision_4_3"); + ("Numeric.float_Convert_4_4"); + ("Numeric.float_Add_4_4"); + ("Numeric.float_Mult_4_4"); + ("Numeric.float_Sub_4_4"); + ("Numeric.float_Div_4_4"); + ("Numeric.float_GreaterThan_4_4"); + ("Numeric.float_LessThan_4_4"); + ("Numeric.float_GreaterThanEqual_4_4"); + ("Numeric.float_LessThanEqual_4_4"); + ("Numeric.float_Equal_4_4"); + ("Numeric.float_higher_precision_4_4"); + ("Numeric.float_equal_precision_4_4"); + ("Numeric.float_Convert_4_5"); + ("Numeric.float_Add_4_5"); + ("Numeric.float_Mult_4_5"); + ("Numeric.float_Sub_4_5"); + ("Numeric.float_Div_4_5"); + ("Numeric.float_GreaterThan_4_5"); + ("Numeric.float_LessThan_4_5"); + ("Numeric.float_GreaterThanEqual_4_5"); + ("Numeric.float_LessThanEqual_4_5"); + ("Numeric.float_Equal_4_5"); + ("Numeric.float_higher_precision_4_5"); + ("Numeric.float_equal_precision_4_5"); + ("Numeric.float_Convert_4_6"); + ("Numeric.float_Add_4_6"); + ("Numeric.float_Mult_4_6"); + ("Numeric.float_Sub_4_6"); + ("Numeric.float_Div_4_6"); + ("Numeric.float_GreaterThan_4_6"); + ("Numeric.float_LessThan_4_6"); + ("Numeric.float_GreaterThanEqual_4_6"); + ("Numeric.float_LessThanEqual_4_6"); + ("Numeric.float_Equal_4_6"); + ("Numeric.float_higher_precision_4_6"); + ("Numeric.float_equal_precision_4_6"); + ("Numeric.float_Create_5"); + ("Numeric.float_Neg_5"); + ("Numeric.float_is_zero_5"); + ("Numeric.float_is_one_5"); + ("Numeric.float_Convert_5_0"); + ("Numeric.float_Add_5_0"); + ("Numeric.float_Mult_5_0"); + ("Numeric.float_Sub_5_0"); + ("Numeric.float_Div_5_0"); + ("Numeric.float_GreaterThan_5_0"); + ("Numeric.float_LessThan_5_0"); + ("Numeric.float_GreaterThanEqual_5_0"); + ("Numeric.float_LessThanEqual_5_0"); + ("Numeric.float_Equal_5_0"); + ("Numeric.float_higher_precision_5_0"); + ("Numeric.float_equal_precision_5_0"); + ("Numeric.float_Convert_5_1"); + ("Numeric.float_Add_5_1"); + ("Numeric.float_Mult_5_1"); + ("Numeric.float_Sub_5_1"); + ("Numeric.float_Div_5_1"); + ("Numeric.float_GreaterThan_5_1"); + ("Numeric.float_LessThan_5_1"); + ("Numeric.float_GreaterThanEqual_5_1"); + ("Numeric.float_LessThanEqual_5_1"); + ("Numeric.float_Equal_5_1"); + ("Numeric.float_higher_precision_5_1"); + ("Numeric.float_equal_precision_5_1"); + ("Numeric.float_Convert_5_2"); + ("Numeric.float_Add_5_2"); + ("Numeric.float_Mult_5_2"); + ("Numeric.float_Sub_5_2"); + ("Numeric.float_Div_5_2"); + ("Numeric.float_GreaterThan_5_2"); + ("Numeric.float_LessThan_5_2"); + ("Numeric.float_GreaterThanEqual_5_2"); + ("Numeric.float_LessThanEqual_5_2"); + ("Numeric.float_Equal_5_2"); + ("Numeric.float_higher_precision_5_2"); + ("Numeric.float_equal_precision_5_2"); + ("Numeric.float_Convert_5_3"); + ("Numeric.float_Add_5_3"); + ("Numeric.float_Mult_5_3"); + ("Numeric.float_Sub_5_3"); + ("Numeric.float_Div_5_3"); + ("Numeric.float_GreaterThan_5_3"); + ("Numeric.float_LessThan_5_3"); + ("Numeric.float_GreaterThanEqual_5_3"); + ("Numeric.float_LessThanEqual_5_3"); + ("Numeric.float_Equal_5_3"); + ("Numeric.float_higher_precision_5_3"); + ("Numeric.float_equal_precision_5_3"); + ("Numeric.float_Convert_5_4"); + ("Numeric.float_Add_5_4"); + ("Numeric.float_Mult_5_4"); + ("Numeric.float_Sub_5_4"); + ("Numeric.float_Div_5_4"); + ("Numeric.float_GreaterThan_5_4"); + ("Numeric.float_LessThan_5_4"); + ("Numeric.float_GreaterThanEqual_5_4"); + ("Numeric.float_LessThanEqual_5_4"); + ("Numeric.float_Equal_5_4"); + ("Numeric.float_higher_precision_5_4"); + ("Numeric.float_equal_precision_5_4"); + ("Numeric.float_Convert_5_5"); + ("Numeric.float_Add_5_5"); + ("Numeric.float_Mult_5_5"); + ("Numeric.float_Sub_5_5"); + ("Numeric.float_Div_5_5"); + ("Numeric.float_GreaterThan_5_5"); + ("Numeric.float_LessThan_5_5"); + ("Numeric.float_GreaterThanEqual_5_5"); + ("Numeric.float_LessThanEqual_5_5"); + ("Numeric.float_Equal_5_5"); + ("Numeric.float_higher_precision_5_5"); + ("Numeric.float_equal_precision_5_5"); + ("Numeric.float_Convert_5_6"); + ("Numeric.float_Add_5_6"); + ("Numeric.float_Mult_5_6"); + ("Numeric.float_Sub_5_6"); + ("Numeric.float_Div_5_6"); + ("Numeric.float_GreaterThan_5_6"); + ("Numeric.float_LessThan_5_6"); + ("Numeric.float_GreaterThanEqual_5_6"); + ("Numeric.float_LessThanEqual_5_6"); + ("Numeric.float_Equal_5_6"); + ("Numeric.float_higher_precision_5_6"); + ("Numeric.float_equal_precision_5_6"); + ("Numeric.float_Create_6"); + ("Numeric.float_Neg_6"); + ("Numeric.float_is_zero_6"); + ("Numeric.float_is_one_6"); + ("Numeric.float_Convert_6_0"); + ("Numeric.float_Add_6_0"); + ("Numeric.float_Mult_6_0"); + ("Numeric.float_Sub_6_0"); + ("Numeric.float_Div_6_0"); + ("Numeric.float_GreaterThan_6_0"); + ("Numeric.float_LessThan_6_0"); + ("Numeric.float_GreaterThanEqual_6_0"); + ("Numeric.float_LessThanEqual_6_0"); + ("Numeric.float_Equal_6_0"); + ("Numeric.float_higher_precision_6_0"); + ("Numeric.float_equal_precision_6_0"); + ("Numeric.float_Convert_6_1"); + ("Numeric.float_Add_6_1"); + ("Numeric.float_Mult_6_1"); + ("Numeric.float_Sub_6_1"); + ("Numeric.float_Div_6_1"); + ("Numeric.float_GreaterThan_6_1"); + ("Numeric.float_LessThan_6_1"); + ("Numeric.float_GreaterThanEqual_6_1"); + ("Numeric.float_LessThanEqual_6_1"); + ("Numeric.float_Equal_6_1"); + ("Numeric.float_higher_precision_6_1"); + ("Numeric.float_equal_precision_6_1"); + ("Numeric.float_Convert_6_2"); + ("Numeric.float_Add_6_2"); + ("Numeric.float_Mult_6_2"); + ("Numeric.float_Sub_6_2"); + ("Numeric.float_Div_6_2"); + ("Numeric.float_GreaterThan_6_2"); + ("Numeric.float_LessThan_6_2"); + ("Numeric.float_GreaterThanEqual_6_2"); + ("Numeric.float_LessThanEqual_6_2"); + ("Numeric.float_Equal_6_2"); + ("Numeric.float_higher_precision_6_2"); + ("Numeric.float_equal_precision_6_2"); + ("Numeric.float_Convert_6_3"); + ("Numeric.float_Add_6_3"); + ("Numeric.float_Mult_6_3"); + ("Numeric.float_Sub_6_3"); + ("Numeric.float_Div_6_3"); + ("Numeric.float_GreaterThan_6_3"); + ("Numeric.float_LessThan_6_3"); + ("Numeric.float_GreaterThanEqual_6_3"); + ("Numeric.float_LessThanEqual_6_3"); + ("Numeric.float_Equal_6_3"); + ("Numeric.float_higher_precision_6_3"); + ("Numeric.float_equal_precision_6_3"); + ("Numeric.float_Convert_6_4"); + ("Numeric.float_Add_6_4"); + ("Numeric.float_Mult_6_4"); + ("Numeric.float_Sub_6_4"); + ("Numeric.float_Div_6_4"); + ("Numeric.float_GreaterThan_6_4"); + ("Numeric.float_LessThan_6_4"); + ("Numeric.float_GreaterThanEqual_6_4"); + ("Numeric.float_LessThanEqual_6_4"); + ("Numeric.float_Equal_6_4"); + ("Numeric.float_higher_precision_6_4"); + ("Numeric.float_equal_precision_6_4"); + ("Numeric.float_Convert_6_5"); + ("Numeric.float_Add_6_5"); + ("Numeric.float_Mult_6_5"); + ("Numeric.float_Sub_6_5"); + ("Numeric.float_Div_6_5"); + ("Numeric.float_GreaterThan_6_5"); + ("Numeric.float_LessThan_6_5"); + ("Numeric.float_GreaterThanEqual_6_5"); + ("Numeric.float_LessThanEqual_6_5"); + ("Numeric.float_Equal_6_5"); + ("Numeric.float_higher_precision_6_5"); + ("Numeric.float_equal_precision_6_5"); + ("Numeric.float_Convert_6_6"); + ("Numeric.float_Add_6_6"); + ("Numeric.float_Mult_6_6"); + ("Numeric.float_Sub_6_6"); + ("Numeric.float_Div_6_6"); + ("Numeric.float_GreaterThan_6_6"); + ("Numeric.float_LessThan_6_6"); + ("Numeric.float_GreaterThanEqual_6_6"); + ("Numeric.float_LessThanEqual_6_6"); + ("Numeric.float_Equal_6_6"); + ("Numeric.float_higher_precision_6_6"); + ("Numeric.float_equal_precision_6_6")] ;; let user () = - [] - [@@macro] + [("Ipl_functions.model_func_fresh_string'")] ;; [@@@logic] diff --git a/vgs/templates/dune b/vgs/templates/dune index 388f32ea..d1a41d16 100644 --- a/vgs/templates/dune +++ b/vgs/templates/dune @@ -1,7 +1,7 @@ (library - (name templates) - (public_name fix-engine.templates) - (wrapped false) - (flags - (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) - (libraries imandra-prelude venue venue_types)) + (name templates) + (public_name fix-engine.templates) + (wrapped false) + (flags (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) + (libraries imandra-prelude core venue venue_types) +) diff --git a/vgs/templates/scenario.iml b/vgs/templates/scenario.iml index ebc39c7a..be9f383d 100644 --- a/vgs/templates/scenario.iml +++ b/vgs/templates/scenario.iml @@ -1,29 +1,47 @@ -(* Imandra Inc. copyright 2020 *) -[@@@import "../../src-model/src/act_checks.iml"] -open Act_checks;; +(* Imandra Inc. copyright 2021 *) [@@@import "../../src-model/src-types/model_messages.iml"] open Model_messages;; -[@@@import "../../src-model/src/msg_process.iml"] -open Msg_process;; +[@@@import "../../src-core/numeric.iml"] +open Numeric;; [@@@import "scenario_type.iml"] open Scenario_type;; [@@@import "../../src-model/src-types/state.iml"] open State;; [@@@import "template.iml"] open Template;; +[@@@import "../../src-model/src/venue.iml"] +open Venue;; -let is_event_valid (e : event) (s : model_state) : bool = +let mod_state_with_event (e) (s) = (match e with - | Message m -> (is_message_valid m s) - | Action a -> (is_action_valid a s) + | Action a -> { s with + incoming_action = Some a; + incoming_msg = FIX_TL_None + } + | Message m -> { s with + incoming_msg = FIX_TL_Normal m; + incoming_action = None + } ) + [@@macro] +;; + +let is_event_valid (e : event) (s : model_state) : bool = + let e = mod_state_with_event e s + in + is_valid e + [@@macro] [@@macro] ;; +module Scenario_NewOrderFill = struct +end + type region_expander = { - field_projections : string list; - field_printers : (event -> string option) - list; + field_projections : string list list; + field_printers : (event -> (model_state -> string option) + ) + list list; valid_fn : string option; expand_when : string option }[@@program] @@ -35,27 +53,47 @@ type scenario = { description : string option; template : t list; region_expander : region_expander list; - template_attributes : (string*string option) list; - events_attributes : (string*string option) list list + template_attributes : (string*[`Str of string | `Bool of bool | `Int of int | `Float of fix_float] list) list; + events_attributes : (string*[`Str of string | `Bool of bool | `Int of int | `Float of fix_float] list) list list }[@@program] ;; -let scenarios = [] [@@program];; +let scenarios = [({ + id = "NewOrderFill"; + name = Some "NewOrderFill"; + description = Some "Initialise Book State, send NewOrderSingle Message then receive a fill action"; + template = [(Template_bookState);(Template_NewOrderSingle);(Template_fill)]; + region_expander = [({ + field_projections = []; + field_printers = []; + valid_fn = None; + expand_when = None + });({ + field_projections = []; + field_printers = []; + valid_fn = None; + expand_when = None + });({ + field_projections = []; + field_printers = []; + valid_fn = None; + expand_when = None + })]; + template_attributes = []; + events_attributes = [([]);([]);([])] +})] [@@program];; -let mod_state_with_event (e) (s) = - (match e with - | Action a -> { s with - incoming_action = Some a - } - | Message m -> { s with - incoming_msg = FIX_TL_Normal m - } +let field_projection_to_type (x) = + (match x with + | _ -> "" ) + [@@macro] ;; -let field_projection_to_type (x) = +let field_projection_to_name (x) = (match x with | _ -> "" ) [@@macro] ;; + diff --git a/vgs/templates/scenario_type.iml b/vgs/templates/scenario_type.iml index cd21b516..103d9b92 100644 --- a/vgs/templates/scenario_type.iml +++ b/vgs/templates/scenario_type.iml @@ -1,4 +1,4 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@import "../../src-model/src-types/actions.iml"] open Actions;; [@@@import "../../src-model/src-types/model_messages.iml"] @@ -7,5 +7,6 @@ open Model_messages;; type event = | Action of fix_action - | Message of model_msg + | Message of model_msg_opt_def ;; + diff --git a/vgs/templates/template.iml b/vgs/templates/template.iml index d3647845..22af3557 100644 --- a/vgs/templates/template.iml +++ b/vgs/templates/template.iml @@ -1,4 +1,6 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) +[@@@import "../../src-model/src-types/actions.iml"] +open Actions;; [@@@import "../../src-model/src-types/model_messages.iml"] open Model_messages;; [@@@import "scenario_type.iml"] @@ -6,34 +8,45 @@ open Scenario_type;; type t = + | Template_bookState + | Template_NewOrderSingle + | Template_fill | Template_'any ;; let is_incoming (m) = (match m with - | FIX_Msg_NewOrderSingle _ -> true + | FIX_Msg_Def_Opt_NewOrderSingle _ -> true + | FIX_Msg_Def_Opt_ExecutionReport _ -> true | _ -> false ) ;; let data (x : t) = (match x with + | Template_bookState -> "Model_records.m_action_fix_bookstate" + | Template_NewOrderSingle -> "Model_messages.mod_newordersingle_defopt_data" + | Template_fill -> "Model_records.m_action_fix_fill" | Template_'any -> "'any" ) - [@@macro] ;; let concrete (x : t) (c : event) = (match (x,c) with - | (Template_'any,Action _) -> true - | (Template_'any,Message m) -> (is_incoming m) + | (Template_bookState,Action FIX_Action_bookState _) -> true + | (Template_NewOrderSingle,Message FIX_Msg_Def_Opt_NewOrderSingle _) -> true + | (Template_fill,Action FIX_Action_fill _) -> true | _ -> false ) + [@@macro] ;; let to_string_hum (x : t) = (match x with + | Template_bookState -> "bookState" + | Template_NewOrderSingle -> "NewOrderSingle" + | Template_fill -> "fill" | Template_'any -> "Any event" ) - [@@macro] ;; + diff --git a/vgs/templates/validation_functions.iml b/vgs/templates/validation_functions.iml index 61afa7b1..30bf4c44 100644 --- a/vgs/templates/validation_functions.iml +++ b/vgs/templates/validation_functions.iml @@ -1,10 +1,23 @@ -(* Imandra Inc. copyright 2020 *) +(* Imandra Inc. copyright 2021 *) [@@@program] let validation_functions = + [(("Msg_check_fields.check_field_mod_f_NewOrderSingle_ClOrdID","Field ClOrdID of Message NewOrderSingle violates the constraint: \" it != (Some \"N/A\")\"")); + (("Msg_check_fields.check_field_mod_f_NewOrderSingle_OrdType","Field OrdType of Message NewOrderSingle violates the constraint: \" it in [ OrdType.Limit, OrdType.Market, StopSpread ]\"")); + (("Msg_check_fields.check_field_mod_f_NewOrderSingle_SpreadProportion","Field SpreadProportion of Message NewOrderSingle violates the constraint: \" case(it){None:true}{Some x: x>0.0 && x<=1.0}\"")); + (("Msg_check_fields.check_field_mod_f_NewOrderSingle_Parties","Field Parties of Message NewOrderSingle violates the constraint: \" it.PartyIndex > 0 && it.PartyIndex < 100\"")); + (("Msg_check_fields.check_field_mod_f_NewOrderSingle_Parties","Field Parties of Message NewOrderSingle violates the constraint: \" it.PartyID != \"N/A\"\"")); + (("Msg_check_validate.validate_NewOrderSingle_0","Message NewOrderSingle violates the constraint \"\n (this.OrdType == OrdType.Market <==> !present(this.Price)) &&\n (this.OrdType == OrdType.Limit ==> present(this.Price)) &&\n (this.OrdType == OrdType.StopSpread ==> present(this.Price))\"")); + (("Msg_check_validate.validate_NewOrderSingle_1","Message NewOrderSingle violates the constraint \"\n this.OrdType == StopSpread <==>\n present(this.SpreadProportion)\"")); + (("Msg_check_validate.validate_NewOrderSingle_2","Message NewOrderSingle violates the constraint \"\n this.OrdType != OrdType.Market ==>\n (case this.Price\n {Some price: price > 0.0}\n {None: false}\n )\"")); + (("Msg_check_validate.validate_NewOrderSingle_3","Message NewOrderSingle violates the constraint \"\n case(this.Parties.PtysSubGrp.PartySubID)\n {None:true}\n {Some x : this.Parties.PartyID != x}\"")); + (("Act_checks.is_valid_action_fill","\n state.OrdStatus != OrdStatus.PendingNew and \n this.fill_qty > 0.0 and \n this.fill_qty <= state.LeavesQty and \n this.fill_price > 0.0 and \n if ( state.Side == Side.Buy )\n then ( this.fill_price >= state.bestAsk )\n else ( this.fill_price <= state.bestBid ) and \n (state.OrdType != OrdType.Market) ==>\n ( case state.Price\n { Some p:\n if ( state.Side == Side.Buy ) then\n ( this.fill_price <= p )\n else ( this.fill_price >= p )\n }\n { None: true }\n )")); + (("Act_checks.is_valid_action_bookState","\n this.bestAsk > this.bestBid &&\n this.bestBid > 0.0 &&\n this.bestAsk > 0.0"))] +;; + +let exclude_functions = [] - [@@macro] ;; [@@@logic] From 7ead8f15b113eb7d85f18967a340db8f074797d6 Mon Sep 17 00:00:00 2001 From: Ewen Maclean Date: Thu, 8 Apr 2021 16:47:58 +0100 Subject: [PATCH 4/9] adding missing new helper functions --- .../ambiguous_default_funcs.iml | 17 +++++++++++++++++ src-model/src-helper-functions/dune | 7 +++++++ 2 files changed, 24 insertions(+) create mode 100644 src-model/src-helper-functions/ambiguous_default_funcs.iml create mode 100644 src-model/src-helper-functions/dune diff --git a/src-model/src-helper-functions/ambiguous_default_funcs.iml b/src-model/src-helper-functions/ambiguous_default_funcs.iml new file mode 100644 index 00000000..587d4680 --- /dev/null +++ b/src-model/src-helper-functions/ambiguous_default_funcs.iml @@ -0,0 +1,17 @@ +(* Imandra Inc. copyright 2021 *) +[@@@import "../src-types/model_app_enums.iml"] +open Model_app_enums;; + + +let amb_func_execinst_set (y : model_fix_execinst Set.t) (x : model_fix_execinst Set.t option) : model_fix_execinst Set.t = + (match x with + | None -> y + | Some d -> d + ) +;; + +let ambiguous_default_names () = + [("Ambiguous_default_funcs.amb_func_execinst_set")] + [@@macro] +;; + diff --git a/src-model/src-helper-functions/dune b/src-model/src-helper-functions/dune new file mode 100644 index 00000000..512fb054 --- /dev/null +++ b/src-model/src-helper-functions/dune @@ -0,0 +1,7 @@ +(library + (name venue_helper_functions) + (public_name fix-engine.venue_helper_functions) + (wrapped false) + (flags (:standard -open Imandra_prelude -warn-error -A+8+39 -alert -deprecated -w -33-58)) + (libraries imandra-prelude venue_types) +) From 361e2dbf3fea6ee7a135842cc3243a06dcc1ba58 Mon Sep 17 00:00:00 2001 From: Ewen Maclean Date: Thu, 8 Apr 2021 17:18:25 +0100 Subject: [PATCH 5/9] wip: updating admin decoders for logon/logoff --- src-model/src/ipl_rg_functions.iml | 75 ++++++++ src-model/src/msg_minimal_invalid.iml | 164 ++++++++++++++++++ .../full_admin_messages_decoder.iml | 61 ++++--- src-protocol-pp/full_admin_messages_json.iml | 4 +- 4 files changed, 280 insertions(+), 24 deletions(-) create mode 100644 src-model/src/ipl_rg_functions.iml create mode 100644 src-model/src/msg_minimal_invalid.iml diff --git a/src-model/src/ipl_rg_functions.iml b/src-model/src/ipl_rg_functions.iml new file mode 100644 index 00000000..89b1126a --- /dev/null +++ b/src-model/src/ipl_rg_functions.iml @@ -0,0 +1,75 @@ +(* Imandra Inc. copyright 2021 *) +[@@@import "../src-types/model_repeating_groups.iml"] +open Model_repeating_groups;; + + +let rg_forall_fun_Parties (arg_vr : model_fix_rec_parties) (arg_hof : (model_fix_inner_parties -> bool) +) (arg_last_calc : bool) : bool = + (&&) (let c_0lambd_v = arg_vr.rg_Parties_element_0 + in + (match c_0lambd_v with + | None -> true + | Some c_innerc_0lambd_v -> (arg_hof c_innerc_0lambd_v) + ) + ) ((&&) (let c_1lambd_v = arg_vr.rg_Parties_element_1 + in + (match c_1lambd_v with + | None -> true + | Some c_innerc_1lambd_v -> (arg_hof c_innerc_1lambd_v) + ) + ) ((&&) (let c_2lambd_v = arg_vr.rg_Parties_element_2 + in + (match c_2lambd_v with + | None -> true + | Some c_innerc_2lambd_v -> (arg_hof c_innerc_2lambd_v) + ) + ) ((&&) (let c_3lambd_v = arg_vr.rg_Parties_element_3 + in + (match c_3lambd_v with + | None -> true + | Some c_innerc_3lambd_v -> (arg_hof c_innerc_3lambd_v) + ) + ) (let c_5lambd_v = arg_vr.rg_Parties_element_4 + in + (match c_5lambd_v with + | None -> arg_last_calc + | Some c_innerc_5lambd_v -> (arg_hof c_innerc_5lambd_v) + ) + )))) +;; + +let rg_forall_fun_PtysSubGrp (arg_vr : model_fix_rec_ptyssubgrp) (arg_hof : (model_fix_inner_ptyssubgrp -> bool) +) (arg_last_calc : bool) : bool = + (&&) (let c_0lambd_v = arg_vr.rg_PtysSubGrp_element_0 + in + (match c_0lambd_v with + | None -> true + | Some c_innerc_0lambd_v -> (arg_hof c_innerc_0lambd_v) + ) + ) ((&&) (let c_1lambd_v = arg_vr.rg_PtysSubGrp_element_1 + in + (match c_1lambd_v with + | None -> true + | Some c_innerc_1lambd_v -> (arg_hof c_innerc_1lambd_v) + ) + ) ((&&) (let c_2lambd_v = arg_vr.rg_PtysSubGrp_element_2 + in + (match c_2lambd_v with + | None -> true + | Some c_innerc_2lambd_v -> (arg_hof c_innerc_2lambd_v) + ) + ) ((&&) (let c_3lambd_v = arg_vr.rg_PtysSubGrp_element_3 + in + (match c_3lambd_v with + | None -> true + | Some c_innerc_3lambd_v -> (arg_hof c_innerc_3lambd_v) + ) + ) (let c_5lambd_v = arg_vr.rg_PtysSubGrp_element_4 + in + (match c_5lambd_v with + | None -> arg_last_calc + | Some c_innerc_5lambd_v -> (arg_hof c_innerc_5lambd_v) + ) + )))) +;; + diff --git a/src-model/src/msg_minimal_invalid.iml b/src-model/src/msg_minimal_invalid.iml new file mode 100644 index 00000000..c15062dc --- /dev/null +++ b/src-model/src/msg_minimal_invalid.iml @@ -0,0 +1,164 @@ +(* Imandra Inc. copyright 2021 *) +[@@@import "../src-types/model_messages.iml"] +open Model_messages;; +[@@@import "msg_check_fields.iml"] +open Msg_check_fields;; +[@@@import "msg_check_types.iml"] +open Msg_check_types;; +[@@@import "msg_check_validate.iml"] +open Msg_check_validate;; +[@@@import "../src-types/state.iml"] +open State;; + + +let check_fields_minimal_invalid_NewOrderSingle_0 (msg_data : mod_newordersingle_data) (m_state : model_state) : bool = + let mod_f_NewOrderSingle_Parties_result = check_field_mod_f_NewOrderSingle_Parties msg_data m_state + in + let mod_f_NewOrderSingle_SpreadProportion_result = check_field_mod_f_NewOrderSingle_SpreadProportion msg_data m_state + in + let mod_f_NewOrderSingle_OrdType_result = check_field_mod_f_NewOrderSingle_OrdType msg_data m_state + in + let mod_f_NewOrderSingle_ClOrdID_result = check_field_mod_f_NewOrderSingle_ClOrdID msg_data m_state + in + (&&) ((&&) ((&&) mod_f_NewOrderSingle_ClOrdID_result.field_invalid_defrej (not mod_f_NewOrderSingle_OrdType_result.field_invalid_defrej)) (not mod_f_NewOrderSingle_SpreadProportion_result.field_invalid_defrej)) (not mod_f_NewOrderSingle_Parties_result.field_invalid_defrej) +;; + +let check_fields_minimal_invalid_NewOrderSingle_1 (msg_data : mod_newordersingle_data) (m_state : model_state) : bool = + let mod_f_NewOrderSingle_Parties_result = check_field_mod_f_NewOrderSingle_Parties msg_data m_state + in + let mod_f_NewOrderSingle_SpreadProportion_result = check_field_mod_f_NewOrderSingle_SpreadProportion msg_data m_state + in + let mod_f_NewOrderSingle_OrdType_result = check_field_mod_f_NewOrderSingle_OrdType msg_data m_state + in + let mod_f_NewOrderSingle_ClOrdID_result = check_field_mod_f_NewOrderSingle_ClOrdID msg_data m_state + in + (&&) ((&&) ((&&) mod_f_NewOrderSingle_OrdType_result.field_invalid_defrej (not mod_f_NewOrderSingle_ClOrdID_result.field_invalid_defrej)) (not mod_f_NewOrderSingle_SpreadProportion_result.field_invalid_defrej)) (not mod_f_NewOrderSingle_Parties_result.field_invalid_defrej) +;; + +let check_fields_minimal_invalid_NewOrderSingle_2 (msg_data : mod_newordersingle_data) (m_state : model_state) : bool = + let mod_f_NewOrderSingle_Parties_result = check_field_mod_f_NewOrderSingle_Parties msg_data m_state + in + let mod_f_NewOrderSingle_SpreadProportion_result = check_field_mod_f_NewOrderSingle_SpreadProportion msg_data m_state + in + let mod_f_NewOrderSingle_OrdType_result = check_field_mod_f_NewOrderSingle_OrdType msg_data m_state + in + let mod_f_NewOrderSingle_ClOrdID_result = check_field_mod_f_NewOrderSingle_ClOrdID msg_data m_state + in + (&&) ((&&) ((&&) mod_f_NewOrderSingle_SpreadProportion_result.field_invalid_defrej (not mod_f_NewOrderSingle_ClOrdID_result.field_invalid_defrej)) (not mod_f_NewOrderSingle_OrdType_result.field_invalid_defrej)) (not mod_f_NewOrderSingle_Parties_result.field_invalid_defrej) +;; + +let check_fields_minimal_invalid_NewOrderSingle_3 (msg_data : mod_newordersingle_data) (m_state : model_state) : bool = + let mod_f_NewOrderSingle_Parties_result = check_field_mod_f_NewOrderSingle_Parties msg_data m_state + in + let mod_f_NewOrderSingle_SpreadProportion_result = check_field_mod_f_NewOrderSingle_SpreadProportion msg_data m_state + in + let mod_f_NewOrderSingle_OrdType_result = check_field_mod_f_NewOrderSingle_OrdType msg_data m_state + in + let mod_f_NewOrderSingle_ClOrdID_result = check_field_mod_f_NewOrderSingle_ClOrdID msg_data m_state + in + (&&) ((&&) ((&&) mod_f_NewOrderSingle_Parties_result.field_invalid_defrej (not mod_f_NewOrderSingle_ClOrdID_result.field_invalid_defrej)) (not mod_f_NewOrderSingle_OrdType_result.field_invalid_defrej)) (not mod_f_NewOrderSingle_SpreadProportion_result.field_invalid_defrej) +;; + +let check_fields_minimal_invalid_NewOrderSingle (msg_data : mod_newordersingle_data) (m_state : model_state) : bool = + let mod_f_NewOrderSingle_Parties_result = check_field_mod_f_NewOrderSingle_Parties msg_data m_state + in + let mod_f_NewOrderSingle_SpreadProportion_result = check_field_mod_f_NewOrderSingle_SpreadProportion msg_data m_state + in + let mod_f_NewOrderSingle_OrdType_result = check_field_mod_f_NewOrderSingle_OrdType msg_data m_state + in + let mod_f_NewOrderSingle_ClOrdID_result = check_field_mod_f_NewOrderSingle_ClOrdID msg_data m_state + in + (||) ((&&) (check_fields_minimal_invalid_NewOrderSingle_3 msg_data m_state) mod_f_NewOrderSingle_Parties_result.field_invalid_defrej) ((||) ((&&) (check_fields_minimal_invalid_NewOrderSingle_2 msg_data m_state) mod_f_NewOrderSingle_SpreadProportion_result.field_invalid_defrej) ((||) ((&&) (check_fields_minimal_invalid_NewOrderSingle_1 msg_data m_state) mod_f_NewOrderSingle_OrdType_result.field_invalid_defrej) ((&&) (check_fields_minimal_invalid_NewOrderSingle_0 msg_data m_state) mod_f_NewOrderSingle_ClOrdID_result.field_invalid_defrej))) +;; + +let check_fields_minimal_invalid_ExecutionReport (msg_data : mod_executionreport_data) (m_state : model_state) : bool = + false +;; + +let check_validate_minimal_invalid_NewOrderSingle_0 (msg_data : mod_newordersingle_data) (m_state : model_state) : bool = + let cust_rest3 = validate_NewOrderSingle_3 msg_data m_state + in + let cust_rest2 = validate_NewOrderSingle_2 msg_data m_state + in + let cust_rest1 = validate_NewOrderSingle_1 msg_data m_state + in + let cust_rest0 = validate_NewOrderSingle_0 msg_data m_state + in + (&&) ((&&) ((&&) cust_rest0.validate_invalid_defrej (not cust_rest1.validate_invalid_defrej)) (not cust_rest2.validate_invalid_defrej)) (not cust_rest3.validate_invalid_defrej) +;; + +let check_validate_minimal_invalid_NewOrderSingle_1 (msg_data : mod_newordersingle_data) (m_state : model_state) : bool = + let cust_rest3 = validate_NewOrderSingle_3 msg_data m_state + in + let cust_rest2 = validate_NewOrderSingle_2 msg_data m_state + in + let cust_rest1 = validate_NewOrderSingle_1 msg_data m_state + in + let cust_rest0 = validate_NewOrderSingle_0 msg_data m_state + in + (&&) ((&&) ((&&) cust_rest1.validate_invalid_defrej (not cust_rest0.validate_invalid_defrej)) (not cust_rest2.validate_invalid_defrej)) (not cust_rest3.validate_invalid_defrej) +;; + +let check_validate_minimal_invalid_NewOrderSingle_2 (msg_data : mod_newordersingle_data) (m_state : model_state) : bool = + let cust_rest3 = validate_NewOrderSingle_3 msg_data m_state + in + let cust_rest2 = validate_NewOrderSingle_2 msg_data m_state + in + let cust_rest1 = validate_NewOrderSingle_1 msg_data m_state + in + let cust_rest0 = validate_NewOrderSingle_0 msg_data m_state + in + (&&) ((&&) ((&&) cust_rest2.validate_invalid_defrej (not cust_rest0.validate_invalid_defrej)) (not cust_rest1.validate_invalid_defrej)) (not cust_rest3.validate_invalid_defrej) +;; + +let check_validate_minimal_invalid_NewOrderSingle_3 (msg_data : mod_newordersingle_data) (m_state : model_state) : bool = + let cust_rest3 = validate_NewOrderSingle_3 msg_data m_state + in + let cust_rest2 = validate_NewOrderSingle_2 msg_data m_state + in + let cust_rest1 = validate_NewOrderSingle_1 msg_data m_state + in + let cust_rest0 = validate_NewOrderSingle_0 msg_data m_state + in + (&&) ((&&) ((&&) cust_rest3.validate_invalid_defrej (not cust_rest0.validate_invalid_defrej)) (not cust_rest1.validate_invalid_defrej)) (not cust_rest2.validate_invalid_defrej) +;; + +let check_validate_minimal_invalid_NewOrderSingle (msg_data : mod_newordersingle_data) (m_state : model_state) : bool = + let cust_rest3 = validate_NewOrderSingle_3 msg_data m_state + in + let cust_rest2 = validate_NewOrderSingle_2 msg_data m_state + in + let cust_rest1 = validate_NewOrderSingle_1 msg_data m_state + in + let cust_rest0 = validate_NewOrderSingle_0 msg_data m_state + in + (||) ((&&) (check_validate_minimal_invalid_NewOrderSingle_3 msg_data m_state) cust_rest3.validate_invalid_defrej) ((||) ((&&) (check_validate_minimal_invalid_NewOrderSingle_2 msg_data m_state) cust_rest2.validate_invalid_defrej) ((||) ((&&) (check_validate_minimal_invalid_NewOrderSingle_1 msg_data m_state) cust_rest1.validate_invalid_defrej) ((&&) (check_validate_minimal_invalid_NewOrderSingle_0 msg_data m_state) cust_rest0.validate_invalid_defrej))) +;; + +let check_validate_minimal_invalid_ExecutionReport (msg_data : mod_executionreport_data) (m_state : model_state) : bool = + false +;; + +let msg_NewOrderSingle_minimal_invalid (msg_data : mod_newordersingle_data) (m_state : model_state) : bool = + let fields_invalid = check_fields_minimal_invalid_NewOrderSingle msg_data m_state + in + let validates_invalid = check_validate_minimal_invalid_NewOrderSingle msg_data m_state + in + (||) ((&&) fields_invalid (not validates_invalid)) ((&&) validates_invalid (not fields_invalid)) +;; + +let msg_ExecutionReport_minimal_invalid (msg_data : mod_executionreport_data) (m_state : model_state) : bool = + let fields_invalid = check_fields_minimal_invalid_ExecutionReport msg_data m_state + in + let validates_invalid = check_validate_minimal_invalid_ExecutionReport msg_data m_state + in + (||) ((&&) fields_invalid (not validates_invalid)) ((&&) validates_invalid (not fields_invalid)) +;; + +let is_message_minimal_invalid (msg : model_msg) (m_state : model_state) : bool = + (match msg with + | FIX_Msg_NewOrderSingle d -> (msg_NewOrderSingle_minimal_invalid d m_state) + | FIX_Msg_ExecutionReport d -> (msg_ExecutionReport_minimal_invalid d m_state) + ) +;; + diff --git a/src-protocol-pp/full_admin_messages_decoder.iml b/src-protocol-pp/full_admin_messages_decoder.iml index 13250056..25bf46ed 100644 --- a/src-protocol-pp/full_admin_messages_decoder.iml +++ b/src-protocol-pp/full_admin_messages_decoder.iml @@ -24,32 +24,49 @@ let full_msg_types_inner_rg_decoder : full_msg_types_inner_rg D.decoder = let open D in field "mtps_ref_msg_type" full_msg_tag_of_json >>= fun mtps_ref_msg_type -> field "mtps_direction" full_admin_enum_fix_msgdirection_decoder >>= fun mtps_direction -> - D.succeed {mtps_ref_msg_type;mtps_direction} -;; -(* -(** *) -let full_msg_logon_to_json x = - [ ( "EncryptMethod" , encryption_method_to_json x.ln_encrypt_method ) - ; ( "HeartBtInt" , duration_to_json x.ln_heartbeat_interval ) - ; ( "RawDataLength" , int_opt_to_json x.ln_raw_data_length ) - ; ( "RawData" , string_opt_to_json x.ln_raw_data ) - ; ( "ResetSeqNumFlag" , bool_opt_to_json x.ln_reset_seq_num_flag ) - ; ( "NextExpectedMsgSeqNum", int_opt_to_json x.ln_next_expected_msg_seq_num ) - ; ( "MaxMessageSize" , int_opt_to_json x.ln_max_message_size ) - ; ( "TestMessageIndicator" , bool_opt_to_json x.ln_test_message_indicator ) - ; ( "Username" , string_opt_to_json x.ln_username ) - ; ( "Password" , string_opt_to_json x.ln_password ) - ; ( "MsgTypes" , rg msg_type_to_json x.ln_msg_types ) - ] |> assoc_filter_nulls + D.succeed {mtps_ref_msg_type;mtps_direction} ;; -(** *) -let full_msg_logoff_to_json x = - [ ( "EncodedText" , int_opt_to_json x.lo_encoded_text_len ) - ; ( "EncodedTextLen" , string_opt_to_json x.lo_encoded_text ) - ] |> assoc_filter_nulls +let full_msg_logon_decoder : full_msg_logon_data D.decoder = + let open D in + field "EncryptMethod" full_admin_enum_fix_encryption_method_decoder >>= fun ln_encrypt_method -> + field "HeartBtInt" duration_decoder >>= fun ln_heartbeat_interval -> + maybe (field "RawDataLength" int_decoder) >>= fun ln_raw_data_length -> + maybe (field "RawData" string) >>= fun ln_raw_data -> + maybe (field "ResetSeqNumFlag" bool) >>= fun ln_reset_seq_num_flag -> + maybe (field "NextExpectedMsgSeqNum" int) >>= fun ln_next_expected_msg_seq_num -> + maybe (field "MaxMessageSize" int) >>= fun ln_max_message_size -> + maybe (field "TestMessageIndicator" bool) >>= fun ln_test_message_indicator -> + maybe (field "Username" string) >>= fun ln_username -> + maybe (field "Password" string) >>= fun ln_password -> + list (field "MsgTypes" full_msg_types_inner_rg_decoder) >>= fun ln_msg_types -> + D.succeed { + ln_encrypt_method + ; ln_heartbeat_interval + ; ln_raw_data_length + ; ln_raw_data + ; ln_reset_seq_num_flag + ; ln_next_expected_msg_seq_num = Option.map Z.of_int ln_next_expected_msg_seq_num + ; ln_max_message_size = Option.map Z.of_int ln_max_message_size + ; ln_test_message_indicator + ; ln_username + ; ln_password + ; ln_msg_types + } + +let full_msg_logoff_decoder : full_msg_logoff_data D.decoder = + let open D in + (maybe (field "EncodedTextLen" int)) >>= fun lo_encoded_text_len -> + (maybe (field "EncodedText" string)) >>= fun lo_encoded_text -> + D.succeed { + lo_encoded_text_len = Option.map Z.of_int lo_encoded_text_len + ; lo_encoded_text + } + ;; +(* + (** *) let full_msg_resend_request_to_json x = [ ( "BeginSeqNo", int_to_json x.rr_begin_seq_num ) diff --git a/src-protocol-pp/full_admin_messages_json.iml b/src-protocol-pp/full_admin_messages_json.iml index 9c750cfb..3a95a8b9 100644 --- a/src-protocol-pp/full_admin_messages_json.iml +++ b/src-protocol-pp/full_admin_messages_json.iml @@ -60,8 +60,8 @@ let full_msg_logon_to_json x = (** *) let full_msg_logoff_to_json x = - [ ( "EncodedText" , int_opt_to_json x.lo_encoded_text_len ) - ; ( "EncodedTextLen" , string_opt_to_json x.lo_encoded_text ) + [ ( "EncodedTextLen" , int_opt_to_json x.lo_encoded_text_len ) + ; ( "EncodedText" , string_opt_to_json x.lo_encoded_text ) ] |> assoc_filter_nulls ;; From ada1414b1238c369f4af42470624930df262356e Mon Sep 17 00:00:00 2001 From: Ewen Maclean Date: Thu, 8 Apr 2021 20:12:05 +0100 Subject: [PATCH 6/9] Adding top level msg decoder --- .../time_defaults_json.iml | 5 + src-protocol-pp/encode_full_messages.iml | 2 +- src-protocol-pp/full_admin_enums_decoder.iml | 6 +- .../full_admin_messages_decoder.iml | 130 ++++++++----- src-protocol-pp/full_message_tags_decoder.iml | 2 +- src-protocol-pp/full_messages_decoder.iml | 174 ++++++++++++++++++ src-protocol-pp/full_messages_json.iml | 17 +- src-protocol-pp/parse_full_messages.iml | 4 +- src-protocol/full_messages.iml | 2 +- src/fix_engine_utils.iml | 2 +- 10 files changed, 278 insertions(+), 66 deletions(-) create mode 100644 src-protocol-pp/full_messages_decoder.iml diff --git a/src-core-time-defaults-pp/time_defaults_json.iml b/src-core-time-defaults-pp/time_defaults_json.iml index fa81798d..e950ab25 100644 --- a/src-core-time-defaults-pp/time_defaults_json.iml +++ b/src-core-time-defaults-pp/time_defaults_json.iml @@ -18,4 +18,9 @@ let utctimestamp_opt_to_json = utctimestamp_milli_opt_to_json;; let utctimeonly_to_json = utctimeonly_milli_to_json;; let utctimeonly_opt_to_json = utctimeonly_milli_opt_to_json;; + +let utctimestamp_decoder = utctimestamp_milli_decoder;; + +let utctimeonly_decoder = utctimeonly_milli_decoder;; + [@@@logic] diff --git a/src-protocol-pp/encode_full_messages.iml b/src-protocol-pp/encode_full_messages.iml index e3e44d01..001a491d 100644 --- a/src-protocol-pp/encode_full_messages.iml +++ b/src-protocol-pp/encode_full_messages.iml @@ -56,7 +56,7 @@ let encode_header msg_tag msg = ; ( "122" , opt encode_UTCTimestamp msg.h_orig_sending_time ) ; ( "212" , opt encode_int msg.h_xml_data_len ) ; ( "213" , opt encode_int msg.h_xml_data ) - ; ( "347" , opt encode_int msg.h_message_enconding ) + ; ( "347" , opt encode_int msg.h_message_encoding ) ; ( "369" , opt encode_int msg.h_last_msg_seq_num_processed ) ; ( "627" , opt encode_int msg.h_no_hops ) ] diff --git a/src-protocol-pp/full_admin_enums_decoder.iml b/src-protocol-pp/full_admin_enums_decoder.iml index b80af6e3..9a1c4f9e 100644 --- a/src-protocol-pp/full_admin_enums_decoder.iml +++ b/src-protocol-pp/full_admin_enums_decoder.iml @@ -6,7 +6,7 @@ open Full_admin_enums;; module D = Decoders_yojson.Basic.Decode -let string_to_execinst_opt = +let string_to_fix_session_reject_reason_opt = function | "InvalidTagNumber" -> Some InvalidTagNumber | "RequiredTagMissing" -> Some RequiredTagMissing @@ -29,9 +29,9 @@ let string_to_execinst_opt = | _ -> None ;; -let full_admin_enum_execinst_decoder : fix_session_reject_reason D.decoder = +let full_admin_enum_fix_session_reject_reason_decoder : fix_session_reject_reason D.decoder = let open D in - string >>= fun x -> match string_to_execinst_opt x with + string >>= fun x -> match string_to_fix_session_reject_reason_opt x with | None -> fail "Unknown enum (fix_session_reject_reason) encoding." | Some y -> succeed y ;; diff --git a/src-protocol-pp/full_admin_messages_decoder.iml b/src-protocol-pp/full_admin_messages_decoder.iml index 25bf46ed..134b0b37 100644 --- a/src-protocol-pp/full_admin_messages_decoder.iml +++ b/src-protocol-pp/full_admin_messages_decoder.iml @@ -62,65 +62,97 @@ let full_msg_logoff_decoder : full_msg_logoff_data D.decoder = lo_encoded_text_len = Option.map Z.of_int lo_encoded_text_len ; lo_encoded_text } - ;; -(* - -(** *) -let full_msg_resend_request_to_json x = - [ ( "BeginSeqNo", int_to_json x.rr_begin_seq_num ) - ; ( "EndSeqNo" , int_to_json x.rr_end_seq_num ) - ] |> assoc_filter_nulls +let full_msg_resent_request_decoder : full_msg_resend_request_data D.decoder = + let open D in + field "BeginSeqNo" int >>= fun rr_begin_seq_num -> + field "EndSeqNo" int >>= fun rr_end_seq_num -> + D.succeed { + rr_begin_seq_num = Z.of_int rr_begin_seq_num; + rr_end_seq_num = Z.of_int rr_end_seq_num + } ;; -(** *) -let full_msg_reject_to_json x = - [ ( "RefSeqNum" , int_to_json x.sr_ref_seq_num ) - ; ( "RefTagID" , full_field_tag_opt_to_json x.sr_ref_tag_id ) - ; ( "RefMsgType" , full_msg_tag_opt_to_json x.sr_ref_msg_type ) - ; ( "SessionRejectReason" , session_reject_reason_opt_to_json x.sr_session_reject_reason ) - ; ( "Text" , string_opt_to_json x.sr_text ) - ; ( "EncodedTextLen" , int_opt_to_json x.sr_encoded_text_len ) - ; ( "EncodedText" , string_opt_to_json x.sr_encoded_text ) - ] |> assoc_filter_nulls +let full_msg_reject_decoder : full_msg_reject_data D.decoder = + let open D in + field "RefSeqNum" int >>= fun sr_ref_seq_num -> + maybe (field "RefTagID" full_field_tag_of_json) >>= fun sr_ref_tag_id -> + maybe (field "RefMsgType" full_msg_tag_of_json) >>= fun sr_ref_msg_type -> + maybe (field "SessionRejectReason" full_admin_enum_fix_session_reject_reason_decoder) >>= fun sr_session_reject_reason -> + maybe (field "Text" string) >>= fun sr_text -> + maybe (field "EncodedTextLen" int) >>= fun sr_encoded_text_len -> + maybe (field "EncodedText" string) >>= fun sr_encoded_text -> + D.succeed + { sr_ref_seq_num = Z.of_int sr_ref_seq_num + ; sr_ref_tag_id + ; sr_ref_msg_type + ; sr_session_reject_reason + ; sr_text + ; sr_encoded_text_len = Option.map Z.of_int sr_encoded_text_len + ; sr_encoded_text + } ;; -(** *) -let full_msg_sequence_reset_to_json x = - [ ( "Sequence_Reset_GapFillFlag" , int_to_json x.seqr_new_seq_no ) - ; ( "Sequence_Reset_NewSeqNo" , gapFillFlag_opt_to_json x.seqr_gap_fill_flag ) - ] |> assoc_filter_nulls +let full_msg_sequence_reset_decoder : full_msg_sequence_reset_data D.decoder = + let open D in + field "Sequence_Reset_GapFillFlag" int >>= fun seqr_new_seq_no -> + maybe (field "Sequence_Reset_NewSeqNo" full_admin_enum_fix_gapfillflag_decoder) + >>= fun seqr_gap_fill_flag -> + D.succeed { + seqr_new_seq_no = Z.of_int seqr_new_seq_no + ; seqr_gap_fill_flag + } ;; -(** *) -let full_msg_test_request_to_json x = - [ ( "Test_Request_TestReqID_Tag" , string_to_json x.test_req_id ) - ] |> assoc_filter_nulls +let full_msg_test_request_decoder : full_msg_test_request_data D.decoder = + let open D in + field "Test_Request_TestReqID_Tag" string >>= fun test_req_id -> + D.succeed {test_req_id} ;; -(** *) -let full_msg_business_reject_to_json x = - [ ( "RefSeqNum" , int_to_json x.br_ref_seq_num ) - ; ( "RefMsgType" , full_msg_tag_to_json x.br_ref_msg_type ) - ; ( "BusinessRejectRefID" , full_field_tag_opt_to_json x.br_ref_field_id ) - ; ( "BusinessRejectReason" , business_reject_reason_to_json x.br_business_reject_reason) - ; ( "Text" , string_opt_to_json x.br_text ) - ; ( "EncodedTextLen" , int_opt_to_json x.br_encoded_text_len ) - ; ( "EncodedText" , string_opt_to_json x.br_encoded_text ) - ] |> assoc_filter_nulls +let full_msg_business_reject_decoder : full_msg_business_reject_data D.decoder = + let open D in + field "RefSeqNum" int >>= fun br_ref_seq_num -> + field "RefMsgType" full_msg_tag_of_json >>= fun br_ref_msg_type -> + maybe (field "BusinessRejectRefID" full_field_tag_of_json) >>= fun br_ref_field_id -> + field "BusinessRejectReason" full_admin_enum_fix_business_reject_reason_decoder >>= + fun br_business_reject_reason -> + maybe (field "Text" string) >>= fun br_text -> + maybe (field "EncodedTextLen" int) >>= fun br_encoded_text_len -> + maybe (field "EncodedText" string) >>= fun br_encoded_text -> + D.succeed { + br_ref_seq_num = Z.of_int br_ref_seq_num + ; br_ref_msg_type + ; br_ref_field_id + ; br_business_reject_reason + ; br_text + ; br_encoded_text_len = Option.map Z.of_int br_encoded_text_len + ; br_encoded_text + } ;; -(** *) -let full_admin_msg_to_json x : json = match x with - | Full_Msg_Heartbeat x -> `Assoc [ ( "Heartbeat" , full_msg_heartbeat_to_json x ) ] - | Full_Msg_Logon x -> `Assoc [ ( "Logon" , full_msg_logon_to_json x ) ] - | Full_Msg_Logoff x -> `Assoc [ ( "Logoff" , full_msg_logoff_to_json x ) ] - | Full_Msg_Reject x -> `Assoc [ ( "Reject" , full_msg_reject_to_json x ) ] - | Full_Msg_Business_Reject x -> `Assoc [ ( "Business_Reject" , full_msg_business_reject_to_json x ) ] - | Full_Msg_Resend_Request x -> `Assoc [ ( "Resend_Request" , full_msg_resend_request_to_json x ) ] - | Full_Msg_Sequence_Reset x -> `Assoc [ ( "Sequence_Reset" , full_msg_sequence_reset_to_json x ) ] - | Full_Msg_Test_Request x -> `Assoc [ ( "Test_Request" , full_msg_test_request_to_json x ) ] +let full_admin_msg_decoder : full_admin_msg_data D.decoder = + let open D in + single_field ( + function + | "Full_Msg_Heartbeat" -> full_msg_heartbeat_decoder >>= + fun m -> D.succeed (Full_Msg_Heartbeat m) + | "Full_Msg_Logon" -> full_msg_logon_decoder >>= + fun m -> D.succeed (Full_Msg_Logon m) + | "Full_Msg_Logoff" -> full_msg_logoff_decoder >>= + fun m -> D.succeed (Full_Msg_Logoff m) + | "Full_Msg_Reject" -> full_msg_reject_decoder >>= + fun m -> D.succeed (Full_Msg_Reject m) + | "Full_Msg_Business_Reject" -> full_msg_business_reject_decoder >>= + fun m -> D.succeed (Full_Msg_Business_Reject m) + | "Full_Msg_Resend_Request" -> full_msg_resent_request_decoder >>= + fun m -> D.succeed (Full_Msg_Resend_Request m) + | "Full_Msg_Sequence_Reset" -> full_msg_sequence_reset_decoder >>= + fun m -> D.succeed (Full_Msg_Sequence_Reset m) + | "Full_Msg_Test_Request" -> full_msg_test_request_decoder >>= + fun m -> D.succeed (Full_Msg_Test_Request m) + | x -> D.fail @@ "Unknown admin message "^x + ) ;; -[@@@logic] -*) +[@@@logic] \ No newline at end of file diff --git a/src-protocol-pp/full_message_tags_decoder.iml b/src-protocol-pp/full_message_tags_decoder.iml index 0a4f6d6c..7da9a01d 100644 --- a/src-protocol-pp/full_message_tags_decoder.iml +++ b/src-protocol-pp/full_message_tags_decoder.iml @@ -27,7 +27,7 @@ let full_msg_tag_of_json : full_msg_tag D.decoder = | x -> D.fail @@ "Unknown full message tag " ^ x ;; -let full_field_tag_to_json : full_field_tag D.decoder = +let full_field_tag_of_json : full_field_tag D.decoder = let open D in single_field @@ function | "Full_Admin_Field_Tag" -> diff --git a/src-protocol-pp/full_messages_decoder.iml b/src-protocol-pp/full_messages_decoder.iml new file mode 100644 index 00000000..9ad0d272 --- /dev/null +++ b/src-protocol-pp/full_messages_decoder.iml @@ -0,0 +1,174 @@ +(* Imandra Inc. copyright 2021 *) +[@@@program] +[@@@require "decoders-yojson"] +[@@@import "../src-protocol/full_messages.iml"] +[@@@import "full_admin_messages_decoder.iml"] +[@@@import "../src-protocol-exts-pp/full_app_messages_decoder.iml"] +[@@@import "../src-protocol/full_admin_tags.iml"] +[@@@import "full_message_tags_decoder.iml"] +[@@@import "full_admin_enums_decoder.iml"] +[@@@import "../src-core-time-defaults-pp/time_defaults_json.iml"] +open Full_app_messages_decoder;; +open Full_admin_messages_decoder;; +open Full_admin_tags;; +open Full_messages;; +open Full_message_tags_decoder;; +open Full_admin_enums_decoder;; +open Time_defaults_json;; + +module D = Decoders_yojson.Basic.Decode;; + +let full_msg_decoder : full_msg_data D.decoder = + let open D in + single_field @@ function + | "Full_FIX_Admin_Msg" -> full_admin_msg_decoder >>= fun x -> + D.succeed (Full_FIX_Admin_Msg x) + | "Full_FIX_App_Msg" -> full_app_msg_of_json >>= fun x -> + D.succeed (Full_FIX_App_Msg x) + | x -> D.fail @@ "Unknown full message type "^x +;; + + +let full_msg_reject_decoder : session_rejected_msg_data D.decoder = + let open D in + field "RefSeqNum" int >>= fun srej_msg_msg_seq_num -> + maybe (field "RefTagID" full_field_tag_of_json) >>= fun srej_msg_field_tag -> + maybe (field "RefMsgType" full_msg_tag_of_json) >>= fun srej_msg_msg_type -> + maybe (field "SessionRejectReason" full_admin_enum_fix_session_reject_reason_decoder) >>= fun srej_msg_reject_reason -> + maybe (field "Text" string) >>= fun srej_text -> + maybe (field "EncodedTextLen" int) >>= fun srej_encoded_text_len -> + maybe (field "EncodedText" string) >>= fun srej_encoded_text -> + D.succeed + { srej_msg_msg_seq_num = Z.of_int srej_msg_msg_seq_num + ; srej_msg_field_tag + ; srej_msg_msg_type + ; srej_msg_reject_reason + ; srej_text + ; srej_encoded_text_len = Option.map Z.of_int srej_encoded_text_len + ; srej_encoded_text + } +;; + + +let full_msg_business_reject_decoder : biz_rejected_msg_data D.decoder = + let open D in + field "RefSeqNum" int >>= fun brej_msg_ref_seq_num -> + field "RefMsgType" full_msg_tag_of_json >>= fun brej_msg_msg_tag -> + maybe (field "BusinessFieldTag" full_field_tag_of_json) >>= fun brej_msg_field_tag -> + field "BusinessRejectReason" full_admin_enum_fix_business_reject_reason_decoder >>= + fun brej_msg_reject_reason -> + maybe (field "Text" string) >>= fun brej_msg_text -> + maybe (field "EncodedText" string) >>= fun brej_msg_encoded_text -> + D.succeed { + brej_msg_ref_seq_num = Z.of_int brej_msg_ref_seq_num; + brej_msg_msg_tag; + brej_msg_reject_reason; + brej_msg_field_tag; + brej_msg_text; + brej_msg_encoded_text; + } +;; + +let header_decoder : fix_header D.decoder = + let open D in + field "BeginString" string >>= fun h_begin_string -> + field "BodyLength" int >>= fun h_body_length -> + field "SenderCompID" string >>= fun h_sender_comp_id -> + field "TargetCompID" string >>= fun h_target_comp_id -> + field "MsgSeqNum" int >>= fun h_msg_seq_num -> + maybe (field "OnBehalfOfCompID" string) >>= fun h_on_behalf_of_comp_id -> + maybe (field "DeliverToCompID" string) >>= fun h_deliver_to_comp_id -> + maybe (field "SecureDataLen" int) >>= fun h_secure_data_len -> + maybe (field "SecureData" int) >>= fun h_secure_data -> + maybe (field "SenderSubID" string) >>= fun h_sender_sub_id -> + maybe (field "SenderLocationID" string) >>= fun h_sender_location_id -> + maybe (field "TargetSubID" string) >>= fun h_target_sub_id -> + maybe (field "TargetLocationID" string) >>= fun h_target_location_id -> + maybe (field "OnBehalfOfSubID" string) >>= fun h_on_behalf_of_sub_id -> + maybe (field "OnBehalfOfLocationID" string) >>= fun h_on_behalf_of_location_id -> + maybe (field "DeliverToSubID" string) >>= fun h_deliver_to_sub_id -> + maybe (field "DeliverToLocationID" string) >>= fun h_deliver_to_location_id -> + maybe (field "PossDupFlag" bool) >>= fun h_poss_dup_flag -> + maybe (field "PossResend" bool) >>= fun h_poss_resend -> + field "SendingTime" utctimestamp_decoder >>= fun h_sending_time -> + maybe (field "OrigSendingTime" utctimestamp_decoder) >>= fun h_orig_sending_time -> + maybe (field "XmlDataLen" int) >>= fun h_xml_data_len -> + maybe (field "XmlData" int) >>= fun h_xml_data -> + maybe (field "MessageEncoding" int) >>= fun h_message_enconding -> + maybe (field "LastMsgSeqNumProcessed" int) >>= fun h_last_msg_seq_num_processed -> + maybe (field "NoHops" int) >>= fun h_no_hops -> + D.succeed { + h_begin_string + ; h_body_length = Z.of_int h_body_length + ; h_sender_comp_id + ; h_target_comp_id + ; h_msg_seq_num = Z.of_int h_msg_seq_num + ; h_on_behalf_of_comp_id + ; h_deliver_to_comp_id + ; h_secure_data_len = Option.map Z.of_int h_secure_data_len + ; h_secure_data = Option.map Z.of_int h_secure_data + ; h_sender_sub_id + ; h_sender_location_id + ; h_target_sub_id + ; h_target_location_id + ; h_on_behalf_of_sub_id + ; h_on_behalf_of_location_id + ; h_deliver_to_sub_id + ; h_deliver_to_location_id + ; h_poss_dup_flag + ; h_poss_resend + ; h_sending_time + ; h_orig_sending_time + ; h_xml_data_len = Option.map Z.of_int h_xml_data_len + ; h_xml_data = Option.map Z.of_int h_xml_data + ; h_message_encoding = Option.map Z.of_int h_message_enconding + ; h_last_msg_seq_num_processed = Option.map Z.of_int h_last_msg_seq_num_processed + ; h_no_hops = Option.map Z.of_int h_no_hops + } +;; + +let trailer_decoder : fix_trailer D.decoder = + let open D in + maybe (field "SignatureLength" int) >>= fun signature_length -> + maybe (field "Signature" int) >>= fun signature -> + field "CheckSum" int >>= fun check_sum -> + D.succeed { + signature_length = Option.map Z.of_int signature_length + ; signature = Option.map Z.of_int signature + ; check_sum = Z.of_int check_sum + } +;; + +let full_valid_msg_decoder : full_valid_fix_msg D.decoder = + let open D in + field "StandardHeader" header_decoder >>= fun full_msg_header -> + field "MessageBody" full_msg_decoder >>= fun full_msg_data -> + field "StandardTrailer" trailer_decoder >>= fun full_msg_trailer -> + D.succeed { + full_msg_header + ; full_msg_data + ; full_msg_trailer + } +;; + +let full_valid_msg_list_decoder : full_valid_fix_msg list D.decoder = + let open D in + list full_valid_msg_decoder +;; + +let full_top_level_msg_decoder : full_top_level_msg D.decoder = + let open D in + single_field @@ function + | "ValidMsg" -> full_valid_msg_decoder >>= fun m -> + D.succeed (ValidMsg m) + | "SessionRejectedMsg" -> full_msg_reject_decoder >>= fun m -> + D.succeed (SessionRejectedMsg m) + | "BusinessRejectedMsg" -> full_msg_business_reject_decoder >>= fun m -> + D.succeed (BusinessRejectedMsg m) + | "Garbled" -> string >>= fun m -> + D.succeed Garbled + | x -> D.fail @@ "unknown top level message "^x + +;; + +[@@@logic] \ No newline at end of file diff --git a/src-protocol-pp/full_messages_json.iml b/src-protocol-pp/full_messages_json.iml index f9ba600f..04883196 100644 --- a/src-protocol-pp/full_messages_json.iml +++ b/src-protocol-pp/full_messages_json.iml @@ -31,8 +31,8 @@ let assoc_filter_nulls l : json = let full_msg_to_json = function - | Full_FIX_Admin_Msg x -> full_admin_msg_to_json x - | Full_FIX_App_Msg x -> full_app_msg_to_json x + | Full_FIX_Admin_Msg x -> `Assoc [("Full_FIX_Admin_Msg",full_admin_msg_to_json x)] + | Full_FIX_App_Msg x -> `Assoc [("Full_FIX_App_Msg",full_app_msg_to_json x)] ;; @@ -49,11 +49,12 @@ let session_rejected_msg_to_json x : json = let biz_rejected_msg_to_json x : json = - [ ( "RefSeqNum" , int_to_json x.brej_msg_ref_seq_num ) - ; ( "RefMsgTyp" , full_msg_tag_to_json x.brej_msg_msg_tag ) - ; ( "BusinessRejectReasoni" , business_reject_reason_to_json x.brej_msg_reject_reason ) - ; ( "Text" , string_opt_to_json x.brej_msg_text ) - ; ( "EncodedText" , string_opt_to_json x.brej_msg_encoded_text ) + [ ( "RefSeqNum" , int_to_json x.brej_msg_ref_seq_num ) + ; ( "RefMsgTyp" , full_msg_tag_to_json x.brej_msg_msg_tag ) + ; ( "BusinessFieldTag" , full_field_tag_opt_to_json x.brej_msg_field_tag ) + ; ( "BusinessRejectReason" , business_reject_reason_to_json x.brej_msg_reject_reason ) + ; ( "Text" , string_opt_to_json x.brej_msg_text ) + ; ( "EncodedText" , string_opt_to_json x.brej_msg_encoded_text ) ] |> assoc_filter_nulls ;; @@ -81,7 +82,7 @@ let header_to_json x : json = ; ( "OrigSendingTime" , utctimestamp_opt_to_json x.h_orig_sending_time ) ; ( "XmlDataLen" , int_opt_to_json x.h_xml_data_len ) ; ( "XmlData" , int_opt_to_json x.h_xml_data ) - ; ( "MessageEncoding" , int_opt_to_json x.h_message_enconding ) + ; ( "MessageEncoding" , int_opt_to_json x.h_message_encoding ) ; ( "LastMsgSeqNumProcessed", int_opt_to_json x.h_last_msg_seq_num_processed ) ; ( "NoHops" , int_opt_to_json x.h_no_hops ) ] |> assoc_filter_nulls diff --git a/src-protocol-pp/parse_full_messages.iml b/src-protocol-pp/parse_full_messages.iml index 6f7da10f..931c6872 100644 --- a/src-protocol-pp/parse_full_messages.iml +++ b/src-protocol-pp/parse_full_messages.iml @@ -58,7 +58,7 @@ let parse_header msg = opt msg "122" parse_UTCTimestamp @@ fun msg h_orig_sending_time -> opt msg "212" parse_int @@ fun msg h_xml_data_len -> opt msg "213" parse_int @@ fun msg h_xml_data -> - opt msg "347" parse_int @@ fun msg h_message_enconding -> + opt msg "347" parse_int @@ fun msg h_message_encoding -> opt msg "369" parse_int @@ fun msg h_last_msg_seq_num_processed -> opt msg "627" parse_int @@ fun msg h_no_hops -> ParseSuccess @@ -85,7 +85,7 @@ let parse_header msg = ; h_orig_sending_time ; h_xml_data_len ; h_xml_data - ; h_message_enconding + ; h_message_encoding ; h_last_msg_seq_num_processed ; h_no_hops } , msg diff --git a/src-protocol/full_messages.iml b/src-protocol/full_messages.iml index d2918bb8..1b6ef7f6 100644 --- a/src-protocol/full_messages.iml +++ b/src-protocol/full_messages.iml @@ -114,7 +114,7 @@ type fix_header = { h_orig_sending_time : fix_utctimestamp option; (* Tag 122 *) h_xml_data_len : int option; (* Tag 212 *) h_xml_data : int option; (* Tag 213 *) - h_message_enconding : int option; (* Tag 347 *) + h_message_encoding : int option; (* Tag 347 *) h_last_msg_seq_num_processed : int option; (* Tag 369 *) h_no_hops : int option; (* Tag 627 *) } diff --git a/src/fix_engine_utils.iml b/src/fix_engine_utils.iml index 27740d8e..5c48f481 100644 --- a/src/fix_engine_utils.iml +++ b/src/fix_engine_utils.iml @@ -147,7 +147,7 @@ let create_outbound_fix_msg ( osn, target_comp_id, our_comp_id, curr_time, msg, h_orig_sending_time = None; h_xml_data_len = None; h_xml_data = None; - h_message_enconding = None; + h_message_encoding = None; h_last_msg_seq_num_processed = None; h_no_hops = None; }; From 1a28373f35b89e6bbb65f238c3bf02eac671c986 Mon Sep 17 00:00:00 2001 From: Ewen Maclean Date: Thu, 8 Apr 2021 21:12:01 +0100 Subject: [PATCH 7/9] adding test to check decoding of admin messages --- .../full_admin_messages_decoder.iml | 16 ++++---- src-tests-utils/roundtrip_test.iml | 40 +++++++++++++++++++ src-tests/dune | 2 + src-tests/test_cache.ml | 4 +- src/fix_engine_utils.iml | 1 - 5 files changed, 52 insertions(+), 11 deletions(-) create mode 100644 src-tests-utils/roundtrip_test.iml diff --git a/src-protocol-pp/full_admin_messages_decoder.iml b/src-protocol-pp/full_admin_messages_decoder.iml index 134b0b37..0f637ae0 100644 --- a/src-protocol-pp/full_admin_messages_decoder.iml +++ b/src-protocol-pp/full_admin_messages_decoder.iml @@ -136,21 +136,21 @@ let full_admin_msg_decoder : full_admin_msg_data D.decoder = let open D in single_field ( function - | "Full_Msg_Heartbeat" -> full_msg_heartbeat_decoder >>= + | "Heartbeat" -> full_msg_heartbeat_decoder >>= fun m -> D.succeed (Full_Msg_Heartbeat m) - | "Full_Msg_Logon" -> full_msg_logon_decoder >>= + | "Logon" -> full_msg_logon_decoder >>= fun m -> D.succeed (Full_Msg_Logon m) - | "Full_Msg_Logoff" -> full_msg_logoff_decoder >>= + | "Logoff" -> full_msg_logoff_decoder >>= fun m -> D.succeed (Full_Msg_Logoff m) - | "Full_Msg_Reject" -> full_msg_reject_decoder >>= + | "Reject" -> full_msg_reject_decoder >>= fun m -> D.succeed (Full_Msg_Reject m) - | "Full_Msg_Business_Reject" -> full_msg_business_reject_decoder >>= + | "Business_Reject" -> full_msg_business_reject_decoder >>= fun m -> D.succeed (Full_Msg_Business_Reject m) - | "Full_Msg_Resend_Request" -> full_msg_resent_request_decoder >>= + | "Resend_Request" -> full_msg_resent_request_decoder >>= fun m -> D.succeed (Full_Msg_Resend_Request m) - | "Full_Msg_Sequence_Reset" -> full_msg_sequence_reset_decoder >>= + | "Sequence_Reset" -> full_msg_sequence_reset_decoder >>= fun m -> D.succeed (Full_Msg_Sequence_Reset m) - | "Full_Msg_Test_Request" -> full_msg_test_request_decoder >>= + | "Test_Request" -> full_msg_test_request_decoder >>= fun m -> D.succeed (Full_Msg_Test_Request m) | x -> D.fail @@ "Unknown admin message "^x ) diff --git a/src-tests-utils/roundtrip_test.iml b/src-tests-utils/roundtrip_test.iml new file mode 100644 index 00000000..d8fba97c --- /dev/null +++ b/src-tests-utils/roundtrip_test.iml @@ -0,0 +1,40 @@ +[@@@program] +[@@@require "decoders-yojson"] +[@@@import "../src-protocol-pp/full_messages_decoder.iml"] +[@@@import "../src-protocol-pp/full_messages_json.iml"] +[@@@import "../src-core-time-defaults/time_defaults.iml"] +[@@@import "../src/fix_engine_utils.iml"] +[@@@import "../src-protocol/full_messages.iml"] +open Full_messages_decoder +open Full_messages_json +open Time_defaults +open Fix_engine_utils +open Full_messages +module D = Decoders_yojson.Basic.Decode;; + + +let make_fix_msg i = + let msg = Full_FIX_Admin_Msg ( + Full_Msg_Heartbeat { hb_test_req_id = Some "123" } + ) in + create_outbound_fix_msg (i - 1, + "IMANDRA", + "TARGET", + make_utctimestamp 2017 1 1 0 1 0 None, + msg, false + ) +;; + +let test () = + let orig = make_fix_msg 1 in + let json = full_valid_msg_to_json orig |> Yojson.Basic.to_string in + D.decode_string full_valid_msg_decoder json |> + function + | Ok rt -> + if rt = orig + then () + else failwith "incorrect" + | Error r -> + failwith (D.pp_error Format.std_formatter r; failwith "decoding of full message failed") +;; +[@@@logic] \ No newline at end of file diff --git a/src-tests/dune b/src-tests/dune index 5d45773c..1f12eae0 100644 --- a/src-tests/dune +++ b/src-tests/dune @@ -2,9 +2,11 @@ (name test_runner) (libraries threads cmdliner lwt.unix fix_simulation_utils protocol_pp core_printer test_utils) + (modes byte) (modules test_runner)) (executable (name test_cache) (libraries test_utils fix_engine) + (modes byte) (modules test_cache)) diff --git a/src-tests/test_cache.ml b/src-tests/test_cache.ml index 92eb72ab..23554aee 100644 --- a/src-tests/test_cache.ml +++ b/src-tests/test_cache.ml @@ -16,7 +16,7 @@ print_string "The old cache:\n" ;; print_string - (Yojson.pretty_to_string + (Yojson.Basic.pretty_to_string (Full_messages_json.full_msg_list_to_json Test_cache_utils.cache) ) ;; @@ -29,7 +29,7 @@ let new_cache = ;; print_string - (Yojson.pretty_to_string (Full_messages_json.full_msg_list_to_json new_cache)) + (Yojson.Basic.pretty_to_string (Full_messages_json.full_msg_list_to_json new_cache)) (* Can we transition correctly? *) (* make these fix_msgs in utils and import *) diff --git a/src/fix_engine_utils.iml b/src/fix_engine_utils.iml index 5c48f481..8954e53d 100644 --- a/src/fix_engine_utils.iml +++ b/src/fix_engine_utils.iml @@ -7,7 +7,6 @@ fix_engine_utils.iml *) - [@@@import "../src-core/datetime.iml"] [@@@import "../src-protocol/full_admin_enums.iml"] [@@@import "../src-protocol/full_admin_messages.iml"] From fc3c09fb571516fa9817ca8ce146a23f7727cf9a Mon Sep 17 00:00:00 2001 From: Ewen Maclean Date: Fri, 9 Apr 2021 11:32:31 +0100 Subject: [PATCH 8/9] making tests compile and adding roundtrip integration test --- Dockerfile | 3 +- Makefile | 1 + src-tests-utils/roundtrip_test.iml | 40 ----------------- src-tests-utils/test_cache_utils.iml | 9 ++-- src-tests/dune | 7 +++ src-tests/test_cache.ml | 65 +++++++++++++++++----------- src/fix_engine_transitions.iml | 2 +- 7 files changed, 53 insertions(+), 74 deletions(-) delete mode 100644 src-tests-utils/roundtrip_test.iml diff --git a/Dockerfile b/Dockerfile index c1e0c565..09620d45 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,4 +3,5 @@ FROM imandra/imandra-client-switch COPY --chown=opam:nogroup ./fix-engine.opam . RUN opam install . --deps-only --with-test --working-dir COPY --chown=opam:nogroup . . -RUN make build build_server \ No newline at end of file +RUN make build build_server build_tests +RUN ./_build//default/src-tests/test_roundtrip.bc \ No newline at end of file diff --git a/Makefile b/Makefile index 12944189..44ef5753 100644 --- a/Makefile +++ b/Makefile @@ -20,6 +20,7 @@ build_tests: @echo "(dirs :standard \ *-vg)" > dune dune build src-tests/test_runner.bc dune build src-tests/test_cache.bc + dune build src-tests/test_roundtrip.bc rm dune doc: diff --git a/src-tests-utils/roundtrip_test.iml b/src-tests-utils/roundtrip_test.iml deleted file mode 100644 index d8fba97c..00000000 --- a/src-tests-utils/roundtrip_test.iml +++ /dev/null @@ -1,40 +0,0 @@ -[@@@program] -[@@@require "decoders-yojson"] -[@@@import "../src-protocol-pp/full_messages_decoder.iml"] -[@@@import "../src-protocol-pp/full_messages_json.iml"] -[@@@import "../src-core-time-defaults/time_defaults.iml"] -[@@@import "../src/fix_engine_utils.iml"] -[@@@import "../src-protocol/full_messages.iml"] -open Full_messages_decoder -open Full_messages_json -open Time_defaults -open Fix_engine_utils -open Full_messages -module D = Decoders_yojson.Basic.Decode;; - - -let make_fix_msg i = - let msg = Full_FIX_Admin_Msg ( - Full_Msg_Heartbeat { hb_test_req_id = Some "123" } - ) in - create_outbound_fix_msg (i - 1, - "IMANDRA", - "TARGET", - make_utctimestamp 2017 1 1 0 1 0 None, - msg, false - ) -;; - -let test () = - let orig = make_fix_msg 1 in - let json = full_valid_msg_to_json orig |> Yojson.Basic.to_string in - D.decode_string full_valid_msg_decoder json |> - function - | Ok rt -> - if rt = orig - then () - else failwith "incorrect" - | Error r -> - failwith (D.pp_error Format.std_formatter r; failwith "decoding of full message failed") -;; -[@@@logic] \ No newline at end of file diff --git a/src-tests-utils/test_cache_utils.iml b/src-tests-utils/test_cache_utils.iml index 5d1b5e3f..d77f2c4b 100644 --- a/src-tests-utils/test_cache_utils.iml +++ b/src-tests-utils/test_cache_utils.iml @@ -9,8 +9,8 @@ *) [@@@import "../src-protocol/full_admin_messages.iml"] [@@@import "../src-protocol/full_messages.iml"] -[@@@import "../src/fix_engine_transitions.iml"] -[@@@import "../src/fix_engine_utils.iml"] +[@@@import "../src/fix_engine_transitions.iml"] +[@@@import "../src/fix_engine_utils.iml"] [@@@import "../src-core-time-defaults/time_defaults.iml"] [@@@import "../src-protocol-pp/full_messages_json.iml"] [@@@program] @@ -20,9 +20,6 @@ open Fix_engine_transitions open Fix_engine_utils open Time_defaults - - - let pe = print_endline;; let make_fix_msg i = @@ -35,7 +32,7 @@ let make_fix_msg i = make_utctimestamp 2017 1 1 0 1 0 None, msg, false ) -;; +;; let cache = [ make_fix_msg (1); diff --git a/src-tests/dune b/src-tests/dune index 1f12eae0..485688bc 100644 --- a/src-tests/dune +++ b/src-tests/dune @@ -10,3 +10,10 @@ (libraries test_utils fix_engine) (modes byte) (modules test_cache)) + + +(executable + (name test_roundtrip) + (libraries test_utils fix_engine) + (modes byte) + (modules test_roundtrip)) diff --git a/src-tests/test_cache.ml b/src-tests/test_cache.ml index 23554aee..959196a4 100644 --- a/src-tests/test_cache.ml +++ b/src-tests/test_cache.ml @@ -3,54 +3,67 @@ (*** Aesthetic Integration Limited - Copyright (c) 2014 - 2018 + Copyright (c) 2014 - 2021 test_cache.ml - + *) let pe = print_endline - ;; -print_string "The old cache:\n" +let _ = print_string "The old cache:\n" ;; -print_string + +let _ = print_string (Yojson.Basic.pretty_to_string (Full_messages_json.full_msg_list_to_json Test_cache_utils.cache) ) ;; + print_string "\n\nThe new cache\n" let new_cache = - Fix_engine_transitions.add_to_cache - (Test_cache_utils.new_cache_fix_msg, Test_cache_utils.cache) + Fix_engine_transitions.update_cache + (List.map + (fun x -> Fix_engine_state.CacheMessage x) Test_cache_utils.cache) + (Fix_engine_state.CacheMessage Test_cache_utils.new_cache_fix_msg) ;; -print_string - (Yojson.Basic.pretty_to_string (Full_messages_json.full_msg_list_to_json new_cache)) - -(* Can we transition correctly? *) -(* make these fix_msgs in utils and import *) +let print_cache cache_entry = + match cache_entry with + | Fix_engine_state.CacheMessage m -> + Yojson.Basic.pretty_to_string (Full_messages_json.full_valid_msg_to_json m) + | Fix_engine_state.CacheGap (l,r) -> Yojson.Basic.pretty_to_string + (`Assoc ([("l",`Int (Z.to_int l));("r",`Int (Z.to_int r))])) ;; -pe "\nShould be fine - since 0th we have everything" -;; -Test_cache_utils.check_cache - (Test_cache_utils.cache1, Test_cache_utils.test_cache_index) +let _ = List.iter + (fun x -> let s = print_cache x in print_string s) new_cache -;; -pe "\nFails - missing 5-9" -;; -Test_cache_utils.check_cache - (Test_cache_utils.cache2, Test_cache_utils.test_cache_index) + (* Can we transition correctly? *) + (* make these fix_msgs in utils and import *) -;; -pe "\nFails - missing 1st" + ;; + pe "\nShould be fine - since 0th we have everything" -;; -Test_cache_utils.check_cache - (Test_cache_utils.cache3, Test_cache_utils.test_cache_index) + ;; + Test_cache_utils.check_cache + (List.map (fun x -> Fix_engine_state.CacheMessage x) Test_cache_utils.cache1, Test_cache_utils.test_cache_index) + + ;; + pe "\nFails - missing 5-9" + + ;; + Test_cache_utils.check_cache + (List.map (fun x -> Fix_engine_state.CacheMessage x) Test_cache_utils.cache2, Test_cache_utils.test_cache_index) + + ;; + pe "\nFails - missing 1st" + + ;; + Test_cache_utils.check_cache + (List.map (fun x -> Fix_engine_state.CacheMessage x) Test_cache_utils.cache3, Test_cache_utils.test_cache_index) diff --git a/src/fix_engine_transitions.iml b/src/fix_engine_transitions.iml index fbf8dccc..c1b406aa 100644 --- a/src/fix_engine_transitions.iml +++ b/src/fix_engine_transitions.iml @@ -384,7 +384,7 @@ let cache_to_str cache = | CacheGap (x,y) -> "(" ^ Z.to_string x ^ "->" ^ Z.to_string y ^ ")" | CacheMessage m -> "(" ^ Z.to_string m.full_msg_header.h_msg_seq_num ^ ")" ) |> String.concat " , " -;; +[@@program];; let is_cache_complete ( cache, last_seq_processed : cache_entry list * int ) = match cache with [] -> false | entry :: tl -> From 7a86c24ec38fb3fee2f41d21ac1ed54d3a858d18 Mon Sep 17 00:00:00 2001 From: Ewen Maclean Date: Fri, 9 Apr 2021 11:35:02 +0100 Subject: [PATCH 9/9] missing file in commit --- src-tests/test_roundtrip.ml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 src-tests/test_roundtrip.ml diff --git a/src-tests/test_roundtrip.ml b/src-tests/test_roundtrip.ml new file mode 100644 index 00000000..5088d190 --- /dev/null +++ b/src-tests/test_roundtrip.ml @@ -0,0 +1,18 @@ +open Full_messages_decoder +open Full_messages_json +open Test_cache_utils +module D = Decoders_yojson.Basic.Decode;; + + +let () = + let orig = make_fix_msg (Z.of_int 1) in + let json = full_valid_msg_to_json orig |> Yojson.Basic.to_string in + D.decode_string full_valid_msg_decoder json |> + function + | Ok rt -> + if rt = orig + then print_endline "Roundtrip successful" + else failwith "Roundtrip failed" + | Error r -> + failwith (D.pp_error Format.std_formatter r; failwith "decoding of full message failed") +;;