Skip to content

M_CodeJam_CodeExceptions_UnexpectedArgumentValue__1_1

Andrew Koryavchenko edited this page Jun 17, 2018 · 6 revisions

CodeExceptions.UnexpectedArgumentValue(T) Method (String, T, String, Object[])

Creates ArgumentOutOfRangeException. Used to be thrown from default: switch clause

Namespace: CodeJam
Assembly: CodeJam (in CodeJam.dll) Version: 2.1.0.0

Syntax

C#

public static ArgumentOutOfRangeException UnexpectedArgumentValue<T>(
	string argumentName,
	T value,
	string messageFormat,
	params Object[] args
)

VB

Public Shared Function UnexpectedArgumentValue(Of T) ( 
	argumentName As String,
	value As T,
	messageFormat As String,
	ParamArray args As Object()
) As ArgumentOutOfRangeException

F#

static member UnexpectedArgumentValue : 
        argumentName : string * 
        value : 'T * 
        messageFormat : string * 
        args : Object[] -> ArgumentOutOfRangeException 

Parameters

 

argumentName
Type: System.String
Name of the argument.
value
Type: T
The value.
messageFormat
Type: System.String
The message format.
args
Type: System.Object[]
The arguments.

Type Parameters

 

T
The type of the value. Auto-inferred.

Return Value

Type: ArgumentOutOfRangeException
Initialized instance of ArgumentOutOfRangeException.

See Also

Reference

CodeExceptions Class
UnexpectedArgumentValue Overload
CodeJam Namespace

Clone this wiki locally