Details
Description
I have a dictionary which is defined as follows (stripped some stuff out for simplicity)
<message name="QuoteRequest" msgtype="R" msgcat="app">
<field name="QuoteReqID" required="Y"/>
<group name="NoRelatedSym" required="Y">
<component name="Instrument" required="Y"/>
</group>
<field name="Text" required="N"/>
</message>
...
<message name="Quote" msgtype="S" msgcat="app">
<field name="QuoteReqID" required="Y"/>
<component name="Instrument" required="Y"/>
</message>
...
<component name="Instrument">
<field name="Symbol" required="Y"/>
<field name="SecurityID" required="N"/>
<field name="SecurityIDSource" required="N"/>
<field name="Product" required="N"/>
<field name="SecurityType" required="N"/>
<field name="SecuritySubType" required="N"/>
<field name="SecurityXMLLen" required="N"/>
<field name="SecurityXML" required="N"/>
<field name="SecurityXMLSchema" required="N"/>
</component>
From inside the java code, If I run the following code to see if field 55 ("Symbol") is listed as required in the R msg, it returns false:
GroupInfo gi = dictionary.getGroup("R", 146);
boolean requiredInRMsg = gi.getDataDictionary().isRequiredField("R", 55);
If I run the following code to see if field 55 ("Symbol") is listed as required in the S msg, it returns true:
GroupInfo gi = dictionary.getGroup("S", 146);
boolean requiredInRMsg = gi.getDataDictionary().isRequiredField("S", 55);
It appears that quickfix is not respecting the Required flag for a field in a component if that component is inside of a group.