Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Unused classes
Message
De
06/03/2006 21:36:48
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
06/03/2006 21:14:46
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Titre:
Divers
Thread ID:
01101765
Message ID:
01101910
Vues:
16
>>>That would be a false negative. A false positive would be a class which is subclassed, but subclasses are never used.
>>
>>Yeah, I did think about that possibility, but I think that would be no problem. After deleting the unused subclasses, I could run the hypothetical process again, and detect the superclass.
>>
>>> Also, if you're using a data-driven class factory, you'd need to check for factory calls, to see if there are dead records in the factory table.
>>
>>I am not sure how that factory thing would work.
>
>Just more work to be done. Usually, a factory object is called with
>
>
oNewObj=oFactory.Create("The Pink Form")
>
>It looks into some factory.dbf for a record with "The Pink Form" in the name field, and uses other fields to retrieve actual class and classlibrary of the object to create. So the additional work here would be to look for all lines containing oFactory.Create().

So, the actual class instantiation would be delegated to the factory class. Actually quite simple, then, at least the basic concept. Thanks for the explanation.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform