Table of Contents

Class FilePathNotExistsAttributeBase

Namespace
McMaster.Extensions.CommandLineUtils.Validation
Assembly
McMaster.Extensions.CommandLineUtils.dll

Base type for attributes that check for files or directories not existing.

[AttributeUsage(AttributeTargets.Property)]
public abstract class FilePathNotExistsAttributeBase : ValidationAttribute
Inheritance
object
Attribute
ValidationAttribute
FilePathNotExistsAttributeBase
Derived

Methods

IsValid(object?, ValidationContext)

Validates the specified value with respect to the current validation attribute.

protected override ValidationResult? IsValid(object? value, ValidationContext validationContext)

Parameters

value object

The value to validate.

validationContext ValidationContext

The context information about the validation operation.

Returns

ValidationResult

An instance of the ValidationResult class.

Exceptions

InvalidOperationException

The current attribute is malformed.

NotImplementedException

IsValid(object, ValidationContext) has not been implemented by a derived class.