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

📄 cq931ie.hpp

📁 ABis无线接口全套资料
💻 HPP
字号:
//
// cq931ie.hpp
// Q931 information element unpacked and packed class.
// 2005-10-29
//

#ifndef _CQ931IE_HPP
#define _CQ931IE_HPP

#ifndef _Q931IEFMT_HPP
#include "q931iefmt.hpp"
#endif

#define MAX_LENGTH_OF_IE	32

class CChannelIdentification
{
public:
	CChannelIdentification( );
	CChannelIdentification(char len, char  * ptr);
	~CChannelIdentification( );

	void Unpacked(char len, char  * ptr);
	char  * Packed(SQ931CiB3 byte3, SQ931CiB3_2 byte3_2, unsigned short pcm, unsigned char ts, int& len);

public:
	unsigned short GetPcm( )
	{
		return pcmId;
	}

	unsigned char GetChannel( )
	{
		return tsId;
	}

	unsigned char NumberOfChannel( )
	{
		return noChn;
	}

	unsigned char  * GetChannelArray( )
	{
		return channel;
	}
	
	SQ931CiB3& GetB3( )
	{
		return b3;
	}

	SQ931CiB3_2& GetB3_2( )
	{
		return b3_2;
	}
	
public:
	SQ931CiB3	b3;		// The byte 3 of channel identification.
	SQ931CiB3_2	b3_2;	// the byte 3.2 of channel identification.
	unsigned short pcmId;
	unsigned char tsId;
	unsigned char noChn;
	unsigned char channel[32];

private:
	char  * content;
};

class CBearerCapability
{
public:
	CBearerCapability( );
	CBearerCapability(char len, char  * ptr);
	~CBearerCapability( );

	void Unpacked(char len, char  * ptr);
	char  * Packed(UINT16& len); // Packed BC information element according internal data.
	// char  * Packed(SQ931CiB3 byte3, SQ931CiB3_2 byte3_2, unsigned short pcm, unsigned char ts, int& len);
public:
	SQ931BcB3 b3;
	SQ931BcB4 b4;
	SQ931BcB4_1 b4_1;
	SQ931BcB5d  b5d; // Byte 5 that include 5a ~ 5d
	SQ931BcB6B7 b6;
	SQ931BcB6B7 b7;
	char lengthOfB5;

public:
	char isB5Exist; // 0: Not exist; 1: Exist.
	char isB6Exist; // 0: Not exist; 1: Exist.
	char isB7Exist; // 0: Not exist; 1: Exist.

private:
	char  * content;
};

#endif // ifndef _CQ931_HPP

⌨️ 快捷键说明

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