01: /*
02: * soapUI, copyright (C) 2004-2007 eviware.com
03: *
04: * soapUI is free software; you can redistribute it and/or modify it under the
05: * terms of version 2.1 of the GNU Lesser General Public License as published by
06: * the Free Software Foundation.
07: *
08: * soapUI is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without
09: * even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10: * See the GNU Lesser General Public License for more details at gnu.org.
11: */
12:
13: package com.eviware.soapui.model.iface;
14:
15: import java.io.InputStream;
16:
17: /**
18: * Attachment for Requests and their responses
19: *
20: * @author Ole.Matzura
21: */
22:
23: public interface Attachment {
24: public String getName();
25:
26: public String getContentType();
27:
28: public void setContentType(String contentType);
29:
30: public long getSize();
31:
32: public String getPart();
33:
34: public void setPart(String part);
35:
36: public InputStream getInputStream() throws Exception;
37:
38: public String getUrl();
39:
40: public boolean isCached();
41:
42: public AttachmentType getAttachmentType();
43:
44: public enum AttachmentType {
45: MIME, XOP, CONTENT, SWAREF, UNKNOWN
46: }
47:
48: public String getContentID();
49:
50: public enum AttachmentEncoding {
51: BASE64, HEX, NONE
52: }
53:
54: public AttachmentEncoding getEncoding();
55: }
|