Alternative: Delegates

If you expect to repeat the same sort of custom getters and setters, you might consider implementing a delegate instead. A delegate will allow you to encapsulate the common logic better.


Prev Table of Contents Next

This book is licensed under the Creative Commons Attribution-ShareAlike 4.0 International license.