Crate library_of_babel

Source
Expand description

A Rust implementation of The Library of Babel

Structs§

Address
Struct containing Address to a page in a book on a shelf in the wall in the hex room
PAGE_MULT
Page multiplier
TITLE_MULT
Title multiplier

Enums§

LibError
Enum of errors that this crate can return

Constants§

BABEL_SET
BABEL set of chars
BASE64_SET
BASE64 set of chars
COLUMNS
Number of columns in a page
PAGE_LENGTH
Total length of a page
ROWS
Number of rows in a page
TITLE_LENGTH
Max length of a book title

Functions§

check_address
Check if all values in the Address are within allowed constraints
get_page
Get a page at an Address in the library
get_title_of_page
Get a title of the page at an Address in the library
search_page_by_title
Search page by a title in the library and return a Address to the book pointing to first page
search_text_in_library
Search specific text in the library and return a page