Table of Contents

Class ReadingDescriptorCollection

Namespace
Acuit.Pinpoint.IO.Testing
Assembly
Acuit.Pinpoint.IO.Testing.Abstractions.dll

A collection of reading descriptors.

public class ReadingDescriptorCollection : IReadingDescriptorCollection, IReadOnlyList<IReadingDescriptor>, IReadOnlyCollection<IReadingDescriptor>, IEnumerable<IReadingDescriptor>, IReadOnlyDictionary<string, IReadingDescriptor>, IReadOnlyCollection<KeyValuePair<string, IReadingDescriptor>>, IEnumerable<KeyValuePair<string, IReadingDescriptor>>, IEnumerable
Inheritance
ReadingDescriptorCollection
Implements
Inherited Members

Constructors

ReadingDescriptorCollection(IEnumerable<IReadingDescriptor>)

Initializes a new instance of the ReadingDescriptorCollection class.

public ReadingDescriptorCollection(IEnumerable<IReadingDescriptor> descriptors)

Parameters

descriptors IEnumerable<IReadingDescriptor>

The descriptors.

Exceptions

ArgumentNullException

descriptors is null.

Properties

Count

Gets the number of elements in the collection.

public int Count { get; }

Property Value

int

The number of elements in the collection.

Empty

Gets an instance that contains no reading descriptors.

public static ReadingDescriptorCollection Empty { get; }

Property Value

ReadingDescriptorCollection

this[int]

Gets the element at the specified index in the read-only list.

public IReadingDescriptor this[int index] { get; }

Parameters

index int

The zero-based index of the element to get.

Property Value

IReadingDescriptor

The element at the specified index in the read-only list.

this[string]

Gets the element that has the specified key in the read-only dictionary.

public IReadingDescriptor this[string key] { get; }

Parameters

key string

The key to locate.

Property Value

IReadingDescriptor

The element that has the specified key in the read-only dictionary.

Exceptions

ArgumentNullException

key is null.

KeyNotFoundException

The property is retrieved and key is not found.

Keys

Gets an enumerable collection that contains the keys in the read-only dictionary.

public IEnumerable<string> Keys { get; }

Property Value

IEnumerable<string>

An enumerable collection that contains the keys in the read-only dictionary.

Values

Gets an enumerable collection that contains the values in the read-only dictionary.

public IEnumerable<IReadingDescriptor> Values { get; }

Property Value

IEnumerable<IReadingDescriptor>

An enumerable collection that contains the values in the read-only dictionary.

Methods

ContainsKey(string)

Determines whether the read-only dictionary contains an element that has the specified key.

public bool ContainsKey(string key)

Parameters

key string

The key to locate.

Returns

bool

true if the read-only dictionary contains an element that has the specified key; otherwise, false.

Exceptions

ArgumentNullException

key is null.

GetEnumerator()

Returns an enumerator that iterates through the collection.

public IEnumerator<IReadingDescriptor> GetEnumerator()

Returns

IEnumerator<IReadingDescriptor>

An enumerator that can be used to iterate through the collection.

TryGetValue(string, out IReadingDescriptor)

Gets the value that is associated with the specified key.

public bool TryGetValue(string key, out IReadingDescriptor value)

Parameters

key string

The key to locate.

value IReadingDescriptor

When this method returns, the value associated with the specified key, if the key is found; otherwise, the default value for the type of the value parameter. This parameter is passed uninitialized.

Returns

bool

true if the object that implements the IReadOnlyDictionary<TKey, TValue> interface contains an element that has the specified key; otherwise, false.

Exceptions

ArgumentNullException

key is null.