clojure.data
clojure.data
完整名称空间名称:clojure.data
概述
Non-core data functions.
协议
DiffProtocol
Implementation detail. Subject to change.
已知实现:java.util.List、java.util.Map、java.util-Set、nil、Object
差相似函数
Usage: (diff-similar a b)
Implementation detail. Subject to change.
在Clojure版本1.3中添加
公平参与协议
Implementation detail. Subject to change.
已知实现:java.util.List、java.util.Map、java.util-Set、nil、Object
相等-分区函数
Usage: (equality-partition x)
Implementation detail. Subject to change.
在Clojure版本1.3中添加
公共变量和函数
扩散函数
Usage: (diff a b)
Recursively compares a and b, returning a tuple of
[things-only-in-a things-only-in-b things-in-both].
Comparison rules:
* For equal a and b, return [nil nil a].
* Maps are subdiffed where keys match and values differ.
* Sets are never subdiffed.
* All sequential things are treated as associative collections
by their indexes, with results returned as vectors.
* Everything else (including strings!) is treated as
an atom and compared for equality.
在Clojure版本1.3中添加