Replace

stdtraits~ Replace

Source:

Swap out one value in a con­tainer for an­other.

This trait is im­pli­citly im­ple­men­ted if the con­tainer im­ple­ments Get and Set.

In­ter­face

(c: Con­tainer, v: Value, k: Key) => r: Value.