Vote UpVote

The Visitor Pattern – Part 2

The Art of Delphi Programming – In Part 1 of this series we learned about the benefits of the Visitor Pattern and saw a basic approach according to the GoF description. As clean and elegant the visitor pattern might look in the first place, it nonetheless has its disadvantages. Say, we want to add a new shape TShapeTriangle. We have to do it inside the same unit the other shapes are declared. As the shapes reference the visitor and the visitor references the shapes we have to put all shape classes together with the visitor into the same unit. Although this might work in some smaller scenarios, it definitely doesn’t in ...
Favorite? Off-Topic? Uwe Raabe @ 2010-08-16 23:33


Visits: 541
Votes: 5
Favorites: 0
Off-Topic: 0

Visits by Source

User Actions

Users who voted for this posting

Mohammed Nasman
Uwe Raabe
Contact us to advertise on DelphiFeeds.com

Community Links

Torry Firebird News


Please login or register to use this functionality.
(click on this box to dismiss)