public void setXMLMarshalHandler(XMLMarshalListener marshalListener) { setMarshalListener(marshalListener); }
public void setXMLMarshalHandler(XMLMarshalListener marshalListener) { setMarshalListener(marshalListener); }
public void setMarshalCallbacks(Map callbacks) { if(callbacks == null || callbacks.isEmpty()) { return; } if(xmlMarshaller.getMarshalListener() == null) { xmlMarshaller.setMarshalListener(new JAXBMarshalListener(jaxbContext, this)); } ((JAXBMarshalListener) xmlMarshaller.getMarshalListener()).setClassBasedMarshalEvents(callbacks); }
public void setMarshalCallbacks(Map callbacks) { if(callbacks == null || callbacks.isEmpty()) { return; } if(xmlMarshaller.getMarshalListener() == null) { xmlMarshaller.setMarshalListener(new JAXBMarshalListener(jaxbContext, this)); } ((JAXBMarshalListener) xmlMarshaller.getMarshalListener()).setClassBasedMarshalEvents(callbacks); }
public XMLMarshaller getXmlMarshaller() { XMLMarshaller marshaller = xmlMarshallerMap.get(Thread.currentThread()); if (marshaller == null) { marshaller = getXmlContext().createMarshaller(); marshaller.setMarshalListener(new SDOMarshalListener(marshaller, (SDOTypeHelper) aHelperContext.getTypeHelper())); xmlMarshallerMap.put(Thread.currentThread(), marshaller); } XMLContext context = getXmlContext(); if (marshaller.getXMLContext() != context) { marshaller.setXMLContext(context); } return marshaller; }
public XMLMarshaller getXmlMarshaller() { XMLMarshaller marshaller = xmlMarshallerMap.get(Thread.currentThread()); if (marshaller == null) { marshaller = getXmlContext().createMarshaller(); marshaller.setMarshalListener(new SDOMarshalListener(marshaller, (SDOTypeHelper) aHelperContext.getTypeHelper())); xmlMarshallerMap.put(Thread.currentThread(), marshaller); } XMLContext context = getXmlContext(); if (marshaller.getXMLContext() != context) { marshaller.setXMLContext(context); } return marshaller; }
@Override public void setListener(Marshaller.Listener listener) { if(xmlMarshaller.getMarshalListener() == null) { xmlMarshaller.setMarshalListener(new JAXBMarshalListener(jaxbContext, this)); } ((JAXBMarshalListener) xmlMarshaller.getMarshalListener()).setListener(listener); }
public void setListener(Marshaller.Listener listener) { if(xmlMarshaller.getMarshalListener() == null) { xmlMarshaller.setMarshalListener(new JAXBMarshalListener(jaxbContext, this)); } ((JAXBMarshalListener) xmlMarshaller.getMarshalListener()).setListener(listener); }
private XMLMarshaller getXmlMarshaller(Object options) { XMLMarshaller xmlMarshaller = getXmlMarshaller().clone(); if(null == options) { return xmlMarshaller; } try { DataObject optionsDO = (DataObject) options; if(optionsDO.isSet(SDOConstants.ATTACHMENT_MARSHALLER_OPTION)) { xmlMarshaller.setAttachmentMarshaller((XMLAttachmentMarshaller)optionsDO.get(SDOConstants.ATTACHMENT_MARSHALLER_OPTION)); } xmlMarshaller.setMarshalListener(new SDOMarshalListener(xmlMarshaller, (SDOTypeHelper) aHelperContext.getTypeHelper())); return xmlMarshaller; } catch(ClassCastException ccException) { throw SDOException.optionsMustBeADataObject(ccException, SDOConstants.ORACLE_SDO_URL ,SDOConstants.XMLHELPER_LOAD_OPTIONS); } }
private XMLMarshaller getXmlMarshaller(Object options) { XMLMarshaller xmlMarshaller = getXmlMarshaller().clone(); if(null == options) { return xmlMarshaller; } try { DataObject optionsDO = (DataObject) options; if(optionsDO.isSet(SDOConstants.ATTACHMENT_MARSHALLER_OPTION)) { xmlMarshaller.setAttachmentMarshaller((XMLAttachmentMarshaller)optionsDO.get(SDOConstants.ATTACHMENT_MARSHALLER_OPTION)); } xmlMarshaller.setMarshalListener(new SDOMarshalListener(xmlMarshaller, (SDOTypeHelper) aHelperContext.getTypeHelper())); return xmlMarshaller; } catch(ClassCastException ccException) { throw SDOException.optionsMustBeADataObject(ccException, SDOConstants.ORACLE_SDO_URL ,SDOConstants.XMLHELPER_LOAD_OPTIONS); } }