function addAttachmentReturn = addAttachment(obj,in0,in1,in2,in3)
%addAttachment(obj,in0,in1,in2,in3)
%
%     Input:
%       in0 = (string)
%       in1 = (long)
%       in2.comment = (string)
%       in2.contentType = (string)
%       in2.created = (dateTime)
%       in2.creator = (string)
%       in2.fileName = (string)
%       in2.fileSize = (long)
%       in2.id = (long)
%       in2.pageId = (long)
%       in2.title = (string)
%       in2.url = (string)
%       in3 = (base64Binary)
%   
%     Output:
%       addAttachmentReturn.comment = (string)
%       addAttachmentReturn.contentType = (string)
%       addAttachmentReturn.created = (dateTime)
%       addAttachmentReturn.creator = (string)
%       addAttachmentReturn.fileName = (string)
%       addAttachmentReturn.fileSize = (long)
%       addAttachmentReturn.id = (long)
%       addAttachmentReturn.pageId = (long)
%       addAttachmentReturn.title = (string)
%       addAttachmentReturn.url = (string)

% Build up the argument lists.
values = { ...
   in0, ...
   in1, ...
   in2, ...
   in3, ...
   };
names = { ...
   'in0', ...
   'in1', ...
   'in2', ...
   'in3', ...
   };
types = { ...
   '{http://www.w3.org/2001/XMLSchema}string', ...
   'long', ...
   '', ...
   'base64Binary', ...
   };

% Create the message, make the call, and convert the response into a variable.
soapMessage = createSoapMessage( ...
    'http://soap.rpc.confluence.atlassian.com', ...
    'addAttachment', ...
    values,names,types,'rpc');
response = callSoapService( ...
    obj.endpoint, ...
    '', ...
    soapMessage);
addAttachmentReturn = parseSoapResponse(response);
