ah sneaky bit of java