The Unit.asType(Class) method is designed to throw ClassCastException if the
unit can not be casted to a unit of the given quantity class. However the
Javadoc additionally said "throws UnsupportedOperationException if the given
type is not recognized". If the type is not recognized, the method can
obviously not cast to that type, so the ClassCastException should be
sufficient. Consequently I suggest to remove that sentence from Javadoc.
Original issue reported on code.google.com by martdesr...@gmail.com on 8 Jan 2013 at 2:41
Original issue reported on code.google.com by
martdesr...@gmail.com
on 8 Jan 2013 at 2:41