@XmlTransient annotation is applied while marshalling and unmarshalling. But if we want to have this property to be transient only during marshalling, bit of tweaking needs to be performed.
A new listener is created to apply custom transformations right before actual marshalling and attached it to the JAXB context.
New annotation is added to support our semi transient feature.

Test is modified accordingly