Zero Install .NET API 2.20.0
ZeroInstall.Commands.ICommandHandler Interface Reference

Callback methods to allow users to interact with CliCommands. More...

Inheritance diagram for ZeroInstall.Commands.ICommandHandler:
NanoByte::Common::Tasks::ITaskHandler ZeroInstall.Commands.CliCommandHandler

Public Member Functions

void DisableUI ()
 Disables any persistent UI elements that were created but still leaves them visible. More...
 
void CloseUI ()
 Closes any persistent UI elements that were created. More...
 
void ShowSelections (Selections selections, IFeedManager feedManager)
 Shows the Selections made by the solver to the user. Returns immediately. May be ignored by some implementations. More...
 
void CustomizeSelections (Func< Selections > solveCallback)
 Allows the user to customize the interface preferences and rerun the solver if desired. Returns once the user is finished. More...
 
void ShowIntegrateApp (IntegrationState state)
 Displays application integration options to the user. Returns once the user is finished. More...
 
void ManageStore (IImplementationStore implementationStore, IFeedCache feedCache)
 Displays a user interface for managing IImplementationStores. Returns once the user is finished. More...
 
- Public Member Functions inherited from NanoByte::Common::Tasks::ITaskHandler
void RunTask (ITask task)
 
bool Ask ([Localizable(true)] string question, bool? defaultAnswer=null,[Localizable(true)] string? alternateMessage=null)
 
void Output ([Localizable(true)] string title,[Localizable(true)] string message)
 
void Output ([Localizable(true)] string title, IEnumerable< T > data)
 
void Output ([Localizable(true)] string title, NamedCollection< T > data)
 
void Error (Exception exception)
 

Properties

bool IsGui [get]
 Indicates whether this handler is a GUI.
 
bool Background [getset]
 Hides the GUI and uses something like a tray icon instead. Has no effect when IsGui is false.
 
- Properties inherited from NanoByte::Common::Tasks::ITaskHandler
CancellationToken CancellationToken
 
ICredentialProvider? CredentialProvider
 
Verbosity Verbosity
 

Detailed Description

Callback methods to allow users to interact with CliCommands.

The methods may be called from a background thread. Implementations apply appropriate thread-synchronization to update UI elements.

Member Function Documentation

◆ CloseUI()

void ZeroInstall.Commands.ICommandHandler.CloseUI ( )

Closes any persistent UI elements that were created.

Implemented in ZeroInstall.Commands.CliCommandHandler.

◆ CustomizeSelections()

void ZeroInstall.Commands.ICommandHandler.CustomizeSelections ( Func< Selections solveCallback)

Allows the user to customize the interface preferences and rerun the solver if desired. Returns once the user is finished.

Parameters
solveCallbackCalled after interface preferences have been changed and the solver needs to be rerun.

Implemented in ZeroInstall.Commands.CliCommandHandler.

◆ DisableUI()

void ZeroInstall.Commands.ICommandHandler.DisableUI ( )

Disables any persistent UI elements that were created but still leaves them visible.

Implemented in ZeroInstall.Commands.CliCommandHandler.

◆ ManageStore()

void ZeroInstall.Commands.ICommandHandler.ManageStore ( IImplementationStore  implementationStore,
IFeedCache  feedCache 
)

Displays a user interface for managing IImplementationStores. Returns once the user is finished.

Parameters
implementationStoreThe IImplementationStore to manage.
feedCacheInformation about implementations found in the implementationStore are extracted from here.

Implemented in ZeroInstall.Commands.CliCommandHandler.

◆ ShowIntegrateApp()

void ZeroInstall.Commands.ICommandHandler.ShowIntegrateApp ( IntegrationState  state)

Displays application integration options to the user. Returns once the user is finished.

Parameters
stateA View-Model for modifying the current desktop integration state.
Exceptions
OperationCanceledExceptionThe user does not want any changes to be applied.

The caller is responsible for saving any changes.

Implemented in ZeroInstall.Commands.CliCommandHandler.

◆ ShowSelections()

void ZeroInstall.Commands.ICommandHandler.ShowSelections ( Selections  selections,
IFeedManager  feedManager 
)

Shows the Selections made by the solver to the user. Returns immediately. May be ignored by some implementations.

Parameters
selectionsThe Selections as provided by the solver.
feedManagerThe feed manager used to retrieve feeds for additional information about implementations.

Implemented in ZeroInstall.Commands.CliCommandHandler.


The documentation for this interface was generated from the following file: