| [738ae1] | 1 | /*
 | 
|---|
 | 2 |  * TextQuery.hpp
 | 
|---|
 | 3 |  *
 | 
|---|
 | 4 |  *  Created on: Nov 8, 2010
 | 
|---|
 | 5 |  *      Author: heber
 | 
|---|
 | 6 |  */
 | 
|---|
 | 7 | 
 | 
|---|
 | 8 | #ifndef TEXTQUERY_HPP_
 | 
|---|
 | 9 | #define TEXTQUERY_HPP_
 | 
|---|
 | 10 | 
 | 
|---|
| [56f73b] | 11 | // include config.h
 | 
|---|
 | 12 | #ifdef HAVE_CONFIG_H
 | 
|---|
 | 13 | #include <config.h>
 | 
|---|
 | 14 | #endif
 | 
|---|
 | 15 | 
 | 
|---|
 | 16 | 
 | 
|---|
| [738ae1] | 17 | #include "TextUI/TextDialog.hpp"
 | 
|---|
 | 18 | 
 | 
|---|
| [1c55b8] | 19 | class TextDialog::AtomTextQuery : public Dialog::TQuery<const atom *> {
 | 
|---|
| [738ae1] | 20 | public:
 | 
|---|
| [f130d4] | 21 |   AtomTextQuery(Parameter<const atom *> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 22 |   virtual ~AtomTextQuery();
 | 
|---|
 | 23 |   virtual bool handle();
 | 
|---|
 | 24 | };
 | 
|---|
 | 25 | 
 | 
|---|
| [1c55b8] | 26 | class TextDialog::AtomsTextQuery : public Dialog::TQuery<std::vector<const atom *> > {
 | 
|---|
| [738ae1] | 27 | public:
 | 
|---|
| [f130d4] | 28 |   AtomsTextQuery(Parameter<std::vector<const atom *> > &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 29 |   virtual ~AtomsTextQuery();
 | 
|---|
 | 30 |   virtual bool handle();
 | 
|---|
 | 31 | };
 | 
|---|
 | 32 | 
 | 
|---|
| [1c55b8] | 33 | class TextDialog::BooleanTextQuery : public Dialog::TQuery<bool> {
 | 
|---|
| [738ae1] | 34 | public:
 | 
|---|
| [f130d4] | 35 |   BooleanTextQuery(Parameter<bool> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 36 |   virtual ~BooleanTextQuery();
 | 
|---|
 | 37 |   virtual bool handle();
 | 
|---|
 | 38 | };
 | 
|---|
 | 39 | 
 | 
|---|
| [1c55b8] | 40 | class TextDialog::RealSpaceMatrixTextQuery : public Dialog::TQuery<RealSpaceMatrix> {
 | 
|---|
| [738ae1] | 41 | public:
 | 
|---|
| [f130d4] | 42 |   RealSpaceMatrixTextQuery(Parameter<RealSpaceMatrix> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [7d9416] | 43 |   virtual ~RealSpaceMatrixTextQuery();
 | 
|---|
| [738ae1] | 44 |   virtual bool handle();
 | 
|---|
 | 45 | };
 | 
|---|
 | 46 | 
 | 
|---|
| [1c55b8] | 47 | class TextDialog::DoubleTextQuery : public Dialog::TQuery<double> {
 | 
|---|
| [738ae1] | 48 | public:
 | 
|---|
| [f130d4] | 49 |   DoubleTextQuery(Parameter<double> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 50 |   virtual ~DoubleTextQuery();
 | 
|---|
 | 51 |   virtual bool handle();
 | 
|---|
 | 52 | };
 | 
|---|
 | 53 | 
 | 
|---|
| [1c55b8] | 54 | class TextDialog::DoublesTextQuery : public Dialog::TQuery<std::vector<double> > {
 | 
|---|
| [738ae1] | 55 | public:
 | 
|---|
| [f130d4] | 56 |   DoublesTextQuery(Parameter<std::vector<double> > &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 57 |   virtual ~DoublesTextQuery();
 | 
|---|
 | 58 |   virtual bool handle();
 | 
|---|
 | 59 | };
 | 
|---|
 | 60 | 
 | 
|---|
| [1c55b8] | 61 | class TextDialog::ElementTextQuery : public Dialog::TQuery<const element *> {
 | 
|---|
| [738ae1] | 62 | public:
 | 
|---|
| [f130d4] | 63 |   ElementTextQuery(Parameter<const element *> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 64 |   virtual ~ElementTextQuery();
 | 
|---|
 | 65 |   virtual bool handle();
 | 
|---|
 | 66 | };
 | 
|---|
 | 67 | 
 | 
|---|
| [1c55b8] | 68 | class TextDialog::ElementsTextQuery : public Dialog::TQuery<std::vector<const element *> > {
 | 
|---|
| [738ae1] | 69 | public:
 | 
|---|
| [f130d4] | 70 |   ElementsTextQuery(Parameter<std::vector<const element *> > &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 71 |   virtual ~ElementsTextQuery();
 | 
|---|
 | 72 |   virtual bool handle();
 | 
|---|
 | 73 | };
 | 
|---|
 | 74 | 
 | 
|---|
 | 75 | class TextDialog::EmptyTextQuery : public Dialog::EmptyQuery {
 | 
|---|
 | 76 | public:
 | 
|---|
| [f130d4] | 77 |   EmptyTextQuery(const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 78 |   virtual ~EmptyTextQuery();
 | 
|---|
 | 79 |   virtual bool handle();
 | 
|---|
 | 80 | };
 | 
|---|
 | 81 | 
 | 
|---|
| [1c55b8] | 82 | class TextDialog::FileTextQuery : public Dialog::TQuery<boost::filesystem::path> {
 | 
|---|
| [738ae1] | 83 | public:
 | 
|---|
| [f130d4] | 84 |   FileTextQuery(Parameter<boost::filesystem::path> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 85 |   virtual ~FileTextQuery();
 | 
|---|
 | 86 |   virtual bool handle();
 | 
|---|
 | 87 | };
 | 
|---|
 | 88 | 
 | 
|---|
| [1c55b8] | 89 | class TextDialog::FilesTextQuery : public Dialog::TQuery<std::vector<boost::filesystem::path> > {
 | 
|---|
| [2c5765] | 90 | public:
 | 
|---|
| [f130d4] | 91 |   FilesTextQuery(Parameter<std::vector< boost::filesystem::path> > ¶m, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [2c5765] | 92 |   virtual ~FilesTextQuery();
 | 
|---|
 | 93 |   virtual bool handle();
 | 
|---|
 | 94 | };
 | 
|---|
 | 95 | 
 | 
|---|
| [1c55b8] | 96 | class TextDialog::IntTextQuery : public Dialog::TQuery<int> {
 | 
|---|
| [738ae1] | 97 | public:
 | 
|---|
| [f130d4] | 98 |   IntTextQuery(Parameter<int> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 99 |   virtual ~IntTextQuery();
 | 
|---|
 | 100 |   virtual bool handle();
 | 
|---|
 | 101 | };
 | 
|---|
 | 102 | 
 | 
|---|
| [1c55b8] | 103 | class TextDialog::IntsTextQuery : public Dialog::TQuery<std::vector<int> > {
 | 
|---|
| [738ae1] | 104 | public:
 | 
|---|
| [f130d4] | 105 |   IntsTextQuery(Parameter<std::vector<int> > &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 106 |   virtual ~IntsTextQuery();
 | 
|---|
 | 107 |   virtual bool handle();
 | 
|---|
 | 108 | };
 | 
|---|
 | 109 | 
 | 
|---|
| [1c55b8] | 110 | class TextDialog::MoleculeTextQuery : public Dialog::TQuery<const molecule *> {
 | 
|---|
| [738ae1] | 111 | public:
 | 
|---|
| [f130d4] | 112 |   MoleculeTextQuery(Parameter<const molecule *> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 113 |   virtual ~MoleculeTextQuery();
 | 
|---|
 | 114 |   virtual bool handle();
 | 
|---|
 | 115 | };
 | 
|---|
 | 116 | 
 | 
|---|
| [1c55b8] | 117 | class TextDialog::MoleculesTextQuery : public Dialog::TQuery<std::vector<const molecule *> > {
 | 
|---|
| [738ae1] | 118 | public:
 | 
|---|
| [f130d4] | 119 |   MoleculesTextQuery(Parameter<std::vector<const molecule *> > &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 120 |   virtual ~MoleculesTextQuery();
 | 
|---|
 | 121 |   virtual bool handle();
 | 
|---|
 | 122 | };
 | 
|---|
 | 123 | 
 | 
|---|
| [1c55b8] | 124 | class TextDialog::StringTextQuery : public Dialog::TQuery<std::string> {
 | 
|---|
| [738ae1] | 125 | public:
 | 
|---|
| [f130d4] | 126 |   StringTextQuery(Parameter<std::string> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 127 |   virtual ~StringTextQuery();
 | 
|---|
 | 128 |   virtual bool handle();
 | 
|---|
 | 129 | };
 | 
|---|
 | 130 | 
 | 
|---|
| [1c55b8] | 131 | class TextDialog::StringsTextQuery : public Dialog::TQuery<std::vector<std::string> > {
 | 
|---|
| [738ae1] | 132 | public:
 | 
|---|
| [f130d4] | 133 |   StringsTextQuery(Parameter<std::vector<std::string> > &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 134 |   virtual ~StringsTextQuery();
 | 
|---|
 | 135 |   virtual bool handle();
 | 
|---|
 | 136 | };
 | 
|---|
 | 137 | 
 | 
|---|
| [1c55b8] | 138 | class TextDialog::UnsignedIntTextQuery : public Dialog::TQuery<unsigned int> {
 | 
|---|
| [838cd0] | 139 | public:
 | 
|---|
| [f130d4] | 140 |   UnsignedIntTextQuery(Parameter<unsigned int> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [838cd0] | 141 |   virtual ~UnsignedIntTextQuery();
 | 
|---|
 | 142 |   virtual bool handle();
 | 
|---|
 | 143 | };
 | 
|---|
 | 144 | 
 | 
|---|
| [1c55b8] | 145 | class TextDialog::UnsignedIntsTextQuery : public Dialog::TQuery<std::vector<unsigned int> > {
 | 
|---|
| [12948c] | 146 | public:
 | 
|---|
| [f130d4] | 147 |   UnsignedIntsTextQuery(Parameter<std::vector<unsigned int> > &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [12948c] | 148 |   virtual ~UnsignedIntsTextQuery();
 | 
|---|
 | 149 |   virtual bool handle();
 | 
|---|
 | 150 | };
 | 
|---|
 | 151 | 
 | 
|---|
| [1c55b8] | 152 | class TextDialog::VectorTextQuery : public Dialog::TQuery<Vector> {
 | 
|---|
| [738ae1] | 153 | public:
 | 
|---|
| [f130d4] | 154 |   VectorTextQuery(Parameter<Vector> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 155 |   virtual ~VectorTextQuery();
 | 
|---|
 | 156 |   virtual bool handle();
 | 
|---|
 | 157 | };
 | 
|---|
 | 158 | 
 | 
|---|
| [1c55b8] | 159 | class TextDialog::VectorsTextQuery : public Dialog::TQuery<std::vector<Vector> > {
 | 
|---|
| [738ae1] | 160 | public:
 | 
|---|
| [f130d4] | 161 |   VectorsTextQuery(Parameter<std::vector<Vector> > &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [738ae1] | 162 |   virtual ~VectorsTextQuery();
 | 
|---|
 | 163 |   virtual bool handle();
 | 
|---|
 | 164 | };
 | 
|---|
 | 165 | 
 | 
|---|
| [1c55b8] | 166 | class TextDialog::RandomNumberDistribution_ParametersTextQuery : public Dialog::TQuery<RandomNumberDistribution_Parameters> {
 | 
|---|
| [0275ad] | 167 | public:
 | 
|---|
| [f130d4] | 168 |   RandomNumberDistribution_ParametersTextQuery(Parameter<RandomNumberDistribution_Parameters> &, const std::string &_title, const std::string &_description = NULL);
 | 
|---|
| [0275ad] | 169 |   virtual ~RandomNumberDistribution_ParametersTextQuery();
 | 
|---|
 | 170 |   virtual bool handle();
 | 
|---|
 | 171 | };
 | 
|---|
 | 172 | 
 | 
|---|
| [738ae1] | 173 | #endif /* TEXTQUERY_HPP_ */
 | 
|---|