forked from robnewton/HDHomeRun_Stream_Builder
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathChannel.cs
56 lines (54 loc) · 1.56 KB
/
Channel.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace HDHomerun_Stream_Builder
{
public class Channel
{
public string Device { get; set; }
public string Tuner { get; set; }
public string Id { get; set; }
public string Number { get; set; }
public bool Encrypted { get; set; }
public bool IsBroadcasting { get; set; }
public bool BroadcastingChecked { get; set; }
public string Callsign { get; set; }
public int VirtualNumberAsInt
{
get
{
int temp = 0;
int.TryParse(this.VirtualNumber, out temp);
return temp;
}
private set { }
}
public string ProxyProgram { get; set; }
public string VirtualNumber { get; set; }
public string Name { get; set; }
public string StreamUrl
{
get
{
return "hdhomerun://" + Device + "-" + Tuner + "/tuner" + Tuner + "?channel=auto:" + Number + "&program=" + ProxyProgram;
}
private set { }
}
public bool Checked { get; set; }
public string Filename
{
get
{
return VirtualNumber + " - " + Utils.MakeSafeFilename(Name, '_') + ".strm";
}
private set { }
}
public Channel(string num, string device, string tuner)
{
Number = num;
Device = device;
Tuner = tuner;
}
}
}