Skip to content

Commit

Permalink
Adding the serial port listener system
Browse files Browse the repository at this point in the history
  • Loading branch information
madhephaestus committed Oct 27, 2014
1 parent 4078bb6 commit af2c270
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions nrjavaserial/src/main/java/gnu/io/NRSerialPort.java
Original file line number Diff line number Diff line change
Expand Up @@ -163,4 +163,13 @@ public int getBaud() {
public void notifyOnDataAvailable(boolean b) {
serial.notifyOnDataAvailable(b);
}
public void addEventListener(SerialPortEventListener lsnr)
throws TooManyListenersException {
serial.addEventListener(lsnr);
}

public void removeEventListener(SerialPortEventListener lsnr) {
serial.removeEventListener(lsnr);
}

}

0 comments on commit af2c270

Please sign in to comment.