| Home | Libraries | People | FAQ | More

#### basic_format_context

(EXPERIMENTAL) Format context for incremental SQL formatting.

##### Synopsis

Defined in header `<boost/mysql/format_sql.hpp>`

    template<
        class OutputString>
    class basic_format_context :
        public format_context_base

##### Member Functions

Name | Description
--- | ---
add_error | Adds an error to the current error state.
append_raw | Adds raw SQL to the output string.
append_value | Formats a value and adds it to the output string.
basic_format_context [constructor] | Constructor. — Move constructor.
error_state | Retrieves the current error state.
format_opts | Retrieves the format options.
get | Retrieves the result of the formatting operation.
operator= | Move assignment.

##### Description

The primary interface for incremental SQL formatting. Contrary to `format_context_base`, this type is aware of the output string's actual type. `basic_format_context` owns an instance of `OutputString`. Format operations will append characters to such string.

Objects of this type are single-use: once the result has been retrieved using `get`, they cannot be re-used. This is a move-only type.

Convenience header `<boost/mysql.hpp>`