Skip to main content

Subscribe to GoRails to get access to this episode and all other pro episodes, and new awesome content every month.

Subscribe Now
Only $19/month

Unlimited access. Cancel anytime.

22 Liskov Substitution Principle

Episode 244 · May 15, 2018

Subclasses should add to a base classes behavior, not replace it

Design Patterns


Resources

Transcripts

No transcripts available. Earn a free month

Discussion


Gravatar
Awesome.

Keep up the SOLID principles work.

Gravatar
Great Episode !! Looking forward to the other episodes!!

Gravatar
A classic symptom of LSP violation is the Refused Bequest code smell, and the opening example (with the subclass raising an exception) is a nice example.

Hard to believe you said all that about birds and types and didn't mention ducks ;)


Login or create an account to join the conversation.