Table of Contents

Interface IBag<T>

Namespace
AlgorithmsSW.Bag
Assembly
AlgorithmsSW.dll

A collection that supports adding elements, and iterating over them.

[PageReference(121)]
public interface IBag<T> : IEnumerable<T>, IEnumerable

Type Parameters

T

The type of the items in the bag.

Inherited Members
Extension Methods

Properties

Count

Gets the number of elements in the bag.

int Count { get; }

Property Value

int

IsEmpty

Gets a value indicating whether the bag is empty.

bool IsEmpty { get; }

Property Value

bool

Methods

Add(T?)

Adds an item to the bag.

void Add(T? item)

Parameters

item T

The item to add.