Merge pull request #1 from mwfogleman/recursive-path
Add documentation for recursive-path.
This commit is contained in:
commit
e4b475080e
1 changed files with 14 additions and 1 deletions
|
|
@ -20,6 +20,7 @@
|
||||||
- [extend-protocolpath](#extend-protocolpath)
|
- [extend-protocolpath](#extend-protocolpath)
|
||||||
- [path](#path)
|
- [path](#path)
|
||||||
- [providepath](#providepath)
|
- [providepath](#providepath)
|
||||||
|
- [recursive-path](#recursive-path)
|
||||||
- [Collector Macros](#collector-macros)
|
- [Collector Macros](#collector-macros)
|
||||||
- [defcollector](#defcollector)
|
- [defcollector](#defcollector)
|
||||||
- [Navigator Macros](#navigator-macros)
|
- [Navigator Macros](#navigator-macros)
|
||||||
|
|
@ -355,6 +356,18 @@ Any higher order navigators passed to `path` must include their arguments, even
|
||||||
|
|
||||||
Defines the path that will be associated to the provided name. The name must have been previously declared using [declarepath](#declarepath).
|
Defines the path that will be associated to the provided name. The name must have been previously declared using [declarepath](#declarepath).
|
||||||
|
|
||||||
|
## recursive-path
|
||||||
|
|
||||||
|
`(recursive-path params self-sym path)`
|
||||||
|
|
||||||
|
Assists in making recursive paths, both parameterized and unparameterized. Example:
|
||||||
|
|
||||||
|
```clojure
|
||||||
|
=> (let [tree-walker (recursive-path [] p (if-path vector? [ALL p] STAY))]
|
||||||
|
(select tree-walker [1 [2 [3 4] 5] [[6]]]))
|
||||||
|
[1 2 3 4 5 6]
|
||||||
|
```
|
||||||
|
|
||||||
# Collector Macros
|
# Collector Macros
|
||||||
|
|
||||||
## defcollector
|
## defcollector
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue