screenlets.sensors.NetSensor

Package screenlets :: Module sensors :: Class NetSensor |
[hide private]
[frames] | no frames]

# Class NetSensor

source code

    object --+
             |
    ??.GObject --+
                 |
            Sensor --+
                     |
                    NetSensor

Instance Methods | [hide private]
__init__(self, interval=1000, device=`'``eth0``'`) Create a new NetSensor which emits an 'sensor_updated'-signal after a given interval (default is 1000ms). | source code
get_upload_speed(self) Return the current upload speed in b/s. | source code
get_download_speed(self) Return the current download speed in b/s. | source code
get_uploaded(self) Return the overall upload amount. | source code
get_downloaded(self) Return the overall download amount. | source code
on_update(self) Called on each interval. | source code
Inherited from `Sensor`: `get_interval`, `set_interval`, `stop` Inherited from `unreachable.GObject`: `__copy__`, `__deepcopy__`, `__delattr__`, `__eq__`, `__gdoc__`, `__ge__`, `__gobject_init__`, `__gt__`, `__hash__`, `__le__`, `__lt__`, `__ne__`, `__new__`, `__repr__`, `__setattr__`, `chain`, `connect`, `connect_after`, `connect_object`, `connect_object_after`, `disconnect`, `disconnect_by_func`, `emit`, `emit_stop_by_name`, `freeze_notify`, `get_data`, `get_properties`, `get_property`, `handler_block`, `handler_block_by_func`, `handler_disconnect`, `handler_is_connected`, `handler_unblock`, `handler_unblock_by_func`, `notify`, `props`, `set_data`, `set_properties`, `set_property`, `stop_emission`, `thaw_notify`, `weak_ref` Inherited from `object`: `__format__`, `__getattribute__`, `__reduce__`, `__reduce_ex__`, `__sizeof__`, `__str__`, `__subclasshook__`

Class Variables | [hide private]
Inherited from `Sensor`: `__gsignals__`, `__gtype__`

Properties | [hide private]
Inherited from `unreachable.GObject`: `__grefcount__` Inherited from `object`: `__class__`

Method Details | [hide private]

### __init__(self, interval=1000, device=`'``eth0``'`) (Constructor) | source code
Create a new NetSensor which emits an 'sensor_updated'-signal after a given interval (default is 1000ms). Overrides: object.__init__

### on_update(self) | source code
Called on each interval. Calculates the load and updates the internal values. Overrides: Sensor.on_update