Hi,
I've got a value object, which stores info for example amount. The getAmount() getter returns amount in cents. However in various places, we need to get amount in dollar. There are 2 approaches I can think of:
- write a convert method and place it in a utility class.
- add a getAmountInDollar() getter in the value object.
I prefer the second approach. What do you think? What are pros and cons of both approaches?