Undoing generics to fix java 6 compatibility