浅谈接口的封装和设计思想入门
2017-03-21 21:17
405 查看
如下是我学习C+的笔记(关于接口的封装和设计思想入门)
只做了小小的总结。 第一套api函数
#ifdefine _CLT_SOCKET_H__
#define _CLT_SOCKET_H__
//客户端初始化环境
int cltSocket_init(void **handle);
//客户端发报文
int cltSocket_senddata(void *handle,unsigned char *buf,int buflen);
//客户端收报文
int cltSocket_resvdata(void*handle,unsigned char *buf,int *buflen);
//客户端销毁报文
int cltSocket_destory(void *handle);
#endif
第二套api函数
#ifndef _CLT_SOCKET_H__
#define _CLT_SOCKET_H__
//客户端初始化环境
int cltSocket_init2(void **handle);
//客户端发报文
int cltSocket_senddata2(void *handle,unsigned char *buf,int buflen);
//客户端收报文
int cltSocket_resvdata2(void*hanle,unsigned char **buf,int *buflen);
int cltSocket_resvdata_Free2(unsigned char *buf);
//客户端销毁报文
int cltSocket_destory2(void *handle);
#endif
相关文章推荐
- 面向接口设计思想
- 面向对象设计三大原则(封装变化点,对接口进行编程,多使用组合而不是继承)
- 程序设计二:基于接口程序设计思想的模板实现、面向方面的程序设计
- C笔记--接口封装思想引导以及初步实践
- [代码分享]静态链表,接口仿照STL设计,操作未做封装
- [代码分享]静态链表,接口仿照STL设计,操作未做封装
- 多态(Polymorphism) 、接口(Interface)、浅谈设计模式
- [代码分享]静态链表,接口仿照STL设计,操作未做封装
- 浅谈单片机程序设计中的“分层思想”
- 微软对基类的使用手册, 觉得与现在流行的针对接口设计思想不是很合拍~~!!!
- 面向对象的分析设计程序思想通过封装、继承、多态将程序耦合度降低,使程序更加灵活、容易修改和易于复用。
- FPGA 设计的四种常用思想与技巧(三)--数据接口的同步方法
- Javascript继承机制的设计思想 封装 继承
- 市场定位和硬件设计的错误-浅谈GM8126的封装
- 微软对基类的使用手册, 觉得与现在流行的针对接口设计思想不是很合拍~~!!!
- C#中类和接口的设计思想(本人认为比较好的思想,欢迎大家讨论指点)
- 浅谈单片机程序设计中的“分层思想”!
- Jser 设计模式系列之面向对象 - 接口封装与继承
- 浅谈设计层次的抽象类和接口异同
- 微软对基类的使用手册, 觉得与现在流行的针对接口设计思想不是很合拍~~!!!