renderDawoStreams method
void
renderDawoStreams()
TODO HTML not allowed in VM
testing and playing with above streams, show output
Implementation
/*
void presentButtonClickStream() {
var button = new ButtonElement();
document.body.children.add(button);
button.text = "Foo";
var clickCount = 0;
button.onClick.listen((mouseEvent) {
print("clicked"); // remain subscribed for all clicks
});
var subscription = button.onClick.listen(null);
subscription.onData((mouseEvent) {
print("copy that");
clickCount++;
window.alert("Clicked");
if (clickCount == 3) {
subscription.cancel(); // unsubscribe after the third click
}
});
} // ----- presentButtonClickStream
*/
/*
var tempsStream = new Stream.fromIterable(musicTemps);
// subscribe to the streams events
void listenMusicStream() {
tempsStream.listen((value) { //
print("Received: $value"); // onData handler
});
} // ----- listenMusicStream
*/
/* io.example. do not work on html / browser side
import 'dart:io';
main() {
File file = new File("some_file.txt");
file.openRead()
.transform(UTF8.decoder) // use a UTF8.decoder
.listen((String data) => print(data), // output the data
onError: (error) => print("Error, could not open file"),
onDone: () => print("Finished reading data"));
}
*/
/// testing and playing with above streams, show output
void renderDawoStreams() {
// code here
print('\n *** renderDawoStream Nothing to see here now *** \n ');
}