aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Model/Activity
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Model/Activity')
-rw-r--r--MediaBrowser.Model/Activity/ActivityLogEntry.cs68
-rw-r--r--MediaBrowser.Model/Activity/IActivityManager.cs17
-rw-r--r--MediaBrowser.Model/Activity/IActivityRepository.cs12
3 files changed, 97 insertions, 0 deletions
diff --git a/MediaBrowser.Model/Activity/ActivityLogEntry.cs b/MediaBrowser.Model/Activity/ActivityLogEntry.cs
new file mode 100644
index 000000000..1f4bff10d
--- /dev/null
+++ b/MediaBrowser.Model/Activity/ActivityLogEntry.cs
@@ -0,0 +1,68 @@
+using MediaBrowser.Model.Logging;
+using System;
+
+namespace MediaBrowser.Model.Activity
+{
+ public class ActivityLogEntry
+ {
+ /// <summary>
+ /// Gets or sets the identifier.
+ /// </summary>
+ /// <value>The identifier.</value>
+ public long Id { get; set; }
+
+ /// <summary>
+ /// Gets or sets the name.
+ /// </summary>
+ /// <value>The name.</value>
+ public string Name { get; set; }
+
+ /// <summary>
+ /// Gets or sets the overview.
+ /// </summary>
+ /// <value>The overview.</value>
+ public string Overview { get; set; }
+
+ /// <summary>
+ /// Gets or sets the short overview.
+ /// </summary>
+ /// <value>The short overview.</value>
+ public string ShortOverview { get; set; }
+
+ /// <summary>
+ /// Gets or sets the type.
+ /// </summary>
+ /// <value>The type.</value>
+ public string Type { get; set; }
+
+ /// <summary>
+ /// Gets or sets the item identifier.
+ /// </summary>
+ /// <value>The item identifier.</value>
+ public string ItemId { get; set; }
+
+ /// <summary>
+ /// Gets or sets the date.
+ /// </summary>
+ /// <value>The date.</value>
+ public DateTime Date { get; set; }
+
+ /// <summary>
+ /// Gets or sets the user identifier.
+ /// </summary>
+ /// <value>The user identifier.</value>
+ public Guid UserId { get; set; }
+
+ /// <summary>
+ /// Gets or sets the user primary image tag.
+ /// </summary>
+ /// <value>The user primary image tag.</value>
+ public string UserPrimaryImageTag { get; set; }
+
+ /// <summary>
+ /// Gets or sets the log severity.
+ /// </summary>
+ /// <value>The log severity.</value>
+ public LogSeverity Severity { get; set; }
+ }
+}
diff --git a/MediaBrowser.Model/Activity/IActivityManager.cs b/MediaBrowser.Model/Activity/IActivityManager.cs
new file mode 100644
index 000000000..7fff26987
--- /dev/null
+++ b/MediaBrowser.Model/Activity/IActivityManager.cs
@@ -0,0 +1,17 @@
+using System;
+using MediaBrowser.Model.Events;
+using MediaBrowser.Model.Querying;
+
+namespace MediaBrowser.Model.Activity
+{
+ public interface IActivityManager
+ {
+ event EventHandler<GenericEventArgs<ActivityLogEntry>> EntryCreated;
+
+ void Create(ActivityLogEntry entry);
+
+ QueryResult<ActivityLogEntry> GetActivityLogEntries(DateTime? minDate, int? startIndex, int? limit);
+
+ QueryResult<ActivityLogEntry> GetActivityLogEntries(DateTime? minDate, bool? hasUserId, int? x, int? y);
+ }
+}
diff --git a/MediaBrowser.Model/Activity/IActivityRepository.cs b/MediaBrowser.Model/Activity/IActivityRepository.cs
new file mode 100644
index 000000000..5a2c52400
--- /dev/null
+++ b/MediaBrowser.Model/Activity/IActivityRepository.cs
@@ -0,0 +1,12 @@
+using System;
+using MediaBrowser.Model.Querying;
+
+namespace MediaBrowser.Model.Activity
+{
+ public interface IActivityRepository
+ {
+ void Create(ActivityLogEntry entry);
+
+ QueryResult<ActivityLogEntry> GetActivityLogEntries(DateTime? minDate, bool? z, int? startIndex, int? limit);
+ }
+}