Table of Contents

Class OptionChecker

Namespace
OneImlx.Terminal.Commands.Checkers
Assembly
OneImlx.Terminal.dll

The default option checker.

public class OptionChecker : IOptionChecker
Inheritance
OptionChecker
Implements
Inherited Members

Remarks

The OptionChecker uses the ValidationAttribute to check an option value.

Constructors

OptionChecker(IDataTypeMapper<Option>, TerminalOptions)

Initialize a new instance.

public OptionChecker(IDataTypeMapper<Option> mapper, TerminalOptions options)

Parameters

mapper IDataTypeMapper<Option>

The option data-type mapper.

options TerminalOptions

The configuration options.

Methods

CheckOptionAsync(OptionCheckerContext)

Checks Option asynchronously.

public Task<OptionCheckerResult> CheckOptionAsync(OptionCheckerContext context)

Parameters

context OptionCheckerContext

The option check context.

Returns

Task<OptionCheckerResult>

The OptionCheckerResult instance.

StrictTypeCheckingAsync(OptionCheckerContext, DataTypeMapperResult)

Checks the option value compatibility.

protected Task<OptionCheckerResult> StrictTypeCheckingAsync(OptionCheckerContext context, DataTypeMapperResult mapperResult)

Parameters

context OptionCheckerContext
mapperResult DataTypeMapperResult

Returns

Task<OptionCheckerResult>