Show / Hide Table of Contents

Class FallbackSolver

Wraps two solvers always passing requests to the primary one initially and falling back to secondary one should the primary one fail.

Inheritance
Object
FallbackSolver
Implements
ISolver
Namespace: ZeroInstall.Services.Solvers
Assembly: ZeroInstall.Services.dll
Syntax
public sealed class FallbackSolver : Object, ISolver
Remarks

This class is immutable and thread-safe.

Constructors

FallbackSolver(ISolver, ISolver)

Declaration
public FallbackSolver(ISolver primarySolver, ISolver secondarySolver)
Parameters
Type Name Description
ISolver primarySolver
ISolver secondarySolver

Methods

Solve(Requirements)

Provides Selections that satisfy a set of Requirements.

Declaration
public Selections Solve(Requirements requirements)
Parameters
Type Name Description
Requirements requirements

The requirements to satisfy.

Returns
Type Description
Selections

The selected ImplementationSelections.

Remarks

Feed files may be downloaded, signature validation is performed, implementations are not downloaded.

Exceptions
Type Condition
OperationCanceledException

The user canceled the task.

ArgumentException

requirements is incomplete.

IOException

A problem occurred while reading the feed file.

WebException

A problem occurred while fetching the feed file.

UnauthorizedAccessException

Access to the cache is not permitted.

SignatureException

The signature data of a remote feed file could not be verified.

SolverException

The solver was unable to provide Selections that fulfill the requirements.

Implements

ISolver
In This Article
Back to top Copyright Bastian Eicher et al