WebSocketMessage.cs 547 B

12345678910111213141516171819202122
  1. using System.Text.Json.Serialization;
  2. using MediaBrowser.Model.Session;
  3. namespace MediaBrowser.Controller.Net;
  4. /// <summary>
  5. /// Websocket message without data.
  6. /// </summary>
  7. public abstract class WebSocketMessage
  8. {
  9. /// <summary>
  10. /// Gets or sets the type of the message.
  11. /// TODO make this abstract and get only.
  12. /// </summary>
  13. public virtual SessionMessageType MessageType { get; set; }
  14. /// <summary>
  15. /// Gets or sets the server id.
  16. /// </summary>
  17. [JsonIgnore]
  18. public string? ServerId { get; set; }
  19. }