java-solidlisted
Install: claude install-skill limited-grisaille833/claude-java-plugins
Review the provided Java code for SOLID principles violations. For each principle, check for violations and suggest targeted improvements. Tailor suggestions to the detected Java version.
## S — Single Responsibility Principle
A class should have one reason to change.
**Violations to flag:**
- Classes named `*Manager`, `*Helper`, `*Utils` with more than 3 unrelated methods
- Service classes that also contain validation logic, email sending, AND database calls
- Classes with more than ~200 lines (often a signal of multiple responsibilities)
- Methods that do multiple distinct things (parse + validate + persist + notify)
**Fix pattern:** Extract each responsibility into its own class. Show the split.
## O — Open/Closed Principle
Open for extension, closed for modification.
**Violations to flag:**
- `if/else` or `switch` chains on type/status that would require modification to add new types
- Hard-coded behaviour that should be configurable
- Direct instantiation of concrete classes in business logic (use interfaces)
**Fix pattern:** Introduce Strategy, Template Method, or polymorphism. Show the refactoring.
## L — Liskov Substitution Principle
Subtypes must be substitutable for their base types.
**Violations to flag:**
- Subclass overrides a method by throwing `UnsupportedOperationException`
- Subclass weakens preconditions (accepts nulls when parent doesn't)
- Subclass strengthens postconditions (returns more restricted type)
- Square extends Rectangle anti-pattern
**