packages feed

hw-json-standard-cursor 0.1.0.1 → 0.1.1.0

raw patch · 3 files changed

+7/−6 lines, 3 filesPVP: major bump suggested

API removals or changes: PVP suggests a major version bump

API changes (from Hackage documentation)

- HaskellWorks.Data.Json.Standard.Cursor.Fast: type Cursor = GenericCursor ByteString CsPoppy (RangeMin (Vector Word64))
+ HaskellWorks.Data.Json.Standard.Cursor.Fast: type Cursor = GenericCursor ByteString CsPoppy (RangeMin CsPoppy)

Files

README.md view
@@ -3,7 +3,10 @@  `hw-json-standard-cursor` is support library for `hw-json`, a succinct JSON parsing library. -It uses succinct data-structures to allow traversal of large JSON strings with minimal memory overhead.+It is used to create "interest-bits" (`*.ib.idx`) files and+"balanced-parenthesis" (`*.bp.idx`) files.  These can then be loaded by the `hw-json`+library to enable parsing of parts of the original JSON file without deserialising+the entire JSON file into objects in memory.  For more information see [`hw-json`](https://github.com/haskell-works/hw-json). 
hw-json-standard-cursor.cabal view
@@ -1,7 +1,7 @@ cabal-version:  2.2  name:           hw-json-standard-cursor-version:        0.1.0.1+version:        0.1.1.0 synopsis:       Memory efficient JSON parser description:    Memory efficient JSON parser. Please see README.md category:       Data
src/HaskellWorks/Data/Json/Standard/Cursor/Fast.hs view
@@ -7,7 +7,6 @@   , fromString   ) where -import Data.Word import Foreign.ForeignPtr import HaskellWorks.Data.Json.Standard.Cursor.Generic import HaskellWorks.Data.Json.Standard.Cursor.Specific@@ -16,7 +15,6 @@ import qualified Data.ByteString                                      as BS import qualified Data.ByteString.Char8                                as BSC import qualified Data.ByteString.Internal                             as BSI-import qualified Data.Vector.Storable                                 as DVS import qualified HaskellWorks.Data.BalancedParens.RangeMin            as RM import qualified HaskellWorks.Data.FromForeignRegion                  as F import qualified HaskellWorks.Data.Json.Standard.Cursor.Internal.IbBp as J@@ -26,13 +24,13 @@ instance SpecificCursor Fast where   type CursorOf Fast = Cursor -type Cursor = GenericCursor BS.ByteString CsPoppy (RM.RangeMin (DVS.Vector Word64))+type Cursor = GenericCursor BS.ByteString CsPoppy (RM.RangeMin CsPoppy)  fromByteString :: BS.ByteString -> Cursor fromByteString bs = GenericCursor   { cursorText      = bs   , interests       = makeCsPoppy ib-  , balancedParens  = RM.mkRangeMin bp+  , balancedParens  = RM.mkRangeMin (makeCsPoppy bp)   , cursorRank      = 1   }   where J.IbBp ib bp = J.toIbBp bs