0.0.4 • Published 10 years ago

pinging v0.0.4

Weekly downloads
2
License
BSD-2-Clause
Repository
github
Last release
10 years ago

PingingJS

Pinging, JS style.

PingingJS is a fully-implemented ping function, using raw sockets and when.js.

Please note: using raw-sockets requires root on linux/OSX machines.

Getting PingingJS

npm install pinging

Usage

var ping = require('pinging');

ping('8.8.8.8', {
	count: 4, // send 4 pings,
	timeout: 1000, // timeout ping after 1 second
	payload: 'PingingJSIsAwesome', // send the truth as the ping's payload
})
.then(function (stats) {
	console.log('Pings sent:' + stats.pingsSent);
	console.log('Pings recieved:' + stats.pingsRecieved);
})
.catch(function (err) {
	console.log('This ping had a boo-boo...');
});

For more advanced examples, please see the scripts directory.

How fast is it?

Very.

0.0.4

10 years ago

0.0.3

10 years ago

0.0.2

10 years ago

0.0.1

10 years ago