private Reference2ReferenceOpenHashMap<T, U> init(
            Iterable<? extends AbstractOptionValue<?, ?, ?>> additionalValues) {

        if (additionalValues instanceof AbstractOptions) {
            @SuppressWarnings("unchecked")
            final Reference2ReferenceOpenHashMap<T, U> clone =
                    ((AbstractOptions<T, U>) additionalValues).valueMap.clone();
            return clone;
        }

        final Reference2ReferenceOpenHashMap<T, U> map = new Reference2ReferenceOpenHashMap<>();
        for (final AbstractOptionValue<?, ?, ?> value : additionalValues) {
            @SuppressWarnings("unchecked")
            final U newValue = (U) value;
            map.put(newValue.option(), newValue);
        }
        return map;
    }
Creates a new instance.

@param baseOptions the base options to merge
@param additionalValues the option values
core/src/main/java/com/linecorp/armeria/common/util/AbstractOptions.java