I want to generate xml file in this format.
<?xml version="1.0" encoding="UTF-8"?>
<Comprobante xmlns:cfdi="http://www.sat.gob.mx/cfd/3" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="3.0"
folio="779" fecha="2011-12-05T18:24:42"
sello="..."
formaDePago="PAGO EN UNA SOLA EXHIBICION" noCertificado="00001000000102160027" condicionesDePago="EFECTOS FISCALES AL PAGO"
subTotal="5123.23" total="5942.95" Moneda="USD" tipoDeComprobante="ingreso"
xsi:schemaLocation="http://www.sat.gob.mx/cfd/3 http://www.sat.gob.mx/sitio_internet/cfd/3/cfdv3.xsd">
<Emisor rfc="TIA050408342" nombre="TECNOLOGIAS DE INFORMACION AMERICA S.A. DE C.V.">
<DomicilioFiscal calle="Montecito" noExterior="38" noInterior="P 32-5" colonia="Napoles" localidad="Distrito Federal"
municipio="Distrito Federal" estado="México" pais="Mex." codigoPostal="03810" />
</Emisor>
<Addenda>
<ElementosClientesNormales xmlns:ext="http://www.buzone.com.mx/XSD/Sender19877/A"
xsi:schemaLocation="http://www.buzone.com.mx/XSD/Sender19877/A http://www.buzone.com.mx/XSD/Sender19877/A/Addenda.xsd">
<Conector>TEX9302097F3</Conector>
<CadenaOriginal>...about 1000 characters...</CadenaOriginal>
</Addenda>
</Comprobante>
As we know we ca create xml file using SAX parser or JAXB or dom4j
but still I am not able to generate tags like Comprobante:cfdi and add elements with it like folio="774" and so on.
Also how we can create tags like Emisor:cfdi rfc
How can I create such xml creation using java.? Any blog , tutorial that explains the way to create such xml file.
Thanks, Ran