... to the digital home of Steven Schwenke.

This site is supposed to be a showcase for my thoughts about software engineering, less a personal homepage. If you want to know more about me, invite me to a beer.

Also, have a look at my book "Developer on the Stage".


Posted by Steven

One topic of discussion I encountered in every project so far is the “right” usage of Springs Dependency Injection (DI). In this article, I want to describe how this controversial feature is used in my current project.

Posted by Steven

The other day I had a discussion with a coworker about comments. Often he annotates the parts of the code that he writes with his name / SVN name like this:

  1. // EXBLUB1

The reasons for this are:

Posted by Steven

Recently, a colleague asked me, if I still enjoy being in the new team. I immediately answered that with an honest “yes”, although we both agree that our project is far away from the cutting edge of new technology. My coworker said that it is understandable that young developers rather want to play with new frameworks and new languages instead of building a Swing application like we do. Additionally, our project also is not a green field. It has been around for years.

Posted by Steven

„TODOs are jobs that the programmer thinks should be done, but for some reason can’t do at the moment. It might be a reminder to delete a deprecated feature or a plea for someone else to look at a problem. It might be a request for someone else to think of a better name or a reminder to make a change that is dependent on a planned event. Whatever else a TODO might be, it is not an excuse to leave bad code in the system.”  - Robert C. Martin, “Clean Code – A Handbook of Agile Software Craftsmanship”.

Posted by Steven

A couple of days ago, I finished reading „Rework“ by Jason Fried and David Heinemeier Hansson. The book is about their enterprise 37 signals and mainly addresses founders. One chapter is about the motivation of work. Fried and Hansson state that “to do great work, you need to feel that you’re making a difference”. The own work should be part of something important and by doing it, one puts a meaningful dent in the universe. If one would stop that work, someone would notice. The own work has to matter.

Extending Java Enums

21 Oct 2012
Posted by Steven

I often stumble over ideas that are cool in some way and that I would never have thought about it. One of those ideas is extending Java Enums. Often frameworks and toolkits bring some kind of enumeration with them. For most of the tasks at hand, the elements in those Enums are sufficient. For the other cases, they can be extended to include more status. Of cause the library cannot handle the added elements in the Enum, so the methods working with it may have to be overridden. In this article I want to show how Java Enums can be extended.

First, let's have a look at the Enum: