Added resolvers, unified package versioning and author section to fit with mono repo style
This commit is contained in:
37
documentation/rule-processing/readme.md
Normal file
37
documentation/rule-processing/readme.md
Normal file
@@ -0,0 +1,37 @@
|
||||
# @efforting.tech/rule-processing
|
||||
|
||||
Rule processing primitives
|
||||
|
||||
- [Source code](https://gitea.efforting.tech/efforting.tech/nodejs.esm-library/src/branch/main/source/rule-processing/resolver.mjs)
|
||||
|
||||
**TODO:** Write proper documentation for this module - currently just a sketch
|
||||
|
||||
## Class overview
|
||||
|
||||
<a name="clov-Abstract_Resolver"></a>
|
||||
### Abstract_Resolver
|
||||
|
||||
Abstract base class that currently implements [`resolve()`](#f-Abstract_Resolver-resolve).
|
||||
|
||||
<a name="clov-Chained_Resolver"></a>
|
||||
### Chained_Resolver
|
||||
|
||||
Goes through every link in the chain and uses the first handler that was resolved.
|
||||
|
||||
<a name="clov-Mapping_Resolver"></a>
|
||||
### Mapping_Resolver
|
||||
|
||||
Resolves handlers by key, either derived via a key function or simply by the item itself as key.
|
||||
|
||||
## Classes
|
||||
|
||||
<a name="cl-Abstract_Resolver"></a>
|
||||
### Abstract_Resolver
|
||||
|
||||
<a name="f-Abstract_Resolver-resolve"></a>
|
||||
#### function `resolve`
|
||||
```js
|
||||
function resolve(item)
|
||||
```
|
||||
Resolves an item by calling the handler returned by the concrete [`resolve_handler()`](#function-resolve_handler) function.
|
||||
|
||||
Reference in New Issue
Block a user