Module pibfi_options

Description

Options parser for pibfi.

Synopsis

This module implements collecting options from the command line.

When invoking pibfi from the command line, the following syntax can be used:

The following options are recognized.

Function Index

Exported Functions
get_flag/1Gets a switch from the command line.
get_option/3Gets an option from a list of (already parsed) option tuples.
get_opts/1Gets a set of options from the command line.
Internal Documented Functions
convert/2Converts an option value specified on the command line to a term that pibfi can work with internally.
missing/1Gets the default value for an option specified with no value on the command line.
unescape/1Transforms escape codes in a string into embedded characters.

Exported Functions

get_flag/1

get_flag(Switch::atom()) -> true | false

Gets a switch from the command line.

get_option/3

get_option(Options::[{atom(), term()}], Option::atom(), Default::term()) -> term()

Gets an option from a list of (already parsed) option tuples.

get_opts/1

get_opts([atom()]) -> [{atom(), term()}]

Gets a set of options from the command line.

Documented Internal Functions

convert/2

convert(atom(), string()) -> term()

Converts an option value specified on the command line to a term that pibfi can work with internally.

missing/1

missing(atom()) -> term()

Gets the default value for an option specified with no value on the command line.

unescape/1

unescape(string()) -> string()

Transforms escape codes in a string into embedded characters. The escape code #i where i is a decimal integer of from one to three digits is converted into an ASCII character of that value.