MythTV  master
v2channel.cpp
Go to the documentation of this file.
1 // Program Name: channel.cpp
3 // Created : Apr. 8, 2011
4 //
5 // Copyright (c) 2011 Robert McNamara <rmcnamara@mythtv.org>
6 // Copyright (c) 2013 MythTV Developers
7 //
8 // This program is free software; you can redistribute it and/or modify
9 // it under the terms of the GNU General Public License as published by
10 // the Free Software Foundation; either version 2 of the License, or
11 // (at your option) any later version.
12 //
13 // This program is distributed in the hope that it will be useful,
14 // but WITHOUT ANY WARRANTY; without even the implied warranty of
15 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 // GNU General Public License for more details.
17 //
18 // You should have received a copy of the GNU General Public License
19 // along with this program; if not, write to the Free Software
20 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21 //
22 // You should have received a copy of the GNU General Public License
23 // along with this program. If not, see <http://www.gnu.org/licenses/>.
24 //
26 
27 // C++
28 #include <cmath>
29 
30 // Qt
31 #include <QList>
32 
33 // MythTV
35 #include "libmythbase/compat.h"
36 #include "libmythbase/mythdbcon.h"
37 #include "libmythbase/mythdirs.h"
40 #include "libmythtv/channelutil.h"
41 #include "libmythtv/sourceutil.h"
42 #include "libmythtv/cardutil.h"
43 #include "libmythbase/mythdate.h"
44 #include "libmythtv/frequencies.h"
46 
47 // MythBackend
48 #include "v2artworkInfoList.h"
49 #include "v2castMemberList.h"
50 #include "v2channel.h"
51 #include "v2programAndChannel.h"
52 #include "v2recording.h"
53 #include "v2serviceUtil.h"
54 #include "v2grabber.h"
55 #include "v2freqtable.h"
56 
58 //
60 
62 (CHANNEL_HANDLE, V2Channel::staticMetaObject, &V2Channel::RegisterCustomTypes))
63 
65 {
66  qRegisterMetaType<V2ChannelInfoList*>("V2ChannelInfoList");
67  qRegisterMetaType<V2ChannelInfo*>("V2ChannelInfo");
68  qRegisterMetaType<V2VideoSourceList*>("V2VideoSourceList");
69  qRegisterMetaType<V2VideoSource*>("V2VideoSource");
70  qRegisterMetaType<V2LineupList*>("V2LineupList");
71  qRegisterMetaType<V2Lineup*>("V2Lineup");
72  qRegisterMetaType<V2VideoMultiplexList*>("V2VideoMultiplexList");
73  qRegisterMetaType<V2VideoMultiplex*>("V2VideoMultiplex");
74  qRegisterMetaType<V2Program*>("V2Program");
75  qRegisterMetaType<V2RecordingInfo*>("V2RecordingInfo");
76  qRegisterMetaType<V2ArtworkInfoList*>("V2ArtworkInfoList");
77  qRegisterMetaType<V2ArtworkInfo*>("V2ArtworkInfo");
78  qRegisterMetaType<V2CastMemberList*>("V2CastMemberList");
79  qRegisterMetaType<V2CastMember*>("V2CastMember");
80  qRegisterMetaType<V2Grabber*>("V2Grabber");
81  qRegisterMetaType<V2GrabberList*>("V2GrabberList");
82  qRegisterMetaType<V2FreqTableList*>("V2FreqTableList");
83 }
84 
86 {
87 }
88 
89 
90 
92  uint nChannelGroupID,
93  uint nStartIndex,
94  uint nCount,
95  bool bOnlyVisible,
96  bool bDetails,
97  bool bOrderByName,
98  bool bGroupByCallsign,
99  bool bOnlyTunable )
100 {
101  ChannelInfoList chanList;
102 
103  uint nTotalAvailable = 0;
104 
105  chanList = ChannelUtil::LoadChannels( 0, 0, nTotalAvailable, bOnlyVisible,
108  nSourceID, nChannelGroupID, false, "",
109  "", bOnlyTunable);
110 
111  // ----------------------------------------------------------------------
112  // Build Response
113  // ----------------------------------------------------------------------
114 
115  auto *pChannelInfos = new V2ChannelInfoList();
116 
117  nStartIndex = (nStartIndex > 0) ? std::min( nStartIndex, nTotalAvailable ) : 0;
118  nCount = (nCount > 0) ? std::min(nCount, (nTotalAvailable - nStartIndex)) :
119  (nTotalAvailable - nStartIndex);
120 
121  ChannelInfoList::iterator chanIt;
122  auto chanItBegin = chanList.begin() + nStartIndex;
123  auto chanItEnd = chanItBegin + nCount;
124 
125  for( chanIt = chanItBegin; chanIt < chanItEnd; ++chanIt )
126  {
127  V2ChannelInfo *pChannelInfo = pChannelInfos->AddNewChannelInfo();
128 
129  ChannelInfo channelInfo = (*chanIt);
130 
131  if (!V2FillChannelInfo(pChannelInfo, channelInfo, bDetails))
132  {
133  delete pChannelInfo;
134  delete pChannelInfos;
135  throw( QString("V2Channel ID appears invalid."));
136  }
137  }
138 
139  int nCurPage = 0;
140  int nTotalPages = 0;
141  if (nCount == 0)
142  nTotalPages = 1;
143  else
144  nTotalPages = (int)std::ceil((float)nTotalAvailable / nCount);
145 
146  if (nTotalPages == 1)
147  nCurPage = 1;
148  else
149  {
150  nCurPage = (int)std::ceil((float)nStartIndex / nCount) + 1;
151  }
152 
153  pChannelInfos->setStartIndex ( nStartIndex );
154  pChannelInfos->setCount ( nCount );
155  pChannelInfos->setCurrentPage ( nCurPage );
156  pChannelInfos->setTotalPages ( nTotalPages );
157  pChannelInfos->setTotalAvailable( nTotalAvailable );
158  pChannelInfos->setAsOf ( MythDate::current() );
159  pChannelInfos->setVersion ( MYTH_BINARY_VERSION );
160  pChannelInfos->setProtoVer ( MYTH_PROTO_VERSION );
161 
162  return pChannelInfos;
163 }
164 
166 //
168 
170 {
171  if (nChanID == 0)
172  throw( QString("V2Channel ID appears invalid."));
173 
174  auto *pChannelInfo = new V2ChannelInfo();
175 
176  if (!V2FillChannelInfo(pChannelInfo, nChanID, true))
177  {
178  // throw causes a crash on linux and we can't know in advance
179  // that a channel id from an old recording rule is invalid
180  //throw( QString("V2Channel ID appears invalid."));
181  }
182 
183  return pChannelInfo;
184 }
185 
187  uint SourceID,
188  uint ChannelID,
189  const QString &CallSign,
190  const QString &ChannelName,
191  const QString &ChannelNumber,
192  uint ServiceID,
193  uint ATSCMajorChannel,
194  uint ATSCMinorChannel,
195  bool UseEIT,
196  bool Visible,
197  const QString &ExtendedVisible,
198  const QString &FrequencyID,
199  const QString &Icon,
200  const QString &Format,
201  const QString &XMLTVID,
202  const QString &DefaultAuthority,
203  uint ServiceType )
204 {
205  if (!HAS_PARAMv2("ChannelID"))
206  throw QString("ChannelId is required");
207 
208  if (m_request->m_queries.size() < 2 )
209  throw QString("Nothing to update");
210 
211  ChannelInfo channel;
212  if (!channel.Load(ChannelID))
213  throw QString("ChannelId %1 doesn't exist");
214 
215  if (HAS_PARAMv2("MplexID"))
216  channel.m_mplexId = MplexID;
217  if (HAS_PARAMv2("SourceID"))
218  channel.m_sourceId = SourceID;
219  if (HAS_PARAMv2("CallSign"))
220  channel.m_callSign = CallSign;
221  if (HAS_PARAMv2("ChannelName"))
222  channel.m_name = ChannelName;
223  if (HAS_PARAMv2("ChannelNumber"))
224  channel.m_chanNum = ChannelNumber;
225  if (HAS_PARAMv2("ServiceID"))
226  channel.m_serviceId = ServiceID;
227  if (HAS_PARAMv2("ATSCMajorChannel"))
228  channel.m_atscMajorChan = ATSCMajorChannel;
229  if (HAS_PARAMv2("ATSCMinorChannel"))
230  channel.m_atscMinorChan = ATSCMinorChannel;
231  if (HAS_PARAMv2("UseEIT"))
232  channel.m_useOnAirGuide = UseEIT;
233  if (HAS_PARAMv2("ExtendedVisible"))
234  channel.m_visible = channelVisibleTypeFromString(ExtendedVisible);
235  else if (HAS_PARAMv2("Visible"))
236  {
237  if (channel.m_visible == kChannelVisible ||
238  channel.m_visible == kChannelNotVisible)
239  {
240  channel.m_visible =
242  }
243  else if ((channel.m_visible == kChannelAlwaysVisible && !Visible) ||
244  (channel.m_visible == kChannelNeverVisible && Visible))
245  {
246  throw QString("Can't override Always/NeverVisible");
247  }
248  }
249  if (HAS_PARAMv2("FrequencyID"))
250  channel.m_freqId = FrequencyID;
251  if (HAS_PARAMv2("Icon"))
252  channel.m_icon = Icon;
253  if (HAS_PARAMv2("Format"))
254  channel.m_tvFormat = Format;
255  if (HAS_PARAMv2("XMLTVID"))
256  channel.m_xmltvId = XMLTVID;
257  if (HAS_PARAMv2("DefaultAuthority"))
258  channel.m_defaultAuthority = DefaultAuthority;
259  if (HAS_PARAMv2("servicetype"))
260  channel.m_serviceType = ServiceType;
261 
262  bool bResult = ChannelUtil::UpdateChannel(
263  channel.m_mplexId, channel.m_sourceId, channel.m_chanId,
264  channel.m_callSign, channel.m_name, channel.m_chanNum,
265  channel.m_serviceId, channel.m_atscMajorChan,
266  channel.m_atscMinorChan, channel.m_useOnAirGuide,
267  channel.m_visible, channel.m_freqId,
268  channel.m_icon, channel.m_tvFormat, channel.m_xmltvId,
269  channel.m_defaultAuthority, channel.m_serviceType );
270 
271  return bResult;
272 }
273 
275  uint SourceID,
276  uint ChannelID,
277  const QString &CallSign,
278  const QString &ChannelName,
279  const QString &ChannelNumber,
280  uint ServiceID,
281  uint ATSCMajorChannel,
282  uint ATSCMinorChannel,
283  bool UseEIT,
284  bool Visible,
285  const QString &ExtendedVisible,
286  const QString &FrequencyID,
287  const QString &Icon,
288  const QString &Format,
289  const QString &XMLTVID,
290  const QString &DefaultAuthority,
291  uint ServiceType )
292 {
293  ChannelVisibleType chan_visible = kChannelVisible;
294  if (HAS_PARAMv2("ExtendedVisible"))
295  chan_visible = channelVisibleTypeFromString(ExtendedVisible);
296  else if (HAS_PARAMv2("Visible"))
297  chan_visible = (Visible ? kChannelVisible : kChannelNotVisible);
298 
299  bool bResult = ChannelUtil::CreateChannel( MplexID, SourceID, ChannelID,
300  CallSign, ChannelName, ChannelNumber,
301  ServiceID, ATSCMajorChannel, ATSCMinorChannel,
302  UseEIT, chan_visible, FrequencyID,
303  Icon, Format, XMLTVID, DefaultAuthority,
304  ServiceType );
305 
306  return bResult;
307 }
308 
310 {
311  bool bResult = ChannelUtil::DeleteChannel( nChannelID );
312 
313  return bResult;
314 }
315 
317 //
319 
321 {
322  MSqlQuery query(MSqlQuery::InitCon());
323 
324  if (!query.isConnected())
325  throw( QString("Database not open while trying to list "
326  "Video Sources."));
327 
328  query.prepare("SELECT sourceid, name, xmltvgrabber, userid, "
329  "freqtable, lineupid, password, useeit, configpath, "
330  "dvb_nit_id, bouquet_id, region_id, scanfrequency, "
331  "lcnoffset FROM videosource "
332  "ORDER BY sourceid" );
333 
334  if (!query.exec())
335  {
336  MythDB::DBError("MythAPI::GetVideoSourceList()", query);
337 
338  throw( QString( "Database Error executing query." ));
339  }
340 
341  // ----------------------------------------------------------------------
342  // return the results of the query
343  // ----------------------------------------------------------------------
344 
345  auto* pList = new V2VideoSourceList();
346 
347  while (query.next())
348  {
349 
350  V2VideoSource *pVideoSource = pList->AddNewVideoSource();
351 
352  pVideoSource->setId ( query.value(0).toInt() );
353  pVideoSource->setSourceName ( query.value(1).toString() );
354  pVideoSource->setGrabber ( query.value(2).toString() );
355  pVideoSource->setUserId ( query.value(3).toString() );
356  pVideoSource->setFreqTable ( query.value(4).toString() );
357  pVideoSource->setLineupId ( query.value(5).toString() );
358  pVideoSource->setPassword ( query.value(6).toString() );
359  pVideoSource->setUseEIT ( query.value(7).toBool() );
360  pVideoSource->setConfigPath ( query.value(8).toString() );
361  pVideoSource->setNITId ( query.value(9).toInt() );
362  pVideoSource->setBouquetId ( query.value(10).toUInt() );
363  pVideoSource->setRegionId ( query.value(11).toUInt() );
364  pVideoSource->setScanFrequency ( query.value(12).toUInt() );
365  pVideoSource->setLCNOffset ( query.value(13).toUInt() );
366  }
367 
368  pList->setAsOf ( MythDate::current() );
369  pList->setVersion ( MYTH_BINARY_VERSION );
370  pList->setProtoVer ( MYTH_PROTO_VERSION );
371 
372  return pList;
373 }
374 
376 //
378 
380 {
381  MSqlQuery query(MSqlQuery::InitCon());
382 
383  if (!query.isConnected())
384  throw( QString("Database not open while trying to list "
385  "Video Sources."));
386 
387  query.prepare("SELECT name, xmltvgrabber, userid, "
388  "freqtable, lineupid, password, useeit, configpath, "
389  "dvb_nit_id, bouquet_id, region_id, scanfrequency, "
390  "lcnoffset "
391  "FROM videosource WHERE sourceid = :SOURCEID "
392  "ORDER BY sourceid" );
393  query.bindValue(":SOURCEID", nSourceID);
394 
395  if (!query.exec())
396  {
397  MythDB::DBError("MythAPI::GetVideoSource()", query);
398 
399  throw( QString( "Database Error executing query." ));
400  }
401 
402  // ----------------------------------------------------------------------
403  // return the results of the query
404  // ----------------------------------------------------------------------
405 
406  auto *pVideoSource = new V2VideoSource();
407 
408  if (query.next())
409  {
410  pVideoSource->setId ( nSourceID );
411  pVideoSource->setSourceName ( query.value(0).toString() );
412  pVideoSource->setGrabber ( query.value(1).toString() );
413  pVideoSource->setUserId ( query.value(2).toString() );
414  pVideoSource->setFreqTable ( query.value(3).toString() );
415  pVideoSource->setLineupId ( query.value(4).toString() );
416  pVideoSource->setPassword ( query.value(5).toString() );
417  pVideoSource->setUseEIT ( query.value(6).toBool() );
418  pVideoSource->setConfigPath ( query.value(7).toString() );
419  pVideoSource->setNITId ( query.value(8).toInt() );
420  pVideoSource->setBouquetId ( query.value(9).toUInt() );
421  pVideoSource->setRegionId ( query.value(10).toUInt() );
422  pVideoSource->setScanFrequency ( query.value(11).toUInt() );
423  pVideoSource->setLCNOffset ( query.value(12).toUInt() );
424  }
425 
426  return pVideoSource;
427 }
428 
430 //
432 
434  const QString &sSourceName,
435  const QString &sGrabber,
436  const QString &sUserId,
437  const QString &sFreqTable,
438  const QString &sLineupId,
439  const QString &sPassword,
440  bool bUseEIT,
441  const QString &sConfigPath,
442  int nNITId,
443  uint nBouquetId,
444  uint nRegionId,
445  uint nScanFrequency,
446  uint nLCNOffset )
447 {
448 
449  if (!HAS_PARAMv2("SourceID"))
450  {
451  LOG(VB_GENERAL, LOG_ERR, "SourceId is required");
452  return false;
453  }
454 
455  if (!SourceUtil::IsSourceIDValid(nSourceId))
456  {
457  LOG(VB_GENERAL, LOG_ERR, QString("SourceId %1 doesn't exist")
458  .arg(nSourceId));
459  return false;
460  }
461 
462  if (m_request->m_queries.size() < 2 )
463  {
464  LOG(VB_GENERAL, LOG_ERR, QString("SourceId=%1 was the only parameter")
465  .arg(nSourceId));
466  return false;
467  }
468 
469  MSqlBindings bindings;
470  MSqlBindings::const_iterator it;
471  QString settings;
472 
473  if ( HAS_PARAMv2("SourceName") )
474  ADD_SQLv2(settings, bindings, "name", "SourceName", sSourceName);
475 
476  if ( HAS_PARAMv2("Grabber") )
477  ADD_SQLv2(settings, bindings, "xmltvgrabber", "Grabber", sGrabber);
478 
479  if ( HAS_PARAMv2("UserId") )
480  ADD_SQLv2(settings, bindings, "userid", "UserId", sUserId);
481 
482  if ( HAS_PARAMv2("FreqTable") )
483  ADD_SQLv2(settings, bindings, "freqtable", "FreqTable", sFreqTable);
484 
485  if ( HAS_PARAMv2("LineupId") )
486  ADD_SQLv2(settings, bindings, "lineupid", "LineupId", sLineupId);
487 
488  if ( HAS_PARAMv2("Password") )
489  ADD_SQLv2(settings, bindings, "password", "Password", sPassword);
490 
491  if ( HAS_PARAMv2("UseEIT") )
492  ADD_SQLv2(settings, bindings, "useeit", "UseEIT", bUseEIT);
493 
494  if (HAS_PARAMv2("ConfigPath"))
495  {
496  if (sConfigPath.isEmpty())
497  settings += "configpath=NULL, "; // mythfilldatabase grabber requirement
498  else
499  ADD_SQLv2(settings, bindings, "configpath", "ConfigPath", sConfigPath);
500  }
501 
502  if ( HAS_PARAMv2("NITId") )
503  ADD_SQLv2(settings, bindings, "dvb_nit_id", "NITId", nNITId);
504 
505  if ( HAS_PARAMv2("BouquetId") )
506  ADD_SQLv2(settings, bindings, "bouquet_id", "BouquetId", nBouquetId);
507 
508  if ( HAS_PARAMv2("RegionId") )
509  ADD_SQLv2(settings, bindings, "region_id", "RegionId", nRegionId);
510 
511  if ( HAS_PARAMv2("ScanFrequency") )
512  ADD_SQLv2(settings, bindings, "scanfrequency", "ScanFrequency", nScanFrequency);
513 
514  if ( HAS_PARAMv2("LCNOffset") )
515  ADD_SQLv2(settings, bindings, "lcnoffset", "LCNOffset", nLCNOffset);
516 
517  if ( settings.isEmpty() )
518  {
519  LOG(VB_GENERAL, LOG_ERR, "No valid parameters were passed");
520  return false;
521  }
522 
523  settings.chop(2);
524 
525  MSqlQuery query(MSqlQuery::InitCon());
526 
527  query.prepare(QString("UPDATE videosource SET %1 WHERE sourceid=:SOURCEID")
528  .arg(settings));
529  bindings[":SOURCEID"] = nSourceId;
530 
531  for (it = bindings.cbegin(); it != bindings.cend(); ++it)
532  query.bindValue(it.key(), it.value());
533 
534  if (!query.exec())
535  {
536  MythDB::DBError("MythAPI::UpdateVideoSource()", query);
537 
538  throw( QString( "Database Error executing query." ));
539  }
540 
541  return true;
542 }
543 
545 //
547 
548 int V2Channel::AddVideoSource( const QString &sSourceName,
549  const QString &sGrabber,
550  const QString &sUserId,
551  const QString &sFreqTable,
552  const QString &sLineupId,
553  const QString &sPassword,
554  bool bUseEIT,
555  const QString &sConfigPath,
556  int nNITId,
557  uint nBouquetId,
558  uint nRegionId,
559  uint nScanFrequency,
560  uint nLCNOffset )
561 {
562  int nResult = SourceUtil::CreateSource(sSourceName, sGrabber, sUserId, sFreqTable,
563  sLineupId, sPassword, bUseEIT, sConfigPath,
564  nNITId, nBouquetId, nRegionId, nScanFrequency,
565  nLCNOffset);
566 
567  return nResult;
568 }
569 
571 //
573 
575 {
576  bool bResult = SourceUtil::DeleteAllSources();
577 
578  return bResult;
579 }
580 
582 {
583  bool bResult = SourceUtil::DeleteSource( nSourceID );
584 
585  return bResult;
586 }
587 
589 //
591 
592 V2LineupList* V2Channel::GetDDLineupList( const QString &/*sSource*/,
593  const QString &/*sUserId*/,
594  const QString &/*sPassword*/ )
595 {
596  auto *pLineups = new V2LineupList();
597  return pLineups;
598 }
599 
601 //
603 
605  const uint nCardId,
606  bool bWaitForFinish )
607 {
608  if ( nSourceId < 1 || nCardId < 1)
609  throw( QString("A source ID and card ID are both required."));
610 
611  int nResult = 0;
612 
613  QString cardtype = CardUtil::GetRawInputType(nCardId);
614 
615  // These tests commented because they prevent fetching channels for CETON
616  // cable card device, which is compatible with fetching and requires fetching.
617  // if (!CardUtil::IsUnscanable(cardtype) &&
618  // !CardUtil::IsEncoder(cardtype))
619  // {
620  // throw( QString("This device is incompatible with channel fetching.") );
621  // }
622 
623  SourceUtil::UpdateChannelsFromListings(nSourceId, cardtype, bWaitForFinish);
624 
625  if (bWaitForFinish)
626  nResult = SourceUtil::GetChannelCount(nSourceId);
627 
628  return nResult;
629 }
630 
632 //
634 
636  uint nStartIndex,
637  uint nCount )
638 {
639  MSqlQuery query(MSqlQuery::InitCon());
640 
641  if (!query.isConnected())
642  throw( QString("Database not open while trying to list "
643  "Video Sources."));
644 
645  query.prepare("SELECT mplexid, sourceid, transportid, networkid, "
646  "frequency, inversion, symbolrate, fec, polarity, "
647  "modulation, bandwidth, lp_code_rate, transmission_mode, "
648  "guard_interval, visible, constellation, hierarchy, hp_code_rate, "
649  "mod_sys, rolloff, sistandard, serviceversion, updatetimestamp, "
650  "default_authority FROM dtv_multiplex WHERE sourceid = :SOURCEID "
651  "ORDER BY mplexid" );
652  query.bindValue(":SOURCEID", nSourceID);
653 
654  if (!query.exec())
655  {
656  MythDB::DBError("MythAPI::GetVideoMultiplexList()", query);
657 
658  throw( QString( "Database Error executing query." ));
659  }
660 
661  uint muxCount = (uint)query.size();
662 
663  // ----------------------------------------------------------------------
664  // Build Response
665  // ----------------------------------------------------------------------
666 
667  auto *pVideoMultiplexes = new V2VideoMultiplexList();
668 
669  nStartIndex = (nStartIndex > 0) ? std::min( nStartIndex, muxCount ) : 0;
670  nCount = (nCount > 0) ? std::min( nCount, muxCount ) : muxCount;
671  int nEndIndex = std::min((nStartIndex + nCount), muxCount );
672 
673  for( int n = nStartIndex; n < nEndIndex; n++)
674  {
675  if (query.seek(n))
676  {
677  V2VideoMultiplex *pVideoMultiplex = pVideoMultiplexes->AddNewVideoMultiplex();
678 
679  pVideoMultiplex->setMplexId( query.value(0).toInt() );
680  pVideoMultiplex->setSourceId( query.value(1).toInt() );
681  pVideoMultiplex->setTransportId( query.value(2).toInt() );
682  pVideoMultiplex->setNetworkId( query.value(3).toInt() );
683  pVideoMultiplex->setFrequency( query.value(4).toLongLong() );
684  pVideoMultiplex->setInversion( query.value(5).toString() );
685  pVideoMultiplex->setSymbolRate( query.value(6).toLongLong() );
686  pVideoMultiplex->setFEC( query.value(7).toString() );
687  pVideoMultiplex->setPolarity( query.value(8).toString() );
688  pVideoMultiplex->setModulation( query.value(9).toString() );
689  pVideoMultiplex->setBandwidth( query.value(10).toString() );
690  pVideoMultiplex->setLPCodeRate( query.value(11).toString() );
691  pVideoMultiplex->setTransmissionMode( query.value(12).toString() );
692  pVideoMultiplex->setGuardInterval( query.value(13).toString() );
693  pVideoMultiplex->setVisible( query.value(14).toBool() );
694  pVideoMultiplex->setConstellation( query.value(15).toString() );
695  pVideoMultiplex->setHierarchy( query.value(16).toString() );
696  pVideoMultiplex->setHPCodeRate( query.value(17).toString() );
697  pVideoMultiplex->setModulationSystem( query.value(18).toString() );
698  pVideoMultiplex->setRollOff( query.value(19).toString() );
699  pVideoMultiplex->setSIStandard( query.value(20).toString() );
700  pVideoMultiplex->setServiceVersion( query.value(21).toInt() );
701  pVideoMultiplex->setUpdateTimeStamp(
702  MythDate::as_utc(query.value(22).toDateTime()));
703  pVideoMultiplex->setDefaultAuthority( query.value(23).toString() );
704  }
705  }
706 
707  int curPage = 0;
708  int totalPages = 0;
709  if (nCount == 0)
710  totalPages = 1;
711  else
712  totalPages = (int)std::ceil((float)muxCount / nCount);
713 
714  if (totalPages == 1)
715  curPage = 1;
716  else
717  {
718  curPage = (int)std::ceil((float)nStartIndex / nCount) + 1;
719  }
720 
721  pVideoMultiplexes->setStartIndex ( nStartIndex );
722  pVideoMultiplexes->setCount ( nCount );
723  pVideoMultiplexes->setCurrentPage ( curPage );
724  pVideoMultiplexes->setTotalPages ( totalPages );
725  pVideoMultiplexes->setTotalAvailable( muxCount );
726  pVideoMultiplexes->setAsOf ( MythDate::current() );
727  pVideoMultiplexes->setVersion ( MYTH_BINARY_VERSION );
728  pVideoMultiplexes->setProtoVer ( MYTH_PROTO_VERSION );
729 
730  return pVideoMultiplexes;
731 }
732 
734 {
735  MSqlQuery query(MSqlQuery::InitCon());
736 
737  if (!query.isConnected())
738  throw( QString("Database not open while trying to list "
739  "Video Multiplex."));
740 
741  query.prepare("SELECT sourceid, transportid, networkid, "
742  "frequency, inversion, symbolrate, fec, polarity, "
743  "modulation, bandwidth, lp_code_rate, transmission_mode, "
744  "guard_interval, visible, constellation, hierarchy, hp_code_rate, "
745  "mod_sys, rolloff, sistandard, serviceversion, updatetimestamp, "
746  "default_authority FROM dtv_multiplex WHERE mplexid = :MPLEXID "
747  "ORDER BY mplexid" );
748  query.bindValue(":MPLEXID", nMplexID);
749 
750  if (!query.exec())
751  {
752  MythDB::DBError("MythAPI::GetVideoMultiplex()", query);
753 
754  throw( QString( "Database Error executing query." ));
755  }
756 
757  auto *pVideoMultiplex = new V2VideoMultiplex();
758 
759  if (query.next())
760  {
761  pVideoMultiplex->setMplexId( nMplexID );
762  pVideoMultiplex->setSourceId( query.value(0).toInt() );
763  pVideoMultiplex->setTransportId( query.value(1).toInt() );
764  pVideoMultiplex->setNetworkId( query.value(2).toInt() );
765  pVideoMultiplex->setFrequency( query.value(3).toLongLong() );
766  pVideoMultiplex->setInversion( query.value(4).toString() );
767  pVideoMultiplex->setSymbolRate( query.value(5).toLongLong() );
768  pVideoMultiplex->setFEC( query.value(6).toString() );
769  pVideoMultiplex->setPolarity( query.value(7).toString() );
770  pVideoMultiplex->setModulation( query.value(8).toString() );
771  pVideoMultiplex->setBandwidth( query.value(9).toString() );
772  pVideoMultiplex->setLPCodeRate( query.value(10).toString() );
773  pVideoMultiplex->setTransmissionMode( query.value(11).toString() );
774  pVideoMultiplex->setGuardInterval( query.value(12).toString() );
775  pVideoMultiplex->setVisible( query.value(13).toBool() );
776  pVideoMultiplex->setConstellation( query.value(14).toString() );
777  pVideoMultiplex->setHierarchy( query.value(15).toString() );
778  pVideoMultiplex->setHPCodeRate( query.value(16).toString() );
779  pVideoMultiplex->setModulationSystem( query.value(17).toString() );
780  pVideoMultiplex->setRollOff( query.value(18).toString() );
781  pVideoMultiplex->setSIStandard( query.value(19).toString() );
782  pVideoMultiplex->setServiceVersion( query.value(20).toInt() );
783  pVideoMultiplex->setUpdateTimeStamp(
784  MythDate::as_utc(query.value(21).toDateTime()));
785  pVideoMultiplex->setDefaultAuthority( query.value(22).toString() );
786  }
787 
788  return pVideoMultiplex;
789 }
790 
792 //
794 
796 {
797  MSqlQuery query(MSqlQuery::InitCon());
798 
799  if (!query.isConnected())
800  throw( QString("Database not open while trying to get source name."));
801 
802  query.prepare("SELECT name FROM videosource WHERE sourceid = :SOURCEID ");
803  query.bindValue(":SOURCEID", SourceID);
804 
805  if (!query.exec())
806  {
807  MythDB::DBError("MythAPI::GetXMLTVIdList()", query);
808 
809  throw( QString( "Database Error executing query." ));
810  }
811 
812  QStringList idList;
813 
814  if (query.next())
815  {
816  QString sourceName = query.value(0).toString();
817 
818  QString xmltvFile = GetConfDir() + '/' + sourceName + ".xmltv";
819 
820  if (QFile::exists(xmltvFile))
821  {
822  QFile file(xmltvFile);
823  if (!file.open(QIODevice::ReadOnly | QIODevice::Text))
824  return idList;
825 
826  while (!file.atEnd())
827  {
828  QByteArray line = file.readLine();
829 
830  if (line.startsWith("channel="))
831  {
832  QString id = line.mid(8, -1).trimmed();
833  idList.append(id);
834  }
835  }
836 
837  idList.sort();
838  }
839  }
840  else
841  throw(QString("SourceID (%1) not found").arg(SourceID));
842 
843  return idList;
844 }
845 
846 // Prevent concurrent access to tv_find_grabbers
847 static QMutex lockGrabber;
848 
850 {
851  // ----------------------------------------------------------------------
852  // Build Response
853  // ----------------------------------------------------------------------
854 
855  QMutexLocker lock(&lockGrabber);
856 
857  auto *pGrabberList = new V2GrabberList();
858 
859  // Add default grabbers
860  V2Grabber *pGrabber = pGrabberList->AddNewGrabber();
861  pGrabber->setProgram("eitonly");
862  pGrabber->setDisplayName(QObject::tr("Transmitted guide only (EIT)"));
863  pGrabber = pGrabberList->AddNewGrabber();
864  pGrabber->setProgram("/bin/true");
865  pGrabber->setDisplayName(QObject::tr("No grabber"));
866 
867  QStringList args;
868  args += "baseline";
869 
870  MythSystemLegacy find_grabber_proc("tv_find_grabbers", args,
872  find_grabber_proc.Run(25s);
873  LOG(VB_GENERAL, LOG_INFO,
874  "Running 'tv_find_grabbers " + args.join(" ") + "'.");
875  uint status = find_grabber_proc.Wait();
876 
877  if (status == GENERIC_EXIT_OK)
878  {
879  QTextStream ostream(find_grabber_proc.ReadAll());
880  while (!ostream.atEnd())
881  {
882  QString grabber_list(ostream.readLine());
883 #if QT_VERSION < QT_VERSION_CHECK(5,14,0)
884  QStringList grabber_split =
885  grabber_list.split("|", QString::SkipEmptyParts);
886 #else
887  QStringList grabber_split =
888  grabber_list.split("|", Qt::SkipEmptyParts);
889 #endif
890  QString grabber_name = grabber_split[1];
891  QFileInfo grabber_file(grabber_split[0]);
892  QString program = grabber_file.fileName();
893 
894  if (!pGrabberList->containsProgram(program))
895  {
896  pGrabber = pGrabberList->AddNewGrabber();
897  pGrabber->setProgram(program);
898  pGrabber->setDisplayName(grabber_name);
899  }
900  LOG(VB_GENERAL, LOG_DEBUG, "Found " + grabber_split[0]);
901  }
902  LOG(VB_GENERAL, LOG_INFO, "Finished running tv_find_grabbers");
903  }
904  else
905  {
906  LOG(VB_GENERAL, LOG_ERR, "Failed to run tv_find_grabbers");
907  }
908 
909  return pGrabberList;
910 }
911 
913 {
914  // Channel Frequency Table
915  QStringList freqList;
916  freqList.append("default");
917  for (const auto & freqEntry : gChanLists)
918  {
919  freqList.append(freqEntry.name);
920  }
921  return freqList;
922 
923 }
ChannelInfo
Definition: channelinfo.h:31
MythHTTPService::HAS_PARAMv2
bool HAS_PARAMv2(const QString &p)
Definition: mythhttpservice.h:36
V2Channel::RemoveDBChannel
static bool RemoveDBChannel(uint ChannelID)
Definition: v2channel.cpp:309
MSqlBindings
QMap< QString, QVariant > MSqlBindings
typedef for a map of string -> string bindings for generic queries.
Definition: mythdbcon.h:101
MSqlQuery::next
bool next(void)
Wrap QSqlQuery::next() so we can display the query results.
Definition: mythdbcon.cpp:807
MSqlQuery
QSqlQuery wrapper that fetches a DB connection from the connection pool.
Definition: mythdbcon.h:128
build_compdb.args
args
Definition: build_compdb.py:11
ChannelInfo::m_serviceType
uint m_serviceType
Definition: channelinfo.h:112
V2Channel::AddDBChannel
bool AddDBChannel(uint MplexID, uint SourceID, uint ChannelID, const QString &CallSign, const QString &ChannelName, const QString &ChannelNumber, uint ServiceID, uint ATSCMajorChannel, uint ATSCMinorChannel, bool UseEIT, bool Visible, const QString &ExtendedVisible, const QString &FrequencyID, const QString &Icon, const QString &Format, const QString &XMLTVID, const QString &DefaultAuthority, uint ServiceType)
Definition: v2channel.cpp:274
MSqlQuery::size
int size(void) const
Definition: mythdbcon.h:215
SourceUtil::DeleteSource
static bool DeleteSource(uint sourceid)
Definition: sourceutil.cpp:527
MythSystemLegacy
Definition: mythsystemlegacy.h:67
ChannelInfo::m_chanId
uint m_chanId
Definition: channelinfo.h:85
MythDate::as_utc
QDateTime as_utc(const QDateTime &old_dt)
Returns copy of QDateTime with TimeSpec set to UTC.
Definition: mythdate.cpp:27
ChannelUtil::LoadChannels
static ChannelInfoList LoadChannels(uint startIndex, uint count, uint &totalAvailable, bool ignoreHidden=true, OrderBy orderBy=kChanOrderByChanNum, GroupBy groupBy=kChanGroupByChanid, uint sourceID=0, uint channelGroupID=0, bool liveTVOnly=false, const QString &callsign="", const QString &channum="", bool ignoreUntunable=true)
Load channels from database into a list of ChannelInfo objects.
Definition: channelutil.cpp:2430
SourceUtil::GetChannelCount
static uint GetChannelCount(uint sourceid)
Definition: sourceutil.cpp:133
UseEIT
Definition: videosource.cpp:599
ADD_SQLv2
static void ADD_SQLv2(QString &settings_var, MSqlBindings &bindvar, const QString &col, const QString &api_param, const T &val)
Definition: v2serviceUtil.h:25
kChannelNeverVisible
@ kChannelNeverVisible
Definition: channelinfo.h:25
ChannelUtil::DeleteChannel
static bool DeleteChannel(uint channel_id)
Definition: channelutil.cpp:1765
ChannelInfo::m_freqId
QString m_freqId
Definition: channelinfo.h:87
v2programAndChannel.h
V2Channel::RemoveVideoSource
static bool RemoveVideoSource(uint SourceID)
Definition: v2channel.cpp:581
V2Channel::UpdateDBChannel
bool UpdateDBChannel(uint MplexID, uint SourceID, uint ChannelID, const QString &CallSign, const QString &ChannelName, const QString &ChannelNumber, uint ServiceID, uint ATSCMajorChannel, uint ATSCMinorChannel, bool UseEIT, bool Visible, const QString &ExtendedVisible, const QString &FrequencyID, const QString &Icon, const QString &Format, const QString &XMLTVID, const QString &DefaultAuthority, uint ServiceType)
Definition: v2channel.cpp:186
ChannelUtil::kChanGroupByChanid
@ kChanGroupByChanid
Definition: channelutil.h:209
frequencies.h
MSqlQuery::value
QVariant value(int i) const
Definition: mythdbcon.h:205
mythdbcon.h
V2VideoSourceList
Definition: v2videoSourceList.h:12
v2recording.h
mythhttpmetaservice.h
ChannelInfo::m_atscMajorChan
uint m_atscMajorChan
Definition: channelinfo.h:113
MSqlQuery::exec
bool exec(void)
Wrap QSqlQuery::exec() so we can display SQL.
Definition: mythdbcon.cpp:608
ChannelInfo::m_name
QString m_name
Definition: channelinfo.h:92
MythDate::Format
Format
Definition: mythdate.h:15
LOG
#define LOG(_MASK_, _LEVEL_, _QSTRING_)
Definition: mythlogging.h:39
SourceID
Definition: videosource.cpp:2873
MythSystemLegacy::ReadAll
QByteArray & ReadAll()
Definition: mythsystemlegacy.cpp:402
ChannelUtil::kChanOrderByName
@ kChanOrderByName
Definition: channelutil.h:201
build_compdb.file
file
Definition: build_compdb.py:55
SourceUtil::CreateSource
static int CreateSource(const QString &sourcename, const QString &grabber, const QString &userid, const QString &freqtable, const QString &lineupid, const QString &password, bool useeit, const QString &configpath, int nitid, uint bouquetid, uint regionid, uint scanfrequency, uint lcnoffset)
Definition: sourceutil.cpp:474
mythdirs.h
V2Channel::RegisterCustomTypes
static void RegisterCustomTypes()
kChannelAlwaysVisible
@ kChannelAlwaysVisible
Definition: channelinfo.h:22
GENERIC_EXIT_OK
@ GENERIC_EXIT_OK
Exited with no error.
Definition: exitcodes.h:11
ChannelUtil::CreateChannel
static bool CreateChannel(uint db_mplexid, uint db_sourceid, uint new_channel_id, const QString &callsign, const QString &service_name, const QString &chan_num, uint service_id, uint atsc_major_channel, uint atsc_minor_channel, bool use_on_air_guide, ChannelVisibleType visible, const QString &freqid, const QString &icon=QString(), QString format="Default", const QString &xmltvid=QString(), const QString &default_authority=QString(), uint service_type=0)
Definition: channelutil.cpp:1483
Visible
Definition: channelsettings.cpp:392
ChannelInfo::m_icon
QString m_icon
Definition: channelinfo.h:93
V2Channel::GetChannelInfoList
static V2ChannelInfoList * GetChannelInfoList(uint SourceID, uint ChannelGroupID, uint StartIndex, uint Count, bool OnlyVisible, bool Details, bool OrderByName, bool GroupByCallsign, bool OnlyTunable)
Definition: v2channel.cpp:91
MythDate::current
QDateTime current(bool stripped)
Returns current Date and Time in UTC.
Definition: mythdate.cpp:14
V2Grabber
Definition: v2grabber.h:20
V2Channel::GetGrabberList
static V2GrabberList * GetGrabberList()
Definition: v2channel.cpp:849
mythversion.h
mythsystemlegacy.h
ChannelID
Definition: channelsettings.h:20
SourceUtil::IsSourceIDValid
static bool IsSourceIDValid(uint sourceid)
Definition: sourceutil.cpp:377
MYTH_PROTO_VERSION
static constexpr const char * MYTH_PROTO_VERSION
Increment this whenever the MythTV network protocol changes.
Definition: mythversion.h:47
ChannelInfo::m_useOnAirGuide
bool m_useOnAirGuide
Definition: channelinfo.h:108
v2channel.h
mythdate.h
sourceutil.h
SourceUtil::UpdateChannelsFromListings
static bool UpdateChannelsFromListings(uint sourceid, const QString &inputtype=QString(), bool wait=false)
Definition: sourceutil.cpp:393
V2ChannelInfoList
Definition: v2channelInfoList.h:10
ServiceID
Definition: channelsettings.cpp:313
GetConfDir
QString GetConfDir(void)
Definition: mythdirs.cpp:224
v2serviceUtil.h
channelVisibleTypeFromString
ChannelVisibleType channelVisibleTypeFromString(const QString &type)
Definition: channelinfo.cpp:539
V2Channel::GetVideoMultiplex
static V2VideoMultiplex * GetVideoMultiplex(uint MplexID)
Definition: v2channel.cpp:733
V2Channel::GetXMLTVIdList
static QStringList GetXMLTVIdList(uint SourceID)
Definition: v2channel.cpp:795
ChannelInfo::m_atscMinorChan
uint m_atscMinorChan
Definition: channelinfo.h:114
MSqlQuery::InitCon
static MSqlQueryInfo InitCon(ConnectionReuse _reuse=kNormalConnection)
Only use this in combination with MSqlQuery constructor.
Definition: mythdbcon.cpp:540
compat.h
MythDB::DBError
static void DBError(const QString &where, const MSqlQuery &query)
Definition: mythdb.cpp:227
V2Channel::AddVideoSource
static int AddVideoSource(const QString &SourceName, const QString &Grabber, const QString &UserId, const QString &FreqTable, const QString &LineupId, const QString &Password, bool UseEIT, const QString &ConfigPath, int NITId, uint BouquetId, uint RegionId, uint ScanFrequency, uint LCNOffset)
Definition: v2channel.cpp:548
v2freqtable.h
ChannelInfo::m_chanNum
QString m_chanNum
Definition: channelinfo.h:86
MythSystemLegacy::Wait
uint Wait(std::chrono::seconds timeout=0s)
Definition: mythsystemlegacy.cpp:243
V2Channel::V2Channel
V2Channel()
Definition: v2channel.cpp:85
CHANNEL_HANDLE
#define CHANNEL_HANDLE
Definition: v2channel.h:37
V2Channel::UpdateVideoSource
bool UpdateVideoSource(uint SourceID, const QString &SourceName, const QString &Grabber, const QString &UserId, const QString &FreqTable, const QString &LineupId, const QString &Password, bool UseEIT, const QString &ConfigPath, int NITId, uint BouquetId, uint RegionId, uint ScanFrequency, uint LCNOffset)
Definition: v2channel.cpp:433
V2Channel::GetChannelInfo
static V2ChannelInfo * GetChannelInfo(uint ChanID)
Definition: v2channel.cpp:169
MSqlQuery::seek
bool seek(int where, bool relative=false)
Wrap QSqlQuery::seek(int,bool)
Definition: mythdbcon.cpp:827
V2FillChannelInfo
bool V2FillChannelInfo(V2ChannelInfo *pChannel, uint nChanID, bool bDetails)
Definition: v2serviceUtil.cpp:143
V2Channel::GetVideoSource
static V2VideoSource * GetVideoSource(uint SourceID)
Definition: v2channel.cpp:379
ChannelVisibleType
ChannelVisibleType
Definition: channelinfo.h:20
MYTH_BINARY_VERSION
static constexpr const char * MYTH_BINARY_VERSION
Update this whenever the plug-in ABI changes.
Definition: mythversion.h:15
MSqlQuery::isConnected
bool isConnected(void) const
Only updated once during object creation.
Definition: mythdbcon.h:138
uint
unsigned int uint
Definition: compat.h:79
MythHTTPService
Definition: mythhttpservice.h:19
kMSRunShell
@ kMSRunShell
run process through shell
Definition: mythsystem.h:43
lockGrabber
static QMutex lockGrabber
Definition: v2channel.cpp:847
channelutil.h
V2Channel::RemoveAllVideoSources
static bool RemoveAllVideoSources(void)
Definition: v2channel.cpp:574
v2artworkInfoList.h
ChannelUtil::UpdateChannel
static bool UpdateChannel(uint db_mplexid, uint source_id, uint channel_id, const QString &callsign, const QString &service_name, const QString &chan_num, uint service_id, uint atsc_major_channel, uint atsc_minor_channel, bool use_on_air_guide, ChannelVisibleType visible, const QString &freqid=QString(), const QString &icon=QString(), QString format=QString(), const QString &xmltvid=QString(), const QString &default_authority=QString(), uint service_type=0)
Definition: channelutil.cpp:1563
gChanLists
const CHANLISTS_vec gChanLists
Definition: frequencies.cpp:2215
CardUtil::GetRawInputType
static QString GetRawInputType(uint inputid)
Definition: cardutil.h:287
ChannelInfo::m_serviceId
uint m_serviceId
Definition: channelinfo.h:111
kChannelVisible
@ kChannelVisible
Definition: channelinfo.h:23
mythcorecontext.h
V2Channel::GetDDLineupList
static V2LineupList * GetDDLineupList(const QString &Source, const QString &UserId, const QString &Password)
Definition: v2channel.cpp:592
cardutil.h
V2VideoMultiplexList
Definition: v2videoMultiplexList.h:11
ChannelInfo::Load
bool Load(uint lchanid=-1)
Definition: channelinfo.cpp:131
MSqlQuery::bindValue
void bindValue(const QString &placeholder, const QVariant &val)
Add a single binding.
Definition: mythdbcon.cpp:883
Q_GLOBAL_STATIC_WITH_ARGS
Q_GLOBAL_STATIC_WITH_ARGS(MythHTTPMetaService, s_service,(CHANNEL_HANDLE, V2Channel::staticMetaObject, &V2Channel::RegisterCustomTypes)) void V2Channel
Definition: v2channel.cpp:61
V2Channel::FetchChannelsFromSource
static int FetchChannelsFromSource(uint SourceId, uint CardId, bool WaitForFinish)
Definition: v2channel.cpp:604
V2LineupList
Definition: v2lineup.h:56
ChannelInfo::m_sourceId
uint m_sourceId
Definition: channelinfo.h:89
V2GrabberList
Definition: v2grabber.h:48
ChannelInfo::m_tvFormat
QString m_tvFormat
Definition: channelinfo.h:105
V2Channel::GetVideoSourceList
static V2VideoSourceList * GetVideoSourceList(void)
Definition: v2channel.cpp:320
V2Channel::GetFreqTableList
static QStringList GetFreqTableList()
Definition: v2channel.cpp:912
SourceUtil::DeleteAllSources
static bool DeleteAllSources(void)
Definition: sourceutil.cpp:583
V2VideoMultiplex
Definition: v2videoMultiplex.h:12
ChannelInfo::m_xmltvId
QString m_xmltvId
Definition: channelinfo.h:97
Icon
Definition: channelsettings.cpp:209
MythHTTPService::m_request
HTTPRequest2 m_request
Definition: mythhttpservice.h:35
MythSystemLegacy::Run
void Run(std::chrono::seconds timeout=0s)
Runs a command inside the /bin/sh shell. Returns immediately.
Definition: mythsystemlegacy.cpp:213
V2Channel::GetVideoMultiplexList
static V2VideoMultiplexList * GetVideoMultiplexList(uint SourceID, uint StartIndex, uint Count)
Definition: v2channel.cpp:635
ChannelInfo::m_mplexId
uint m_mplexId
Definition: channelinfo.h:110
v2castMemberList.h
ChannelInfo::m_visible
ChannelVisibleType m_visible
Definition: channelinfo.h:106
kMSStdOut
@ kMSStdOut
allow access to stdout
Definition: mythsystem.h:41
v2grabber.h
V2VideoSource
Definition: v2videoSource.h:10
MythHTTPMetaService
Definition: mythhttpmetaservice.h:10
ChannelInfo::m_defaultAuthority
QString m_defaultAuthority
Definition: channelinfo.h:118
ChannelInfo::m_callSign
QString m_callSign
Definition: channelinfo.h:91
V2ChannelInfo
Definition: v2programAndChannel.h:27
ChannelUtil::kChanOrderByChanNum
@ kChanOrderByChanNum
Definition: channelutil.h:200
ChannelUtil::kChanGroupByCallsign
@ kChanGroupByCallsign
Definition: channelutil.h:207
kChannelNotVisible
@ kChannelNotVisible
Definition: channelinfo.h:24
MSqlQuery::prepare
bool prepare(const QString &query)
QSqlQuery::prepare() is not thread safe in Qt <= 3.3.2.
Definition: mythdbcon.cpp:832
ChannelInfoList
std::vector< ChannelInfo > ChannelInfoList
Definition: channelinfo.h:131