[][src]Module bloguen::util

Module containing various utility functions.

Structs

BCP_47

Regex to use for parsing a BCP47 language tag.

LANGUAGE_EN_GB

The default en-GB language tag.

MARKDOWN_OPTIONS

Options to use for parsing Markdown.

PolyWrite

An output sink, writing the data passed thereto to two sinks contained therein.

XmlEscapeWrite

An output sink, escaping <, >, and & characters passed thereto.

Statics

ADJECTIVES

A set of upper-case-first adjectives for random string gen.

ADVERBS

A set of upper-case-first adverbs for random string gen.

BLOGUEN_VERSION

Current version of bloguen.

NOUNS

A set of upper-case-first nouns for random string gen.

Functions

concat_path

Correctly append the specified string onto the specified path.

current_username

Try to get the name of the currently logged-in user.

default_language

Try to get the default language for the system/user/environment.

extract_actual_assets

Get a list of all actual (i.e. existant) assets in the specified AST.

extract_links

Get list of all links in the specified AST.

is_asset_link

Check if the link points to a local relative asset.

mul_str

Create a string consisting of n repetitions of what.

name_based_full_name

Generate a reproducible blogue author from its name.

name_based_post_time

Generate a reproducible post time from its name.

newline_pad

Insert enough newlines at the start and end of the string to reach the specified count.

normalise_datetime

Normalise a DateTime with any offset to a FixedOffset one.

parse_date_format_specifier

Parse a datetime specifier in the format_output() argument style.

parse_function_notation

Trivially parse a standard funxion invocation notation.

path_depth

Get how many times this path descends minus how may times it goes up a level

read_file

Read the contents of the specified file into a String.

uppercase_first

Uppercase the first character of the supplied string.