Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Is there any way around this issue?
Message
From
29/05/2003 21:53:13
 
 
To
29/05/2003 15:30:37
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00793727
Message ID:
00794335
Views:
19
>Hi John,
>Am I reading this right?
>You're saying to have "abstract" classes that are not meant to be instantiated >into objects, but then have a set of "concrete" classes to use in objects.

Yes, I am. These are subclasses of the VFP classes available through the Visual Class Designer or DEFINE CLASS statements in a procedure file.


>What's the point of the "abstract" classes?

They hold the default functiona;lity that every object which is instantiated will have. In the event that the VFP team adds functionality to these base classes, they will automatically be inherited by this set of classes and others derived from them.


> Are these "abstract" classes the same thing as VFP's "foundation classes"?

No. The Fox Foundation Classes are subclasses of the VFP base classes, but have been extended with additional properties and methods. Any subclasses of the FF classes will inherit these extensions. The closest library in the FFC to a set of abstract base classes is _BASE.VCX. Abstract classes are more like a blueprint or schematic. They serve as a template that all objects derived from the classes will have. Additional functionality in the form of properties and methods can be added to the abstract classes. Usually any properties added at this level are set to default values and methods are not implemented. Unlike languages like C++, which permit the definition of pure abstract or "virtual" classes, the base classes used in VFP come with a high level of functionality right from the start. Some, like the Empty class cannot be subclassed.


>I'm currently using a set of classes that are derived from VFP's foundation >classes. I leave the foundation classes alone (so that future updates can replace >them), and use my classes in objects.

I think you understand the concept of having a set of classes that form a base for application development. But I think you can see that the extensions in the FFC made them heavier than what you envisioned for the task. Unfortunately, the FFC don't start with just a simple subclass of the VFP base classes.

Hope this helps,

John
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform