本文整理汇总了C++中CEpgInfoTag::EndAsLocalTime方法的典型用法代码示例。如果您正苦于以下问题:C++ CEpgInfoTag::EndAsLocalTime方法的具体用法?C++ CEpgInfoTag::EndAsLocalTime怎么用?C++ CEpgInfoTag::EndAsLocalTime使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CEpgInfoTag
的用法示例。
在下文中一共展示了CEpgInfoTag::EndAsLocalTime方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: MatchStartAndEndTimes
bool EpgSearchFilter::MatchStartAndEndTimes(const CEpgInfoTag &tag) const
{
return (tag.StartAsLocalTime() >= m_startDateTime && tag.EndAsLocalTime() <= m_endDateTime);
}
示例2: ScheduleRecording
JSON_STATUS CPVROperations::ScheduleRecording(const CStdString &method, ITransportLayer *transport, IClient *client, const CVariant ¶meterObject, CVariant &result)
{
if (!g_PVRManager.IsStarted())
{
CLog::Log(LOGDEBUG, "JSONRPC: PVR not started");
return FailedToExecute;
}
int iEpgId = (int)parameterObject["epgid"].asInteger();
int iUniqueId = (int)parameterObject["uniqueid"].asInteger();
int iStartTime = (int)parameterObject["starttime"].asInteger();
if (iEpgId > 0 && iUniqueId > 0 && iStartTime > 0)
{
CDateTime startTime(iStartTime);
CEpgInfoTag *tag = g_EpgContainer.GetById(iEpgId)->GetTag(iUniqueId, startTime);
if (tag && tag->ChannelTag())
{
CLog::Log(LOGDEBUG, "JSONRPC: schedule recording - channel: '%s' start: '%s' end: '%s'", tag->ChannelTag()->ChannelName().c_str(), tag->StartAsLocalTime().GetAsLocalizedDateTime(false, false).c_str(), tag->EndAsLocalTime().GetAsLocalizedDateTime(false, false).c_str());
CPVRTimerInfoTag *newTimer = CPVRTimerInfoTag::CreateFromEpg(*tag);
bool bCreated = (newTimer != NULL);
bool bAdded = false;
if (bCreated)
{
CLog::Log(LOGDEBUG, "JSONRPC: recording scheduled");
bAdded = CPVRTimers::AddTimer(*newTimer);
}
else
{
CLog::Log(LOGERROR, "JSONRPC: failed to schedule recording");
}
delete newTimer;
return bAdded ? ACK : InternalError;
}
}
return InvalidParams;
}