官术网_书友最值得收藏!

SOLID Design Principles for Go

In 2002, Robert "Uncle Bob" Martin published the book Agile Software Development, Principles, Patterns, and Practices in which he defined the five principles of reusable programs, which he called SOLID principles. While it might seem strange to include these principles in a book about a programming language invented 10 years later, these principles are still relevant today.

In this chapter, we will briefly examine each of these principles, how they relate to dependency injection (DI) and what that means for Go. SOLID is an acronym for five popular object-oriented software design principles:

  • Single responsibility principle 
  • Open/closed principle 
  • Liskov substitution principle 
  • Interface segregation principle 
  • Dependency inversion principle 
主站蜘蛛池模板: 贵阳市| 吉林省| 嘉禾县| 霍山县| 田阳县| 揭阳市| 城市| 东乌珠穆沁旗| 华宁县| 横山县| 翁源县| 漳平市| 三门县| 山阴县| 行唐县| 商都县| 房山区| 海丰县| 湘乡市| 达日县| 亚东县| 垦利县| 新竹县| 韶关市| 大姚县| 上饶市| 陇川县| 赤峰市| 怀集县| 邢台县| 玉环县| 南阳市| 陇西县| 凌海市| 辽宁省| 江阴市| 富源县| 盘锦市| 松溪县| 临沭县| 遂宁市|