60 lines
844 B
Plaintext
60 lines
844 B
Plaintext
Class MyPoint
|
|
|
|
BeginProtect
|
|
x.i
|
|
y.i
|
|
EndProtect
|
|
|
|
Public Method GetX()
|
|
MethodReturn This\X
|
|
EndMethod
|
|
|
|
Public Method GetY()
|
|
MethodReturn This\Y
|
|
EndMethod
|
|
|
|
Public Method SetX(n)
|
|
This\X=n
|
|
EndMethod
|
|
|
|
Public Method SetY(n)
|
|
This\Y=n
|
|
EndMethod
|
|
|
|
Public Method Print()
|
|
PrintN("Point")
|
|
EndMethod
|
|
|
|
Public Method Init(x=0,y=0)
|
|
This\x=x
|
|
This\y=y
|
|
EndMethod
|
|
EndClass
|
|
|
|
Class Circle Extends MyPoint
|
|
|
|
Protect Radie.i
|
|
|
|
Public Method Circel(x=0, y=0, r=0)
|
|
This\X = x
|
|
This\y = y
|
|
This\Radie=r
|
|
EndMethod
|
|
|
|
Public Method GetRadie()
|
|
MethodReturn This\Radie
|
|
EndMethod
|
|
|
|
Public Method SetRadie(n)
|
|
This\Radie = n
|
|
EndMethod
|
|
|
|
Public Method Print()
|
|
PrintN("Circle: "+ _
|
|
" X= "+Str(This\X)+ _
|
|
" Y= "+Str(This\Y)+ _
|
|
" R= "+Str(This\Radie))
|
|
EndMethod
|
|
|
|
EndClass
|