throw new IllegalArgumentException
("Duration argument has extra characters after unit: " +
property);
}
try {
final TimeUnit unit = TimeUnit.valueOf(unitName);
millis = TimeUnit.MILLISECONDS.convert(time, unit);
} catch (IllegalArgumentException e) {
try {
final IEEETimeUnit unit = IEEETimeUnit.valueOf(unitName);
millis = unit.toMillis(time);
} catch (IllegalArgumentException e2) {
throw new IllegalArgumentException
("Duration argument has unknown unit name: " +
property);
}