Visitor Pattern Code Review
Define the Context Object
Code Review
- Visitor Pattern Code Review: Define the Pattern Interface and Handler Objects
- Visitor Pattern Code Review: Define the Element Interface and Handler Objects
- Visitor Pattern Code Review: Define the Context Object
- Visitor Pattern Code Review: Use the Visitor Pattern
Code Walkthrough
The Context class (object) is a simple class that stores that input data to be used by the Element base class (object).
class Context
{
public String Input { get; set; }
public Context(String c) { this.Input = c; } }
public Context(String c) { this.Input = c; } }
Printer Friendly Version
Add to Favourites
DotNet Kicks
Digg
del.icio.us
Live Favourites
ma.gnolia
reddit
Slashdot
Technorati
Yahoo!