sharedStdIn top-level property

SharedStdIn sharedStdIn

A shared singleton instance of dart:io's stdin stream.

Unlike the normal stdin stream, sharedStdIn may switch subscribers as long as the previous subscriber cancels before the new subscriber starts listening.

SharedStdIn.terminate must be invoked in order to close the underlying connection to stdin, allowing your program to close automatically without hanging.


final SharedStdIn sharedStdIn = SharedStdIn(stdin);