Instance Method インスタンスメソッド

finish()

Resume the task awaiting the next iteration point by having it return nil, which signifies the end of the iteration.

Declaration 宣言

func finish()

Discussion 解説

Calling this function more than once has no effect. After calling finish, the stream enters a terminal state and doesn’t produces any additional elements.