Yeah, an IllegalArgumentException seems appropriate.