Top "Design-principles" questions

Design principles are ideas that guide developers toward certain goals in software design.

What is an example of the Liskov Substitution Principle?

I have heard that the Liskov Substitution Principle (LSP) is a fundamental principle of object oriented design. What is it …

oop definition solid-principles design-principles liskov-substitution-principle
Why Choose Struct Over Class?

Playing around with Swift, coming from a Java background, why would you want to choose a Struct instead of a …

swift class struct design-principles
Pipeline design pattern implementation

This is a design question regarding the implementation of a Pipeline. The following is my naive implementation. Interface for individual …

java oop design-patterns design-principles
What is an example of the Single Responsibility Principle?

Can someone give me an example of the Single Responsibility Principle? I am trying to understand what it means, in …

oop definition solid-principles single-responsibility-principle design-principles
Design Patterns for Multithreading

Multitasking seems to be a disaster at times when big projects crashes due to shared mutation of I would say …

multithreading design-patterns multitasking design-principles
DRY principle in java

I have been reading DRY principle.Though it seems so easy but I am having difficulty in understanding how we …

java design-principles
Should I favour IEnumerable<T> or Arrays?

In many projects I work on, whenever I have to return a read only collection, I use the IEnumerable<…

c# .net vb.net design-principles
Calling the variable property directly vs getter/setters - OOP Design

I know this is probably subjective but I read this optimization page from Google for PHP and they suggest use …

php optimization variables getter-setter design-principles
Rules Engines User Interface Design

At work, we have optimization engines, and one of the inputs used by these engines are business rules, which we …

user-interface design-principles rule-engine
What's the difference between design patterns and design principles?

I'm new to Ruby on Rails, and I went through these articles. Design Patterns in Ruby: Observer, Singleton Design Patterns …

ruby-on-rails ruby design-patterns design-principles