From 958f8f71e8174aa3884cbafa54d07bf247517014 Mon Sep 17 00:00:00 2001 From: Shadowghost Date: Thu, 8 Jun 2023 10:36:04 +0200 Subject: Add wrapper object for authentication event information --- .../AuthenticationRequestEventArgs.cs | 60 ++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 MediaBrowser.Controller/Events/Authentication/AuthenticationRequestEventArgs.cs (limited to 'MediaBrowser.Controller/Events/Authentication/AuthenticationRequestEventArgs.cs') diff --git a/MediaBrowser.Controller/Events/Authentication/AuthenticationRequestEventArgs.cs b/MediaBrowser.Controller/Events/Authentication/AuthenticationRequestEventArgs.cs new file mode 100644 index 000000000..c0d8a277b --- /dev/null +++ b/MediaBrowser.Controller/Events/Authentication/AuthenticationRequestEventArgs.cs @@ -0,0 +1,60 @@ +using System; +using MediaBrowser.Controller.Session; + +namespace MediaBrowser.Controller.Events.Authentication; + +/// +/// A class representing an authentication result event. +/// +public class AuthenticationRequestEventArgs +{ + /// + /// Initializes a new instance of the class. + /// + /// The . + public AuthenticationRequestEventArgs(AuthenticationRequest request) + { + Username = request.Username; + UserId = request.UserId; + App = request.App; + AppVersion = request.AppVersion; + DeviceId = request.DeviceId; + DeviceName = request.DeviceName; + RemoteEndPoint = request.RemoteEndPoint; + } + + /// + /// Gets or sets the user name. + /// + public string? Username { get; set; } + + /// + /// Gets or sets the user id. + /// + public Guid? UserId { get; set; } + + /// + /// Gets or sets the app. + /// + public string? App { get; set; } + + /// + /// Gets or sets the app version. + /// + public string? AppVersion { get; set; } + + /// + /// Gets or sets the device id. + /// + public string? DeviceId { get; set; } + + /// + /// Gets or sets the device name. + /// + public string? DeviceName { get; set; } + + /// + /// Gets or sets the remote endpoint. + /// + public string? RemoteEndPoint { get; set; } +} -- cgit v1.2.3