package gettext

  1. Overview
  2. Docs

Module GettextTypesSource

Types and exception of ocaml-gettext.

  • author Sylvain Le Gall

Core types of ocaml-gettext library

Sourcetype range = Int32.t * Int32.t
Sourcetype textdomain = string
Sourcetype locale = string
Sourcetype dir = string
Sourcetype filename = string
Sourcetype codeset = string

Exceptions

Sourceexception CompileProblemReadingFile of filename * string

Filename wich generates the error message str

Sourceexception CompileExtractionFailed of filename * string * int

While extracting filename the command str returns exit code i.

Sourceexception CompileExtractionInterrupted of filename * string * int

While extracting filename the command receive signal i.

Sourceexception DomainFileDoesntExist of filename list

Cannot the filename corresponding to a textdomain among the specified files.

Sourceexception FormatInconsistent of string * string

The two strings returned doesn't have the same meaning regarding Printf syntax.

Sourceexception GettextUninitialized

A part of the code try to translate a string, but ocaml-gettext is not initialized.

Sourceexception MoInvalidOptions of Lexing.lexbuf * string

There is an invalid field in the content information of a MO file.

Sourceexception MoInvalidPlurals of Lexing.lexbuf * string

The plural-form field is not correct.

Sourceexception MoInvalidContentType of Lexing.lexbuf * string

The content-type field is not correct.

Sourceexception MoInvalidTranslationSingular of string * int

A plural translation of a singular string has occured.

Sourceexception MoInvalidTranslationPlural of string list * int

An out-of-bound plural translation has occured.

Sourceexception MoJunk of string * string list

There is more plural translation than the number of plural forms.

Sourceexception MoEmptyEntry
Sourceexception MoInvalidFile

A MO corrupted file has been read.

Sourceexception MoInvalidHeaderNegativeStrings

The MO file specified a negative number of strings.

Sourceexception MoInvalidHeaderTableStringOutOfBound of range * range

Offset of the string table is out of bound.

Sourceexception MoInvalidHeaderTableTranslationOutOfBound of range * range

Offset of the translation table is out of bound.

Sourceexception MoInvalidHeaderTableTranslationStringOverlap of range * range

String and translation table overlap.

Sourceexception MoInvalidStringOutOfBound of int * int

The offset and length of a string entry leads to an access beyond the end of the MO file.

Sourceexception MoInvalidTranslationOutOfBound of int * int

The offset and length of a translation entry leads to an access beyond the end of the MO file.

Sourceexception MoCannotOpenFile of string

An error occured when trying to open a MO file.

Sourceexception PoInvalidFile of string * Lexing.lexbuf * in_channel

A PO file cannot be parsed.

Sourceexception PoFileInvalidIndex of string * int

When parsing a PO file, found an out of order table indices in a plural form.

Sourceexception PoFileDoesntExist of string

The PO file doesn't exist.

Sourceexception PoInconsistentMerge of string * string

Cannot merge two PO files.

Sourceexception TranslateStringNotFound of string

A string to translate cannot be found.

Sourceexception LocalePosixUnparseable of string

Cannot parse the POSIX representation of the locale.

Modules signatures

Sourcetype dependencies = (textdomain * codeset option * dir option) list
Sourcemodule type INIT_TYPE = sig ... end
OCaml

Innovation. Community. Security.