*/
private void setSecondDefiningParameter(SecondDefiningParameter second) throws ConversionException {
while (second.secondDefiningParameter != null) {
second = second.secondDefiningParameter;
}
final Measure measure = second.measure;
if (measure != null) {
final boolean isIvfDefinitive = second.isIvfDefinitive();
if ((isIvfDefinitive ? inverseFlattening : semiMinorAxis) != 0) {
warnDuplicated("secondDefiningParameter");
} else {
ivfDefinitive = isIvfDefinitive;
double value = measure.value;
if (isIvfDefinitive) {
if (value == 0) {
value = Double.POSITIVE_INFINITY;
}
ensureStrictlyPositive("inverseFlattening", inverseFlattening = value);
} else if (semiMinorAxis == 0) {
ensureStrictlyPositive("semiMinorAxis", semiMinorAxis = value);
harmonizeAxisUnits(measure.getUnit(Length.class));
}
if (semiMajorAxis != 0) {
afterUnmarshal();
}
}