`
ABC: ABC Process procedures - some OOP information 1998-04-25 -- Russell B. Eggen From reggen@topspeed.com Sun Apr 26 02:36:59 1998 > I know I should dig into the templates and OOP before I ask this, >but I'm still trying to find the time :) May I ask: What does >Parent.TakeRecord do exactly? I noticed that in the template generated >code, that the value returned from that was assigned to the return >value. Kind of hard to explain if one is not familiar with the OOP style of programming (that is all OOP is anyway, a different style). When you use an embed point, you are automaticly extending the ABC classes. So the embed has all the functionality and data of what the embed is extending. This is known as derivation (as it is derived from the parent class). This is automatic in Clarion. You also get something else, inheritiance. This means that anything you put in the embed knows about the parent class. It knows what properties (data) it has and it knows what actions it can do (procedures and functions, aka methods). This is also automagically given to you. This has the nice benefit of using one chunk of code, but you can now apply that SAME chunk of code to different sets of data. For example, take a class of code that deals with a browse list. All browse lists do common things, such as scroll up & down, change colors & icons, load data, edit, etc. You are allowed to code it only once. But, it can act on any set of data. How many things can you browse? Customers, Parts, Accounts, Transactions, etc.. SAME piece of code! (and you cannot copy it either, it must be the original Printed December 4, 2024, 2:58 am This article has been viewed/printed 35445 times. Google search has resulted in 20 hits on this article since January 25, 2004. |