Package.h
上传用户:maryhy001
上传日期:2007-05-02
资源大小:2317k
文件大小:1k
- #ifndef _PACKAGE_H
- #define _PACKAGE_H
- #include "stdNetApi.h"
- //@@@@@@@@@@@@@@@@ package struct define here @@@@@@@@@@@@@@@@@
- //max net packet size(bytes).
- #define MAX_NET_PACKET 8192
- //max net chating package size
- #define MAX_NETCHAT_PACKET 1024
- #define MAX_IP_ADDR_SIZE 20
- #define MAX_HOST_NAME_SIZE 256
- //system control command package type
- #define PKT_COMMAND 0x1000
- #define PKT_CMD_CLTSIGNIN 0x1001
- //command package types --- reponse package type
- #define AKT_CMD_CLTSIGNINOK 0x1011
- #define AKT_CMD_CLTSIGNINFAIL 0x1012
- //file transfer package type
- #define PKT_FLE_UPLOAD 0x2000
- #define PKT_FLE_DOWNLOADFLE 0x2010
- //file transfer package types
- #define PKT_FLE_HEADER 0x2001
- #define PKT_FLE_BODY 0x2002
- #define PKT_FLE_TAIL 0x2003
- //file transfer package types --- response package type
- #define AKT_FLE_RECVFLEHEADEROK 0x2004
- #define AKT_FLE_RECVFLEHEADERFAIL 0x2005
- #define AKT_FLE_RECVFLEBODYPACKOK 0x2006
- #define AKT_FLE_RECVFLEBODYPACKFAIL 0x2007
- #define AKT_FLE_RECVFLETAILOK 0x2008
- #define AKT_FLE_RECVFLETAILFAIL 0x2009
- //net file header struct.
- typedef struct tagNetFileHdr{
-
- char szFileName[MAX_PATH];
- BY_HANDLE_FILE_INFORMATION fiFileInfo;
- char szSenderIp[MAX_IP_ADDR_SIZE];
- char szSenderHost[MAX_HOST_NAME_SIZE];
- char szInLocalFileName[MAX_PATH];
- }NETFILEHDR, *LPNETFILEHDR;
- #endif //_PACKAGE_H