1. If the object is generated by byte, short, int and char types, then directly assign the value without conversion.
2. If the object is generated by String type, first convert the object to String type, and then convert the string type to int type.
For example:
string myInt = " 123 ";
Object os = myInt
int b = integer . parse int((String)OS); //You can also use os.toString ().
3. If the object is generated by float, double and long long types, the idea is the same as above. First, the object is converted to the corresponding data type, and then to the int type.