2 ms·
Facade, well, that’s obvious from the name. It’s not just an OO pattern. Visitor is a hack. You need to traverse an opaque structure but you know the types o
by projektfu 6y ago
Facade, well, that’s obvious from the name. It’s not just an OO pattern.
Visitor is a hack. You need to traverse an opaque structure but you know the types of its nodes. A simple lambda in other languages, it’s needed in (older) C++ and Java because of the single dispatch method calls. Even so, it’s not common in languages that rely on runtime typing or algebraic data types.