ping-wrapper
Ping wrapper for node - one process listening on stdout is spawned, inherits from EventEmitter
Last updated 5 years ago by langpavel .
Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install ping-wrapper 
SYNC missed versions from official npm registry.

node-ping-wrapper

Ping wrapper for node - one process listening on stdout is spawned; inherits from EventEmitter

Usage:

var Ping = require('ping-wrapper');


// load configuration from file 'config-default-' + process.platform
// Only linux is supported at the moment
Ping.configure();


var ping = new Ping('127.0.0.1');

ping.on('ping', function(data){
	console.log('Ping %s: time: %d ms', data.host, data.time);
});

ping.on('fail', function(data){
	console.log('Fail', data);
});


// later you can call ping.stop()

Current Tags

  • 0.0.3                                ...           latest (5 years ago)

3 Versions

  • 0.0.3                                ...           5 years ago
  • 0.0.2                                ...           7 years ago
  • 0.0.1                                ...           8 years ago
Maintainers (1)
Downloads
Today 0
This Week 1
This Month 2
Last Day 0
Last Week 0
Last Month 1
Dependencies (0)
None
Dev Dependencies (0)
None
Dependents (1)

Copyright 2014 - 2017 © taobao.org |