Cast this bsh.Primitive value to a new bsh.Primitive value This is usually a numeric type cast. Other cases include: A boolean can be cast to boolen null can be cast to any object type and remains null Attempting to cast a void causes an exception @param toType is the java object or pr
( Class toType, int operation )
| 972 | @param toType is the java object or primitive TYPE class |
| 973 | */ |
| 974 | public Primitive castToType( Class toType, int operation ) |
| 975 | throws UtilEvalError |
| 976 | { |
| 977 | return castPrimitive( |
| 978 | toType, getType()/*fromType*/, this/*fromValue*/, |
| 979 | false/*checkOnly*/, operation ); |
| 980 | } |
| 981 | |
| 982 | /* |
| 983 | Cast or check a cast of a primitive type to another type. |
no test coverage detected