€cdocutils.nodes
document
q)q}q(U	nametypesq}q(X   add/delete user rolesqNX
   list rolesqNX   rolesqNX   setupq	NX   get roleq
NX    useful object properties/methodsqNX   introqNX   list user global rolesqNuUsubstitution_defsq}qUparse_messagesq]qUcurrent_sourceqNU
decorationqNUautofootnote_startqKUnameidsq}q(hUadd-delete-user-rolesqhU
list-rolesqhUrolesqh	Usetupqh
Uget-roleqhU useful-object-properties-methodsqhUintroqhUlist-user-global-rolesquUchildrenq]q cdocutils.nodes
section
q!)q"}q#(U	rawsourceq$U Uparentq%hUsourceq&XJ   /Users/jamie/projects/php/php-opencloud/doc/services/identity/Roles.md.rstq'Utagnameq(Usectionq)U
attributesq*}q+(Udupnamesq,]Uclassesq-]Ubackrefsq.]Uidsq/]q0haUnamesq1]q2hauUlineq3KUdocumentq4hh]q5(cdocutils.nodes
title
q6)q7}q8(h$X   Rolesq9h%h"h&h'h(Utitleq:h*}q;(h,]h-]h.]h/]h1]uh3Kh4hh]q<cdocutils.nodes
Text
q=X   Rolesq>…q?}q@(h$h9h%h7ubaubh!)qA}qB(h$U h%h"h&h'h(h)h*}qC(h,]h-]h.]h/]qDhah1]qEhauh3Kh4hh]qF(h6)qG}qH(h$X   IntroqIh%hAh&h'h(h:h*}qJ(h,]h-]h.]h/]h1]uh3Kh4hh]qKh=X   IntroqL…qM}qN(h$hIh%hGubaubcdocutils.nodes
paragraph
qO)qP}qQ(h$X/  A role is a personality that a user assumes when performing a specific
set of operations. A role includes a set of rights and privileges. A
user assuming a role inherits the rights and privileges associated with
the role. A token that is issued to a user includes the list of roles
the user can assume. When a user calls a service, that service
determines how to interpret a user's roles. A role that grants access to
a list of operations or resources within one service may grant access to
a completely different list when interpreted by a different service.qRh%hAh&h'h(U	paragraphqSh*}qT(h,]h-]h.]h/]h1]uh3Kh4hh]qUh=X/  A role is a personality that a user assumes when performing a specific
set of operations. A role includes a set of rights and privileges. A
user assuming a role inherits the rights and privileges associated with
the role. A token that is issued to a user includes the list of roles
the user can assume. When a user calls a service, that service
determines how to interpret a user's roles. A role that grants access to
a list of operations or resources within one service may grant access to
a completely different list when interpreted by a different service.qV…qW}qX(h$hRh%hPubaubeubh!)qY}qZ(h$U h%h"h&h'h(h)h*}q[(h,]h-]h.]h/]q\hah1]q]h	auh3Kh4hh]q^(h6)q_}q`(h$X   Setupqah%hYh&h'h(h:h*}qb(h,]h-]h.]h/]h1]uh3Kh4hh]qch=X   Setupqd…qe}qf(h$hah%h_ubaubhO)qg}qh(h$Xq   Role objects are instantiated from the Identity service. For more
details, see the `Service <Service.md>`__ docs.h%hYh&h'h(hSh*}qi(h,]h-]h.]h/]h1]uh3Kh4hh]qj(h=XS   Role objects are instantiated from the Identity service. For more
details, see the qk…ql}qm(h$XS   Role objects are instantiated from the Identity service. For more
details, see the h%hgubcdocutils.nodes
reference
qn)qo}qp(h$X   `Service <Service.md>`__h*}qq(UnameX   ServiceUrefuriqrX
   Service.mdh/]h.]h,]h-]h1]uh%hgh]qsh=X   Serviceqt…qu}qv(h$U h%houbah(U	referenceqwubh=X    docs.qx…qy}qz(h$X    docs.h%hgubeubeubh!)q{}q|(h$U h%h"h&h'h(h)h*}q}(h,]h-]h.]h/]q~hah1]qhauh3Kh4hh]q€(h6)q}q‚(h$X    Useful object properties/methodsqƒh%h{h&h'h(h:h*}q„(h,]h-]h.]h/]h1]uh3Kh4hh]q…h=X    Useful object properties/methodsq†…q‡}qˆ(h$hƒh%hubaubcdocutils.nodes
table
q‰)qŠ}q‹(h$U h%h{h&h'h(UtableqŒh*}q(h,]h-]h.]h/]h1]uh3Nh4hh]qŽcdocutils.nodes
tgroup
q)q}q‘(h$U h*}q’(h/]h.]h,]h-]h1]UcolsKuh%hŠh]q“(cdocutils.nodes
colspec
q”)q•}q–(h$U h*}q—(h/]h.]h,]h-]h1]UcolwidthKuh%hh]h(Ucolspecq˜ubh”)q™}qš(h$U h*}q›(h/]h.]h,]h-]h1]UcolwidthKuh%hh]h(h˜ubh”)qœ}q(h$U h*}qž(h/]h.]h,]h-]h1]UcolwidthKuh%hh]h(h˜ubcdocutils.nodes
thead
qŸ)q }q¡(h$U h*}q¢(h,]h-]h.]h/]h1]uh%hh]q£cdocutils.nodes
row
q¤)q¥}q¦(h$U h*}q§(h,]h-]h.]h/]h1]uh%h h]q¨(cdocutils.nodes
entry
q©)qª}q«(h$U h*}q¬(h,]h-]h.]h/]h1]uh%h¥h]q­hO)q®}q¯(h$X   Propertyq°h%hªh&h'h(hSh*}q±(h,]h-]h.]h/]h1]uh3Kh]q²h=X   Propertyq³…q´}qµ(h$h°h%h®ubaubah(Uentryq¶ubh©)q·}q¸(h$U h*}q¹(h,]h-]h.]h/]h1]uh%h¥h]qºhO)q»}q¼(h$X   Getterq½h%h·h&h'h(hSh*}q¾(h,]h-]h.]h/]h1]uh3Kh]q¿h=X   GetterqÀ…qÁ}qÂ(h$h½h%h»ubaubah(h¶ubh©)qÃ}qÄ(h$U h*}qÅ(h,]h-]h.]h/]h1]uh%h¥h]qÆhO)qÇ}qÈ(h$X   SetterqÉh%hÃh&h'h(hSh*}qÊ(h,]h-]h.]h/]h1]uh3Kh]qËh=X   SetterqÌ…qÍ}qÎ(h$hÉh%hÇubaubah(h¶ubeh(UrowqÏubah(UtheadqÐubcdocutils.nodes
tbody
qÑ)qÒ}qÓ(h$U h*}qÔ(h,]h-]h.]h/]h1]uh%hh]qÕ(h¤)qÖ}q×(h$U h*}qØ(h,]h-]h.]h/]h1]uh%hÒh]qÙ(h©)qÚ}qÛ(h$U h*}qÜ(h,]h-]h.]h/]h1]uh%hÖh]qÝhO)qÞ}qß(h$X   idqàh%hÚh&h'h(hSh*}qá(h,]h-]h.]h/]h1]uh3Kh]qâh=X   idqã…qä}qå(h$hàh%hÞubaubah(h¶ubh©)qæ}qç(h$U h*}qè(h,]h-]h.]h/]h1]uh%hÖh]qéhO)qê}që(h$X   ``getId()``qìh%hæh&h'h(hSh*}qí(h,]h-]h.]h/]h1]uh3Kh]qîcdocutils.nodes
literal
qï)qð}qñ(h$hìh*}qò(h,]h-]h.]h/]h1]uh%hêh]qóh=X   getId()qô…qõ}qö(h$U h%hðubah(Uliteralq÷ubaubah(h¶ubh©)qø}qù(h$U h*}qú(h,]h-]h.]h/]h1]uh%hÖh]qûhO)qü}qý(h$X   ``setId()``qþh%høh&h'h(hSh*}qÿ(h,]h-]h.]h/]h1]uh3Kh]r   hï)r  }r  (h$hþh*}r  (h,]h-]h.]h/]h1]uh%hüh]r  h=X   setId()r  …r  }r  (h$U h%j  ubah(h÷ubaubah(h¶ubeh(hÏubh¤)r  }r	  (h$U h*}r
  (h,]h-]h.]h/]h1]uh%hÒh]r  (h©)r  }r  (h$U h*}r  (h,]h-]h.]h/]h1]uh%j  h]r  hO)r  }r  (h$X   namer  h%j  h&h'h(hSh*}r  (h,]h-]h.]h/]h1]uh3Kh]r  h=X   namer  …r  }r  (h$j  h%j  ubaubah(h¶ubh©)r  }r  (h$U h*}r  (h,]h-]h.]h/]h1]uh%j  h]r  hO)r  }r  (h$X   ``getName()``r  h%j  h&h'h(hSh*}r  (h,]h-]h.]h/]h1]uh3Kh]r   hï)r!  }r"  (h$j  h*}r#  (h,]h-]h.]h/]h1]uh%j  h]r$  h=X	   getName()r%  …r&  }r'  (h$U h%j!  ubah(h÷ubaubah(h¶ubh©)r(  }r)  (h$U h*}r*  (h,]h-]h.]h/]h1]uh%j  h]r+  hO)r,  }r-  (h$X   ``setName()``r.  h%j(  h&h'h(hSh*}r/  (h,]h-]h.]h/]h1]uh3Kh]r0  hï)r1  }r2  (h$j.  h*}r3  (h,]h-]h.]h/]h1]uh%j,  h]r4  h=X	   setName()r5  …r6  }r7  (h$U h%j1  ubah(h÷ubaubah(h¶ubeh(hÏubh¤)r8  }r9  (h$U h*}r:  (h,]h-]h.]h/]h1]uh%hÒh]r;  (h©)r<  }r=  (h$U h*}r>  (h,]h-]h.]h/]h1]uh%j8  h]r?  hO)r@  }rA  (h$X   descriptionrB  h%j<  h&h'h(hSh*}rC  (h,]h-]h.]h/]h1]uh3K h]rD  h=X   descriptionrE  …rF  }rG  (h$jB  h%j@  ubaubah(h¶ubh©)rH  }rI  (h$U h*}rJ  (h,]h-]h.]h/]h1]uh%j8  h]rK  hO)rL  }rM  (h$X   ``getDescription()``rN  h%jH  h&h'h(hSh*}rO  (h,]h-]h.]h/]h1]uh3K h]rP  hï)rQ  }rR  (h$jN  h*}rS  (h,]h-]h.]h/]h1]uh%jL  h]rT  h=X   getDescription()rU  …rV  }rW  (h$U h%jQ  ubah(h÷ubaubah(h¶ubh©)rX  }rY  (h$U h*}rZ  (h,]h-]h.]h/]h1]uh%j8  h]r[  hO)r\  }r]  (h$X   ``setDescription()``r^  h%jX  h&h'h(hSh*}r_  (h,]h-]h.]h/]h1]uh3K h]r`  hï)ra  }rb  (h$j^  h*}rc  (h,]h-]h.]h/]h1]uh%j\  h]rd  h=X   setDescription()re  …rf  }rg  (h$U h%ja  ubah(h÷ubaubah(h¶ubeh(hÏubeh(Utbodyrh  ubeh(Utgroupri  ubaubeubh!)rj  }rk  (h$U h%h"h&h'h(h)h*}rl  (h,]h-]h.]h/]rm  hah1]rn  hauh3K$h4hh]ro  (h6)rp  }rq  (h$X
   List rolesrr  h%jj  h&h'h(h:h*}rs  (h,]h-]h.]h/]h1]uh3K$h4hh]rt  h=X
   List rolesru  …rv  }rw  (h$jr  h%jp  ubaubhO)rx  }ry  (h$XF   This call lists the global roles available within a specified service.rz  h%jj  h&h'h(hSh*}r{  (h,]h-]h.]h/]h1]uh3K&h4hh]r|  h=XF   This call lists the global roles available within a specified service.r}  …r~  }r  (h$jz  h%jx  ubaubcdocutils.nodes
literal_block
r€  )r  }r‚  (h$XG   $roles = $service->getRoles();

foreach ($roles as $role) {
   // ...
}h%jj  h&h'h(Uliteral_blockrƒ  h*}r„  (U	xml:spacer…  Upreserver†  h/]h.]h,]h-]r‡  (Ucoderˆ  X   phpr‰  eh1]uh3K/h4hh]rŠ  cdocutils.nodes
inline
r‹  )rŒ  }r  (h$XG   $roles = $service->getRoles();

foreach ($roles as $role) {
   // ...
}h*}rŽ  (h,]h-]r  Uotherr  ah.]h/]h1]uh%j  h]r‘  h=XG   $roles = $service->getRoles();

foreach ($roles as $role) {
   // ...
}r’  …r“  }r”  (h$U h%jŒ  ubah(Uinliner•  ubaubhO)r–  }r—  (h$X]   For more information about how to use iterators, see the
`documentation <../Iterators.md>`__.h%jj  h&h'h(hSh*}r˜  (h,]h-]h.]h/]h1]uh3K0h4hh]r™  (h=X9   For more information about how to use iterators, see the
rš  …r›  }rœ  (h$X9   For more information about how to use iterators, see the
h%j–  ubhn)r  }rž  (h$X#   `documentation <../Iterators.md>`__h*}rŸ  (UnameX   documentationhrX   ../Iterators.mdh/]h.]h,]h-]h1]uh%j–  h]r   h=X   documentationr¡  …r¢  }r£  (h$U h%j  ubah(hwubh=X   .…r¤  }r¥  (h$X   .h%j–  ubeubeubh!)r¦  }r§  (h$U h%h"h&h'h(h)h*}r¨  (h,]h-]h.]h/]r©  hah1]rª  h
auh3K4h4hh]r«  (h6)r¬  }r­  (h$X   Get roler®  h%j¦  h&h'h(h:h*}r¯  (h,]h-]h.]h/]h1]uh3K4h4hh]r°  h=X   Get roler±  …r²  }r³  (h$j®  h%j¬  ubaubhO)r´  }rµ  (h$XR   This call lists detailed information (id, name, description) for a
specified role.r¶  h%j¦  h&h'h(hSh*}r·  (h,]h-]h.]h/]h1]uh3K6h4hh]r¸  h=XR   This call lists detailed information (id, name, description) for a
specified role.r¹  …rº  }r»  (h$j¶  h%j´  ubaubj€  )r¼  }r½  (h$X7   $roleId = '123abc';
$role = $service->getRole($roleId);h%j¦  h&h'h(jƒ  h*}r¾  (j…  j†  h/]h.]h,]h-]r¿  (jˆ  X   phprÀ  eh1]uh3K=h4hh]rÁ  j‹  )rÂ  }rÃ  (h$X7   $roleId = '123abc';
$role = $service->getRole($roleId);h*}rÄ  (h,]h-]rÅ  UotherrÆ  ah.]h/]h1]uh%j¼  h]rÇ  h=X7   $roleId = '123abc';
$role = $service->getRole($roleId);rÈ  …rÉ  }rÊ  (h$U h%jÂ  ubah(j•  ubaubeubh!)rË  }rÌ  (h$U h%h"h&h'h(h)h*}rÍ  (h,]h-]h.]h/]rÎ  hah1]rÏ  hauh3K?h4hh]rÐ  (h6)rÑ  }rÒ  (h$X   Add/delete user rolesrÓ  h%jË  h&h'h(h:h*}rÔ  (h,]h-]h.]h/]h1]uh3K?h4hh]rÕ  h=X   Add/delete user rolesrÖ  …r×  }rØ  (h$jÓ  h%jÑ  ubaubhO)rÙ  }rÚ  (h$XR   To add/remove user roles, you must first instantiate a
`user <Users.md>`__ object:h%jË  h&h'h(hSh*}rÛ  (h,]h-]h.]h/]h1]uh3KAh4hh]rÜ  (h=X7   To add/remove user roles, you must first instantiate a
rÝ  …rÞ  }rß  (h$X7   To add/remove user roles, you must first instantiate a
h%jÙ  ubhn)rà  }rá  (h$X   `user <Users.md>`__h*}râ  (UnameX   userhrX   Users.mdh/]h.]h,]h-]h1]uh%jÙ  h]rã  h=X   userrä  …rå  }ræ  (h$U h%jà  ubah(hwubh=X    object:rç  …rè  }ré  (h$X    object:h%jÙ  ubeubj€  )rê  }rë  (h$Xw   $roleId = '123abc';

// add role to user
$user->addRole($roleId);

// remove role from user
$user->removeRole($roleId);h%jË  h&h'h(jƒ  h*}rì  (j…  j†  h/]h.]h,]h-]rí  (jˆ  X   phprî  eh1]uh3KMh4hh]rï  j‹  )rð  }rñ  (h$Xw   $roleId = '123abc';

// add role to user
$user->addRole($roleId);

// remove role from user
$user->removeRole($roleId);h*}rò  (h,]h-]ró  Uotherrô  ah.]h/]h1]uh%jê  h]rõ  h=Xw   $roleId = '123abc';

// add role to user
$user->addRole($roleId);

// remove role from user
$user->removeRole($roleId);rö  …r÷  }rø  (h$U h%jð  ubah(j•  ubaubeubh!)rù  }rú  (h$U h%h"h&h'h(h)h*}rû  (h,]h-]h.]h/]rü  hah1]rý  hauh3KOh4hh]rþ  (h6)rÿ  }r   (h$X   List user global rolesr  h%jù  h&h'h(h:h*}r  (h,]h-]h.]h/]h1]uh3KOh4hh]r  h=X   List user global rolesr  …r  }r  (h$j  h%jÿ  ubaubhO)r  }r  (h$X@   This call returns a list of global roles associated with a user:r	  h%jù  h&h'h(hSh*}r
  (h,]h-]h.]h/]h1]uh3KQh4hh]r  h=X@   This call returns a list of global roles associated with a user:r  …r  }r  (h$j	  h%j  ubaubj€  )r  }r  (h$XD   $roles = $user->getRoles();

foreach ($roles as $role) {
   // ...
}h%jù  h&h'h(jƒ  h*}r  (j…  j†  h/]h.]h,]h-]r  (jˆ  X   phpr  eh1]uh3KZh4hh]r  j‹  )r  }r  (h$XD   $roles = $user->getRoles();

foreach ($roles as $role) {
   // ...
}h*}r  (h,]h-]r  Uotherr  ah.]h/]h1]uh%j  h]r  h=XD   $roles = $user->getRoles();

foreach ($roles as $role) {
   // ...
}r  …r  }r  (h$U h%j  ubah(j•  ubaubhO)r  }r  (h$X]   For more information about how to use iterators, see the
`documentation <../Iterators.md>`__.h%jù  h&h'h(hSh*}r   (h,]h-]h.]h/]h1]uh3K[h4hh]r!  (h=X9   For more information about how to use iterators, see the
r"  …r#  }r$  (h$X9   For more information about how to use iterators, see the
h%j  ubhn)r%  }r&  (h$X#   `documentation <../Iterators.md>`__h*}r'  (UnameX   documentationhrX   ../Iterators.mdh/]h.]h,]h-]h1]uh%j  h]r(  h=X   documentationr)  …r*  }r+  (h$U h%j%  ubah(hwubh=X   .…r,  }r-  (h$X   .h%j  ubeubeubeubah$U Utransformerr.  NUfootnote_refsr/  }r0  Urefnamesr1  }r2  Usymbol_footnotesr3  ]r4  Uautofootnote_refsr5  ]r6  Usymbol_footnote_refsr7  ]r8  U	citationsr9  ]r:  h4hUcurrent_liner;  NUtransform_messagesr<  ]r=  Ureporterr>  NUid_startr?  KUautofootnotesr@  ]rA  Ucitation_refsrB  }rC  Uindirect_targetsrD  ]rE  UsettingsrF  (cdocutils.frontend
Values
rG  orH  }rI  (Ufootnote_backlinksrJ  KUrecord_dependenciesrK  NUrfc_base_urlrL  Uhttp://tools.ietf.org/html/rM  U	tracebackrN  ˆUpep_referencesrO  NUstrip_commentsrP  NUtoc_backlinksrQ  h¶Ulanguage_coderR  UenrS  U	datestamprT  NUreport_levelrU  KU_destinationrV  NU
halt_levelrW  KUstrip_classesrX  Nh:NUerror_encoding_error_handlerrY  UbackslashreplacerZ  Udebugr[  NUembed_stylesheetr\  ‰Uoutput_encoding_error_handlerr]  Ustrictr^  Usectnum_xformr_  KUdump_transformsr`  NUdocinfo_xformra  KUwarning_streamrb  NUpep_file_url_templaterc  Upep-%04drd  Uexit_status_levelre  KUconfigrf  NUstrict_visitorrg  NUcloak_email_addressesrh  ˆUtrim_footnote_reference_spaceri  ‰Uenvrj  NUdump_pseudo_xmlrk  NUexpose_internalsrl  NUsectsubtitle_xformrm  ‰Usource_linkrn  NUrfc_referencesro  NUoutput_encodingrp  Uutf-8rq  U
source_urlrr  NUinput_encodingrs  U	utf-8-sigrt  U_disable_configru  NU	id_prefixrv  U U	tab_widthrw  KUerror_encodingrx  UUTF-8ry  U_sourcerz  h'Ugettext_compactr{  ˆU	generatorr|  NUdump_internalsr}  NUsmart_quotesr~  ‰Upep_base_urlr  Uhttp://www.python.org/dev/peps/r€  Usyntax_highlightr  Ulongr‚  Uinput_encoding_error_handlerrƒ  j^  Uauto_id_prefixr„  Uidr…  Udoctitle_xformr†  ‰Ustrip_elements_with_classesr‡  NU_config_filesrˆ  ]Ufile_insertion_enabledr‰  ˆUraw_enabledrŠ  KUdump_settingsr‹  NubUsymbol_footnote_startrŒ  K Uidsr  }rŽ  (hjË  hj¦  hh"hhYhjj  hhAhh{hjù  uUsubstitution_namesr  }r  h(h4h*}r‘  (h,]h/]h.]Usourceh'h-]h1]uU	footnotesr’  ]r“  Urefidsr”  }r•  ub.