Changed source compliance level to 1.5, and adapted code accordingly.