diamond.authentication.roles

Copyright © DiamondMVC 2019

Members

Classes

Role
class Role

Wrapper around a role.

Functions

addRole
Role addRole(string name)

Adds a new role.

addRole
Role addRole(string name, Role parent)

Adds a new role.

getRole
Role getRole(string name)

Gets a role by its name.

getRole
Role getRole(HttpClient client)

Gets a role by its request.

setDefaultRole
void setDefaultRole(Role role)

Sets the default role.

setRole
void setRole(HttpClient client, Role role)

Sets the role.

setRoleFromSession
bool setRoleFromSession(HttpClient client, bool defaultIsInvalid)

Sets the role from the session.

setSessionRole
void setSessionRole(HttpClient client, Role role)

Sets the session role.

Properties

hasRoles
bool hasRoles [@property getter]

Gets a boolean determining whether there are roles or not.

Static variables

defaultRole
Role defaultRole;

The default role.

Meta

Authors

Jacob Jensen (bausshf)