method Broadcast.clone
Another handle of the same hub.
Example:
use std.stream { Broadcast }
fn main() io {
let hub = Broadcast<i32>.new(buffer: 4)
let same = hub.clone()
var sub = same.subscribe()
print("{hub.subscribers()}")
}Вывод
1
pub(api) fn clone() -> Broadcast<T>С версии. 1.0.0-beta
Возвращает
Broadcast<T>
Эффекты
не объявлены (чистая, пока тело не говорит иное)
Определено в: std/stream/stream.oxl:698