subx 0.3.0 copy "subx: ^0.3.0" to clipboard
subx: ^0.3.0 copied to clipboard

outdated

RxDart Subscriptions management

SubX #

Build Status

RxDart Subscriptions management.

Provide Apis to store and manage RxDart subscriptions and provide methods to unsubscribe them all.

Prerequisites #

The project has dependencies that require the Dart SDK 2.0

SubxList #

Object that holds and manages a list of Subscriptions.

Usage #

import 'dart:async';
import 'package:rxdart/rxdart.dart';
import 'package:subx/subx.dart';
import "package:test/test.dart";

SubxList subxList = SubxList();
BehaviorSubject source = BehaviorSubject();

StreamSubscription subscription = source.listen((data) {...});
StreamSubscription subscription2 = source.listen((data) {...});

subxList.add(subscription);
subxList.add(subscription2);

...

subxList.unsubscribeAll();

SubxMap #

Object that holds and manages Key-Subscription pairs.

Usage #

import 'dart:async';
import 'package:rxdart/rxdart.dart';
import 'package:subx/subx.dart';
import "package:test/test.dart";

SubxList subxList = SubxList();
BehaviorSubject source = BehaviorSubject();

StreamSubscription subscription = source.listen((data) {...});
StreamSubscription subscription2 = source.listen((data) {...});

subxList.set('key1', subscription);
subxList.set('key2', subscription2);

...

subxList.unsubscribeAll();

License #

Copyright (c) Tyrcord, Inc. Licensed under the ISC License.

See LICENSE file in the project root for details.

0
likes
0
pub points
17%
popularity

Publisher

unverified uploader

RxDart Subscriptions management

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

async

More

Packages that depend on subx