| Safe Haskell | None |
|---|---|
| Language | GHC2021 |
Ecluse.Core.Registry.Npm.Reader
Description
The packument walk for full and selected reads. It emits the fields that Ecluse.Core.Registry.Npm.Streaming emits for the same mode, in the same order, and builds each retained release once with its keys and strings interned as read.
Synopsis
- data PackumentRead
- npmWalk :: (Build b r, Result r ~ Walked s) => b -> Int -> PackumentRead -> FieldStep s (NpmFieldOf (Built b)) r -> (s -> Text -> Bool) -> InternTable -> s -> TokenResult -> r
- releaseUniqueFields :: [Text]
Documentation
data PackumentRead Source #
The whole packument, or one release with its timestamp and the latest tag.
Constructors
| WholePackument | |
| OneRelease Text |
Instances
| Show PackumentRead Source # | |
Defined in Ecluse.Core.Registry.Npm.Reader Methods showsPrec :: Int -> PackumentRead -> ShowS # show :: PackumentRead -> String # showList :: [PackumentRead] -> ShowS # | |
| Eq PackumentRead Source # | |
Defined in Ecluse.Core.Registry.Npm.Reader Methods (==) :: PackumentRead -> PackumentRead -> Bool # (/=) :: PackumentRead -> PackumentRead -> Bool # | |
npmWalk :: (Build b r, Result r ~ Walked s) => b -> Int -> PackumentRead -> FieldStep s (NpmFieldOf (Built b)) r -> (s -> Text -> Bool) -> InternTable -> s -> TokenResult -> r Source #
Walk one packument into the builder, passing each field to the step as it completes. Only a release the consumer keeps enters the table, and only the first of each member it repeats.
releaseUniqueFields :: [Text] Source #
Members whose values differ in every release, so the table keeps them as read. A name matches
at any depth, so a rarer member such as _npmUser.url is kept as read too.