diff --git a/README_SETUP.md b/README_SETUP.md index 147745c32ad3d1460609e91942e4b7400b243560..f73190cad3386518361a9d76dac2f1825d5f3f28 100644 --- a/README_SETUP.md +++ b/README_SETUP.md @@ -77,6 +77,8 @@ For the tests there is a slightly different setup required (with option `-D CMAK 1. `mkdir build && cd build/` 2. `conan install .. -s "compiler.libcxx=libstdc++11"` 3. `cmake -B . -D CMAKE_BUILD_TYPE=Debug ..` + * If your clang-format version is too old, formatting, linting etc. can be skipped: + `cmake -B . -D CMAKE_BUILD_TYPE=Debug -D SKIP_LINTING=ON ..` 4. `cmake --build .` ### Run diff --git a/include/caosdb/entity.h b/include/caosdb/entity.h index a96126e1b705ff741527d77fd285946395487299..8d3aeb9e4e489d9de73ebba6911c55b7b3e690bd 100644 --- a/include/caosdb/entity.h +++ b/include/caosdb/entity.h @@ -558,6 +558,16 @@ private: * Container for Properties of Entities. * * Should only be instantiated and write-accessed by the owning entity. + * + * Note that iterating over the Property contents only works via references, since the Property copy + * constructor is deliberately disabled: + * + * \code + * // Accessing single properties as reference + * auto &property = my_properties.at(0); + * // Iterating via reference + * for (auto &property : my_properties) {...} + * \endcode */ class Properties : public RepeatedPtrFieldWrapper<Property,