All Projects → lempiji → rx

lempiji / rx

Licence: MIT license
Reactive Extensions for D Programming Language

Programming Languages

d
599 projects

Projects that are alternatives of or similar to rx

Pharmacist
Builds observables from events.
Stars: ✭ 221 (+325%)
Mutual labels:  reactivex, reactive-extensions, rx
Dynamicdata
Reactive collections based on Rx.Net
Stars: ✭ 1,083 (+1982.69%)
Mutual labels:  reactivex, reactive-extensions, rx
Rxpy
Reactive Extensions for Python, https://rxpy.rtfd.io
Stars: ✭ 4,086 (+7757.69%)
Mutual labels:  reactivex, reactive-extensions
Rxdownloader
- Reactive Extension Library for Android to download files
Stars: ✭ 40 (-23.08%)
Mutual labels:  reactivex, reactive-extensions
ObservableComputations
Cross-platform .NET library for computations whose arguments and results are objects that implement INotifyPropertyChanged and INotifyCollectionChanged (ObservableCollection) interfaces.
Stars: ✭ 94 (+80.77%)
Mutual labels:  reactive-extensions, rx
WebsocketClientLite.PCL
websocket Client Lite PCL - Xaramrin
Stars: ✭ 22 (-57.69%)
Mutual labels:  reactivex, rx
Awesome Rxjs
A collection of awesome RxJS resources
Stars: ✭ 314 (+503.85%)
Mutual labels:  reactivex, reactive-extensions
Reactiveui
An advanced, composable, functional reactive model-view-viewmodel framework for all .NET platforms that is inspired by functional reactive programming. ReactiveUI allows you to abstract mutable state away from your user interfaces, express the idea around a feature in one readable place and improve the testability of your application.
Stars: ✭ 6,709 (+12801.92%)
Mutual labels:  reactivex, reactive-extensions
Rxcommon
Multiplatform implementation of ReactiveX providing a common way to build one set of business logic for native, iOS, Javascript, Android, JVM, and other platforms.
Stars: ✭ 83 (+59.62%)
Mutual labels:  reactivex, rx
Awesome Reactive Programming
A repository for sharing all the resources available on Reactive Programming and Reactive Systems
Stars: ✭ 163 (+213.46%)
Mutual labels:  reactivex, reactive-extensions
rxkotlin-jdbc
Fluent RxJava JDBC extension functions for Kotlin
Stars: ✭ 27 (-48.08%)
Mutual labels:  reactivex, rx
Reactive Examples
Samples App using the Reactive Extensions and Reactive UI
Stars: ✭ 203 (+290.38%)
Mutual labels:  reactivex, reactive-extensions
Rx.Http
A reactive way to make HTTP Request in .NET Core 🚀
Stars: ✭ 62 (+19.23%)
Mutual labels:  reactivex, rx
Rxrust
Rust implementation of Reactive Extensions.
Stars: ✭ 376 (+623.08%)
Mutual labels:  reactivex, rx
rx-reason
Reactive programming library for ReasonML/OCaml
Stars: ✭ 49 (-5.77%)
Mutual labels:  reactivex, rx
purescript-outwatch
A functional and reactive UI framework based on Rx and VirtualDom
Stars: ✭ 33 (-36.54%)
Mutual labels:  reactivex, rx
Unirx
Reactive Extensions for Unity
Stars: ✭ 5,501 (+10478.85%)
Mutual labels:  reactive-extensions, rx
Reactiveproperty
ReactiveProperty provides MVVM and asynchronous support features under Reactive Extensions. Target framework is .NET Standard 2.0.
Stars: ✭ 603 (+1059.62%)
Mutual labels:  reactive-extensions, rx
Flutter validation login form bloc pattern rxdart
[Functional reactive programming (FRP)]💧 💧 💧 [Pure RxDart] Validation login form by using the BLoC pattern with RxDart - A new Flutter project featuring a faked authentication interface to demonstrate validation. Implemented with BloC pattern.
Stars: ✭ 45 (-13.46%)
Mutual labels:  reactivex, rx
Deepspeech Server
A testing server for a speech to text service based on mozilla deepspeech
Stars: ✭ 176 (+238.46%)
Mutual labels:  reactivex, reactive-extensions

Reactive Extensions for D Programming Language

Dub version MIT License Build Status codecov

Overview

This is a library like Rx.NET for asynchronous or event based programs, based on the concept of OutputRange.

The operators' name is based on std.algorithm and ReactiveX.

Example

import rx;
import std.conv : to;
import std.range : iota, put;

void main()
{
    // create own source of int
    auto subject = new SubjectObject!int;

    // define result array
    string[] result;

    // define pipeline and subscribe
    // sequence: source -> filter by even -> map to string -> join to result
    auto disposable = subject.filter!(n => n % 2 == 0).map!(o => to!string(o))
        .doSubscribe!(text => result ~= text);

    // set unsubscribe on exit
    // it is not necessary in this simple example,
    // but in many cases you should call dispose to prevent memory leaks.
    scope (exit)
        disposable.dispose();

    // put values to source. 
    put(subject, iota(10));

    // result is like this
    assert(result == ["0", "2", "4", "6", "8"]);
}

And more examples or Documents

Usage

Setting dependencies in dub.json

{
    ...
    "dependencies": {
        "rx": "~>0.10.0"
    }
}

or dub.sdl

dependency "rx" version="~>0.10.0"

Concepts

Basic interfaces

All operators are written using template and struct for optimization. this example is a binary interface like std.range.interfaces.

//module rx.disposable
interface Disposable
{
    void dispose();
}

//module rx.observer
interface Observer(E) : OutputRange!E
{
    //void put(E obj); //inherits from OutputRange!E
    void completed();
    void failure(Exception e);
}

//module rx.observable
interface Observable(E)
{
    alias ElementType = E;
    Disposable subscribe(Observer!E observer);
}

Supported Compilers

Supported compilers are dmd and ldc that latest 3 versions.

License

This library is under the MIT License.
Some code is borrowed from Rx.NET.

Contributing

Issue and PullRequest are welcome! 😃

Refer to CONTRIBUTING.md for details.

Development

Build and unittest

git clone https://github.com/lempiji/rx
cd rx
dub test

Update documents

Use https://github.com/adamdruppe/adrdox

Future work

  • generic observable factory
    • create, start, timer, interval
  • more subjects
    • publish, connectable
  • more algorithms
    • window, multicast
  • more test
  • more documents
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].