File tree Expand file tree Collapse file tree 2 files changed +16
-0
lines changed
serial/src/processing/serial Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -177,6 +177,13 @@ protected int clientIndex(Client client) {
177177 return -1 ;
178178 }
179179
180+ /**
181+ * Return true if this server is still active and hasn't run
182+ * into any trouble.
183+ */
184+ public boolean active () {
185+ return (thread != null );
186+ }
180187
181188 static public String ip () {
182189 try {
Original file line number Diff line number Diff line change @@ -135,6 +135,15 @@ public void dispose() {
135135 }
136136
137137
138+ /**
139+ * Return true if this port is still active and hasn't run
140+ * into any trouble.
141+ */
142+ public boolean active () {
143+ return (port .isOpened ());
144+ }
145+
146+
138147 public void pre () {
139148 if (serialAvailableMethod != null && invokeSerialAvailable ) {
140149 invokeSerialAvailable = false ;
You can’t perform that action at this time.
0 commit comments