libpqxx
The C++ client library for PostgreSQL
connection-string.hxx
Go to the documentation of this file.
1 #ifndef PQXX_INTERNAL_CONNECTION_STRING_HXX
2 #define PQXX_INTERNAL_CONNECTION_STRING_HXX
3 
4 namespace pqxx::internal
5 {
7 
11 {
12 public:
13  explicit connection_string_parser(
14  char const connection_string[], sl = sl::current());
21 
23 
25 
38  [[nodiscard]] std::array<std::vector<char const *>, 2u> parse() const;
39 
40 private:
41  using opts_pointer = std::unique_ptr<
42  pqxx::internal::pq::PQconninfoOption,
43  void (*)(pqxx::internal::pq::PQconninfoOption *)>;
44  opts_pointer m_options;
45 };
46 } // namespace pqxx::internal
47 
48 #endif
An SQL array received from the database.
Definition: array.hxx:57
Parse a connection string into option keys and their values.
Definition: connection-string.hxx:11
connection_string_parser(connection_string_parser &&)=default
connection_string_parser & operator=(connection_string_parser const &)=delete
connection_string_parser & operator=(connection_string_parser &&)=default
connection_string_parser(connection_string_parser const &)=delete
#define PQXX_LIBEXPORT
Definition: header-pre.hxx:206
void PQconninfoOption
Placeholder for libpq's PQconninfoOption type.
Definition: types.hxx:437
Private namespace for libpqxx's internal use; do not access.
Definition: connection.cxx:333
The home of all libpqxx classes, functions, templates, etc.
Definition: array.cxx:26
std::source_location sl
Convenience alias for std::source_location. It's just too long.
Definition: types.hxx:38