Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Control source property
Message
 
À
29/06/1997 23:14:00
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00038071
Message ID:
00038088
Vues:
45
>What are the pros and cons of directly "tying" a form's fields to their data source property vesus creating a "middle level" object that stores the values in each of the form's fields and then has the methods to "insert," "modify," "discard," "rollback," etc. Using the Microsoft 3-tier model, I am inclined to create a business level (or middle level) object to store a form's data and then act upon that data as appropriate.
>
>What are the various opinions about this?
>
>
>Sincerely,
>
>Rob
Rob,

If you choose to go the three tiered model then you need the extra layer of classes to provide the middle tier. In a true three tiered model these calsses would not be part of you aplication because they need to be available to all possible front ends accessing the data.

In VFP 5 you can create OLE public classes to perform the business layer operations for you. Those classes can then be instantiated by VFP, VB, Access, or anyother front end that has the ability to wokr with ActiveX servers.

In theory the three tiered model is very powerfull, but in many systems the overhead is not worth the return. I have worked in a three tiered model but for most of the projects I work on the three tiered model is overkill and so I have tended to use the simpler two tiered model. The database handles the data and the front end presents it.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform