palestine_connection 0.0.16 copy "palestine_connection: ^0.0.16" to clipboard
palestine_connection: ^0.0.16 copied to clipboard

outdated

Lightweight internet connection test, lookup any provided domain.

palestine_connection #

Lightweight internet connection test, lookup Google domain.

License Pub Example

Part of PalestineDevelopers project

Fork Star Watch

Features #

  • Periodic internet connection tests
  • dispose method

Getting started #

To start, import package

import 'package:palestine_connection/palestine_connection.dart';

Usage #

Just as easy as this

final PalConnection connection = PalConnection();
connection.initialize(
    domain: PalDomain.google, // Domain To Test On (optional)
    periodicInSeconds: 3, // 3 seconds
    onConnectionLost: () {
      // No Internet
    },
    onConnectionRestored: () {
      // Internet is back
    },
  );

It could get more easier actually

PalConnection().initialize(
    domain: PalDomain.random, // Random choices "changing"
    periodicInSeconds: 3, // 3 seconds
    onConnectionLost: () {
      // No Internet
    },
    onConnectionRestored: () {
      // Internet is back
    },
  );

Then you could dispose it

connection.dispose();
62
likes
0
points
83
downloads

Publisher

verified publishermsayed.net

Weekly Downloads

Lightweight internet connection test, lookup any provided domain.

Repository (GitHub)
View/report issues

License

unknown (license)

More

Packages that depend on palestine_connection