Difference between revisions of "InRole"

From SmartWiki
Jump to: navigation, search
Line 1: Line 1:
@me.inRole(Rolename)@
+
'''@me.inRole(Rolename)@'''
  
 
There are three things to use caution about this new and user-friendly syntax.
 
There are three things to use caution about this new and user-friendly syntax.
  
::Case Sensitive – Watch for lower case “i” and upper case “R”
+
*'''Case Sensitive''' – Watch for lower case “i” and upper case “R”
::Do not encapsulate the whole syntax – This syntax always returns a value, either true or false which mostly would not cause any problems for example in sslogic or visibility conditions. However encapsulation of the syntax would basically return a string which is useless if not equalled to another string.   
+
*'''Do not encapsulate the whole syntax''' – This syntax always returns a value, either true or false which mostly would not cause any problems for example in sslogic or visibility conditions. However encapsulation of the syntax would basically return a string which is useless if not equalled to another string.   
::Do not encapsulate the role name –  This I believe is looping the role names in the instance and tries to match what is in the brackets. Use the exact role name without encapsulating.
+
*'''Do not encapsulate the role name''' –  This I believe is looping the role names in the instance and tries to match what is in the brackets. Use the exact role name without encapsulating.
  
Correct:  @me.inRole(Organization Contact)@
+
 
Wrong: “@me.inRole(Organization Contact)@”
+
 
Wrong:  @me.inRole(“Organization Contact”)@
+
'''Correct''''''@me.inRole(Organization Contact)@'''
Wrong: “@me.inRole(“Organization Contact”)@”
+
 
Wrong:  @me.InRole(Organization Contact)@ OR @me.inrole(Organization Contact)@
+
'''Wrong''': “@me.inRole(Organization Contact)@”
 +
 
 +
'''Wrong''':  @me.inRole(“Organization Contact”)@
 +
 
 +
'''Wrong''': “@me.inRole(“Organization Contact”)@”
 +
 
 +
'''Wrong''':  @me.InRole(Organization Contact)@ OR @me.inrole(Organization Contact)@

Revision as of 14:48, 18 September 2012

@me.inRole(Rolename)@

There are three things to use caution about this new and user-friendly syntax.

  • Case Sensitive – Watch for lower case “i” and upper case “R”
  • Do not encapsulate the whole syntax – This syntax always returns a value, either true or false which mostly would not cause any problems for example in sslogic or visibility conditions. However encapsulation of the syntax would basically return a string which is useless if not equalled to another string.
  • Do not encapsulate the role name – This I believe is looping the role names in the instance and tries to match what is in the brackets. Use the exact role name without encapsulating.


Correct: @me.inRole(Organization Contact)@

Wrong: “@me.inRole(Organization Contact)@”

Wrong: @me.inRole(“Organization Contact”)@

Wrong: “@me.inRole(“Organization Contact”)@”

Wrong: @me.InRole(Organization Contact)@ OR @me.inrole(Organization Contact)@