Quotes from Robert C. Martin
In general, it is harmful to depend on modules that contain more than you need. This is obviously true for source code dependencies that can force unnecessary recompilation and redeployment—but it is also true at a much higher, architectural level.
~ Robert C. Martin
BazillionQuotes.com
Architecture represents the significant design decisions that shape a system, where significant is measured by cost of change. —Grady Booch
~ Robert C. Martin
BazillionQuotes.com
The only way to prove that your software is easy to change is to make easy changes to it. And when you find that the changes aren't as easy as you thought, you refine the design so that the next change is easier. When do you make these easy changes? All the time! Every time you look at a module you make small, lightweight changes to it to improve its structure.
~ Robert C. Martin
BazillionQuotes.com
What attributes can we give our functions that will allow a casual reader to intuit the kind of program they live inside?
~ Robert C. Martin
BazillionQuotes.com
It is the volatile concrete elements of our system that we want to avoid depending on. Those are the modules that we are actively developing, and that are undergoing frequent change.
~ Robert C. Martin
BazillionQuotes.com
Architecture is the decisions that you wish you could get right early in a project, but that you are not necessarily more likely to get them right than any other. —Ralph Johnson
~ Robert C. Martin
BazillionQuotes.com
OO imposes discipline on indirect transfer of control.
~ Robert C. Martin
BazillionQuotes.com
Don't refer to volatile concrete classes. Refer to abstract interfaces instead. This rule applies in all languages, whether statically or dynamically typed. It also puts severe constraints on the creation of objects and generally enforces the use of Abstract Factories.
~ Robert C. Martin
BazillionQuotes.com
Don't derive from volatile concrete classes. This is a corollary to the previous rule, but it bears special mention. In statically typed languages, inheritance is the strongest, and most rigid, of all the source code relationships; consequently, it should be used with great care. In dynamically typed languages, inheritance is less of a problem, but it is still a dependency—and caution is always the wisest choice.
~ Robert C. Martin
BazillionQuotes.com
We do not want to expose the details of our data. Rather we want to express our data in abstract terms. This is not merely accomplished by using interfaces and/or getters and setters. Serious thought needs to be put into the best way to represent the data that an object contains. The worst option is to blithely add getters and setters.
~ Robert C. Martin
BazillionQuotes.com
The problem isn't the simplicity of the code but the implicity of the code (to coin a phrase): the degree to which the context is not explicit in the code itself.
~ Robert C. Martin
BazillionQuotes.com
A good architecture comes from understanding it more as a journey than as a destination, more as an ongoing process of enquiry than as a frozen artifact.
~ Robert C. Martin
BazillionQuotes.com
Don't override concrete functions. Concrete functions often require source code dependencies. When you override those functions, you do not eliminate those dependencies—indeed, you inherit them. To manage those dependencies, you should make the function abstract and create multiple implementations.
~ Robert C. Martin
BazillionQuotes.com
In general output arguments should be avoided. If your function must change the state of something, have it change the state of its owning object.
~ Robert C. Martin
BazillionQuotes.com
Architecture is a hypothesis, that needs to be proven by implementation and measurement. —Tom Gilb
~ Robert C. Martin
BazillionQuotes.com
Variables in functional languages do not vary.
~ Robert C. Martin
BazillionQuotes.com
Never mention the name of anything concrete and volatile. This is really just a restatement of the principle itself.
~ Robert C. Martin
BazillionQuotes.com
All race conditions, deadlock conditions, and concurrent update problems are due to mutable variables. You cannot have a race condition or a concurrent update problem if no variable is ever updated. You cannot have deadlocks without mutable locks.
~ Robert C. Martin
BazillionQuotes.com
This means that the UI and the database can be plugins to the business rules. It means that the source code of the business rules never mentions the UI or the database.
~ Robert C. Martin
BazillionQuotes.com
In Clojure, an atom is a special kind of variable whose value is allowed to mutate under very disciplined conditions that are enforced by the swap! function.
~ Robert C. Martin
BazillionQuotes.com
Woe to the poor developer who buckles under pressure and agrees to try to make the deadline. That developer will start taking shortcuts and working extra hours in the vain hope of working a miracle.
~ Robert C. Martin
BazillionQuotes.com
To comply with these rules, the creation of volatile concrete objects requires special handling. This caution is warranted because, in virtually all languages, the creation of an object requires a source code dependency on the concrete definition of that object. In most object-oriented languages, such as Java, we would use an Abstract Factory to manage this undesirable dependency.
~ Robert C. Martin
BazillionQuotes.com
The majority of the cost of a software project is in long-term maintenance.
~ Robert C. Martin
BazillionQuotes.com
Event sourcing is a strategy wherein we store the transactions, but not the state. When state is required, we simply apply all the transactions from the beginning of time.
~ Robert C. Martin
BazillionQuotes.com
