Liking cljdoc? Tell your friends :D

hara.test.form.match


match-baseclj

(match-base fmeta {:keys [unit refers namespaces] :as filter} default)

determines whether a term matches with a filter (match-base {:unit #{:web}} {:unit #{:web}} false) => [true false false] (match-base {:refer 'user/foo :namespace 'user} {:refers '[user/other] :namespaces '[foo bar]} true) => [true false false]

determines whether a term matches with a filter
(match-base {:unit #{:web}}
            {:unit #{:web}}
            false)
=> [true false false]
(match-base {:refer 'user/foo
             :namespace 'user}
            {:refers '[user/other]
             :namespaces '[foo bar]}
            true)
=> [true false false]
raw docstring

match-excludeclj

(match-exclude fmeta filter)

determines whether exclusion is a match (match-exclude {:unit #{:web}} {:unit #{:web}}) => true (match-exclude {:refer 'user/foo :namespace 'user} {}) => false

determines whether exclusion is a match
(match-exclude {:unit #{:web}}
               {:unit #{:web}})
=> true
(match-exclude {:refer 'user/foo
                :namespace 'user}
               {})
=> false
raw docstring

match-includeclj

(match-include fmeta filter)

determines whether inclusion is a match (match-include {:unit #{:web}} {:unit #{:web}}) => true

(match-include {:refer 'user/foo :namespace 'user} {}) => true

determines whether inclusion is a match
(match-include {:unit #{:web}}
               {:unit #{:web}})
=> true

(match-include {:refer 'user/foo
                :namespace 'user}
               {})
=> true
raw docstring

match-optionsclj

(match-options {:keys [refer unit] :as fmeta}
               {:keys [include exclude] :as settings})

determines whether a set of options can match (match-options {:unit #{:web} :refer 'user/foo} {:include [{:tags #{:web}}] :exclude []}) => true

(match-options {:unit #{:web} :refer 'user/foo} {:include [{:tags #{:web}}] :exclude [{:refers '[user/foo]}]}) => false

(match-options {:unit #{:web} :ns 'user :refer 'user/foo} {:include [{:namespaces [#"us"]}]}) => true

determines whether a set of options can match
(match-options {:unit #{:web}
                :refer 'user/foo}
               {:include [{:tags #{:web}}]
                :exclude []})
=> true

(match-options {:unit #{:web}
                :refer 'user/foo}
               {:include [{:tags #{:web}}]
                :exclude [{:refers '[user/foo]}]})
=> false

(match-options {:unit #{:web}
                :ns 'user
                :refer 'user/foo}
               {:include [{:namespaces [#"us"]}]})
=> true
raw docstring

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

× close