-
Notifications
You must be signed in to change notification settings - Fork 549
Closed
Description
How can I add enum field inside a composite so that enum class is generated
Say I have the following enum inside the composite - it does not generate a header class for RequestType
<enum name="RequestType" encodingType="uInt8NULL">
<validValue name="None">0</validValue> <!-- Example: Unsolicited Cancel -->
<validValue name="Submit">1</validValue>
<validValue name="Update">2</validValue>
<validValue name="Cancel">3</validValue>
</enum>
<composite name="OrderRequest" description="Order Request">
<type name="order_id" primitiveType="uint64" semanticType="int"/>
<type name="req_id" primitiveType="uint64" semanticType="int"/>
<type name="user_token" presence="optional" primitiveType="uint64" semanticType="int"/>
<type name="request_type" type="RequestType" primitiveType="uint8" semanticType="RequestType"/>
</composite>
Activity
vyazelenko commentedon Jun 11, 2025
@samkhopkar You need to use
OrderRequest
in one of the message types, i.e. if types/enums/composites are not used then no code will be generated for it.