ModelDownloadConditions

class ModelDownloadConditions : NSObject, NSCopying

Configurations for downloading conditions.

  • Indicates whether WiFi is required for downloading. The default is NO.

    Declaration

    Swift

    var isWiFiRequired: Bool { get }
  • Indicates whether the model can be downloaded while the app is in the background. The default is NO.

    Declaration

    Swift

    var canDownloadInBackground: Bool { get }
  • Creates an instance of ModelDownloadConditions with the given configuration.

    Declaration

    Swift

    init(isWiFiRequired: Bool, canDownloadInBackground: Bool)

    Parameters

    isWiFiRequired

    Whether a device has to be connected to WiFi for downloading to start.

    canDownloadInBackground

    Whether the model can be downloaded while the app is in the background.

    Return Value

    A new instance of ModelDownloadConditions.

  • Unavailable.