<pre class="language-dart"><code class="language-dart">bool get hasTerminal {
  try {
    return stdioType(this) == StdioType.terminal;
  } on FileSystemException catch (_) {
    &#47;&#47; If stdioType throws a FileSystemException, then it is not hooked up to
    &#47;&#47; a terminal, probably because it is closed, but let other exception
    &#47;&#47; types bubble up.
    return false;
  }
}</code></pre>
        </section>
</section>
        
  </div> <!-- /.main-content -->

  <div id="dartdoc-sidebar-