Hi, if I remember correctly you have to use the namespace uri as the key in the HashMap and not the prefix. Try using this:
mappingNameSpaces.put("http://my_uri", "trn"); Kind regards Christian Kaltepoth On Wednesday 10 October 2007 16:25:22 Sandra Mendez wrote: > I would like to save un xml with a specific namespace. I tried the > following: Map mappingNameSpaces = new HashMap(); > mappingNameSpaces.put("trn", http://my_uri); > > XmlOptions xmlOptions = new XmlOptions(); > xmlOptions.setSaveOuter(); > xmlOptions.setSaveSuggestedPrefixes(mappingNameSpaces); > > ClassXmlBean.xmlText(xmlOptions)); > > I got my xml with no prefixe "trn". Does anyone know how to do this? > > > > ___________________________________________________________________________ >__ Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! > Mail -- Christian Kaltepoth <[EMAIL PROTECTED]> GnuPG Key: http://www.kaltepoth.de/gnupg/pubkey.asc Fingerprint: 9F04 0A94 CC40 C3EF 1A69 B2BB 51F4 4C84 BEB6 F127 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]