Documentation about JetBrains/rd (LifetimeDefinition, IPropertyView, etc) Follow
I noticed some plugin using `rd` (Reactive Distributed) types. However I wasn't able to find any proper documentation. From what I think I understood from the project some of the Kotlin types are generated from C#, right ?
While I can somewhat navigate this repository, it would be awesome if there was some kind of document explaining how to use, and documenting misuse.
Thank you in advance
Please sign in to leave a comment.
We currently do not have high-level documentation available.
Please see https://github.com/JetBrains/rd/issues/206
What do you want to use? And where?
Currently I have something that works using `IPropertyView.advise(lifetime)`, and simply `IProperty.set`. I understand and see it in action that the advise handler is called when the set method is called
Yet I noticed IJ proposes different obscure variation of the `advise` methods (Until, eternal, WithPrev, etc). There is also I noticed the `view` method. Outside what I can find in the source repository. I'd like to confirm what these do or implies.
Currently I would like block the code until a value has been set to a correct value.
From what I have seen it seems `adviseUntil` is appropriate.
Actually no, `adviseUntil` is not what I'm looking for.
There are also other interesting methods like `debounce`, I understand their meaning, but understanding their implication in regard of the rd library could be useful.
Unfortunately, there're no tools for blocking wait for property value. You might want to try using Kotlin Coroutines/kotlinx.coroutines.CompletableDeferred. Or "plain" JCEF/JS https://plugins.jetbrains.com/docs/intellij/jcef.html
Actually I found what I was looking for via IntelliJ's `org.jetbrains.concurrency` package, as it gives me more flexibility on blocking or using promises. In particular :