For various business reasons I want to hold some static IDs in one of my classes. They were originally int but I wanted to change them to Integer s
int
Integer
You must use a constant value in a switch statement.
switch(mObj.getId()){ case 5: //do something default: //do something default }