C5  2.4
The C5 Generic Collection Library for C# and CLI is a comprehensive collection library supporting lists, sets, bags, dictionaries, priority queues, (FIFO) queues, and (LIFO) stacks. C5 runs on .NET 3.5+, Silverlight 5, Windows Phone 8, Xamarin.iOS, Xamarin.Android, and Mono.
C5.DuplicateNotAllowedException Class Reference

An exception thrown when an operation attempts to create a duplicate in a collection with set semantics (P:C5.IExtensible`1.AllowsDuplicates is false) or attempts to create a duplicate key in a dictionary. More...

Inheritance diagram for C5.DuplicateNotAllowedException:

Public Member Functions

 DuplicateNotAllowedException ()
 Create a simple exception with no further explanation. More...
 
 DuplicateNotAllowedException (string message)
 Create the exception with an explanation of the reason. More...
 

Detailed Description

An exception thrown when an operation attempts to create a duplicate in a collection with set semantics (P:C5.IExtensible`1.AllowsDuplicates is false) or attempts to create a duplicate key in a dictionary.

With collections this can only happen with Insert operations on lists, since the Add operations will not try to create duplictes and either ignore the failure or report it in a bool return value.

With dictionaries this can happen with the M:C5.IDictionary`2.Add(`0,`1) metod.

Constructor & Destructor Documentation

C5.DuplicateNotAllowedException.DuplicateNotAllowedException ( )

Create a simple exception with no further explanation.

C5.DuplicateNotAllowedException.DuplicateNotAllowedException ( string  message)

Create the exception with an explanation of the reason.

Parameters
message

The documentation for this class was generated from the following file: