Git Product home page Git Product logo

design-patterns-in-ruby's Introduction

Design Patterns in Ruby

Summary of the design patterns explained in the book Design Patterns in Ruby, where Russ Olsen explains and adapts to Ruby 14 of the original 23 GoF design patterns.

Design Patterns

GoF Patterns

  • Adapter: helps two incompatible interfaces to work together
  • Builder: create complex objects that are hard to configure
  • Command: performs some specific task without having any information about the receiver of the request
  • Composite: builds a hierarchy of tree objects and interacts with all them the same way
  • Decorator: vary the responsibilities of an object adding some features
  • Factory: create objects without having to specify the exact class of the object that will be created
  • Interpreter: provides a specialized language to solve a well defined problem of know domain
  • Iterator: provides a way to access a collection of sub-objects without exposing the underlaying representation
  • Observer: helps building a highly integrated system, maintainable and avoids coupling between classes
  • Proxy: allows us having more control over how and when we access to a certain object
  • Singleton: have a single instance of certain class across the application
  • Strategy: varies part of an algorithm at runtime
  • Template Method: redefines certain steps of an algorithm without changing the algorithm's structure

Non-GoF Patterns: Patterns For Ruby

Contributing

Contributions are welcome! What could you do?:

  • Find typos and grammar mistakes
  • Propose a better way to explain a pattern
  • Add clearer examples of a pattern usage
  • Add other GoF patterns that are not covered in the book

Code examples refactoring PR's will not be considered. The examples provided by Russ Olsen in his book are meant to be simple and self explanatory, not the best performing or most elegant, their purpose is just educational.

design-patterns-in-ruby's People

Contributors

benkoshy avatar davidgf avatar desnor avatar elissonmichael avatar ilkhamgaysin avatar jay-pandya-btc avatar jaypandya73 avatar kevin-clark-90 avatar neodelf avatar rob-mcgrail avatar

Watchers

 avatar

Forkers

timimasa

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.