[QFJ-58] FIX enum values for fields of type MULTIPLEVALUESTRING are generated as type char Created: 29/Aug/06 Updated: 15/Nov/12 Resolved: 07/Sep/06 |
|
Status: | Closed |
Project: | QuickFIX/J |
Component/s: | Metadata/Specs |
Affects Version/s: | 1.0.0 B3, 1.0.0 Final, 1.0.1, 1.0.2, 1.0.3, 1.1.0 |
Fix Version/s: | None |
Type: | Bug | Priority: | Default |
Reporter: | Jörg Thönnes | Assignee: | Steve Bate |
Resolution: | Not a bug | Votes: | 0 |
Labels: | None |
Description |
These fields are of type MULTIPLEVALUESTRING: <field number="18" name="ExecInst" type="MULTIPLEVALUESTRING"> Normally, I would use e.g. new ExecInst( ExecInst.IMMEDIATE ) but this fails since ExecInst.IMMEDIATE is of type char, while the constructor of ExecInst requires a String argument. |
Comments |
Comment by Jörg Thönnes [ 29/Aug/06 ] |
Extend src/codegen/Fields.xsl to map all possible types. Missing types are: DATA At least extend the XSL templates get-type and get-field-type to include a line for MULTIPLEVALUESTRING: <xsl:when test="@type='MULTIPLEVALUESTRING'">String</xsl:when> |
Comment by Jörg Thönnes [ 30/Aug/06 ] |
Steve, please merge this to the trunk. How about adding mappings for the other missing types as DATA and drop the catch-all other to spot missing types? |
Comment by Steve Bate [ 03/Sep/06 ] |
I have some bad news. The changes for MULTIPLEVALUESTRING broke the JNI API compatibility (which uses chars for the enum). Unfortunately, there were gaps in the API unit tests so they didn't fail after the change. I've modified the API unit tests to catch these types of problems. I've reverted the changes on the branch. We can speak to Oren about changing this in the JNI API and then make the changes in QFJ again. I agree that using a string is a better idea. I'm leaving the issue active but not assigned to a release for now. |
Comment by Steve Bate [ 07/Sep/06 ] |
I'm marking this as "not a bug" for now. If Oren decides to change the types in the JNI API, we can reopen this issue as a feature. |