ip-0.9.2: Library for IP and MAC addresses

Safe HaskellNone
LanguageHaskell2010

Data.Text.Builder.Variable

Description

This is a builder optimized for concatenating short variable-length strings whose length has a known upper bound. In these cases, this can be up to ten times faster than the builder provided by the text library. However, data whose textual encoding has no known upper bound cannot be encoded by the builder provided here. For example, it is possible to provide decimal builders for types like Int8 and Word16, whose lengths are respectively bounded by 4 and 5. However, this is not possible for Integer, since its decimal representation could be arbitrarily long.

Synopsis

Documentation

data Builder a Source #

Instances

Monoid (Builder a) Source # 

Methods

mempty :: Builder a #

mappend :: Builder a -> Builder a -> Builder a #

mconcat :: [Builder a] -> Builder a #

run :: Builder a -> a -> Text Source #

contramap :: (b -> a) -> Builder a -> Builder b Source #

charBmp :: Builder Char Source #

A character in the basic multilingual plane.