How to set data for nested object's fields in drools decision table

217 Views Asked by At

I want to set data for nested object in drools decision table. I have a Java model class SalesMobilityApiModel in which I have a nested object of type AddressProofModel. The AddressProofModel class has few fields, such as String documentCategory, String documentType, etc.

Now I want to set values for the fields of the nested object, for example:

addressProofModel.setDocumentCategory("category1")

based on condition of one of the input parameter 'profile' in the parent SalesMobilityApiModel object.

I using Drools decision tables and can't figure out how to do this.

SalesMobilityApiModel AddressProofModel

I have tried multiple things to set values for the fields inside the nested class 'AddressProofModel', but every time faced some exception.

Solution attempt

How can I update the fields in the child object?

0

There are 0 best solutions below