From 4ae3d35f2fd29c4836b69a6e9fff2d14ad122dee Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Thu, 26 Sep 2024 21:17:51 +0300 Subject: [PATCH 01/41] minor modules updates --- src/extensions/rppasio/rppasio/fwd.hpp | 7 +------ src/extensions/rppgrpc/rppgrpc/client_reactor.hpp | 3 +++ src/extensions/rppgrpc/rppgrpc/fwd.hpp | 2 +- src/extensions/rppgrpc/rppgrpc/server_reactor.hpp | 3 +++ src/extensions/rppqt/rppqt/fwd.hpp | 8 +------- src/rpp/rpp/fwd.hpp | 4 ++-- 6 files changed, 11 insertions(+), 16 deletions(-) diff --git a/src/extensions/rppasio/rppasio/fwd.hpp b/src/extensions/rppasio/rppasio/fwd.hpp index 047846684..7d2cc2e93 100644 --- a/src/extensions/rppasio/rppasio/fwd.hpp +++ b/src/extensions/rppasio/rppasio/fwd.hpp @@ -11,13 +11,8 @@ #pragma once /** - * @defgroup rppasio RPPASIO + * @defgroup rppasio rppasio * @brief RppAsio is extension of RPP which enables support of boost-asio library. */ - -/** - * @defgroup asio_schedulers Asio Schedulers - * @ingroup rppasio - */ #include diff --git a/src/extensions/rppgrpc/rppgrpc/client_reactor.hpp b/src/extensions/rppgrpc/rppgrpc/client_reactor.hpp index 2e1ff1cfc..a2e136b25 100644 --- a/src/extensions/rppgrpc/rppgrpc/client_reactor.hpp +++ b/src/extensions/rppgrpc/rppgrpc/client_reactor.hpp @@ -29,6 +29,7 @@ namespace rppgrpc * - to pass values TO stream you can emit values to observer obtained via `reactor->get_observer()` * * @snippet client_reactor.cpp bidi_reactor + * @ingroup rppgrpc * */ template @@ -103,6 +104,7 @@ namespace rppgrpc * - reactor provides `reactor->get_observable()` method but such as observable emits nothing and can be used only to be notified about completion/error * * @snippet client_reactor.cpp write_reactor + * @ingroup rppgrpc * */ template @@ -166,6 +168,7 @@ namespace rppgrpc * - to access values FROM stream you can subscribe to observable obtained via `reactor->get_observable()` (same observable WOULD emit on_completed in case of successful stream termination and on_error in case of some errors with grpc stream) * * @snippet client_reactor.cpp read_reactor + * @ingroup rppgrpc * */ template diff --git a/src/extensions/rppgrpc/rppgrpc/fwd.hpp b/src/extensions/rppgrpc/rppgrpc/fwd.hpp index 4f1114a43..7e89807d5 100644 --- a/src/extensions/rppgrpc/rppgrpc/fwd.hpp +++ b/src/extensions/rppgrpc/rppgrpc/fwd.hpp @@ -13,7 +13,7 @@ #include /** - * @defgroup rppgrpc RPPGRPC + * @defgroup rppgrpc rppgrpc * @brief RppGrpc is extension of RPP which enables support of grpc library. */ diff --git a/src/extensions/rppgrpc/rppgrpc/server_reactor.hpp b/src/extensions/rppgrpc/rppgrpc/server_reactor.hpp index 392d8aae1..3fc8bca29 100644 --- a/src/extensions/rppgrpc/rppgrpc/server_reactor.hpp +++ b/src/extensions/rppgrpc/rppgrpc/server_reactor.hpp @@ -30,6 +30,7 @@ namespace rppgrpc * @warning grpc server reactor have to finish manually, so it is expected that you call `on_completed()` on reactor->get_observer() * * @snippet server_reactor.cpp bidi_reactor + * @ingroup rppgrpc * */ template @@ -107,6 +108,7 @@ namespace rppgrpc * - to pass values TO stream you can emit values to observer obtained via `reactor->get_observer()` * * @snippet server_reactor.cpp write_reactor + * @ingroup rppgrpc * */ template @@ -174,6 +176,7 @@ namespace rppgrpc * - to access values FROM stream you can subscribe to observable obtained via `reactor->get_observable()` (same observable WOULD emit on_completed in case of successful stream termination and on_error in case of some errors with grpc stream) * * @snippet server_reactor.cpp read_reactor + * @ingroup rppgrpc * */ template diff --git a/src/extensions/rppqt/rppqt/fwd.hpp b/src/extensions/rppqt/rppqt/fwd.hpp index 586f7bf81..af9c6bdc5 100644 --- a/src/extensions/rppqt/rppqt/fwd.hpp +++ b/src/extensions/rppqt/rppqt/fwd.hpp @@ -11,7 +11,7 @@ #pragma once /** - * @defgroup rppqt RPPQT + * @defgroup rppqt rppqt * @brief RppQt is extension of RPP which enables support of Qt library. */ @@ -23,10 +23,4 @@ #include -/** - * @defgroup schedulers Schedulers - * @brief Scheduler is the way to introduce multi-threading in your application via RPP - * @see https://reactivex.io/documentation/scheduler.html - * @ingroup rpp - */ #include diff --git a/src/rpp/rpp/fwd.hpp b/src/rpp/rpp/fwd.hpp index 03a2f3c46..b0583a538 100644 --- a/src/rpp/rpp/fwd.hpp +++ b/src/rpp/rpp/fwd.hpp @@ -11,8 +11,8 @@ #pragma once /** - * @defgroup rpp RPP - * @brief ReactivePlusPlus (RPP) is Reactive extension for C++20 + * @defgroup rpp rpp + * @brief ReactivePlusPlus (rpp) is Reactive extension for C++20 */ #include From 2a9eee6f44e806f61cd6326ad30e9041f92b4fce Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Thu, 26 Sep 2024 21:55:04 +0300 Subject: [PATCH 02/41] actualize a bit --- Doxyfile | 8 ++++---- .../rpp/doxygen/{start_wih.cpp => start_with.cpp} | 0 src/rpp/rpp/observables/observable.hpp | 8 ++++++++ 3 files changed, 12 insertions(+), 4 deletions(-) rename src/examples/rpp/doxygen/{start_wih.cpp => start_with.cpp} (100%) diff --git a/Doxyfile b/Doxyfile index 393db99f7..edd9689a7 100644 --- a/Doxyfile +++ b/Doxyfile @@ -852,7 +852,7 @@ WARNINGS = YES # will automatically be disabled. # The default value is: YES. -WARN_IF_UNDOCUMENTED = YES +WARN_IF_UNDOCUMENTED = NO # If the WARN_IF_DOC_ERROR tag is set to YES, doxygen will generate warnings for # potential errors in the documentation, such as documenting some parameters in @@ -1139,7 +1139,7 @@ INPUT_FILTER = # need to set EXTENSION_MAPPING for the extension otherwise the files are not # properly processed by doxygen. -FILTER_PATTERNS = "*.hpp=python ./ci/generate_marbles.py" +FILTER_PATTERNS = "*.hpp=python3 ./ci/generate_marbles.py" # If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using # INPUT_FILTER) will also be used to filter the input files that are used for @@ -1931,7 +1931,7 @@ EXTRA_SEARCH_MAPPINGS = # If the GENERATE_LATEX tag is set to YES, doxygen will generate LaTeX output. # The default value is: YES. -GENERATE_LATEX = YES +GENERATE_LATEX = NO # The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. If a # relative path is entered the value of OUTPUT_DIRECTORY will be put in front of @@ -2067,7 +2067,7 @@ PDF_HYPERLINKS = YES # The default value is: YES. # This tag requires that the tag GENERATE_LATEX is set to YES. -USE_PDFLATEX = YES +USE_PDFLATEX = NO # The LATEX_BATCHMODE tag signals the behavior of LaTeX in case of an error. # Possible values are: NO same as ERROR_STOP, YES same as BATCH, BATCH In batch diff --git a/src/examples/rpp/doxygen/start_wih.cpp b/src/examples/rpp/doxygen/start_with.cpp similarity index 100% rename from src/examples/rpp/doxygen/start_wih.cpp rename to src/examples/rpp/doxygen/start_with.cpp diff --git a/src/rpp/rpp/observables/observable.hpp b/src/rpp/rpp/observables/observable.hpp index 19bc89521..5944ffbd5 100644 --- a/src/rpp/rpp/observables/observable.hpp +++ b/src/rpp/rpp/observables/observable.hpp @@ -89,6 +89,7 @@ namespace rpp * @warning This overloading has some performance penalties, use it only when you really need to use disposable * * @param d is disposable to be attached to observer. If disposable is nullptr or disposed -> no any subscription happens + * @param obs is observer to subscribe to this observable * @return composite_disposable_wrapper is disposable to be able to dispose observer when it needed * * @par Example @@ -119,6 +120,7 @@ namespace rpp * @warning This overloading has some performance penalties, use it only when you really need to use disposable * * @param d is disposable to be attached to observer. If disposable is nullptr or disposed -> no any subscription happens + * @param observer_strategy is strategy to create observer to subscribe to this observable * @return composite_disposable_wrapper is disposable to be able to dispose observer when it needed */ template ObserverStrategy> @@ -242,6 +244,9 @@ namespace rpp * @warning This overloading has some performance penalties, use it only when you really need to use disposable * * @param d is disposable to be attached to observer. If disposable is nullptr or disposed -> no any subscription happens + * @param on_next is callback to handle values from this observable + * @param on_error is callback to handle error from this observable + * @param on_completed is callback to handle completion of this observable * @return composite_disposable_wrapper is disposable to be able to dispose observer when it needed * * @par Example @@ -277,6 +282,9 @@ namespace rpp * @warning This overloading has some performance penalties, use it only when you really need to use disposable * * @param d is disposable to be attached to observer. If disposable is nullptr or disposed -> no any subscription happens + * @param on_next is callback to handle values from this observable + * @param on_completed is callback to handle completion of this observable + * * @return composite_disposable_wrapper is disposable to be able to dispose observer when it needed * * @par Example From d7c9c54d17339afe73689b1ecf3d994c8177a76a Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Thu, 26 Sep 2024 22:13:15 +0300 Subject: [PATCH 03/41] exclude build --- Doxyfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doxyfile b/Doxyfile index edd9689a7..6993c9a05 100644 --- a/Doxyfile +++ b/Doxyfile @@ -1048,7 +1048,7 @@ RECURSIVE = YES # Note that relative paths are relative to the directory from which doxygen is # run. -EXCLUDE = src/rpp/rpp/utils +EXCLUDE = build # The EXCLUDE_SYMLINKS tag can be used to select whether or not files or # directories that are symbolic links (a Unix file system feature) are excluded From 0a9b34977c4641447885875e2debddbe5814988f Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Fri, 27 Sep 2024 23:27:58 +0300 Subject: [PATCH 04/41] missing images --- src/rpp/rpp/operators/on_error_resume_next.hpp | 2 +- src/rpp/rpp/operators/retry.hpp | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/rpp/rpp/operators/on_error_resume_next.hpp b/src/rpp/rpp/operators/on_error_resume_next.hpp index 23d1c820b..8a4e3bb69 100644 --- a/src/rpp/rpp/operators/on_error_resume_next.hpp +++ b/src/rpp/rpp/operators/on_error_resume_next.hpp @@ -124,7 +124,7 @@ namespace rpp::operators * * @marble on_error_resume_next { - source observable : +-1-x + source observable : +-1-# operator "on_error_resume_next: () => obs(-2-3-|)" : +-1-2-3-| } * diff --git a/src/rpp/rpp/operators/retry.hpp b/src/rpp/rpp/operators/retry.hpp index 037ac7fb7..237267922 100644 --- a/src/rpp/rpp/operators/retry.hpp +++ b/src/rpp/rpp/operators/retry.hpp @@ -139,8 +139,8 @@ namespace rpp::operators * * @marble retry { - source observable : +-1-x - operator "retry:(2)" : +-1-1-1-x + source observable : +-1-# + operator "retry:(2)" : +-1-1-1-# } * * @param count is the number of retries @@ -163,7 +163,7 @@ namespace rpp::operators * * @marble infinite_retry { - source observable : +-1-x + source observable : +-1-# operator "retry:()" : +-1-1-1-1-1-1-1-1-1-1-1-> } * From 486bf1c6aacc83e684a9a03a47a0c6916d4620bc Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sun, 29 Sep 2024 19:16:51 +0000 Subject: [PATCH 05/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/extensions/rppqt/rppqt/fwd.hpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/extensions/rppqt/rppqt/fwd.hpp b/src/extensions/rppqt/rppqt/fwd.hpp index af9c6bdc5..8123def06 100644 --- a/src/extensions/rppqt/rppqt/fwd.hpp +++ b/src/extensions/rppqt/rppqt/fwd.hpp @@ -21,6 +21,5 @@ * @ingroup rppqt */ -#include - #include +#include From a74eec43754439d5ecdfa9ac6b55990b425ff459 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Mon, 30 Sep 2024 22:50:56 +0300 Subject: [PATCH 06/41] readme --- Readme.md | 27 ++++++--------------------- 1 file changed, 6 insertions(+), 21 deletions(-) diff --git a/Readme.md b/Readme.md index 99f3a3396..579044c9e 100644 --- a/Readme.md +++ b/Readme.md @@ -34,7 +34,7 @@ rpp::source::from_callable(&::getchar) ``` [Try it on godbolt!](https://godbolt.org/#g:!((g:!((g:!((h:codeEditor,i:(filename:'1',fontScale:14,fontUsePx:'0',j:1,lang:c%2B%2B,selection:(endColumn:65,endLineNumber:12,positionColumn:1,positionLineNumber:8,selectionStartColumn:65,selectionStartLineNumber:12,startColumn:1,startLineNumber:8),source:'%23include+%3Crpp/rpp.hpp%3E%0A%23include+%3Ciostream%3E%0A%23include+%3Cfunctional%3E%0A%0Aint+main()%0A%7B%0A++++rpp::source::from_callable(%26::getchar)%0A++++%7C+rpp::operators::repeat()%0A++++%7C+rpp::operators::take_while(%5B%5D(char+v)+%7B+return+v+!!%3D+!'0!'%3B+%7D)%0A++++%7C+rpp::operators::filter(std::not_fn(%26::isdigit))%0A++++%7C+rpp::operators::map(%26::toupper)%0A++++%7C+rpp::operators::subscribe(%5B%5D(char+v)+%7B+std::cout+%3C%3C+v%3B+%7D)%3B%0A++++return+0%3B%0A%7D'),l:'5',n:'1',o:'C%2B%2B+source+%231',t:'0')),k:60.849967804249836,l:'4',m:100,n:'0',o:'',s:0,t:'0'),(g:!((h:executor,i:(argsPanelShown:'1',compilationPanelShown:'0',compiler:g132,compilerName:'',compilerOutShown:'0',execArgs:'',execStdin:'He11lLo+%23@!!$+W%23oRl@123d+!!0001123W',fontScale:14,fontUsePx:'0',j:1,lang:c%2B%2B,libs:!((name:reactive_plus_plus,ver:v2)),options:'-std%3Dc%2B%2B20',overrides:!(),runtimeTools:!(),source:1,stdinPanelShown:'0',wrap:'1'),l:'5',n:'0',o:'Executor+x86-64+gcc+13.2+(C%2B%2B,+Editor+%231)',t:'0')),header:(),k:39.150032195750164,l:'4',n:'0',o:'',s:0,t:'0')),l:'2',n:'0',o:'',t:'0')),version:4) -There we are creating observable (soure of emissions/values/data) to emit value via invoking of `getchar` function, `repeat`-ing it infinite amount of time till termination event happening. It emits values while symbol is not equal to `0`, takeing only **not** digits, maping them to upper case and then just printing to console. +There we are creating observable (soure of emissions/values/data) to emit value via invoking of `getchar` function, `repeat`-ing it infinite amount of time till termination event happening. It emits values while symbol is not equal to `0`, taking only **not** digits, maping them to upper case and then just printing to console. Also RPP supports QT out of box. Checkout [RPPQT reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppqt.html). For example: @@ -55,15 +55,11 @@ rppqt::source::from_signal(*button, &QPushButton::clicked); // <------ react on ## What about existing Reactive Extension libraries for C++? -Reactive programming is excelent programming paradigm and approach for creation of multi-threading and real-time programs which reacts on some events. Unfortunately, there is only one stable and fully-implemented library at the moment of creation of ReactivePlusPlus - [RxCpp](https://github.com/ReactiveX/RxCpp). +Reactive programming is a powerful paradigm for creating multi-threaded and real-time applications. Unfortunately, at the moment of creating ReactivePlusPlus, there is only one stable and fully-implemented library available - [RxCpp](https://github.com/ReactiveX/RxCpp). -[RxCpp](https://github.com/ReactiveX/RxCpp) is great and awesome library and perfect implementation of ReactiveX approach. However RxCpp has some disadvantages: -- It is a bit **"old" library written in C++11** with some parts written in the **pre-C++11 style** (mess of old-style classes and wrappers) -- **Issue** with **template parameters**: `rxcpp::observable` contains **full chain of operators** as second template parameter... where each operator has a bunch of another template parameters itself. It forces **IDEs** works **slower** while parsing resulting type of observable. Also it forces to generate **heavier binaries and debug symbols and slower build time**. -- It has high perfomance cost due to tremendous amount of usage of heap. -- Some parts of code written with non-effective logic +While RxCpp is a great and powerful library, it has some disadvantages. It is written in C++11 and contains parts written in pre-C++11 style. This leads to a mess of old-style classes and wrappers. Additionally, the `rxcpp::observable` type has a long chain of template parameters, which can lead to slower IDE performance and larger binaries. Sometimes it has bad perfomance due to tremendous amount of usage of heap or just non-effective logic. -Another implementation of RX for c++: [another-rxcpp](https://github.com/CODIANZ/another-rxcpp). It partly solves issues of RxCpp via **eliminating of template parameter** with help of **type-erasing** and making each callback as `std::function`. As a result issue with templates resvoled, but this approach has disadvantages related to runtime: resulting size of observers/observables becomes greater due to heavy `std::function` object, usage of heap for storing everything causes perfomance issues, implementation is just pretty simple and provides a lot of copies of passed objects. +Another implementation is [another-rxcpp](https://github.com/CODIANZ/another-rxcpp) which uses type erasure and `std::function`, but itt casues larger observer/observable size and potentially casues performance issues. ### Why ReactivePlusPlus? @@ -76,18 +72,7 @@ Another implementation of RX for c++: [another-rxcpp](https://github.com/CODIANZ Currently ReactivePlusPlus is still under development but it has a lot of implemented operators for now. List of implemented features can be found in [API Reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) with very detailed documentation for each of them. -Main advantages of ReactivePlusPlus are that it is written in Modern C++ with Performance and Usage in mind. v2 written to follow zero-overhead principle As a result it is fast, readable, easy to use and well-documented. And it is proven with [continous benchmarking results of v2 and comparison with RxCpp](https://victimsnino.github.io/ReactivePlusPlus/v2/benchmark) - -## Note about `v2`: -Currently I'm working on RPP v2 (`v2` branch). RPP v2 follows [**"zero-overhead principle"**](https://en.cppreference.com/w/cpp/language/Zero-overhead_principle) and most of the operators are (and will) minimize overhead. - -**How?** Due to elimination of heap allocations and avoiding unnecessary things. During implementatuon of `v1` I've found a lot of cases where RPP does unnecessary expensive things. As a result, `v2` does only required things and nothing else. - -For example, `v1`'s `create+map+subscribe` spends about `63.7768ns`, while `v2` is about `0.4ns`. - -v2 started from the scratch, so, each operator would be re-implemented from the scratch too. Implementation status can be tracked in [#324](https://github.com/victimsnino/ReactivePlusPlus/issues/324) - -You still can use previous implementation. It placed in `v1` branch +Main advantages of ReactivePlusPlus are that it is written in Modern C++ with Performance and Usage in mind. v2 written to follow [**"zero-overhead principle"**](https://en.cppreference.com/w/cpp/language/Zero-overhead_principle) As a result it is fast, readable, easy to use and well-documented. And it is proven with [continous benchmarking results of v2 and comparison with RxCpp](https://victimsnino.github.io/ReactivePlusPlus/v2/benchmark) ## Usage @@ -103,7 +88,7 @@ If you are going to know more details about developing for RPP check [HACKING](H ## Documentation: -Check [User Guide](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/md_docs_2readme.html) and [API Reference of RPP](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html). +Check [User Guide/Tutorial](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/md_docs_2readme.html) and [API Reference of RPP](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html). # Useful links From 9e060c6e0cf8815b0dcd8ec974511bf11511b148 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Mon, 30 Sep 2024 23:09:52 +0300 Subject: [PATCH 07/41] readme --- Readme.md | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/Readme.md b/Readme.md index 579044c9e..015783f09 100644 --- a/Readme.md +++ b/Readme.md @@ -1,16 +1,16 @@ -# ReactivePlusPlus -[![GitHub](https://img.shields.io/github/license/victimsnino/ReactivePlusPlus)](https://github.com/victimsnino/ReactivePlusPlus/blob/main/LICENSE) -[![C++20](https://img.shields.io/badge/C%2B%2B-20-green.svg)](https://isocpp.org/std/the-standard ) +# ReactivePlusPlus + [![CI v2](https://github.com/victimsnino/ReactivePlusPlus/actions/workflows/ci%20v2.yml/badge.svg?branch=v2)](https://github.com/victimsnino/ReactivePlusPlus/actions/workflows/ci%20v2.yml) [![codecov](https://codecov.io/gh/victimsnino/ReactivePlusPlus/branch/v2/graph/badge.svg?token=INEHPRF18E)](https://app.codecov.io/gh/victimsnino/ReactivePlusPlus/tree/v2) [![Lines of Code](https://sonarcloud.io/api/project_badges/measure?project=victimsnino_ReactivePlusPlus&metric=ncloc&branch=v2)](https://sonarcloud.io/summary/new_code?id=victimsnino_ReactivePlusPlus&branch=v2) [![Maintainability Rating](https://sonarcloud.io/api/project_badges/measure?project=victimsnino_ReactivePlusPlus&metric=sqale_rating&branch=v2)](https://sonarcloud.io/summary/new_code?id=victimsnino_ReactivePlusPlus&branch=v2) ![GitHub commit activity (v2)](https://img.shields.io/github/commit-activity/m/victimsnino/ReactivePlusPlus/v2) +[![User guide](https://img.shields.io/badge/link-User_guide-green)](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/md_docs_2readme.html) +[![API Reference](https://img.shields.io/badge/link-API_Reference-green)](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) +[![Benchmarks](https://img.shields.io/badge/link-Benchmarks-green)](https://victimsnino.github.io/ReactivePlusPlus/v2/benchmark) -[![Join the chat at https://gitter.im/ReactivePlusPlus/community](https://badges.gitter.im/ReactivePlusPlus/community.svg)](https://gitter.im/ReactivePlusPlus/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![Join the chat in Discord: https://discord.gg/KWMR3RNkVz](https://img.shields.io/badge/Discord-Chat!-brightgreen.svg)](https://discord.gg/KWMR3RNkVz) - [![Conan Center](https://img.shields.io/conan/v/reactiveplusplus)](https://conan.io/center/recipes/reactiveplusplus) ![Vcpkg Version](https://img.shields.io/vcpkg/v/reactiveplusplus) @@ -34,7 +34,9 @@ rpp::source::from_callable(&::getchar) ``` [Try it on godbolt!](https://godbolt.org/#g:!((g:!((g:!((h:codeEditor,i:(filename:'1',fontScale:14,fontUsePx:'0',j:1,lang:c%2B%2B,selection:(endColumn:65,endLineNumber:12,positionColumn:1,positionLineNumber:8,selectionStartColumn:65,selectionStartLineNumber:12,startColumn:1,startLineNumber:8),source:'%23include+%3Crpp/rpp.hpp%3E%0A%23include+%3Ciostream%3E%0A%23include+%3Cfunctional%3E%0A%0Aint+main()%0A%7B%0A++++rpp::source::from_callable(%26::getchar)%0A++++%7C+rpp::operators::repeat()%0A++++%7C+rpp::operators::take_while(%5B%5D(char+v)+%7B+return+v+!!%3D+!'0!'%3B+%7D)%0A++++%7C+rpp::operators::filter(std::not_fn(%26::isdigit))%0A++++%7C+rpp::operators::map(%26::toupper)%0A++++%7C+rpp::operators::subscribe(%5B%5D(char+v)+%7B+std::cout+%3C%3C+v%3B+%7D)%3B%0A++++return+0%3B%0A%7D'),l:'5',n:'1',o:'C%2B%2B+source+%231',t:'0')),k:60.849967804249836,l:'4',m:100,n:'0',o:'',s:0,t:'0'),(g:!((h:executor,i:(argsPanelShown:'1',compilationPanelShown:'0',compiler:g132,compilerName:'',compilerOutShown:'0',execArgs:'',execStdin:'He11lLo+%23@!!$+W%23oRl@123d+!!0001123W',fontScale:14,fontUsePx:'0',j:1,lang:c%2B%2B,libs:!((name:reactive_plus_plus,ver:v2)),options:'-std%3Dc%2B%2B20',overrides:!(),runtimeTools:!(),source:1,stdinPanelShown:'0',wrap:'1'),l:'5',n:'0',o:'Executor+x86-64+gcc+13.2+(C%2B%2B,+Editor+%231)',t:'0')),header:(),k:39.150032195750164,l:'4',n:'0',o:'',s:0,t:'0')),l:'2',n:'0',o:'',t:'0')),version:4) -There we are creating observable (soure of emissions/values/data) to emit value via invoking of `getchar` function, `repeat`-ing it infinite amount of time till termination event happening. It emits values while symbol is not equal to `0`, taking only **not** digits, maping them to upper case and then just printing to console. +> [!NOTE] +> +> There we are creating observable (soure of emissions/values/data) to emit value via invoking of `getchar` function, `repeat`-ing it infinite amount of time till termination event happening. It emits values while symbol is not equal to `0`, taking only **not** digits, maping them to upper case and then just printing to console. Also RPP supports QT out of box. Checkout [RPPQT reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppqt.html). For example: From 96d3e3cecff9db2a61ec0fce9ec6de61eef9c208 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 30 Sep 2024 20:09:48 +0000 Subject: [PATCH 08/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- Readme.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Readme.md b/Readme.md index 015783f09..113f81a8c 100644 --- a/Readme.md +++ b/Readme.md @@ -1,4 +1,4 @@ -# ReactivePlusPlus +# ReactivePlusPlus [![CI v2](https://github.com/victimsnino/ReactivePlusPlus/actions/workflows/ci%20v2.yml/badge.svg?branch=v2)](https://github.com/victimsnino/ReactivePlusPlus/actions/workflows/ci%20v2.yml) [![codecov](https://codecov.io/gh/victimsnino/ReactivePlusPlus/branch/v2/graph/badge.svg?token=INEHPRF18E)](https://app.codecov.io/gh/victimsnino/ReactivePlusPlus/tree/v2) @@ -35,7 +35,7 @@ rpp::source::from_callable(&::getchar) [Try it on godbolt!](https://godbolt.org/#g:!((g:!((g:!((h:codeEditor,i:(filename:'1',fontScale:14,fontUsePx:'0',j:1,lang:c%2B%2B,selection:(endColumn:65,endLineNumber:12,positionColumn:1,positionLineNumber:8,selectionStartColumn:65,selectionStartLineNumber:12,startColumn:1,startLineNumber:8),source:'%23include+%3Crpp/rpp.hpp%3E%0A%23include+%3Ciostream%3E%0A%23include+%3Cfunctional%3E%0A%0Aint+main()%0A%7B%0A++++rpp::source::from_callable(%26::getchar)%0A++++%7C+rpp::operators::repeat()%0A++++%7C+rpp::operators::take_while(%5B%5D(char+v)+%7B+return+v+!!%3D+!'0!'%3B+%7D)%0A++++%7C+rpp::operators::filter(std::not_fn(%26::isdigit))%0A++++%7C+rpp::operators::map(%26::toupper)%0A++++%7C+rpp::operators::subscribe(%5B%5D(char+v)+%7B+std::cout+%3C%3C+v%3B+%7D)%3B%0A++++return+0%3B%0A%7D'),l:'5',n:'1',o:'C%2B%2B+source+%231',t:'0')),k:60.849967804249836,l:'4',m:100,n:'0',o:'',s:0,t:'0'),(g:!((h:executor,i:(argsPanelShown:'1',compilationPanelShown:'0',compiler:g132,compilerName:'',compilerOutShown:'0',execArgs:'',execStdin:'He11lLo+%23@!!$+W%23oRl@123d+!!0001123W',fontScale:14,fontUsePx:'0',j:1,lang:c%2B%2B,libs:!((name:reactive_plus_plus,ver:v2)),options:'-std%3Dc%2B%2B20',overrides:!(),runtimeTools:!(),source:1,stdinPanelShown:'0',wrap:'1'),l:'5',n:'0',o:'Executor+x86-64+gcc+13.2+(C%2B%2B,+Editor+%231)',t:'0')),header:(),k:39.150032195750164,l:'4',n:'0',o:'',s:0,t:'0')),l:'2',n:'0',o:'',t:'0')),version:4) > [!NOTE] -> +> > There we are creating observable (soure of emissions/values/data) to emit value via invoking of `getchar` function, `repeat`-ing it infinite amount of time till termination event happening. It emits values while symbol is not equal to `0`, taking only **not** digits, maping them to upper case and then just printing to console. From daf677ec726a887c52292d1f97f218c4a57b6792 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 5 Oct 2024 21:07:42 +0300 Subject: [PATCH 09/41] Minor comments --- BUILDING.md | 22 ++++++++++------------ HACKING.md | 26 ++++---------------------- Readme.md | 13 +++++++------ 3 files changed, 21 insertions(+), 40 deletions(-) diff --git a/BUILDING.md b/BUILDING.md index 4b661b3b8..93637462a 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -30,12 +30,7 @@ But RPP is header-only library, so, without enabling any extra options is just c - `RPP_BUILD_GRPC_CODE` - (ON/OFF) build GRPC related code (examples/tests)(rppgrpc module doesn't require this one) (default OFF) - requires grpc++/protobuf to be installed - `RPP_BUILD_ASIO_CODE` - (ON/OFF) build RPPASIO related code (examples/tests)(rppasio module doesn't require this one) (default OFF) - requires asio to be installed -By default, it provides rpp and rppqt INTERFACE modules. - - +By default, it provides rpp, rppqt, rppgrpc INTERFACE modules. ## Install @@ -82,7 +77,8 @@ command of CMake: * Package name: `RPP` * Target names: - `RPP::rpp` - main rpp INTERFACE target - - `RPP::rppqt` - additional INTERFACE target to extend functionality for QT. rppqt doesn't include QT or even doesn't link with that. + - `RPP::rppqt` - additional INTERFACE target to extend functionality for QT. rppqt doesn't include QT or even doesn't link with that itself. + - `RPP::rppgrpc` - additional INTERFACE target to extend functionality for GRPC. rppgrpc doesn't include GRPC or even doesn't link with that itself. Example usage: @@ -90,10 +86,11 @@ Example usage: find_package(RPP REQUIRED) # Declare the imported target as a build requirement using PRIVATE, where # project_target is a target created in the consuming project -target_link_libraries( - project_target PRIVATE - RPP::rpp - RPP::rppqt +target_link_libraries(project_target + PRIVATE + RPP::rpp + RPP::rppqt + RPP::rppgrpc ) ``` @@ -103,7 +100,8 @@ To use ReactivePlusPlus in your code just do ```cpp #include ``` -to include whole library functionality and don't worry about includes. Also you can include only forwardings for everyting +to include whole library functionality and don't worry about includes. (same can be applied to rppgrpc or rppqt modules) +Also you can include only forwardings for everyting ```cpp #include ``` diff --git a/HACKING.md b/HACKING.md index e85482528..761fcf79c 100644 --- a/HACKING.md +++ b/HACKING.md @@ -41,7 +41,7 @@ the project: { "name": "dev", "binaryDir": "${sourceDir}/build", - "inherits": ["ci-"], + "inherits": [""], "cacheVariables": { "CMAKE_BUILD_TYPE" : "Release", "RPP_BUILD_EXAMPLES" : "ON" @@ -69,9 +69,8 @@ the project: } ``` -You should replace `` in your newly created presets file with the name of -the operating system you have, which may be `win64` or `unix`. You can see what -these correspond to in the [`CMakePresets.json`](CMakePresets.json) file. +You should replace `` in your newly created presets file with the name of +some base preset from [`CMakePresets.json`](CMakePresets.json) file. It is highly recommended to use `user-*` presets. `CMakeUserPresets.json` is also the perfect place in which you can put all sorts of things that you would otherwise want to pass to the configure command @@ -108,24 +107,7 @@ additional `-t ` flag: #### `coverage` Available if `RPP_ENABLE_COVERAGE` is enabled. This target processes the output of -the previously run tests when built with coverage configuration. The commands -this target runs can be found in the `COVERAGE_TRACE_COMMAND` and -`COVERAGE_HTML_COMMAND` cache variables. The trace command produces an info -file by default, which can be submitted to services with CI integration. The -HTML command uses the trace command's output to generate a HTML document to -`/coverage_html` by default. - +the previously run tests when built with coverage configuration. [1]: https://cmake.org/cmake/help/latest/manual/cmake-presets.7.html [2]: https://cmake.org/download/ diff --git a/Readme.md b/Readme.md index a537281fb..9686ffb3d 100644 --- a/Readme.md +++ b/Readme.md @@ -34,9 +34,10 @@ rpp::source::from_callable(&::getchar) ``` [Try it on godbolt!](https://godbolt.org/#g:!((g:!((g:!((h:codeEditor,i:(filename:'1',fontScale:14,fontUsePx:'0',j:1,lang:c%2B%2B,selection:(endColumn:65,endLineNumber:12,positionColumn:1,positionLineNumber:8,selectionStartColumn:65,selectionStartLineNumber:12,startColumn:1,startLineNumber:8),source:'%23include+%3Crpp/rpp.hpp%3E%0A%23include+%3Ciostream%3E%0A%23include+%3Cfunctional%3E%0A%0Aint+main()%0A%7B%0A++++rpp::source::from_callable(%26::getchar)%0A++++%7C+rpp::operators::repeat()%0A++++%7C+rpp::operators::take_while(%5B%5D(char+v)+%7B+return+v+!!%3D+!'0!'%3B+%7D)%0A++++%7C+rpp::operators::filter(std::not_fn(%26::isdigit))%0A++++%7C+rpp::operators::map(%26::toupper)%0A++++%7C+rpp::operators::subscribe(%5B%5D(char+v)+%7B+std::cout+%3C%3C+v%3B+%7D)%3B%0A++++return+0%3B%0A%7D'),l:'5',n:'1',o:'C%2B%2B+source+%231',t:'0')),k:60.849967804249836,l:'4',m:100,n:'0',o:'',s:0,t:'0'),(g:!((h:executor,i:(argsPanelShown:'1',compilationPanelShown:'0',compiler:g132,compilerName:'',compilerOutShown:'0',execArgs:'',execStdin:'He11lLo+%23@!!$+W%23oRl@123d+!!0001123W',fontScale:14,fontUsePx:'0',j:1,lang:c%2B%2B,libs:!((name:reactive_plus_plus,ver:v2)),options:'-std%3Dc%2B%2B20',overrides:!(),runtimeTools:!(),source:1,stdinPanelShown:'0',wrap:'1'),l:'5',n:'0',o:'Executor+x86-64+gcc+13.2+(C%2B%2B,+Editor+%231)',t:'0')),header:(),k:39.150032195750164,l:'4',n:'0',o:'',s:0,t:'0')),l:'2',n:'0',o:'',t:'0')),version:4) -> [!NOTE] -> -> There we are creating observable (soure of emissions/values/data) to emit value via invoking of `getchar` function, `repeat`-ing it infinite amount of time till termination event happening. It emits values while symbol is not equal to `0`, taking only **not** digits, maping them to upper case and then just printing to console. + +
Explanation +There we are creating observable (soure of emissions/values/data) to emit value via invoking of `getchar` function, `repeat`-ing it infinite amount of time till termination event happening. It emits values while symbol is not equal to `0`, taking only **not** digits, maping them to upper case and then just printing to console. +
Also RPP supports QT out of box. Checkout [RPPQT reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppqt.html). For example: @@ -90,10 +91,10 @@ If you are going to know more details about developing for RPP check [HACKING](H ## Documentation: -Check [User Guide/Tutorial](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/md_docs_2readme.html) and [API Reference of RPP](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html). +Check detailed [User Guide/Tutorial](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/md_docs_2readme.html) and extensive [API Reference of RPP](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html). -# Useful links +## Useful links - [User Guide](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/md_docs_2readme.html) - [API Reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) - [Examples](https://github.com/victimsnino/ReactivePlusPlus/tree/v2/src/examples) @@ -103,7 +104,7 @@ Check [User Guide/Tutorial](https://victimsnino.github.io/ReactivePlusPlus/v2/do - [BUILDING](BUILDING.md) - [CONTRIBUTING](CONTRIBUTING.md) -# Licensing +## Licensing Boost Software License - Version 1.0 - August 17th, 2003 From 8cfa267a572364f9e1d42137204cf80aa1eea8c2 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 5 Oct 2024 18:07:33 +0000 Subject: [PATCH 10/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- BUILDING.md | 2 +- HACKING.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BUILDING.md b/BUILDING.md index 93637462a..1d4a33ec6 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -86,7 +86,7 @@ Example usage: find_package(RPP REQUIRED) # Declare the imported target as a build requirement using PRIVATE, where # project_target is a target created in the consuming project -target_link_libraries(project_target +target_link_libraries(project_target PRIVATE RPP::rpp RPP::rppqt diff --git a/HACKING.md b/HACKING.md index 761fcf79c..8ad0ab4c7 100644 --- a/HACKING.md +++ b/HACKING.md @@ -107,7 +107,7 @@ additional `-t ` flag: #### `coverage` Available if `RPP_ENABLE_COVERAGE` is enabled. This target processes the output of -the previously run tests when built with coverage configuration. +the previously run tests when built with coverage configuration. [1]: https://cmake.org/cmake/help/latest/manual/cmake-presets.7.html [2]: https://cmake.org/download/ From a7900b779b4e2c41e3a22ac5e37bdb3799017206 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 5 Oct 2024 21:08:39 +0300 Subject: [PATCH 11/41] minor --- Readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Readme.md b/Readme.md index 9686ffb3d..9602ba5eb 100644 --- a/Readme.md +++ b/Readme.md @@ -91,7 +91,7 @@ If you are going to know more details about developing for RPP check [HACKING](H ## Documentation: -Check detailed [User Guide/Tutorial](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/md_docs_2readme.html) and extensive [API Reference of RPP](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html). +Check detailed [User Guide/Tutorial](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/md_docs_2readme.html) (to learn more details about ReactivePlusPlus or reactive programming paradigm itself) and extensive [API Reference of RPP](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) (to know how to apply ReactivePlusPlus properly). ## Useful links From 2904e05324261793b6739ad795db5c9926e08b24 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 5 Oct 2024 21:29:01 +0300 Subject: [PATCH 12/41] update doxygen itself a bit --- BUILDING.md | 4 +++- Doxyfile | 2 +- Readme.md | 18 ++++-------------- src/examples/rpp/doxygen/interval.cpp | 4 ++-- src/examples/rpp/doxygen/take_until.cpp | 4 ++-- .../rpp/disposables/interface_disposable.hpp | 4 ++-- src/rpp/rpp/observables/observable.hpp | 8 ++++---- src/rpp/rpp/observers/observer.hpp | 4 ++-- src/rpp/rpp/operators/buffer.hpp | 2 +- src/rpp/rpp/operators/combine_latest.hpp | 6 +++--- src/rpp/rpp/operators/concat.hpp | 2 +- src/rpp/rpp/operators/debounce.hpp | 2 +- src/rpp/rpp/operators/delay.hpp | 2 +- .../rpp/operators/distinct_until_changed.hpp | 2 +- src/rpp/rpp/operators/element_at.hpp | 2 +- src/rpp/rpp/operators/filter.hpp | 2 +- src/rpp/rpp/operators/finally.hpp | 2 +- src/rpp/rpp/operators/first.hpp | 2 +- src/rpp/rpp/operators/flat_map.hpp | 2 +- src/rpp/rpp/operators/group_by.hpp | 2 +- src/rpp/rpp/operators/last.hpp | 2 +- src/rpp/rpp/operators/map.hpp | 2 +- src/rpp/rpp/operators/merge.hpp | 8 ++++---- src/rpp/rpp/operators/multicast.hpp | 4 ++-- src/rpp/rpp/operators/observe_on.hpp | 2 +- src/rpp/rpp/operators/on_error_resume_next.hpp | 2 +- src/rpp/rpp/operators/publish.hpp | 2 +- src/rpp/rpp/operators/reduce.hpp | 4 ++-- src/rpp/rpp/operators/repeat.hpp | 4 ++-- src/rpp/rpp/operators/retry.hpp | 4 ++-- src/rpp/rpp/operators/retry_when.hpp | 2 +- src/rpp/rpp/operators/scan.hpp | 4 ++-- src/rpp/rpp/operators/skip.hpp | 2 +- src/rpp/rpp/operators/start_with.hpp | 6 +++--- src/rpp/rpp/operators/subscribe_on.hpp | 2 +- src/rpp/rpp/operators/switch_on_next.hpp | 2 +- src/rpp/rpp/operators/take.hpp | 2 +- src/rpp/rpp/operators/take_last.hpp | 2 +- src/rpp/rpp/operators/take_until.hpp | 2 +- src/rpp/rpp/operators/take_while.hpp | 2 +- src/rpp/rpp/operators/throttle.hpp | 2 +- src/rpp/rpp/operators/timeout.hpp | 4 ++-- src/rpp/rpp/operators/window.hpp | 2 +- src/rpp/rpp/operators/window_toggle.hpp | 2 +- src/rpp/rpp/operators/with_latest_from.hpp | 4 ++-- src/rpp/rpp/operators/zip.hpp | 4 ++-- src/rpp/rpp/sources/concat.hpp | 4 ++-- 47 files changed, 75 insertions(+), 83 deletions(-) diff --git a/BUILDING.md b/BUILDING.md index 1d4a33ec6..64f8f9f16 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -30,7 +30,7 @@ But RPP is header-only library, so, without enabling any extra options is just c - `RPP_BUILD_GRPC_CODE` - (ON/OFF) build GRPC related code (examples/tests)(rppgrpc module doesn't require this one) (default OFF) - requires grpc++/protobuf to be installed - `RPP_BUILD_ASIO_CODE` - (ON/OFF) build RPPASIO related code (examples/tests)(rppasio module doesn't require this one) (default OFF) - requires asio to be installed -By default, it provides rpp, rppqt, rppgrpc INTERFACE modules. +By default, it provides rpp, rppqt, rppgrpc, rppasio INTERFACE modules. ## Install @@ -78,6 +78,7 @@ command of CMake: * Target names: - `RPP::rpp` - main rpp INTERFACE target - `RPP::rppqt` - additional INTERFACE target to extend functionality for QT. rppqt doesn't include QT or even doesn't link with that itself. + - `RPP::rppasio` - additional INTERFACE target to extend functionality for ASIO. rppasio doesn't include boost::asio or even doesn't link with that itself. - `RPP::rppgrpc` - additional INTERFACE target to extend functionality for GRPC. rppgrpc doesn't include GRPC or even doesn't link with that itself. Example usage: @@ -90,6 +91,7 @@ target_link_libraries(project_target PRIVATE RPP::rpp RPP::rppqt + RPP::rppasio RPP::rppgrpc ) ``` diff --git a/Doxyfile b/Doxyfile index 6993c9a05..60927ad25 100644 --- a/Doxyfile +++ b/Doxyfile @@ -867,7 +867,7 @@ WARN_IF_DOC_ERROR = YES # parameters have no documentation without warning. # The default value is: YES. -WARN_IF_INCOMPLETE_DOC = YES +WARN_IF_INCOMPLETE_DOC = NO # This WARN_NO_PARAMDOC option can be enabled to get warnings for functions that # are documented, but have no documentation for their parameters or return diff --git a/Readme.md b/Readme.md index 9602ba5eb..1fd7f11c8 100644 --- a/Readme.md +++ b/Readme.md @@ -40,20 +40,10 @@ There we are creating observable (soure of emissions/values/data) to emit value -Also RPP supports QT out of box. Checkout [RPPQT reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppqt.html). For example: -```cpp -auto button = new QPushButton("Click me!"); -auto label = new QLabel(); -rppqt::source::from_signal(*button, &QPushButton::clicked); // <------ react on signals - | rpp::operators::observe_on(rpp::schedulers::new_thread{}) - // some heavy job - // ..... - | rpp::operators::scan(0, [](int seed, auto) { return ++seed; }) - | rpp::operators::observe_on(rppqt::schedulers::main_thread_scheduler{}) // <--- go back to main QT scheduler - | rpp::operators::subscribe([&clicks_count_label](int clicks) - { - clicks_count_label->setText(QString{"Clicked %1 times in total!"}.arg(clicks)); - }); +Also RPP supports out of box: +- QT as rppqt module. Checkout [RPPQT reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppqt.html). +- GRPC as rppgrpc module. Checkout [RPPGRPC reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppgrpc.html). +- boost::asio as rppasio module. Checkout [RPPASIO reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppasio.html). ``` ## What about existing Reactive Extension libraries for C++? diff --git a/src/examples/rpp/doxygen/interval.cpp b/src/examples/rpp/doxygen/interval.cpp index e0a61fd75..89cb5ab90 100644 --- a/src/examples/rpp/doxygen/interval.cpp +++ b/src/examples/rpp/doxygen/interval.cpp @@ -21,7 +21,7 @@ int main() // NOLINT(bugprone-exception-escape) // emit 2 duration since start 10ms // emit 3 duration since start 20ms // On complete - //! [defer from_iterable] + //! [interval period] //! [interval initial+period] rpp::source::interval(std::chrono::milliseconds(5), std::chrono::milliseconds(10), rpp::schedulers::immediate{}) @@ -35,5 +35,5 @@ int main() // NOLINT(bugprone-exception-escape) // emit 2 duration since start 15ms // emit 3 duration since start 25ms // On complete - //! [defer from_iterable] + //! [interval initial+period] } diff --git a/src/examples/rpp/doxygen/take_until.cpp b/src/examples/rpp/doxygen/take_until.cpp index 390c3d0b6..77eebe6f7 100644 --- a/src/examples/rpp/doxygen/take_until.cpp +++ b/src/examples/rpp/doxygen/take_until.cpp @@ -19,7 +19,7 @@ int main() // Output : -0-1-2-3-| //! [take_until] - //! [take_until terminate] + //! [terminate] rpp::source::never() | rpp::ops::take_until(rpp::source::error(std::make_exception_ptr(std::runtime_error{""}))) | rpp::ops::subscribe([](int v) { std::cout << "-" << v; }, @@ -28,6 +28,6 @@ int main() // source 1: - // source 2: -x // Output : -x - //! [take_until terminate] + //! [terminate] return 0; } diff --git a/src/rpp/rpp/disposables/interface_disposable.hpp b/src/rpp/rpp/disposables/interface_disposable.hpp index 467746e4f..c49570381 100644 --- a/src/rpp/rpp/disposables/interface_disposable.hpp +++ b/src/rpp/rpp/disposables/interface_disposable.hpp @@ -25,13 +25,13 @@ namespace rpp /** * @brief Check if this disposable is just disposed - * @warning This function must be thread-safe + * @attention This function must be thread-safe */ virtual bool is_disposed() const noexcept = 0; /** * @brief Dispose disposable and free any underlying resources and etc. - * @warning This function must be thread-safe + * @attention This function must be thread-safe */ void dispose() noexcept { dispose_impl(Mode::Disposing); } diff --git a/src/rpp/rpp/observables/observable.hpp b/src/rpp/rpp/observables/observable.hpp index 5944ffbd5..2f12ebfb7 100644 --- a/src/rpp/rpp/observables/observable.hpp +++ b/src/rpp/rpp/observables/observable.hpp @@ -23,8 +23,8 @@ namespace rpp /** * @brief Base class for any observable used in RPP. It handles core callbacks of observable. * @details Observable provides only one core function: subscribe - it accepts observer (or any way to construct it) and then invokes underlying Strategy to emit emissions somehow. - * @warning Actually observable "doesn't emit nothing", it only **invokes Strategy!** Strategy COULD emit emissions immediately OR place observer to some queue or something like this to obtain emissions later (for example subjects) - * @warning Expected that observable's strategy would work with observer in serialized way + * @attention Actually observable "doesn't emit nothing", it only **invokes Strategy!** Strategy COULD emit emissions immediately OR place observer to some queue or something like this to obtain emissions later (for example subjects) + * @attention Expected that observable's strategy would work with observer in serialized way * * @note In case of you are need to keep some "abstract" observable of `Type`, you can use type-erased version: `rpp::dynamic_observable` * @@ -52,7 +52,7 @@ namespace rpp /** * @brief Subscribes passed observer to emissions from this observable. * - * @warning Observer must be moved in to subscribe method. (Not recommended) If you need to copy observer, convert it to dynamic_observer + * @attention Observer must be moved in to subscribe method. (Not recommended) If you need to copy observer, convert it to dynamic_observer */ template ObserverStrategy> void subscribe(observer&& observer) const @@ -138,7 +138,7 @@ namespace rpp * @warning This overloading has some performance penalties, use it only when you really need to use disposable * @return composite_disposable_wrapper is disposable to be able to dispose observer when it needed * - * @warning Observer must be moved in to subscribe method. (Not recommended) If you need to copy observer, convert it to dynamic_observer + * @attention Observer must be moved in to subscribe method. (Not recommended) If you need to copy observer, convert it to dynamic_observer */ template ObserverStrategy> [[nodiscard("Use returned disposable or use subscribe(observer) instead")]] composite_disposable_wrapper subscribe_with_disposable(observer&& observer) const diff --git a/src/rpp/rpp/observers/observer.hpp b/src/rpp/rpp/observers/observer.hpp index 3f109f885..a7b807694 100644 --- a/src/rpp/rpp/observers/observer.hpp +++ b/src/rpp/rpp/observers/observer.hpp @@ -114,7 +114,7 @@ namespace rpp::details /** * @brief Observable calls this method to notify observer about some error during generation next data. - * @warning Obtaining this of this call means no any further on_next/on_error or on_completed calls from this Observable + * @invariant Obtaining of this call means no any further on_next/on_error or on_completed calls from this Observable * @param err details of error */ void on_error(const std::exception_ptr& err) const noexcept @@ -130,7 +130,7 @@ namespace rpp::details /** * @brief Observable calls this method to notify observer about completion of emissions. - * @warning Obtaining this of this call means no any further on_next/on_error or on_completed calls from this Observable + * @invariant Obtaining of this call means no any further on_next/on_error or on_completed calls from this Observable */ void on_completed() const noexcept { diff --git a/src/rpp/rpp/operators/buffer.hpp b/src/rpp/rpp/operators/buffer.hpp index 325b38292..17456be60 100644 --- a/src/rpp/rpp/operators/buffer.hpp +++ b/src/rpp/rpp/operators/buffer.hpp @@ -100,7 +100,7 @@ namespace rpp::operators * @details The resulting bundle is `std::vector` of requested size. Actually it is similar to `window()` operator, but it emits vectors instead of observables. * * @param count number of items being bundled. - * @warning #include + * @note #include * * @par Example: * @snippet buffer.cpp buffer diff --git a/src/rpp/rpp/operators/combine_latest.hpp b/src/rpp/rpp/operators/combine_latest.hpp index 2beeffc94..5b80c1b38 100644 --- a/src/rpp/rpp/operators/combine_latest.hpp +++ b/src/rpp/rpp/operators/combine_latest.hpp @@ -90,10 +90,10 @@ namespace rpp::operators * * @param selector is applied to current emission of current observable and latests emissions from observables * @param observables are observables whose emissions would be combined with current observable - * @warning #include + * @note #include * * @par Examples - * @snippet combine_latest.cpp combine_latest custom selector + * @snippet combine_latest.cpp combine_latest custom combiner * * @ingroup combining_operators * @see https://reactivex.io/documentation/operators/combinelatest.html @@ -127,7 +127,7 @@ namespace rpp::operators * - mutex acquired every time value obtained * * @param observables are observables whose emissions would be combined when any observable sends new value - * @warning #include + * @note #include * * @par Examples * @snippet combine_latest.cpp combine_latest diff --git a/src/rpp/rpp/operators/concat.hpp b/src/rpp/rpp/operators/concat.hpp index ccab31b57..2fd6c4e69 100644 --- a/src/rpp/rpp/operators/concat.hpp +++ b/src/rpp/rpp/operators/concat.hpp @@ -229,7 +229,7 @@ namespace rpp::operators * * @tparam MemoryModel rpp::memory_model strategy used to handle provided observables * - * @warning #include + * @note #include * * @par Example * @snippet concat.cpp concat_as_operator diff --git a/src/rpp/rpp/operators/debounce.hpp b/src/rpp/rpp/operators/debounce.hpp index 24c1a9d34..c98d2231a 100644 --- a/src/rpp/rpp/operators/debounce.hpp +++ b/src/rpp/rpp/operators/debounce.hpp @@ -185,7 +185,7 @@ namespace rpp::operators * @param period is duration of time should be passed since emission from original observable without any new emissions to emit this emission. * @param scheduler is scheduler used to run timer for debounce - * @warning #include + * @note #include * * @par Example * @snippet debounce.cpp debounce diff --git a/src/rpp/rpp/operators/delay.hpp b/src/rpp/rpp/operators/delay.hpp index f92106414..aca0ebc12 100644 --- a/src/rpp/rpp/operators/delay.hpp +++ b/src/rpp/rpp/operators/delay.hpp @@ -204,7 +204,7 @@ namespace rpp::operators * * @param delay_duration is the delay duration for emitting items. Delay duration should be able to cast to rpp::schedulers::duration. * @param scheduler provides the threading model for delay. e.g. With a new thread scheduler, the observer sees the values in a new thread after a delay duration to the subscription. - * @warning #include + * @note #include * * @par Examples * @snippet delay.cpp delay diff --git a/src/rpp/rpp/operators/distinct_until_changed.hpp b/src/rpp/rpp/operators/distinct_until_changed.hpp index 91ecf0ccb..1befc2356 100644 --- a/src/rpp/rpp/operators/distinct_until_changed.hpp +++ b/src/rpp/rpp/operators/distinct_until_changed.hpp @@ -87,7 +87,7 @@ namespace rpp::operators * - passing last and emitted value to predicate * * @param equality_fn optional equality comparator function - * @warning #include + * @note #include * * @par Example * @snippet distinct_until_changed.cpp distinct_until_changed diff --git a/src/rpp/rpp/operators/element_at.hpp b/src/rpp/rpp/operators/element_at.hpp index a2d8d92c8..2ea37c0f2 100644 --- a/src/rpp/rpp/operators/element_at.hpp +++ b/src/rpp/rpp/operators/element_at.hpp @@ -93,7 +93,7 @@ namespace rpp::operators * @details If source observable completes without emitting at least `index` + 1 items, observable emits an error * * @param index index of the item to return - * @warning #include + * @note #include * * @ingroup filtering_operators * @see https://reactivex.io/documentation/operators/elementat.html diff --git a/src/rpp/rpp/operators/filter.hpp b/src/rpp/rpp/operators/filter.hpp index 32b842569..341f3cb56 100644 --- a/src/rpp/rpp/operators/filter.hpp +++ b/src/rpp/rpp/operators/filter.hpp @@ -82,7 +82,7 @@ namespace rpp::operators * - No any copies/moves of emissions, just passing by const& to predicate and then forwarding * * @param predicate is predicate used to check emitted items. true -> items satisfies condition, false -> not - * @warning #include + * @note #include * * @par Example: * @snippet filter.cpp Filter diff --git a/src/rpp/rpp/operators/finally.hpp b/src/rpp/rpp/operators/finally.hpp index 42c4c424b..2d11eca51 100644 --- a/src/rpp/rpp/operators/finally.hpp +++ b/src/rpp/rpp/operators/finally.hpp @@ -46,7 +46,7 @@ namespace rpp::operators * @brief Register callback to be called when execution is done and disposable bound to observer is disposed * * @param last_fn action callback - * @warning #include + * @note #include * * @details action callback needs to be noexcept as it is called on dispose, throwing during this time could potentially break internal disposable state. * diff --git a/src/rpp/rpp/operators/first.hpp b/src/rpp/rpp/operators/first.hpp index 01ada3504..443e27d51 100644 --- a/src/rpp/rpp/operators/first.hpp +++ b/src/rpp/rpp/operators/first.hpp @@ -79,7 +79,7 @@ namespace rpp::operators * - No any heap allocations * - No any copies/moves just forwarding of emission * - * @warning #include + * @note #include * * @par Example: * @snippet first.cpp first diff --git a/src/rpp/rpp/operators/flat_map.hpp b/src/rpp/rpp/operators/flat_map.hpp index 8044cd752..d7319d618 100644 --- a/src/rpp/rpp/operators/flat_map.hpp +++ b/src/rpp/rpp/operators/flat_map.hpp @@ -58,7 +58,7 @@ namespace rpp::operators * @details Note that flat_map merges the emissions of these Observables, so that they may interleave. * * @param callable function that returns an observable for each item emitted by the source observable. - * @warning #include + * @note #include * * @ingroup transforming_operators * @see https://reactivex.io/documentation/operators/flatmap.html diff --git a/src/rpp/rpp/operators/group_by.hpp b/src/rpp/rpp/operators/group_by.hpp index 5aa4e0210..25a1405d5 100644 --- a/src/rpp/rpp/operators/group_by.hpp +++ b/src/rpp/rpp/operators/group_by.hpp @@ -203,7 +203,7 @@ namespace rpp::operators * @param value_selector Function which determines value to be emitted to grouped observable * @param comparator Function to provide strict_weak_order between key types * - * @warning #include + * @note #include * * @par Example: * @snippet group_by.cpp group_by diff --git a/src/rpp/rpp/operators/last.hpp b/src/rpp/rpp/operators/last.hpp index a3643051b..9f7fd5d3a 100644 --- a/src/rpp/rpp/operators/last.hpp +++ b/src/rpp/rpp/operators/last.hpp @@ -87,7 +87,7 @@ namespace rpp::operators * - No any heap allocations * - No replace std::optional with each new emission and move value from optional on_completed * - * @warning #include + * @note #include * * @par Example: * @snippet last.cpp last diff --git a/src/rpp/rpp/operators/map.hpp b/src/rpp/rpp/operators/map.hpp index 43ec6d0d1..2821c1f09 100644 --- a/src/rpp/rpp/operators/map.hpp +++ b/src/rpp/rpp/operators/map.hpp @@ -82,7 +82,7 @@ namespace rpp::operators * - No any copies/moves of emissions, just forwarding to callable * * @param callable is callable used to provide this transformation. Should accept `Type` of original observable and return type for new observable - * @warning #include + * @note #include * * @par Example with same type: * @snippet map.cpp Same type diff --git a/src/rpp/rpp/operators/merge.hpp b/src/rpp/rpp/operators/merge.hpp index 791a65f84..f75ea7602 100644 --- a/src/rpp/rpp/operators/merge.hpp +++ b/src/rpp/rpp/operators/merge.hpp @@ -190,9 +190,9 @@ namespace rpp::operators /** * @brief Converts observable of observables of items into observable of items via merging emissions. * - * @warning According to observable contract (https://reactivex.io/documentation/contract.html) emissions from any observable should be serialized, so, resulting observable uses mutex to satisfy this requirement + * @invariant According to observable contract (https://reactivex.io/documentation/contract.html) emissions from any observable should be serialized, so, resulting observable uses mutex to satisfy this requirement * - * @warning During on subscribe operator takes ownership over rpp::schedulers::current_thread to allow mixing of underlying emissions + * @attention During on subscribe operator takes ownership over rpp::schedulers::current_thread to allow mixing of underlying emissions * * @marble merge { @@ -210,7 +210,7 @@ namespace rpp::operators * - 2 heap allocation (1 for state, 1 to convert observer to dynamic_observer) * - Acquiring mutex during all observer's calls * - * @warning #include + * @note #include * * @par Example: * @snippet merge.cpp merge @@ -244,7 +244,7 @@ namespace rpp::operators * - Acquiring mutex during all observer's calls * * @param observables are observables whose emissions would be merged with current observable - * @warning #include + * @note #include * * @par Example: * @snippet merge.cpp merge_with diff --git a/src/rpp/rpp/operators/multicast.hpp b/src/rpp/rpp/operators/multicast.hpp index a8526dfd0..25ab26f00 100644 --- a/src/rpp/rpp/operators/multicast.hpp +++ b/src/rpp/rpp/operators/multicast.hpp @@ -53,7 +53,7 @@ namespace rpp::operators * @warning Same subject would be used to all observables lifted via this operator. To have fresh subject everytime use another overloading * * @param subject is subject used to create rpp::connectable_observable - * @warning #include + * @note #include * * @par Example * @snippet multicast.cpp multicast @@ -73,7 +73,7 @@ namespace rpp::operators * @warning This overloading creates fresh `Subject` everytime new observable passed to this operator * * @tparam Subject is template teamplate typename over Subject to be created to create corresponding connectable_observable for provided observable - * @warning #include + * @note #include * * @par Example * @snippet multicast.cpp multicast_template diff --git a/src/rpp/rpp/operators/observe_on.hpp b/src/rpp/rpp/operators/observe_on.hpp index 5852aebf7..00fbf8b93 100644 --- a/src/rpp/rpp/operators/observe_on.hpp +++ b/src/rpp/rpp/operators/observe_on.hpp @@ -30,7 +30,7 @@ namespace rpp::operators * * @param scheduler provides the threading model for delay. e.g. With a new thread scheduler, the observer sees the values in a new thread after a delay duration to the subscription. * @param delay_duration is the delay duration for emitting items. Delay duration should be able to cast to rpp::schedulers::duration. - * @warning #include + * @note #include * * @par Examples * @snippet observe_on.cpp observe_on diff --git a/src/rpp/rpp/operators/on_error_resume_next.hpp b/src/rpp/rpp/operators/on_error_resume_next.hpp index 8a4e3bb69..7a696e3b5 100644 --- a/src/rpp/rpp/operators/on_error_resume_next.hpp +++ b/src/rpp/rpp/operators/on_error_resume_next.hpp @@ -130,7 +130,7 @@ namespace rpp::operators * * @param selector callable taking a std::exception_ptr and returning observable to continue on * - * @warning #include + * @note #include * * @ingroup error_handling_operators * @see https://reactivex.io/documentation/operators/catch.html diff --git a/src/rpp/rpp/operators/publish.hpp b/src/rpp/rpp/operators/publish.hpp index 25afff05d..31ee0c9fe 100644 --- a/src/rpp/rpp/operators/publish.hpp +++ b/src/rpp/rpp/operators/publish.hpp @@ -11,7 +11,7 @@ namespace rpp::operators * @warning This overloading creates fresh `Subject` everytime new observable passed to this operator * * @tparam Subject is template teamplate typename over Subject to be created to create corresponding connectable_observable for provided observable - * @warning #include + * @note #include * * @par Example * @snippet multicast.cpp publish diff --git a/src/rpp/rpp/operators/reduce.hpp b/src/rpp/rpp/operators/reduce.hpp index fd15960ba..2534061e1 100644 --- a/src/rpp/rpp/operators/reduce.hpp +++ b/src/rpp/rpp/operators/reduce.hpp @@ -134,7 +134,7 @@ namespace rpp::operators * @param initial_value initial value for seed * @param accumulator function which accepts seed value and new value from observable and return new value of seed. Can accept seed by move-reference. * - * @warning #include + * @note #include * * @par Example * @snippet reduce.cpp reduce @@ -163,7 +163,7 @@ namespace rpp::operators * @param initial_value initial value for seed * @param accumulator function which accepts seed value and new value from observable and return new value of seed. Can accept seed by move-reference. * - * @warning #include + * @note #include * * @par Example * @snippet reduce.cpp reduce_no_seed diff --git a/src/rpp/rpp/operators/repeat.hpp b/src/rpp/rpp/operators/repeat.hpp index 284ce12ce..af7e8608f 100644 --- a/src/rpp/rpp/operators/repeat.hpp +++ b/src/rpp/rpp/operators/repeat.hpp @@ -58,7 +58,7 @@ namespace rpp::operators * - `repeat(1)` - behave like ordinal observable * - `repeat(10)` - 1 normal subscription and 9 re-subscriptions during `on_completed` * - * @warning #include + * @note #include * * @par Examples: * @snippet repeat.cpp repeat @@ -83,7 +83,7 @@ namespace rpp::operators * * @details Actually this operator is kind of `concat(obs, obs...)` * - * @warning #include + * @note #include * * @par Examples: * @snippet repeat.cpp repeat_infinitely diff --git a/src/rpp/rpp/operators/retry.hpp b/src/rpp/rpp/operators/retry.hpp index 237267922..d8aafb6cd 100644 --- a/src/rpp/rpp/operators/retry.hpp +++ b/src/rpp/rpp/operators/retry.hpp @@ -145,7 +145,7 @@ namespace rpp::operators * * @param count is the number of retries * - * @warning #include + * @note #include * * @par Examples: * @snippet retry.cpp retry @@ -167,7 +167,7 @@ namespace rpp::operators operator "retry:()" : +-1-1-1-1-1-1-1-1-1-1-1-> } * - * @warning #include + * @note #include * * @par Examples: * @snippet retry.cpp retry_infinitely diff --git a/src/rpp/rpp/operators/retry_when.hpp b/src/rpp/rpp/operators/retry_when.hpp index d5ad56a69..f1d10dd53 100644 --- a/src/rpp/rpp/operators/retry_when.hpp +++ b/src/rpp/rpp/operators/retry_when.hpp @@ -180,7 +180,7 @@ namespace rpp::operators * a hot observable behind a replay subject can indefinitely yield an error on each re-subscription * and using retry_when on it would lead to an infinite execution. * - * @warning #include + * @note #include * * @par Examples: * @snippet retry_when.cpp retry_when delay diff --git a/src/rpp/rpp/operators/scan.hpp b/src/rpp/rpp/operators/scan.hpp index 66064e127..98597cb8f 100644 --- a/src/rpp/rpp/operators/scan.hpp +++ b/src/rpp/rpp/operators/scan.hpp @@ -141,7 +141,7 @@ namespace rpp::operators * @param initial_value initial value for seed which would be sent during subscription and applied for first value from observable. Then it will be replaced with result and etc. * @param accumulator function which accepts seed value and new value from observable and return new value of seed. Can accept seed by move-reference. * - * @warning #include + * @note #include * * @par Example * @snippet scan.cpp scan @@ -175,7 +175,7 @@ namespace rpp::operators * * @param accumulator function which accepts seed value and new value from observable and return new value of seed. Can accept seed by move-reference. * - * @warning #include + * @note #include * * @par Example * @snippet scan.cpp scan_no_seed diff --git a/src/rpp/rpp/operators/skip.hpp b/src/rpp/rpp/operators/skip.hpp index b130556df..aace06024 100644 --- a/src/rpp/rpp/operators/skip.hpp +++ b/src/rpp/rpp/operators/skip.hpp @@ -82,7 +82,7 @@ namespace rpp::operators * - Just simple `size_t` decrementing * * @param count amount of items to be skipped - * @warning #include + * @note #include * * @par Example: * @snippet skip.cpp skip diff --git a/src/rpp/rpp/operators/start_with.hpp b/src/rpp/rpp/operators/start_with.hpp index 773c72068..75561f50c 100644 --- a/src/rpp/rpp/operators/start_with.hpp +++ b/src/rpp/rpp/operators/start_with.hpp @@ -75,7 +75,7 @@ namespace rpp::operators * * @param observables list of observables which should be used before current observable * - * @warning #include + * @note #include * * @par Example * @snippet start_with.cpp start_with_observable @@ -106,7 +106,7 @@ namespace rpp::operators * @tparam memory_model memory_model strategy used to store provided values * @param vals list of values which should be emitted before current observable * - * @warning #include + * @note #include * * @par Example * @snippet start_with.cpp start_with_values @@ -136,7 +136,7 @@ namespace rpp::operators * @tparam memory_model memory_model strategy used to store provided values * @param vals list of values which should be emitted before current observable * - * @warning #include + * @note #include * * @par Example * @snippet start_with.cpp start_with_values diff --git a/src/rpp/rpp/operators/subscribe_on.hpp b/src/rpp/rpp/operators/subscribe_on.hpp index e7f314296..c1774084d 100644 --- a/src/rpp/rpp/operators/subscribe_on.hpp +++ b/src/rpp/rpp/operators/subscribe_on.hpp @@ -63,7 +63,7 @@ namespace rpp::operators * @details Actually this operator just schedules subscription on original observable to provided scheduler * * @param scheduler is scheduler used for scheduling of OnSubscribe - * @warning #include + * @note #include * * @par Example: * @snippet subscribe_on.cpp subscribe_on diff --git a/src/rpp/rpp/operators/switch_on_next.hpp b/src/rpp/rpp/operators/switch_on_next.hpp index 486ea56c8..6e59c2cd1 100644 --- a/src/rpp/rpp/operators/switch_on_next.hpp +++ b/src/rpp/rpp/operators/switch_on_next.hpp @@ -171,7 +171,7 @@ namespace rpp::operators * * @details Actually this operator just unsubscribes from previous observable and subscribes on new observable when obtained in `on_next` * - * @warning #include + * @note #include * * @par Example: * @snippet switch_on_next.cpp switch_on_next diff --git a/src/rpp/rpp/operators/take.hpp b/src/rpp/rpp/operators/take.hpp index da1fd80c1..a1f0a4285 100644 --- a/src/rpp/rpp/operators/take.hpp +++ b/src/rpp/rpp/operators/take.hpp @@ -85,7 +85,7 @@ namespace rpp::operators * - Just simple `size_t` decrementing * * @param count amount of items to be emitted. 0 - instant complete - * @warning #include + * @note #include * * @par Example: * @snippet take.cpp take diff --git a/src/rpp/rpp/operators/take_last.hpp b/src/rpp/rpp/operators/take_last.hpp index 2517f0a87..c307d54ac 100644 --- a/src/rpp/rpp/operators/take_last.hpp +++ b/src/rpp/rpp/operators/take_last.hpp @@ -112,7 +112,7 @@ namespace rpp::operators * @details Actually this operator has buffer of requested size inside, keeps last `count` values and emit stored values on `on_completed` * * @param count amount of last items to be emitted - * @warning #include + * @note #include * * @par Example * @snippet take_last.cpp take_last diff --git a/src/rpp/rpp/operators/take_until.hpp b/src/rpp/rpp/operators/take_until.hpp index c8c20e8e9..ce950797d 100644 --- a/src/rpp/rpp/operators/take_until.hpp +++ b/src/rpp/rpp/operators/take_until.hpp @@ -132,7 +132,7 @@ namespace rpp::operators * @details Actually this operator just subscribes on 2 observables and completes original when `until_observable` emits any value * * @param until_observable is the observables that stops the source observable from sending values when it emits one value or sends a on_error/on_completed event. - * @warning #include + * @note #include * * @par Examples * @snippet take_until.cpp take_until diff --git a/src/rpp/rpp/operators/take_while.hpp b/src/rpp/rpp/operators/take_while.hpp index 9d6d8d8d0..6245bdfa9 100644 --- a/src/rpp/rpp/operators/take_while.hpp +++ b/src/rpp/rpp/operators/take_while.hpp @@ -82,7 +82,7 @@ namespace rpp::operators * - No any copies/moves of emissions, just passing to predicate by const& and then forwarding * * @param predicate is predicate used to check items. Accepts value from observable and returns `true` if value should be forwarded and `false` if emissions should be stopped and observable should be terminated. - * @warning #include + * @note #include * * @par Example: * @snippet take_while.cpp take_while diff --git a/src/rpp/rpp/operators/throttle.hpp b/src/rpp/rpp/operators/throttle.hpp index a68c3faf6..3107df3d1 100644 --- a/src/rpp/rpp/operators/throttle.hpp +++ b/src/rpp/rpp/operators/throttle.hpp @@ -90,7 +90,7 @@ namespace rpp::operators * @param period is period of time to skip subsequent emissions * @tparam Scheduler is type used to determine `now()`. Shouldn't be used in production code * - * @warning #include + * @note #include * * @par Example: * @snippet throttle.cpp throttle diff --git a/src/rpp/rpp/operators/timeout.hpp b/src/rpp/rpp/operators/timeout.hpp index be97c2a22..8adec32a8 100644 --- a/src/rpp/rpp/operators/timeout.hpp +++ b/src/rpp/rpp/operators/timeout.hpp @@ -189,7 +189,7 @@ namespace rpp::operators * @param period is maximum duration between emitted items before a timeout occurs * @param fallback_observable is observable to subscribe on when timeout reached * @param scheduler is scheduler used to run timer for timeout - * @warning #include + * @note #include * * @par Example * @snippet timeout.cpp fallback_observable @@ -213,7 +213,7 @@ namespace rpp::operators } * @param period is maximum duration between emitted items before a timeout occurs * @param scheduler is scheduler used to run timer for timeout - * @warning #include + * @note #include * * @par Example * @snippet timeout.cpp default diff --git a/src/rpp/rpp/operators/window.hpp b/src/rpp/rpp/operators/window.hpp index 87fcab903..9737ac6d5 100644 --- a/src/rpp/rpp/operators/window.hpp +++ b/src/rpp/rpp/operators/window.hpp @@ -149,7 +149,7 @@ namespace rpp::operators * * @param window_size amount of items which every observable would have * - * @warning #include + * @note #include * * @par Example * @snippet window.cpp window diff --git a/src/rpp/rpp/operators/window_toggle.hpp b/src/rpp/rpp/operators/window_toggle.hpp index fedd416b2..f60603cc4 100644 --- a/src/rpp/rpp/operators/window_toggle.hpp +++ b/src/rpp/rpp/operators/window_toggle.hpp @@ -231,7 +231,7 @@ namespace rpp::operators * @param openings is observable which emissions used to start new window * @param closings_selector is function which returns observable which emission/completion means closing of opened window * - * @warning #include + * @note #include * * @par Example * @snippet window_toggle.cpp window_toggle diff --git a/src/rpp/rpp/operators/with_latest_from.hpp b/src/rpp/rpp/operators/with_latest_from.hpp index 1e0eff555..86fddaabf 100644 --- a/src/rpp/rpp/operators/with_latest_from.hpp +++ b/src/rpp/rpp/operators/with_latest_from.hpp @@ -189,7 +189,7 @@ namespace rpp::operators * * @param selector is applied to current emission of current observable and latests emissions from observables * @param observables are observables whose emissions would be combined when current observable sends new value - * @warning #include + * @note #include * * @par Examples * @snippet with_latest_from.cpp with_latest_from custom selector @@ -224,7 +224,7 @@ namespace rpp::operators * - mutex acquired every time value obtained * * @param observables are observables whose emissions would be combined when current observable sends new value - * @warning #include + * @note #include * * @par Examples * @snippet with_latest_from.cpp with_latest_from diff --git a/src/rpp/rpp/operators/zip.hpp b/src/rpp/rpp/operators/zip.hpp index f785dc7ad..07a265d55 100644 --- a/src/rpp/rpp/operators/zip.hpp +++ b/src/rpp/rpp/operators/zip.hpp @@ -93,7 +93,7 @@ namespace rpp::operators * * @param selector is applied to current emission of current observable and latests emissions from observables * @param observables are observables whose emissions would be zipped with current observable - * @warning #include + * @note #include * * @ingroup combining_operators * @see https://reactivex.io/documentation/operators/zip.html @@ -124,7 +124,7 @@ namespace rpp::operators * - mutex acquired every time value obtained * * @param observables are observables whose emissions would be zipped with current observable - * @warning #include + * @note #include * * @ingroup combining_operators * @see https://reactivex.io/documentation/operators/zip.html diff --git a/src/rpp/rpp/sources/concat.hpp b/src/rpp/rpp/sources/concat.hpp index d09e3b2c4..383c45cd7 100644 --- a/src/rpp/rpp/sources/concat.hpp +++ b/src/rpp/rpp/sources/concat.hpp @@ -162,7 +162,7 @@ namespace rpp::source * @param others rest list of observables to subscribe on * @tparam MemoryModel rpp::memory_model strategy used to handle provided observables * - * @warning #include + * @note #include * * @par Example * @snippet concat.cpp concat_as_source @@ -205,7 +205,7 @@ namespace rpp::source * @param iterable is container with observables to subscribe on * * @tparam MemoryModel rpp::memory_model strategy used to handle provided observables - * @warning #include + * @note #include * * @par Example * @snippet concat.cpp concat_as_source_vector From b5fc52828aee116e5bc5ecac68fd5bc018fecf3e Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 5 Oct 2024 18:29:00 +0000 Subject: [PATCH 13/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- Readme.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Readme.md b/Readme.md index 1fd7f11c8..49e665022 100644 --- a/Readme.md +++ b/Readme.md @@ -41,9 +41,9 @@ There we are creating observable (soure of emissions/values/data) to emit value Also RPP supports out of box: -- QT as rppqt module. Checkout [RPPQT reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppqt.html). -- GRPC as rppgrpc module. Checkout [RPPGRPC reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppgrpc.html). -- boost::asio as rppasio module. Checkout [RPPASIO reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppasio.html). +- QT as rppqt module. Checkout [RPPQT reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppqt.html). +- GRPC as rppgrpc module. Checkout [RPPGRPC reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppgrpc.html). +- boost::asio as rppasio module. Checkout [RPPASIO reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppasio.html). ``` ## What about existing Reactive Extension libraries for C++? From a7d047629a932f3b36a608db3900a871bc65dfa7 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 5 Oct 2024 22:08:33 +0300 Subject: [PATCH 14/41] address PR comments --- Readme.md | 8 ++++---- docs/readme.md | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Readme.md b/Readme.md index 49e665022..249e21b47 100644 --- a/Readme.md +++ b/Readme.md @@ -52,7 +52,7 @@ Reactive programming is a powerful paradigm for creating multi-threaded and real While RxCpp is a great and powerful library, it has some disadvantages. It is written in C++11 and contains parts written in pre-C++11 style. This leads to a mess of old-style classes and wrappers. Additionally, the `rxcpp::observable` type has a long chain of template parameters, which can lead to slower IDE performance and larger binaries. Sometimes it has bad perfomance due to tremendous amount of usage of heap or just non-effective logic. -Another implementation is [another-rxcpp](https://github.com/CODIANZ/another-rxcpp) which uses type erasure and `std::function`, but itt casues larger observer/observable size and potentially casues performance issues. +Another implementation, [another-rxcpp](https://github.com/CODIANZ/another-rxcpp), uses type erasure and `std::function`, but this approach results in larger observer/observable sizes and potentially causes performance issues. ### Why ReactivePlusPlus? @@ -61,11 +61,11 @@ Another implementation is [another-rxcpp](https://github.com/CODIANZ/another-rxc - Concepts provide more clear errors and checks: you will understand that pass something incorrect before compilation in IDE or during compilation with understandable errors instead of _"invalid template class map_invalid_t"_ - Everywhere while possible used deduction of template arguments, for example, type of values of observable by type of subscriber used in on_subscribe and etc - **ReactivePlusPlus** keeps balance between performance and type-erasing mechanism -- **ReactivePlusPlus** is fast: every part of code written with perfomance in mind. Starting from tests over amount of copies/move and finishing to Continous Benchmarking. Benchmarks prove that RPP faster than RxCPP in most cases: [Continous benchmarking results and comparison with RxCpp](https://victimsnino.github.io/ReactivePlusPlus/v2/benchmark) +- **ReactivePlusPlus** is fast: every part of code written with perfomance in mind. Starting from tests over amount of copies/move and finishing to Continuous Benchmarking. Benchmarks prove that RPP faster than RxCPP in most cases: [Continuous benchmarking results and comparison with RxCpp](https://victimsnino.github.io/ReactivePlusPlus/v2/benchmark) Currently ReactivePlusPlus is still under development but it has a lot of implemented operators for now. List of implemented features can be found in [API Reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) with very detailed documentation for each of them. -Main advantages of ReactivePlusPlus are that it is written in Modern C++ with Performance and Usage in mind. v2 written to follow [**"zero-overhead principle"**](https://en.cppreference.com/w/cpp/language/Zero-overhead_principle) As a result it is fast, readable, easy to use and well-documented. And it is proven with [continous benchmarking results of v2 and comparison with RxCpp](https://victimsnino.github.io/ReactivePlusPlus/v2/benchmark) +Main advantages of ReactivePlusPlus are that it is written in Modern C++ with Performance and Usage in mind. v2 is written to follow the [**"zero-overhead principle"**](https://en.cppreference.com/w/cpp/language/Zero-overhead_principle). As a result, it is fast, readable, easy to use, and well-documented. This is proven by [continuous benchmarking results of v2 and comparison with RxCpp](https://victimsnino.github.io/ReactivePlusPlus/v2/benchmark). ## Usage @@ -90,7 +90,7 @@ Check detailed [User Guide/Tutorial](https://victimsnino.github.io/ReactivePlusP - [Examples](https://github.com/victimsnino/ReactivePlusPlus/tree/v2/src/examples) - [reactivex.io](https://reactivex.io) describes everything related to reactive programming. - [rxmarbles](https://rxmarbles.com/) interactive diagrams of observables/operators -- [Continous benchmarking results and comparison with RxCpp](https://victimsnino.github.io/ReactivePlusPlus/v2/benchmark) +- [Continuous benchmarking results and comparison with RxCpp](https://victimsnino.github.io/ReactivePlusPlus/v2/benchmark) - [BUILDING](BUILDING.md) - [CONTRIBUTING](CONTRIBUTING.md) diff --git a/docs/readme.md b/docs/readme.md index 85009e64f..6a40f811d 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -5,7 +5,7 @@ ## Introduction to Reactive Programming > [!IMPORTANT] -> I'm highly recommend to read this article beforehand: [The introduction to Reactive Programming you've been missing](https://gist.github.com/staltz/868e7e9bc2a7b8c1f754) +> It's highly recommended to read this article beforehand: [The introduction to Reactive Programming you've been missing](https://gist.github.com/staltz/868e7e9bc2a7b8c1f754) ### What is Reactive Programming? From cb4f6807695e5524f9c9dc15922340cfd41c3651 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 5 Oct 2024 22:16:02 +0300 Subject: [PATCH 15/41] address PR comments --- Readme.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Readme.md b/Readme.md index 249e21b47..edd087a71 100644 --- a/Readme.md +++ b/Readme.md @@ -50,7 +50,7 @@ Also RPP supports out of box: Reactive programming is a powerful paradigm for creating multi-threaded and real-time applications. Unfortunately, at the moment of creating ReactivePlusPlus, there is only one stable and fully-implemented library available - [RxCpp](https://github.com/ReactiveX/RxCpp). -While RxCpp is a great and powerful library, it has some disadvantages. It is written in C++11 and contains parts written in pre-C++11 style. This leads to a mess of old-style classes and wrappers. Additionally, the `rxcpp::observable` type has a long chain of template parameters, which can lead to slower IDE performance and larger binaries. Sometimes it has bad perfomance due to tremendous amount of usage of heap or just non-effective logic. +While RxCpp is a great and powerful library, it has some disadvantages. It is written in C++11 and contains parts written in pre-C++11 style. This leads to a mess of old-style classes and wrappers. Additionally, the `rxcpp::observable` type has a long chain of template parameters, which can lead to slower IDE performance and larger binaries. Sometimes it has bad performance due to tremendous amount of usage of heap or just non-effective logic. Another implementation, [another-rxcpp](https://github.com/CODIANZ/another-rxcpp), uses type erasure and `std::function`, but this approach results in larger observer/observable sizes and potentially causes performance issues. @@ -61,7 +61,7 @@ Another implementation, [another-rxcpp](https://github.com/CODIANZ/another-rxcpp - Concepts provide more clear errors and checks: you will understand that pass something incorrect before compilation in IDE or during compilation with understandable errors instead of _"invalid template class map_invalid_t"_ - Everywhere while possible used deduction of template arguments, for example, type of values of observable by type of subscriber used in on_subscribe and etc - **ReactivePlusPlus** keeps balance between performance and type-erasing mechanism -- **ReactivePlusPlus** is fast: every part of code written with perfomance in mind. Starting from tests over amount of copies/move and finishing to Continuous Benchmarking. Benchmarks prove that RPP faster than RxCPP in most cases: [Continuous benchmarking results and comparison with RxCpp](https://victimsnino.github.io/ReactivePlusPlus/v2/benchmark) +- **ReactivePlusPlus** is fast: every part of code written with performance in mind. Starting from tests over amount of copies/move and finishing to Continuous Benchmarking. Benchmarks prove that RPP faster than RxCPP in most cases: [Continuous benchmarking results and comparison with RxCpp](https://victimsnino.github.io/ReactivePlusPlus/v2/benchmark) Currently ReactivePlusPlus is still under development but it has a lot of implemented operators for now. List of implemented features can be found in [API Reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) with very detailed documentation for each of them. @@ -96,6 +96,7 @@ Check detailed [User Guide/Tutorial](https://victimsnino.github.io/ReactivePlusP ## Licensing +```text Boost Software License - Version 1.0 - August 17th, 2003 Permission is hereby granted, free of charge, to any person or organization @@ -119,6 +120,7 @@ SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +``` # Credits: ReactivePlusPlus library uses: From 98653844649d0ffe52b564ef7218edcbdf04a3a3 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Thu, 10 Oct 2024 23:33:41 +0300 Subject: [PATCH 16/41] extend a bit --- docs/readme.md | 1 + src/examples/rpp/doxygen/readme.cpp | 22 +++++++++++ src/examples/rppgrpc/doxygen/CMakeLists.txt | 2 +- src/examples/rppqt/doxygen/CMakeLists.txt | 2 +- src/examples/rppqt/doxygen/readme.cpp | 44 +++++++++++++++++++++ src/extensions/rppqt/rppqt/fwd.hpp | 3 ++ src/rpp/rpp/fwd.hpp | 5 +++ 7 files changed, 77 insertions(+), 2 deletions(-) create mode 100644 src/examples/rpp/doxygen/readme.cpp create mode 100644 src/examples/rppqt/doxygen/readme.cpp diff --git a/docs/readme.md b/docs/readme.md index 6a40f811d..5cb504bd7 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -403,6 +403,7 @@ As a a result, users can select preferable way of handling of their types. ## ReactivePlusPlus details + ### Disposable Rpp has following disposables related classes: diff --git a/src/examples/rpp/doxygen/readme.cpp b/src/examples/rpp/doxygen/readme.cpp new file mode 100644 index 000000000..37cbe4881 --- /dev/null +++ b/src/examples/rpp/doxygen/readme.cpp @@ -0,0 +1,22 @@ +#include + +#include +#include + +/** + * @example readme.cpp + */ + +int main() // NOLINT(bugprone-exception-escape) +{ + // ![readme] + rpp::source::from_callable(&::getchar) + | rpp::operators::repeat() + | rpp::operators::take_while([](char v) { return v != '0'; }) + | rpp::operators::filter(std::not_fn(&::isdigit)) + | rpp::operators::map(&::toupper) + | rpp::operators::subscribe([](char v) { std::cout << v; }); + // ![readme] + + return 0; +} diff --git a/src/examples/rppgrpc/doxygen/CMakeLists.txt b/src/examples/rppgrpc/doxygen/CMakeLists.txt index e99bba244..907b302d4 100644 --- a/src/examples/rppgrpc/doxygen/CMakeLists.txt +++ b/src/examples/rppgrpc/doxygen/CMakeLists.txt @@ -4,7 +4,7 @@ rpp_add_proto_target(doyxgen_grpc_proto protocol.proto) foreach(SOURCE ${FILES}) get_filename_component(BASE_NAME ${SOURCE} NAME_WE) - set(TARGET ${BASE_NAME}_doxygen_sample) + set(TARGET ${BASE_NAME}_grpc_doxygen_sample) add_executable(${TARGET} ${SOURCE}) target_link_libraries(${TARGET} PRIVATE rpp rppgrpc doyxgen_grpc_proto) set_target_properties(${TARGET} PROPERTIES FOLDER Examples/rppqt/Doxygen) diff --git a/src/examples/rppqt/doxygen/CMakeLists.txt b/src/examples/rppqt/doxygen/CMakeLists.txt index 6126c3204..a84cc9ea5 100644 --- a/src/examples/rppqt/doxygen/CMakeLists.txt +++ b/src/examples/rppqt/doxygen/CMakeLists.txt @@ -2,7 +2,7 @@ file(GLOB_RECURSE FILES "*.cpp") foreach(SOURCE ${FILES}) get_filename_component(BASE_NAME ${SOURCE} NAME_WE) - set(TARGET ${BASE_NAME}_doxygen_sample) + set(TARGET ${BASE_NAME}_qt_doxygen_sample) add_executable(${TARGET} ${SOURCE}) target_link_libraries(${TARGET} PRIVATE rpp rppqt) set_target_properties(${TARGET} PROPERTIES FOLDER Examples/rppqt/Doxygen) diff --git a/src/examples/rppqt/doxygen/readme.cpp b/src/examples/rppqt/doxygen/readme.cpp new file mode 100644 index 000000000..a4aa0fe48 --- /dev/null +++ b/src/examples/rppqt/doxygen/readme.cpp @@ -0,0 +1,44 @@ +#include +#include + +#include +#include +#include +#include +#include + +#include + +/** + * @example qt_readme.cpp + */ + +int main(int argc, char** argv) // NOLINT(bugprone-exception-escape) +{ + QApplication app{argc, argv}; + + // ![readme] + auto button = new QPushButton("Click me!"); + auto label = new QLabel(); + rppqt::source::from_signal(*button, &QPushButton::clicked) // <------ react on signals + | rpp::operators::observe_on(rpp::schedulers::new_thread{}) + | rpp::ops::tap([](int){ std::this_thread::sleep_for(std::chrono::milliseconds{500}); }) // some heavy job + | rpp::operators::scan(0, [](int seed, auto) { return ++seed; }) + | rpp::operators::observe_on(rppqt::schedulers::main_thread_scheduler{}) // <--- go back to main QT scheduler + | rpp::operators::subscribe([&label](int clicks) + { + label->setText(QString{"Clicked %1 times in total!"}.arg(clicks)); + }); + // ![readme] + + QMainWindow window{}; + auto vbox = new QVBoxLayout(); + vbox->addWidget(button); + vbox->addWidget(label); + window.setCentralWidget(new QWidget); + window.centralWidget()->setLayout(vbox); + window.show(); + + + return app.exec(); +} diff --git a/src/extensions/rppqt/rppqt/fwd.hpp b/src/extensions/rppqt/rppqt/fwd.hpp index 8123def06..d00c56581 100644 --- a/src/extensions/rppqt/rppqt/fwd.hpp +++ b/src/extensions/rppqt/rppqt/fwd.hpp @@ -13,6 +13,9 @@ /** * @defgroup rppqt rppqt * @brief RppQt is extension of RPP which enables support of Qt library. + * + * @par Example: + * @snippet qt_readme.cpp readme */ /** diff --git a/src/rpp/rpp/fwd.hpp b/src/rpp/rpp/fwd.hpp index b0583a538..2316017be 100644 --- a/src/rpp/rpp/fwd.hpp +++ b/src/rpp/rpp/fwd.hpp @@ -13,6 +13,11 @@ /** * @defgroup rpp rpp * @brief ReactivePlusPlus (rpp) is Reactive extension for C++20 + * + * @details ReactivePlusPlus is reactive programming library for C++20 language inspired by "official implementation" ([RxCpp](https://github.com/ReactiveX/RxCpp)) and original idea ([ReactiveX](https://reactivex.io/)) that only depends on standard library and C++20 features (mostly on [concepts](https://en.cppreference.com/w/cpp/language/constraints)). + * + * @par Example: + * @snippet readme.cpp readme */ #include From 18ae1a5d5b94be9884b50b543075c9b5f0c1a2ba Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Thu, 10 Oct 2024 20:34:27 +0000 Subject: [PATCH 17/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/examples/rpp/doxygen/readme.cpp | 2 +- src/examples/rppqt/doxygen/readme.cpp | 23 +++++++++++------------ 2 files changed, 12 insertions(+), 13 deletions(-) diff --git a/src/examples/rpp/doxygen/readme.cpp b/src/examples/rpp/doxygen/readme.cpp index 37cbe4881..1fc29392e 100644 --- a/src/examples/rpp/doxygen/readme.cpp +++ b/src/examples/rpp/doxygen/readme.cpp @@ -4,7 +4,7 @@ #include /** - * @example readme.cpp + * @example readme.cpp */ int main() // NOLINT(bugprone-exception-escape) diff --git a/src/examples/rppqt/doxygen/readme.cpp b/src/examples/rppqt/doxygen/readme.cpp index a4aa0fe48..8f163a579 100644 --- a/src/examples/rppqt/doxygen/readme.cpp +++ b/src/examples/rppqt/doxygen/readme.cpp @@ -1,16 +1,16 @@ #include + #include -#include #include #include -#include #include - +#include +#include #include /** - * @example qt_readme.cpp + * @example qt_readme.cpp */ int main(int argc, char** argv) // NOLINT(bugprone-exception-escape) @@ -21,14 +21,13 @@ int main(int argc, char** argv) // NOLINT(bugprone-exception-escape) auto button = new QPushButton("Click me!"); auto label = new QLabel(); rppqt::source::from_signal(*button, &QPushButton::clicked) // <------ react on signals - | rpp::operators::observe_on(rpp::schedulers::new_thread{}) - | rpp::ops::tap([](int){ std::this_thread::sleep_for(std::chrono::milliseconds{500}); }) // some heavy job - | rpp::operators::scan(0, [](int seed, auto) { return ++seed; }) - | rpp::operators::observe_on(rppqt::schedulers::main_thread_scheduler{}) // <--- go back to main QT scheduler - | rpp::operators::subscribe([&label](int clicks) - { - label->setText(QString{"Clicked %1 times in total!"}.arg(clicks)); - }); + | rpp::operators::observe_on(rpp::schedulers::new_thread{}) + | rpp::ops::tap([](int) { std::this_thread::sleep_for(std::chrono::milliseconds{500}); }) // some heavy job + | rpp::operators::scan(0, [](int seed, auto) { return ++seed; }) + | rpp::operators::observe_on(rppqt::schedulers::main_thread_scheduler{}) // <--- go back to main QT scheduler + | rpp::operators::subscribe([&label](int clicks) { + label->setText(QString{"Clicked %1 times in total!"}.arg(clicks)); + }); // ![readme] QMainWindow window{}; From b3f020f9d8f5029dbabf3475f3d958d058473fd1 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Thu, 10 Oct 2024 23:45:23 +0300 Subject: [PATCH 18/41] adapt --- src/examples/rppqt/doxygen/{readme.cpp => qt_readme.cpp} | 0 src/extensions/rppqt/rppqt/fwd.hpp | 2 +- src/rpp/rpp/fwd.hpp | 4 +--- 3 files changed, 2 insertions(+), 4 deletions(-) rename src/examples/rppqt/doxygen/{readme.cpp => qt_readme.cpp} (100%) diff --git a/src/examples/rppqt/doxygen/readme.cpp b/src/examples/rppqt/doxygen/qt_readme.cpp similarity index 100% rename from src/examples/rppqt/doxygen/readme.cpp rename to src/examples/rppqt/doxygen/qt_readme.cpp diff --git a/src/extensions/rppqt/rppqt/fwd.hpp b/src/extensions/rppqt/rppqt/fwd.hpp index d00c56581..85b8f44d0 100644 --- a/src/extensions/rppqt/rppqt/fwd.hpp +++ b/src/extensions/rppqt/rppqt/fwd.hpp @@ -12,7 +12,7 @@ /** * @defgroup rppqt rppqt - * @brief RppQt is extension of RPP which enables support of Qt library. + * @details RppQt is extension of RPP which enables support of Qt library. * * @par Example: * @snippet qt_readme.cpp readme diff --git a/src/rpp/rpp/fwd.hpp b/src/rpp/rpp/fwd.hpp index 2316017be..bb5ac488c 100644 --- a/src/rpp/rpp/fwd.hpp +++ b/src/rpp/rpp/fwd.hpp @@ -12,9 +12,7 @@ /** * @defgroup rpp rpp - * @brief ReactivePlusPlus (rpp) is Reactive extension for C++20 - * - * @details ReactivePlusPlus is reactive programming library for C++20 language inspired by "official implementation" ([RxCpp](https://github.com/ReactiveX/RxCpp)) and original idea ([ReactiveX](https://reactivex.io/)) that only depends on standard library and C++20 features (mostly on [concepts](https://en.cppreference.com/w/cpp/language/constraints)). + * @details ReactivePlusPlus is reactive programming library for C++20 language inspired by "official implementation" ([RxCpp](https://github.com/ReactiveX/RxCpp)) and original idea ([ReactiveX](https://reactivex.io/)) that only depends on standard library and C++20 features (mostly on [concepts](https://en.cppreference.com/w/cpp/language/constraints)). * * @par Example: * @snippet readme.cpp readme From 489615e5b4ed2a99f9b77b9bfad8f28edf392139 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Thu, 10 Oct 2024 20:45:24 +0000 Subject: [PATCH 19/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/rpp/rpp/fwd.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rpp/rpp/fwd.hpp b/src/rpp/rpp/fwd.hpp index bb5ac488c..fc371f04b 100644 --- a/src/rpp/rpp/fwd.hpp +++ b/src/rpp/rpp/fwd.hpp @@ -12,7 +12,7 @@ /** * @defgroup rpp rpp - * @details ReactivePlusPlus is reactive programming library for C++20 language inspired by "official implementation" ([RxCpp](https://github.com/ReactiveX/RxCpp)) and original idea ([ReactiveX](https://reactivex.io/)) that only depends on standard library and C++20 features (mostly on [concepts](https://en.cppreference.com/w/cpp/language/constraints)). + * @details ReactivePlusPlus is reactive programming library for C++20 language inspired by "official implementation" ([RxCpp](https://github.com/ReactiveX/RxCpp)) and original idea ([ReactiveX](https://reactivex.io/)) that only depends on standard library and C++20 features (mostly on [concepts](https://en.cppreference.com/w/cpp/language/constraints)). * * @par Example: * @snippet readme.cpp readme From c70f0fd0b8186ef8a98ef9fc7dc025952554103b Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 12 Oct 2024 20:43:12 +0300 Subject: [PATCH 20/41] refactor a bit --- docs/readme.md | 96 ++++++++++++++++++++++++-------------------------- 1 file changed, 46 insertions(+), 50 deletions(-) diff --git a/docs/readme.md b/docs/readme.md index 5cb504bd7..a396c4297 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -11,66 +11,63 @@ **Reactive programming** is a *design paradigm* that focuses on building applications that can efficiently respond to asynchronous **events**. -Actually, any application or function has two core parts: input and output. Input/output can even be empty: +Every application or function has two core parts: input and output. Input/output can even be empty: ```cpp -int main() -{ - return 0; -} +void function() { } ``` -Input/output itself can be split into the following two types: +Input/output can be categorized into two types: -- **Static** - Your application or function just accepts such an input and handles it somehow. For example, arguments from the command line or arguments of your function: +- **Static** - The application or function accepts input and handles it. For example, command line arguments or function arguments: ```cpp int sum(int a, int b) { return a + b; } ``` -- **Distributed in time** - Your application or function doesn't know exact length of input, **when** input (or any parts of it) would arrive, but knows **what** to do when it happens: +- **Distributed in time** - The application or function doesn't know the exact length of input or when it will arrive but knows what to do when it happens: ```cpp #include int main() { - while(true) - { - auto ch = ::getchar(); - std::cout << "Obtained char " << ch << std::endl; - } + while(true) + { + auto ch = ::getchar(); + std::cout << "Obtained char " << ch << std::endl; + } } ``` When dealing with input that is **distributed in time**, there are two ways to handle it: -- **Pulling** - You decide **when** you need extra data (e.g., to get something, request, iterate, etc.) and you are simply **checking/requesting** some data. In most cases, this is a blocking operation of requesting data and waitign to be available or periodically checking its current status. For example, if you like a blog with non-periodical posts, you may check it daily for new posts manually. +- **Pulling** - You decide when you need extra data and request it. This is often a blocking operation. For example, manually checking a blog for new posts. -- **Pushing** - You decide **once** that you are interested in a source of data, notify this source somehow (e.g., register, subscribe, etc.), and **react** when new data **becomes available** to you. For example, you might **subscribe** to a blog and **react** to new posts only after receiving a notification on your smartphone, rather than manually checking for updates. +- **Pushing** - You register interest in a data source and react when new data becomes available. For example, subscribing to a blog and receiving notifications for new posts. -Reactive programming is a powerful way to handle input that is **distributed in time**. Instead of constantly polling for updates or waiting for input to arrive, reactive programming allows you to **register** callbacks to be executed **when the input becomes available**. +Reactive programming is a powerful way to handle input that is **distributed in time**. Instead of constantly polling for updates, reactive programming allows you to **register** callbacks to be executed **when the input becomes available**. See for more details. -### Core concepts of Reactive Programming +### Core Concepts of Reactive Programming -In short, Reactive Programming can be described as follows: +Reactive Programming can be described as follows: - An **Observer** subscribes to an **Observable**. -- The **Observable** automatically notifies its subscribed **Observers** about any new events/emissions. **Observable** could invoke next **observer**'s method: - - **on_next(T)** - notifies about new event/emission - - **on_error(std::exception_ptr)** - notified about error during work. It is termination event (no more calls from this observable should be expected) - - **on_completed()** - notified about successful completion.It is termination event (no more calls from this observable should be expected) - - **set_upstream(disposable)** - observable could pass to observer it's own disposable to provide ability for observer to terminate observable's internal actions/state. - - **is_disposed()** - observable could check if observer is still interested in this source data (==false) or disposed and not listening anymore (==true) -- During subscription, the **Observable** can return/provide a **Disposable** for **Observer** to provide ability to check if observable is still alive or make early termination (==dispose) if needed. +- The **Observable** notifies its subscribed **Observers** about new events/emissions: + - **on_next(T)** - notifies about a new event/emission + - **on_error(std::exception_ptr)** - notifies about an error. This is a termination event. (no more calls from this observable should be expected) + - **on_completed()** - notifies about successful completion. This is a termination event. (no more calls from this observable should be expected) + - **set_upstream(disposable)** - observable could pass to observer it's own disposable to provide ability for observer to terminate observable's internal actions/state + - **is_disposed()** - checks if the observer is still interested in the source data. + +During subscription, the **Observable** can provide a **Disposable** for the **Observer** to check if the observable is still alive or to terminate early if needed. For example: ```cpp #include - #include int main() @@ -133,22 +130,24 @@ In such an way it is not powerful enough, so Reactive Programming provides a lis ### Observable contract -Reactive programming has [Observable Contract](https://reactivex.io/documentation/contract.html). Please, read it. +Reactive programming has an [Observable Contract](https://reactivex.io/documentation/contract.html). Please read it. -This contact has next important part: +This contract includes: -> Observables must issue notifications to observers serially (not in parallel). They may issue these notifications from different threads, but there must be a formal happens-before relationship between the notifications +> Observables must issue notifications to observers serially (not in parallel). They may issue these notifications from different threads, but there must be a formal happens-before relationship between the notifications. -RPP follows this contract and especially this part. It means, that: +RPP follows this contract, meaning: -1. **All** implemented in **RPP operators** are **following this contract**:
- All built-in RPP observables/operators emit emissions serially -2. Any user-provided callbacks (for operators or observers) can be not thread-safe due to thread-safety of observable is guaranteed.
- For example: internal logic of `take` operator doesn't use mutexes or atomics due to underlying observable **MUST** emit items serially -3. When you implement your own operator via `create` be careful to **follow this contract**! -4. It is true **EXCEPT FOR** subjects if they are used manually due to users can use subjects for its own purposes there is potentially place for breaking this concept. Be careful and use serialized_* instead if can't guarantee serial emissions! +1.
**All** RPP operators follow this contract. +All built-in RPP observables/operators emit emissions serially +
+2.
User-provided callbacks can be non-thread-safe due to the thread-safety of the observable. + For example: internal logic of `take` operator doesn't use mutexes or atomics due to underlying observable MUST emit items serially +
+3. When implementing your own operator via `create`, **follow this contract**! +4. This is true **EXCEPT FOR** subjects if used manually. Use serialized_* instead if you can't guarantee serial emissions. -It means, that for example: +For example: ```cpp auto s1 = rpp::source::just(1) | rpp::operators::repeat() | rpp::operators::subscribe_on(rpp::schedulers::new_thread{}); @@ -166,7 +165,7 @@ It means, that for example: ``` -will never produce something like +This will never produce: ```log enter 1 @@ -175,7 +174,7 @@ exit 2 exit 1 ``` -only serially +Only serially: ```log enter 1 @@ -190,13 +189,12 @@ exit 2 ### Operators -**Operators** are way to modify the **Observable**'s emissions to adapt values to the **Observer**. +**Operators** modify the **Observable**'s emissions to adapt values to the **Observer**. For example, we can create observable to get chars from console input, do it till ‘0’ char, get only letters and send to observer this letters as UPPER. With operators it is pretty simple to do it in correct way: ```cpp #include - #include int main() @@ -215,14 +213,13 @@ int main() } ``` -You can check documentation for each operator on [API Reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) page. Below you can find details about how operator works and how to create your own custom operator in RPP. +Check the [API Reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) for more details about operators. -See for more details about operators concept. +See for more details about operators. +#### How Operator Works? -#### How operator works? - -Let's check this example: +Example: ```cpp rpp::source::create([](const auto& observer){ @@ -355,9 +352,9 @@ rpp::source::create([](const auto& observer) A **Scheduler** is responsible for controlling the type of multithreading behavior (or lack thereof) used in the observable. For example, a **scheduler** can utilize a new thread, a thread pool, or a raw queue to manage its processing. -Checkout [API Reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) to learn more about schedulers in RPP. +Check the [API Reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) for more details about schedulers. -See for more details about scheduler concept. +See for more details about schedulers. ### Disposable @@ -371,7 +368,7 @@ In most cases disposables are placed in observers. RPP's observer can use two ty 2. **External disposable** - This is a disposable that allows the observer to be disposed of from outside the observer itself. This can be useful in situations where you need to cancel an ongoing operation or release resources before the observable has completed its work. -### Exception guarantee +### Exception Guarantee In non-reactive programming functions/modules throws exception in case of something invalid. As a result, user can catch it and handle it somehow while internal state of objects can be in some state (invalid/untouched/partly valid) and etc. @@ -460,7 +457,6 @@ But in some cases you want to keep observable or observer inside your classes or - they are type-erased wrappers over regular observable/observer with goal to hide all unnecessary stuff from user's code. For example, you can easily use it as: ```cpp #include - #include struct some_data From a71b7bd50e1cc147544aaa1d22f76246320a25b1 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 12 Oct 2024 21:01:01 +0300 Subject: [PATCH 21/41] fix a bit --- BUILDING.md | 4 +- Readme.md | 2 +- docs/readme.md | 57 +------------------ .../rppgrpc/rppgrpc/client_reactor.hpp | 6 +- src/extensions/rppgrpc/rppgrpc/fwd.hpp | 6 ++ .../rppgrpc/rppgrpc/server_reactor.hpp | 6 +- src/rpp/rpp/observables.hpp | 56 +++++++++++++++++- 7 files changed, 71 insertions(+), 66 deletions(-) diff --git a/BUILDING.md b/BUILDING.md index 64f8f9f16..2cc86530a 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -27,7 +27,7 @@ But RPP is header-only library, so, without enabling any extra options is just c - `RPP_BUILD_EXAMPLES` - (ON/OFF) build examples of usage of RPP (default OFF) - `RPP_BUILD_SFML_CODE` - (ON/OFF) build RPP code related to SFML or not (default OFF) - requires SFML to be installed - `RPP_BUILD_QT_CODE` - (ON/OFF) build QT related code (examples/tests)(rppqt module doesn't require this one) (default OFF) - requires QT5/6 to be installed -- `RPP_BUILD_GRPC_CODE` - (ON/OFF) build GRPC related code (examples/tests)(rppgrpc module doesn't require this one) (default OFF) - requires grpc++/protobuf to be installed +- `RPP_BUILD_GRPC_CODE` - (ON/OFF) build gRPC related code (examples/tests)(rppgrpc module doesn't require this one) (default OFF) - requires gRPC++/protobuf to be installed - `RPP_BUILD_ASIO_CODE` - (ON/OFF) build RPPASIO related code (examples/tests)(rppasio module doesn't require this one) (default OFF) - requires asio to be installed By default, it provides rpp, rppqt, rppgrpc, rppasio INTERFACE modules. @@ -79,7 +79,7 @@ command of CMake: - `RPP::rpp` - main rpp INTERFACE target - `RPP::rppqt` - additional INTERFACE target to extend functionality for QT. rppqt doesn't include QT or even doesn't link with that itself. - `RPP::rppasio` - additional INTERFACE target to extend functionality for ASIO. rppasio doesn't include boost::asio or even doesn't link with that itself. - - `RPP::rppgrpc` - additional INTERFACE target to extend functionality for GRPC. rppgrpc doesn't include GRPC or even doesn't link with that itself. + - `RPP::rppgrpc` - additional INTERFACE target to extend functionality for gRPC. rppgrpc doesn't include gRPC or even doesn't link with that itself. Example usage: diff --git a/Readme.md b/Readme.md index edd087a71..f024e8138 100644 --- a/Readme.md +++ b/Readme.md @@ -42,7 +42,7 @@ There we are creating observable (soure of emissions/values/data) to emit value Also RPP supports out of box: - QT as rppqt module. Checkout [RPPQT reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppqt.html). -- GRPC as rppgrpc module. Checkout [RPPGRPC reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppgrpc.html). +- gRPC as rppgrpc module. Checkout [RPPgRPC reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppgrpc.html). - boost::asio as rppasio module. Checkout [RPPASIO reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rppasio.html). ``` diff --git a/docs/readme.md b/docs/readme.md index a396c4297..ee20aabe8 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -130,62 +130,7 @@ In such an way it is not powerful enough, so Reactive Programming provides a lis ### Observable contract -Reactive programming has an [Observable Contract](https://reactivex.io/documentation/contract.html). Please read it. - -This contract includes: - -> Observables must issue notifications to observers serially (not in parallel). They may issue these notifications from different threads, but there must be a formal happens-before relationship between the notifications. - -RPP follows this contract, meaning: - -1.
**All** RPP operators follow this contract. -All built-in RPP observables/operators emit emissions serially -
-2.
User-provided callbacks can be non-thread-safe due to the thread-safety of the observable. - For example: internal logic of `take` operator doesn't use mutexes or atomics due to underlying observable MUST emit items serially -
-3. When implementing your own operator via `create`, **follow this contract**! -4. This is true **EXCEPT FOR** subjects if used manually. Use serialized_* instead if you can't guarantee serial emissions. - -For example: - -```cpp - auto s1 = rpp::source::just(1) | rpp::operators::repeat() | rpp::operators::subscribe_on(rpp::schedulers::new_thread{}); - auto s2 = rpp::source::just(2) | rpp::operators::repeat() | rpp::operators::subscribe_on(rpp::schedulers::new_thread{}); - s1 | rpp::operators::merge_with(s2) - | rpp::operators::map([](int v) - { - std::cout << "enter " << v << std::endl; - std::this_thread::sleep_for(std::chrono::seconds{1}); - std::cout << "exit " << v << std::endl; - return v; - }) - | rpp::operators::as_blocking() - | rpp::operators::subscribe([](int){}); - -``` - -This will never produce: - -```log -enter 1 -enter 2 -exit 2 -exit 1 -``` - -Only serially: - -```log -enter 1 -exit 1 -enter 1 -exit 1 -enter 2 -exit 2 -enter 2 -exit 2 -``` +\copydoc observables ### Operators diff --git a/src/extensions/rppgrpc/rppgrpc/client_reactor.hpp b/src/extensions/rppgrpc/rppgrpc/client_reactor.hpp index a2e136b25..3f62d680d 100644 --- a/src/extensions/rppgrpc/rppgrpc/client_reactor.hpp +++ b/src/extensions/rppgrpc/rppgrpc/client_reactor.hpp @@ -29,8 +29,8 @@ namespace rppgrpc * - to pass values TO stream you can emit values to observer obtained via `reactor->get_observer()` * * @snippet client_reactor.cpp bidi_reactor - * @ingroup rppgrpc * + * @ingroup rppgrpc_reactors */ template class client_bidi_reactor final : public grpc::ClientBidiReactor @@ -104,8 +104,8 @@ namespace rppgrpc * - reactor provides `reactor->get_observable()` method but such as observable emits nothing and can be used only to be notified about completion/error * * @snippet client_reactor.cpp write_reactor - * @ingroup rppgrpc * + * @ingroup rppgrpc_reactors */ template class client_write_reactor final : public grpc::ClientWriteReactor @@ -168,8 +168,8 @@ namespace rppgrpc * - to access values FROM stream you can subscribe to observable obtained via `reactor->get_observable()` (same observable WOULD emit on_completed in case of successful stream termination and on_error in case of some errors with grpc stream) * * @snippet client_reactor.cpp read_reactor - * @ingroup rppgrpc * + * @ingroup rppgrpc_reactors */ template class client_read_reactor final : public grpc::ClientReadReactor diff --git a/src/extensions/rppgrpc/rppgrpc/fwd.hpp b/src/extensions/rppgrpc/rppgrpc/fwd.hpp index 7e89807d5..43763c6f3 100644 --- a/src/extensions/rppgrpc/rppgrpc/fwd.hpp +++ b/src/extensions/rppgrpc/rppgrpc/fwd.hpp @@ -17,6 +17,12 @@ * @brief RppGrpc is extension of RPP which enables support of grpc library. */ + /** + * @defgroup rppgrpc_reactors gRPC reactors + * @brief Reactors for gRPC to connect it to RPP properly + * @ingroup rppgrpc + */ + namespace rppgrpc { template diff --git a/src/extensions/rppgrpc/rppgrpc/server_reactor.hpp b/src/extensions/rppgrpc/rppgrpc/server_reactor.hpp index 3fc8bca29..956ab6dd9 100644 --- a/src/extensions/rppgrpc/rppgrpc/server_reactor.hpp +++ b/src/extensions/rppgrpc/rppgrpc/server_reactor.hpp @@ -30,8 +30,8 @@ namespace rppgrpc * @warning grpc server reactor have to finish manually, so it is expected that you call `on_completed()` on reactor->get_observer() * * @snippet server_reactor.cpp bidi_reactor - * @ingroup rppgrpc * + * @ingroup rppgrpc_reactors */ template class server_bidi_reactor final : public grpc::ServerBidiReactor @@ -108,8 +108,8 @@ namespace rppgrpc * - to pass values TO stream you can emit values to observer obtained via `reactor->get_observer()` * * @snippet server_reactor.cpp write_reactor - * @ingroup rppgrpc * + * @ingroup rppgrpc_reactors */ template class server_write_reactor final : public grpc::ServerWriteReactor @@ -176,8 +176,8 @@ namespace rppgrpc * - to access values FROM stream you can subscribe to observable obtained via `reactor->get_observable()` (same observable WOULD emit on_completed in case of successful stream termination and on_error in case of some errors with grpc stream) * * @snippet server_reactor.cpp read_reactor - * @ingroup rppgrpc * + * @ingroup rppgrpc_reactors */ template class server_read_reactor final : public grpc::ServerReadReactor diff --git a/src/rpp/rpp/observables.hpp b/src/rpp/rpp/observables.hpp index 1bf79618d..7f27c9e0e 100644 --- a/src/rpp/rpp/observables.hpp +++ b/src/rpp/rpp/observables.hpp @@ -13,7 +13,61 @@ /** * @defgroup observables Observables * @brief Observable is the source of any Reactive Stream. - * @details Observable provides ability to subscribe observer on stream of events. After subscription observable would emit values to observer. + * @details Observable is the source of any Reactive Stream. Observable provides ability to subscribe observer on stream of events. After subscription observable would emit values to observer. + * + * Reactive programming has an [Observable Contract](https://reactivex.io/documentation/contract.html). Please read it. + * + * This contract includes: + * + * > Observables must issue notifications to observers serially (not in parallel). They may issue these notifications from different threads, but there must be a formal happens-before relationship between the notifications. + * + * RPP follows this contract, meaning: + * + * 1. **All** RPP operators follow this contract.\n + * All built-in RPP observables/operators emit emissions serially + * + * 2. User-provided callbacks can be non-thread-safe due to the thread-safety of the observable.\n + * For example: internal logic of `take` operator doesn't use mutexes or atomics due to underlying observable **MUST** emit items serially + * + * 3. When implementing your own operator via `create`, **follow this contract**! + * + * 4. This is true **EXCEPT FOR** subjects if used manually. Use serialized_* instead if you can't guarantee serial emissions. + * + * For example: + * \code{.cpp} + * auto s1 = rpp::source::just(1) | rpp::operators::repeat() | rpp::operators::subscribe_on(rpp::schedulers::new_thread{}); + * auto s2 = rpp::source::just(2) | rpp::operators::repeat() | rpp::operators::subscribe_on(rpp::schedulers::new_thread{}); + * s1 | rpp::operators::merge_with(s2) + * | rpp::operators::map([](int v) + * { + * std::cout << "enter " << v << std::endl; + * std::this_thread::sleep_for(std::chrono::seconds{1}); + * std::cout << "exit " << v << std::endl; + * return v; + * }) + * | rpp::operators::as_blocking() + * | rpp::operators::subscribe([](int){}); + * \endcode + * + * This will never produce: + * \code{.log} + * enter 1 + * enter 2 + * exit 2 + * exit 1 + * \endcode + * + * Only serially: + * \code{.log} + * enter 1 + * exit 1 + * enter 1 + * exit 1 + * enter 2 + * exit 2 + * enter 2 + * exit 2 + * \endcode * @see https://reactivex.io/documentation/observable.html * @ingroup rpp */ From c369dd22b2be46bf5812d3a4712ea8e328fc4c59 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 12 Oct 2024 18:00:43 +0000 Subject: [PATCH 22/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/extensions/rppgrpc/rppgrpc/fwd.hpp | 2 +- src/rpp/rpp/observables.hpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/extensions/rppgrpc/rppgrpc/fwd.hpp b/src/extensions/rppgrpc/rppgrpc/fwd.hpp index 43763c6f3..0ad059054 100644 --- a/src/extensions/rppgrpc/rppgrpc/fwd.hpp +++ b/src/extensions/rppgrpc/rppgrpc/fwd.hpp @@ -17,7 +17,7 @@ * @brief RppGrpc is extension of RPP which enables support of grpc library. */ - /** +/** * @defgroup rppgrpc_reactors gRPC reactors * @brief Reactors for gRPC to connect it to RPP properly * @ingroup rppgrpc diff --git a/src/rpp/rpp/observables.hpp b/src/rpp/rpp/observables.hpp index 7f27c9e0e..a5c16f2b8 100644 --- a/src/rpp/rpp/observables.hpp +++ b/src/rpp/rpp/observables.hpp @@ -25,7 +25,7 @@ * * 1. **All** RPP operators follow this contract.\n * All built-in RPP observables/operators emit emissions serially - * + * * 2. User-provided callbacks can be non-thread-safe due to the thread-safety of the observable.\n * For example: internal logic of `take` operator doesn't use mutexes or atomics due to underlying observable **MUST** emit items serially * From 69ed6fcc4254014afccfc6806d6eb990b27312a4 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 12 Oct 2024 21:09:00 +0300 Subject: [PATCH 23/41] extract to operator --- docs/readme.md | 30 ++---------------------------- src/rpp/rpp/operators.hpp | 32 +++++++++++++++++++++++++++----- 2 files changed, 29 insertions(+), 33 deletions(-) diff --git a/docs/readme.md b/docs/readme.md index ee20aabe8..2d0cbadaf 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -134,35 +134,9 @@ In such an way it is not powerful enough, so Reactive Programming provides a lis ### Operators -**Operators** modify the **Observable**'s emissions to adapt values to the **Observer**. +\copydoc operators -For example, we can create observable to get chars from console input, do it till ‘0’ char, get only letters and send to observer this letters as UPPER. With operators it is pretty simple to do it in correct way: - -```cpp -#include -#include - -int main() -{ - rpp::source::from_callable(&::getchar) - | rpp::operators::repeat() - | rpp::operators::take_while([](char v) { return v != '0'; }) - | rpp::operators::filter(std::not_fn(&::isdigit)) - | rpp::operators::map(&::toupper) - | rpp::operators::subscribe([](char v) { std::cout << v; }); - - // input: 12345qwer5125ttqt0 - // output: QWERTTQT - - return 0; -} -``` - -Check the [API Reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) for more details about operators. - -See for more details about operators. - -#### How Operator Works? +#### How Operators Work? Example: diff --git a/src/rpp/rpp/operators.hpp b/src/rpp/rpp/operators.hpp index 015d6c889..dd4c059cc 100644 --- a/src/rpp/rpp/operators.hpp +++ b/src/rpp/rpp/operators.hpp @@ -12,11 +12,33 @@ /** * @defgroup operators Operators - * @brief Operators is way to modify observables and extend with some extra custom logic - * @details By default observable emits some values with some underlying logic. For example, it iterates over vector and - * emits values. But operators provide ability to make such an stream a bit more complex, for example, emit only SOME - * values, transform to string and etc. As a result, it would be ANOTHER stream of ANOTHER values, but more suitable for - * some specific case. + * @brief Operators provide a way to modify observables and extend them with custom logic. + * @details By default, an observable emits values based on some underlying logic. For example, it might iterate over a vector and emit values. Operators allow you to make such a stream more complex, for example, by emitting only certain values, transforming them to strings, etc. As a result, you get another stream of different values, but more suitable for a specific case. + * + * For example, you can create an observable to get characters from console input, continue until the '0' character is encountered, filter out non-letter characters, and send the remaining letters as uppercase to the observer. With operators, this is straightforward to implement correctly: + * + * @code{.cpp} + * #include + * #include + * + * int main() + * { + * rpp::source::from_callable(&::getchar) + * | rpp::operators::repeat() + * | rpp::operators::take_while([](char v) { return v != '0'; }) + * | rpp::operators::filter(std::not_fn(&::isdigit)) + * | rpp::operators::map(&::toupper) + * | rpp::operators::subscribe([](char v) { std::cout << v; }); + * + * // input: 12345qwer5125ttqt0 + * // output: QWERTTQT + * + * return 0; + * } + * @endcode + * + * Check the [API Reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) for more details about operators. + * * @see https://reactivex.io/documentation/operators.html * @ingroup rpp */ From f75bcde70f24d5c7a71e4e0210073b956536dc01 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 12 Oct 2024 18:09:12 +0000 Subject: [PATCH 24/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/rpp/rpp/operators.hpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/rpp/rpp/operators.hpp b/src/rpp/rpp/operators.hpp index dd4c059cc..1d2fb982d 100644 --- a/src/rpp/rpp/operators.hpp +++ b/src/rpp/rpp/operators.hpp @@ -14,13 +14,13 @@ * @defgroup operators Operators * @brief Operators provide a way to modify observables and extend them with custom logic. * @details By default, an observable emits values based on some underlying logic. For example, it might iterate over a vector and emit values. Operators allow you to make such a stream more complex, for example, by emitting only certain values, transforming them to strings, etc. As a result, you get another stream of different values, but more suitable for a specific case. - * + * * For example, you can create an observable to get characters from console input, continue until the '0' character is encountered, filter out non-letter characters, and send the remaining letters as uppercase to the observer. With operators, this is straightforward to implement correctly: - * + * * @code{.cpp} * #include * #include - * + * * int main() * { * rpp::source::from_callable(&::getchar) @@ -29,16 +29,16 @@ * | rpp::operators::filter(std::not_fn(&::isdigit)) * | rpp::operators::map(&::toupper) * | rpp::operators::subscribe([](char v) { std::cout << v; }); - * + * * // input: 12345qwer5125ttqt0 * // output: QWERTTQT - * + * * return 0; * } * @endcode - * + * * Check the [API Reference](https://victimsnino.github.io/ReactivePlusPlus/v2/docs/html/group__rpp.html) for more details about operators. - * + * * @see https://reactivex.io/documentation/operators.html * @ingroup rpp */ From a1d2b0012a1dceb50f286b2911ca5bec92d6df89 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 12 Oct 2024 21:34:52 +0300 Subject: [PATCH 25/41] minor --- docs/readme.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/readme.md b/docs/readme.md index 2d0cbadaf..370e9be33 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -128,6 +128,7 @@ See for more details. In such an way it is not powerful enough, so Reactive Programming provides a list of **operators**. +## Getting started ### Observable contract \copydoc observables @@ -318,7 +319,7 @@ makes only 1 copy/move to shared_ptr and then uses it instead. As a a result, users can select preferable way of handling of their types. -## ReactivePlusPlus details +## Advanced details ### Disposable From 36c7a400235fb612051e56d5ea3c4973ef6407e7 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 12 Oct 2024 21:39:29 +0300 Subject: [PATCH 26/41] change groups --- src/extensions/rppasio/rppasio/fwd.hpp | 1 + src/extensions/rppgrpc/rppgrpc/fwd.hpp | 1 + src/extensions/rppqt/rppqt/fwd.hpp | 1 + src/rpp/rpp/fwd.hpp | 5 +++++ 4 files changed, 8 insertions(+) diff --git a/src/extensions/rppasio/rppasio/fwd.hpp b/src/extensions/rppasio/rppasio/fwd.hpp index 7d2cc2e93..459de59a3 100644 --- a/src/extensions/rppasio/rppasio/fwd.hpp +++ b/src/extensions/rppasio/rppasio/fwd.hpp @@ -13,6 +13,7 @@ /** * @defgroup rppasio rppasio * @brief RppAsio is extension of RPP which enables support of boost-asio library. + * @ingroup rpp_extensions */ #include diff --git a/src/extensions/rppgrpc/rppgrpc/fwd.hpp b/src/extensions/rppgrpc/rppgrpc/fwd.hpp index 0ad059054..1ec822c66 100644 --- a/src/extensions/rppgrpc/rppgrpc/fwd.hpp +++ b/src/extensions/rppgrpc/rppgrpc/fwd.hpp @@ -15,6 +15,7 @@ /** * @defgroup rppgrpc rppgrpc * @brief RppGrpc is extension of RPP which enables support of grpc library. + * @ingroup rpp_extensions */ /** diff --git a/src/extensions/rppqt/rppqt/fwd.hpp b/src/extensions/rppqt/rppqt/fwd.hpp index 85b8f44d0..b3e0931ca 100644 --- a/src/extensions/rppqt/rppqt/fwd.hpp +++ b/src/extensions/rppqt/rppqt/fwd.hpp @@ -16,6 +16,7 @@ * * @par Example: * @snippet qt_readme.cpp readme + * @ingroup rpp_extensions */ /** diff --git a/src/rpp/rpp/fwd.hpp b/src/rpp/rpp/fwd.hpp index fc371f04b..0aa0f6412 100644 --- a/src/rpp/rpp/fwd.hpp +++ b/src/rpp/rpp/fwd.hpp @@ -18,6 +18,11 @@ * @snippet readme.cpp readme */ + /** + * @defgroup rpp_extensions rpp exensions + * @brief Extensions for ReactivePlusPlus library for 3rd party libraries + */ + #include #include #include From e429b5ed31d493d10cbaa9db1676b86363460705 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 12 Oct 2024 18:39:16 +0000 Subject: [PATCH 27/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/rpp/rpp/fwd.hpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/rpp/rpp/fwd.hpp b/src/rpp/rpp/fwd.hpp index 0aa0f6412..13ee912bc 100644 --- a/src/rpp/rpp/fwd.hpp +++ b/src/rpp/rpp/fwd.hpp @@ -18,10 +18,10 @@ * @snippet readme.cpp readme */ - /** - * @defgroup rpp_extensions rpp exensions - * @brief Extensions for ReactivePlusPlus library for 3rd party libraries - */ +/** + * @defgroup rpp_extensions rpp exensions + * @brief Extensions for ReactivePlusPlus library for 3rd party libraries + */ #include #include From a0a87403e44d511a22c3502bc2a8279bd112d49c Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 12 Oct 2024 22:25:05 +0300 Subject: [PATCH 28/41] fixes --- Doxyfile | 6 +++--- docs/readme.md | 4 ++-- src/rpp/rpp/operators/buffer.hpp | 2 +- src/rpp/rpp/operators/combine_latest.hpp | 4 ++-- src/rpp/rpp/operators/concat.hpp | 2 +- src/rpp/rpp/operators/debounce.hpp | 2 +- src/rpp/rpp/operators/delay.hpp | 2 +- src/rpp/rpp/operators/distinct_until_changed.hpp | 2 +- src/rpp/rpp/operators/element_at.hpp | 2 +- src/rpp/rpp/operators/filter.hpp | 2 +- src/rpp/rpp/operators/finally.hpp | 2 +- src/rpp/rpp/operators/first.hpp | 2 +- src/rpp/rpp/operators/flat_map.hpp | 2 +- src/rpp/rpp/operators/group_by.hpp | 2 +- src/rpp/rpp/operators/last.hpp | 2 +- src/rpp/rpp/operators/map.hpp | 2 +- src/rpp/rpp/operators/merge.hpp | 4 ++-- src/rpp/rpp/operators/multicast.hpp | 4 ++-- src/rpp/rpp/operators/observe_on.hpp | 2 +- src/rpp/rpp/operators/on_error_resume_next.hpp | 2 +- src/rpp/rpp/operators/publish.hpp | 2 +- src/rpp/rpp/operators/reduce.hpp | 7 +++---- src/rpp/rpp/operators/repeat.hpp | 4 ++-- src/rpp/rpp/operators/retry.hpp | 4 ++-- src/rpp/rpp/operators/retry_when.hpp | 2 +- src/rpp/rpp/operators/scan.hpp | 4 ++-- src/rpp/rpp/operators/skip.hpp | 2 +- src/rpp/rpp/operators/start_with.hpp | 6 +++--- src/rpp/rpp/operators/subscribe.hpp | 6 +++--- src/rpp/rpp/operators/subscribe_on.hpp | 2 +- src/rpp/rpp/operators/switch_on_next.hpp | 2 +- src/rpp/rpp/operators/take.hpp | 2 +- src/rpp/rpp/operators/take_last.hpp | 2 +- src/rpp/rpp/operators/take_until.hpp | 2 +- src/rpp/rpp/operators/take_while.hpp | 2 +- src/rpp/rpp/operators/throttle.hpp | 2 +- src/rpp/rpp/operators/timeout.hpp | 4 ++-- src/rpp/rpp/operators/window.hpp | 4 ++-- src/rpp/rpp/operators/window_toggle.hpp | 2 +- src/rpp/rpp/operators/with_latest_from.hpp | 4 ++-- src/rpp/rpp/operators/zip.hpp | 4 ++-- src/rpp/rpp/sources/concat.hpp | 4 ++-- 42 files changed, 62 insertions(+), 63 deletions(-) diff --git a/Doxyfile b/Doxyfile index 60927ad25..49dd52320 100644 --- a/Doxyfile +++ b/Doxyfile @@ -836,7 +836,7 @@ CITE_BIB_FILES = # messages are off. # The default value is: NO. -QUIET = NO +QUIET = YES # The WARNINGS tag can be used to turn on/off the warning messages that are # generated to standard error (stderr) by doxygen. If WARNINGS is set to YES @@ -1100,7 +1100,7 @@ EXAMPLE_RECURSIVE = NO # that contain images that are to be included in the documentation (see the # \image command). -IMAGE_PATH = gen_images +IMAGE_PATH = gen_docs/html/ # The INPUT_FILTER tag can be used to specify a program that doxygen should # invoke to filter for each input file. Doxygen will invoke the filter program @@ -1161,7 +1161,7 @@ FILTER_SOURCE_PATTERNS = # (index.html). This can be useful if you have a project on for instance GitHub # and want to reuse the introduction page also for the doxygen output. -USE_MDFILE_AS_MAINPAGE = ./docs/Readme.md +USE_MDFILE_AS_MAINPAGE = ./docs/readme.md # The Fortran standard specifies that for fixed formatted Fortran code all # characters from position 72 are to be considered as comment. A common diff --git a/docs/readme.md b/docs/readme.md index 370e9be33..d67261834 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -1,4 +1,4 @@ -# Documentation +# Getting started [TOC] @@ -128,7 +128,7 @@ See for more details. In such an way it is not powerful enough, so Reactive Programming provides a list of **operators**. -## Getting started +## Documentation ### Observable contract \copydoc observables diff --git a/src/rpp/rpp/operators/buffer.hpp b/src/rpp/rpp/operators/buffer.hpp index 17456be60..b82286f8e 100644 --- a/src/rpp/rpp/operators/buffer.hpp +++ b/src/rpp/rpp/operators/buffer.hpp @@ -100,7 +100,7 @@ namespace rpp::operators * @details The resulting bundle is `std::vector` of requested size. Actually it is similar to `window()` operator, but it emits vectors instead of observables. * * @param count number of items being bundled. - * @note #include + * @note `#include ` * * @par Example: * @snippet buffer.cpp buffer diff --git a/src/rpp/rpp/operators/combine_latest.hpp b/src/rpp/rpp/operators/combine_latest.hpp index 5b80c1b38..a843647bb 100644 --- a/src/rpp/rpp/operators/combine_latest.hpp +++ b/src/rpp/rpp/operators/combine_latest.hpp @@ -90,7 +90,7 @@ namespace rpp::operators * * @param selector is applied to current emission of current observable and latests emissions from observables * @param observables are observables whose emissions would be combined with current observable - * @note #include + * @note `#include ` * * @par Examples * @snippet combine_latest.cpp combine_latest custom combiner @@ -127,7 +127,7 @@ namespace rpp::operators * - mutex acquired every time value obtained * * @param observables are observables whose emissions would be combined when any observable sends new value - * @note #include + * @note `#include ` * * @par Examples * @snippet combine_latest.cpp combine_latest diff --git a/src/rpp/rpp/operators/concat.hpp b/src/rpp/rpp/operators/concat.hpp index 2fd6c4e69..053725378 100644 --- a/src/rpp/rpp/operators/concat.hpp +++ b/src/rpp/rpp/operators/concat.hpp @@ -229,7 +229,7 @@ namespace rpp::operators * * @tparam MemoryModel rpp::memory_model strategy used to handle provided observables * - * @note #include + * @note `#include ` * * @par Example * @snippet concat.cpp concat_as_operator diff --git a/src/rpp/rpp/operators/debounce.hpp b/src/rpp/rpp/operators/debounce.hpp index c98d2231a..1fac12eb6 100644 --- a/src/rpp/rpp/operators/debounce.hpp +++ b/src/rpp/rpp/operators/debounce.hpp @@ -185,7 +185,7 @@ namespace rpp::operators * @param period is duration of time should be passed since emission from original observable without any new emissions to emit this emission. * @param scheduler is scheduler used to run timer for debounce - * @note #include + * @note `#include ` * * @par Example * @snippet debounce.cpp debounce diff --git a/src/rpp/rpp/operators/delay.hpp b/src/rpp/rpp/operators/delay.hpp index aca0ebc12..612df5c35 100644 --- a/src/rpp/rpp/operators/delay.hpp +++ b/src/rpp/rpp/operators/delay.hpp @@ -204,7 +204,7 @@ namespace rpp::operators * * @param delay_duration is the delay duration for emitting items. Delay duration should be able to cast to rpp::schedulers::duration. * @param scheduler provides the threading model for delay. e.g. With a new thread scheduler, the observer sees the values in a new thread after a delay duration to the subscription. - * @note #include + * @note `#include ` * * @par Examples * @snippet delay.cpp delay diff --git a/src/rpp/rpp/operators/distinct_until_changed.hpp b/src/rpp/rpp/operators/distinct_until_changed.hpp index 1befc2356..18f676acd 100644 --- a/src/rpp/rpp/operators/distinct_until_changed.hpp +++ b/src/rpp/rpp/operators/distinct_until_changed.hpp @@ -87,7 +87,7 @@ namespace rpp::operators * - passing last and emitted value to predicate * * @param equality_fn optional equality comparator function - * @note #include + * @note `#include ` * * @par Example * @snippet distinct_until_changed.cpp distinct_until_changed diff --git a/src/rpp/rpp/operators/element_at.hpp b/src/rpp/rpp/operators/element_at.hpp index 2ea37c0f2..1cf3afa61 100644 --- a/src/rpp/rpp/operators/element_at.hpp +++ b/src/rpp/rpp/operators/element_at.hpp @@ -93,7 +93,7 @@ namespace rpp::operators * @details If source observable completes without emitting at least `index` + 1 items, observable emits an error * * @param index index of the item to return - * @note #include + * @note `#include ` * * @ingroup filtering_operators * @see https://reactivex.io/documentation/operators/elementat.html diff --git a/src/rpp/rpp/operators/filter.hpp b/src/rpp/rpp/operators/filter.hpp index 341f3cb56..887757957 100644 --- a/src/rpp/rpp/operators/filter.hpp +++ b/src/rpp/rpp/operators/filter.hpp @@ -82,7 +82,7 @@ namespace rpp::operators * - No any copies/moves of emissions, just passing by const& to predicate and then forwarding * * @param predicate is predicate used to check emitted items. true -> items satisfies condition, false -> not - * @note #include + * @note `#include ` * * @par Example: * @snippet filter.cpp Filter diff --git a/src/rpp/rpp/operators/finally.hpp b/src/rpp/rpp/operators/finally.hpp index 2d11eca51..cdcf843fc 100644 --- a/src/rpp/rpp/operators/finally.hpp +++ b/src/rpp/rpp/operators/finally.hpp @@ -46,7 +46,7 @@ namespace rpp::operators * @brief Register callback to be called when execution is done and disposable bound to observer is disposed * * @param last_fn action callback - * @note #include + * @note `#include ` * * @details action callback needs to be noexcept as it is called on dispose, throwing during this time could potentially break internal disposable state. * diff --git a/src/rpp/rpp/operators/first.hpp b/src/rpp/rpp/operators/first.hpp index 443e27d51..fd8f79cc1 100644 --- a/src/rpp/rpp/operators/first.hpp +++ b/src/rpp/rpp/operators/first.hpp @@ -79,7 +79,7 @@ namespace rpp::operators * - No any heap allocations * - No any copies/moves just forwarding of emission * - * @note #include + * @note `#include ` * * @par Example: * @snippet first.cpp first diff --git a/src/rpp/rpp/operators/flat_map.hpp b/src/rpp/rpp/operators/flat_map.hpp index d7319d618..b338ec461 100644 --- a/src/rpp/rpp/operators/flat_map.hpp +++ b/src/rpp/rpp/operators/flat_map.hpp @@ -58,7 +58,7 @@ namespace rpp::operators * @details Note that flat_map merges the emissions of these Observables, so that they may interleave. * * @param callable function that returns an observable for each item emitted by the source observable. - * @note #include + * @note `#include ` * * @ingroup transforming_operators * @see https://reactivex.io/documentation/operators/flatmap.html diff --git a/src/rpp/rpp/operators/group_by.hpp b/src/rpp/rpp/operators/group_by.hpp index 25a1405d5..1e6cccba4 100644 --- a/src/rpp/rpp/operators/group_by.hpp +++ b/src/rpp/rpp/operators/group_by.hpp @@ -203,7 +203,7 @@ namespace rpp::operators * @param value_selector Function which determines value to be emitted to grouped observable * @param comparator Function to provide strict_weak_order between key types * - * @note #include + * @note `#include ` * * @par Example: * @snippet group_by.cpp group_by diff --git a/src/rpp/rpp/operators/last.hpp b/src/rpp/rpp/operators/last.hpp index 9f7fd5d3a..9126303b9 100644 --- a/src/rpp/rpp/operators/last.hpp +++ b/src/rpp/rpp/operators/last.hpp @@ -87,7 +87,7 @@ namespace rpp::operators * - No any heap allocations * - No replace std::optional with each new emission and move value from optional on_completed * - * @note #include + * @note `#include ` * * @par Example: * @snippet last.cpp last diff --git a/src/rpp/rpp/operators/map.hpp b/src/rpp/rpp/operators/map.hpp index 2821c1f09..73159588d 100644 --- a/src/rpp/rpp/operators/map.hpp +++ b/src/rpp/rpp/operators/map.hpp @@ -82,7 +82,7 @@ namespace rpp::operators * - No any copies/moves of emissions, just forwarding to callable * * @param callable is callable used to provide this transformation. Should accept `Type` of original observable and return type for new observable - * @note #include + * @note `#include ` * * @par Example with same type: * @snippet map.cpp Same type diff --git a/src/rpp/rpp/operators/merge.hpp b/src/rpp/rpp/operators/merge.hpp index f75ea7602..bc58e43b2 100644 --- a/src/rpp/rpp/operators/merge.hpp +++ b/src/rpp/rpp/operators/merge.hpp @@ -210,7 +210,7 @@ namespace rpp::operators * - 2 heap allocation (1 for state, 1 to convert observer to dynamic_observer) * - Acquiring mutex during all observer's calls * - * @note #include + * @note `#include ` * * @par Example: * @snippet merge.cpp merge @@ -244,7 +244,7 @@ namespace rpp::operators * - Acquiring mutex during all observer's calls * * @param observables are observables whose emissions would be merged with current observable - * @note #include + * @note `#include ` * * @par Example: * @snippet merge.cpp merge_with diff --git a/src/rpp/rpp/operators/multicast.hpp b/src/rpp/rpp/operators/multicast.hpp index 25ab26f00..564577e6d 100644 --- a/src/rpp/rpp/operators/multicast.hpp +++ b/src/rpp/rpp/operators/multicast.hpp @@ -53,7 +53,7 @@ namespace rpp::operators * @warning Same subject would be used to all observables lifted via this operator. To have fresh subject everytime use another overloading * * @param subject is subject used to create rpp::connectable_observable - * @note #include + * @note `#include ` * * @par Example * @snippet multicast.cpp multicast @@ -73,7 +73,7 @@ namespace rpp::operators * @warning This overloading creates fresh `Subject` everytime new observable passed to this operator * * @tparam Subject is template teamplate typename over Subject to be created to create corresponding connectable_observable for provided observable - * @note #include + * @note `#include ` * * @par Example * @snippet multicast.cpp multicast_template diff --git a/src/rpp/rpp/operators/observe_on.hpp b/src/rpp/rpp/operators/observe_on.hpp index 00fbf8b93..9068ba55e 100644 --- a/src/rpp/rpp/operators/observe_on.hpp +++ b/src/rpp/rpp/operators/observe_on.hpp @@ -30,7 +30,7 @@ namespace rpp::operators * * @param scheduler provides the threading model for delay. e.g. With a new thread scheduler, the observer sees the values in a new thread after a delay duration to the subscription. * @param delay_duration is the delay duration for emitting items. Delay duration should be able to cast to rpp::schedulers::duration. - * @note #include + * @note `#include ` * * @par Examples * @snippet observe_on.cpp observe_on diff --git a/src/rpp/rpp/operators/on_error_resume_next.hpp b/src/rpp/rpp/operators/on_error_resume_next.hpp index 7a696e3b5..4426cc250 100644 --- a/src/rpp/rpp/operators/on_error_resume_next.hpp +++ b/src/rpp/rpp/operators/on_error_resume_next.hpp @@ -130,7 +130,7 @@ namespace rpp::operators * * @param selector callable taking a std::exception_ptr and returning observable to continue on * - * @note #include + * @note `#include ` * * @ingroup error_handling_operators * @see https://reactivex.io/documentation/operators/catch.html diff --git a/src/rpp/rpp/operators/publish.hpp b/src/rpp/rpp/operators/publish.hpp index 31ee0c9fe..dfdfb8675 100644 --- a/src/rpp/rpp/operators/publish.hpp +++ b/src/rpp/rpp/operators/publish.hpp @@ -11,7 +11,7 @@ namespace rpp::operators * @warning This overloading creates fresh `Subject` everytime new observable passed to this operator * * @tparam Subject is template teamplate typename over Subject to be created to create corresponding connectable_observable for provided observable - * @note #include + * @note `#include ` * * @par Example * @snippet multicast.cpp publish diff --git a/src/rpp/rpp/operators/reduce.hpp b/src/rpp/rpp/operators/reduce.hpp index 2534061e1..de3c6fbba 100644 --- a/src/rpp/rpp/operators/reduce.hpp +++ b/src/rpp/rpp/operators/reduce.hpp @@ -131,10 +131,10 @@ namespace rpp::operators operator "reduce: s=10, (s,x)=>s+x" : +------16| } * - * @param initial_value initial value for seed + * @param seed initial value for seed * @param accumulator function which accepts seed value and new value from observable and return new value of seed. Can accept seed by move-reference. * - * @note #include + * @note `#include ` * * @par Example * @snippet reduce.cpp reduce @@ -160,10 +160,9 @@ namespace rpp::operators * * @details There is no initial value for seed, so, first value would be used as seed value and forwarded as is. * - * @param initial_value initial value for seed * @param accumulator function which accepts seed value and new value from observable and return new value of seed. Can accept seed by move-reference. * - * @note #include + * @note `#include ` * * @par Example * @snippet reduce.cpp reduce_no_seed diff --git a/src/rpp/rpp/operators/repeat.hpp b/src/rpp/rpp/operators/repeat.hpp index af7e8608f..1928b4058 100644 --- a/src/rpp/rpp/operators/repeat.hpp +++ b/src/rpp/rpp/operators/repeat.hpp @@ -58,7 +58,7 @@ namespace rpp::operators * - `repeat(1)` - behave like ordinal observable * - `repeat(10)` - 1 normal subscription and 9 re-subscriptions during `on_completed` * - * @note #include + * @note `#include ` * * @par Examples: * @snippet repeat.cpp repeat @@ -83,7 +83,7 @@ namespace rpp::operators * * @details Actually this operator is kind of `concat(obs, obs...)` * - * @note #include + * @note `#include ` * * @par Examples: * @snippet repeat.cpp repeat_infinitely diff --git a/src/rpp/rpp/operators/retry.hpp b/src/rpp/rpp/operators/retry.hpp index d8aafb6cd..dbeb667f8 100644 --- a/src/rpp/rpp/operators/retry.hpp +++ b/src/rpp/rpp/operators/retry.hpp @@ -145,7 +145,7 @@ namespace rpp::operators * * @param count is the number of retries * - * @note #include + * @note `#include ` * * @par Examples: * @snippet retry.cpp retry @@ -167,7 +167,7 @@ namespace rpp::operators operator "retry:()" : +-1-1-1-1-1-1-1-1-1-1-1-> } * - * @note #include + * @note `#include ` * * @par Examples: * @snippet retry.cpp retry_infinitely diff --git a/src/rpp/rpp/operators/retry_when.hpp b/src/rpp/rpp/operators/retry_when.hpp index f1d10dd53..ef9f28a22 100644 --- a/src/rpp/rpp/operators/retry_when.hpp +++ b/src/rpp/rpp/operators/retry_when.hpp @@ -180,7 +180,7 @@ namespace rpp::operators * a hot observable behind a replay subject can indefinitely yield an error on each re-subscription * and using retry_when on it would lead to an infinite execution. * - * @note #include + * @note `#include ` * * @par Examples: * @snippet retry_when.cpp retry_when delay diff --git a/src/rpp/rpp/operators/scan.hpp b/src/rpp/rpp/operators/scan.hpp index 98597cb8f..1fdff676f 100644 --- a/src/rpp/rpp/operators/scan.hpp +++ b/src/rpp/rpp/operators/scan.hpp @@ -141,7 +141,7 @@ namespace rpp::operators * @param initial_value initial value for seed which would be sent during subscription and applied for first value from observable. Then it will be replaced with result and etc. * @param accumulator function which accepts seed value and new value from observable and return new value of seed. Can accept seed by move-reference. * - * @note #include + * @note `#include ` * * @par Example * @snippet scan.cpp scan @@ -175,7 +175,7 @@ namespace rpp::operators * * @param accumulator function which accepts seed value and new value from observable and return new value of seed. Can accept seed by move-reference. * - * @note #include + * @note `#include ` * * @par Example * @snippet scan.cpp scan_no_seed diff --git a/src/rpp/rpp/operators/skip.hpp b/src/rpp/rpp/operators/skip.hpp index aace06024..dd6aaea46 100644 --- a/src/rpp/rpp/operators/skip.hpp +++ b/src/rpp/rpp/operators/skip.hpp @@ -82,7 +82,7 @@ namespace rpp::operators * - Just simple `size_t` decrementing * * @param count amount of items to be skipped - * @note #include + * @note `#include ` * * @par Example: * @snippet skip.cpp skip diff --git a/src/rpp/rpp/operators/start_with.hpp b/src/rpp/rpp/operators/start_with.hpp index 75561f50c..f7f6d76c1 100644 --- a/src/rpp/rpp/operators/start_with.hpp +++ b/src/rpp/rpp/operators/start_with.hpp @@ -75,7 +75,7 @@ namespace rpp::operators * * @param observables list of observables which should be used before current observable * - * @note #include + * @note `#include ` * * @par Example * @snippet start_with.cpp start_with_observable @@ -106,7 +106,7 @@ namespace rpp::operators * @tparam memory_model memory_model strategy used to store provided values * @param vals list of values which should be emitted before current observable * - * @note #include + * @note `#include ` * * @par Example * @snippet start_with.cpp start_with_values @@ -136,7 +136,7 @@ namespace rpp::operators * @tparam memory_model memory_model strategy used to store provided values * @param vals list of values which should be emitted before current observable * - * @note #include + * @note `#include ` * * @par Example * @snippet start_with.cpp start_with_values diff --git a/src/rpp/rpp/operators/subscribe.hpp b/src/rpp/rpp/operators/subscribe.hpp index 9f9c75813..b76ca1bf9 100644 --- a/src/rpp/rpp/operators/subscribe.hpp +++ b/src/rpp/rpp/operators/subscribe.hpp @@ -233,7 +233,7 @@ namespace rpp::operators * @details This overloading attaches passed disposable to observer and return it to provide ability to dispose observer early if needed. * @warning This overloading has some performance penalties, use it only when you really need to use disposable * - * @param d is disposable to be attached to observer. If disposable is nullptr or disposed -> no any subscription happens + * @param disposable is disposable to be attached to observer. If disposable is nullptr or disposed -> no any subscription happens * * @ingroup utility_operators */ @@ -271,7 +271,7 @@ namespace rpp::operators * @details This overloading attaches passed disposable to observer and return it to provide ability to dispose observer early if needed. * @warning This overloading has some performance penalties, use it only when you really need to use disposable * - * @param d is disposable to be attached to observer. If disposable is nullptr or disposed -> no any subscription happens + * @param disposable is disposable to be attached to observer. If disposable is nullptr or disposed -> no any subscription happens * * @ingroup utility_operators */ @@ -286,7 +286,7 @@ namespace rpp::operators * @details This overloading attaches passed disposable to observer and return it to provide ability to dispose observer early if needed. * @warning This overloading has some performance penalties, use it only when you really need to use disposable * - * @param d is disposable to be attached to observer. If disposable is nullptr or disposed -> no any subscription happens + * @param disposable is disposable to be attached to observer. If disposable is nullptr or disposed -> no any subscription happens * * @ingroup utility_operators */ diff --git a/src/rpp/rpp/operators/subscribe_on.hpp b/src/rpp/rpp/operators/subscribe_on.hpp index c1774084d..918137bb7 100644 --- a/src/rpp/rpp/operators/subscribe_on.hpp +++ b/src/rpp/rpp/operators/subscribe_on.hpp @@ -63,7 +63,7 @@ namespace rpp::operators * @details Actually this operator just schedules subscription on original observable to provided scheduler * * @param scheduler is scheduler used for scheduling of OnSubscribe - * @note #include + * @note `#include ` * * @par Example: * @snippet subscribe_on.cpp subscribe_on diff --git a/src/rpp/rpp/operators/switch_on_next.hpp b/src/rpp/rpp/operators/switch_on_next.hpp index 6e59c2cd1..5a578b0d9 100644 --- a/src/rpp/rpp/operators/switch_on_next.hpp +++ b/src/rpp/rpp/operators/switch_on_next.hpp @@ -171,7 +171,7 @@ namespace rpp::operators * * @details Actually this operator just unsubscribes from previous observable and subscribes on new observable when obtained in `on_next` * - * @note #include + * @note `#include ` * * @par Example: * @snippet switch_on_next.cpp switch_on_next diff --git a/src/rpp/rpp/operators/take.hpp b/src/rpp/rpp/operators/take.hpp index a1f0a4285..dce510d1b 100644 --- a/src/rpp/rpp/operators/take.hpp +++ b/src/rpp/rpp/operators/take.hpp @@ -85,7 +85,7 @@ namespace rpp::operators * - Just simple `size_t` decrementing * * @param count amount of items to be emitted. 0 - instant complete - * @note #include + * @note `#include ` * * @par Example: * @snippet take.cpp take diff --git a/src/rpp/rpp/operators/take_last.hpp b/src/rpp/rpp/operators/take_last.hpp index c307d54ac..f12b26620 100644 --- a/src/rpp/rpp/operators/take_last.hpp +++ b/src/rpp/rpp/operators/take_last.hpp @@ -112,7 +112,7 @@ namespace rpp::operators * @details Actually this operator has buffer of requested size inside, keeps last `count` values and emit stored values on `on_completed` * * @param count amount of last items to be emitted - * @note #include + * @note `#include ` * * @par Example * @snippet take_last.cpp take_last diff --git a/src/rpp/rpp/operators/take_until.hpp b/src/rpp/rpp/operators/take_until.hpp index ce950797d..2046bf0bc 100644 --- a/src/rpp/rpp/operators/take_until.hpp +++ b/src/rpp/rpp/operators/take_until.hpp @@ -132,7 +132,7 @@ namespace rpp::operators * @details Actually this operator just subscribes on 2 observables and completes original when `until_observable` emits any value * * @param until_observable is the observables that stops the source observable from sending values when it emits one value or sends a on_error/on_completed event. - * @note #include + * @note `#include ` * * @par Examples * @snippet take_until.cpp take_until diff --git a/src/rpp/rpp/operators/take_while.hpp b/src/rpp/rpp/operators/take_while.hpp index 6245bdfa9..574d4047e 100644 --- a/src/rpp/rpp/operators/take_while.hpp +++ b/src/rpp/rpp/operators/take_while.hpp @@ -82,7 +82,7 @@ namespace rpp::operators * - No any copies/moves of emissions, just passing to predicate by const& and then forwarding * * @param predicate is predicate used to check items. Accepts value from observable and returns `true` if value should be forwarded and `false` if emissions should be stopped and observable should be terminated. - * @note #include + * @note `#include ` * * @par Example: * @snippet take_while.cpp take_while diff --git a/src/rpp/rpp/operators/throttle.hpp b/src/rpp/rpp/operators/throttle.hpp index 3107df3d1..bd52d9904 100644 --- a/src/rpp/rpp/operators/throttle.hpp +++ b/src/rpp/rpp/operators/throttle.hpp @@ -90,7 +90,7 @@ namespace rpp::operators * @param period is period of time to skip subsequent emissions * @tparam Scheduler is type used to determine `now()`. Shouldn't be used in production code * - * @note #include + * @note `#include ` * * @par Example: * @snippet throttle.cpp throttle diff --git a/src/rpp/rpp/operators/timeout.hpp b/src/rpp/rpp/operators/timeout.hpp index 8adec32a8..4d2ce2709 100644 --- a/src/rpp/rpp/operators/timeout.hpp +++ b/src/rpp/rpp/operators/timeout.hpp @@ -189,7 +189,7 @@ namespace rpp::operators * @param period is maximum duration between emitted items before a timeout occurs * @param fallback_observable is observable to subscribe on when timeout reached * @param scheduler is scheduler used to run timer for timeout - * @note #include + * @note `#include ` * * @par Example * @snippet timeout.cpp fallback_observable @@ -213,7 +213,7 @@ namespace rpp::operators } * @param period is maximum duration between emitted items before a timeout occurs * @param scheduler is scheduler used to run timer for timeout - * @note #include + * @note `#include ` * * @par Example * @snippet timeout.cpp default diff --git a/src/rpp/rpp/operators/window.hpp b/src/rpp/rpp/operators/window.hpp index 9737ac6d5..c62ce7ee8 100644 --- a/src/rpp/rpp/operators/window.hpp +++ b/src/rpp/rpp/operators/window.hpp @@ -147,9 +147,9 @@ namespace rpp::operators * * @details Actually it is similar to `buffer` but it emits observable instead of container. * - * @param window_size amount of items which every observable would have + * @param count amount of items which every observable would have * - * @note #include + * @note `#include ` * * @par Example * @snippet window.cpp window diff --git a/src/rpp/rpp/operators/window_toggle.hpp b/src/rpp/rpp/operators/window_toggle.hpp index f60603cc4..c51d918ec 100644 --- a/src/rpp/rpp/operators/window_toggle.hpp +++ b/src/rpp/rpp/operators/window_toggle.hpp @@ -231,7 +231,7 @@ namespace rpp::operators * @param openings is observable which emissions used to start new window * @param closings_selector is function which returns observable which emission/completion means closing of opened window * - * @note #include + * @note `#include ` * * @par Example * @snippet window_toggle.cpp window_toggle diff --git a/src/rpp/rpp/operators/with_latest_from.hpp b/src/rpp/rpp/operators/with_latest_from.hpp index 86fddaabf..c446ca27b 100644 --- a/src/rpp/rpp/operators/with_latest_from.hpp +++ b/src/rpp/rpp/operators/with_latest_from.hpp @@ -189,7 +189,7 @@ namespace rpp::operators * * @param selector is applied to current emission of current observable and latests emissions from observables * @param observables are observables whose emissions would be combined when current observable sends new value - * @note #include + * @note `#include ` * * @par Examples * @snippet with_latest_from.cpp with_latest_from custom selector @@ -224,7 +224,7 @@ namespace rpp::operators * - mutex acquired every time value obtained * * @param observables are observables whose emissions would be combined when current observable sends new value - * @note #include + * @note `#include ` * * @par Examples * @snippet with_latest_from.cpp with_latest_from diff --git a/src/rpp/rpp/operators/zip.hpp b/src/rpp/rpp/operators/zip.hpp index 07a265d55..ec29fd04e 100644 --- a/src/rpp/rpp/operators/zip.hpp +++ b/src/rpp/rpp/operators/zip.hpp @@ -93,7 +93,7 @@ namespace rpp::operators * * @param selector is applied to current emission of current observable and latests emissions from observables * @param observables are observables whose emissions would be zipped with current observable - * @note #include + * @note `#include ` * * @ingroup combining_operators * @see https://reactivex.io/documentation/operators/zip.html @@ -124,7 +124,7 @@ namespace rpp::operators * - mutex acquired every time value obtained * * @param observables are observables whose emissions would be zipped with current observable - * @note #include + * @note `#include ` * * @ingroup combining_operators * @see https://reactivex.io/documentation/operators/zip.html diff --git a/src/rpp/rpp/sources/concat.hpp b/src/rpp/rpp/sources/concat.hpp index 383c45cd7..a3a661f40 100644 --- a/src/rpp/rpp/sources/concat.hpp +++ b/src/rpp/rpp/sources/concat.hpp @@ -162,7 +162,7 @@ namespace rpp::source * @param others rest list of observables to subscribe on * @tparam MemoryModel rpp::memory_model strategy used to handle provided observables * - * @note #include + * @note `#include ` * * @par Example * @snippet concat.cpp concat_as_source @@ -205,7 +205,7 @@ namespace rpp::source * @param iterable is container with observables to subscribe on * * @tparam MemoryModel rpp::memory_model strategy used to handle provided observables - * @note #include + * @note `#include ` * * @par Example * @snippet concat.cpp concat_as_source_vector From 2af8ca35f284e1d1e35098f3d53a0bd18c64173a Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sat, 12 Oct 2024 23:38:20 +0300 Subject: [PATCH 29/41] Cusstomize --- .gitmodules | 3 + Doxyfile | 541 +++++++++++++++++++++++---------------- DoxygenLayout.xml | 14 +- docs/custom.css | 19 ++ docs/doxygen-awesome-css | 1 + docs/header.html | 89 +++++++ docs/readme.md | 2 +- 7 files changed, 450 insertions(+), 219 deletions(-) create mode 100644 .gitmodules create mode 100644 docs/custom.css create mode 160000 docs/doxygen-awesome-css create mode 100644 docs/header.html diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 000000000..10beb9651 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "docs/doxygen-awesome-css"] + path = docs/doxygen-awesome-css + url = https://github.com/jothepro/doxygen-awesome-css.git diff --git a/Doxyfile b/Doxyfile index 49dd52320..a43265856 100644 --- a/Doxyfile +++ b/Doxyfile @@ -1,7 +1,7 @@ -# Doxyfile 1.9.8 +# Doxyfile 1.12.0 # This file describes the settings to be used by the documentation system -# doxygen (www.doxygen.org) for a project. +# Doxygen (www.doxygen.org) for a project. # # All text after a double hash (##) is considered a comment and is placed in # front of the TAG it is preceding. @@ -15,10 +15,10 @@ # # Note: # -# Use doxygen to compare the used configuration file with the template +# Use Doxygen to compare the used configuration file with the template # configuration file: # doxygen -x [configFile] -# Use doxygen to compare the used configuration file with the template +# Use Doxygen to compare the used configuration file with the template # configuration file without replacing the environment variables or CMake type # replacement variables: # doxygen -x_noenv [configFile] @@ -54,7 +54,7 @@ PROJECT_NUMBER = # for a project that appears at the top of each page and should give viewer a # quick idea about the purpose of the project. Keep the description short. -PROJECT_BRIEF = "One more implementation of ReactiveX approach in C++ with care about performance and templates in mind" +PROJECT_BRIEF = "ReactiveX implementation for C++20" # With the PROJECT_LOGO tag one can specify a logo or an icon that is included # in the documentation. The maximum height of the logo should not exceed 55 @@ -63,17 +63,23 @@ PROJECT_BRIEF = "One more implementation of ReactiveX approach in C++ w PROJECT_LOGO = +# With the PROJECT_ICON tag one can specify an icon that is included in the tabs +# when the HTML document is shown. Doxygen will copy the logo to the output +# directory. + +PROJECT_ICON = + # The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) path # into which the generated documentation will be written. If a relative path is -# entered, it will be relative to the location where doxygen was started. If +# entered, it will be relative to the location where Doxygen was started. If # left blank the current directory will be used. OUTPUT_DIRECTORY = gen_docs -# If the CREATE_SUBDIRS tag is set to YES then doxygen will create up to 4096 +# If the CREATE_SUBDIRS tag is set to YES then Doxygen will create up to 4096 # sub-directories (in 2 levels) under the output directory of each output format # and will distribute the generated files over these directories. Enabling this -# option can be useful when feeding doxygen a huge amount of source files, where +# option can be useful when feeding Doxygen a huge amount of source files, where # putting all generated files in the same directory would otherwise causes # performance problems for the file system. Adapt CREATE_SUBDIRS_LEVEL to # control the number of sub-directories. @@ -92,7 +98,7 @@ CREATE_SUBDIRS = NO CREATE_SUBDIRS_LEVEL = 8 -# If the ALLOW_UNICODE_NAMES tag is set to YES, doxygen will allow non-ASCII +# If the ALLOW_UNICODE_NAMES tag is set to YES, Doxygen will allow non-ASCII # characters to appear in the names of generated files. If set to NO, non-ASCII # characters will be escaped, for example _xE3_x81_x84 will be used for Unicode # U+3044. @@ -101,7 +107,7 @@ CREATE_SUBDIRS_LEVEL = 8 ALLOW_UNICODE_NAMES = NO # The OUTPUT_LANGUAGE tag is used to specify the language in which all -# documentation generated by doxygen is written. Doxygen will use this +# documentation generated by Doxygen is written. Doxygen will use this # information to generate all constant output in the proper language. # Possible values are: Afrikaans, Arabic, Armenian, Brazilian, Bulgarian, # Catalan, Chinese, Chinese-Traditional, Croatian, Czech, Danish, Dutch, English @@ -115,14 +121,14 @@ ALLOW_UNICODE_NAMES = NO OUTPUT_LANGUAGE = English -# If the BRIEF_MEMBER_DESC tag is set to YES, doxygen will include brief member +# If the BRIEF_MEMBER_DESC tag is set to YES, Doxygen will include brief member # descriptions after the members that are listed in the file and class # documentation (similar to Javadoc). Set to NO to disable this. # The default value is: YES. BRIEF_MEMBER_DESC = YES -# If the REPEAT_BRIEF tag is set to YES, doxygen will prepend the brief +# If the REPEAT_BRIEF tag is set to YES, Doxygen will prepend the brief # description of a member or function before the detailed description # # Note: If both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the @@ -153,13 +159,13 @@ ABBREVIATE_BRIEF = "The $name class" \ the # If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then -# doxygen will generate a detailed section even if there is only a brief +# Doxygen will generate a detailed section even if there is only a brief # description. # The default value is: NO. ALWAYS_DETAILED_SEC = NO -# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all +# If the INLINE_INHERITED_MEMB tag is set to YES, Doxygen will show all # inherited members of a class in the documentation of that class as if those # members were ordinary class members. Constructors, destructors and assignment # operators of the base classes will not be shown. @@ -167,7 +173,7 @@ ALWAYS_DETAILED_SEC = NO INLINE_INHERITED_MEMB = NO -# If the FULL_PATH_NAMES tag is set to YES, doxygen will prepend the full path +# If the FULL_PATH_NAMES tag is set to YES, Doxygen will prepend the full path # before files name in the file list and in the header files. If set to NO the # shortest path that makes the file name unique will be used # The default value is: YES. @@ -177,11 +183,11 @@ FULL_PATH_NAMES = YES # The STRIP_FROM_PATH tag can be used to strip a user-defined part of the path. # Stripping is only done if one of the specified strings matches the left-hand # part of the path. The tag can be used to show relative paths in the file list. -# If left blank the directory from which doxygen is run is used as the path to +# If left blank the directory from which Doxygen is run is used as the path to # strip. # # Note that you can specify absolute paths here, but also relative paths, which -# will be relative from the directory where doxygen is started. +# will be relative from the directory where Doxygen is started. # This tag requires that the tag FULL_PATH_NAMES is set to YES. STRIP_FROM_PATH = @@ -195,14 +201,14 @@ STRIP_FROM_PATH = STRIP_FROM_INC_PATH = -# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter (but +# If the SHORT_NAMES tag is set to YES, Doxygen will generate much shorter (but # less readable) file names. This can be useful is your file systems doesn't # support long names like on DOS, Mac, or CD-ROM. # The default value is: NO. SHORT_NAMES = NO -# If the JAVADOC_AUTOBRIEF tag is set to YES then doxygen will interpret the +# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen will interpret the # first line (until the first dot) of a Javadoc-style comment as the brief # description. If set to NO, the Javadoc-style will behave just like regular Qt- # style comments (thus requiring an explicit @brief command for a brief @@ -211,17 +217,17 @@ SHORT_NAMES = NO JAVADOC_AUTOBRIEF = NO -# If the JAVADOC_BANNER tag is set to YES then doxygen will interpret a line +# If the JAVADOC_BANNER tag is set to YES then Doxygen will interpret a line # such as # /*************** # as being the beginning of a Javadoc-style comment "banner". If set to NO, the # Javadoc-style will behave just like regular comments and it will not be -# interpreted by doxygen. +# interpreted by Doxygen. # The default value is: NO. JAVADOC_BANNER = NO -# If the QT_AUTOBRIEF tag is set to YES then doxygen will interpret the first +# If the QT_AUTOBRIEF tag is set to YES then Doxygen will interpret the first # line (until the first dot) of a Qt-style comment as the brief description. If # set to NO, the Qt-style will behave just like regular Qt-style comments (thus # requiring an explicit \brief command for a brief description.) @@ -229,7 +235,7 @@ JAVADOC_BANNER = NO QT_AUTOBRIEF = NO -# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make doxygen treat a +# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen treat a # multi-line C++ special comment block (i.e. a block of //! or /// comments) as # a brief description. This used to be the default behavior. The new default is # to treat a multi-line C++ comment block as a detailed description. Set this @@ -241,10 +247,10 @@ QT_AUTOBRIEF = NO MULTILINE_CPP_IS_BRIEF = NO -# By default Python docstrings are displayed as preformatted text and doxygen's +# By default Python docstrings are displayed as preformatted text and Doxygen's # special commands cannot be used. By setting PYTHON_DOCSTRING to NO the -# doxygen's special commands can be used and the contents of the docstring -# documentation blocks is shown as doxygen documentation. +# Doxygen's special commands can be used and the contents of the docstring +# documentation blocks is shown as Doxygen documentation. # The default value is: YES. PYTHON_DOCSTRING = YES @@ -255,7 +261,7 @@ PYTHON_DOCSTRING = YES INHERIT_DOCS = YES -# If the SEPARATE_MEMBER_PAGES tag is set to YES then doxygen will produce a new +# If the SEPARATE_MEMBER_PAGES tag is set to YES then Doxygen will produce a new # page for each member. If set to NO, the documentation of a member will be part # of the file/class/namespace that contains it. # The default value is: NO. @@ -325,30 +331,30 @@ OPTIMIZE_OUTPUT_SLICE = NO # parses. With this tag you can assign which parser to use for a given # extension. Doxygen has a built-in mapping, but you can override or extend it # using this tag. The format is ext=language, where ext is a file extension, and -# language is one of the parsers supported by doxygen: IDL, Java, JavaScript, +# language is one of the parsers supported by Doxygen: IDL, Java, JavaScript, # Csharp (C#), C, C++, Lex, D, PHP, md (Markdown), Objective-C, Python, Slice, # VHDL, Fortran (fixed format Fortran: FortranFixed, free formatted Fortran: # FortranFree, unknown formatted Fortran: Fortran. In the later case the parser # tries to guess whether the code is fixed or free formatted code, this is the -# default for Fortran type files). For instance to make doxygen treat .inc files +# default for Fortran type files). For instance to make Doxygen treat .inc files # as Fortran files (default is PHP), and .f files as C (default is Fortran), # use: inc=Fortran f=C. # # Note: For files without extension you can use no_extension as a placeholder. # # Note that for custom extensions you also need to set FILE_PATTERNS otherwise -# the files are not read by doxygen. When specifying no_extension you should add +# the files are not read by Doxygen. When specifying no_extension you should add # * to the FILE_PATTERNS. # # Note see also the list of default file extension mappings. EXTENSION_MAPPING = -# If the MARKDOWN_SUPPORT tag is enabled then doxygen pre-processes all comments +# If the MARKDOWN_SUPPORT tag is enabled then Doxygen pre-processes all comments # according to the Markdown format, which allows for more readable # documentation. See https://daringfireball.net/projects/markdown/ for details. -# The output of markdown processing is further processed by doxygen, so you can -# mix doxygen, HTML, and XML commands with Markdown formatting. Disable only in +# The output of markdown processing is further processed by Doxygen, so you can +# mix Doxygen, HTML, and XML commands with Markdown formatting. Disable only in # case of backward compatibilities issues. # The default value is: YES. @@ -358,10 +364,10 @@ MARKDOWN_SUPPORT = YES # to that level are automatically included in the table of contents, even if # they do not have an id attribute. # Note: This feature currently applies only to Markdown headings. -# Minimum value: 0, maximum value: 99, default value: 5. +# Minimum value: 0, maximum value: 99, default value: 6. # This tag requires that the tag MARKDOWN_SUPPORT is set to YES. -TOC_INCLUDE_HEADINGS = 5 +TOC_INCLUDE_HEADINGS = 6 # The MARKDOWN_ID_STYLE tag can be used to specify the algorithm used to # generate identifiers for the Markdown headings. Note: Every identifier is @@ -374,7 +380,7 @@ TOC_INCLUDE_HEADINGS = 5 MARKDOWN_ID_STYLE = DOXYGEN -# When enabled doxygen tries to link words that correspond to documented +# When enabled Doxygen tries to link words that correspond to documented # classes, or namespaces to their corresponding documentation. Such a link can # be prevented in individual cases by putting a % sign in front of the word or # globally by setting AUTOLINK_SUPPORT to NO. @@ -384,10 +390,10 @@ AUTOLINK_SUPPORT = YES # If you use STL classes (i.e. std::string, std::vector, etc.) but do not want # to include (a tag file for) the STL sources as input, then you should set this -# tag to YES in order to let doxygen match functions declarations and +# tag to YES in order to let Doxygen match functions declarations and # definitions whose arguments contain STL classes (e.g. func(std::string); -# versus func(std::string) {}). This also make the inheritance and collaboration -# diagrams that involve STL classes more complete and accurate. +# versus func(std::string) {}). This also makes the inheritance and +# collaboration diagrams that involve STL classes more complete and accurate. # The default value is: NO. BUILTIN_STL_SUPPORT = NO @@ -399,16 +405,16 @@ BUILTIN_STL_SUPPORT = NO CPP_CLI_SUPPORT = NO # Set the SIP_SUPPORT tag to YES if your project consists of sip (see: -# https://www.riverbankcomputing.com/software/sip/intro) sources only. Doxygen -# will parse them like normal C++ but will assume all classes use public instead -# of private inheritance when no explicit protection keyword is present. +# https://www.riverbankcomputing.com/software) sources only. Doxygen will parse +# them like normal C++ but will assume all classes use public instead of private +# inheritance when no explicit protection keyword is present. # The default value is: NO. SIP_SUPPORT = NO # For Microsoft's IDL there are propget and propput attributes to indicate # getter and setter methods for a property. Setting this option to YES will make -# doxygen to replace the get and set methods by a property in the documentation. +# Doxygen to replace the get and set methods by a property in the documentation. # This will only work if the methods are indeed getting or setting a simple # type. If this is not the case, or you want to show the methods anyway, you # should set this option to NO. @@ -417,7 +423,7 @@ SIP_SUPPORT = NO IDL_PROPERTY_SUPPORT = YES # If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC -# tag is set to YES then doxygen will reuse the documentation of the first +# tag is set to YES then Doxygen will reuse the documentation of the first # member in the group (if any) for the other members of the group. By default # all members of a group must be documented explicitly. # The default value is: NO. @@ -475,18 +481,18 @@ TYPEDEF_HIDES_STRUCT = NO # The size of the symbol lookup cache can be set using LOOKUP_CACHE_SIZE. This # cache is used to resolve symbols given their name and scope. Since this can be # an expensive process and often the same symbol appears multiple times in the -# code, doxygen keeps a cache of pre-resolved symbols. If the cache is too small -# doxygen will become slower. If the cache is too large, memory is wasted. The +# code, Doxygen keeps a cache of pre-resolved symbols. If the cache is too small +# Doxygen will become slower. If the cache is too large, memory is wasted. The # cache size is given by this formula: 2^(16+LOOKUP_CACHE_SIZE). The valid range # is 0..9, the default is 0, corresponding to a cache size of 2^16=65536 -# symbols. At the end of a run doxygen will report the cache usage and suggest +# symbols. At the end of a run Doxygen will report the cache usage and suggest # the optimal cache size from a speed point of view. # Minimum value: 0, maximum value: 9, default value: 0. LOOKUP_CACHE_SIZE = 0 -# The NUM_PROC_THREADS specifies the number of threads doxygen is allowed to use -# during processing. When set to 0 doxygen will based this on the number of +# The NUM_PROC_THREADS specifies the number of threads Doxygen is allowed to use +# during processing. When set to 0 Doxygen will based this on the number of # cores available in the system. You can set it explicitly to a value larger # than 0 to get more control over the balance between CPU load and processing # speed. At this moment only the input processing can be done using multiple @@ -510,7 +516,7 @@ TIMESTAMP = NO # Build related configuration options #--------------------------------------------------------------------------- -# If the EXTRACT_ALL tag is set to YES, doxygen will assume all entities in +# If the EXTRACT_ALL tag is set to YES, Doxygen will assume all entities in # documentation are documented, even if no documentation was available. Private # class members and static file members will be hidden unless the # EXTRACT_PRIVATE respectively EXTRACT_STATIC tags are set to YES. @@ -576,7 +582,7 @@ EXTRACT_ANON_NSPACES = NO RESOLVE_UNNAMED_PARAMS = YES -# If the HIDE_UNDOC_MEMBERS tag is set to YES, doxygen will hide all +# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all # undocumented members inside documented classes or files. If set to NO these # members will be included in the various overviews, but no documentation # section is generated. This option has no effect if EXTRACT_ALL is enabled. @@ -584,7 +590,7 @@ RESOLVE_UNNAMED_PARAMS = YES HIDE_UNDOC_MEMBERS = NO -# If the HIDE_UNDOC_CLASSES tag is set to YES, doxygen will hide all +# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all # undocumented classes that are normally visible in the class hierarchy. If set # to NO, these classes will be included in the various overviews. This option # will also hide undocumented C++ concepts if enabled. This option has no effect @@ -593,14 +599,14 @@ HIDE_UNDOC_MEMBERS = NO HIDE_UNDOC_CLASSES = NO -# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, doxygen will hide all friend +# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all friend # declarations. If set to NO, these declarations will be included in the # documentation. # The default value is: NO. HIDE_FRIEND_COMPOUNDS = NO -# If the HIDE_IN_BODY_DOCS tag is set to YES, doxygen will hide any +# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any # documentation blocks found inside the body of a function. If set to NO, these # blocks will be appended to the function's detailed documentation block. # The default value is: NO. @@ -614,7 +620,7 @@ HIDE_IN_BODY_DOCS = NO INTERNAL_DOCS = NO -# With the correct setting of option CASE_SENSE_NAMES doxygen will better be +# With the correct setting of option CASE_SENSE_NAMES Doxygen will better be # able to match the capabilities of the underlying filesystem. In case the # filesystem is case sensitive (i.e. it supports files in the same directory # whose names only differ in casing), the option must be set to YES to properly @@ -623,7 +629,7 @@ INTERNAL_DOCS = NO # output files written for symbols that only differ in casing, such as for two # classes, one named CLASS and the other named Class, and to also support # references to files without having to specify the exact matching casing. On -# Windows (including Cygwin) and MacOS, users should typically set this option +# Windows (including Cygwin) and macOS, users should typically set this option # to NO, whereas on Linux or other Unix flavors it should typically be set to # YES. # Possible values are: SYSTEM, NO and YES. @@ -631,14 +637,14 @@ INTERNAL_DOCS = NO CASE_SENSE_NAMES = NO -# If the HIDE_SCOPE_NAMES tag is set to NO then doxygen will show members with +# If the HIDE_SCOPE_NAMES tag is set to NO then Doxygen will show members with # their full class and namespace scopes in the documentation. If set to YES, the # scope will be hidden. # The default value is: NO. HIDE_SCOPE_NAMES = NO -# If the HIDE_COMPOUND_REFERENCE tag is set to NO (default) then doxygen will +# If the HIDE_COMPOUND_REFERENCE tag is set to NO (default) then Doxygen will # append additional text to a page's title, such as Class Reference. If set to # YES the compound reference will be hidden. # The default value is: NO. @@ -651,7 +657,7 @@ HIDE_COMPOUND_REFERENCE= NO SHOW_HEADERFILE = YES -# If the SHOW_INCLUDE_FILES tag is set to YES then doxygen will put a list of +# If the SHOW_INCLUDE_FILES tag is set to YES then Doxygen will put a list of # the files that are included by a file in the documentation of that file. # The default value is: YES. @@ -664,7 +670,7 @@ SHOW_INCLUDE_FILES = YES SHOW_GROUPED_MEMB_INC = NO -# If the FORCE_LOCAL_INCLUDES tag is set to YES then doxygen will list include +# If the FORCE_LOCAL_INCLUDES tag is set to YES then Doxygen will list include # files with double quotes in the documentation rather than with sharp brackets. # The default value is: NO. @@ -676,14 +682,14 @@ FORCE_LOCAL_INCLUDES = NO INLINE_INFO = YES -# If the SORT_MEMBER_DOCS tag is set to YES then doxygen will sort the +# If the SORT_MEMBER_DOCS tag is set to YES then Doxygen will sort the # (detailed) documentation of file and class members alphabetically by member # name. If set to NO, the members will appear in declaration order. # The default value is: YES. SORT_MEMBER_DOCS = YES -# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the brief +# If the SORT_BRIEF_DOCS tag is set to YES then Doxygen will sort the brief # descriptions of file, namespace and class members alphabetically by member # name. If set to NO, the members will appear in declaration order. Note that # this will also influence the order of the classes in the class list. @@ -691,7 +697,7 @@ SORT_MEMBER_DOCS = YES SORT_BRIEF_DOCS = NO -# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen will sort the +# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then Doxygen will sort the # (brief and detailed) documentation of class members so that constructors and # destructors are listed first. If set to NO the constructors will appear in the # respective orders defined by SORT_BRIEF_DOCS and SORT_MEMBER_DOCS. @@ -703,7 +709,7 @@ SORT_BRIEF_DOCS = NO SORT_MEMBERS_CTORS_1ST = NO -# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the hierarchy +# If the SORT_GROUP_NAMES tag is set to YES then Doxygen will sort the hierarchy # of group names into alphabetical order. If set to NO the group names will # appear in their defined order. # The default value is: NO. @@ -720,11 +726,11 @@ SORT_GROUP_NAMES = NO SORT_BY_SCOPE_NAME = NO -# If the STRICT_PROTO_MATCHING option is enabled and doxygen fails to do proper +# If the STRICT_PROTO_MATCHING option is enabled and Doxygen fails to do proper # type resolution of all parameters of a function it will reject a match between # the prototype and the implementation of a member function even if there is # only one candidate or it is obvious which candidate to choose by doing a -# simple string match. By disabling STRICT_PROTO_MATCHING doxygen will still +# simple string match. By disabling STRICT_PROTO_MATCHING Doxygen will still # accept a match between prototype and implementation in such cases. # The default value is: NO. @@ -794,25 +800,25 @@ SHOW_FILES = YES SHOW_NAMESPACES = YES # The FILE_VERSION_FILTER tag can be used to specify a program or script that -# doxygen should invoke to get the current version for each file (typically from +# Doxygen should invoke to get the current version for each file (typically from # the version control system). Doxygen will invoke the program by executing (via # popen()) the command command input-file, where command is the value of the # FILE_VERSION_FILTER tag, and input-file is the name of an input file provided -# by doxygen. Whatever the program writes to standard output is used as the file +# by Doxygen. Whatever the program writes to standard output is used as the file # version. For an example see the documentation. FILE_VERSION_FILTER = # The LAYOUT_FILE tag can be used to specify a layout file which will be parsed -# by doxygen. The layout file controls the global structure of the generated +# by Doxygen. The layout file controls the global structure of the generated # output files in an output format independent way. To create the layout file -# that represents doxygen's defaults, run doxygen with the -l option. You can +# that represents Doxygen's defaults, run Doxygen with the -l option. You can # optionally specify a file name after the option, if omitted DoxygenLayout.xml # will be used as the name of the layout file. See also section "Changing the # layout of pages" for information. # -# Note that if you run doxygen from a directory containing a file called -# DoxygenLayout.xml, doxygen will parse it automatically even if the LAYOUT_FILE +# Note that if you run Doxygen from a directory containing a file called +# DoxygenLayout.xml, Doxygen will parse it automatically even if the LAYOUT_FILE # tag is left empty. LAYOUT_FILE = DoxygenLayout.xml @@ -827,19 +833,35 @@ LAYOUT_FILE = DoxygenLayout.xml CITE_BIB_FILES = +# The EXTERNAL_TOOL_PATH tag can be used to extend the search path (PATH +# environment variable) so that external tools such as latex and gs can be +# found. +# Note: Directories specified with EXTERNAL_TOOL_PATH are added in front of the +# path already specified by the PATH variable, and are added in the order +# specified. +# Note: This option is particularly useful for macOS version 14 (Sonoma) and +# higher, when running Doxygen from Doxywizard, because in this case any user- +# defined changes to the PATH are ignored. A typical example on macOS is to set +# EXTERNAL_TOOL_PATH = /Library/TeX/texbin /usr/local/bin +# together with the standard path, the full search path used by doxygen when +# launching external tools will then become +# PATH=/Library/TeX/texbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin + +EXTERNAL_TOOL_PATH = + #--------------------------------------------------------------------------- # Configuration options related to warning and progress messages #--------------------------------------------------------------------------- # The QUIET tag can be used to turn on/off the messages that are generated to -# standard output by doxygen. If QUIET is set to YES this implies that the +# standard output by Doxygen. If QUIET is set to YES this implies that the # messages are off. # The default value is: NO. QUIET = YES # The WARNINGS tag can be used to turn on/off the warning messages that are -# generated to standard error (stderr) by doxygen. If WARNINGS is set to YES +# generated to standard error (stderr) by Doxygen. If WARNINGS is set to YES # this implies that the warnings are on. # # Tip: Turn warnings on while writing the documentation. @@ -847,14 +869,14 @@ QUIET = YES WARNINGS = YES -# If the WARN_IF_UNDOCUMENTED tag is set to YES then doxygen will generate +# If the WARN_IF_UNDOCUMENTED tag is set to YES then Doxygen will generate # warnings for undocumented members. If EXTRACT_ALL is set to YES then this flag # will automatically be disabled. # The default value is: YES. WARN_IF_UNDOCUMENTED = NO -# If the WARN_IF_DOC_ERROR tag is set to YES, doxygen will generate warnings for +# If the WARN_IF_DOC_ERROR tag is set to YES, Doxygen will generate warnings for # potential errors in the documentation, such as documenting some parameters in # a documented function twice, or documenting parameters that don't exist or # using markup commands wrongly. @@ -862,8 +884,8 @@ WARN_IF_UNDOCUMENTED = NO WARN_IF_DOC_ERROR = YES -# If WARN_IF_INCOMPLETE_DOC is set to YES, doxygen will warn about incomplete -# function parameter documentation. If set to NO, doxygen will accept that some +# If WARN_IF_INCOMPLETE_DOC is set to YES, Doxygen will warn about incomplete +# function parameter documentation. If set to NO, Doxygen will accept that some # parameters have no documentation without warning. # The default value is: YES. @@ -871,7 +893,7 @@ WARN_IF_INCOMPLETE_DOC = NO # This WARN_NO_PARAMDOC option can be enabled to get warnings for functions that # are documented, but have no documentation for their parameters or return -# value. If set to NO, doxygen will only warn about wrong parameter +# value. If set to NO, Doxygen will only warn about wrong parameter # documentation, but not about the absence of documentation. If EXTRACT_ALL is # set to YES then this flag will automatically be disabled. See also # WARN_IF_INCOMPLETE_DOC @@ -879,20 +901,20 @@ WARN_IF_INCOMPLETE_DOC = NO WARN_NO_PARAMDOC = NO -# If WARN_IF_UNDOC_ENUM_VAL option is set to YES, doxygen will warn about -# undocumented enumeration values. If set to NO, doxygen will accept +# If WARN_IF_UNDOC_ENUM_VAL option is set to YES, Doxygen will warn about +# undocumented enumeration values. If set to NO, Doxygen will accept # undocumented enumeration values. If EXTRACT_ALL is set to YES then this flag # will automatically be disabled. # The default value is: NO. WARN_IF_UNDOC_ENUM_VAL = NO -# If the WARN_AS_ERROR tag is set to YES then doxygen will immediately stop when +# If the WARN_AS_ERROR tag is set to YES then Doxygen will immediately stop when # a warning is encountered. If the WARN_AS_ERROR tag is set to FAIL_ON_WARNINGS -# then doxygen will continue running as if WARN_AS_ERROR tag is set to NO, but -# at the end of the doxygen process doxygen will return with a non-zero status. -# If the WARN_AS_ERROR tag is set to FAIL_ON_WARNINGS_PRINT then doxygen behaves -# like FAIL_ON_WARNINGS but in case no WARN_LOGFILE is defined doxygen will not +# then Doxygen will continue running as if WARN_AS_ERROR tag is set to NO, but +# at the end of the Doxygen process Doxygen will return with a non-zero status. +# If the WARN_AS_ERROR tag is set to FAIL_ON_WARNINGS_PRINT then Doxygen behaves +# like FAIL_ON_WARNINGS but in case no WARN_LOGFILE is defined Doxygen will not # write the warning messages in between other messages but write them at the end # of a run, in case a WARN_LOGFILE is defined the warning messages will be # besides being in the defined file also be shown at the end of a run, unless @@ -903,7 +925,7 @@ WARN_IF_UNDOC_ENUM_VAL = NO WARN_AS_ERROR = NO -# The WARN_FORMAT tag determines the format of the warning messages that doxygen +# The WARN_FORMAT tag determines the format of the warning messages that Doxygen # can produce. The string should contain the $file, $line, and $text tags, which # will be replaced by the file and line number from which the warning originated # and the warning text. Optionally the format may contain $version, which will @@ -916,7 +938,7 @@ WARN_FORMAT = "$file:$line: $text" # In the $text part of the WARN_FORMAT command it is possible that a reference # to a more specific place is given. To make it easier to jump to this place -# (outside of doxygen) the user can define a custom "cut" / "paste" string. +# (outside of Doxygen) the user can define a custom "cut" / "paste" string. # Example: # WARN_LINE_FORMAT = "'vi $file +$line'" # See also: WARN_FORMAT @@ -951,7 +973,7 @@ INPUT = src/rpp \ docs # This tag can be used to specify the character encoding of the source files -# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses +# that Doxygen parses. Internally Doxygen uses the UTF-8 encoding. Doxygen uses # libiconv (or the iconv built into libc) for the transcoding. See the libiconv # documentation (see: # https://www.gnu.org/software/libiconv/) for the list of possible encodings. @@ -961,12 +983,12 @@ INPUT = src/rpp \ INPUT_ENCODING = UTF-8 # This tag can be used to specify the character encoding of the source files -# that doxygen parses The INPUT_FILE_ENCODING tag can be used to specify +# that Doxygen parses The INPUT_FILE_ENCODING tag can be used to specify # character encoding on a per file pattern basis. Doxygen will compare the file # name with each pattern and apply the encoding instead of the default # INPUT_ENCODING) if there is a match. The character encodings are a list of the -# form: pattern=encoding (like *.php=ISO-8859-1). See cfg_input_encoding -# "INPUT_ENCODING" for further information on supported encodings. +# form: pattern=encoding (like *.php=ISO-8859-1). +# See also: INPUT_ENCODING for further information on supported encodings. INPUT_FILE_ENCODING = @@ -976,23 +998,27 @@ INPUT_FILE_ENCODING = # # Note that for custom extensions or not directly supported extensions you also # need to set EXTENSION_MAPPING for the extension otherwise the files are not -# read by doxygen. +# read by Doxygen. # # Note the list of default checked file patterns might differ from the list of # default file extension mappings. # # If left blank the following patterns are tested:*.c, *.cc, *.cxx, *.cxxm, -# *.cpp, *.cppm, *.c++, *.c++m, *.java, *.ii, *.ixx, *.ipp, *.i++, *.inl, *.idl, -# *.ddl, *.odl, *.h, *.hh, *.hxx, *.hpp, *.h++, *.ixx, *.l, *.cs, *.d, *.php, -# *.php4, *.php5, *.phtml, *.inc, *.m, *.markdown, *.md, *.mm, *.dox (to be -# provided as doxygen C comment), *.py, *.pyw, *.f90, *.f95, *.f03, *.f08, +# *.cpp, *.cppm, *.ccm, *.c++, *.c++m, *.java, *.ii, *.ixx, *.ipp, *.i++, *.inl, +# *.idl, *.ddl, *.odl, *.h, *.hh, *.hxx, *.hpp, *.h++, *.ixx, *.l, *.cs, *.d, +# *.php, *.php4, *.php5, *.phtml, *.inc, *.m, *.markdown, *.md, *.mm, *.dox (to +# be provided as Doxygen C comment), *.py, *.pyw, *.f90, *.f95, *.f03, *.f08, # *.f18, *.f, *.for, *.vhd, *.vhdl, *.ucf, *.qsf and *.ice. FILE_PATTERNS = *.c \ *.cc \ *.cxx \ + *.cxxm \ *.cpp \ + *.cppm \ + *.ccm \ *.c++ \ + *.c++m \ *.java \ *.ii \ *.ixx \ @@ -1007,6 +1033,7 @@ FILE_PATTERNS = *.c \ *.hxx \ *.hpp \ *.h++ \ + *.ixx \ *.l \ *.cs \ *.d \ @@ -1045,10 +1072,11 @@ RECURSIVE = YES # excluded from the INPUT source files. This way you can easily exclude a # subdirectory from a directory tree whose root is specified with the INPUT tag. # -# Note that relative paths are relative to the directory from which doxygen is +# Note that relative paths are relative to the directory from which Doxygen is # run. -EXCLUDE = build +EXCLUDE = build \ + docs/doxygen-awesome-css # The EXCLUDE_SYMLINKS tag can be used to select whether or not files or # directories that are symbolic links (a Unix file system feature) are excluded @@ -1102,7 +1130,7 @@ EXAMPLE_RECURSIVE = NO IMAGE_PATH = gen_docs/html/ -# The INPUT_FILTER tag can be used to specify a program that doxygen should +# The INPUT_FILTER tag can be used to specify a program that Doxygen should # invoke to filter for each input file. Doxygen will invoke the filter program # by executing (via popen()) the command: # @@ -1117,14 +1145,14 @@ IMAGE_PATH = gen_docs/html/ # code is scanned, but not when the output code is generated. If lines are added # or removed, the anchors will not be placed correctly. # -# Note that doxygen will use the data processed and written to standard output +# Note that Doxygen will use the data processed and written to standard output # for further processing, therefore nothing else, like debug statements or used # commands (so in case of a Windows batch file always use @echo OFF), should be # written to standard output. # # Note that for custom extensions or not directly supported extensions you also # need to set EXTENSION_MAPPING for the extension otherwise the files are not -# properly processed by doxygen. +# properly processed by Doxygen. INPUT_FILTER = @@ -1137,7 +1165,7 @@ INPUT_FILTER = # # Note that for custom extensions or not directly supported extensions you also # need to set EXTENSION_MAPPING for the extension otherwise the files are not -# properly processed by doxygen. +# properly processed by Doxygen. FILTER_PATTERNS = "*.hpp=python3 ./ci/generate_marbles.py" @@ -1159,7 +1187,7 @@ FILTER_SOURCE_PATTERNS = # If the USE_MDFILE_AS_MAINPAGE tag refers to the name of a markdown file that # is part of the input, its contents will be placed on the main page # (index.html). This can be useful if you have a project on for instance GitHub -# and want to reuse the introduction page also for the doxygen output. +# and want to reuse the introduction page also for the Doxygen output. USE_MDFILE_AS_MAINPAGE = ./docs/readme.md @@ -1186,12 +1214,13 @@ FORTRAN_COMMENT_AFTER = 72 SOURCE_BROWSER = NO # Setting the INLINE_SOURCES tag to YES will include the body of functions, -# classes and enums directly into the documentation. +# multi-line macros, enums or list initialized variables directly into the +# documentation. # The default value is: NO. INLINE_SOURCES = NO -# Setting the STRIP_CODE_COMMENTS tag to YES will instruct doxygen to hide any +# Setting the STRIP_CODE_COMMENTS tag to YES will instruct Doxygen to hide any # special comment blocks from generated source code fragments. Normal C, C++ and # Fortran comments will always remain visible. # The default value is: YES. @@ -1229,7 +1258,7 @@ REFERENCES_LINK_SOURCE = YES SOURCE_TOOLTIPS = YES # If the USE_HTAGS tag is set to YES then the references to source code will -# point to the HTML generated by the htags(1) tool instead of doxygen built-in +# point to the HTML generated by the htags(1) tool instead of Doxygen built-in # source browser. The htags tool is part of GNU's global source tagging system # (see https://www.gnu.org/software/global/global.html). You will need version # 4.8.6 or higher. @@ -1243,14 +1272,14 @@ SOURCE_TOOLTIPS = YES # Doxygen will invoke htags (and that will in turn invoke gtags), so these # tools must be available from the command line (i.e. in the search path). # -# The result: instead of the source browser generated by doxygen, the links to +# The result: instead of the source browser generated by Doxygen, the links to # source code will now point to the output of htags. # The default value is: NO. # This tag requires that the tag SOURCE_BROWSER is set to YES. USE_HTAGS = NO -# If the VERBATIM_HEADERS tag is set the YES then doxygen will generate a +# If the VERBATIM_HEADERS tag is set the YES then Doxygen will generate a # verbatim copy of the header file for each class for which an include is # specified. Set to NO to disable this. # See also: Section \class. @@ -1258,6 +1287,46 @@ USE_HTAGS = NO VERBATIM_HEADERS = YES +# If the CLANG_ASSISTED_PARSING tag is set to YES then Doxygen will use the +# clang parser (see: +# http://clang.llvm.org/) for more accurate parsing at the cost of reduced +# performance. This can be particularly helpful with template rich C++ code for +# which Doxygen's built-in parser lacks the necessary type information. +# Note: The availability of this option depends on whether or not Doxygen was +# generated with the -Duse_libclang=ON option for CMake. +# The default value is: NO. + +CLANG_ASSISTED_PARSING = NO + +# If the CLANG_ASSISTED_PARSING tag is set to YES and the CLANG_ADD_INC_PATHS +# tag is set to YES then Doxygen will add the directory of each input to the +# include path. +# The default value is: YES. +# This tag requires that the tag CLANG_ASSISTED_PARSING is set to YES. + +CLANG_ADD_INC_PATHS = YES + +# If clang assisted parsing is enabled you can provide the compiler with command +# line options that you would normally use when invoking the compiler. Note that +# the include paths will already be set by Doxygen for the files and directories +# specified with INPUT and INCLUDE_PATH. +# This tag requires that the tag CLANG_ASSISTED_PARSING is set to YES. + +CLANG_OPTIONS = + +# If clang assisted parsing is enabled you can provide the clang parser with the +# path to the directory containing a file called compile_commands.json. This +# file is the compilation database (see: +# http://clang.llvm.org/docs/HowToSetupToolingForLLVM.html) containing the +# options used when the source files were built. This is equivalent to +# specifying the -p option to a clang tool, such as clang-check. These options +# will then be passed to the parser. Any options specified with CLANG_OPTIONS +# will be added as well. +# Note: The availability of this option depends on whether or not Doxygen was +# generated with the -Duse_libclang=ON option for CMake. + +CLANG_DATABASE_PATH = + #--------------------------------------------------------------------------- # Configuration options related to the alphabetical class index #--------------------------------------------------------------------------- @@ -1282,7 +1351,7 @@ IGNORE_PREFIX = # Configuration options related to the HTML output #--------------------------------------------------------------------------- -# If the GENERATE_HTML tag is set to YES, doxygen will generate HTML output +# If the GENERATE_HTML tag is set to YES, Doxygen will generate HTML output # The default value is: YES. GENERATE_HTML = YES @@ -1303,40 +1372,40 @@ HTML_OUTPUT = html HTML_FILE_EXTENSION = .html # The HTML_HEADER tag can be used to specify a user-defined HTML header file for -# each generated HTML page. If the tag is left blank doxygen will generate a +# each generated HTML page. If the tag is left blank Doxygen will generate a # standard header. # # To get valid HTML the header file that includes any scripts and style sheets -# that doxygen needs, which is dependent on the configuration options used (e.g. +# that Doxygen needs, which is dependent on the configuration options used (e.g. # the setting GENERATE_TREEVIEW). It is highly recommended to start with a # default header using # doxygen -w html new_header.html new_footer.html new_stylesheet.css # YourConfigFile # and then modify the file new_header.html. See also section "Doxygen usage" -# for information on how to generate the default header that doxygen normally +# for information on how to generate the default header that Doxygen normally # uses. # Note: The header is subject to change so you typically have to regenerate the -# default header when upgrading to a newer version of doxygen. For a description +# default header when upgrading to a newer version of Doxygen. For a description # of the possible markers and block names see the documentation. # This tag requires that the tag GENERATE_HTML is set to YES. -HTML_HEADER = +HTML_HEADER = docs/header.html # The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each -# generated HTML page. If the tag is left blank doxygen will generate a standard +# generated HTML page. If the tag is left blank Doxygen will generate a standard # footer. See HTML_HEADER for more information on how to generate a default # footer and what special commands can be used inside the footer. See also # section "Doxygen usage" for information on how to generate the default footer -# that doxygen normally uses. +# that Doxygen normally uses. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_FOOTER = # The HTML_STYLESHEET tag can be used to specify a user-defined cascading style # sheet that is used by each HTML page. It can be used to fine-tune the look of -# the HTML output. If left blank doxygen will generate a default style sheet. +# the HTML output. If left blank Doxygen will generate a default style sheet. # See also section "Doxygen usage" for information on how to generate the style -# sheet that doxygen normally uses. +# sheet that Doxygen normally uses. # Note: It is recommended to use HTML_EXTRA_STYLESHEET instead of this tag, as # it is more robust and this tag (HTML_STYLESHEET) will in the future become # obsolete. @@ -1346,7 +1415,7 @@ HTML_STYLESHEET = # The HTML_EXTRA_STYLESHEET tag can be used to specify additional user-defined # cascading style sheets that are included after the standard style sheets -# created by doxygen. Using this option one can overrule certain style aspects. +# created by Doxygen. Using this option one can overrule certain style aspects. # This is preferred over using HTML_STYLESHEET since it does not replace the # standard style sheet and is therefore more robust against future updates. # Doxygen will copy the style sheet files to the output directory. @@ -1360,7 +1429,10 @@ HTML_STYLESHEET = # documentation. # This tag requires that the tag GENERATE_HTML is set to YES. -HTML_EXTRA_STYLESHEET = +HTML_EXTRA_STYLESHEET = docs/doxygen-awesome-css/doxygen-awesome.css \ + docs/doxygen-awesome-css/doxygen-awesome-sidebar-only.css \ + docs/doxygen-awesome-css/doxygen-awesome-sidebar-only-darkmode-toggle.css \ + docs/custom.css # The HTML_EXTRA_FILES tag can be used to specify one or more extra images or # other source files which should be copied to the HTML output directory. Note @@ -1370,15 +1442,16 @@ HTML_EXTRA_STYLESHEET = # files will be copied as-is; there are no commands or markers available. # This tag requires that the tag GENERATE_HTML is set to YES. -HTML_EXTRA_FILES = +HTML_EXTRA_FILES = docs/doxygen-awesome-css/doxygen-awesome-darkmode-toggle.js \ + docs/doxygen-awesome-css/doxygen-awesome-fragment-copy-button.js # The HTML_COLORSTYLE tag can be used to specify if the generated HTML output # should be rendered with a dark or light theme. -# Possible values are: LIGHT always generate light mode output, DARK always -# generate dark mode output, AUTO_LIGHT automatically set the mode according to -# the user preference, use light mode if no preference is set (the default), -# AUTO_DARK automatically set the mode according to the user preference, use -# dark mode if no preference is set and TOGGLE allow to user to switch between +# Possible values are: LIGHT always generates light mode output, DARK always +# generates dark mode output, AUTO_LIGHT automatically sets the mode according +# to the user preference, uses light mode if no preference is set (the default), +# AUTO_DARK automatically sets the mode according to the user preference, uses +# dark mode if no preference is set and TOGGLE allows a user to switch between # light and dark mode via a button. # The default value is: AUTO_LIGHT. # This tag requires that the tag GENERATE_HTML is set to YES. @@ -1441,6 +1514,26 @@ HTML_DYNAMIC_SECTIONS = NO HTML_CODE_FOLDING = YES +# If the HTML_COPY_CLIPBOARD tag is set to YES then Doxygen will show an icon in +# the top right corner of code and text fragments that allows the user to copy +# its content to the clipboard. Note this only works if supported by the browser +# and the web page is served via a secure context (see: +# https://www.w3.org/TR/secure-contexts/), i.e. using the https: or file: +# protocol. +# The default value is: YES. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_COPY_CLIPBOARD = NO + +# Doxygen stores a couple of settings persistently in the browser (via e.g. +# cookies). By default these settings apply to all HTML pages generated by +# Doxygen across all projects. The HTML_PROJECT_COOKIE tag can be used to store +# the settings under a project specific key, such that the user preferences will +# be stored separately. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_PROJECT_COOKIE = + # With HTML_INDEX_NUM_ENTRIES one can control the preferred number of entries # shown in the various tree structured indices initially; the user can expand # and collapse entries dynamically later on. Doxygen will expand the tree to @@ -1458,7 +1551,7 @@ HTML_INDEX_NUM_ENTRIES = 100 # generated that can be used as input for Apple's Xcode 3 integrated development # environment (see: # https://developer.apple.com/xcode/), introduced with OSX 10.5 (Leopard). To -# create a documentation set, doxygen will generate a Makefile in the HTML +# create a documentation set, Doxygen will generate a Makefile in the HTML # output directory. Running make will produce the docset in that directory and # running make install will install the docset in # ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find it at @@ -1506,7 +1599,7 @@ DOCSET_PUBLISHER_ID = org.doxygen.Publisher DOCSET_PUBLISHER_NAME = Publisher -# If the GENERATE_HTMLHELP tag is set to YES then doxygen generates three +# If the GENERATE_HTMLHELP tag is set to YES then Doxygen generates three # additional HTML index files: index.hhp, index.hhc, and index.hhk. The # index.hhp is a project file that can be read by Microsoft's HTML Help Workshop # on Windows. In the beginning of 2021 Microsoft took the original page, with @@ -1517,7 +1610,7 @@ DOCSET_PUBLISHER_NAME = Publisher # ad/0/A/9/0A939EF6-E31C-430F-A3DF-DFAE7960D564/htmlhelp.exe). # # The HTML Help Workshop contains a compiler that can convert all HTML output -# generated by doxygen into a single compiled HTML file (.chm). Compiled HTML +# generated by Doxygen into a single compiled HTML file (.chm). Compiled HTML # files are now used as the Windows 98 help format, and will replace the old # Windows help format (.hlp) on all Windows platforms in the future. Compressed # HTML files also contain an index, a table of contents, and you can search for @@ -1537,7 +1630,7 @@ CHM_FILE = # The HHC_LOCATION tag can be used to specify the location (absolute path # including file name) of the HTML help compiler (hhc.exe). If non-empty, -# doxygen will try to run the HTML help compiler on the generated index.hhp. +# Doxygen will try to run the HTML help compiler on the generated index.hhp. # The file has to be specified with full path. # This tag requires that the tag GENERATE_HTMLHELP is set to YES. @@ -1639,7 +1732,7 @@ QHP_CUST_FILTER_ATTRS = QHP_SECT_FILTER_ATTRS = # The QHG_LOCATION tag can be used to specify the location (absolute path -# including file name) of Qt's qhelpgenerator. If non-empty doxygen will try to +# including file name) of Qt's qhelpgenerator. If non-empty Doxygen will try to # run qhelpgenerator on the generated .qhp file. # This tag requires that the tag GENERATE_QHP is set to YES. @@ -1674,7 +1767,7 @@ ECLIPSE_DOC_ID = org.doxygen.Project # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. -DISABLE_INDEX = YES +DISABLE_INDEX = NO # The GENERATE_TREEVIEW tag is used to specify whether a tree-like index # structure should be generated to display hierarchical information. If the tag @@ -1684,7 +1777,7 @@ DISABLE_INDEX = YES # (i.e. any modern browser). Windows users are probably better off using the # HTML help feature. Via custom style sheets (see HTML_EXTRA_STYLESHEET) one can # further fine tune the look of the index (see "Fine-tuning the output"). As an -# example, the default style sheet generated by doxygen has an example that +# example, the default style sheet generated by Doxygen has an example that # shows how to put an image at the root of the tree instead of the PROJECT_NAME. # Since the tree basically has the same information as the tab index, you could # consider setting DISABLE_INDEX to YES when enabling this option. @@ -1706,7 +1799,7 @@ GENERATE_TREEVIEW = YES FULL_SIDEBAR = NO # The ENUM_VALUES_PER_LINE tag can be used to set the number of enum values that -# doxygen will group on one line in the generated HTML documentation. +# Doxygen will group on one line in the generated HTML documentation. # # Note that a value of 0 will completely suppress the enum values from appearing # in the overview section. @@ -1715,6 +1808,12 @@ FULL_SIDEBAR = NO ENUM_VALUES_PER_LINE = 4 +# When the SHOW_ENUM_VALUES tag is set doxygen will show the specified +# enumeration values besides the enumeration mnemonics. +# The default value is: NO. + +SHOW_ENUM_VALUES = NO + # If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be used # to set the initial width (in pixels) of the frame in which the tree is shown. # Minimum value: 0, maximum value: 1500, default value: 250. @@ -1722,21 +1821,21 @@ ENUM_VALUES_PER_LINE = 4 TREEVIEW_WIDTH = 250 -# If the EXT_LINKS_IN_WINDOW option is set to YES, doxygen will open links to +# If the EXT_LINKS_IN_WINDOW option is set to YES, Doxygen will open links to # external symbols imported via tag files in a separate window. # The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. EXT_LINKS_IN_WINDOW = NO -# If the OBFUSCATE_EMAILS tag is set to YES, doxygen will obfuscate email +# If the OBFUSCATE_EMAILS tag is set to YES, Doxygen will obfuscate email # addresses. # The default value is: YES. # This tag requires that the tag GENERATE_HTML is set to YES. OBFUSCATE_EMAILS = YES -# If the HTML_FORMULA_FORMAT option is set to svg, doxygen will use the pdf2svg +# If the HTML_FORMULA_FORMAT option is set to svg, Doxygen will use the pdf2svg # tool (see https://github.com/dawbarton/pdf2svg) or inkscape (see # https://inkscape.org) to generate formulas as SVG images instead of PNGs for # the HTML output. These images will generally look nicer at scaled resolutions. @@ -1749,7 +1848,7 @@ HTML_FORMULA_FORMAT = png # Use this tag to change the font size of LaTeX formulas included as images in # the HTML documentation. When you change the font size after a successful -# doxygen run you need to manually remove any form_*.png images from the HTML +# Doxygen run you need to manually remove any form_*.png images from the HTML # output directory to force them to be regenerated. # Minimum value: 8, maximum value: 50, default value: 10. # This tag requires that the tag GENERATE_HTML is set to YES. @@ -1793,7 +1892,7 @@ MATHJAX_VERSION = MathJax_2 # Possible values are: HTML-CSS (which is slower, but has the best # compatibility. This is the name for Mathjax version 2, for MathJax version 3 # this will be translated into chtml), NativeMML (i.e. MathML. Only supported -# for NathJax 2. For MathJax version 3 chtml will be used instead.), chtml (This +# for MathJax 2. For MathJax version 3 chtml will be used instead.), chtml (This # is the name for Mathjax version 3, for MathJax version 2 this will be # translated into HTML-CSS) and SVG. # The default value is: HTML-CSS. @@ -1827,7 +1926,7 @@ MATHJAX_RELPATH = MATHJAX_EXTENSIONS = -# The MATHJAX_CODEFILE tag can be used to specify a file with javascript pieces +# The MATHJAX_CODEFILE tag can be used to specify a file with JavaScript pieces # of code that will be used on startup of the MathJax code. See the MathJax site # (see: # http://docs.mathjax.org/en/v2.7-latest/output.html) for more details. For an @@ -1836,12 +1935,12 @@ MATHJAX_EXTENSIONS = MATHJAX_CODEFILE = -# When the SEARCHENGINE tag is enabled doxygen will generate a search box for -# the HTML output. The underlying search engine uses javascript and DHTML and +# When the SEARCHENGINE tag is enabled Doxygen will generate a search box for +# the HTML output. The underlying search engine uses JavaScript and DHTML and # should work on any modern browser. Note that when using HTML help # (GENERATE_HTMLHELP), Qt help (GENERATE_QHP), or docsets (GENERATE_DOCSET) # there is already a search function so this one should typically be disabled. -# For large projects the javascript based search engine can be slow, then +# For large projects the JavaScript based search engine can be slow, then # enabling SERVER_BASED_SEARCH may provide a better solution. It is possible to # search using the keyboard; to jump to the search box use + S # (what the is depends on the OS and browser, but it is typically @@ -1860,7 +1959,7 @@ SEARCHENGINE = YES # When the SERVER_BASED_SEARCH tag is enabled the search engine will be # implemented using a web server instead of a web client using JavaScript. There # are two flavors of web server based searching depending on the EXTERNAL_SEARCH -# setting. When disabled, doxygen will generate a PHP script for searching and +# setting. When disabled, Doxygen will generate a PHP script for searching and # an index file used by the script. When EXTERNAL_SEARCH is enabled the indexing # and searching needs to be provided by external tools. See the section # "External Indexing and Searching" for details. @@ -1869,7 +1968,7 @@ SEARCHENGINE = YES SERVER_BASED_SEARCH = NO -# When EXTERNAL_SEARCH tag is enabled doxygen will no longer generate the PHP +# When EXTERNAL_SEARCH tag is enabled Doxygen will no longer generate the PHP # script for searching. Instead the search results are written to an XML file # which needs to be processed by an external indexer. Doxygen will invoke an # external search engine pointed to by the SEARCHENGINE_URL option to obtain the @@ -1914,7 +2013,7 @@ SEARCHDATA_FILE = searchdata.xml EXTERNAL_SEARCH_ID = -# The EXTRA_SEARCH_MAPPINGS tag can be used to enable searching through doxygen +# The EXTRA_SEARCH_MAPPINGS tag can be used to enable searching through Doxygen # projects other than the one defined by this configuration file, but that are # all added to the same external search index. Each project needs to have a # unique id set via EXTERNAL_SEARCH_ID. The search mapping then maps the id of @@ -1928,7 +2027,7 @@ EXTRA_SEARCH_MAPPINGS = # Configuration options related to the LaTeX output #--------------------------------------------------------------------------- -# If the GENERATE_LATEX tag is set to YES, doxygen will generate LaTeX output. +# If the GENERATE_LATEX tag is set to YES, Doxygen will generate LaTeX output. # The default value is: YES. GENERATE_LATEX = NO @@ -1973,7 +2072,7 @@ MAKEINDEX_CMD_NAME = makeindex LATEX_MAKEINDEX_CMD = makeindex -# If the COMPACT_LATEX tag is set to YES, doxygen generates more compact LaTeX +# If the COMPACT_LATEX tag is set to YES, Doxygen generates more compact LaTeX # documents. This may be useful for small projects and may help to save some # trees in general. # The default value is: NO. @@ -2004,15 +2103,15 @@ EXTRA_PACKAGES = # The LATEX_HEADER tag can be used to specify a user-defined LaTeX header for # the generated LaTeX document. The header should contain everything until the -# first chapter. If it is left blank doxygen will generate a standard header. It +# first chapter. If it is left blank Doxygen will generate a standard header. It # is highly recommended to start with a default header using # doxygen -w latex new_header.tex new_footer.tex new_stylesheet.sty # and then modify the file new_header.tex. See also section "Doxygen usage" for -# information on how to generate the default header that doxygen normally uses. +# information on how to generate the default header that Doxygen normally uses. # # Note: Only use a user-defined header if you know what you are doing! # Note: The header is subject to change so you typically have to regenerate the -# default header when upgrading to a newer version of doxygen. The following +# default header when upgrading to a newer version of Doxygen. The following # commands have a special meaning inside the header (and footer): For a # description of the possible markers and block names see the documentation. # This tag requires that the tag GENERATE_LATEX is set to YES. @@ -2021,10 +2120,10 @@ LATEX_HEADER = # The LATEX_FOOTER tag can be used to specify a user-defined LaTeX footer for # the generated LaTeX document. The footer should contain everything after the -# last chapter. If it is left blank doxygen will generate a standard footer. See +# last chapter. If it is left blank Doxygen will generate a standard footer. See # LATEX_HEADER for more information on how to generate a default footer and what # special commands can be used inside the footer. See also section "Doxygen -# usage" for information on how to generate the default footer that doxygen +# usage" for information on how to generate the default footer that Doxygen # normally uses. Note: Only use a user-defined footer if you know what you are # doing! # This tag requires that the tag GENERATE_LATEX is set to YES. @@ -2033,7 +2132,7 @@ LATEX_FOOTER = # The LATEX_EXTRA_STYLESHEET tag can be used to specify additional user-defined # LaTeX style sheets that are included after the standard style sheets created -# by doxygen. Using this option one can overrule certain style aspects. Doxygen +# by Doxygen. Using this option one can overrule certain style aspects. Doxygen # will copy the style sheet files to the output directory. # Note: The order of the extra style sheet files is of importance (e.g. the last # style sheet in the list overrules the setting of the previous ones in the @@ -2059,7 +2158,7 @@ LATEX_EXTRA_FILES = PDF_HYPERLINKS = YES -# If the USE_PDFLATEX tag is set to YES, doxygen will use the engine as +# If the USE_PDFLATEX tag is set to YES, Doxygen will use the engine as # specified with LATEX_CMD_NAME to generate the PDF file directly from the LaTeX # files. Set this option to YES, to get a higher quality PDF documentation. # @@ -2084,7 +2183,7 @@ USE_PDFLATEX = NO LATEX_BATCHMODE = NO -# If the LATEX_HIDE_INDICES tag is set to YES then doxygen will not include the +# If the LATEX_HIDE_INDICES tag is set to YES then Doxygen will not include the # index chapters (such as File Index, Compound Index, etc.) in the output. # The default value is: NO. # This tag requires that the tag GENERATE_LATEX is set to YES. @@ -2111,7 +2210,7 @@ LATEX_EMOJI_DIRECTORY = # Configuration options related to the RTF output #--------------------------------------------------------------------------- -# If the GENERATE_RTF tag is set to YES, doxygen will generate RTF output. The +# If the GENERATE_RTF tag is set to YES, Doxygen will generate RTF output. The # RTF output is optimized for Word 97 and may not look too pretty with other RTF # readers/editors. # The default value is: NO. @@ -2126,7 +2225,7 @@ GENERATE_RTF = NO RTF_OUTPUT = rtf -# If the COMPACT_RTF tag is set to YES, doxygen generates more compact RTF +# If the COMPACT_RTF tag is set to YES, Doxygen generates more compact RTF # documents. This may be useful for small projects and may help to save some # trees in general. # The default value is: NO. @@ -2146,28 +2245,36 @@ COMPACT_RTF = NO RTF_HYPERLINKS = NO -# Load stylesheet definitions from file. Syntax is similar to doxygen's +# Load stylesheet definitions from file. Syntax is similar to Doxygen's # configuration file, i.e. a series of assignments. You only have to provide # replacements, missing definitions are set to their default value. # # See also section "Doxygen usage" for information on how to generate the -# default style sheet that doxygen normally uses. +# default style sheet that Doxygen normally uses. # This tag requires that the tag GENERATE_RTF is set to YES. RTF_STYLESHEET_FILE = # Set optional variables used in the generation of an RTF document. Syntax is -# similar to doxygen's configuration file. A template extensions file can be +# similar to Doxygen's configuration file. A template extensions file can be # generated using doxygen -e rtf extensionFile. # This tag requires that the tag GENERATE_RTF is set to YES. RTF_EXTENSIONS_FILE = +# The RTF_EXTRA_FILES tag can be used to specify one or more extra images or +# other source files which should be copied to the RTF_OUTPUT output directory. +# Note that the files will be copied as-is; there are no commands or markers +# available. +# This tag requires that the tag GENERATE_RTF is set to YES. + +RTF_EXTRA_FILES = + #--------------------------------------------------------------------------- # Configuration options related to the man page output #--------------------------------------------------------------------------- -# If the GENERATE_MAN tag is set to YES, doxygen will generate man pages for +# If the GENERATE_MAN tag is set to YES, Doxygen will generate man pages for # classes and files. # The default value is: NO. @@ -2198,7 +2305,7 @@ MAN_EXTENSION = .3 MAN_SUBDIR = -# If the MAN_LINKS tag is set to YES and doxygen generates man output, then it +# If the MAN_LINKS tag is set to YES and Doxygen generates man output, then it # will generate one additional man file for each entity documented in the real # man page(s). These additional files only source the real man page, but without # them the man command would be unable to find the correct page. @@ -2211,7 +2318,7 @@ MAN_LINKS = NO # Configuration options related to the XML output #--------------------------------------------------------------------------- -# If the GENERATE_XML tag is set to YES, doxygen will generate an XML file that +# If the GENERATE_XML tag is set to YES, Doxygen will generate an XML file that # captures the structure of the code including all documentation. # The default value is: NO. @@ -2225,7 +2332,7 @@ GENERATE_XML = NO XML_OUTPUT = xml -# If the XML_PROGRAMLISTING tag is set to YES, doxygen will dump the program +# If the XML_PROGRAMLISTING tag is set to YES, Doxygen will dump the program # listings (including syntax highlighting and cross-referencing information) to # the XML output. Note that enabling this will significantly increase the size # of the XML output. @@ -2234,7 +2341,7 @@ XML_OUTPUT = xml XML_PROGRAMLISTING = YES -# If the XML_NS_MEMB_FILE_SCOPE tag is set to YES, doxygen will include +# If the XML_NS_MEMB_FILE_SCOPE tag is set to YES, Doxygen will include # namespace members in file scope as well, matching the HTML output. # The default value is: NO. # This tag requires that the tag GENERATE_XML is set to YES. @@ -2245,7 +2352,7 @@ XML_NS_MEMB_FILE_SCOPE = NO # Configuration options related to the DOCBOOK output #--------------------------------------------------------------------------- -# If the GENERATE_DOCBOOK tag is set to YES, doxygen will generate Docbook files +# If the GENERATE_DOCBOOK tag is set to YES, Doxygen will generate Docbook files # that can be used to generate PDF. # The default value is: NO. @@ -2263,7 +2370,7 @@ DOCBOOK_OUTPUT = docbook # Configuration options for the AutoGen Definitions output #--------------------------------------------------------------------------- -# If the GENERATE_AUTOGEN_DEF tag is set to YES, doxygen will generate an +# If the GENERATE_AUTOGEN_DEF tag is set to YES, Doxygen will generate an # AutoGen Definitions (see https://autogen.sourceforge.net/) file that captures # the structure of the code including all documentation. Note that this feature # is still experimental and incomplete at the moment. @@ -2275,8 +2382,8 @@ GENERATE_AUTOGEN_DEF = NO # Configuration options related to Sqlite3 output #--------------------------------------------------------------------------- -# If the GENERATE_SQLITE3 tag is set to YES doxygen will generate a Sqlite3 -# database with symbols found by doxygen stored in tables. +# If the GENERATE_SQLITE3 tag is set to YES Doxygen will generate a Sqlite3 +# database with symbols found by Doxygen stored in tables. # The default value is: NO. GENERATE_SQLITE3 = NO @@ -2289,9 +2396,9 @@ GENERATE_SQLITE3 = NO SQLITE3_OUTPUT = sqlite3 -# The SQLITE3_OVERWRITE_DB tag is set to YES, the existing doxygen_sqlite3.db -# database file will be recreated with each doxygen run. If set to NO, doxygen -# will warn if an a database file is already found and not modify it. +# The SQLITE3_RECREATE_DB tag is set to YES, the existing doxygen_sqlite3.db +# database file will be recreated with each Doxygen run. If set to NO, Doxygen +# will warn if a database file is already found and not modify it. # The default value is: YES. # This tag requires that the tag GENERATE_SQLITE3 is set to YES. @@ -2301,7 +2408,7 @@ SQLITE3_RECREATE_DB = YES # Configuration options related to the Perl module output #--------------------------------------------------------------------------- -# If the GENERATE_PERLMOD tag is set to YES, doxygen will generate a Perl module +# If the GENERATE_PERLMOD tag is set to YES, Doxygen will generate a Perl module # file that captures the structure of the code including all documentation. # # Note that this feature is still experimental and incomplete at the moment. @@ -2309,7 +2416,7 @@ SQLITE3_RECREATE_DB = YES GENERATE_PERLMOD = NO -# If the PERLMOD_LATEX tag is set to YES, doxygen will generate the necessary +# If the PERLMOD_LATEX tag is set to YES, Doxygen will generate the necessary # Makefile rules, Perl scripts and LaTeX code to be able to generate PDF and DVI # output from the Perl module output. # The default value is: NO. @@ -2339,13 +2446,13 @@ PERLMOD_MAKEVAR_PREFIX = # Configuration options related to the preprocessor #--------------------------------------------------------------------------- -# If the ENABLE_PREPROCESSING tag is set to YES, doxygen will evaluate all +# If the ENABLE_PREPROCESSING tag is set to YES, Doxygen will evaluate all # C-preprocessor directives found in the sources and include files. # The default value is: YES. ENABLE_PREPROCESSING = YES -# If the MACRO_EXPANSION tag is set to YES, doxygen will expand all macro names +# If the MACRO_EXPANSION tag is set to YES, Doxygen will expand all macro names # in the source code. If set to NO, only conditional compilation will be # performed. Macro expansion can be done in a controlled way by setting # EXPAND_ONLY_PREDEF to YES. @@ -2404,7 +2511,7 @@ PREDEFINED = EXPAND_AS_DEFINED = -# If the SKIP_FUNCTION_MACROS tag is set to YES then doxygen's preprocessor will +# If the SKIP_FUNCTION_MACROS tag is set to YES then Doxygen's preprocessor will # remove all references to function-like macros that are alone on a line, have # an all uppercase name, and do not end with a semicolon. Such function macros # are typically used for boiler-plate code, and will confuse the parser if not @@ -2428,12 +2535,12 @@ SKIP_FUNCTION_MACROS = YES # section "Linking to external documentation" for more information about the use # of tag files. # Note: Each tag file must have a unique name (where the name does NOT include -# the path). If a tag file is not located in the directory in which doxygen is +# the path). If a tag file is not located in the directory in which Doxygen is # run, you must also specify the path to the tagfile here. TAGFILES = -# When a file name is specified after GENERATE_TAGFILE, doxygen will create a +# When a file name is specified after GENERATE_TAGFILE, Doxygen will create a # tag file that is based on the input files it reads. See section "Linking to # external documentation" for more information about the usage of tag files. @@ -2470,7 +2577,7 @@ EXTERNAL_PAGES = YES HIDE_UNDOC_RELATIONS = YES -# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is +# If you set the HAVE_DOT tag to YES then Doxygen will assume the dot tool is # available from the path. This tool is part of Graphviz (see: # https://www.graphviz.org/), a graph visualization toolkit from AT&T and Lucent # Bell Labs. The other options in this section have no effect if this option is @@ -2479,8 +2586,8 @@ HIDE_UNDOC_RELATIONS = YES HAVE_DOT = NO -# The DOT_NUM_THREADS specifies the number of dot invocations doxygen is allowed -# to run in parallel. When set to 0 doxygen will base this on the number of +# The DOT_NUM_THREADS specifies the number of dot invocations Doxygen is allowed +# to run in parallel. When set to 0 Doxygen will base this on the number of # processors available in the system. You can set it explicitly to a value # larger than 0 to get control over the balance between CPU load and processing # speed. @@ -2491,7 +2598,7 @@ DOT_NUM_THREADS = 0 # DOT_COMMON_ATTR is common attributes for nodes, edges and labels of # subgraphs. When you want a differently looking font in the dot files that -# doxygen generates you can specify fontname, fontcolor and fontsize attributes. +# Doxygen generates you can specify fontname, fontcolor and fontsize attributes. # For details please see Node, # Edge and Graph Attributes specification You need to make sure dot is able # to find the font, which can be done by putting it in a standard location or by @@ -2525,20 +2632,24 @@ DOT_NODE_ATTR = "shape=box,height=0.2,width=0.4" DOT_FONTPATH = -# If the CLASS_GRAPH tag is set to YES or GRAPH or BUILTIN then doxygen will +# If the CLASS_GRAPH tag is set to YES or GRAPH or BUILTIN then Doxygen will # generate a graph for each documented class showing the direct and indirect # inheritance relations. In case the CLASS_GRAPH tag is set to YES or GRAPH and # HAVE_DOT is enabled as well, then dot will be used to draw the graph. In case # the CLASS_GRAPH tag is set to YES and HAVE_DOT is disabled or if the # CLASS_GRAPH tag is set to BUILTIN, then the built-in generator will be used. # If the CLASS_GRAPH tag is set to TEXT the direct and indirect inheritance -# relations will be shown as texts / links. +# relations will be shown as texts / links. Explicit enabling an inheritance +# graph or choosing a different representation for an inheritance graph of a +# specific class, can be accomplished by means of the command \inheritancegraph. +# Disabling an inheritance graph can be accomplished by means of the command +# \hideinheritancegraph. # Possible values are: NO, YES, TEXT, GRAPH and BUILTIN. # The default value is: YES. CLASS_GRAPH = YES -# If the COLLABORATION_GRAPH tag is set to YES then doxygen will generate a +# If the COLLABORATION_GRAPH tag is set to YES then Doxygen will generate a # graph for each documented class showing the direct and indirect implementation # dependencies (inheritance, containment, and class references variables) of the # class with other documented classes. Explicit enabling a collaboration graph, @@ -2550,7 +2661,7 @@ CLASS_GRAPH = YES COLLABORATION_GRAPH = YES -# If the GROUP_GRAPHS tag is set to YES then doxygen will generate a graph for +# If the GROUP_GRAPHS tag is set to YES then Doxygen will generate a graph for # groups, showing the direct groups dependencies. Explicit enabling a group # dependency graph, when GROUP_GRAPHS is set to NO, can be accomplished by means # of the command \groupgraph. Disabling a directory graph can be accomplished by @@ -2561,7 +2672,7 @@ COLLABORATION_GRAPH = YES GROUP_GRAPHS = YES -# If the UML_LOOK tag is set to YES, doxygen will generate inheritance and +# If the UML_LOOK tag is set to YES, Doxygen will generate inheritance and # collaboration diagrams in a style similar to the OMG's Unified Modeling # Language. # The default value is: NO. @@ -2582,10 +2693,10 @@ UML_LOOK = NO UML_LIMIT_NUM_FIELDS = 10 -# If the DOT_UML_DETAILS tag is set to NO, doxygen will show attributes and +# If the DOT_UML_DETAILS tag is set to NO, Doxygen will show attributes and # methods without types and arguments in the UML graphs. If the DOT_UML_DETAILS -# tag is set to YES, doxygen will add type and arguments for attributes and -# methods in the UML graphs. If the DOT_UML_DETAILS tag is set to NONE, doxygen +# tag is set to YES, Doxygen will add type and arguments for attributes and +# methods in the UML graphs. If the DOT_UML_DETAILS tag is set to NONE, Doxygen # will not generate fields with class member information in the UML graphs. The # class diagrams will look similar to the default class diagrams but using UML # notation for the relationships. @@ -2597,8 +2708,8 @@ DOT_UML_DETAILS = NO # The DOT_WRAP_THRESHOLD tag can be used to set the maximum number of characters # to display on a single line. If the actual line length exceeds this threshold -# significantly it will wrapped across multiple lines. Some heuristics are apply -# to avoid ugly line breaks. +# significantly it will be wrapped across multiple lines. Some heuristics are +# applied to avoid ugly line breaks. # Minimum value: 0, maximum value: 1000, default value: 17. # This tag requires that the tag HAVE_DOT is set to YES. @@ -2613,7 +2724,7 @@ DOT_WRAP_THRESHOLD = 17 TEMPLATE_RELATIONS = NO # If the INCLUDE_GRAPH, ENABLE_PREPROCESSING and SEARCH_INCLUDES tags are set to -# YES then doxygen will generate a graph for each documented file showing the +# YES then Doxygen will generate a graph for each documented file showing the # direct and indirect include dependencies of the file with other documented # files. Explicit enabling an include graph, when INCLUDE_GRAPH is is set to NO, # can be accomplished by means of the command \includegraph. Disabling an @@ -2624,7 +2735,7 @@ TEMPLATE_RELATIONS = NO INCLUDE_GRAPH = YES # If the INCLUDED_BY_GRAPH, ENABLE_PREPROCESSING and SEARCH_INCLUDES tags are -# set to YES then doxygen will generate a graph for each documented file showing +# set to YES then Doxygen will generate a graph for each documented file showing # the direct and indirect include dependencies of the file with other documented # files. Explicit enabling an included by graph, when INCLUDED_BY_GRAPH is set # to NO, can be accomplished by means of the command \includedbygraph. Disabling @@ -2635,7 +2746,7 @@ INCLUDE_GRAPH = YES INCLUDED_BY_GRAPH = YES -# If the CALL_GRAPH tag is set to YES then doxygen will generate a call +# If the CALL_GRAPH tag is set to YES then Doxygen will generate a call # dependency graph for every global function or class method. # # Note that enabling this option will significantly increase the time of a run. @@ -2647,7 +2758,7 @@ INCLUDED_BY_GRAPH = YES CALL_GRAPH = NO -# If the CALLER_GRAPH tag is set to YES then doxygen will generate a caller +# If the CALLER_GRAPH tag is set to YES then Doxygen will generate a caller # dependency graph for every global function or class method. # # Note that enabling this option will significantly increase the time of a run. @@ -2659,14 +2770,14 @@ CALL_GRAPH = NO CALLER_GRAPH = NO -# If the GRAPHICAL_HIERARCHY tag is set to YES then doxygen will graphical +# If the GRAPHICAL_HIERARCHY tag is set to YES then Doxygen will graphical # hierarchy of all classes instead of a textual one. # The default value is: YES. # This tag requires that the tag HAVE_DOT is set to YES. GRAPHICAL_HIERARCHY = YES -# If the DIRECTORY_GRAPH tag is set to YES then doxygen will show the +# If the DIRECTORY_GRAPH tag is set to YES then Doxygen will show the # dependencies a directory has on other directories in a graphical way. The # dependency relations are determined by the #include relations between the # files in the directories. Explicit enabling a directory graph, when @@ -2725,7 +2836,7 @@ DOT_PATH = DOTFILE_DIRS = -# You can include diagrams made with dia in doxygen documentation. Doxygen will +# You can include diagrams made with dia in Doxygen documentation. Doxygen will # then run dia to produce the diagram and insert it in the documentation. The # DIA_PATH tag allows you to specify the directory where the dia binary resides. # If left empty dia is assumed to be found in the default search path. @@ -2738,7 +2849,7 @@ DIA_PATH = DIAFILE_DIRS = -# When using plantuml, the PLANTUML_JAR_PATH tag should be used to specify the +# When using PlantUML, the PLANTUML_JAR_PATH tag should be used to specify the # path where java can find the plantuml.jar file or to the filename of jar file # to be used. If left blank, it is assumed PlantUML is not used or called during # a preprocessing step. Doxygen will generate a warning when it encounters a @@ -2746,20 +2857,20 @@ DIAFILE_DIRS = PLANTUML_JAR_PATH = -# When using plantuml, the PLANTUML_CFG_FILE tag can be used to specify a -# configuration file for plantuml. +# When using PlantUML, the PLANTUML_CFG_FILE tag can be used to specify a +# configuration file for PlantUML. PLANTUML_CFG_FILE = -# When using plantuml, the specified paths are searched for files specified by -# the !include statement in a plantuml block. +# When using PlantUML, the specified paths are searched for files specified by +# the !include statement in a PlantUML block. PLANTUML_INCLUDE_PATH = # The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of nodes # that will be shown in the graph. If the number of nodes in a graph becomes -# larger than this value, doxygen will truncate the graph, which is visualized -# by representing a node as a red box. Note that doxygen if the number of direct +# larger than this value, Doxygen will truncate the graph, which is visualized +# by representing a node as a red box. Note that if the number of direct # children of the root node in a graph is already larger than # DOT_GRAPH_MAX_NODES then the graph will not be shown at all. Also note that # the size of a graph can be further restricted by MAX_DOT_GRAPH_DEPTH. @@ -2789,17 +2900,17 @@ MAX_DOT_GRAPH_DEPTH = 0 DOT_MULTI_TARGETS = NO -# If the GENERATE_LEGEND tag is set to YES doxygen will generate a legend page +# If the GENERATE_LEGEND tag is set to YES Doxygen will generate a legend page # explaining the meaning of the various boxes and arrows in the dot generated # graphs. -# Note: This tag requires that UML_LOOK isn't set, i.e. the doxygen internal +# Note: This tag requires that UML_LOOK isn't set, i.e. the Doxygen internal # graphical representation for inheritance and collaboration diagrams is used. # The default value is: YES. # This tag requires that the tag HAVE_DOT is set to YES. GENERATE_LEGEND = YES -# If the DOT_CLEANUP tag is set to YES, doxygen will remove the intermediate +# If the DOT_CLEANUP tag is set to YES, Doxygen will remove the intermediate # files that are used to generate the various graphs. # # Note: This setting is not only used for dot files but also for msc temporary @@ -2808,11 +2919,11 @@ GENERATE_LEGEND = YES DOT_CLEANUP = YES -# You can define message sequence charts within doxygen comments using the \msc -# command. If the MSCGEN_TOOL tag is left empty (the default), then doxygen will +# You can define message sequence charts within Doxygen comments using the \msc +# command. If the MSCGEN_TOOL tag is left empty (the default), then Doxygen will # use a built-in version of mscgen tool to produce the charts. Alternatively, # the MSCGEN_TOOL tag can also specify the name an external tool. For instance, -# specifying prog as the value, doxygen will call the tool as prog -T +# specifying prog as the value, Doxygen will call the tool as prog -T # -o . The external tool should support # output file formats "png", "eps", "svg", and "ismap". diff --git a/DoxygenLayout.xml b/DoxygenLayout.xml index 1bbe4ddff..c986f0eb9 100644 --- a/DoxygenLayout.xml +++ b/DoxygenLayout.xml @@ -1,11 +1,15 @@ - + - + + + + + @@ -43,7 +47,7 @@ - + @@ -115,6 +119,7 @@ + @@ -126,6 +131,7 @@ + @@ -161,6 +167,7 @@ + @@ -173,6 +180,7 @@ + diff --git a/docs/custom.css b/docs/custom.css new file mode 100644 index 000000000..378ed29bd --- /dev/null +++ b/docs/custom.css @@ -0,0 +1,19 @@ +/* table.memberdecls .memItemLeft, +table.memberdecls .memItemRight, +table.memberdecls .memTemplItemLeft, +table.memberdecls .memTemplItemRight, +table.memberdecls .memTemplParams { + transition: none; + padding-top: var(--spacing-small); + padding-bottom: var(--spacing-small); + border-top: 1px solid var(--separator-color); + border-bottom: 1px solid var(--separator-color); + background-color: var(--fragment-background); +} */ + +html { + --spacing-small: 1px; + --spacing-medium: 5px; + --spacing-large: 10px; + --content-maxwidth: auto; +} \ No newline at end of file diff --git a/docs/doxygen-awesome-css b/docs/doxygen-awesome-css new file mode 160000 index 000000000..568f56cde --- /dev/null +++ b/docs/doxygen-awesome-css @@ -0,0 +1 @@ +Subproject commit 568f56cde6ac78b6dfcc14acd380b2e745c301ea diff --git a/docs/header.html b/docs/header.html new file mode 100644 index 000000000..f4ac330ea --- /dev/null +++ b/docs/header.html @@ -0,0 +1,89 @@ + + + + + + + + +$projectname: $title +$title + + + + + + + + + + + + + + +$treeview +$search +$mathjax +$darkmode + +$extrastylesheet + + + + + + + + + +
+ + + +
+ + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
$projectname $projectnumber +
+
$projectbrief
+
+
$projectbrief
+
$searchbox
$searchbox
+
+ + diff --git a/docs/readme.md b/docs/readme.md index d67261834..59a513451 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -1,4 +1,4 @@ -# Getting started +# Manual documentation [TOC] From 00eaa4827804698c83b140e11f548f222941f966 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 12 Oct 2024 20:38:00 +0000 Subject: [PATCH 30/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- docs/custom.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/custom.css b/docs/custom.css index 378ed29bd..cc6c91858 100644 --- a/docs/custom.css +++ b/docs/custom.css @@ -16,4 +16,4 @@ html { --spacing-medium: 5px; --spacing-large: 10px; --content-maxwidth: auto; -} \ No newline at end of file +} From 22623292a210fa4ce588a35a618cd4539da8796d Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sun, 13 Oct 2024 19:23:52 +0300 Subject: [PATCH 31/41] minor changes --- DoxygenLayout.xml | 2 +- docs/readme.md | 4 +--- src/rpp/rpp/operators.hpp | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/DoxygenLayout.xml b/DoxygenLayout.xml index c986f0eb9..1003c8215 100644 --- a/DoxygenLayout.xml +++ b/DoxygenLayout.xml @@ -5,7 +5,7 @@ - + diff --git a/docs/readme.md b/docs/readme.md index 59a513451..013c681ac 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -7,7 +7,6 @@ > [!IMPORTANT] > It's highly recommended to read this article beforehand: [The introduction to Reactive Programming you've been missing](https://gist.github.com/staltz/868e7e9bc2a7b8c1f754) -### What is Reactive Programming? **Reactive programming** is a *design paradigm* that focuses on building applications that can efficiently respond to asynchronous **events**. @@ -50,7 +49,7 @@ Reactive programming is a powerful way to handle input that is **distributed in See for more details. -### Core Concepts of Reactive Programming +## Core Concepts Reactive Programming can be described as follows: @@ -128,7 +127,6 @@ See for more details. In such an way it is not powerful enough, so Reactive Programming provides a list of **operators**. -## Documentation ### Observable contract \copydoc observables diff --git a/src/rpp/rpp/operators.hpp b/src/rpp/rpp/operators.hpp index 1d2fb982d..aed7680a6 100644 --- a/src/rpp/rpp/operators.hpp +++ b/src/rpp/rpp/operators.hpp @@ -32,7 +32,7 @@ * * // input: 12345qwer5125ttqt0 * // output: QWERTTQT - * + * * return 0; * } * @endcode From 2d48f438015aab897c964b4a2c0898b48b9b2882 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sun, 13 Oct 2024 19:40:47 +0300 Subject: [PATCH 32/41] Improve readability --- Doxyfile | 4 +-- DoxygenLayout.xml | 70 ++++++++++++++++++++++++----------------------- docs/custom.css | 2 ++ 3 files changed, 40 insertions(+), 36 deletions(-) diff --git a/Doxyfile b/Doxyfile index a43265856..f08b6bd9d 100644 --- a/Doxyfile +++ b/Doxyfile @@ -367,7 +367,7 @@ MARKDOWN_SUPPORT = YES # Minimum value: 0, maximum value: 99, default value: 6. # This tag requires that the tag MARKDOWN_SUPPORT is set to YES. -TOC_INCLUDE_HEADINGS = 6 +TOC_INCLUDE_HEADINGS = 99 # The MARKDOWN_ID_STYLE tag can be used to specify the algorithm used to # generate identifiers for the Markdown headings. Note: Every identifier is @@ -1545,7 +1545,7 @@ HTML_PROJECT_COOKIE = # Minimum value: 0, maximum value: 9999, default value: 100. # This tag requires that the tag GENERATE_HTML is set to YES. -HTML_INDEX_NUM_ENTRIES = 100 +HTML_INDEX_NUM_ENTRIES = 9999 # If the GENERATE_DOCSET tag is set to YES, additional index files will be # generated that can be used as input for Apple's Xcode 3 integrated development diff --git a/DoxygenLayout.xml b/DoxygenLayout.xml index 1003c8215..a9abc09f5 100644 --- a/DoxygenLayout.xml +++ b/DoxygenLayout.xml @@ -6,41 +6,43 @@ - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/docs/custom.css b/docs/custom.css index cc6c91858..97ca2ca8d 100644 --- a/docs/custom.css +++ b/docs/custom.css @@ -16,4 +16,6 @@ html { --spacing-medium: 5px; --spacing-large: 10px; --content-maxwidth: auto; + --side-nav-arrow-opacity: 0.3; + --side-nav-arrow-hover-opacity: 0.99; } From 9a7b872173efadb369fa53a27ef2f633fa18f751 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sun, 13 Oct 2024 16:40:29 +0000 Subject: [PATCH 33/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/rpp/rpp/operators.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rpp/rpp/operators.hpp b/src/rpp/rpp/operators.hpp index aed7680a6..1d2fb982d 100644 --- a/src/rpp/rpp/operators.hpp +++ b/src/rpp/rpp/operators.hpp @@ -32,7 +32,7 @@ * * // input: 12345qwer5125ttqt0 * // output: QWERTTQT - * + * * return 0; * } * @endcode From 217f9653746063f8a6580d33b3f1537f89bd6d25 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sun, 13 Oct 2024 19:45:26 +0300 Subject: [PATCH 34/41] revert a bit --- Doxyfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doxyfile b/Doxyfile index f08b6bd9d..7fc2f7bc0 100644 --- a/Doxyfile +++ b/Doxyfile @@ -367,7 +367,7 @@ MARKDOWN_SUPPORT = YES # Minimum value: 0, maximum value: 99, default value: 6. # This tag requires that the tag MARKDOWN_SUPPORT is set to YES. -TOC_INCLUDE_HEADINGS = 99 +TOC_INCLUDE_HEADINGS = 6 # The MARKDOWN_ID_STYLE tag can be used to specify the algorithm used to # generate identifiers for the Markdown headings. Note: Every identifier is From 51e0ed19a2ccd315c85750a97b5cd9e81ed7f2e7 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sun, 13 Oct 2024 20:05:35 +0300 Subject: [PATCH 35/41] minor --- src/extensions/rppqt/rppqt/fwd.hpp | 2 +- src/rpp/rpp/fwd.hpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/extensions/rppqt/rppqt/fwd.hpp b/src/extensions/rppqt/rppqt/fwd.hpp index b3e0931ca..dc70c68d7 100644 --- a/src/extensions/rppqt/rppqt/fwd.hpp +++ b/src/extensions/rppqt/rppqt/fwd.hpp @@ -12,7 +12,7 @@ /** * @defgroup rppqt rppqt - * @details RppQt is extension of RPP which enables support of Qt library. + * @brief RppQt is extension of RPP which enables support of Qt library. * * @par Example: * @snippet qt_readme.cpp readme diff --git a/src/rpp/rpp/fwd.hpp b/src/rpp/rpp/fwd.hpp index 13ee912bc..45db24c23 100644 --- a/src/rpp/rpp/fwd.hpp +++ b/src/rpp/rpp/fwd.hpp @@ -19,7 +19,7 @@ */ /** - * @defgroup rpp_extensions rpp exensions + * @defgroup rpp_extensions Extensions * @brief Extensions for ReactivePlusPlus library for 3rd party libraries */ From 956059f5487a93651f37a5a458dde029dcb218a8 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sun, 13 Oct 2024 22:11:12 +0300 Subject: [PATCH 36/41] qt, grpc --- src/examples/rppqt/doxygen/qt_readme.cpp | 2 +- src/extensions/rppgrpc/rppgrpc/fwd.hpp | 8 ++++++++ src/extensions/rppqt/rppqt/fwd.hpp | 4 +++- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/src/examples/rppqt/doxygen/qt_readme.cpp b/src/examples/rppqt/doxygen/qt_readme.cpp index 8f163a579..55af74329 100644 --- a/src/examples/rppqt/doxygen/qt_readme.cpp +++ b/src/examples/rppqt/doxygen/qt_readme.cpp @@ -27,7 +27,7 @@ int main(int argc, char** argv) // NOLINT(bugprone-exception-escape) | rpp::operators::observe_on(rppqt::schedulers::main_thread_scheduler{}) // <--- go back to main QT scheduler | rpp::operators::subscribe([&label](int clicks) { label->setText(QString{"Clicked %1 times in total!"}.arg(clicks)); - }); + }); // ![readme] QMainWindow window{}; diff --git a/src/extensions/rppgrpc/rppgrpc/fwd.hpp b/src/extensions/rppgrpc/rppgrpc/fwd.hpp index 1ec822c66..6b6417559 100644 --- a/src/extensions/rppgrpc/rppgrpc/fwd.hpp +++ b/src/extensions/rppgrpc/rppgrpc/fwd.hpp @@ -15,6 +15,14 @@ /** * @defgroup rppgrpc rppgrpc * @brief RppGrpc is extension of RPP which enables support of grpc library. + * @details gRPC provides way to handle requests and responses with help of reactors. RppGrpc is set of reactors (for both: client and server side) with all possible stream modes (client, server or bidirectional stream) to pass such an reactors to gRPC and handle them via RPP. + * + * @par Server-side example: + * @snippet server_reactor.cpp bidi_reactor + * + * @par Client-side example: + * @snippet client_reactor.cpp bidi_reactor + * * @ingroup rpp_extensions */ diff --git a/src/extensions/rppqt/rppqt/fwd.hpp b/src/extensions/rppqt/rppqt/fwd.hpp index dc70c68d7..b0bff930e 100644 --- a/src/extensions/rppqt/rppqt/fwd.hpp +++ b/src/extensions/rppqt/rppqt/fwd.hpp @@ -13,15 +13,17 @@ /** * @defgroup rppqt rppqt * @brief RppQt is extension of RPP which enables support of Qt library. + * @details RppQt is set of wrappers to connect QT world with RPP. * * @par Example: * @snippet qt_readme.cpp readme + * * @ingroup rpp_extensions */ /** * @defgroup qt_operators QT Operators - * @brief QT Operators is way to modify observables and extend with some extra custom logic but applied for QObjects + * @brief QT Operators is set of RPP operators but applied to QObjects. * @ingroup rppqt */ From a6ed81c9b99210640fb61a3c457e606b6eb495ae Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sun, 13 Oct 2024 19:10:53 +0000 Subject: [PATCH 37/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/examples/rppqt/doxygen/qt_readme.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/examples/rppqt/doxygen/qt_readme.cpp b/src/examples/rppqt/doxygen/qt_readme.cpp index 55af74329..8f163a579 100644 --- a/src/examples/rppqt/doxygen/qt_readme.cpp +++ b/src/examples/rppqt/doxygen/qt_readme.cpp @@ -27,7 +27,7 @@ int main(int argc, char** argv) // NOLINT(bugprone-exception-escape) | rpp::operators::observe_on(rppqt::schedulers::main_thread_scheduler{}) // <--- go back to main QT scheduler | rpp::operators::subscribe([&label](int clicks) { label->setText(QString{"Clicked %1 times in total!"}.arg(clicks)); - }); + }); // ![readme] QMainWindow window{}; From a935837a9df44b37498ce2cb5a7663d0e09992a3 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sun, 13 Oct 2024 22:18:38 +0300 Subject: [PATCH 38/41] extensions --- docs/readme.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/docs/readme.md b/docs/readme.md index 013c681ac..4780782be 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -410,3 +410,23 @@ rpp::source::just(1,2,3) return observable | rpp::ops::filter([](int v){ return v % 2 == 0;}); }); ``` + +## Extensions: + +RPP is library to build reactive streams. But in general applicaton uses some another framework/library to build core logic of application. With some of them RPP can be unified to build much more better software. +Below you can find list of extensions for RPP with adaption to external frameworks for much more easiser integeration with RPP. These extensions are part of RPP library: + +### rppqt + +\copydoc rppqt +Check API reference of \link rppqt \endlink for more details + +### rppgrpc + +\copydoc rppgrpc +Check API reference of \link rppgrpc \endlink for more details + +### rppasio + +\copydoc rppasio +Check API reference of \link rppasio \endlink for more details From 8a59ee163bbfd61b429e584536b805c09aa83c86 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sun, 13 Oct 2024 19:18:18 +0000 Subject: [PATCH 39/41] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- docs/readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/readme.md b/docs/readme.md index 4780782be..b373fd0cf 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -413,7 +413,7 @@ return observable | rpp::ops::filter([](int v){ return v % 2 == 0;}); ## Extensions: -RPP is library to build reactive streams. But in general applicaton uses some another framework/library to build core logic of application. With some of them RPP can be unified to build much more better software. +RPP is library to build reactive streams. But in general applicaton uses some another framework/library to build core logic of application. With some of them RPP can be unified to build much more better software. Below you can find list of extensions for RPP with adaption to external frameworks for much more easiser integeration with RPP. These extensions are part of RPP library: ### rppqt From 5bbe662a7cc710dd2e532b798f6137380626ed24 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sun, 13 Oct 2024 22:20:06 +0300 Subject: [PATCH 40/41] adapt ci --- .github/workflows/ci v2.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci v2.yml b/.github/workflows/ci v2.yml index 55579cf7a..480172004 100644 --- a/.github/workflows/ci v2.yml +++ b/.github/workflows/ci v2.yml @@ -217,6 +217,8 @@ jobs: steps: - uses: actions/checkout@v4 + with: + submodules: true - uses: actions/setup-python@v5 with: { python-version: "3.8" } From 0dbdbc485544b52c23fc3c21cb60de8fabd67239 Mon Sep 17 00:00:00 2001 From: Aleksey Loginov Date: Sun, 13 Oct 2024 22:46:38 +0300 Subject: [PATCH 41/41] credit --- Readme.md | 1 + 1 file changed, 1 insertion(+) diff --git a/Readme.md b/Readme.md index f024e8138..84eb55278 100644 --- a/Readme.md +++ b/Readme.md @@ -132,3 +132,4 @@ ReactivePlusPlus library uses: - [reactivex.io](https://reactivex.io) as source for insipration and definition of entities used in RPP. Some comments used in RPP source code taken from [reactivex.io](https://reactivex.io) - [rxmarbles python](https://pypi.org/project/rxmarbles/) as generator of marbles graphs in doxygen documentation - [cmake-init](https://github.com/friendlyanon/cmake-init) as generator for most part of initial CMakes +- [doxygen-awesome-css](https://jothepro.github.io/doxygen-awesome-css/) as CSS theme for doxygen documentation