• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdeutils API Reference
  • KDE Home
  • Contact Us
 

superkaramba

  • sources
  • kde-4.12
  • kdeutils
  • superkaramba
  • src
  • sensors
program.h
Go to the documentation of this file.
1 /***************************************************************************
2  * Copyright (C) 2003 by Hans Karlsson *
3  * karlsson.h@home.se *
4  * *
5  * This program is free software; you can redistribute it and/or modify *
6  * it under the terms of the GNU General Public License as published by *
7  * the Free Software Foundation; either version 2 of the License, or *
8  * (at your option) any later version. *
9  ***************************************************************************/
10 #ifndef PROGRAMSENSOR_H
11 #define PROGRAMSENSOR_H
12 
13 #include "sensor.h"
14 
15 #include <K3Process>
16 #include <K3ProcIO>
17 #include <QTextCodec>
18 
19 class Karamba;
20 
21 class ProgramSensor : public Sensor
22 {
23  Q_OBJECT
24 public:
25  explicit ProgramSensor(Karamba* k, const QString &programName, int msec = 1000, const QString &encoding = QString());
26  ~ProgramSensor();
27  void update();
28 
29 private:
30  QTextCodec *codec;
31  K3ShellProcess ksp;
32  QString programName;
33  QString sensorResult;
34  Karamba* m_karamba;
35 
36  void replaceLine(QString& format, const QString& line);
37  void replaceArgs(QRegExp& regEx, QString& format, const QStringList& tokens);
38 
39 public slots:
40  void receivedStdout(K3Process *proc, char *buffer, int buflen);
41  void processExited(K3Process *proc);
42 };
43 
44 #endif // PROGRAMSENSOR_H
ProgramSensor::processExited
void processExited(K3Process *proc)
Definition: program.cpp:72
ProgramSensor::~ProgramSensor
~ProgramSensor()
Definition: program.cpp:35
Sensor
Definition: sensor.h:17
Karamba
Definition: karamba.h:52
sensor.h
ProgramSensor::update
void update()
Definition: program.cpp:125
ProgramSensor
Definition: program.h:21
ProgramSensor::receivedStdout
void receivedStdout(K3Process *proc, char *buffer, int buflen)
Definition: program.cpp:38
ProgramSensor::ProgramSensor
ProgramSensor(Karamba *k, const QString &programName, int msec=1000, const QString &encoding=QString())
Definition: program.cpp:15
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:07:20 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

superkaramba

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

kdeutils API Reference

Skip menu "kdeutils API Reference"
  • ark
  • filelight
  • kcalc
  • kcharselect
  • kdf
  • kfloppy
  • kgpg
  • kremotecontrol
  • ktimer
  • kwallet
  • superkaramba
  • sweeper

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal