COVISE Core
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros
coUifPara.h
Go to the documentation of this file.
1 /* This file is part of COVISE.
2 
3  You can use it under the terms of the GNU Lesser General Public License
4  version 2.1 or later, see lgpl-2.1.txt.
5 
6  * License: LGPL 2+ */
7 
8 #ifndef _CO_PARA_PORT_H_
9 #define _CO_PARA_PORT_H_
10 
11 // 13.09.99
12 
13 #include <covise/covise.h>
14 #include "coPort.h"
15 
20 namespace covise
21 {
22 
23 class APIEXPORT coUifPara : public coPort
24 {
25 
26 public:
27  // Type information: which kind of port is this
28  typedef int Typeinfo;
29 
30 protected:
31  // calculate a number from a string: similar to DO, but not same
32  static Typeinfo numericType(const char *typeStr);
33 
34 private:
36  coUifPara &operator=(const coUifPara &);
37 
39  coUifPara();
40 
42  coUifPara(const coUifPara &old);
43 
44 protected:
45  // whether this port is active: inactive ports do not show up on show()
46  int d_active;
47 
48 public:
53  coUifPara(const char *name, const char *desc);
54 
56  virtual ~coUifPara();
57 
59  virtual void setActive(int isActive);
60 
62  virtual void hide();
63 
65  virtual void show();
66 
68  virtual int paramChange() = 0;
69 
71  virtual int preCompute()
72  {
73  return 0;
74  }
75 
77  virtual void initialize() = 0;
78 
80  virtual void print(ostream &str) const;
81 
83  virtual int switchable() const;
84 
86  virtual int isOfType(coUifPara::Typeinfo type) = 0;
87 
89  virtual void enable();
90 
92  virtual void disable();
93 
95  virtual Kind kind() const;
96 
98  int isActive() const;
99 
101  void para_error(const char *what);
102 
104  virtual const char *getTypeString() const = 0;
105 
107  virtual const char *getValString() const = 0;
108 
110  virtual void setValString(const char *str) = 0;
111 };
112 }
113 #endif
Definition: coUifPara.h:23
GLuint const GLchar * name
Definition: khronos-glext.h:6722
int d_active
Definition: coUifPara.h:46
GLboolean enable
Definition: khronos-glext.h:12389
#define APIEXPORT
Definition: coExport.h:251
int Typeinfo
Definition: coPort.h:29
GLenum type
Definition: khronos-glext.h:6279
Definition: coPort.h:24
virtual int preCompute()
do whatever needed before compute CB : enforce that all parameters do sth.
Definition: coUifPara.h:71
int Typeinfo
Definition: coUifPara.h:28