基本结构
(这部分的地址均为网络地址)
1、struct sockaddr:通用套接字地址结构
此结构用于存储通用套接字地址。
数据结构定义:
typedef unsigned short sa_family_t;
struct sockaddr {
sa_family_t sa_family; /* address family, AF_xxx */...
分类:
其他好文 时间:
2014-08-15 22:35:49
阅读次数:
443
网络传输经常用base64编码的数据,因此我们需要将其解码成正常字符集合。 base64.h 1 #ifdef __cplusplus 2 extern "C" { 3 #endif 4 5 char * base64_encode( const unsigned char * binda...
分类:
其他好文 时间:
2014-08-15 19:14:09
阅读次数:
167
9.51 设计一类,它又三个unsigned成员,分别表示年月日。为其编写构造函数,接受一个表示日期的string参数。程序如下:#include#includeusing namespace std;class My_Date{public: My_Date(const string &s)...
分类:
其他好文 时间:
2014-08-15 17:32:49
阅读次数:
170
http://bbs.csdn.net/topics/250068243char *strcpy(char* dest, const char *src);用unsigned char编译会出错U8 dest[5];U8 src[5] = {0x01,0x02,0x03,0x04,0x05};//加...
分类:
其他好文 时间:
2014-08-15 14:08:58
阅读次数:
249
struct bitmap{ unsigned int len; unsigned char* buf;};struct bitmap* creat_bitmap(unsigned int len){ struct bitmap *bm; if (len buf = ...
分类:
其他好文 时间:
2014-08-15 12:46:48
阅读次数:
213
/*使用unsigned const char*纯碎是为了配合项目,改成char*会比较通用些*/BOOL CDllSuiteEngine::Time_StrToType(unsigned const char* lpszValue, SYSTEMTIME &time){ if (!lpszV...
分类:
其他好文 时间:
2014-08-15 12:29:28
阅读次数:
308
int b = 0, c = 0;// b 输入的0~255之间的数 c 移动位数
printf("请输入一个整数和移动位数\n");
scanf("%d%d", &b, &c);
unsigned char a = b;
unsigned char left = 0;//存储左移之后的结果
unsigned char right = 0;...
分类:
编程语言 时间:
2014-08-15 09:33:07
阅读次数:
255
1.概述 版本: v3.0 beta 语言: C++ 定义在 “COCOS2DX_ROOT/cocos/base” 路径下的 "CCValue.h" 的头文件中。 ? 1 class Value; cocos2d::Valie 是一个包含了很多原生类型(int,float,double,bool,unsigned ch...
分类:
其他好文 时间:
2014-08-15 03:00:37
阅读次数:
214
1 const static unsigned char __crctable[256] = 2 { 3 0x00, 0x91, 0xE3, 0x72, 0x07, 0x96, 0xE4, 0x75, 4 0x0E, 0x9F, 0xED, 0x7C, 0x09, 0x98, 0x...
分类:
其他好文 时间:
2014-08-14 23:24:26
阅读次数:
214
1 #include "timerHz.h" 2 #include "msp430g2553.h" 3 4 #define _DEBUG_TIMERHZ_ 5 6 unsigned int capArray[16] = {0}; 7 unsigned char index = 2, flag ...
分类:
其他好文 时间:
2014-08-14 16:10:28
阅读次数:
277