Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Nesting Error
Message
From
22/04/2016 14:00:41
Mike Yearwood
Toronto, Ontario, Canada
 
 
To
22/04/2016 10:28:54
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows 7
Network:
Windows 2003 Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01634528
Message ID:
01635256
Views:
79
>Personal preference,
>
>My take: One class per classlib means it isn't a lib. It's a class. Why even have the classlib at this point? A class should have one purpose and one purpose only. This is called out in the Single Responsibility Principle (read about it at http://www.dotnetcurry.com/software-gardening/1148/solid-single-responsibility-principle) A classlib should hold *related* classes. For example, a classlib with stuff for a form should have nothing but stuff for a form. Nothing for reports.

I've rarely, if ever seen any kind of sensible "relation" between the classes in a lib. The relation is simply arbitrary. All reports for example. All base classes. There is no need for the lib, just like there is no need for a procedure library. All that is truly needed are the procedures/functions and classes. How they are stored at design time should not affect runtime.

>
>>I'm seemingly the biggest proponent of having only one class in a classlib. That is exactly the same as saying having only one screen in an scx. I just name the class and the classlib the same.
Previous
Reply
Map
View

Click here to load this message in the networking platform