lib/serial/eventeddeviceloader.js
function EventedSerialDeviceLoader(Device, vendorId, productId) {

  // call super class
  SerialDeviceLoader.call(this, Device, false);

  this.vidPidPairs = [];

  if (!productId && _.isArray(vendorId)) {
    this.vidPidPairs = vendorId;
  } else {
    this.vidPidPairs = [{vendorId: vendorId, productId: productId}];
  }
}
function EventedSerialDeviceLoader(Device, vendorId, productId) {

  // call super class
  SerialDeviceLoader.call(this, Device, false);

  this.vidPidPairs = [];

  if (!productId && _.isArray(vendorId)) {
    this.vidPidPairs = vendorId;
  } else {
    this.vidPidPairs = [{vendorId: vendorId, productId: productId}];
  }
}
function EventedSerialDeviceLoader ( Device , vendorId , productId ) { // call super class SerialDeviceLoader . call ( this , Device , false ) ; this . vidPidPairs = [ ] ; if ( ! productId && _ . isArray ( vendorId ) ) { this . vidPidPairs = vendorId ; } else { this . vidPidPairs = [ { vendorId : vendorId , productId : productId } ] ; } }
An EventedSerialDeviceLoader can check if there are available some serial devices.
@param {Object}          Device    Device The constructor function of the device.
@param {Number || Array} vendorId  The vendor id or an array of vid/pid pairs.
@param {Number}          productId The product id or optional.
An EventedSerialDeviceLoader can check if there are available some serial devices .