Method
EDataServerWebDAVSessionpost_sync
since: 3.32
Declaration [src]
gboolean
e_webdav_session_post_sync (
EWebDAVSession* webdav,
const gchar* uri,
const gchar* data,
gsize data_length,
const gchar* in_content_type,
SoupMessageHeaders* in_headers,
gchar** out_content_type,
SoupMessageHeaders** out_headers,
GByteArray** out_content,
GCancellable* cancellable,
GError** error
)
Description [src]
Issues POST request on the provided uri, or, in case it’s NULL, on the URI
defined in associated ESource.
The optional in_headers can contain additional headers to be added to the request.
These headers replace any existing in the request headers, without support for the list-values headers.
The optional out_content_type can be used to get content type of the response.
Free it with g_free(), when no longer needed.
The optional out_headers contains response headers. Free it with soup_message_headers_free(),
when no longer needed.
The optional out_content can be used to get actual result content. Free it
with g_byte_array_free(), when no longer needed.
Available since: 3.32
Parameters
uri-
Type:
const gchar*URI to issue the request for, or
NULLto read fromESource.The argument can be NULL.The data is owned by the caller of the method. The value is a NUL terminated UTF-8 string. data-
Type:
const gchar*Data to post to the server.
The data is owned by the caller of the method. The value is a NUL terminated UTF-8 string. data_length-
Type:
gsizeLength of
data, or -1, whendatais NUL-terminated. in_content_type-
Type:
const gchar*A Content-Type of the
data, orNULL, to use application/xml.The argument can be NULL.The data is owned by the caller of the method. The value is a NUL terminated UTF-8 string. in_headers-
Type:
SoupMessageHeadersAdditional
SoupMessageHeadersto be added to the request, orNULL.The argument can be NULL.The data is owned by the caller of the method. out_content_type-
Type:
gchar**Return location for response Content-Type, or
NULL.The argument will be set by the function. The argument can be set to NULLby the method.The caller of the method takes ownership of the returned data, and is responsible for freeing it. The value is a NUL terminated UTF-8 string. out_headers-
Type:
SoupMessageHeadersOptional return location for response
SoupMessageHeaders, orNULL.The argument will be set by the function. The argument can be NULL.The caller of the method takes ownership of the returned data, and is responsible for freeing it. out_content-
Type: An array of
guint8Return location for response content, or
NULL.The argument will be set by the function. The argument can be set to NULLby the method.The caller of the method takes ownership of the returned data, and is responsible for freeing it. cancellable-
Type:
GCancellableOptional
GCancellableobject, orNULL.The argument can be NULL.The data is owned by the caller of the method. error-
Type:
GError **The return location for a recoverable error.
The argument can be NULL.If the return location is not NULL, then you must initialize it to aNULLGError*.The argument will be left initialized to NULLby the method if there are no errors.In case of error, the argument will be set to a newly allocated GError; the caller will take ownership of the data, and be responsible for freeing it.