fix generics warnings

add -Xlint to parent's pom.xml and fix generics warnings.