Software Engineering in WordPress, PHP, and Backend Development

Author: Tom (Page 90 of 427)

Object-Oriented Programming: Understanding Interfaces

At this point, I’d say that the foundations of understanding object-oriented programming have been laid.

Specifically, I’ve covered:

  1. Abstraction
  2. Encapsulation
  3. Inheritance
  4. Polymorphism

And, yeah, there’s some debate as to what constitutes the foundations (that is, some don’t toss polymorphism into the mix though I do). But the above four should provide a solid foundation off of which to continue building your object-oriented programming skills.

There are more, but I don’t think they are as deep, detailed, or tough to understand as some of the aforementioned concepts. Then again, different things come easier to others.

Understanding Interfaces

At any rate, the next two topics that are important to understand are:

  1. Interfaces
  2. Abstraction

I’ll talk about each separate but make sure that you’ve read the Fundamentals series first because the above two topics will allow you to rely on them and take advantage of them.

Vague, I know, but let me explain and then go from there.

Continue reading

Starting 2018

For the first time in I can’t remember when I took ten days offline. Completely.

https://twitter.com/tommcfarlin/status/944345818034778112

To be clear, when I say “I took time offline,” I don’t mean that I took time offline regarding work. I mean that…

  • I deleted applications from my phone and my computer,
  • I signed out of accounts on my browser,
  • I took time off from work and all forms of social media,
  • I spent time focused on the things I wanted to focus on (versus had to focus on),
  • I spent my time with my family and on thinking through how the past year went and what I want to do in the coming year.

At this point, it’s normal to try to segue into a post about resolutions and but I’m not so much about resolutions as I am about goals.

And I’m not about prescribing goals for anyone but me, anyway. Though it’s common in our space to look back and reflect on the year and how things went, I don’t find posts outlining what we plan to do in the coming year.

That’s probably because it’s far easier to reflect than project (after all, we know less about what’s coming in the year at this point than we do at the end of the year, right?), I still like to spend some time trying to lay out a few goals.

Robert Burns wrote the famous quote:

The best-laid plans of mice and men often go awry.

But since we typically do posts about how the year went, why not write about what we want to do so that, 52 weeks or so from this post, we can look back on what was done, what wasn’t, the surprises, and the why behind it all.

Continue reading

Merry Christmas and Happy Holidays (From 2017 To 2018)

As with most in the United States (and elsewhere), I try to take some time off of work during the week from Christmas to New Years’. I’ve not always taken a break from social media, blogging, and all that stuff, but I think I’m going to give it a go this year.

Christmas 2017

That is, I’m planning to be off the grid as much as possible starting this evening.

To be clear, this isn’t prescriptive. This isn’t based on any dramatic anything. This isn’t even blogworthy, I suppose, but it’s worth having something here at the end of the year, right? 🙂

Further, I don’t do retrospective posts, but I thought it might be worth highlighting some of the stuff over the past year and perhaps what I’m looking to do in the coming year (not new years resolutions, per se, but just a few things I’d like to do).

Continue reading

Two Pillars of Object-Oriented Programming: Part 2 of 2

As I mentioned in the first post of this series, you’re often going to hear about The Three Pillars of Object-Oriented Programming. You may also hear about The Four Pillars of Object-Oriented Programming.

And it’s not that there’s a total of seven or anything like that. Instead, it’s more about what people consider to be foundational to OOP: Are there three or four major concepts?

You can surmise from the previous article (let alone the title), I believe there are four.

Two Pillars of Object-Oriented Programming: Inheritance and Polymorphism

And in this post, I’m going to cover the final two:

  • Inheritance,
  • and Polymorphism

If you’ve done any type of object-oriented programming prior to reading this article, you’ve likely heard of at least one of these.

Regardless, let’s take a look at each of them in more detail.

Continue reading

We’re Not Gonna Need It (Or Maybe We Will)

When it comes to writing software, two of the most popular schools of thought are:

  1. YAGNI (or “you aren’t gonna need it”),
  2. and Generalization (or maybe “premature generalization”).

They aren’t necessarily exact opposites, but for where I’m going with this, it’s worth treating them as such.

In my experience, projects boil down to projects for customers or products that you’re building to sell. This isn’t to say we don’t build products for customers, so maybe it’s just easier to say:

  • “Hey, I’m building this for someone else,”
  • or, “Yeah, I’m building this for me [for profit].”

Here’s the thing: I often find that when it comes to building things for other people, it’s easier to want to go about Generalization for their code and YAGNI for our code.

So which one is right? Or is there even a right one?

Continue reading

« Older posts Newer posts »

© 2025 Tom McFarlin

Theme by Anders NorenUp ↑