OpenMod Docs OpenMod Docs
OpenMod Docs OpenMod Docs
OpenMod .NET Plugin Framework.

Class PermissionRolesDataStore

Inheritance
System.Object
PermissionRolesDataStore
Implements
IPermissionRolesDataStore
IDisposable
Namespace: OpenMod.Core.Permissions
Assembly: OpenMod.Core.dll
Syntax
public class PermissionRolesDataStore : object, IPermissionRolesDataStore, IDisposable

Constructors

| Improve this Doc View Source

PermissionRolesDataStore(ILogger<PermissionRolesDataStore>, IOpenModDataStoreAccessor, IRuntime, IEventBus)

Declaration
public PermissionRolesDataStore(ILogger<PermissionRolesDataStore> logger, IOpenModDataStoreAccessor dataStoreAccessor, IRuntime runtime, IEventBus eventBus)
Parameters
Type Name Description
ILogger<PermissionRolesDataStore> logger
IOpenModDataStoreAccessor dataStoreAccessor
IRuntime runtime
IEventBus eventBus

Fields

| Improve this Doc View Source

RolesKey

Declaration
public const string RolesKey = null
Field Value
Type Description
System.String

Properties

| Improve this Doc View Source

Roles

Declaration
public List<PermissionRoleData> Roles { get; }
Property Value
Type Description
List<PermissionRoleData>

Methods

| Improve this Doc View Source

Dispose()

Declaration
public void Dispose()
| Improve this Doc View Source

ExistsAsync()

Declaration
public virtual Task<bool> ExistsAsync()
Returns
Type Description
Task<System.Boolean>
| Improve this Doc View Source

GetRoleAsync(String)

Declaration
public Task<PermissionRoleData> GetRoleAsync(string id)
Parameters
Type Name Description
System.String id
Returns
Type Description
Task<PermissionRoleData>
| Improve this Doc View Source

GetRoleDataAsync<T>(String, String)

Declaration
public Task<T> GetRoleDataAsync<T>(string roleId, string key)
Parameters
Type Name Description
System.String roleId
System.String key
Returns
Type Description
Task<T>
Type Parameters
Name Description
T
| Improve this Doc View Source

InitAsync()

Declaration
protected virtual Task InitAsync()
Returns
Type Description
Task
| Improve this Doc View Source

ReloadAsync()

Declaration
public virtual Task ReloadAsync()
Returns
Type Description
Task
| Improve this Doc View Source

SaveChangesAsync()

Declaration
public virtual Task SaveChangesAsync()
Returns
Type Description
Task

Implements

IPermissionRolesDataStore
IDisposable

Extension Methods

DisposeHelper.DisposeSyncOrAsync(Object)