Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Abstract Class mod?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
The Mere Mortals Framework
Divers
Thread ID:
00150899
Message ID:
00151342
Vues:
22
BOb,

>Instead of us having to instantiate a second AbstractFactory in the framework so we don't have to worry about loosing entries we make in the classes table... would it be possible to specify the table that we want the factory to do the lookup in.>

>If no table name is passed it will use classes, but if a table is passed it will do the lookup there.>

>This way we only need one instance of the class instead of two. This will save overhead right?>

When you have two objects that inherit from the same class, there's *very* little extra overhead (particularly in the case of the Abstract Factory) when instantiating the second object. Visual FoxPro points to the same memory space as the first object for the "lineage" information.

Since this is the case, two Abstract Factory objects would be more efficient than dynamically swapping class lookup tables at runtime.

Regards,
Kevin McNeish
Eight-Time .NET MVP
VFP and iOS Author, Speaker & Trainer
Oak Leaf Enterprises, Inc.
Chief Architect, MM Framework
http://www.oakleafsd.com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform