source: PSPA/Interface_Web/trunk/pspaWT/sources/controler/include/abstractSoftware.h @ 485

Last change on this file since 485 was 485, checked in by lemeur, 10 years ago

liste des logiciels compatibles dans les tooltip des elements

File size: 1.7 KB
Line 
1#ifndef ABSTRACTSOFTWARE_SEEN
2#define ABSTRACTSOFTWARE_SEEN
3
4#include "globalParameters.h"
5#include "sectorParameters.h"
6#include "particleBeam.h"
7#include "nomDeLogiciel.h"
8#include "nomdElements.h"
9#include "trivaluedBool.h"
10
11#include <iostream>
12#include <string>
13
14using namespace std;
15
16class dataManager;
17class sectionToExecute;
18
19class abstractSoftware
20{
21
22 protected :
23 
24  dataManager* dataManager_;
25  string inputFileName_;
26  nomDeLogiciel* nameOfSoftware_;
27
28  /**
29     Accepted elements list for this software
30  */
31  //  std::vector <nomdElements::typedElement> acceptedElements_;
32
33  /**
34     Ignore software list for this element
35  */
36  //  std::vector <nomdElements::typedElement> ignoredElements_;
37 
38  abstractSoftware();
39
40  bool launchJob(string commandLine, string& resul);
41
42  //  void registerElement(nomdElements::typedElement nomdel,trivaluedBool b);
43
44  sectionToExecute* getSectionToExecute() {
45    return sectionToExecute_;
46  }
47
48  public :
49
50  abstractSoftware(string, sectionToExecute*, dataManager* );
51  ~abstractSoftware() {
52    delete nameOfSoftware_;
53}
54
55  inline const nomDeLogiciel* getNomDeLogiciel() const {
56    return nameOfSoftware_;
57  }
58
59  //   trivaluedBool doAcceptElement(nomdElements::typedElement typdel);
60
61  virtual bool createInputFile(particleBeam* beamBefore, string workingDir) = 0;
62  virtual bool execute(string workingDir) = 0;
63  virtual bool buildBeamAfterElements(string workingDir) = 0;
64
65  /** Color of the background of this sofware
66      Should be a valid Css name as FFEEDD
67  */
68  virtual string getColor() = 0;
69 
70  /** Name of this software
71   */
72  inline string getName() const {
73    return nameOfSoftware_->getString();
74  }
75  private :
76  sectionToExecute* sectionToExecute_;
77 
78};
79#endif
Note: See TracBrowser for help on using the repository browser.