Table of Contents

Class WidgetsHelper

Namespace
Dynamicweb.Dashboard.Widgets
Assembly
Dynamicweb.Core.dll

Contains some helpers methods for easy work with log event widgets

public static class WidgetsHelper
Inheritance
WidgetsHelper
Inherited Members

Fields

DurationFilterOptionIds

public static readonly Dictionary<TimePeriodUnit, string> DurationFilterOptionIds

Field Value

Dictionary<TimePeriodUnit, string>

LogLevelFilterOptionIds

public static readonly Dictionary<LogLevel, string> LogLevelFilterOptionIds

Field Value

Dictionary<LogLevel, string>

Methods

GetLogCategories(List<ParameterOption>)

Get log event categories

public static void GetLogCategories(List<ParameterOption> options)

Parameters

options List<ParameterOption>

GetLogEventTimePeriod(List<ParameterOption>)

Gets time periods.

public static void GetLogEventTimePeriod(List<ParameterOption> options)

Parameters

options List<ParameterOption>

GetLogEvents(string, string, TimePeriodUnit)

Get log events

public static IEnumerable<LogEvent> GetLogEvents(string eventLevel, string category, TimePeriodUnit timePeriod)

Parameters

eventLevel string
category string
timePeriod TimePeriodUnit

Returns

IEnumerable<LogEvent>

GetLogEvents(string, string, TimePeriodUnit, string, int)

Get log events

public static IEnumerable<LogEvent> GetLogEvents(string eventLevel, string category, TimePeriodUnit timePeriod, string orderBy, int top)

Parameters

eventLevel string
category string
timePeriod TimePeriodUnit
orderBy string
top int

Returns

IEnumerable<LogEvent>

GetLogEvents(string, string, DateTime)

Get log events

public static IEnumerable<LogEvent> GetLogEvents(string eventLevel, string category, DateTime startTime)

Parameters

eventLevel string
category string
startTime DateTime

Returns

IEnumerable<LogEvent>

GetLogEvents(string, string, DateTime, string, int)

Get log events

public static IEnumerable<LogEvent> GetLogEvents(string eventLevel, string category, DateTime startTime, string orderBy, int top)

Parameters

eventLevel string
category string
startTime DateTime
orderBy string
top int

Returns

IEnumerable<LogEvent>

GetLogLevelOptions(List<ParameterOption>)

Get log level options

public static void GetLogLevelOptions(List<ParameterOption> options)

Parameters

options List<ParameterOption>

GetScheduledTasks(string, TimePeriodUnit, bool)

public static IList<Task> GetScheduledTasks(string taskId, TimePeriodUnit timePeriod, bool includeOverdueTasks = false)

Parameters

taskId string
timePeriod TimePeriodUnit
includeOverdueTasks bool

Returns

IList<Task>

GetStartTimeFromPeriod(TimePeriodUnit)

Get start time by period

public static DateTime GetStartTimeFromPeriod(TimePeriodUnit timePeriod)

Parameters

timePeriod TimePeriodUnit

Returns

DateTime

GetTasks(List<ParameterOption>)

public static void GetTasks(List<ParameterOption> options)

Parameters

options List<ParameterOption>

ParseCategoryAndAction(string)

public static Tuple<string, string> ParseCategoryAndAction(string categoryParameter)

Parameters

categoryParameter string

Returns

Tuple<string, string>

TaskIsActive(Task)

public static bool TaskIsActive(Task task)

Parameters

task Task

Returns

bool
To top