Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/World.cpp

    r387b36 r6d574a  
    55 *      Author: crueger
    66 */
     7
     8#include "Helpers/MemDebug.hpp"
    79
    810#include "World.hpp"
     
    1820#include "Descriptors/SelectiveIterator_impl.hpp"
    1921#include "Actions/ManipulateAtomsProcess.hpp"
     22#include "Helpers/Assert.hpp"
    2023
    2124#include "Patterns/Singleton_impl.hpp"
     
    103106  molecule *mol = NULL;
    104107  mol = NewMolecule();
    105   assert(!molecules.count(currMoleculeId));
     108  ASSERT(!molecules.count(currMoleculeId),"currMoleculeId did not specify an unused ID");
    106109  mol->setId(currMoleculeId++);
    107110  // store the molecule by ID
     
    119122  OBSERVE;
    120123  molecule *mol = molecules[id];
    121   assert(mol);
     124  ASSERT(mol,"Molecule id that was meant to be destroyed did not exist");
    122125  DeleteMolecule(mol);
    123126  molecules.erase(id);
     
    155158  OBSERVE;
    156159  atom *atom = atoms[id];
    157   assert(atom);
     160  ASSERT(atom,"Atom ID that was meant to be destroyed did not exist");
    158161  DeleteAtom(atom);
    159162  atoms.erase(id);
     
    167170  if(!target){
    168171    target = atoms[oldId];
    169     assert(target && "Atom with that ID not found");
     172    ASSERT(target,"Atom with that ID not found");
    170173    return target->changeId(newId);
    171174  }
     
    276279
    277280World::World() :
     281    Observable("World"),
    278282    periode(new periodentafel),
    279283    configuration(new config),
Note: See TracChangeset for help on using the changeset viewer.