• Skip to content
  • Skip to link menu
KDE 3.5 API Reference
  • KDE API Reference
  • @topname@
  • Sitemap
  • Contact Us
 

superkaramba

networksensor.h

00001 /***************************************************************************
00002  *   Copyright (C) 2003 by Hans Karlsson                                   *
00003  *   karlsson.h@home.se                                                      *
00004  *                                                                         *
00005  *   This program is free software; you can redistribute it and/or modify  *
00006  *   it under the terms of the GNU General Public License as published by  *
00007  *   the Free Software Foundation; either version 2 of the License, or     *
00008  *   (at your option) any later version.                                   *
00009  ***************************************************************************/
00010 #ifndef NETWORKSENSOR_H
00011 #define NETWORKSENSOR_H
00012 
00013 #include "sensor.h"
00014 
00015 #include <tqdatetime.h>
00016 #include <tqfile.h>
00017 #include <tqregexp.h>
00018 #ifdef __FreeBSD__
00019 #include <sys/types.h>
00020 #include <sys/socket.h>
00021 #include <net/if.h>
00022 #include <net/if_mib.h>
00023 #endif
00024 
00025 class NetworkSensor :  public Sensor
00026 {
00027     Q_OBJECT
00028 public:
00029     NetworkSensor( TQString device, int interval );
00030     ~NetworkSensor();
00031     void update();
00032 
00033 
00034 private:
00035     unsigned long receivedBytes;
00036     unsigned long transmittedBytes;
00037     TQTime netTimer;
00038     TQString device;
00039 #ifdef __FreeBSD__
00040     int if_number;
00041     ifmibdata if_mib;
00042 #endif
00043     void getInOutBytes (unsigned long &in,unsigned long &out) const;
00044 
00045 };
00046 #endif // NETWORKSENSOR_H
00047 

superkaramba

Skip menu "superkaramba"
  • Main Page
  • Alphabetical List
  • Class List
  • File List
  • Class Members

@topname@

Skip menu "@topname@"
  • kcalc
  •   knumber
  • superkaramba
Generated for @topname@ by doxygen 1.5.6
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal