Skip to main content

UserInterface

Trait UserInterface 

Source
pub trait UserInterface: Send + Sync {
    // Required methods
    fn user_identifier(&self) -> &str;
    fn roles(&self) -> &[String];
}
Expand description

Authenticated (or anonymous) principal.

Required Methods§

Source

fn user_identifier(&self) -> &str

Stable user identifier (login, UUID, …).

Source

fn roles(&self) -> &[String]

Role names granted to this user.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§