pattern-visitor
CommunityAdd behaviors without modifying classes
Software Engineering#oop#software-architecture#behavioral-design#visitor-pattern#double-dispatch#object-operations
Authorjohnnystefan
Version1.0.0
Installs0
System Documentation
What problem does it solve?
The Visitor pattern decouples operations from a stable class hierarchy so you can add behaviors without touching each entity or sprinkling type checks.
Core Features & Use Cases
- Double Dispatch: Each element accepts a visitor which then runs the subtype-specific logic, keeping behavior centralized.
- Operation Expansion: New visitors encapsulate tasks like reporting, exporting, or analytics without changing existing domain classes.
- Use Case: When generating different formats of member reports for clubs, let the visitor visit each entity type and emit the correct output.
Quick Start
Use the visitor pattern to add a new operation across your entity types without modifying their classes.
Dependency Matrix
Required Modules
None requiredComponents
Standard package💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: pattern-visitor Download link: https://github.com/johnnystefan/test-saas-business/archive/main.zip#pattern-visitor Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.