code: public void checkRole(CmsObject cms, CmsRole role) throws CmsRoleViolationException {
  
          m_securityManager.checkRole(cms.getRequestContext(), role);
      }
docs: Checks if the user of this OpenCms context is a member of the given role
  for the given organizational unit.<p>
  
  The user must have the given role in at least one parent organizational unit.<p>
  
  @param cms the opencms context
  @param role the role to check
  
  @throws CmsRoleViolationException if the user does not have the required role permissions