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

applying(_:)

Applies the given difference to this collection. 与えられた差異をこのコレクションに適用します。

Declaration 宣言

func applying(_ difference: CollectionDifference<Element>) -> Array<Element>?

Parameters パラメータ

difference

The difference to be applied. 適用されることになる差異。

Return Value 戻り値

An instance representing the state of the receiver with the difference applied, or nil if the difference is incompatible with the receiver’s state. 適用された差異をもつレシーバの状態を表しているインスタンス、またはnil、もし差異がレシーバのもつ状態と相容れないならば。

Discussion 解説

Complexity: O(n + c), where n is self.count and c is the number of changes contained by the parameter. 計算量:O(n + c)、ここでnself.countです、そしてcはパラメータによって含まれる変更の数です。

See Also 参照

Creating and Applying Differences 差異の作成と適用