2018-12-31 14:00:47 +03:00
|
|
|
|
type
|
|
|
|
|
|
TExample = class
|
2019-09-08 19:56:17 +03:00
|
|
|
|
private
|
2018-12-31 14:00:47 +03:00
|
|
|
|
fX: integer;
|
|
|
|
|
|
|
2019-09-08 19:56:17 +03:00
|
|
|
|
public
|
2018-12-31 14:00:47 +03:00
|
|
|
|
property X: integer
|
|
|
|
|
|
read fX
|
|
|
|
|
|
write
|
|
|
|
|
|
begin
|
|
|
|
|
|
if value < 0 then
|
|
|
|
|
|
raise new System.ArgumentException();
|
|
|
|
|
|
fX := value;
|
|
|
|
|
|
end;
|
|
|
|
|
|
property Y: integer read fX write begin writeln(2); end;
|
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
|
|
begin
|
|
|
|
|
|
end.
|