Add toString.

This commit is contained in:
David Braun 2017-10-18 14:28:01 -04:00
parent e1b638bef7
commit f07e849662
3 changed files with 12 additions and 1 deletions

View file

@ -24,6 +24,7 @@
- [shift() -> async](#shift---async)
- [slice(start[, end]) -> Channel](#slicestart-end---channel)
- [some(callbackfn[, thisArg])](#somecallbackfn-thisarg)
- [toString()](#tostring)
- [Functional API](#functional-api)
<!-- /TOC -->
@ -305,6 +306,10 @@ Unlike in `Array`'s method, `callbackfn` is called with only one argument.
`some` acts like the "exists" quantifier in mathematics. In particular, for an
empty channel, it returns `false`.
### toString() -> String
Return `"Channel(n)"` where `n` is the length of the buffer.
# Functional API
There is a parallel API to support functional-style programming. Every channel