Skip to main content
A trait for indexing operations (container[index]) where the input type is not modified. container[index] is syntactic sugar for container.index(index).

Signature

Examples

The following example implements IndexView on a NucleotideCount container, which can be indexed without modifying the input, enabling individual counts to be retrieved with index syntax.

Trait functions

index

Performs the indexing (container[index]) operation.

Panics

May panic if the index is out of bounds.

Signature

Trait types

Target

The returned type after indexing.

Signature