Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Does a PRG class execute faster than a VCX based class?
Message
De
17/08/2005 21:20:53
Mike Yearwood
Toronto, Ontario, Canada
 
 
À
16/08/2005 10:44:09
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 6 SP5
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01040117
Message ID:
01041829
Vues:
33
Hi Cetin

>>>Yes a namespace might not be same as a vcx but in .Net everything is an object and thus a namespace could easily be seen as a sort of classlib. Actually I don't bother myself with its definition much (and not sure I could describe it ever).
>>>Yes a class instantition and calling its functions would take more than calling a weekend function directly. OTOH weekstart, weekend and such functions are not good samples for class.
>>
>>Why not?
>
>Because I can't think of its properties that'd differ much. However think if that was a Calendar. Gregorian, Hijri etc calendars have different month names, lengths etc. If I would create something that would show a calendar I'd do that with a class and not a prg (I mean functions not prg based classes). ie:
>
>*class calendar
>MonthNames[...]
>DayNames[...]
>FirstDayOfWeek
>ShowCalendar()
>
>*class HijriCalenDar
>subclassed from calendar
>MonthNames[...]
>DayNames[...]
>FirstDayOfWeek=...
>
>*class GregorianCalenDar
>subclassed from calendar
>MonthNames[...]
>DayNames[...]
>FirstDayOfWeek=...
>
>Cetin

So you have a superclass calendar subclassed to different calendars. That is the same as having a superclass function and subclassed Weekday, weekstart methods called from a single common method or even encoded in a single common method.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform