Page 3 of 3

Posted: Fri Sep 28, 2007 1:03 am
by rsts
This really looks like some interesting stuff. I've been pretty busy with some other projects the past few days but I'm looking forward to being able to spend some time digesting it.

Many thanks for your efforts in putting it all together.

cheers

Posted: Sat Sep 29, 2007 12:16 pm
by Dräc
Thanks to all!
Don't hesitate to tell me possible enhancement for an easier reading of the tutorial (more explanations? Specific examples?...)

Posted: Wed Oct 03, 2007 10:25 pm
by Dräc
New update of the OOP set of instructions:

First, a simplification of the class declaration.
The implementation is the same as previous, but the Init_Mbers : EndInit_Mbers block became a private block of the OOP implementation. This private block is used by the new block New : EndNew to perform the instanciation and the initialisation in one way.
So a PureBasic class is at present:

Code: Select all

;Object class 
Class(<ClassName>) 
[Method1()]
[Method2()]
[Method3()]
...
Methods(<ClassName>) 
[<*Method1>]
[<*Method2>]
[<*Method3>]
...
Members(<ClassName>) 
[<Attribute1>]
[<Attribute2>]
...
EndClass(<ClassName>) 

;Object methods (implementation)
Method(<ClassName>, Method1) [,<variable1 [= DefaultValue]>,...])
...
[ProcedureReturn value]
EndMethod(<ClassName>, Method1) 

...(ditto for each method)

;Object constructor
New(<ClassName>)
...
EndNew

;Object destructor
Free(<ClassName>)
...
EndFree
Second, Three new commands:
DeclareMethod, DeclareNew and DeclareFree to be used as the Declare keyword respectively for Methods, Constructors and Destructors. They are not presented in the tutorial

Posted: Thu Oct 18, 2007 11:12 pm
by Dräc
Small update: the *this\Instance feacture is full operational

Use it to call methods within the methods!

See http://drac.site.chez-alice.fr/Tutorial ... ur_Alerte1

Posted: Fri Oct 19, 2007 11:59 am
by byo
I appreciate the effort you put into this. Image