private Collection<Attachment> setupAttachmentOutput(SoapMessage message) { // We have attachments, so add the interceptor message.getInterceptorChain().add(attachOut); // We should probably come up with another property for this message.put(AttachmentOutInterceptor.WRITE_ATTACHMENTS, Boolean.TRUE); Collection<Attachment> atts = message.getAttachments(); if (atts == null) { atts = new ArrayList<>(); message.setAttachments(atts); } return atts; } }
for (Attachment a : message.getAttachments()) { if (a.getId().startsWith(start)) { DataHandler dh = a.getDataHandler();
@Override public void handleMessage(SoapMessage message) throws Fault { Map<?, ?> providedAttachments = (Map<?, ?>) message.getContextualProperty(ATTACHMENTS); if (providedAttachments.isEmpty()) { return; } Collection<Attachment> attachments = message.getAttachments(); if (attachments == null) { attachments = new ArrayList<>(); message.setAttachments(attachments); } for (Map.Entry<?, ?> entry : providedAttachments.entrySet()) { attachments.add(new AttachmentImpl((String)entry.getKey(), (DataHandler)entry.getValue())); } message.put(AttachmentOutInterceptor.WRITE_ATTACHMENTS, Boolean.TRUE); } }
private Collection<Attachment> setupAttachmentOutput(SoapMessage message) { // We have attachments, so add the interceptor message.getInterceptorChain().add(attachOut); // We should probably come up with another property for this message.put(AttachmentOutInterceptor.WRITE_ATTACHMENTS, Boolean.TRUE); Collection<Attachment> atts = message.getAttachments(); if (atts == null) { atts = new ArrayList<>(); message.setAttachments(atts); } return atts; } }
boolean removeAttachments ) throws IOException { final Collection<org.apache.cxf.message.Attachment> attachments = soapMessage.getAttachments();
AttachmentResultCallback attachmentResultCallback = (AttachmentResultCallback) callback; if (soapMessage.getAttachments() == null) { soapMessage.setAttachments(new ArrayList<Attachment>()); final Collection<org.apache.cxf.message.Attachment> attachments = soapMessage.getAttachments(); String attachmentId = attachmentRemovalCallback.getAttachmentId(); if (attachmentId != null) { final Collection<org.apache.cxf.message.Attachment> attachments = soapMessage.getAttachments();
AttachmentResultCallback attachmentResultCallback = (AttachmentResultCallback) callback; if (soapMessage.getAttachments() == null) { soapMessage.setAttachments(new ArrayList<Attachment>()); final Collection<org.apache.cxf.message.Attachment> attachments = soapMessage.getAttachments(); String attachmentId = attachmentRemovalCallback.getAttachmentId(); if (attachmentId != null) { final Collection<org.apache.cxf.message.Attachment> attachments = soapMessage.getAttachments();
boolean removeAttachments ) throws IOException { final Collection<org.apache.cxf.message.Attachment> attachments = soapMessage.getAttachments();
for (Attachment a : message.getAttachments()) { if (a.getId().startsWith(start)) { DataHandler dh = a.getDataHandler();
if (message.getAttachments() == null) { message.setAttachments(new ArrayList<Attachment>(soapMessage .countAttachments())); att.setHeader(header.getName(), header.getValue()); message.getAttachments().add(att);
if (message.getAttachments() == null) { message.setAttachments(new ArrayList<Attachment>(soapMessage .countAttachments())); att.setHeader(header.getName(), header.getValue()); message.getAttachments().add(att);
dataBinding = p.getDataBinding(); DataReader<Node> dataReader = dataBinding.createReader(Node.class); dataReader.setAttachments(message.getAttachments()); dataReader.setProperty(DataReader.ENDPOINT, message.getExchange().getEndpoint()); dataReader.setProperty(Message.class.getName(), message);
dataBinding = p.getDataBinding(); DataReader<Node> dataReader = dataBinding.createReader(Node.class); dataReader.setAttachments(message.getAttachments()); dataReader.setProperty(DataReader.ENDPOINT, message.getExchange().getEndpoint()); dataReader.setProperty(Message.class.getName(), message);
final Collection<org.apache.cxf.message.Attachment> attachments = msg.getAttachments(); int attachmentCount = 0; if (attachments != null && !attachments.isEmpty()) {
final Collection<org.apache.cxf.message.Attachment> attachments = msg.getAttachments(); int attachmentCount = 0; if (attachments != null && !attachments.isEmpty()) {
Collection<Attachment> atts = message.getAttachments(); if (atts != null) { for (Attachment a : atts) {
Collection<Attachment> atts = message.getAttachments(); if (atts != null) { for (Attachment a : atts) {