List of usage examples for org.dom4j DocumentHelper createElement
public static Element createElement(String name)
From source file:com.zimbra.cs.client.soap.LmcPingRequest.java
License:Open Source License
protected Element getRequestXML() { Element request = DocumentHelper.createElement(AdminConstants.PING_REQUEST); return request; }
From source file:com.zimbra.cs.client.soap.LmcSaveDocumentRequest.java
License:Open Source License
protected Element getRequestXML() { Element request = DocumentHelper.createElement(MailConstants.SAVE_DOCUMENT_REQUEST); Element doc = DomUtil.add(request, MailConstants.E_DOC, ""); LmcSoapRequest.addAttrNotNull(doc, MailConstants.A_NAME, mDoc.getName()); LmcSoapRequest.addAttrNotNull(doc, MailConstants.A_CONTENT_TYPE, mDoc.getContentType()); LmcSoapRequest.addAttrNotNull(doc, MailConstants.A_FOLDER, mDoc.getFolder()); Element upload = DomUtil.add(doc, MailConstants.E_UPLOAD, ""); LmcSoapRequest.addAttrNotNull(upload, MailConstants.A_ID, mDoc.getAttachmentId()); return request; }
From source file:com.zimbra.cs.client.soap.LmcSearchGalRequest.java
License:Open Source License
protected Element getRequestXML() throws LmcSoapClientException { Element request = DocumentHelper.createElement(AccountConstants.SEARCH_GAL_REQUEST); DomUtil.add(request, AccountConstants.E_NAME, mName); return request; }
From source file:com.zimbra.cs.client.soap.LmcSearchRequest.java
License:Open Source License
protected Element createQuery(QName elemName) { Element request = DocumentHelper.createElement(elemName); // add all the attributes of the SearchRequest element addAttrNotNull(request, MailConstants.A_QUERY_LIMIT, mLimit); addAttrNotNull(request, MailConstants.A_QUERY_OFFSET, mOffset); addAttrNotNull(request, MailConstants.A_SEARCH_TYPES, mTypes); addAttrNotNull(request, MailConstants.A_SORTBY, mSortBy); // add the query element DomUtil.add(request, MailConstants.E_QUERY, mQuery); return request; }
From source file:com.zimbra.cs.client.soap.LmcSendMsgRequest.java
License:Open Source License
protected Element getRequestXML() { Element request = DocumentHelper.createElement(MailConstants.SEND_MSG_REQUEST); addMsg(request, mMsg, mInReplyTo, mFwdMsgID, mFwdPartNumbers); return request; }
From source file:com.zimbra.cs.client.soap.LmcTagActionRequest.java
License:Open Source License
protected Element getRequestXML() { Element request = DocumentHelper.createElement(MailConstants.TAG_ACTION_REQUEST); Element a = DomUtil.add(request, MailConstants.E_ACTION, ""); DomUtil.addAttr(a, MailConstants.A_OPERATION, mOp); DomUtil.addAttr(a, MailConstants.A_ID, mIDList); DomUtil.addAttr(a, MailConstants.A_NAME, mName); DomUtil.addAttr(a, MailConstants.A_COLOR, mColor); return request; }
From source file:com.zimbra.cs.dav.client.DavRequest.java
License:Open Source License
public static DavRequest PROPFIND(String uri) { DavRequest req = new DavRequest(uri, PROPFIND); Element root = DocumentHelper.createElement(DavElements.E_PROPFIND); root.addElement(DavElements.E_PROP); req.setRequestMessage(root);//from w ww . j a v a 2 s . c o m return req; }
From source file:com.zimbra.cs.dav.client.DavRequest.java
License:Open Source License
public static DavRequest CALENDARMULTIGET(String uri) { DavRequest req = new DavRequest(uri, REPORT); Element root = DocumentHelper.createElement(DavElements.E_CALENDAR_MULTIGET); root.addElement(DavElements.E_PROP); req.setRequestMessage(root);// ww w .ja v a 2s. c o m return req; }
From source file:com.zimbra.cs.dav.client.DavRequest.java
License:Open Source License
public static DavRequest EXPAND(String uri) { DavRequest req = new DavRequest(uri, REPORT); Element root = DocumentHelper.createElement(DavElements.E_EXPAND_PROPERTY); req.setRequestMessage(root);/*from w w w .ja v a 2s.co m*/ return req; }
From source file:com.zimbra.cs.dav.client.DavRequest.java
License:Open Source License
public static DavRequest CALENDARQUERY(String uri) { DavRequest req = new DavRequest(uri, REPORT); Element root = DocumentHelper.createElement(DavElements.E_CALENDAR_QUERY); root.addElement(DavElements.E_PROP); root.addElement(DavElements.E_FILTER).addElement(DavElements.E_COMP_FILTER).addAttribute(DavElements.P_NAME, "VCALENDAR"); req.setRequestMessage(root);/* w w w . j a va 2 s . c o m*/ return req; }