AuthenticationResultEventArgs.cs 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. using System;
  2. using MediaBrowser.Controller.Authentication;
  3. using MediaBrowser.Controller.Session;
  4. using MediaBrowser.Model.Dto;
  5. namespace MediaBrowser.Controller.Events.Authentication;
  6. /// <summary>
  7. /// A class representing an authentication result event.
  8. /// </summary>
  9. public class AuthenticationResultEventArgs : EventArgs
  10. {
  11. /// <summary>
  12. /// Initializes a new instance of the <see cref="AuthenticationResultEventArgs"/> class.
  13. /// </summary>
  14. /// <param name="result">The <see cref="AuthenticationResult"/>.</param>
  15. public AuthenticationResultEventArgs(AuthenticationResult result)
  16. {
  17. User = result.User;
  18. SessionInfo = result.SessionInfo;
  19. ServerId = result.ServerId;
  20. }
  21. /// <summary>
  22. /// Gets or sets the user.
  23. /// </summary>
  24. public UserDto User { get; set; }
  25. /// <summary>
  26. /// Gets or sets the session information.
  27. /// </summary>
  28. public SessionInfo? SessionInfo { get; set; }
  29. /// <summary>
  30. /// Gets or sets the server id.
  31. /// </summary>
  32. public string? ServerId { get; set; }
  33. }