code: public synchronized static void write(int fd, byte[] ... data) throws IOException {
          for(byte[] single : data) {
              // write the data contents to the serial port via JNI native method
              write(fd, single, single.length);
          }
      }
docs: <p>Sends one of more bytes arrays to the serial device identified by the given file descriptor.</p>
  
  @param fd
  The file descriptor of the serial port/device.
  @param data
  One or more byte arrays of data to be transmitted. (variable-length-argument)