$44 GRAYBYTE WORDPRESS FILE MANAGER $33

SERVER : premium201.web-hosting.com #1 SMP Wed Mar 26 12:08:09 UTC 2025
SERVER IP : 172.67.217.254 | ADMIN IP 216.73.216.157
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/usr/lib/node_modules/npm/node_modules/asynckit/lib/

HOME
Current File : /usr/lib/node_modules/npm/node_modules/asynckit/lib//readable_asynckit.js
var streamify = require('./streamify.js')
  , defer     = require('./defer.js')
  ;

// API
module.exports = ReadableAsyncKit;

/**
 * Base constructor for all streams
 * used to hold properties/methods
 */
function ReadableAsyncKit()
{
  ReadableAsyncKit.super_.apply(this, arguments);

  // list of active jobs
  this.jobs = {};

  // add stream methods
  this.destroy = destroy;
  this._start  = _start;
  this._read   = _read;
}

/**
 * Destroys readable stream,
 * by aborting outstanding jobs
 *
 * @returns {void}
 */
function destroy()
{
  if (this.destroyed)
  {
    return;
  }

  this.destroyed = true;

  if (typeof this.terminator == 'function')
  {
    this.terminator();
  }
}

/**
 * Starts provided jobs in async manner
 *
 * @private
 */
function _start()
{
  // first argument – runner function
  var runner = arguments[0]
    // take away first argument
    , args   = Array.prototype.slice.call(arguments, 1)
      // second argument - input data
    , input  = args[0]
      // last argument - result callback
    , endCb  = streamify.callback.call(this, args[args.length - 1])
    ;

  args[args.length - 1] = endCb;
  // third argument - iterator
  args[1] = streamify.iterator.call(this, args[1]);

  // allow time for proper setup
  defer(function()
  {
    if (!this.destroyed)
    {
      this.terminator = runner.apply(null, args);
    }
    else
    {
      endCb(null, Array.isArray(input) ? [] : {});
    }
  }.bind(this));
}


/**
 * Implement _read to comply with Readable streams
 * Doesn't really make sense for flowing object mode
 *
 * @private
 */
function _read()
{

}


Current_dir [ NOT WRITEABLE ] Document_root [ NOT WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
1 Jan 1970 12.00 AM
root / root
0
abort.js
0.485 KB
10 Mar 2021 2.36 PM
root / root
0644
async.js
0.585 KB
10 Mar 2021 2.36 PM
root / root
0644
defer.js
0.431 KB
10 Mar 2021 2.36 PM
root / root
0644
iterate.js
1.752 KB
10 Mar 2021 2.36 PM
root / root
0644
readable_asynckit.js
1.573 KB
10 Mar 2021 2.36 PM
root / root
0644
readable_parallel.js
0.657 KB
10 Mar 2021 2.36 PM
root / root
0644
readable_serial.js
0.64 KB
10 Mar 2021 2.36 PM
root / root
0644
readable_serial_ordered.js
0.919 KB
10 Mar 2021 2.36 PM
root / root
0644
state.js
0.919 KB
10 Mar 2021 2.36 PM
root / root
0644
streamify.js
2.895 KB
10 Mar 2021 2.36 PM
root / root
0644
terminator.js
0.521 KB
10 Mar 2021 2.36 PM
root / root
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025 CONTACT ME
Static GIF