public static Element stringToDOM(byte[] bytes) throws SAXException, IOException { return stringToDOM(new String(bytes)); }
/** * De-serialization routines. * * @see Serializable */ private void readObject(java.io.ObjectInputStream in) throws IOException, ClassNotFoundException { try { e = DOMUtils.stringToDOM((String)in.readObject()); } catch (SAXException e) { __log.error("De-serialization eror", e); throw new IOException(e.getMessage()); } }
public List<Element> getExtensionElement(QName qname) { try { return DOMUtils.findChildrenByName(DOMUtils.stringToDOM(_pinfo.toString()), qname); } catch (Exception e) { return Collections.emptyList(); } }
public List<Element> getExtensionElement(QName qname) { try { return DOMUtils.findChildrenByName(DOMUtils.stringToDOM(_pinfo.toString()), qname); } catch (Exception e) { return Collections.emptyList(); } }
public List<Element> getExtensionElement(QName name) { try { return DOMUtils.findChildrenByName(DOMUtils.stringToDOM(processInfo.toString()), name); } catch (Exception e) { return Collections.emptyList(); } }
protected Invocation addInvoke(String id, QName target, String operation, String request, String responsePattern, Invocation synchronizeWith) throws Exception { Invocation inv = new Invocation(id, synchronizeWith); inv.target = target; inv.operation = operation; inv.request = DOMUtils.stringToDOM(request); inv.expectedStatus = null; if (responsePattern != null) { inv.expectedFinalStatus = MessageExchange.Status.RESPONSE; inv.expectedResponsePattern = Pattern.compile(responsePattern, Pattern.DOTALL); } _invocations.add(inv); return inv; }
public Element getCallbackEPR() { entering("MessageExchangeDaoImpl.getCallbackEPR"); byte[] endpoint = _hself.getCallbackEndpoint(); if (endpoint == null) return null; try { return DOMUtils.stringToDOM(endpoint); } catch (Exception e) { throw new RuntimeException(e); } }
public Element getEPR() { entering("MessageExchangeDaoImpl.getEPR"); byte[] endpoint = _hself.getEndpoint(); if (endpoint == null) return null; try { return DOMUtils.stringToDOM(endpoint); } catch (Exception e) { throw new RuntimeException(e); } }
public Element getData() { entering("FaultDAOImpl.getData"); if (_self.getData() == null) return null; try { return DOMUtils.stringToDOM(_self.getData()); } catch (SAXException e) { throw new RuntimeException(e); } catch (IOException e) { throw new RuntimeException(e); } }
public Element getDetails() { entering("ActivityRecoveryDaoImpl.getDetails"); if (_self.getDetails() == null) { return null; } try { return DOMUtils.stringToDOM(_self.getDetails()); } catch (SAXException e) { throw new RuntimeException(e); } catch (IOException e) { throw new RuntimeException(e); } }
public Element getPartnerEPR() { entering("PartnerLinkDAOImpl.getPartnerEPR"); if (_partnerEPR != null) return _partnerEPR; if (_self.getPartnerEPR() == null) return null; try { return _partnerEPR = DOMUtils.stringToDOM(_self.getPartnerEPR()); } catch (Exception e) { throw new RuntimeException(e); } }
public Element getData() { entering("MessageDaoImpl.getData"); if (_hself.getMessageData() == null) return null; try { return DOMUtils.stringToDOM(_hself.getMessageData()); } catch (Exception e) { throw new RuntimeException(e); } }
public Element getHeader() { entering("MessageDaoImpl.getHeader"); if (_hself.getHeader() == null) return null; try { return DOMUtils.stringToDOM(_hself.getHeader()); } catch (Exception e) { throw new RuntimeException(e); } }
public Element getMyEPR() { entering("PartnerLinkDAOImpl.getMyEPR"); if (_myEPR != null) return _myEPR; if (_self.getMyEPR() == null) return null; try { return DOMUtils.stringToDOM(_self.getMyEPR()); } catch (Exception e) { throw new RuntimeException(e); } }
public Element getSourceEPR(String mexId) { MessageExchangeDAO dao = _dao.getConnection().getMessageExchange(mexId); String epr = dao.getProperty(MessageExchange.PROPERTY_SEP_PARTNERROLE_EPR); if (epr == null) return null; try { Element eepr = DOMUtils.stringToDOM(epr); return eepr; } catch (Exception ex) { __log.error("Invalid value for SEP property " + MessageExchange.PROPERTY_SEP_PARTNERROLE_EPR + ": " + epr); } return null; }
Result result = new StreamResult(writer); tf.transform(source, result); node = DOMUtils.stringToDOM(writer.toString()); } else { DOMResult result = new DOMResult();
Element response = null; try { faultResponse = DOMUtils.stringToDOM(faultData.toString()); response = DOMUtils.stringToDOM(responseData.toString()); } catch (SAXException e) {
odeMsg.setHeaderPart(header.getLocalPart(), DOMUtils.stringToDOM(DOMUtils.domToString(headers.get(header)))); } catch (Exception e) { __log.error("Can't copy input header " + header);
private Node prepare(){ if(_data.isSimpleType()) { String data; if (_data.getSimpleValue() != null) { data = _data.getSimpleValue(); } else { if(_data.getData() == null || _data.getData().length == 0) return null; data = new String(_data.getData()); } Document d = DOMUtils.newDocument(); // we create a dummy wrapper element // prevents some apps from complaining // when text node is not actual child of document Element e = d.createElement("temporary-simple-type-wrapper"); Text tnode = d.createTextNode(data); d.appendChild(e); e.appendChild(tnode); return tnode; } else { if(_data.getData() == null || _data.getData().length == 0) return null; String data = new String(_data.getData()); try{ return DOMUtils.stringToDOM(data); }catch(Exception e){ throw new RuntimeException(e); } } }
Element literalRoot; try { literalRoot = DOMUtils.stringToDOM(literal); } catch (Exception e) { throw new RuntimeException("XML literal parsing failed " + literal, e);