ArgumentValidationAttribute.ValidatePostConversion Method

Validates the argument value after it was converted to the argument's type, and throws an exception if validation failed.

Definition

Namespace: Ookii.CommandLine.Validation
Assembly: Ookii.CommandLine (in Ookii.CommandLine.dll) Version: 5.0.0+724ca9b7fa5edc075ec2ae65044e61b0d494fd1c
C#
public void ValidatePostConversion(
	CommandLineArgument argument,
	Object? value
)

Parameters

argument  CommandLineArgument
The argument being validated.
value  Object
The argument value. If not null, this must bean instance of CommandLineArgument.ElementType.

Remarks

This method calls the IsValidPostConversion(CommandLineArgument, Object) method to do the actual validation.

Exceptions

CommandLineArgumentException The value parameter is not a valid value. The CommandLineArgumentException.Category property will be the value of the ErrorCategory property.

See Also