Table of contents
Collapse the table of content
Expand the table of content

SecurityExtensions.GetAllUniqueRoleAssignments Method

SharePoint Dev Documents|Last Updated: 6/19/2017
1 Contributor

Get all unique role assignments for a web object and all its descendents down to document or list item level.

Assembly: OfficeDevPnP.Core.dll


public static IEnumerable<RoleAssignmentEntity> GetAllUniqueRoleAssignments(this Web web, Int32 leafBreadthLimit = 2147483647)



  Type: Microsoft.SharePoint.Client.Web
  The current web object to be processed.

(optional) leafBreadthLimit

  Type: System.Int32
  Skip further visiting on this branch if the number of child items or documents with unique role assignments exceeded leafBreadthLimit. When setting to 0, the process will stop at list / document library level.

Return Value

Type: IEnumerable
Returns all role assignments

See also

© 2018 Microsoft