It's Less Funny When It's Your Life

Posted

A couple of days ago, Steve Yegge posted a sort-of funny piece to his blog about Wikileaks leaking the source code of 5000 open source Java projects by making all modifiers ‘public’ and all classes and members non-‘final’. One mock-quote in it was:

If people could keep using the older, more convenient APIs I made for them, then why…would they use my newer, ridiculously complicated ones? It boggles the imagination.

In response, a friend of mine who works for a major bank said that he just had to explain to a new Java programmer why:

  1. In Java, you have to use java.util.Date and java.util.Calendar and java.sql.Date
  2. java.util.Date has a getYear() which needs you to add 1900 to the year (because that was reasonable to somebody)
  3. Months are 0 based, but days of the month are not.
  4. Calendar.get() uses YEAR, MONTH and DATE to get year month and day. Because you know, I always think of describing the date with dates. It's recursive. Or circular. It's something.
  5. Even with all three dates, you'll still end up getting nothing done, because you can't compare dates. So go just download this open source library instead.
  6. And finally, now you have opensource, so fill out this security deviation form for the bank.