Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Portability layer
Message
De
04/09/1998 11:35:07
 
 
À
03/09/1998 17:36:03
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00132981
Message ID:
00133342
Vues:
13
Some good suggestions from you and John.

I'm not planning on implementing any such scheme today. Was more curious if anybody had tried it. I'd love to try some scheme later. (Of course, finding the time is always the issue <g>)


Bob

>>Anybody ever implemented a portability wrapper for VFP? I mean create a class, say _VFP, that contains methods that correspond to every (most?) VFP command/function.
>>
>>So, instead of writing
>>cText = LEFT("abc", 2)
>>
>>you would write
>>cText = _VFP.Left("abc", 2)
>>
>>
>>I can't count the number of times that such a layer would have saved me from having to go back and rework some code. Example: for internationalization issues I want all my LEFTs to be LEFTCs. With the wrapper, I could implement the Left() method to call LEFTC and not touch my code. I could change all my _VFP.MessageBox(...) calls to actually be implemented as a MsgSvc() call or whatever.
>>
>>I don't know the performance issues involved, but there certainly seem to be some merits to doing this.
>>
>>
>>Bob
>
>
>Why not redefine the functions using header files?
>
>#DEFINE LEFT MyLeft
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform