Module gwy :: Class TextHeaderError
[hide private]
[frames] | no frames]

Class TextHeaderError

source code

Error codes returned by text header parsing.

Some errors, in particular TEXT_HEADER_ERROR_KEY and TEXT_HEADER_ERROR_VALUE are expected to be raised by user callbacks (they are not restricted to these codes though).


Since: 2.18

Note: All the enumerated values are defined at the module level, not the class level. The are just groupped by class here for easier orientation.

Class Variables [hide private]
  TEXT_HEADER_ERROR_GARBAGE
Line cannot be parsed into a key-value pair.
  TEXT_HEADER_ERROR_KEY
Key name is invalid, namely empty.
  TEXT_HEADER_ERROR_PREFIX
Line lacks the mandatory prefix.
  TEXT_HEADER_ERROR_SECTION_END
Section ended when a different section or no section was open.
  TEXT_HEADER_ERROR_SECTION_NAME
Section name is invalid.
  TEXT_HEADER_ERROR_SECTION_START
Section started before the previous ended.
  TEXT_HEADER_ERROR_TERMINATOR
The text header has ended without being terminated by specified terminator.
  TEXT_HEADER_ERROR_VALUE
Value is invalid.
Class Variable Details [hide private]

TEXT_HEADER_ERROR_SECTION_END

Section ended when a different section or no section was open. Note that gwy_text_header_context_get_section() returns the section being closed at the time this error is raised.

TEXT_HEADER_ERROR_SECTION_NAME

Section name is invalid. It is raised by the parser only for an empty section name.

TEXT_HEADER_ERROR_SECTION_START

Section started before the previous ended. This is raised only if endsection_template is set.

TEXT_HEADER_ERROR_VALUE

Value is invalid. This is never raised by the parser.