Click here to Skip to main content
15,908,437 members
Home / Discussions / Design and Architecture
   

Design and Architecture

 
GeneralRe: from c pointer function to good object design Pin
led mike2-Sep-08 5:23
led mike2-Sep-08 5:23 
GeneralRe: from c pointer function to good object design Pin
mp3butcher2-Sep-08 5:53
mp3butcher2-Sep-08 5:53 
GeneralRe: from c pointer function to good object design Pin
led mike2-Sep-08 6:37
led mike2-Sep-08 6:37 
General[Message Deleted] Pin
mp3butcher2-Sep-08 22:10
mp3butcher2-Sep-08 22:10 
General[Message Deleted] Pin
mp3butcher2-Sep-08 22:38
mp3butcher2-Sep-08 22:38 
GeneralRe: from c pointer function to good object design Pin
mp3butcher3-Sep-08 1:35
mp3butcher3-Sep-08 1:35 
GeneralRe: from c pointer function to good object design Pin
led mike3-Sep-08 5:30
led mike3-Sep-08 5:30 
GeneralRe: from c pointer function to good object design Pin
mp3butcher3-Sep-08 23:17
mp3butcher3-Sep-08 23:17 
In fact my question has two linked aspects:
As I can't pass otherthing than a static member function to my cfunction( double (*g)(char*)):
1)I would like to know how I could make it a real parameter (not hardcoded) that belong to the caller of Cfunc.
2)I would like to know how I could make a cool cpp design permitting to overload the argument pointer function.
Then the design side of my question is the second aspect.
First I would like to parametrize my cfunction with member function belonging to the caller object...
If you see a manner to do it passing other thing that a static member function, I would be very glad.
PS: I think what i've done with the function<> template is not what you're thinking of:
class CPP{
double funcparam(char*);
void exec(){
function2<double> f=&CPP::funcparam;
CFUNC(f);
}
};
Silly isn't it?:(For this I think I haven't understand what to do... Cry | :((
the only way I've found to make it work is:

class CPP{
static double funcparam(char*);
void exec(){
CFUNC(&funcparam);
}
};
but it don't permit to overload funcparam...
GeneralRe: from c pointer function to good object design Pin
led mike4-Sep-08 8:55
led mike4-Sep-08 8:55 
GeneralRe: from c pointer function to good object design Pin
mp3butcher4-Sep-08 21:48
mp3butcher4-Sep-08 21:48 
QuestionRe: from c pointer function to good object design Pin
led mike5-Sep-08 4:29
led mike5-Sep-08 4:29 
AnswerRe: from c pointer function to good object design Pin
mp3butcher5-Sep-08 4:55
mp3butcher5-Sep-08 4:55 
Questionloading images and text Pin
netJP12L1-Sep-08 19:03
netJP12L1-Sep-08 19:03 
AnswerRe: loading images and text Pin
Pete O'Hanlon1-Sep-08 23:00
mvePete O'Hanlon1-Sep-08 23:00 
AnswerRe: loading images and text Pin
alex.barylski15-Sep-08 18:40
alex.barylski15-Sep-08 18:40 
GeneralRe: loading images and text Pin
netJP12L16-Sep-08 4:59
netJP12L16-Sep-08 4:59 
GeneralRe: loading images and text Pin
Pete O'Hanlon16-Sep-08 12:07
mvePete O'Hanlon16-Sep-08 12:07 
QuestionFather class in how to use the special sub-category of type Pin
huangrongchuan31-Aug-08 21:56
huangrongchuan31-Aug-08 21:56 
QuestionPhone Number Internationalization Pin
k_dasaprakash31-Aug-08 3:21
k_dasaprakash31-Aug-08 3:21 
AnswerRe: Phone Number Internationalization Pin
Paul Conrad31-Aug-08 5:40
professionalPaul Conrad31-Aug-08 5:40 
AnswerRe: Phone Number Internationalization Pin
Pete O'Hanlon31-Aug-08 8:40
mvePete O'Hanlon31-Aug-08 8:40 
AnswerRe: Phone Number Internationalization Pin
Ray Cassick31-Aug-08 14:33
Ray Cassick31-Aug-08 14:33 
AnswerRe: Phone Number Internationalization [modified] Pin
txjudo18-Nov-08 2:32
txjudo18-Nov-08 2:32 
Questiongive me a solusion Pin
simonsinxer30-Aug-08 1:47
simonsinxer30-Aug-08 1:47 
AnswerRe: give me a solusion Pin
Paul Conrad2-Sep-08 19:11
professionalPaul Conrad2-Sep-08 19:11 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.