Click or drag to resize
IActivityLogService Interface
Provides possibility to log activities.

Namespace: CMS.Activities
Assembly: CMS.Activities (in CMS.Activities.dll) Version: 10.0.0
Syntax
C#
public interface IActivityLogService

The IActivityLogService type exposes the following members.

Methods
  NameDescription
Public methodLog
Logs given activity. Registered IActivityLogFilter are checked, activity is further processed only if all filters allow it. Then IActivityInfo is created and activityInitializer is called. Afterwards all registered modifiers are applied to the IActivityInfo. Finally the IActivityInfo is validated by registered IActivityLogValidator. Activity is stored only if it is valid. After the activity is stored, two events are fired. ActivityProcessedInLogService which should be used to hook on and also ActivityLogged which is there due to compatibility reasons (should not be used).
Public methodLogWithoutModifiersAndFilters
Logs activity initialized by activityInitializer directly to the database. Implementation does not check IActivityLogFilter and does not use IActivityModifier. Final validation by IActivityLogValidator is performed. If you have HttpRequestBase available please use Log(IActivityInitializer, HttpRequestBase, Boolean) instead. Method is designed to be used in environment without request e.g. scheduled tasks. After the activity is stored, two events are fired. ActivityProcessedInLogService which should be used to hook on and also ActivityLogged which is there due to compatibility reasons (should not be used).
Public methodRegisterFilter
Registers global filter which decide if activity should not be logged or otherwise. Filters are called before IActivityInfo is created. Activity is not logged if at least one filter denies activity. Filters are global, thus they are shared across all instances of the service.
Public methodRegisterModifier
Registers global activity modifier. Modifier is used to update every newly created IActivityInfo. Modifier is called after activity is created and successfully initialized. Modifiers are global, thus they are shared across all instances of the service.
Public methodRegisterValidator
Registers global activity validator. Validators are used to check whether the processed IActivityInfo is valid and can be logged. Validators are global, therefore they are shared across all instances of the service.
Top
See Also