📄 eons.h
字号:
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//
// Use of this source code is subject to the terms of your Microsoft Windows CE
// Source Alliance Program license form. If you did not accept the terms of
// such a license, you are not authorized to use this source code.
//
#ifndef __EONS_H__
#define __EONS_H__
#include <Toolbox.h>
#include <ril.h>
struct OPLStruct
{
char szPLMN[16];
DWORD dwLACa;
DWORD dwLACz;
DWORD dwIndex;
};
class EONS
{
public:
EONS();
EONS( const EONS& ref );
virtual ~EONS();
void Clear();
virtual HRESULT Read();
BOOL Ready() const;
BOOL Search( DWORD dwPLMN, __opt RILOPERATORNAMES *pRON ) const;
BOOL Search( DWORD dwPLMN, DWORD dwLAC, __opt RILOPERATORNAMES *pRON ) const;
void Dump() const;
protected:
static const DWORD EFopl;
static const DWORD EFpnn;
virtual HRESULT ReadData();
virtual HRESULT ReadOPLData();
virtual HRESULT ReadPNNData();
BOOL DecodeNetworkNameTLV( const char *cptr, __in_ecount(dwOut) char *pszOUT, DWORD dwOut ) const;
GrowableThingCollection<OPLStruct> m_opl;
GrowableThingCollection<RILOPERATORNAMES> m_pnn;
private:
EONS& operator= ( const EONS& ref );
static const char WILDCARD;
static const char DONTCARE;
static const int IEIfullname;
static const int IEIshortname;
static DWORD s_ThreadStartCallback( LPVOID lpThreadData );
BOOL Match( DWORD dwPLMN, DWORD dwLAC, __opt RILOPERATORNAMES *pRON ) const;
void Validate() const;
mutable CRITICAL_SECTION m_cs;
HANDLE m_hThread;
BOOL m_fDoneReading;
};
/*************************/
/*************************/
class EONSCache : public EONS
{
public:
EONSCache();
EONSCache( const EONS& ref );
virtual ~EONSCache();
virtual HRESULT Read();
virtual HRESULT Write();
void Invalidate();
protected:
static const TCHAR RegistryPath[];
/* read from cache */
virtual HRESULT ReadOPLData();
virtual HRESULT ReadPNNData();
/* write to cache */
virtual HRESULT WriteOPLData();
virtual HRESULT WritePNNData();
private:
EONSCache( const EONSCache& ref );
EONSCache& operator= ( const EONSCache& ref );
};
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -