}
public String addMtomAttachment(byte[] data, int offset, int length, String mimeType, String elementNS,
String elementLocalName) {
Attachment att = AttachmentUtil.createMtomAttachment(
isXop, mimeType, elementNS, data, offset, length, threshold);
if (att != null) {
atts.add(att);
lastElementName = new QName(elementNS, elementLocalName);
return "cid:" + att.getId();
} else {
return null;
}
}