Skip to content

www.rolfje.com

Author: rolfje

Installing Wubi 9.10

Posted on 2010-04-23 By rolfje 2 Comments on Installing Wubi 9.10

Why I HATE LinuxOk, fist of all: DO NOT DOWNLOAD WUBI 9.10 as it contains a serious GRUB2 problem which will give you some headaches if you’re new to Linux. Why I’m saying this? I just ran into this GRUB2 problem while installing the new Wubi 9.10. Here’s what I did:

  1. Downloaded Wubi 9.10 windows installer and ran it.
  2. Installer downloads stuff, and boots into Ubuntu installer
  3. After reboot, GRUB screen comes up with a loud beep and a prompt. Great.

Some googling finds a lot of Linux voodoo talking l33tspe4king nerds, but it did contain some info with which I managed to get things working:

Read More “Installing Wubi 9.10” »

Uncategorized

Anti-fog Helmet Visor Tip

Posted on 2010-04-19 By rolfje 12 Comments on Anti-fog Helmet Visor Tip

In some biker magazines you’ll see some cheap journalists write that the “dish washing soap anti-fog is an urban myth”, and that it will “blur your vision”, some may even say it’s downright dangerous. This blogpost is to show that if done right, dish washing soap is actually the absolute best anti-fog treatment money can buy. If you’ve tried this and still don’t like it, there are some easier alternatives at the bottom for your convenience.

Read More “Anti-fog Helmet Visor Tip” »

Uncategorized

Simple Strict Date Parsing

Posted on 2010-03-06 By rolfje No Comments on Simple Strict Date Parsing

In Java, the DateFormat.parse() method is a funny little critter. It helps you by trying to figure out what date you actually meant when you typed in “35/12/2O10” (note the letter “O” in 2O10). In this case, it will parse the date without errors or warnings, and returns the date “11/12/04” (November 12th, 0004). That’s because it thinks “35” is a month, and “2” is the year, ignoring everything after the letter “O”.

DateFormat tries to convert the “35th month” into 2 years and 11 months, and correct the date accordingly. df.setLenient(false) prevents this, but that still leaves the problem of the parsing stopping at the first wrong character without warning.

I needed a much stricter way of parsing dates, and yesterday I found an elegant solution to this problem. It’s so small I was able to tweet it in less than 140 characters, but I thought it deserved a decent blogpost so here it goes:

public Date parseDateString(String inputDateString) 
         throws ParseException {
  DateFormat df = DateFormat.getDateInstance(DateFormat.SHORT);
  Date parsedDate = df.parse(inputDateString);

  if (!inputDateString.equals(df.format(parsedDate))) {
    throw new ParseException("Invalid Date", 0);
  }
  return parsedDate;
}

The brilliance here is in the comparing of the formatted date with the original input. The method returns a normal ParseException so you can perfectly replace your original df.parse() calls with it, making them more strict.

Thanks to Bas for this elegant and simple solution.

Software

Ibatis Inline Parameter Maps

Posted on 2010-02-16 By rolfje 3 Comments on Ibatis Inline Parameter Maps

Today I (re)discovered a feature in the Ibatis data mapper framework which was clearly documented, but for some reason was not being used in our project. The feature is called “inline parameter maps” and combined with a wrapper bean it can clean up a lot of clutter in the code and in the SqlMaps. Please feel free to share this example with your fellow Ibatis Data Mapper 2 framework users.

Read More “Ibatis Inline Parameter Maps” »

Uncategorized

The rumors can stop now. iPad is here.

Posted on 2010-01-27 By rolfje No Comments on The rumors can stop now. iPad is here.

So the word is finally out, it’s going to be the iPad. I was kind of worried about this, and my worries are not completely taken away by the news currently oozing out of the Apple keynote. I see some problems with this device, although they are well hidden under Steve’s reality distortion field, the Apple secret sauce and the “gee why didn’t we think of that” features.

Read More “The rumors can stop now. iPad is here.” »

Uncategorized

The Car Buying Story

Posted on 2010-01-10 By rolfje No Comments on The Car Buying Story

Stephen needs a new car. Being dilligent and a car lover, he takes the time to write down all criteria for a great car. When he finishes the list, he notices that the only car matching all his criteria is a Ferrari. Well, he always loved a Ferrari so that makes sense. To make things more realistic he adds another criteria, called “price”, and starts looking for alternatives.

Read More “The Car Buying Story” »

Apple, Fun, Hardware

Zūmo Mount for Triumph Speed Triple

Posted on 2009-12-30 By rolfje 10 Comments on Zūmo Mount for Triumph Speed Triple

The RAM mount coming with the Garmin zūmo’s are fine, but I wanted something more elegant to go with my Triumph Speed Triple. This article contains a detailed description of building your own mount for the Garmin zūmo 660. I mounted the zūmo on my Speed Triple, but the mount is universal enough to be center-mounted on any bike which has riser-mounted handlebars.

No guarantees ofcourse, you’re on your own from here. Bring your tools and read on.

WARNING: When I tried to cut one of these rubbers in half, the bottom disk came loose. It was not as securely glued to the rubber as the top disk. When pulling the zūmo on the mount it does not come off, but if you want to be sure order the Garmin 550 mount rubbers (described in article below).

Read More “Zūmo Mount for Triumph Speed Triple” »

Hardware, Workshop

Kilometerheffing? GPS-data NEE!

Posted on 2009-12-24 By rolfje 2 Comments on Kilometerheffing? GPS-data NEE!

Ik weet niet welke lobbyist menner Eurlings heeft verteld dat dit een briljant plan is, maar ik weet donders goed waarom onze regering kilometerheffing wil invoeren. Weer een kraantje toegevoegd aan het vat dat “werkende Nederlander” heet, en als bonus nog wat privacy gevoelige GPS gegevens om in rond te neuzen ook. Mocht je de rest van deze post niet willen lezen, reageer dan wel even op de volgende sites, want Eurlings heeft gezegd dat kilometerheffing “bij gebrek aan draagvlak” (welk draagvlak?) niet doorgaat:

  • http://www.redonzeprivacy.nl/
  • http://www.kilometerheffingnoway.nl/
  • http://www.kilometerheffing-nee.nl/
  • http://petities.nl/petitie/kilometerheffing-is-verkeerd
  • http://www.kilometer-heffing.eu/
  • http://www.anwbledenpeiling.nl/ <– Eurlings gaat deze uitslag gebruiken! (als je de vragen gezien hebt zie je waarom :-/ )

Read More “Kilometerheffing? GPS-data NEE!” »

Uncategorized

Flow

Posted on 2009-12-22 By rolfje 3 Comments on Flow

Being “in the flow”. The nicest state of mind known to mankind. You act without thinking, and everyone of your actions is the perfect response to the situation. Riding a motorcycle on a beautiful road without a destination can easily get you into this state. With an empty mind, you see the next 2 corners, feel your bike as your brakes hit the disc, smell the forest, and hear the wind as you start accelerating out of the first corner while naturally placing the bike into position for the next.

Read More “Flow” »

Software

Sonar “Close Connection” warning workaround.

Posted on 2009-10-06 By rolfje 7 Comments on Sonar “Close Connection” warning workaround.

When you use Spring and Ibatis and SQLTemplates, you could have code in your project which looks somewhat like this:

Connection connection = DataSourceUtils.getConnection(getDataSource());
...<do connection stuff here>...
DataSourceUtils.releaseConnection(connection, getDataSource());

Sonar will report that you did not close the connection, while in fact, Spring did that for you. You can not just add a “connection.close()” to the code because the whole point of calling “releaseConnection()” is to have Spring handle all the smart stuff on committing, closing, and returning the connection to the pool if needed.

Read More “Sonar “Close Connection” warning workaround.” »

Software

Posts navigation

Previous 1 … 9 10 11 … 35 Next
         

Recent Comments

  • rolfje on Exit WordPress
  • rolfje on Methode Buijs uitgelegd
  • LinkedIn is at Peak Enshittifaction – Will Chatham's Blog on Linked-In not really Opt-in?
  • Hans j on 1N4148 diode as RF switch
  • Roaming Rhonda on DLNA on OSX, done right

Tags

Apple backup design DIY DRM eclipse environment Fun Garmin GForge gmail google hacking hamradio Hardware helicopter iphone ipod iTunes Java Keynote linux maven modelling music news opinion oracle osx photo photography programming repair review security Software Steve Jobs technology Time Machine Ubuntu usability Utilities vacation windows Workshop

Categories

  • Apple (105)
  • Divorce (1)
  • Electronics (3)
  • Fun (57)
  • Games (7)
  • Hardware (72)
  • Microsoft (18)
  • Racing (14)
  • Software (134)
  • Uncategorized (66)
  • Workshop (20)

Archives

Copyright © 2025 www.rolfje.com.

Powered by PressBook WordPress theme