I\'m generating XML using JAXB. But JAXB is generating an empty Tag closing it self. But my client want separate empty tag. I know both are equals but he is not agree with m
Problem solved, To force a closing tag, just add an empty String as the value of this tag ! You can do it using @XmlValue :
public class closedTag { @XmlValue private String content; public closedTag() { this.content = ""; } }