Class DashboardPanelStore
Implements
Inherited Members
Namespace: DataWeb.Dashboard.SqlServer
Assembly: DataWeb.Data.SqlServer.dll
Syntax
public class DashboardPanelStore : IDashboardPanelStore
Constructors
DashboardPanelStore(ISqlHelper)
Declaration
public DashboardPanelStore(ISqlHelper sqlHelper)
Parameters
| Type | Name | Description |
|---|---|---|
| ISqlHelper | sqlHelper |
Properties
Name
Gets the name of the store implementation.
Declaration
public string Name { get; }
Property Value
| Type | Description |
|---|---|
| string |
Methods
GetPanelAsync(PanelFilter, CancellationToken)
Retrieves the first dashboard panel matching the specified filter, or null if none is found.
Declaration
public Task<DashboardPanelData> GetPanelAsync(PanelFilter filter, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| PanelFilter | filter | The filter criteria used to query the dashboard panel. |
| CancellationToken | cancellationToken | A token to cancel the asynchronous operation. |
Returns
| Type | Description |
|---|---|
| Task<DashboardPanelData> | The first matching DashboardPanelData, or null. |
GetPanelsAsync(PanelFilter, CancellationToken)
Retrieves a collection of dashboard panels matching the specified filter.
Declaration
public Task<IEnumerable<DashboardPanelData>> GetPanelsAsync(PanelFilter filter, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| PanelFilter | filter | The filter criteria used to query dashboard panels. |
| CancellationToken | cancellationToken | A token to cancel the asynchronous operation. |
Returns
| Type | Description |
|---|---|
| Task<IEnumerable<DashboardPanelData>> | A collection of DashboardPanelData matching the filter. |
RemoveAsync(string, CancellationToken)
Deletes the dashboard panel with the specified identifier.
Declaration
public Task RemoveAsync(string panelId, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| string | panelId | The identifier of the panel to delete. |
| CancellationToken | cancellationToken | A token to cancel the asynchronous operation. |
Returns
| Type | Description |
|---|---|
| Task |
SetAsync(DashboardPanelData, CancellationToken)
Inserts or updates the specified dashboard panel.
Declaration
public Task SetAsync(DashboardPanelData panel, CancellationToken cancellationToken = default)
Parameters
| Type | Name | Description |
|---|---|---|
| DashboardPanelData | panel | The panel data to persist. |
| CancellationToken | cancellationToken | A token to cancel the asynchronous operation. |
Returns
| Type | Description |
|---|---|
| Task |