
sec.roleExists( role-name as String ) as Boolean
This function returns true if the specified role exists in the security database.
| Parameters | |
|---|---|
| role-name | The role name. | 
http://marklogic.com/xdmp/privileges/get-role
  This function must be executed against the security database.
   
  const sec = require('/MarkLogic/security.xqy');
  sec.roleExists("my-role")