Autor Beitrag
coder24h
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 48



BeitragVerfasst: Mo 29.05.06 12:00 
Was grundlegendes: Wie heißt der Zeiger innerhalb der Klasse auf mich selber? C: this
MrSaint
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 1033
Erhaltene Danke: 1

WinXP Pro SP2
Delphi 6 Prof.
BeitragVerfasst: Mo 29.05.06 12:07 
ausblenden Delphi-Quelltext
1:
Self					


:D

_________________
"people knew how to write small, efficient programs [...], a skill that has subsequently been lost"
Andrew S. Tanenbaum - Modern Operating Systems
mkinzler
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 4106
Erhaltene Danke: 13


Delphi 2010 Pro; Delphi.Prism 2011 pro
BeitragVerfasst: Mo 29.05.06 12:14 
Das kommt darauf an was coder24h will Self ist eine Referenz auf die Instanz und nicht auf die Klasse.

_________________
Markus Kinzler.
Narses
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Administrator
Beiträge: 10185
Erhaltene Danke: 1261

W11x64
TP3 .. D7pro .. D10.2CE
BeitragVerfasst: Mo 29.05.06 12:17 
Moin!

Hm... :gruebel:

Sind Klassen nicht abstrakt? Demzufolge kann es doch nur Zeiger auf Instanzen geben, oder? ;)

cu
Narses

_________________
There are 10 types of people - those who understand binary and those who don´t.
AXMD
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 4006
Erhaltene Danke: 7

Windows 10 64 bit
C# (Visual Studio 2019 Express)
BeitragVerfasst: Mo 29.05.06 12:17 
user profile iconmkinzler hat folgendes geschrieben:
Das kommt darauf an was coder24h will Self ist eine Referenz auf die Instanz und nicht auf die Klasse.


user profile iconcoder24h hat folgendes geschrieben:
C: this


Wenn er in C(++) this meint, dann entspricht das dem Self in Delphi - er wird vermutlich eine Instanz meinen.

AXMD
Christian S.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 20451
Erhaltene Danke: 2264

Win 10
C# (VS 2019)
BeitragVerfasst: Mo 29.05.06 13:09 
user profile iconmkinzler hat folgendes geschrieben:
Das kommt darauf an was coder24h will Self ist eine Referenz auf die Instanz und nicht auf die Klasse.
Um ein bisschen pingelig zu sein: in Klassenmethoden ist self die Referenz auf die Klasse und zwar der Klasse, in der sie aufgerufen wird (kann also auch eine abgeleitete Klasse sein).

_________________
Zwei Worte werden Dir im Leben viele Türen öffnen - "ziehen" und "drücken".