ILauncher Interface
Definition
Starts the default app associated with the specified file or URI.
public interface ILauncher
Methods
| Name | Description |
|---|---|
| LaunchFileAsync | Starts the default app associated with the specified storage file or folder. |
| LaunchUriAsync | Starts the default app associated with the URI scheme name for the specified URI. |
LaunchFileAsync Method
Starts the default app associated with the specified storage file or folder.
public System.Threading.Tasks.Task<bool> LaunchFileAsync(Avalonia.Platform.Storage.IStorageItem storageItem)
Parameters
storageItem Avalonia.Platform.Storage.IStorageItem
The file or folder.
Returns
System.Threading.Tasks.Task<bool>
True, if launch operation was successful. False, if unsupported or failed.
LaunchUriAsync Method
Starts the default app associated with the URI scheme name for the specified URI.
public System.Threading.Tasks.Task<bool> LaunchUriAsync(Uri uri)
Parameters
uri Uri
The URI.
Returns
System.Threading.Tasks.Task<bool>
True, if launch operation was successful. False, if unsupported or failed.