SEARCH
0-9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Prev | Current Page 379 | Next

Jonathan Jacky, Margus Veanes, Colin Campbell, Wolfram Schulte

"Model-Based Software Testing and Analysis with C#"

Several more are
described in the library documentation.
302 Modeling Library Reference
Count
Returns the number of elements in the value array.
IsEmpty
Returns true if the value array has no elements. Returns false otherwise.
Item(int)
Length
etc. . . .
A.2.6 Bag
Bag
An unordered collection of possibly repeating elements. This is also known as a
multiset. The type is immutable; add/remove methods return a new bag.
Syntax
public sealed class Bag : CollectionValue
Constructors
Bag()
Constructs an empty bag. The static field Bag.EmptyBag is preferred instead
of using this form of the constructor.
Bag(IEnumerable)
Constructs a bag with elements taken from a collection. The Count of the resulting
bag will be the same as the number of values in the collection given as the
argument.
Bag(T[])
Constructs a bag with elements given as params arguments. The Count of the
bag will be the same as the number of arguments to the constructor.
Bag(IEnumerable>)
Constructs a bag with elements and their corresponding multiplicities given as
a pair enumeration.
Bag(Pair[])
Constructs a bag with params arguments that are pairs of elements and their
corresponding multiplicities.
Methods
The following entries describe some of the methods of this type. Many more are
described in the library documentation.


Pages:
367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391
hotel jelenia góra Russian bride Free English grammar and study guid powiekszenia wielkoformatowe counter strike 1.6