I have been following Blaise Doughan blog .
In this example we trimmed only the <bio>........</bio>
section . so the output is
<html>...</html>
Without the trimming the String looks like
<?xml version="1.0" encoding="UTF-8"?><bio><html>...</html> </bio>
1. We are mapping the bio as an element , but why is it matched as a full xml ? (<xml ..>
)
@XmlAnyElement(BioHandler.class)
public String getBio() {
return bio;
}
2.In my case I don't have any predefined Tag for unknown Xml, So I don't know for sure what will be structure of my unknown Xml , So how can I get only the element section ? Every time I avoid the trimming code I get a small new xml inside my main xml .
<?xml version="1.0" encoding="UTF-8"?>
<customer>
<name>Jane Doe</name>
<?xml version="1.0" encoding="UTF-8"?>
<bio>
<html>...</html>
</bio>
</customer>