Einzelnen Beitrag anzeigen

Bjoerk

Registriert seit: 28. Feb 2011
Ort: Mannheim
1.384 Beiträge
 
Delphi 10.4 Sydney
 
#2

AW: Probleme Mit Parser für UPN

  Alt 2. Mär 2012, 20:46
Schmeiß mal die Lies raus und nenn deine Konstruktoren Create. Private Variablen beginnen per Konvention in Delphi mit einem F (wie Feld).

Delphi-Quellcode:
type
  TBinbaum = class
  private
    FInhalt: TObject;
    FLeft, FRight: TBinbaum;
  public
    property Inhalt: TObject Read FInhalt;
    ..
    constructor Create; overload;
    constructor Create(const Inhalt: TObject); overload;
  end;
Delphi-Quellcode:
constructor TBinbaum.Create;
begin
  inherited Create;
  FLeft:= Nil;
  FRight:= Nil;
  FInhalt:= Nil;
end;

constructor TBinbaum.Create (const Inhalt: TObject);
begin
  Create;
  FInhalt:= Inhalt;
end;
  Mit Zitat antworten Zitat