Google.IOSResolver.UpdateTargetSdk C# (CSharp) Method

UpdateTargetSdk() public static method

Update the target SDK if it's required.
public static UpdateTargetSdk ( ) : bool
return bool
    public static bool UpdateTargetSdk() {
        var minVersionAndPodNames = TargetSdkNeedsUpdate();
        if (minVersionAndPodNames.Value != null) {
            var minVersionString =
                TargetSdkVersionToString(minVersionAndPodNames.Key);
            var update = EditorUtility.DisplayDialog(
                "Unsupported Target SDK",
                "Target SDK selected in the iOS Player Settings (" +
                TargetSdk + ") is not supported by the Cocoapods " +
                "included in this project. " +
                "The build will very likely fail. The minimum supported " +
                "version is \"" + minVersionString + "\" " +
                "required by pods (" +
                String.Join(", ", minVersionAndPodNames.Value.ToArray()) +
                ").\n" +
                "Would you like to update the target SDK version?",
                "Yes", cancel: "No");
            if (update) {
                TargetSdkVersion = minVersionAndPodNames.Key;
                string errorString = (
                    "Target SDK has been updated from " + TargetSdk +
                    " to " + minVersionString + ".  You must restart the " +
                    "build for this change to take effect.");
                EditorUtility.DisplayDialog(
                    "Target SDK updated.", errorString, "OK");
                return true;
            }
        }
        return false;
    }

Same methods

IOSResolver::UpdateTargetSdk ( Pod pod, bool notifyUser = true ) : bool