Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Private array vs array property?
Message
 
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01425197
Message ID:
01425198
Views:
65
>Hi,
>
>I need to use an array in a couple of methods of a class. I can declare it private and therefore the array will be in scope everywhere I need to. Or I can make this array to be a property of the class (custom class). Speed is not important to me (in this particular case). But I wonder what would VFP clean-up (destroy) better, a private array or array property?
>
>Thank you for any suggestions.

Dmitry,

It should be an array property of the class, if you need it as an array. Don't use private variables / arrays. Object properties is always a cleaner way when dealing with classes.
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform