libexplain  1.4.D001
Functions
libexplain/option.h File Reference

Go to the source code of this file.

Functions

int explain_option_numeric_errno (void)
int explain_option_dialect_specific (void)
int explain_option_debug (void)
int explain_option_assemble_program_name (void)
int explain_option_symbolic_mode_bits (void)
int explain_option_internal_strerror (void)
int explain_option_hanging_indent (int width)
int explain_option_extra_device_info (void)

Function Documentation

The explain_option_assemble_program_name option is used to determine whether or not the explain_output_error, explain_output_error_and_die and explain_output_warning functions should include the program name at the start the messages.

Returns:
int; true (non-zero) is shall include program name, zero (false) if shall not include program name.

Definition at line 276 of file option.c.

int explain_option_debug ( void  )

The explain_option_debug function may be used to obtain the EXPLAIN_OPTIONS (no-)debug flag, used to control whether or not debug behaviour is enabled. Defaults to off.

Returns:
int; true (non-zero) if additional dialect specific text is to be displayed (this is the default), false (zero) if it is not to be dislayed.

Definition at line 249 of file option.c.

The explain_option_dialect_specific function may be used to obtain the EXPLAIN_OPTIONS (no-)dialect-specific flag, used to control whether or not informative text that is specific to a given UNIX dialect is to be displayed. This is commonly turned off for the test suite.

Returns:
int; true (non-zero) if additional dialect specific text is to be displayed (this is the default), false (zero) if it is not to be dislayed.

Definition at line 267 of file option.c.

Definition at line 374 of file option.c.

int explain_option_hanging_indent ( int  width)

The explain_option_hanging_indent function may be used to obtain the "hanging-indent" option value.

Parameters:
widthThe width of the output line. The hanging indent must be less than 10% of this.

Definition at line 339 of file option.c.

The explain_option_internal_strerror function may be used to obtain the "(no-)internal-strerror" flag. Defaults to false, meaning use the system strerror. Useful for avoiding false negatives in the automatic test suite.

Returns:
true (non-zero) if are to use internal strerror strings, false (zero) if are to use system strerror.

Definition at line 330 of file option.c.

The explain_option_numeric_errno function may be used to obtain the EXPLAIN_OPTIONS (no-)numeric-errno flag, used to control whether or not the numeric value of errno is displayed. This is commonly turned off for the test suite, to cope with capricious errno numbering on different UNIX dialects.

Returns:
int; true (non-zero) if numeric errno values are to be displayed (this is the default), false (zero) if they are not to be dislayed.

Definition at line 258 of file option.c.

The explain_option_symbolic_mode_bits function may be used to obtain the EXPLAIN_OPTIONS (no-)symbolic-mode-bits flag, used to control whether or not symbolic mode bits are to be used. Default to false, meaning print octal mode bits.

Returns:
true (non-zero) if symbolic mode bits are to be printed (e.g. S_IRUSR), false (zero) if octal mode bits are to be printed.

Definition at line 321 of file option.c.