295 |
* @return the Bean as a new view, or if the operation |
* @return the Bean as a new view, or if the operation |
296 |
* could not be performed, the Bean itself. |
* could not be performed, the Bean itself. |
297 |
*/ |
*/ |
298 |
public static Object getInstanceOf(Object bean, Class newClass) |
public static Object getInstanceOf(Object bean, Class<?> newClass) |
299 |
{ |
{ |
300 |
return bean; |
return bean; |
301 |
} |
} |
314 |
* @return whether the Bean can be cast to the class type |
* @return whether the Bean can be cast to the class type |
315 |
* in question. |
* in question. |
316 |
*/ |
*/ |
317 |
public static boolean isInstanceOf(Object bean, Class newBeanClass) |
public static boolean isInstanceOf(Object bean, Class<?> newBeanClass) |
318 |
{ |
{ |
319 |
return newBeanClass.isInstance(bean); |
return newBeanClass.isInstance(bean); |
320 |
} |
} |