You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am kind of struggling to translate the Intro to Rx article into something that will help me use RxCpp. I am not looking for examples that parallel the ranges examples, but rather on how to construct my own observables, oberservers, and (more likely) subjects.
As background: I have a library that will need to process an asynchronous data stream, where the underlying API is a given. No API call is synchronous. Any response, error or reply, comes in through a message stream and is handed off to a callback that I can register with the API. The callback has to check what kind of message it has followed by message-specific attempts to match the message to a previous request. What appears to work well in C# using the .Net version of Rx, is registering collections of Subjects for each kind of message. Then the message dispatcher can just look up the collection of subscribers and call OnNext, OnError, or OnCompleted as needed. The user of my library can perform any request needed, receiving an Observable that it can subscribe to, or if the reply is known to be a single message, do a blocking Get().
I would have expected to be able to use the same approach in C++, but cannot find any hints on how to use RxCpp in this manner. The namespace structure does not match the packages in C# or Java and many of the classes from those implementations I cannot find. The online Doxygen documentation for most RxCpp classes looks pretty empty.
The text was updated successfully, but these errors were encountered:
If it is applicable for you, you can use ReactivePlusPlus documentation (ReactivePlusPlus is re-implementation of RxCpp on C++20). Most of the documentation and details are absolutely applicable to RxCpp
Thank you. Operators were the last part for me to look at, as my library will produce observables or receive observers, rather than use them. I'll have a look at ReactivePlusPlus and the documentation. C++20 is my own target, so I hope you don't mind if I check it out a bit further.
I am kind of struggling to translate the Intro to Rx article into something that will help me use RxCpp. I am not looking for examples that parallel the ranges examples, but rather on how to construct my own
observable
s,oberserver
s, and (more likely)subject
s.As background: I have a library that will need to process an asynchronous data stream, where the underlying API is a given. No API call is synchronous. Any response, error or reply, comes in through a message stream and is handed off to a callback that I can register with the API. The callback has to check what kind of message it has followed by message-specific attempts to match the message to a previous request. What appears to work well in C# using the .Net version of Rx, is registering collections of Subjects for each kind of message. Then the message dispatcher can just look up the collection of subscribers and call
OnNext
,OnError
, orOnCompleted
as needed. The user of my library can perform any request needed, receiving anObservable
that it can subscribe to, or if the reply is known to be a single message, do a blockingGet()
.I would have expected to be able to use the same approach in C++, but cannot find any hints on how to use RxCpp in this manner. The namespace structure does not match the packages in C# or Java and many of the classes from those implementations I cannot find. The online Doxygen documentation for most RxCpp classes looks pretty empty.
The text was updated successfully, but these errors were encountered: