interp-1.0.0.2: Tracery-like randomized text interpolation

Safe HaskellNone
LanguageHaskell2010

Data.Text.Interp.Interpolate

Synopsis

Documentation

data IState Source #

Record holding intermediary interpolation state

Constructors

IState 

Fields

interp Source #

Arguments

:: Subst

mapping to get substitutions out of

-> NonEmpty IText

lits of segments to interpolate

-> I Text

final interpolation

Build interpolated text out of a Subst mapping and a list of segments to interpolate

interp' Source #

Arguments

:: Subst

mapping

-> IState

intermediary state

-> IText

segment to interpolate

-> I IState

updated state, after the segment's been interpolated

Interpolate a single segment