linspector-old/lib/services/ping.py

15 lines
350 B
Python
Raw Normal View History

"""
The ping service in pure Python.
"""
2013-06-18 00:10:14 +02:00
# http://code.activestate.com/recipes/409689-icmplib-library-for-creating-and-reading-icmp-pack/
from lib.services.service import Service
2013-06-18 00:10:14 +02:00
2013-06-18 02:58:40 +02:00
2013-06-18 00:10:14 +02:00
class PingService(Service):
def __init__(self, **kwargs):
2013-06-19 23:48:19 +02:00
super(PingService, self).__init__(**kwargs)
2013-06-18 00:10:14 +02:00
def create(kwargs):
2013-06-18 02:58:40 +02:00
return PingService(**kwargs)