ping_win32 0.0.2 copy "ping_win32: ^0.0.2" to clipboard
ping_win32: ^0.0.2 copied to clipboard

A simple wrapper for Win32 IcmpSendEcho2 function

ping_win32 #

A simple wrapper for Win32 IcmpSendEcho2 function.

Although there has been a handful of ping implementations that wraps the command-line ping utility and it supports variety of platforms including Windows, on Windows platform, it does not support locales other than en-US and it results in severe incompatibility with other locales.

ping_win32 is a faster, efficient, and better replacement for such ping implementations on Windows.

Getting started #

dart pub add ping_win32

Usage #

PingWin32.ping is the only one function provided by the library:

import 'dart:io';

import 'package:ping_win32/ping_win32.dart';

void main() async {
  final result = await PingWin32.ping(
    InternetAddress.tryParse('192.168.10.12')!,
    timeout: Duration(seconds: 10),
  );
  print(result);
}

The returned value is in IcmpResult class and it has status, roundTripTime, and ttl.

References #

0
likes
110
pub points
23%
popularity

Publisher

verified publisherespresso3389.jp

A simple wrapper for Win32 IcmpSendEcho2 function

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

Dependencies

ffi

More

Packages that depend on ping_win32