-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/
-- | Low-level, streaming YAML interface.
--
-- README and API documentation are available at
-- https://www.stackage.org/package/libyaml
@package libyaml
@version 0.1.2
-- | Low-level, streaming YAML interface. For a higher-level interface, see
-- Data.Yaml.
module Text.Libyaml
-- | Event with start and end marks.
data MarkedEvent
MarkedEvent :: Event -> YamlMark -> YamlMark -> MarkedEvent
[yamlEvent] :: MarkedEvent -> Event
[yamlStartMark] :: MarkedEvent -> YamlMark
[yamlEndMark] :: MarkedEvent -> YamlMark
data Event
EventStreamStart :: Event
EventStreamEnd :: Event
EventDocumentStart :: Event
EventDocumentEnd :: Event
EventAlias :: !AnchorName -> Event
EventScalar :: !ByteString -> !Tag -> !Style -> !Anchor -> Event
EventSequenceStart :: !Tag -> !SequenceStyle -> !Anchor -> Event
EventSequenceEnd :: Event
EventMappingStart :: !Tag -> !MappingStyle -> !Anchor -> Event
EventMappingEnd :: Event
-- | Style for scalars - e.g. quoted / folded
data Style
Any :: Style
Plain :: Style
SingleQuoted :: Style
DoubleQuoted :: Style
Literal :: Style
Folded :: Style
PlainNoTag :: Style
-- | Style for sequences - e.g. block or flow
data SequenceStyle
AnySequence :: SequenceStyle
BlockSequence :: SequenceStyle
FlowSequence :: SequenceStyle
-- | Style for mappings - e.g. block or flow
data MappingStyle
AnyMapping :: MappingStyle
BlockMapping :: MappingStyle
FlowMapping :: MappingStyle
data Tag
StrTag :: Tag
FloatTag :: Tag
NullTag :: Tag
BoolTag :: Tag
SetTag :: Tag
IntTag :: Tag
SeqTag :: Tag
MapTag :: Tag
UriTag :: String -> Tag
NoTag :: Tag
type AnchorName = String
type Anchor = Maybe AnchorName
encode :: MonadResource m => ConduitM Event o m ByteString
encodeWith :: MonadResource m => FormatOptions -> ConduitM Event o m ByteString
-- | Create a conduit that yields events from a bytestring.
decode :: MonadResource m => ByteString -> ConduitM i Event m ()
-- | Create a conduit that yields marked events from a bytestring.
--
-- This conduit will yield identical events to that of "decode", but also
-- includes start and end marks for each event.
decodeMarked :: MonadResource m => ByteString -> ConduitM i MarkedEvent m ()
encodeFile :: MonadResource m => FilePath -> ConduitM Event o m ()
-- | Creata a conduit that yields events from a file.
decodeFile :: MonadResource m => FilePath -> ConduitM i Event m ()
-- | Create a conduit that yields marked events from a file.
--
-- This conduit will yield identical events to that of "decodeFile", but
-- also includes start and end marks for each event.
decodeFileMarked :: MonadResource m => FilePath -> ConduitM i MarkedEvent m ()
encodeFileWith :: MonadResource m => FormatOptions -> FilePath -> ConduitM Event o m ()
-- | Contains options relating to the formatting (indendation, width) of
-- the YAML output.
data FormatOptions
defaultFormatOptions :: FormatOptions
-- | Set the maximum number of columns in the YAML output, or
-- Nothing for infinite. By default, the limit is 80 characters.
setWidth :: Maybe Int -> FormatOptions -> FormatOptions
-- | Control when and whether tags are rendered to output.
setTagRendering :: (Event -> TagRender) -> FormatOptions -> FormatOptions
-- | A value for formatOptionsRenderTags that renders no collection
-- tags but all scalar tags (unless suppressed with styles 'NoTag or
-- PlainNoTag).
renderScalarTags :: Event -> TagRender
-- | A value for formatOptionsRenderTags that renders all tags
-- (except NoTag tag and PlainNoTag style).
renderAllTags :: Event -> TagRender
-- | A value for formatOptionsRenderTags that renders no tags.
renderNoTags :: Event -> TagRender
-- | A value for formatOptionsRenderCollectionTags that renders
-- tags which are instances of UriTag
renderUriTags :: Event -> TagRender
data YamlException
YamlException :: String -> YamlException
-- | problem, context, index, position line, position column
YamlParseException :: String -> String -> YamlMark -> YamlException
[yamlProblem] :: YamlException -> String
[yamlContext] :: YamlException -> String
[yamlProblemMark] :: YamlException -> YamlMark
-- | The pointer position
data YamlMark
YamlMark :: Int -> Int -> Int -> YamlMark
[yamlIndex] :: YamlMark -> Int
[yamlLine] :: YamlMark -> Int
[yamlColumn] :: YamlMark -> Int
instance GHC.Show.Show Text.Libyaml.YamlException
instance GHC.Show.Show Text.Libyaml.YamlMark
instance GHC.Enum.Enum Text.Libyaml.TagRender
instance GHC.Show.Show Text.Libyaml.ToEventRawException
instance GHC.Show.Show Text.Libyaml.EventType
instance GHC.Enum.Enum Text.Libyaml.EventType
instance GHC.Classes.Eq Text.Libyaml.Event
instance GHC.Show.Show Text.Libyaml.Event
instance Data.Data.Data Text.Libyaml.Tag
instance GHC.Read.Read Text.Libyaml.Tag
instance GHC.Classes.Eq Text.Libyaml.Tag
instance GHC.Show.Show Text.Libyaml.Tag
instance Data.Data.Data Text.Libyaml.MappingStyle
instance GHC.Classes.Ord Text.Libyaml.MappingStyle
instance GHC.Enum.Bounded Text.Libyaml.MappingStyle
instance GHC.Enum.Enum Text.Libyaml.MappingStyle
instance GHC.Classes.Eq Text.Libyaml.MappingStyle
instance GHC.Show.Show Text.Libyaml.MappingStyle
instance Data.Data.Data Text.Libyaml.SequenceStyle
instance GHC.Classes.Ord Text.Libyaml.SequenceStyle
instance GHC.Enum.Bounded Text.Libyaml.SequenceStyle
instance GHC.Enum.Enum Text.Libyaml.SequenceStyle
instance GHC.Classes.Eq Text.Libyaml.SequenceStyle
instance GHC.Show.Show Text.Libyaml.SequenceStyle
instance Data.Data.Data Text.Libyaml.Style
instance GHC.Classes.Ord Text.Libyaml.Style
instance GHC.Enum.Bounded Text.Libyaml.Style
instance GHC.Enum.Enum Text.Libyaml.Style
instance GHC.Classes.Eq Text.Libyaml.Style
instance GHC.Read.Read Text.Libyaml.Style
instance GHC.Show.Show Text.Libyaml.Style
instance GHC.Exception.Type.Exception Text.Libyaml.YamlException
instance GHC.Exception.Type.Exception Text.Libyaml.ToEventRawException