const CPVRChannel *CPVRChannelGroup::GetByChannelUp(const CPVRChannel &channel) const { CSingleLock lock(m_critSection); unsigned int iChannelNumber = GetChannelNumber(channel) + 1; if (iChannelNumber > size()) iChannelNumber = 1; return GetByChannelNumber(iChannelNumber); }
const CPVRChannel *CPVRChannelGroup::GetByChannelDown(const CPVRChannel &channel) const { CSingleLock lock(m_critSection); int iChannelNumber = GetChannelNumber(channel) - 1; if (iChannelNumber <= 0) iChannelNumber = size(); return GetByChannelNumber(iChannelNumber); }
bool CPVRChannelNumberInputHandler::CheckInputAndExecuteAction() { const CPVRChannelNumber channelNumber = GetChannelNumber(); if (channelNumber.IsValid()) { // we have a valid channel number; execute the associated action now. ExecuteAction(); return true; } return false; }
///Equality operator, we only check to see if the module number, channel number, and times are equal. ///@param [in] rhs : the configuration to compare to ///@return true if the module number, channel number, and time are identical bool operator==(const ChanEvent &rhs) const { return GetModuleNumber() == rhs.GetModuleNumber() && GetChannelNumber() == rhs.GetChannelNumber() && GetTime() == rhs.GetTime(); }
/** \return the channel id defined as pixie module # * 16 + channel number */ unsigned int GetID() const { return DetectorLibrary::get()->GetIndex(GetModuleNumber(), GetChannelNumber()); }
//! \return The channelConfiguration in the map for the channel event const ChannelConfiguration &GetChanID() const { return DetectorLibrary::get()->at(GetModuleNumber(), GetChannelNumber()); }