[Lazarus] How write a proper Type declaration with procedures?

Anthony Walter sysrpl at gmail.com
Wed Oct 28 08:28:05 CET 2015


type
  TURLTable = class(TStringlist)
  private
    FTable: LinkArray;
    function GetTable: LinkArray;
  public
     procedure Insert(const s: string);
     property Table: LinkArray read GetTable;
  end;

function TURLTable.GetTable: LinkArray;
begin
  Result := FTable;
end;

procedure TURLTable.Insert(const s: string);
begin
end;

... or alternately

  property Table: LinkArray read FTable;


... and remove function GetTable: LinkArray;
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20151028/03939785/attachment-0003.html>


More information about the Lazarus mailing list