StructureSwift

    AnySequence

    A type-erased sequence.

    @frozen struct AnySequence<Element>

    Overview

    An instance of AnySequence forwards its operations to an underlying base sequence having the same Element type, hiding the specifics of the underlying sequence.

    Members

    Typealiases

    • typealias Iterator

      A type that provides the sequence’s iteration interface and encapsulates its iteration state.

    Initializers

    • init<S>(S)

      Creates a new sequence that wraps and forwards operations to base.

    • init<I>(() -> I)

      Creates a sequence whose makeIterator() method forwards to makeUnderlyingIterator.

    Instance Properties

    Instance Methods

    Removed Members

    Instance Methods