pointer function
TYPEDEF
typedef int *(JobCompleteCallBack) (char a);
int funct(char a)
{
printf("%d Jobcompleted",a);
return 0;
}
void Doit(char job, JobCompleteCallBack Jcc)
{
//do the job
Jcc(job); //callback
}
void main()
{
Doit(0,funct);
}
指针函数的作用
1.multithreading
2.dynamic link library function call
3.hooking
4.virtulization
5.plug-in model programming
6.c++ virtual function
7.event driven programming
2.