Class: Tty

vertx-shell-js/tty~ Tty

new Tty()

Provide interactions with the Shell TTY.
Source:

Methods

eventHandler(eventType, handler) → {Tty}

Set an event handler to be notified by Shell events.
Parameters:
Name Type Description
eventType Object the event type
handler function
Source:
Returns:
Type
Tty

height() → {number}

Source:
Returns:
  • the current height, i.e the number of columns or if unknown
  • Type
    number

setStdin(stdin) → {Tty}

Set an handler the standard input to read the data in String format.
Parameters:
Name Type Description
stdin function the standard input
Source:
Returns:
this object
Type
Tty

stdout() → {Stream}

Source:
Returns:
  • the standard output for emitting data
  • Type
    Stream

width() → {number}

Source:
Returns:
  • the current width, i.e the number of rows or if unknown
  • Type
    number