[Building Sakai] Get all roles in a site?

Adrian Fish adrian.r.fish at gmail.com
Tue Jul 9 13:53:02 PDT 2013


This should do it ...

Set<Role> roles = SiteService.getSite(SITEID).getRoles();

SiteService is in the kernel under org.sakaiproject.site.api

Cheers,
Adrian.


On 9 July 2013 21:10, Brian Jones <bjones86 at uwo.ca> wrote:

> Hi,
>
> I've been looking at the APIs but I can't see anything obvious that would
> help me with this. I'm hoping I can somehow retrieve a List<> of all Roles
> inside a give site (ID).
>
> Does anyone know anything that can help me with this? Ideally, I'd only
> like
> to identify all Roles in a site that have a certain permission enabled (but
> not in terms of a single user).
>
> Thanks in advance,
>
> Brian Jones
> Applications Development
> Information Technology Services
> Support Services Building, Room 4326
> Western University
> (519) 661-2111 x86969
> bjones86 at uwo.ca
>
>
>
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org
> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>
> TO UNSUBSCRIBE: send email to
> sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of
> "unsubscribe"
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20130709/e308ce12/attachment.html 


More information about the sakai-dev mailing list