public QName getElementName(Class o) throws JAXBException { JaxBeanInfo bi = getBeanInfo(o,true); if(!bi.isElement()) return null; return new QName(bi.getElementNamespaceURI(o),bi.getElementLocalName(o)); }
public QName getElementName(Object o) throws JAXBException { JaxBeanInfo bi = getBeanInfo(o,true); if(!bi.isElement()) return null; return new QName(bi.getElementNamespaceURI(o),bi.getElementLocalName(o)); }
public XmlNode updateXML(Object jaxbObject, XmlNode xmlNode) throws JAXBException { if(jaxbObject==null || xmlNode==null) throw new IllegalArgumentException(); // TODO // for now just marshal // TODO: object model independenc Element e = (Element)xmlNode; Node ns = e.getNextSibling(); Node p = e.getParentNode(); p.removeChild(e); // if the type object is passed, the following step is necessary to make // the marshalling successful. JaxBeanInfo bi = context.getBeanInfo(jaxbObject, true); if(!bi.isElement()) jaxbObject = new JAXBElement(new QName(e.getNamespaceURI(),e.getLocalName()),bi.jaxbType,jaxbObject); getMarshaller().marshal(jaxbObject,p); Node newNode = p.getLastChild(); p.removeChild(newNode); p.insertBefore(newNode,ns); return (XmlNode)newNode; }
public QName getElementName(Class o) throws JAXBException { JaxBeanInfo bi = getBeanInfo(o,true); if(!bi.isElement()) return null; return new QName(bi.getElementNamespaceURI(o),bi.getElementLocalName(o)); }
public XmlNode updateXML(Object jaxbObject, XmlNode xmlNode) throws JAXBException { if(jaxbObject==null || xmlNode==null) throw new IllegalArgumentException(); // TODO // for now just marshal // TODO: object model independenc Element e = (Element)xmlNode; Node ns = e.getNextSibling(); Node p = e.getParentNode(); p.removeChild(e); // if the type object is passed, the following step is necessary to make // the marshalling successful. JaxBeanInfo bi = context.getBeanInfo(jaxbObject, true); if(!bi.isElement()) jaxbObject = new JAXBElement(new QName(e.getNamespaceURI(),e.getLocalName()),bi.jaxbType,jaxbObject); getMarshaller().marshal(jaxbObject,p); Node newNode = p.getLastChild(); p.removeChild(newNode); p.insertBefore(newNode,ns); return (XmlNode)newNode; }
public QName getElementName(Object o) throws JAXBException { JaxBeanInfo bi = getBeanInfo(o,true); if(!bi.isElement()) return null; return new QName(bi.getElementNamespaceURI(o),bi.getElementLocalName(o)); }
public QName getElementName(Object o) throws JAXBException { JaxBeanInfo bi = getBeanInfo(o,true); if(!bi.isElement()) return null; return new QName(bi.getElementNamespaceURI(o),bi.getElementLocalName(o)); }
public XmlNode updateXML(Object jaxbObject, XmlNode xmlNode) throws JAXBException { if(jaxbObject==null || xmlNode==null) throw new IllegalArgumentException(); // TODO // for now just marshal // TODO: object model independenc Element e = (Element)xmlNode; Node ns = e.getNextSibling(); Node p = e.getParentNode(); p.removeChild(e); // if the type object is passed, the following step is necessary to make // the marshalling successful. JaxBeanInfo bi = context.getBeanInfo(jaxbObject, true); if(!bi.isElement()) jaxbObject = new JAXBElement(new QName(e.getNamespaceURI(),e.getLocalName()),bi.jaxbType,jaxbObject); getMarshaller().marshal(jaxbObject,p); Node newNode = p.getLastChild(); p.removeChild(newNode); p.insertBefore(newNode,ns); return (XmlNode)newNode; }
public QName getElementName(Class o) throws JAXBException { JaxBeanInfo bi = getBeanInfo(o,true); if(!bi.isElement()) return null; return new QName(bi.getElementNamespaceURI(o),bi.getElementLocalName(o)); }
public XmlNode updateXML(Object jaxbObject, XmlNode xmlNode) throws JAXBException { if(jaxbObject==null || xmlNode==null) throw new IllegalArgumentException(); // TODO // for now just marshal // TODO: object model independenc Element e = (Element)xmlNode; Node ns = e.getNextSibling(); Node p = e.getParentNode(); p.removeChild(e); // if the type object is passed, the following step is necessary to make // the marshalling successful. JaxBeanInfo bi = context.getBeanInfo(jaxbObject, true); if(!bi.isElement()) jaxbObject = new JAXBElement(new QName(e.getNamespaceURI(),e.getLocalName()),bi.jaxbType,jaxbObject); getMarshaller().marshal(jaxbObject,p); Node newNode = p.getLastChild(); p.removeChild(newNode); p.insertBefore(newNode,ns); return (XmlNode)newNode; }
public QName getElementName(Object o) throws JAXBException { JaxBeanInfo bi = getBeanInfo(o,true); if(!bi.isElement()) return null; return new QName(bi.getElementNamespaceURI(o),bi.getElementLocalName(o)); }
public QName getElementName(Class o) throws JAXBException { JaxBeanInfo bi = getBeanInfo(o,true); if(!bi.isElement()) return null; return new QName(bi.getElementNamespaceURI(o),bi.getElementLocalName(o)); }