Liking cljdoc? Tell your friends :D

clojure.algo.generic.collection

Generic collection interface This library defines generic versions of common collection-related functions as multimethods that can be defined for any type.

Generic collection interface
This library defines generic versions of common
collection-related functions as multimethods that can be
defined for any type.
raw docstring

assoccljmultimethod

(assoc coll & key-val-pairs)

Returns a new collection in which the values corresponding to the given keys are updated by the given values. Each type of collection can have specific restrictions on the possible keys.

Returns a new collection in which the values corresponding to the
given keys are updated by the given values. Each type of collection
can have specific restrictions on the possible keys.
sourceraw docstring

conjcljmultimethod

(conj coll & xs)

Returns a new collection resulting from adding all xs to coll.

Returns a new collection resulting from adding all xs to coll.
sourceraw docstring

dissoccljmultimethod

(dissoc coll & keys)

Returns a new collection in which the entries corresponding to the given keys are removed. Each type of collection can have specific restrictions on the possible keys.

Returns a new collection in which the entries corresponding to the
given keys are removed. Each type of collection can have specific
restrictions on the possible keys.
sourceraw docstring

emptycljmultimethod

(empty coll)

Returns an empty collection of the same kind as the argument

Returns an empty collection of the same kind as the argument
sourceraw docstring

getcljmultimethod

(get coll key)
(get coll key not-found)

Returns the element of coll referred to by key. Each type of collection can have specific restrictions on the possible keys.

Returns the element of coll referred to by key. Each type of collection
can have specific restrictions on the possible keys.
sourceraw docstring

intocljmultimethod

(into to from)

Returns a new coll consisting of to-coll with all of the items of from-coll conjoined. A default implementation based on reduce, conj, and seq is provided.

Returns a new coll consisting of to-coll with all of the items of
from-coll conjoined. A default implementation based on reduce, conj, and
seq is provided.
sourceraw docstring

seqcljmultimethod

(seq s)

Returns a seq on the object s.

Returns a seq on the object s.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close