Skip to content
Ider

沉淀我所学习,累积我所见闻,分享我所体验

Primary Navigation Menu
Menu
  • Home
  • About Ider
    • Who Ider?
    • Why Ider?
    • How Ider?
    • Where Ider?
    • What Ider?

Principle

2017-05-08
08 May
On May 8, 2017
In Article Collection(聚宝收藏), Reading Notes(阅而后知)

The Pragmatic Programmer

前阵子看完了《The Pragmatic Programmer: From Journeyman to Master》,虽然该书是1999年发行的,也没有新版本出来,但读了之后还是感觉受益良多。

先说说不够好的方面。程序开发方面的知识和技术变化非常快,书中知识点可能都没跟上时代的脚步,比如介绍版本控制(Source Control)时就没有提高当前最流行的Git。书中也没有讲到怎么利用社交媒体来提升自身的价值。书里的知识点有些缺乏足够的案列来介绍具体该如何操作,只有对于有相关经验的开发者才能体会到书里表述的信息。所以书里讲得虽然好,还是需要更多的实践去累计其经验。

当然好的方面远远多很多。书里的知识是经过了作者数十年的经验累积总结下来的,这么多年里也获得了众人的认可。书中涵盖的软件开发方面的内容非常的广泛,从如何开始开发,怎么开发,到之后如何协作维护,最后文档总结归纳都有介绍。很多书里的告诫都让我找到了现实中不合理的依据:比如“Don’t Live with Broken Windows”让我明白为什么大家不喜欢写单元测试,就是因为我们项目本身没有多少单元测试, 而我也应该去“Fix the Problem, Not the Blame”,并且要“Be a Catalyst for Change”来测试组里的人去参与到自动化测试中。书中很多知识都可以在现在继续实践,比如书中“Domain Language”一节里就介绍了Backus–Naur form(BNF),让我意识到用很多时候对于问题需求和结论的描述,其实可以用这种结构化的语言来描绘会清晰很多。回想其实SQL语言查询语句的规格,还有Java语言的规格就是用这类语言来表述的,可惜之前并不知道它们也是值得学习的一部分。

我无法将整本书向大家完全阐述清楚,还是需要自己去阅读,并结合实际环境和能力来实践。

书中穿插了很多简短的建议,总结在本文以供参阅:
Read More →

2016-12-31
31 December
On December 31, 2016
In Design Patterns(设计模式), Reading Notes(阅而后知), Software Engineering(软件工程)

面向对象开发原则:S.O.L.I.D.

solid-oop_wall-skills

一开始学编程的时候,都是在学习程序语言,觉得学好了这门语言就可以写好程序;渐渐地发现算法和数据结构更加的重要,因为语言只是细胞,要依附这些行程肉体才能产生作用;但到了实际生产应用的时候,又会察觉整个好像缺少灵魂,常常只能像僵尸般往一个方向前进,缺少驱动力来动态调整,这力量就来自各种设计模式和开发原则。

经历了越多开发中的痛楚,也越来越发觉“S.O.L.I.D.”开发原则只用几句话所概括出来的真谛和内涵。它们对于软件开发是如此有意义,当然具体的实现依然还是依赖于那些基于需求形成的数据结构和算法,只是利用这些开发原则作为灵魂,让程序走得更远更自由。

 

Single Responsibility Principle(SRP)

A class should have one, and only one, reason to change.

Open Closed Principle(OCP)

You should be able to extend a classes behavior, without modifying it.

Liskov Substitution Principle(LSP)

Derived classes must be substitutable for their base classes.

Interface Segregation Principle(ISP)

Make fine grained interfaces that are client specific.

Dependency Inversion Principle(DIP)

Depend on abstractions, not on concretions.

 

References:
  1. ArticleS.UncleBob.PrinciplesOfOod
  2. SOLID (object-oriented design) – Wikipedia
  3. S is for the Single Responsibility Principle
  4. O is for the Open/Closed Principle
  5. L is for the Liskov Substitution Principle
  6. I is for the Interface Segregation Principle
  7. D is for the Dependency Inversion Principle

(后5个是基于Android开发对这些原则做的阐述)

2016-05-25
25 May
On May 25, 2016
In Article Collection(聚宝收藏), English Posts(英文写作), Reading Notes(阅而后知)

Universal Principles of Design

universal-principles-of-design

As a front-end engineer, or specifically, an Android UI Engineer, I have a lot of time to work with designers. But there are a lot of concepts in design I am not familiar with. So I asked them how I can learn design, but not being a designer. Then they recommended this book to me.

I read it, and feel it’s really helpful and useful. It’s not only about UI design, many principles can apply to other designs as well: software design, landscape design, product design, option design. After read this book, I learned the explanation on how certain design decisions are made.

I would definitely forgot most principles, so I wrote this post to transcribe all principles and short description from the book, later I can just come here to recall them.
Read More →

Facebook
Twitter
LinkedIn
RSS
ZhiHu

Recent Posts

  • 三年居家工作感受
  • Pixel Watch智能手表和Pixel 5, 6 Pro 及 7 Pro手机
  • 我拥有过的无线耳机
  • 毕业工作一个月,我差点被开除
  • 我拥有过的移动硬盘
  • ProtoBuf 2.0 method count optimization for android development
  • 面过100场行为面试后

Categories

  • Algorithm Analysis(算法分析)
  • Article Collection(聚宝收藏)
  • Data Structures(数据结构)
  • Design Patterns(设计模式)
  • English Posts(英文写作)
  • Front Interface(界面构想)
  • IT Products(数码产品)
  • Knowledge Base(心得笔库)
  • Language Tips(语言初试)
  • Mathematical Theory(数学理论)
  • Mobile Development(移动开发)
  • Programming Life(程序人生)
  • Reading Notes(阅而后知)
  • Software Engineering(软件工程)
  • Special Tricks(奇技妙招)
  • Tangential Speech(漫话杂谈)

Tags

Aero Android API Bash Binary Search Bitwise Operation Book C/C++ Career Chrome Conference CSS Debug Device DOM Extension Framework Game Gradle Hearthstone HTML Initialization Intellij Interview iOS Java JavaScript jQuery Keyword Language Issues Mac Microsoft Mobile Modifier Objective-C PHP Principle Reference Regular Expression Static String Tools Tutorial UI XML

Blogroll

  • Ahmed's Blog
  • Gert Lombard's Blog
  • Gordon Luk
  • Jack & Allison
  • 开发部落

Archives

Designed using Chromatic. Powered by WordPress.