Look at the
Generics part of the Java Tutorial. The last part where it says "unchecked warnings" will help you. Briefly, since Java5, Vector has been a generic class. Read the tutorial for more details.
And don't use Vector. Use ArrayList instead, and declare the type of the object as java.util.List.