Watch, Follow, &
Connect with Us

For forums, blogs and more please visit our
Developer Tools Community.

ID: 15117, Property overloading

by Ivan Magrini Email: Anonymous

Sometimes it would be very usefull if there is the possibility to overload properties.
Download Details
FTP  download also available 0 bytes
CDN Login Required to Download. (You will be redirected to the login page if you click on the Download Link)
To download this, you must have registered:
A free membership

For Delphi, Version 1.0  to 5.0 13 downloads
Copyright: No significant restrictions

Size: 0 bytes
Updated on Tue, 15 Aug 2000 00:00:00 GMT
Originally uploaded on Tue, 15 Aug 2000 05:11:57 GMT
Many times I wished ObjectPascal has the abillity to overload propertys, to simplify property access. See the following code:

TMyClass = CLASS(..)
Values[Index : INTEGER] : READ GetValueIndex WRITE SetValueIndex;
Values[Name : STRING] : READ GetValueName WRITE GetValueName;

// Now access the values

ServerIP := MyClass.Values[1];
MyClass.Values[''] = '';

I don't know if it's very usefull for other developers, but I think it would be a nice extension
to ObjectPascal

   Latest Comments  View All Add New

Move mouse over comment to see the full text

Could not retrieve comments. Please try again later.

Server Response from: ETNACDC03