AdminStore

class gafaelfawr.storage.admin.AdminStore(session)

Bases: object

Stores and retrieves token administrators.

Parameters:

session (async_scoped_session) – The database session proxy.

Methods Summary

add(admin)

Add a new token administrator.

delete(admin)

Delete an administrator.

list()

Return a list of current administrators.

Methods Documentation

async add(admin)

Add a new token administrator.

Parameters:

admin (Admin) – The administrator to add.

Return type:

None

async delete(admin)

Delete an administrator.

Parameters:

admin (Admin) – The administrator to delete.

Returns:

True if the administrator was found and deleted, False otherwise.

Return type:

bool

async list()

Return a list of current administrators.

Returns:

Current administrators.

Return type:

list of Admin