⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 instance_protocol802_11.cpp

📁 270的linux说明
💻 CPP
📖 第 1 页 / 共 3 页
字号:
}//=============================================================================void Protocol80211_MulticastTransmittedFrameCountClass::GetValueImpl(){	_Log(IntelMobileText("MulticastTransmittedFrameCountClass::GetValueImpl()"));	DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	if(!pThis)		return;	try	{		pThis->Lock();		netdev_dev netdev;		if(netdev_get_device(pThis->GetKey().c_str(), netdev) != NETDEV_SUCCESS)		{			throw;		}		netdev_statistics stats;		if(netdev_get_statistics(netdev, stats) != NETDEV_SUCCESS)		{			this->SetNull(true);			return;		}		IntelMobileUInt64 multiCount = stats.tx_multicast;		this->SetValueImpl(multiCount);			pThis->Unlock();	}	catch(...)	{			pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}}void Protocol80211_MultipleRetryCountClass::GetValueImpl(){	_Log(IntelMobileText("MultipleRetryCountClass::GetValueImpl()"));	this->SetNull(true);}void Protocol80211_ReceivedFragmentCountClass::GetValueImpl(){	_Log(IntelMobileText("ReceivedFragmentCountClass::GetValueImpl()"));	DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	try	{		pThis->Lock();		netdev_dev netdev;		if(netdev_get_device(pThis->GetKey().c_str(), netdev) != NETDEV_SUCCESS)		{			throw;		}		netdev_statistics stats;		if(netdev_get_statistics(netdev, stats) != NETDEV_SUCCESS)		{			this->SetNull(true);			return;		}		IntelMobileUInt64 fragCount = stats.rx_frame_errors;		this->SetValueImpl(fragCount);		pThis->Unlock();	}	catch(...)	{		pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}}void Protocol80211_TransmittedFragmentCountClass::GetValueImpl(){	_Log(IntelMobileText("TransmittedFragmentCountClass::GetValueImpl()"));	DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	try	{		pThis->Lock();		netdev_dev netdev;		if(netdev_get_device(pThis->GetKey().c_str(), netdev) != NETDEV_SUCCESS)		{			throw;		}		netdev_statistics stats;		if(netdev_get_statistics(netdev, stats) != NETDEV_SUCCESS)		{			this->SetNull(true);			return;		}		IntelMobileUInt64 fragCount = stats.tx_frame_errors;		this->SetValueImpl(fragCount);		pThis->Unlock();	}	catch(...)	{		pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}}void Protocol80211_RetryCountClass::GetValueImpl(){	_Log(IntelMobileText("RetryCountClass::GetValueImpl()"));	this->SetNull(true);	}void Protocol80211_RtsFailureCountClass::GetValueImpl(){	_Log(IntelMobileText("RTSFailureCountClass::GetValueImpl()"));	this->SetNull(true);	}void Protocol80211_RtsSuccessCountClass::GetValueImpl(){	_Log(IntelMobileText("RTSSuccessCountClass::GetValueImpl()"));	this->SetNull(true);	}void Protocol80211_OperatingModeClass::GetValueImpl(){	_Log( LOG_DEBUG_DEVICE, IntelMobileText("Trace: OperatingModeClass::GetValueImpl()") );		DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	try	{		pThis->Lock();		netdev_dev netdev;		if(netdev_get_device(pThis->GetKey().c_str(), netdev) != NETDEV_SUCCESS)		{			throw;		}		wnetdev_opt_mode mode;		if(wnetdev_get_opt_mode(netdev, mode) != NETDEV_SUCCESS)		{			this->SetNull(true);			return;		}		IntelMobileProtocol802_11OperatingModeEnum byValue;		switch(mode)		{			case OPTMODE_ADHOC:				byValue = Protocol802_11OperatingModeEnum::Adhoc;				break;			case OPTMODE_INFRASTRUCTURE:				byValue = Protocol802_11OperatingModeEnum::Infrastructure;				break;			default:				byValue = Protocol802_11OperatingModeEnum::Unknown;		}		this->SetValueImpl(byValue);		pThis->Unlock();	}	catch(...)	{		pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}}void Protocol80211_RssiClass::GetValueImpl(){	_Log(IntelMobileText("RssiClass::GetValueImpl()"));	DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	try	{		pThis->Lock();		netdev_dev netdev;		if(netdev_get_device(pThis->GetKey().c_str(), netdev) != NETDEV_SUCCESS)		{			throw;		}		wnetdev_signal signal;		if(wnetdev_get_signal(netdev, signal) != NETDEV_SUCCESS)		{			this->SetNull(true);			return;		}		IntelMobileInt value = signal;		this->SetValueImpl(value);		pThis->Unlock();	}	catch(...)	{		pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}}void Protocol80211_ModulationTypesClass::GetValueImpl(){	_Log(IntelMobileText("NetworkTypesSupportedClass::GetValueImpl()"));	DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	try	{		pThis->Lock();		this->SetNull(true);		pThis->Unlock();	}	catch(...)	{		pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}}void Protocol80211_ModulationTypeClass::GetValueImpl(){	_Log(IntelMobileText("NetworkTypeInUseClass::GetValueImpl()"));	DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	try	{		pThis->Lock();		this->SetNull(true);		pThis->Unlock();	}	catch(...)	{		pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}}// ################################################################################################// ################################################################################################// #####                                                                                    #######// #####                               New implementations                                  #######// #####                                                                                    #######// ################################################################################################// ################################################################################################void Protocol80211_FragmentationThresholdClass::GetValueImpl(){	_Log(IntelMobileText("FragmentationThresholdClass::GetValueImpl()"));	DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	try	{		pThis->Lock();		netdev_dev netdev;		if(netdev_get_device(pThis->GetKey().c_str(), netdev) != NETDEV_SUCCESS)		{			throw;		}		wnetdev_frag_threshold frag_thr;		if(wnetdev_get_frag_threshold(netdev, frag_thr) != NETDEV_SUCCESS)		{			this->SetNull(true);			return;		}		this->SetValueImpl(frag_thr);		pThis->Unlock();	}	catch(...)	{				pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}}bool Protocol80211_FragmentationThresholdClass::SetValueImplOnDevice( IntelMobileUInt sInput ){	//	// TODO: SetValueImpl	return false;}void Protocol80211_TxPowerClass::GetValueImpl(){	_Log(IntelMobileText("RadioTxPowerClass::GetValueImpl()"));	DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	try	{		pThis->Lock();		netdev_dev netdev;		if(netdev_get_device(pThis->GetKey().c_str(), netdev) != NETDEV_SUCCESS)		{			throw;		}		wnetdev_txpower txpower;		if(wnetdev_get_txpower(netdev, txpower) != NETDEV_SUCCESS)		{			this->SetNull(true);			return;		}		this->SetValueImpl(txpower);		pThis->Unlock();	}	catch(...)	{		pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}}void Protocol80211_DataRatesTxClass::GetValueImpl()  //SupportedTxDataRates{	_Log(IntelMobileText("RadioSupportedTxDataRatesClass::GetValueImpl()"));	DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	try	{		pThis->Lock();		netdev_dev netdev;		if(netdev_get_device(pThis->GetKey().c_str(), netdev) != NETDEV_SUCCESS)		{			throw;		}		vector<wnetdev_bitrate> rate_list;		if(wnetdev_get_supported_bitrates(netdev, rate_list) != NETDEV_SUCCESS)		{			this->SetNull(true);			return;		}		vector<wnetdev_bitrate>::iterator itr = rate_list.begin();		for(; itr != rate_list.end(); itr++)		{			this->InsertValueImpl(*itr);		}		pThis->Unlock();	}	catch(...)	{				pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}	this->SetNull( true );}void Protocol80211_DataRatesRxClass::GetValueImpl(){	_Log(IntelMobileText("RadioSupportedRxDataRatesClass::GetValueImpl()"));	DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	try	{		pThis->Lock();		netdev_dev netdev;		if(netdev_get_device(pThis->GetKey().c_str(), netdev) != NETDEV_SUCCESS)		{			throw;		}		vector<wnetdev_bitrate> rate_list;		if(wnetdev_get_supported_bitrates(netdev, rate_list) != NETDEV_SUCCESS)		{			this->SetNull(true);			return;		}		this->Clear();		vector<wnetdev_bitrate>::iterator itr = rate_list.begin();		for(; itr != rate_list.end(); itr++)		{			this->InsertValueImpl(*itr);		}		pThis->Unlock();	}	catch(...)	{				pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}	this->SetNull( true );}void Protocol80211_SsidClass::GetValueImpl(){	_Log(IntelMobileText("SSIDClass::GetValueImpl()"));	DefaultProtocol802_11InstanceObject* pThis = (DefaultProtocol802_11InstanceObject*)_pThis;	try	{		pThis->Lock();		netdev_dev netdev;		if(netdev_get_device(pThis->GetKey().c_str(), netdev) != NETDEV_SUCCESS)		{			throw;		}		wnetdev_ssid ssid;		if(wnetdev_get_ssid(netdev, ssid) != NETDEV_SUCCESS)		{			this->SetNull(true);			return;		}		IntelMobileString value(ssid);		this->SetValueImpl(value);		pThis->Unlock();	}	catch(...)	{		pThis->Unlock();		THROWIMEXCEPTION("800431C3");	}}bool Protocol80211_SsidClass::SetValueImplOnDevice( IntelMobileString sSsidInput ){	//	// TODO: SetValueImpl	return false;}void Protocol80211_RxAntennaIdClass::GetValueImpl(){	_Log(IntelMobileText("RxAntennaClass::GetValueImpl()"));	this->SetNull( true );}bool Protocol80211_RxAntennaIdClass::SetValueImplOnDevice( IntelMobileUInt sInput ){	//	// TODO: SetValueImpl	return false;}void Protocol80211_TxAntennaIdClass::GetValueImpl(){	_Log(IntelMobileText("TxAntennaClass::GetValueImpl()"));	this->SetNull( true );}bool Protocol80211_TxAntennaIdClass::SetValueImplOnDevice( IntelMobileUInt sInput ){	//	// TODO: SetValueImpl	return false;}void Protocol80211_PowerModeClass::GetValueImpl(){	_Log(IntelMobileText("PowerModeClass::GetValueImpl()"));	this->SetNull( true );}bool Protocol80211_PowerModeClass::SetValueImplOnDevice( IntelMobileProtocol802_11PowerModeEnum sInput ){	// TODO: SetValueImpl	return false;}// Extension// Association Info// CurrentChannel

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -