Table of Contents

Class AppAlias

Namespace
ZeroInstall.DesktopIntegration.Windows
Assembly
ZeroInstall.DesktopIntegration.dll

Contains control logic for applying AppAlias on Windows systems.

public static class AppAlias
Inheritance
AppAlias
Inherited Members

Fields

RegKeyAppPaths

The HKCU/HKLM registry key for storing application lookup paths.

public const string RegKeyAppPaths = "Software\\Microsoft\\Windows\\CurrentVersion\\App Paths"

Field Value

string

Methods

Create(FeedTarget, string?, string, IIconStore, bool)

Creates an application alias in the current system.

public static void Create(FeedTarget target, string? command, string aliasName, IIconStore iconStore, bool machineWide)

Parameters

target FeedTarget

The application being integrated.

command string

The command within target the alias shall point to; can be null.

aliasName string

The name of the alias to be created.

iconStore IIconStore

Stores icon files downloaded from the web as local files.

machineWide bool

Create the alias machine-wide instead of just for the current user.

Exceptions

OperationCanceledException

The user canceled the task.

IOException

A problem occurred while writing to the filesystem or registry.

WebException

A problem occurred while downloading additional data (such as icons).

UnauthorizedAccessException

Write access to the filesystem or registry is not permitted.

GetStubDir(bool)

Returns the path of the directory used to store alias stub EXEs.

public static string GetStubDir(bool machineWide)

Parameters

machineWide bool

true for a machine-wide directory; false for a directory just for the current user.

Returns

string

Remove(string, bool)

Removes an application alias from the current system.

public static void Remove(string aliasName, bool machineWide)

Parameters

aliasName string

The name of the alias to be removed.

machineWide bool

The alias was created machine-wide instead of just for the current user.

Exceptions

IOException

A problem occurred while writing to the filesystem or registry.

UnauthorizedAccessException

Write access to the filesystem or registry is not permitted.