You are viewing a plain text version of this content. The canonical link for it is here.
Posted to wsif-dev@ws.apache.org by wh...@apache.org on 2003/03/12 12:42:42 UTC
cvs commit: xml-axis-wsif/java/src/org/apache/wsif WSIFAttachmentPart.java WSIFConstants.java
whitlock 2003/03/12 03:42:42
Modified: java/src/org/apache/wsif WSIFAttachmentPart.java
WSIFConstants.java
Log:
16993: better support for unreferenced attachments
Revision Changes Path
1.2 +24 -24 xml-axis-wsif/java/src/org/apache/wsif/WSIFAttachmentPart.java
Index: WSIFAttachmentPart.java
===================================================================
RCS file: /home/cvs/xml-axis-wsif/java/src/org/apache/wsif/WSIFAttachmentPart.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- WSIFAttachmentPart.java 7 Mar 2003 15:38:39 -0000 1.1
+++ WSIFAttachmentPart.java 12 Mar 2003 11:42:42 -0000 1.2
@@ -74,61 +74,61 @@
public class WSIFAttachmentPart /* implements Serializable */ {
private static final long serialVersionUID = 1L;
private transient DataHandler dh;
- private Map mimeHeaders;
+ private Map properties;
public WSIFAttachmentPart() {
Trc.entry(this);
this.dh = null;
- this.mimeHeaders = new HashMap();
+ this.properties = new HashMap();
Trc.exit();
}
public WSIFAttachmentPart(DataHandler dh) {
Trc.entry(this, dh);
this.dh = dh;
- this.mimeHeaders = new HashMap();
+ this.properties = new HashMap();
Trc.exit();
}
- public WSIFAttachmentPart(DataHandler dh, Map mimeHeaders)
+ public WSIFAttachmentPart(DataHandler dh, Map properties)
throws WSIFException {
- Trc.entry(this, dh, mimeHeaders);
- validateMimeHeaders(mimeHeaders);
+ Trc.entry(this, dh, properties);
+ validateProperties(properties);
this.dh = dh;
- this.mimeHeaders = mimeHeaders;
+ this.properties = properties;
Trc.exit();
}
- public void setMimeHeader(String name, String value) throws WSIFException {
+ public void setProperty(String name, String value) throws WSIFException {
Trc.entry(this, name, value);
- mimeHeaders.put(name, value);
+ properties.put(name, value);
Trc.exit();
}
- public void setMimeHeaders(Map mimeHeaders) throws WSIFException {
- Trc.entry(this, mimeHeaders);
- validateMimeHeaders(mimeHeaders);
- mimeHeaders.putAll(mimeHeaders);
+ public void setProperties(Map properties) throws WSIFException {
+ Trc.entry(this, properties);
+ validateProperties(properties);
+ properties.putAll(properties);
Trc.exit();
}
- public String getMimeHeader(String name) {
+ public String getProperty(String name) {
Trc.entry(this, name);
- String value = (String) mimeHeaders.get(name);
+ String value = (String) properties.get(name);
Trc.exit(value);
return value;
}
- public Iterator getMimeHeaderIterator() {
+ public Iterator getPropertyIterator() {
Trc.entry(this);
- Iterator it = mimeHeaders.keySet().iterator();
+ Iterator it = properties.keySet().iterator();
Trc.exit(it);
return it;
}
- public void clearMimeHeaders() {
+ public void clearProperties() {
Trc.entry(this);
- mimeHeaders = new HashMap();
+ properties = new HashMap();
Trc.exit();
}
@@ -144,14 +144,14 @@
Trc.exit();
}
- private void validateMimeHeaders(Map mimeHeaders) throws WSIFException {
- Trc.entry(this, mimeHeaders);
- Iterator it = mimeHeaders.keySet().iterator();
+ private void validateProperties(Map properties) throws WSIFException {
+ Trc.entry(this, properties);
+ Iterator it = properties.keySet().iterator();
while (it.hasNext()) {
String next = (String) it.next();
- if (!(mimeHeaders.get(next) instanceof String))
+ if (!(properties.get(next) instanceof String))
throw new WSIFException(
- "mimeHeader " + next + " was not a String.");
+ "Property " + next + " was not a String.");
}
Trc.exit();
}
1.23 +12 -0 xml-axis-wsif/java/src/org/apache/wsif/WSIFConstants.java
Index: WSIFConstants.java
===================================================================
RCS file: /home/cvs/xml-axis-wsif/java/src/org/apache/wsif/WSIFConstants.java,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -r1.22 -r1.23
--- WSIFConstants.java 7 Mar 2003 11:41:30 -0000 1.22
+++ WSIFConstants.java 12 Mar 2003 11:42:42 -0000 1.23
@@ -107,6 +107,12 @@
"wsif.syncrequest.timeout";
/**
+ * WSIF property for unreferenced attachments
+ */
+ public static final String WSIF_PROP_UNREFERENCED_ATTACHMENTS =
+ "wsif.unreferencedattachments";
+
+ /**
* WSIFCorelationService registered JNDI name
*/
public static final String CORRELATION_SERVICE_NAMESPACE =
@@ -195,6 +201,12 @@
*/
public static final String CONTEXT_SCHEMA_TYPES =
"org.apache.wsif.schematypes";
+
+ /**
+ *
+ */
+ public static final String UNREFERENCED_ATTACHMENT_PART_NAME =
+ "org.apache.wsif.attachments.unreferenced_attachment_part_name";
/**
* SOAP faults WSIFMessage part name for the fault code