case class SfMessageHeader(beginStringField: BeginStringField, bodyLengthField: Option[BodyLengthField] = None, msgTypeField: MsgTypeField, applVerIdField: Option[ApplVerIDField] = None, applExtIDField: Option[ApplExtIDField] = None, cstmApplVerIDField: Option[CstmApplVerIDField] = None, senderCompIDField: SenderCompIDField, targetCompIDField: TargetCompIDField, onBehalfOfCompIDField: Option[OnBehalfOfCompIDField] = None, deliverToCompIDField: Option[DeliverToCompIDField] = None, secureDataLenField: Option[SecureDataLenField] = None, secureDataField: Option[SecureDataField] = None, msgSeqNumField: MsgSeqNumField, senderSubIDField: Option[SenderSubIDField] = None, senderLocationIDField: Option[SenderLocationIDField] = None, targetSubIDField: Option[TargetSubIDField] = None, targetLocationIDField: Option[TargetLocationIDField] = None, onBehalfOfSubIDField: Option[OnBehalfOfSubIDField] = None, onBehalfOfLocationIDField: Option[OnBehalfOfLocationIDField] = None, deliverToSubIDField: Option[DeliverToSubIDField] = None, deliverToLocationIDField: Option[DeliverToLocationIDField] = None, possDupFlagField: Option[PossDupFlagField] = None, possResendField: Option[PossResendField] = None, sendingTimeField: SendingTimeField, origSendingTimeField: Option[OrigSendingTimeField] = None, xmlDataLenField: Option[XmlDataLenField] = None, xmlDataField: Option[XmlDataField] = None, messageEncodingField: Option[MessageEncodingField] = None, lastMsgSeqNumProcessedField: Option[LastMsgSeqNumProcessedField] = None, noHopsField: Option[NoHopsField] = None, sfMessageHeaderHopsGroup: Option[List[HopsGroup]] = None) extends SfFixFieldsToAscii with Product with Serializable
Created by Jonathan during 2016. The header is defined in places like this: http://www.fixtradingcommunity.org/FIXimate/FIXimate3.0/en/FIX.5.0SP2/body_49485052.html
Note that the body length has to be recalculated when you get the fixStr for outgoing messages which is why it is marked as an Optional member, even though it is required.
ie two use cases, for incoming messages it will be populated for outgoing messages you can leave it as a None as it will be recalculated when you call fixStr(Body)
For incoming messages you can access the original body length as msg.bodyLengthField and to determine that it is correct you can call msg.calcBodyLength(body : SfFixMessageBody)
Take a look at the test case to see it in action. Look at the sackfixsession project for how to create strongly typed full messages and read them.
- Alphabetic
- By Inheritance
- SfMessageHeader
- Serializable
- Product
- Equals
- SfFixFieldsToAscii
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new SfMessageHeader(beginStringField: BeginStringField, bodyLengthField: Option[BodyLengthField] = None, msgTypeField: MsgTypeField, applVerIdField: Option[ApplVerIDField] = None, applExtIDField: Option[ApplExtIDField] = None, cstmApplVerIDField: Option[CstmApplVerIDField] = None, senderCompIDField: SenderCompIDField, targetCompIDField: TargetCompIDField, onBehalfOfCompIDField: Option[OnBehalfOfCompIDField] = None, deliverToCompIDField: Option[DeliverToCompIDField] = None, secureDataLenField: Option[SecureDataLenField] = None, secureDataField: Option[SecureDataField] = None, msgSeqNumField: MsgSeqNumField, senderSubIDField: Option[SenderSubIDField] = None, senderLocationIDField: Option[SenderLocationIDField] = None, targetSubIDField: Option[TargetSubIDField] = None, targetLocationIDField: Option[TargetLocationIDField] = None, onBehalfOfSubIDField: Option[OnBehalfOfSubIDField] = None, onBehalfOfLocationIDField: Option[OnBehalfOfLocationIDField] = None, deliverToSubIDField: Option[DeliverToSubIDField] = None, deliverToLocationIDField: Option[DeliverToLocationIDField] = None, possDupFlagField: Option[PossDupFlagField] = None, possResendField: Option[PossResendField] = None, sendingTimeField: SendingTimeField, origSendingTimeField: Option[OrigSendingTimeField] = None, xmlDataLenField: Option[XmlDataLenField] = None, xmlDataField: Option[XmlDataField] = None, messageEncodingField: Option[MessageEncodingField] = None, lastMsgSeqNumProcessedField: Option[LastMsgSeqNumProcessedField] = None, noHopsField: Option[NoHopsField] = None, sfMessageHeaderHopsGroup: Option[List[HopsGroup]] = None)
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- val applExtIDField: Option[ApplExtIDField]
- val applVerIdField: Option[ApplVerIDField]
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- val beginStringField: BeginStringField
- val bodyLengthField: Option[BodyLengthField]
- def calcBodyLength(fixBodyStr: StringBuilder): BodyLengthField
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- val cstmApplVerIDField: Option[CstmApplVerIDField]
- val deliverToCompIDField: Option[DeliverToCompIDField]
- val deliverToLocationIDField: Option[DeliverToLocationIDField]
- val deliverToSubIDField: Option[DeliverToSubIDField]
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- def fixStr(fixBodyStr: StringBuilder): StringBuilder
Generate a fix string for the message boxy that is given, recalculating the body length
Generate a fix string for the message boxy that is given, recalculating the body length
- fixBodyStr
The body to use when calculating body length
- def fixStr: String
- def formatForFix(b: StringBuilder, f: SfFixRenderable): Unit
- Definition Classes
- SfFixFieldsToAscii
- def formatForToString(b: StringBuilder, f: SfFixRenderable): Unit
- Definition Classes
- SfFixFieldsToAscii
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- var lastCalculatedBodyLength: BodyLengthField
- val lastMsgSeqNumProcessedField: Option[LastMsgSeqNumProcessedField]
- val messageEncodingField: Option[MessageEncodingField]
- val msgSeqNumField: MsgSeqNumField
- val msgTypeField: MsgTypeField
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- val noHopsField: Option[NoHopsField]
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- val onBehalfOfCompIDField: Option[OnBehalfOfCompIDField]
- val onBehalfOfLocationIDField: Option[OnBehalfOfLocationIDField]
- val onBehalfOfSubIDField: Option[OnBehalfOfSubIDField]
- val origSendingTimeField: Option[OrigSendingTimeField]
- val possDupFlagField: Option[PossDupFlagField]
- val possResendField: Option[PossResendField]
- def productElementNames: Iterator[String]
- Definition Classes
- Product
- val secureDataField: Option[SecureDataField]
- val secureDataLenField: Option[SecureDataLenField]
- val senderCompIDField: SenderCompIDField
- val senderLocationIDField: Option[SenderLocationIDField]
- val senderSubIDField: Option[SenderSubIDField]
- val sendingTimeField: SendingTimeField
- val sfMessageHeaderHopsGroup: Option[List[HopsGroup]]
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- val targetCompIDField: TargetCompIDField
- val targetLocationIDField: Option[TargetLocationIDField]
- val targetSubIDField: Option[TargetSubIDField]
- def toString(): String
If this is outgoing message the body length will be missing from the toString until it is rendered to fix(body) - le body len will be 0 as it wont be known.
If this is outgoing message the body length will be missing from the toString until it is rendered to fix(body) - le body len will be 0 as it wont be known.
- Definition Classes
- SfMessageHeader → AnyRef → Any
- def toStringBuilder: StringBuilder
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- val xmlDataField: Option[XmlDataField]
- val xmlDataLenField: Option[XmlDataLenField]