Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/molecule.hpp

    r6adb96 r244a84  
    2727#include <vector>
    2828
    29 #include <string>
    30 
    3129#include "graph.hpp"
    3230#include "stackclass.hpp"
    3331#include "tesselation.hpp"
    34 #include "Patterns/Observer.hpp"
    3532
    3633/****************************************** forward declarations *****************************/
     
    8380 * Class incorporates number of types
    8481 */
    85 class molecule : public PointCloud , public Observable {
     82class molecule : public PointCloud {
    8683  public:
    8784    double cell_size[6];//!< cell size
     
    10299    bool ActiveFlag;    //!< in a MoleculeListClass used to discern active from inactive molecules
    103100    Vector Center;      //!< Center of molecule in a global box
     101    char name[MAXSTRINGSIZE];         //!< arbitrary name
    104102    int IndexNr;        //!< index of molecule in a MoleculeListClass
    105     char name[MAXSTRINGSIZE];         //!< arbitrary name
    106 
    107 public:
     103
    108104  molecule(const periodentafel * const teil);
    109105  virtual ~molecule();
    110106
    111   //getter and setter
    112   const std::string getName();
    113   void setName(const std::string);
    114 
    115107  // re-definition of virtual functions from PointCloud
     108  const char * const GetName() const;
    116109  Vector *GetCenter() const ;
    117110  TesselPoint *GetPoint() const ;
    118111  TesselPoint *GetTerminalPoint() const ;
     112  int GetMaxId() const;
    119113  void GoToNext() const ;
    120114  void GoToPrevious() const ;
     
    304298  bool OutputTemperatureFromTrajectories(ofstream * const output, int startstep, int endstep);
    305299
    306   // Manipulation routines
    307   void flipActiveFlag();
    308 
    309300  private:
    310301  int last_atom;      //!< number given to last atom
     
    316307/** A list of \a molecule classes.
    317308 */
    318 class MoleculeListClass : public Observable {
     309class MoleculeListClass {
    319310  public:
    320311    MoleculeList ListOfMolecules; //!< List of the contained molecules
     
    332323  void Enumerate(ofstream *out);
    333324  void Output(ofstream *out);
    334   void DissectMoleculeIntoConnectedSubgraphs(molecule * const mol, config * const configuration);
     325  void DissectMoleculeIntoConnectedSubgraphs(const periodentafel * const periode, config * const configuration);
    335326  int CountAllAtoms() const;
    336 
    337   // Methods moved here from the menus
    338   // TODO: more refactoring needed on these methods
    339   void flipChosen();
    340   void createNewMolecule(periodentafel *periode);
    341   void loadFromXYZ(periodentafel *periode);
    342   void setMoleculeFilename();
    343   void parseXYZIntoMolecule();
    344   void eraseMolecule();
    345 
    346327
    347328  // merging of molecules
Note: See TracChangeset for help on using the changeset viewer.