What is a primitive type and a wrapper object in Java? How does the compiler handle conversion between the two? When should you use a primitive type or a wrapper object? — Primitive Types Java defines eight primitive data types: byte, short, int, long, float, double, boolean and char. All other variables in java are object reference types. Primitive types in Java are called literals. A literal is the source code representation of a fixed value in memory. …