cast int? to int code example
Example 1: java casting to int
//In java, you can cast to any primitive type by putting (primitiveType)
//before whatever you're casting to.
private static int myInt = (int)myDouble;
Example 2: string to int
int i=Integer.parseInt("200");