Implement close() for serial port streams

master
Harald Wolff 2018-02-10 12:59:22 +01:00
parent 9ecc508fb4
commit 7bbd7e2cbf
1 changed files with 9 additions and 0 deletions

View File

@ -320,6 +320,11 @@ public class NewSerialPort {
} }
return nRead; return nRead;
} }
@Override
public void close() throws IOException {
NewSerialPort.this.close();
}
} }
public class NewSerialPortOutputStream extends OutputStream public class NewSerialPortOutputStream extends OutputStream
@ -388,6 +393,10 @@ public class NewSerialPort {
write(b, 0, b.length); write(b, 0, b.length);
} }
@Override
public void close() throws IOException {
NewSerialPort.this.close();
}
} }
static public String[] getPortNames(){ static public String[] getPortNames(){