Class PieceVisitorDispatcher
java.lang.Object
VASSAL.counters.PieceVisitorDispatcher
- Direct Known Subclasses:
DeckVisitorDispatcher
For implementing a modified Visitor pattern on
GamePiece
s.
Rather than defining accept() methods in the GamePiece subclasses,
this class performs the dispatching of visitors. This allows for easier
implementation of custom GamePiece subclasses outside the core engine.
A class that wishes to recognize custom GamePiece classes and treat
them specially should do so by implementing a sub-interface of
PieceVisitor and using a subclass of PieceVisitorDispatcher
that recognizes the custom type.- See Also:
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
PieceVisitorDispatcher
-
-
Method Details
-
accept
-