Developer documentation | Axl-2.5.1

axlDataDynamic.h
Go to the documentation of this file.
1 /* axlDataDynamic.h ---
2  *
3  * Author: Anais Ducoffe
4  * Copyright (C)
5  * Created:
6  * Version: $Id$
7  * Last-Updated:
8  * By:
9  * Update #:
10  */
11 
12 /* Commentary:
13  *
14  */
15 
16 /* Change log:
17  *
18  */
19 
20 #ifndef AXLDATADYNAMIC_H
21 #define AXLDATADYNAMIC_H
22 
23 #include "axlCoreExport.h"
25 
26 #include <dtkCoreSupport/dtkAbstractProcess.h>
27 
28 #include <QtCore>
29 
30 class axlDataDynamicPrivate;
31 class axlAbstractProcess;
32 
34 {
35  Q_OBJECT
36 
37 public:
38  enum Type {
39  Dynamic = 0x001,
40  Static = 0x002
41  };
42 
43 public:
44  axlDataDynamic(void);
45  virtual ~axlDataDynamic(void);
46 
47 
48 public :
49  axlDataDynamic::Type getType(void);
50  void setType(axlDataDynamic::Type type);
51 
52 
53 public slots:
54  void setInput(dtkAbstractData *data, int channel=0);
55 
56  void setParameter(int parameter);
57  void setParameter(int parameter, int channel);
58  void setParameter(double parameter);
59  void setParameter(double parameter, int channel);
60 
61  int setProcess(QString processName);
62  void setProcess(axlAbstractProcess *process);
63  int numberOfUpdate(void);
64 
65 public :
66  QList<axlAbstractData *> inputs(void);
67  QList<axlAbstractData *> parameters(void);
68  axlAbstractProcess *process(void);
69  axlAbstractData *outputs(void);
70  axlAbstractData *outputs(int channel);
71  void clearInputs(void);
72  bool isNotInputProcess(dtkAbstractData *data);
73  bool isNotOutputProcess(dtkAbstractData *data);
74 
78  QVariantList convertDataToQVariant(void) const;
82  int convertQVariantToData(const QVariantList &data);
83 
84 
85  /* dtk overload */
86 
87 public:
88 
89  virtual QString description(void) const;
90  virtual QString identifier(void) const;
91 
92 public:
93  virtual int numberOfChannels(void);
94 
95 signals :
96  void dataInserted(axlAbstractData *data);
97 
98 public slots:
99  virtual void update(void);
100  void onRemoved(void);
101 
102 private:
103  axlDataDynamicPrivate *d;
104 };
105 
106 dtkAbstractData *createAxlDataDynamic(void);
107 
108 #endif// AXLDATADYNAMIC_H
virtual QString identifier(void) const
virtual QString description(void) const
virtual int convertQVariantToData(const QVariantList &data)
Modify properties and geometry variables of the axlAbstractData. Return 1 if the modification was suc...
Class axlDataDynamic defines a dynamic object.
dtkAbstractData * createAxlDataDynamic(void)
virtual QVariantList convertDataToQVariant(void) const
Convert an axlAbstractData into a QVariantList that specifies all properties of the axlAbstractData...
#define AXLCORE_EXPORT
Class axlAbstractData defines an API for all type of axel data.