< Summary - Jellyfin

Information
Class: MediaBrowser.Model.System.WakeOnLanInfo
Assembly: MediaBrowser.Model
File(s): /srv/git/jellyfin/MediaBrowser.Model/System/WakeOnLanInfo.cs
Line coverage
0%
Covered lines: 0
Uncovered lines: 6
Coverable lines: 6
Total lines: 47
Line coverage: 0%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Coverage history

Coverage history 0 25 50 75 100

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
.ctor(...)100%210%
.ctor(...)100%210%
.ctor()100%210%

File(s)

/srv/git/jellyfin/MediaBrowser.Model/System/WakeOnLanInfo.cs

#LineLine coverage
 1using System.Net.NetworkInformation;
 2
 3namespace MediaBrowser.Model.System
 4{
 5    /// <summary>
 6    /// Provides the MAC address and port for wake-on-LAN functionality.
 7    /// </summary>
 8    public class WakeOnLanInfo
 9    {
 10        /// <summary>
 11        /// Initializes a new instance of the <see cref="WakeOnLanInfo" /> class.
 12        /// </summary>
 13        /// <param name="macAddress">The MAC address.</param>
 014        public WakeOnLanInfo(PhysicalAddress macAddress) : this(macAddress.ToString())
 15        {
 016        }
 17
 18        /// <summary>
 19        /// Initializes a new instance of the <see cref="WakeOnLanInfo" /> class.
 20        /// </summary>
 21        /// <param name="macAddress">The MAC address.</param>
 022        public WakeOnLanInfo(string macAddress) : this()
 23        {
 24            MacAddress = macAddress;
 025        }
 26
 27        /// <summary>
 28        /// Initializes a new instance of the <see cref="WakeOnLanInfo" /> class.
 29        /// </summary>
 30        public WakeOnLanInfo()
 31        {
 032            Port = 9;
 033        }
 34
 35        /// <summary>
 36        /// Gets the MAC address of the device.
 37        /// </summary>
 38        /// <value>The MAC address.</value>
 39        public string? MacAddress { get; }
 40
 41        /// <summary>
 42        /// Gets or sets the wake-on-LAN port.
 43        /// </summary>
 44        /// <value>The wake-on-LAN port.</value>
 45        public int Port { get; set; }
 46    }
 47}