Add documentation for recursive-path.
This commit is contained in:
parent
6a90f3d1c0
commit
a9ba39f748
1 changed files with 14 additions and 1 deletions
|
|
@ -20,6 +20,7 @@
|
|||
- [extend-protocolpath](#extend-protocolpath)
|
||||
- [path](#path)
|
||||
- [providepath](#providepath)
|
||||
- [recursive-path](#recursive-path)
|
||||
- [Collector Macros](#collector-macros)
|
||||
- [defcollector](#defcollector)
|
||||
- [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).
|
||||
|
||||
## 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
|
||||
|
||||
## defcollector
|
||||
|
|
@ -423,4 +436,4 @@ See also [nav](#nav)
|
|||
|
||||
`(nav params transform-impl select-impl)`
|
||||
|
||||
Returns an "anonymous navigator." See [defnav](#defnav).
|
||||
Returns an "anonymous navigator." See [defnav](#defnav).
|
||||
|
|
|
|||
Loading…
Reference in a new issue