Skip to main content

Module plus

Module plus 

Source
Expand description

Gopher+ : the 1993 upward-compatible enhancements to RFC 1436.

Gopher+ adds four things to gopher, and this module models three of them (the fourth, the item-line marker, belongs to crate::menu because it rides in the menu):

  • a response header, so a reply can declare its length instead of relying on the server closing the connection (PlusHeader);
  • attribute blocks, metadata about an item retrieved separately from the item itself (AttributeBlock, View);
  • ASK forms, the interactive questionnaire a ? item carries (AskDirective).

Everything here is pure parsing with no dependencies, so it is available under default-features = false.

Gopher+ was never an RFC. The reference is “Gopher+: Upward compatible enhancements to the Internet Gopher protocol” (University of Minnesota, 1993).

Structs§

AttributeBlock
One Gopher+ attribute block.
MalformedHeader
What parse_header could not make sense of.
View
One entry of a +VIEWS block: an alternate representation of an item.

Enums§

AskDirective
One line of an +ASK block: a question to put to the user.
PlusHeader
The first line of a Gopher+ reply.
PlusRequest
What a Gopher+ retrieval asks for.

Functions§

parse_ask
Parse an +ASK block into its directives, in order.
parse_attributes
Parse a Gopher+ attribute response into its blocks, in order.
parse_header
Parse a Gopher+ response header line (without its CRLF).
parse_views
Parse a +VIEWS block into its alternate representations.