| Summary: | Empty String ("") value incorrectly marshalled to XML | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | z_Archived | Reporter: | Blaise Doughan <blaise.doughan> | ||||||
| Component: | Eclipselink | Assignee: | Nobody - feel free to take it <nobody> | ||||||
| Status: | RESOLVED FIXED | QA Contact: | |||||||
| Severity: | normal | ||||||||
| Priority: | P3 | CC: | eclipselink.oxm-inbox, rick.barkhouse, tomlee | ||||||
| Version: | unspecified | ||||||||
| Target Milestone: | --- | ||||||||
| Hardware: | PC | ||||||||
| OS: | Windows XP | ||||||||
| Whiteboard: | |||||||||
| Attachments: |
|
||||||||
Created attachment 173581 [details]
MOXy - Test Cases
Created attachment 173582 [details]
MOXy - Fix
Fix checked into 2.1.1 at rev: 7755 Fix checked into trunk at rev: 7756 Code reviewed by: Matt MacIvor I'm seeing some behavior quite similar to this in a recent bug-fix release: org.eclipse.persistence.moxy_2.4.2.v20121206-a9d0e8d.jar org.eclipse.persistence.core_2.4.2.v20121206-a9d0e8d.jar Specifically, the parser handles <constant xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="xsd:string"> </constant> (a blank) but fails on <constant xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="xsd:string"></constant> (an empty string). Is there a chance that this bug has crept into the above interim release somehow? If there isn't a clear immediate resolution I'll post a new bug. Tom Hi Tom, From the information you've provided it's not clear that your issue is related to this bug fix. Could you please enter a new bug describing the problem that you are seeing, and please include as much information as possible. A standalone test case showing the issue is preferable, but if that is not possible, please send us more information about your object model, the XML being processed, and any stack traces that you are seeing. The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink |
Given the following object: import javax.xml.bind.annotation.XmlRootElement; @XmlRootElement public class Customer { private String name; public void setName(String name) { this.name = name; } public String getName() { return name; } } If the name is set to "", then the document should marshal as: <customer><name></name></customer> But is currently being marshalled as: <customer/>