source: PSPA/Interface_Web/trunk/pspaWT/sources/controler/include/elementRfgun.h @ 304

Last change on this file since 304 was 304, checked in by lemeur, 11 years ago

introduction du logiciel 'generator' (debut)

File size: 1.8 KB
Line 
1#ifndef RFGUNDEFINITION_SEEN
2#define RFGUNDEFINITION_SEEN
3
4#include <string>
5#include <iostream>
6#include <sstream>
7
8#include "abstractElement.h"
9
10using namespace std;
11
12class elementRfgun : public abstractElement
13{
14   
15    //  int nbParam_;
16    //  string* parametersString_;
17   
18    double defaultPhaseStep_;
19    int defaultNmacrop_;
20    double defaultSigma_t_;
21    double defaultSigma_r_;
22    double defaultEmit_x_; 
23    double defaultEmit_y_; 
24    double defaultE_cin_;
25    double defaultSigma_E_;
26    double defaultTotalCharge_;
27   
28    double phaseStep_; // a recuperer dans les parametres globaux (methode setPhaseStep)
29    int nmacrop_;
30    double sigma_t_; // picoseconds
31    double sigma_r_; // cm
32    double emit_x_; // pi.mm.mrad
33    double emit_y_; // pi.mm.mrad
34    double E_cin_;   // MeV
35    double sigma_E_; // MeV
36    double totalCharge_;  // nC
37   
38    void setDefaultValues();
39   
40    void setDefaults();
41   
42public:
43   
44    elementRfgun();
45   
46    ~elementRfgun() {;}
47   
48    virtual  trivaluedBool is_accepted_by_software(nomDeLogiciel soft) const;
49   
50    virtual void setPhaseStep(double ph) { phaseStep_ = ph;}
51   
52   
53    virtual string* getParametersString() const;
54   
55    virtual void setParametersString(string* param);
56   
57    virtual inline double getInitialKineticEnergy() const {return E_cin_;}
58   
59    virtual string parmelaOutputFlow() const;
60   
61    virtual string transportOutputFlow() const
62    {
63        ostringstream sortie;
64        cout << " CELL sortie transport non programmee " << endl;
65        return sortie.str();
66    }
67   
68    virtual string generatorOutputFlow() const;
69
70    virtual string FileOutputFlow() const;
71   
72    virtual void FileInput(ifstream& ifs);
73   
74    /** return a string with all parameters and value
75     */
76    string print();
77   
78   
79};
80
81
82#endif
Note: See TracBrowser for help on using the repository browser.