Skip to content

electron updater.Class.Provider

Electron-Builder / electron-updater / Provider

Type Parameters

T extends UpdateInfo

Constructors

new Provider()

protected new Provider<T>(runtimeOptions): Provider<T>

Parameters

runtimeOptions: ProviderRuntimeOptions

Returns

Provider<T>

Properties

executor

protected readonly executor: ElectronHttpExecutor

Accessors

fileExtraDownloadHeaders

get fileExtraDownloadHeaders(): null | OutgoingHttpHeaders

Returns

null | OutgoingHttpHeaders


isUseMultipleRangeRequest

get isUseMultipleRangeRequest(): boolean

Returns

boolean

Methods

createRequestOptions()

protected createRequestOptions(url, headers?): RequestOptions

Parameters

url: URL

headers?: null | OutgoingHttpHeaders

Returns

RequestOptions


getCustomChannelName()

protected getCustomChannelName(channel): string

Parameters

channel: string

Returns

string


getDefaultChannelName()

protected getDefaultChannelName(): string

Returns

string


getLatestVersion()

abstract getLatestVersion(): Promise<T>

Returns

Promise<T>


httpRequest()

protected httpRequest(url, headers?, cancellationToken?): Promise<null | string>

Method to perform API request only to resolve update info, but not to download update.

Parameters

url: URL

headers?: null | OutgoingHttpHeaders

cancellationToken?: CancellationToken

Returns

Promise<null | string>


resolveFiles()

abstract resolveFiles(updateInfo): ResolvedUpdateFileInfo[]

Parameters

updateInfo: T

Returns

ResolvedUpdateFileInfo[]


setRequestHeaders()

setRequestHeaders(value): void

Parameters

value: null | OutgoingHttpHeaders

Returns

void