~ubuntu-branches/ubuntu/quantal/qgis/quantal

« back to all changes in this revision

Viewing changes to src/qgsattributeaction.h

  • Committer: Bazaar Package Importer
  • Author(s): Steve Halasz
  • Date: 2005-11-05 16:04:45 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20051105160445-l0g4isz5bc9yehet
Tags: 0.7.4-1
* New upstream release
* Build GRASS support in qgis-plugin-grass package (Closes: #248649)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/***************************************************************************
2
2
                          qgsattributeaction.h 
3
3
 
4
 
 This class that stores and control the managment and execution of actions 
 
4
 These classes store and control the managment and execution of actions 
5
5
 associated with particulay Qgis layers. Actions are defined to be
6
6
 external programs that are run with user-specified inputs that can 
7
7
 depend on the contents of layer attributes.
20
20
 *   (at your option) any later version.                                   *
21
21
 *                                                                         *
22
22
 ***************************************************************************/
23
 
/* $Id: qgsattributeaction.h,v 1.3 2004/11/03 20:55:41 g_j_m Exp $ */
 
23
/* $Id: qgsattributeaction.h,v 1.5 2005/01/19 23:59:10 g_j_m Exp $ */
24
24
 
25
25
#ifndef QGSATTRIBUTEACTION_H
26
26
#define QGSATTRIBUTEACTION_H
27
27
 
28
28
#include <qstring.h>
29
29
#include <qobject.h>
30
 
#include <qprocess.h>
31
30
 
32
31
#include <list>
33
32
#include <vector>
34
33
#include <utility>
 
34
 
35
35
class QDomNode;
36
36
class QDomDocument;
 
37
class QgsMessageViewer;
 
38
 
37
39
 
38
40
/*! \class QgsAction
39
41
 * \brief Utility class that encapsulates an action and associated information
42
44
{
43
45
 public:
44
46
  QgsAction(QString name, QString action, bool capture) :
45
 
    mName(name), mAction(action), mCaptureStdout(capture) {}
 
47
    mName(name), mAction(action), mCaptureOutput(capture) {}
46
48
 
47
49
  //! The name of the action
48
50
  QString name() const { return mName; }
50
52
  //! The action
51
53
  QString action() const { return mAction; }
52
54
 
53
 
  //! Whether to capture stdout for display when this action is run
54
 
  bool capture() const { return mCaptureStdout; }
 
55
  //! Whether to capture output for display when this action is run
 
56
  bool capture() const { return mCaptureOutput; }
55
57
 
56
58
 private:
57
59
  QString mName;
58
60
  QString mAction;
59
 
  bool mCaptureStdout;
 
61
  bool mCaptureOutput;
60
62
};
61
63
 
62
 
class QProcess;
63
 
 
64
64
/*! \class QgsAttributeAction
65
65
 * \brief Storage and management of actions associated with Qgis layer
66
66
 * attributes.
128
128
 
129
129
  // Stores the name/action pairs.
130
130
  AttributeActions mActions;
131
 
 
132
 
  QProcess* process;
133
 
 
134
131
};
135
132
 
136
133
#endif