nd_core_utils 1.0.21 copy "nd_core_utils: ^1.0.21" to clipboard
nd_core_utils: ^1.0.21 copied to clipboard

An utility library for dart.

nd_core_utils #

nd_core_utils is a small utility library for dart core.

1. NDClosureIterable and NDClosureIterator #

var iteratable = NDClosureIterable(get: () => MyIterator());
var iterator = NDClosureIterator(
    current: () {
        // return current
    },
    moveNext() {
        // move next
        // return result
    }
);

2. Iteratable #

2.1 notNull #

final Iteratable it = <int?>[1, null, 2];
print(it.notNull());
// [1, 2]

2.2 insertSeparator #

final Iteratable it = [1, 2, 3];
print(it.insertSeparator(100));
// [1, 100, 2, 100, 3]

3. List #

3.1 notNullInsertSeparator #

final List list = <int?>[1, null, 3];
print(list.notNullInsertSeparator(100));
// [1, 100, 3]
0
likes
110
pub points
55%
popularity

Publisher

unverified uploader

An utility library for dart.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

Dependencies

flutter, logging, tuple

More

Packages that depend on nd_core_utils