Changeset 574d377 for src


Ignore:
Timestamp:
Aug 5, 2015, 5:32:07 PM (9 years ago)
Author:
Frederik Heber <heber@…>
Branches:
Action_Thermostats, Add_AtomRandomPerturbation, Add_FitFragmentPartialChargesAction, Add_RotateAroundBondAction, Add_SelectAtomByNameAction, Added_ParseSaveFragmentResults, AddingActions_SaveParseParticleParameters, Adding_Graph_to_ChangeBondActions, Adding_MD_integration_tests, Adding_ParticleName_to_Atom, Adding_StructOpt_integration_tests, AtomFragments, Automaking_mpqc_open, AutomationFragmentation_failures, Candidate_v1.5.4, Candidate_v1.6.0, Candidate_v1.6.1, ChangeBugEmailaddress, ChangingTestPorts, ChemicalSpaceEvaluator, CombiningParticlePotentialParsing, Combining_Subpackages, Debian_Package_split, Debian_package_split_molecuildergui_only, Disabling_MemDebug, Docu_Python_wait, EmpiricalPotential_contain_HomologyGraph, EmpiricalPotential_contain_HomologyGraph_documentation, Enable_parallel_make_install, Enhance_userguide, Enhanced_StructuralOptimization, Enhanced_StructuralOptimization_continued, Example_ManyWaysToTranslateAtom, Exclude_Hydrogens_annealWithBondGraph, FitPartialCharges_GlobalError, Fix_BoundInBox_CenterInBox_MoleculeActions, Fix_ChargeSampling_PBC, Fix_ChronosMutex, Fix_FitPartialCharges, Fix_FitPotential_needs_atomicnumbers, Fix_ForceAnnealing, Fix_IndependentFragmentGrids, Fix_ParseParticles, Fix_ParseParticles_split_forward_backward_Actions, Fix_PopActions, Fix_QtFragmentList_sorted_selection, Fix_Restrictedkeyset_FragmentMolecule, Fix_StatusMsg, Fix_StepWorldTime_single_argument, Fix_Verbose_Codepatterns, Fix_fitting_potentials, Fixes, ForceAnnealing_goodresults, ForceAnnealing_oldresults, ForceAnnealing_tocheck, ForceAnnealing_with_BondGraph, ForceAnnealing_with_BondGraph_continued, ForceAnnealing_with_BondGraph_continued_betteresults, ForceAnnealing_with_BondGraph_contraction-expansion, FragmentAction_writes_AtomFragments, FragmentMolecule_checks_bonddegrees, GeometryObjects, Gui_Fixes, Gui_displays_atomic_force_velocity, ImplicitCharges, IndependentFragmentGrids, IndependentFragmentGrids_IndividualZeroInstances, IndependentFragmentGrids_IntegrationTest, IndependentFragmentGrids_Sole_NN_Calculation, JobMarket_RobustOnKillsSegFaults, JobMarket_StableWorkerPool, JobMarket_unresolvable_hostname_fix, MoreRobust_FragmentAutomation, ODR_violation_mpqc_open, PartialCharges_OrthogonalSummation, PdbParser_setsAtomName, PythonUI_with_named_parameters, QtGui_reactivate_TimeChanged_changes, Recreated_GuiChecks, Rewrite_FitPartialCharges, RotateToPrincipalAxisSystem_UndoRedo, SaturateAtoms_findBestMatching, SaturateAtoms_singleDegree, StoppableMakroAction, Subpackage_CodePatterns, Subpackage_JobMarket, Subpackage_LinearAlgebra, Subpackage_levmar, Subpackage_mpqc_open, Subpackage_vmg, Switchable_LogView, ThirdParty_MPQC_rebuilt_buildsystem, TrajectoryDependenant_MaxOrder, TremoloParser_IncreasedPrecision, TremoloParser_MultipleTimesteps, TremoloParser_setsAtomName, Ubuntu_1604_changes, stable
Children:
b3a33d
Parents:
0ea4dd
git-author:
Frederik Heber <heber@…> (07/05/15 07:55:15)
git-committer:
Frederik Heber <heber@…> (08/05/15 17:32:07)
Message:

Using static Observable::..NotificationsChannel() functions.

Location:
src
Files:
16 edited

Legend:

Unmodified
Added
Removed
  • src/Actions/ActionQueue.cpp

    r0ea4dd r574d377  
    7272  // channels of observable
    7373  Channels *OurChannel = new Channels;
    74   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     74  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    7575  // add instance for each notification type
    7676  for (size_t type = 0; type < NotificationType_MAX; ++type)
  • src/Actions/ActionStatusList.cpp

    r0ea4dd r574d377  
    4545{
    4646  Channels *OurChannel = new Channels;
    47   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     47  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    4848  // add instance for each notification type
    4949  for (size_t type = 0; type < NotificationType_MAX; ++type)
  • src/Atom/AtomObserver.cpp

    r0ea4dd r574d377  
    5151{
    5252  Channels *OurChannel = new Channels();
    53   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     53  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    5454  OurChannel->addChannel(AtomObservable::PositionChanged);
    5555  OurChannel->addChannel(AtomObservable::ElementChanged);
  • src/Atom/atom_observable.cpp

    r0ea4dd r574d377  
    4747{
    4848  Channels *OurChannel = new Channels;
    49   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     49  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    5050  // add instance for each notification type
    5151  for (size_t type = 0; type < NotificationType_MAX; ++type)
  • src/Bond/bond_observable.cpp

    r0ea4dd r574d377  
    4848{
    4949  Channels *OurChannel = new Channels;
    50   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     50  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    5151  // add instance for each notification type
    5252  for (size_t type = 0; type < NotificationType_MAX; ++type)
  • src/Box.cpp

    r0ea4dd r574d377  
    6767  // observable stuff
    6868  Channels *OurChannel = new Channels;
    69   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     69  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    7070  // add instance for each notification type
    7171  for (size_t type = 0; type < NotificationType_MAX; ++type)
     
    8888  // observable stuff
    8989  Channels *OurChannel = new Channels;
    90   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     90  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    9191  // add instance for each notification type
    9292  for (size_t type = 0; type < NotificationType_MAX; ++type)
     
    105105  // observable stuff
    106106  Channels *OurChannel = new Channels;
    107   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     107  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    108108  // add instance for each notification type
    109109  for (size_t type = 0; type < NotificationType_MAX; ++type)
  • src/LinkedCell/unittests/stubs/AtomObserverStub.cpp

    r0ea4dd r574d377  
    4747{
    4848  Channels *OurChannel = new Channels();
    49   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     49  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    5050  OurChannel->addChannel(AtomObservable::PositionChanged);
    5151}
  • src/LinkedCell/unittests/stubs/ObserverBoxStub.cpp

    r0ea4dd r574d377  
    5050  // observable stuff
    5151  Channels *OurChannel = new Channels;
    52   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     52  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    5353  // add instance for each notification type
    5454  OurChannel->addChannel(Box::MatrixChanged);
  • src/LinkedCell/unittests/stubs/WorldTimeStub.cpp

    r0ea4dd r574d377  
    5050  // observable stuff
    5151  Channels *OurChannel = new Channels;
    52   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     52  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    5353  // add instance for each notification type
    5454  for (size_t type = 0; type < NotificationType_MAX; ++type)
  • src/Shapes/ShapeRegistry.cpp

    r0ea4dd r574d377  
    4848{
    4949  Channels *OurChannel = new Channels;
    50   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     50  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    5151  // add instance for each notification type
    5252  for (size_t type = 0; type < NotificationType_MAX; ++type)
  • src/Shapes/unittests/stubs/WorldSelectedMoleculesStub.cpp

    r0ea4dd r574d377  
    7171  // observable stuff
    7272  Channels *OurChannel = new Channels;
    73   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     73  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    7474  // add instance for each notification type
    7575  OurChannel->addChannel(World::AtomInserted);
  • src/World.cpp

    r0ea4dd r574d377  
    969969  defaultName = "none";
    970970  Channels *OurChannel = new Channels;
    971   NotificationChannels.insert( std::make_pair( static_cast<Observable *>(this), OurChannel) );
     971  Observable::insertNotificationChannel( std::make_pair( static_cast<Observable *>(this), OurChannel) );
    972972  for (size_t type = 0; type < (size_t)NotificationType_MAX; ++type)
    973973    OurChannel->addChannel(type);
  • src/WorldTime.cpp

    r0ea4dd r574d377  
    5151  // observable stuff
    5252  Channels *OurChannel = new Channels;
    53   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     53  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    5454  // add instance for each notification type
    5555  for (size_t type = 0; type < NotificationType_MAX; ++type)
  • src/cleanUp.cpp

    r0ea4dd r574d377  
    4747#include "CodePatterns/logger.hpp"
    4848#include "CodePatterns/Observer/ObserverLog.hpp"
     49#include "CodePatterns/Observer/GlobalObservableInfo.hpp"
    4950
    5051#include "Actions/ActionQueue.hpp"
     
    155156  // CodePatterns always initializes observerLog except with NDEBUG
    156157  ObserverLog::purgeInstance();
     158  GlobalObservableInfo::purgeInstance();
    157159#endif
    158160  Memory::getState();
  • src/molecule.cpp

    r0ea4dd r574d377  
    8787  // add specific channels
    8888  Channels *OurChannel = new Channels;
    89   NotificationChannels.insert( std::make_pair( static_cast<Observable *>(this), OurChannel) );
     89  Observable::insertNotificationChannel( std::make_pair( static_cast<Observable *>(this), OurChannel) );
    9090  for (size_t type = 0; type < (size_t)NotificationType_MAX; ++type)
    9191    OurChannel->addChannel(type);
  • src/unittests/stubs/WorldStub.cpp

    r0ea4dd r574d377  
    7171  // observable stuff
    7272  Channels *OurChannel = new Channels;
    73   NotificationChannels.insert( std::make_pair(static_cast<Observable *>(this), OurChannel) );
     73  Observable::insertNotificationChannel( std::make_pair(static_cast<Observable *>(this), OurChannel) );
    7474  // add instance for each notification type
    7575  OurChannel->addChannel(World::AtomInserted);
Note: See TracChangeset for help on using the changeset viewer.