Movatterモバイル変換


[0]ホーム

URL:


Hackage :: [Package]

bytestring:Fast, compact, strict and lazy byte strings with a list interface

[bsd3,data,library ] [Propose Tags ] [Report a vulnerability ]

An efficient compact, immutable byte string type (both strict and lazy)suitable for binary or 8-bit character data.

TheByteString type represents sequences of bytes or 8-bit characters.It is suitable for high performance use, both in terms of large dataquantities, or high speed requirements. TheByteString functions followthe same style as Haskell's ordinary lists, so it is easy to convert codefrom usingString toByteString.

TwoByteString variants are provided:

  • StrictByteStrings keep the string as a single large array. Thismakes them convenient for passing data between C and Haskell.

  • LazyByteStrings use a lazy list of strict chunks which makes itsuitable for I/O streaming tasks.

TheChar8 modules provide a character-based view of the sameunderlyingByteString types. This makes it convenient to handle mixedbinary and 8-bit character content (which is common in many file formatsand network protocols).

TheBuilder module provides an efficient way to build upByteStringsin an ad-hoc way by repeated concatenation. This is ideal for fastserialisation or pretty printing.

There is also aShortByteString type which has a lower memory overheadand can be converted to or from aByteString. It is suitable for keepingmany short strings in memory, especially long-term, without incurring anypossible heap fragmentation costs.

ByteStrings are not designed for Unicode. For Unicode strings you shoulduse theText type from thetext package.

These modules are intended to be imported qualified, to avoid name clasheswithPrelude functions, e.g.

import qualified Data.ByteString as BS

[Skip to Readme]

Modules

[Index] [Quick Jump]

Flags

Manual Flags

NameDescriptionDefault
pure-haskell

Don't use bytestring's standard C routinesWhen this flag is true, bytestring will use pure Haskell variants (no C FFI)of the internal functions. This is not recommended except in use cases thatcannot (or do not) depend on C, such as with GHC's JavaScript backend.

Disabled

Use-f <flag> to enable a flag, or-f -<flag> to disable that flag.More info

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

  • No Candidates
Versions[RSS]0.9,0.9.0.1,0.9.0.2,0.9.0.3,0.9.0.4,0.9.1.0,0.9.1.1,0.9.1.2,0.9.1.3,0.9.1.4,0.9.1.5,0.9.1.6,0.9.1.7,0.9.1.8,0.9.1.9,0.9.1.10,0.9.2.0,0.9.2.1,0.10.0.0,0.10.0.1,0.10.0.2,0.10.2.0,0.10.4.0,0.10.4.1,0.10.6.0,0.10.8.0,0.10.8.1,0.10.8.2,0.10.9.0,0.10.10.0,0.10.10.1,0.10.12.0,0.10.12.1,0.11.0.0,0.11.1.0,0.11.2.0,0.11.3.0,0.11.3.1,0.11.4.0,0.11.5.0,0.11.5.1,0.11.5.2,0.11.5.3,0.11.5.4,0.12.0.0,0.12.0.1,0.12.0.2,0.12.1.0,0.12.2.0
Change logChangelog.md
Dependenciesbase (>=4.11 && <5),data-array-byte (>=0.1 && <0.2),deepseq,ghc-prim,template-haskell [details]
Tested with ghc ==9.10.1, ghc ==9.8.2, ghc ==9.6.5, ghc ==9.4.8, ghc ==9.2.8, ghc ==9.0.2, ghc ==8.10.7, ghc ==8.8.4, ghc ==8.6.5, ghc ==8.4.4
LicenseBSD-3-Clause
CopyrightCopyright (c) Don Stewart 2005-2009,(c) Duncan Coutts 2006-2015,(c) David Roundy 2003-2005,(c) Jasper Van der Jeugt 2010,(c) Simon Meier 2010-2013.
AuthorDon Stewart,Duncan Coutts
MaintainerHaskell Bytestring Team <andrew.lelechenko@gmail.com>, Core Libraries Committee
CategoryData
Home pagehttps://github.com/haskell/bytestring
Bug trackerhttps://github.com/haskell/bytestring/issues
Source repohead: git clonehttps://github.com/haskell/bytestring
UploadedbyBodigrim at2024-12-06T21:41:31Z
DistributionsArch:0.11.4.0, Fedora:0.11.4.0
Reverse Dependencies6171 direct, 8926 indirect [details]
Downloads120271 total (201 in the last 30 days)
Rating2.75 (votes: 20)[estimated byBayesian average]
Your Rating
  • λ
  • λ
  • λ
StatusDocs available[build log]
Last success reported on 2024-12-06[all 1 reports]

Readme for bytestring-0.12.2.0

[back to package description]

ByteString: Fast, Packed Strings of Bytes

Build StatusHackageStackage LTSStackage Nightly

This library provides theData.ByteString module -- strict and lazybyte arrays manipulable as strings -- providing very time/space-efficientstring and IO operations.

For very large data requirements, or constraints on heap size,Data.ByteString.Lazy is provided, a lazy list of bytestring chunks.Efficient processing of multi-gigabyte data can be achieved this way.

The library also providesData.ByteString.Builder for efficient constructionofByteString values from smaller pieces during binary serialization.

Requirements:

  • Cabal 2.2 or greater
  • GHC 8.4 or greater

Authors

ByteString was derived from the GHCPackedString library,originally written by Bryan O'Sullivan, and then by Simon Marlow.It was adapted and greatly extended for darcs by David Roundy andothers. Don Stewart and Duncan Coutts cleaned up and further extendedthe implementation and added the.Lazy code. Simon Meier contributedtheBuilder feature.

Produced byhackage andCabal 3.12.1.0.


[8]ページ先頭

©2009-2025 Movatter.jp