private String doUpload(Part[] parts, int msTimeout) throws ServiceException {
public String doUpload(Part[] parts, int msTimeout) throws ServiceException {
    private String doUpload(Part[] parts, int msTimeout) throws ServiceException {        String aid = null;                URI uri = getUploadURI();        HttpClient client = getHttpClient(uri);                // make the post        PostMethod post = new PostMethod(uri.toString());        client.getHttpConnectionManager().getParams().setConnectionTimeout(msTimeout);        int statusCode;        try {            post.setRequestEntity( new MultipartRequestEntity(parts, post.getParams()) );            statusCode = client.executeMethod(post);            // parse the response            if (statusCode == 200) {                String response = post.getResponseBodyAsString();                aid = getAttachmentId(response);                if (aid == null)                    throw ServiceException.FAILURE("Attachment post failed, unable to parse response: " + response, null);            } else {                throw ServiceException.FAILURE("Attachment post failed, status=" + statusCode, null);            }        } catch (IOException e) {            throw ZClientException.IO_ERROR(e.getMessage(), e);        } finally {            post.releaseConnection();        }        return aid;    }