Whetstone Class reference
Whetstone Class reference
Whetstone
WhetStone Namespaces
WhetStone.Looping
shuffle Class
shuffle Methods
Shuffle(T) Method
shuffle
Shuffle
T
Method
Shuffles an
IList
T
's elements using algorithm P.
Namespace:
WhetStone.Looping
Assembly:
WhetStone (in WhetStone.dll) Version: 1.0.4.0 (1.0.0.0)
Syntax
C#
Copy
public
static
void
Shuffle
<T>(
this
IList
<T>
arr
,
RandomGenerator
gen
=
null
)
Parameters
arr
Type:
System.Collections.Generic
IList
T
The
IList
T
to shuffle.
gen
(Optional)
Type:
WhetStone.Random
RandomGenerator
The
RandomGenerator
to use.
for
GlobalRandomGenerator
.
Type Parameters
T
The type of the
IList
T
.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
IList
T
. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic)
or
Extension Methods (C# Programming Guide)
.
Exceptions
Exception
Condition
ArgumentException
arr
is read-only
See Also
Reference
shuffle Class
WhetStone.Looping Namespace