set_acl_sync


Description:

public bool set_acl_sync (string? uri, SList<WebDAVAccessControlEntry> entries, Cancellable? cancellable = null) throws Error

Changes Access Control List (ACL) for the uri, or, in case it's null, for the URI defined in associated Source.

Make sure that the entries satisfy ACL restrictions, as returned by get_acl_restrictions_sync. The order in the entries is preserved. It cannot contain any PROTECTED, nor E_WEBDAV_ACE_FLAG_INHERITED, items.

Use get_acl_sync to read currently known ACL entries, remove from the list those protected and inherited, and then modify the rest with the required changed.

Note this function doesn't support general PROPERTY and returns NOT_SUPPORTED error when any such is tried to be written.

In case the returned entries contain any PROPERTY, or there's a need to write such Access Control Entry, then do not use get_acl_sync, neither set_acl_sync , and write more generic implementation.

Parameters:

this

an WebDAVSession

uri

URI to issue the request for, or null to read from Source

entries

entries to write

cancellable

optional Cancellable object, or null

Returns:

Whether succeeded.