Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Baseclasses not te be subclassed
Message
General information
Forum:
Visual FoxPro
Category:
Object Oriented Programming
Miscellaneous
Thread ID:
00149269
Message ID:
00149950
Views:
19
Pete,

>hope you don't mind me advertising your classes, the Pagerefresher class sprung to mind immediately I read the problem, BTW I've used it in many apps since downloading it some months ago,

I don't mind at all, I put the class on the net so that it can be widely shared among developers. I frankly hadn't thought in the terms of using it as a decorator pattern like this until you brought it up.

>how much lighter is it than the custom class?,

Line is just a little more lightweight than Custom. I just did some benchmarking with a tree to parse an IDL file. Reading the Word8.IDL file it creates 6036 objects. Here's the memory consumption of various lightweight objects as reported by sys(1016) which isn't necessarily a reliable object memory measurement
BaseClass    Total Memory    per object KB
Custom       7012212         1.16 
Line         6911884         1.15 
Relation     6880916         1.14
Separator    7211040         1.19
So it's not really significant which of them you use as the BaseClass. 1.2k/object is still a healthy chunk of memory when you are talking about creating complex data structures in memory.

>ah well it's beer time again

You keep rubbing that in on Friday afternoons.. makes me wish the east coast was a little closer to GMT. *s*
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Previous
Reply
Map
View

Click here to load this message in the networking platform