Constructor
From REALbasicWiki
| This article is a stub. You can help the REALbasicWiki community by expanding it. |
A constructor is a method which is called right after an object has been created and allows initialization of the object before any method/event is called. There may be different constructors each taking different parameters.
When the REALbasic runtime is asked to create a new object, it will first get information about the object class and then allocate the memory needed to store such object. Once this has been done, the runtime calls the appropriate constructor, so programmer has a chance to initialize all the basic stuff before any event is called.
[edit] Defining a constructor
A constructor is defined as a method with the name Constructor. It can take any parameter but must not return any value.
