/[xmltv_parser]/trunk/libxmltv/Core/XMLTVChannelCollection.cs
ViewVC logotype

Diff of /trunk/libxmltv/Core/XMLTVChannelCollection.cs

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 44 by william, Fri Mar 8 03:36:44 2013 UTC revision 46 by william, Fri Mar 8 04:01:25 2013 UTC
# Line 19  namespace libxmltv.Core Line 19  namespace libxmltv.Core
19          private XMLTVRuntimeInstance instance;          private XMLTVRuntimeInstance instance;
20          public XMLTVChannelCollection(XMLTVRuntimeInstance xmltv)          public XMLTVChannelCollection(XMLTVRuntimeInstance xmltv)
21          {          {
22              XMLTV_LOGGER.Log.Verbose.Debug.WriteLine("Creating Instance of XMLTVChannelCollection");              xmltv_logger.Log.Verbose.Debug.WriteLine("Creating Instance of XMLTVChannelCollection");
23              //IXMLTV_PARSER _xmltv;              //IXMLTV_PARSER _xmltv;
24              //if (!Internals.VerifyInstance<IXMLTV_PARSER>(xmltv, out _xmltv)) { return; }              //if (!Internals.VerifyInstance<IXMLTV_PARSER>(xmltv, out _xmltv)) { return; }
25              //XMLTV_PARSER = _xmltv;              //XMLTV_PARSER = _xmltv;
# Line 41  namespace libxmltv.Core Line 41  namespace libxmltv.Core
41    
42              foreach (var c in doc.Descendants(XMLTVConstants.CHANNEL_ELEMENT))              foreach (var c in doc.Descendants(XMLTVConstants.CHANNEL_ELEMENT))
43              {              {
44                    if (instance.IsAborting)
45                    {
46                        break;
47                    }
48                  Channel channel = new Channel(c);                  Channel channel = new Channel(c);
49                  entries.Add(channel.Id, channel);                  entries.Add(channel.Id, channel);
50                  Application.DoEvents();                  Application.DoEvents();
# Line 72  namespace libxmltv.Core Line 76  namespace libxmltv.Core
76          {          {
77              // get the channel id              // get the channel id
78              Id = e.Attribute(XMLTVConstants.Channels.ChannelId).Value;              Id = e.Attribute(XMLTVConstants.Channels.ChannelId).Value;
79              XMLTV_LOGGER.Log.Verbose.Debug.WriteLine("\tchannel_id: {0}", Id);              xmltv_logger.Log.Verbose.Debug.WriteLine("\tchannel_id: {0}", Id);
80              var names = e.Descendants(XMLTVConstants.Channels.ChannelDisplayName).ToList();              var names = e.Descendants(XMLTVConstants.Channels.ChannelDisplayName).ToList();
81              Number = Convert.ToInt32(names[1].Value);              Number = Convert.ToInt32(names[1].Value);
82              XMLTV_LOGGER.Log.Verbose.Debug.WriteLine("\tchannel_number: {0}", Number);              xmltv_logger.Log.Verbose.Debug.WriteLine("\tchannel_number: {0}", Number);
83              CallSign = names[2].Value;              CallSign = names[2].Value;
84              XMLTV_LOGGER.Log.Verbose.Debug.WriteLine("\tchannel_callsign: {0}", CallSign);              xmltv_logger.Log.Verbose.Debug.WriteLine("\tchannel_callsign: {0}", CallSign);
85              Name = names[3].Value;              Name = names[3].Value;
86              XMLTV_LOGGER.Log.Verbose.Debug.WriteLine("\tchannel_name: {0}", Name);              xmltv_logger.Log.Verbose.Debug.WriteLine("\tchannel_name: {0}", Name);
87          }          }
88          #region IXMLTVChannel members          #region IXMLTVChannel members
89          public string Id { get; private set; }          public string Id { get; private set; }

Legend:
Removed from v.44  
changed lines
  Added in v.46

  ViewVC Help
Powered by ViewVC 1.1.22