Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Design Pattern - Factory and Abstract Factory
Message
De
03/01/2006 14:04:32
Mike Yearwood
Toronto, Ontario, Canada
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
01082705
Message ID:
01082755
Vues:
25
Hey Jim

>The factory that I use is data driven from a DBF. The DBF has filed for the Item name that I want to create and other fields that hold the classlib and classname that should be used. This way I can;
>
>
>loFactory = Cretae("Factory")
>loWait = loFactory.GetObject("MyPleaseWait")
>* Now loWait is which ever class the factory data file says it should be
>* I can change the form by changing the metadata and no code change is needed
>* I cna mov3 the classlibs around as long as I update the metadata
>
That's one of the approaches I outlined. The questions I have revolve around the implementation matching the definition. In this case, your "client" is employing a data driven factory method patten, not an abstract factory pattern?

Do you not lose a potential for decorating the MyPleaseWait by not using a MyPleaseWait factory as loFactory?
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform