diff options
Diffstat (limited to 'MediaBrowser.Dlna/Server/UpnpDevice.cs')
| -rw-r--r-- | MediaBrowser.Dlna/Server/UpnpDevice.cs | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/MediaBrowser.Dlna/Server/UpnpDevice.cs b/MediaBrowser.Dlna/Server/UpnpDevice.cs new file mode 100644 index 0000000000..96e37eb07c --- /dev/null +++ b/MediaBrowser.Dlna/Server/UpnpDevice.cs @@ -0,0 +1,28 @@ +using System; + +namespace MediaBrowser.Dlna.Server +{ + public sealed class UpnpDevice + { + public readonly Uri Descriptor; + public readonly string Type; + public readonly string USN; + public readonly Guid Uuid; + + public UpnpDevice(Guid aUuid, string aType, Uri aDescriptor) + { + Uuid = aUuid; + Type = aType; + Descriptor = aDescriptor; + + if (Type.StartsWith("uuid:")) + { + USN = Type; + } + else + { + USN = String.Format("uuid:{0}::{1}", Uuid.ToString(), Type); + } + } + } +} |
