lib/Kowalski.js
/**
   * Triggers an Information collection
   * @param {String} name - the name of the Information to collect
   * @param {any} data - data to provide the Information instance
   * @returns {Boolean} whether data was succesfully read
   */
Triggers an Information collection
@param {String} name - the name of the Information to collect
@param {any} data - data to provide the Information instance
@returns {Boolean} whether data was succesfully read
Triggers an Information collection @param { String } name - the name of the Information to collect @param { any } data - data to provide the Information instance @returns { Boolean } whether data was succesfully read
triggerInfoCollect (name, data) {
    name = name.toLowerCase()
    if (!this.informationTypes.has(name)) throw new InvalidArgumentException(`Information type '${name}' does not exist`)
    const Information = this.informationTypes.get(name)
    const info = new Information(data)
    if (!(info instanceof Kowalski.Information)) return false
    if (this.reading) this.reading = this.push(info) 
    else this.infoBuffer.push(info) 
    return true
  }
triggerInfoCollect ( name , data ) { name = name . toLowerCase ( ) if ( ! this . informationTypes . has ( name ) ) throw new InvalidArgumentException ( ` ${ name } ` ) const Information = this . informationTypes . get ( name ) const info = new Information ( data ) if ( ! ( info instanceof Kowalski . Information ) ) return false if ( this . reading ) this . reading = this . push ( info ) else this . infoBuffer . push ( info ) return true }
Triggers an Information collection
 @param {String} name - the name of the Information to collect
 @param {any} data - data to provide the Information instance
 @returns {Boolean} whether data was succesfully read
Triggers an Information collection @param { String } name - the name of the Information to collect @param { any } data - data to provide the Information instance @returns { Boolean } whether data was succesfully read
// if reading stream the info // else save it in the buffer