Ompluscator's Blog
  • Home
  • All Articles
  • Golang
  • Tools

solid

September 18, 2023

Practical SOLID in Golang: Dependency Inversion Principle

We continue our journey through the SOLID principles by presenting the one that has the most significant impact on unit testing in Go: The Dependency Inversion Principle.

Learning a new programming language is often a straightforward process. I often hear: “The first programming language you learn in a year. The second one in a month. The third one in a week, and then each next one in a day.” Saying that is an exaggeration, but it is not too distant from the truth in some cases. For example, jumping to a language relatively similar to the previous one, like Java and C#, can be a straightforward process.
September 18, 2023

Practical SOLID in Golang: Interface Segregation Principle

We continue our journey through the SOLID principles by discussing the one that has a profound impact on code design: The Interface Segregation Principle.

When beginners embark on their programming journey, the initial focus is typically on algorithms and adapting to a new way of thinking. After some time, they delve into Object-Oriented Programming (OOP). If this transition is delayed, it can be challenging to shift from a functional programming mindset. However, eventually, they embrace the use of objects and incorporate them into their code where necessary, sometimes even where they’re not needed. As they learn about abstractions and strive to make their code more reusable, they may overgeneralize, resulting in abstractions applied everywhere, which can hinder future development.
September 18, 2023

Practical SOLID in Golang: Liskov Substitution Principle

We continue our journey through the SOLID principles by presenting the one with the most complex definition: The Liskov Substitution Principle.

I’m not really a fan of reading. Often, when I do read, I find myself losing track of the text’s topic for the past few minutes. Many times, I’ll go through an entire chapter without really grasping what it was all about in the end. It can be frustrating when I’m trying to focus on the content, but I keep realizing I need to backtrack. That’s when I turn to various types of media to learn about a topic.
🍺 Support my Blogging work

Join the Ompluscator's Blog Community

Hey there! Want to be part of our awesome community? Just drop your email below, and we'll send you the good stuff – cool articles, fun updates, and more. No spam, we promise!

Thank you for subscribing!

September 18, 2023

Practical SOLID in Golang: Open/Closed Principle

We continue our journey through the SOLID principles by presenting the one that enhances the flexibility of applications: The Open/Closed Principle.

Many different approaches and principles can lead to long-term improvements in our code. Some of them are well-known in the software development community, while others remain somewhat under the radar. In my opinion, this is the case with The Open/Closed Principle, represented by the letter O in the word SOLID. In my experience, only those genuinely interested in SOLID principles tend to understand what this principle means. We may have applied this principle without even realizing it in some instances, such as when working with the Strategy pattern.
September 18, 2023

Practical SOLID in Golang: Single Responsibility Principle

We start a journey through the essential principles in software development by presenting the most well-known one: The Single Responsibility Principle.

There aren’t too many opportunities for a breakthrough in software development. They usually arise from either rewiring our logic after initial misunderstandings or filling in gaps in our knowledge. I appreciate that feeling of deeper understanding. It can happen during a coding session, while reading a book or an online article, or even while sitting on a bus. An internal voice follows, saying, “Ah, yes, that’s how it works.” Suddenly, all past mistakes seem to have a logical reason, and future requirements take shape.
© Ompluscator's Blog 2024
  • Cookie Policy
  • Privacy Policy
  • Terms and Conditions
  • Consent Preferences

${title}

${content}