-
Notifications
You must be signed in to change notification settings - Fork 44
API
Matteo Gregoricchio edited this page May 7, 2024
·
11 revisions
Reference namespace: Serilog.Ui.Core
// the Provider unique name
string Name { get; }
// Fetch the data and returns a Tuple, consisting of
// - an IEnumerable of LogModel
// - the total number of matches obtained with the non-paginated query.
Task<(IEnumerable<LogModel> results, int total)> FetchDataAsync(
FetchLogsQuery queryParams,
CancellationToken cancellationToken = default);
... to register implementation, check configuration:
// the unique provider name to run the query on
string DatabaseKey
// the 0-based page (used by the providers)
int Page
// the actual page (used by the client-app) [Linq.Skip]
int CurrentPage
// the amount of results to retrieve in a single request [Linq.Take]
int Count
// a log level filter
string Level
// a text search
string SearchCriteria
DateTime? StartDate
DateTime? EndDate
SearchOptions.SortProperty SortOn = SearchOptions.SortProperty.Timestamp;
SearchOptions.SortDirection SortBy = SearchOptions.SortDirection.Desc;
virtual int RowNo { private set; }
virtual string Level
virtual string Message
virtual DateTime Timestamp
virtual string Exception
virtual string Properties
virtual string PropertyType
// use to set the RowNo;
// rowNoStart should be {FetchLogsQuery}.Count * {FetchLogsQuery}.Page
LogModel SetRowNo(int rowNoStart, int index)