当前位置: 首页>>代码示例>>C++>>正文


C++ TransactionEntry::timerExpired方法代码示例

本文整理汇总了C++中TransactionEntry::timerExpired方法的典型用法代码示例。如果您正苦于以下问题:C++ TransactionEntry::timerExpired方法的具体用法?C++ TransactionEntry::timerExpired怎么用?C++ TransactionEntry::timerExpired使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在TransactionEntry的用法示例。


在下文中一共展示了TransactionEntry::timerExpired方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: updateGSMSignalling

/**
	Check GSM signalling.
	Can block for up to 52 GSM L1 frames (240 ms) because LCH::send is blocking.
	@param transaction The call's TransactionEntry.
	@param LCH The call's logical channel (TCH/FACCH or SDCCH).
	@return true If the call was cleared.
*/
bool updateGSMSignalling(TransactionEntry &transaction, LogicalChannel *LCH, unsigned timeout=0)
{
	if (transaction.Q931State()==TransactionEntry::NullState) return true;

	// Any Q.931 timer expired?
	if (transaction.timerExpired()) {
		// Cause 0x66, "recover on timer expiry"
		abortCall(transaction,LCH,L3Cause(0x66));
		return true;
	}

	// Look for a control message from MS side.
	if (L3Frame *l3 = LCH->recv(timeout)) {
		// Check for lower-layer error.
		if (l3->primitive() == ERROR) return true;
		// Parse and dispatch.
		L3Message *l3msg = parseL3(*l3);
		delete l3;
		bool cleared = false;
		if (l3msg) {
			LOG(DEBUG) << "received " << *l3msg;
			cleared = callManagementDispatchGSM(transaction, LCH, l3msg);
			delete l3msg;
		}
		return cleared;
	}

	// If we are here, we have timed out, but assume the call is still running.
	return false;
}
开发者ID:0x7678,项目名称:openbts-uhd,代码行数:37,代码来源:CallControl.cpp


注:本文中的TransactionEntry::timerExpired方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。