language-avro-0.1.4.0: Language definition and parser for AVRO files.
Safe HaskellNone
LanguageHaskell2010

Language.Avro.Parser

Description

Parser for AVRO (.avdl) files, as defined in http://avro.apache.org/docs/1.8.2/spec.html.

Synopsis

Main parsers

parseProtocol :: MonadParsec Char Text m => m Protocol Source #

Parses a single protocol into the Protocol structure.

readWithImports Source #

Arguments

:: FilePath

base directory

-> FilePath

initial file

-> IO (Either Text Protocol) 

Reads and parses a whole file and its imports, recursively.

Intermediate parsers

parseAliases :: MonadParsec Char Text m => m Aliases Source #

Parses aliases, which are just Lists of TypeName.

parseAnnotation :: MonadParsec Char Text m => m Annotation Source #

Parses annotations into the Annotation structure.

parseDecimal :: MonadParsec Char Text m => m Decimal Source #

Parses the special type decimal into it's corresponding Decimal structure.

parseImport :: MonadParsec Char Text m => m ImportType Source #

Parses a single import into the ImportType structure.

parseMethod :: MonadParsec Char Text m => m Method Source #

Parses a single method/message into the Method structure.

parseNamespace :: MonadParsec Char Text m => m Namespace Source #

Parses a single import into the ImportType structure.

parseOrder :: MonadParsec Char Text m => m Order Source #

Parses order annotations into the Order structure.

parseSchema :: MonadParsec Char Text m => m Schema Source #

Parses a single type respecting Data.Avro.Schema's Schema.