Skip to content
Snippets Groups Projects
Commit 85bc73d7 authored by Daniel Hornung's avatar Daniel Hornung
Browse files

STY: Style changes.

parent 2981cd26
Branches
Tags
No related merge requests found
Pipeline #12622 passed
Pipeline: caosdb-cppinttest

#12623

    ...@@ -110,7 +110,8 @@ inline auto get_env_fallback(const char *key, const char *fallback) -> const cha ...@@ -110,7 +110,8 @@ inline auto get_env_fallback(const char *key, const char *fallback) -> const cha
    * @brief Return the value of an environment variable or - if undefined - the * @brief Return the value of an environment variable or - if undefined - the
    * fallback value. * fallback value.
    */ */
    inline auto get_env_fallback(const std::string &key, const std::string &fallback) -> const std::string { inline auto get_env_fallback(const std::string &key, const std::string &fallback)
    -> const std::string {
    const char *val = get_env_fallback(key.c_str(), fallback.c_str()); const char *val = get_env_fallback(key.c_str(), fallback.c_str());
    auto const result = std::string(val); auto const result = std::string(val);
    ......
    ...@@ -273,7 +273,7 @@ auto Entity::FixValue() -> void { FixValueImpl(this); } ...@@ -273,7 +273,7 @@ auto Entity::FixValue() -> void { FixValueImpl(this); }
    // Utility functions ////////////////////////////////////////////////////////// // Utility functions //////////////////////////////////////////////////////////
    // TODO(daniel) cognitive complexity is too high // TODO(daniel) cognitive complexity is too high
    template <typename E> auto FixValueImpl(E *ent) -> void { //NOLINT template <typename E> auto FixValueImpl(E *ent) -> void { // NOLINT
    const auto &dtype = ent->GetDataType(); const auto &dtype = ent->GetDataType();
    const auto &value = ent->GetValue(); const auto &value = ent->GetValue();
    auto new_value = Value(); auto new_value = Value();
    ......
    ...@@ -26,13 +26,13 @@ ...@@ -26,13 +26,13 @@
    #include "caosdb/entity.h" // for Entity #include "caosdb/entity.h" // for Entity
    #include "caosdb/exceptions.h" // for ConfigurationError #include "caosdb/exceptions.h" // for ConfigurationError
    #include "caosdb/info.h" // for VersionInfo #include "caosdb/info.h" // for VersionInfo
    #include "caosdb/logging.h" // for CAOSDB_LOG_TRACE #include "caosdb/logging.h" // for CAOSDB_LOG_TRACE
    #include "caosdb/transaction.h" // for Transaction, ResultSet #include "caosdb/transaction.h" // for Transaction, ResultSet
    #include <iostream> // for operator<<, basic_ostream, basic_ost... #include <iostream> // for operator<<, basic_ostream, basic_ost...
    #include <memory> // for unique_ptr, allocator, __shared_ptr_... #include <memory> // for unique_ptr, allocator, __shared_ptr_...
    #include <string> // for operator<<, char_traits #include <string> // for operator<<, char_traits
    auto logger_name = "libcaosdb"; const auto logger_name = "libcaosdb";
    auto main() -> int { auto main() -> int {
    ...@@ -56,8 +56,8 @@ auto main() -> int { ...@@ -56,8 +56,8 @@ auto main() -> int {
    transaction->RetrieveById("120"); transaction->RetrieveById("120");
    transaction->ExecuteAsynchronously(); transaction->ExecuteAsynchronously();
    auto t_stat = transaction->WaitForIt(); auto t_stat = transaction->WaitForIt();
    CAOSDB_LOG_INFO(logger_name) << "status: " << t_stat.GetCode() CAOSDB_LOG_INFO(logger_name) << "status: " << t_stat.GetCode() << " // "
    << " // " << t_stat.GetDescription(); << t_stat.GetDescription();
    const auto &result_set = transaction->GetResultSet(); const auto &result_set = transaction->GetResultSet();
    if (result_set.size() > 0) { if (result_set.size() > 0) {
    // print information // print information
    ...@@ -80,8 +80,8 @@ auto main() -> int { ...@@ -80,8 +80,8 @@ auto main() -> int {
    q_transaction->Query(query); q_transaction->Query(query);
    q_transaction->ExecuteAsynchronously(); q_transaction->ExecuteAsynchronously();
    t_stat = q_transaction->WaitForIt(); t_stat = q_transaction->WaitForIt();
    CAOSDB_LOG_INFO(logger_name) << "status: " << t_stat.GetCode() CAOSDB_LOG_INFO(logger_name) << "status: " << t_stat.GetCode() << " // "
    << " // " << t_stat.GetDescription(); << t_stat.GetDescription();
    return 0; return 0;
    } catch (const caosdb::exceptions::ConfigurationError &exc) { } catch (const caosdb::exceptions::ConfigurationError &exc) {
    std::cout << "ConfigurationError: " << exc.what() << std::endl; std::cout << "ConfigurationError: " << exc.what() << std::endl;
    ......
    0% Loading or .
    You are about to add 0 people to the discussion. Proceed with caution.
    Please register or to comment