/** * Sets the current window size of this PTY. * * @param winSize the {@link WinSize} instance to set on the master side of the PTY, cannot be * <code>null</code>. * @throws IllegalArgumentException in case the given argument was <code>null</code>. * @throws IOException in case obtaining the window size failed. */ public void setWinSize(WinSize winSize) throws IOException { if (winSize == null) { throw new IllegalArgumentException("WinSize cannot be null!"); } if (JPty.setWinSize(m_fdMaster, winSize) < 0) { throw new IOException("Failed to set window size: " + JPty.errno()); } }