Changeset f61f61 for src/Filling
- Timestamp:
- Mar 30, 2012, 9:18:26 AM (13 years ago)
- 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:
- 68abe5
- Parents:
- 901d87
- git-author:
- Frederik Heber <heber@…> (02/21/12 13:55:58)
- git-committer:
- Frederik Heber <heber@…> (03/30/12 09:18:26)
- Location:
- src/Filling
- Files:
-
- 2 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Filling/Inserter/Inserter.hpp
r901d87 rf61f61 15 15 #endif 16 16 17 #include <boost/shared_ptr.hpp> 18 17 19 #include "Filling/ClusterInterface.hpp" 18 20 … … 20 22 class Vector; 21 23 22 /** Inserter defines the interface to all classes that handle insertion of \a 23 * Cluster into the World at a specific position. 24 class InserterBase; 25 26 /** This class defines the interface for all derived classes. 27 * 28 * This is just a functor of an inserter function. 29 * 24 30 */ 25 31 class Inserter 26 32 { 27 33 public: 28 virtual void operator()(CopyAtomsInterface ©Method, ClusterInterface::Cluster_impl cluster, const Vector &offset) const = 0; 34 typedef boost::shared_ptr<InserterBase> impl_ptr; 35 friend impl_ptr getInserterImpl(const Inserter&); 29 36 30 virtual ~Inserter() {} 37 Inserter(const Inserter &ptr); 38 Inserter(impl_ptr); 39 ~Inserter(); 40 void operator()(CopyAtomsInterface ©Method, ClusterInterface::Cluster_impl cluster, const Vector &offset) const; 41 42 protected: 43 impl_ptr getImpl() const; 44 45 private: 46 impl_ptr impl; 31 47 }; 48 49 Inserter::impl_ptr getInserterImpl(const Inserter &f); 32 50 33 51 -
src/Filling/Inserter/SimpleInserter.hpp
r901d87 rf61f61 15 15 #endif 16 16 17 #include "Filling/Inserter/Inserter .hpp"17 #include "Filling/Inserter/InserterBase.hpp" 18 18 19 19 /** SimpleInserter implements Inserter interface such that the given \a Cluster 20 20 * is simply inserted at the given position. 21 21 */ 22 class SimpleInserter : public Inserter 22 class SimpleInserter : public InserterBase 23 23 { 24 24 public: -
src/Filling/Makefile.am
r901d87 rf61f61 8 8 Filling/Filler.cpp \ 9 9 Filling/Generators/NodeGenerator.cpp \ 10 Filling/Inserter/Inserter.cpp \ 10 11 Filling/Inserter/SimpleInserter.cpp \ 11 12 Filling/Predicates/AnyFillPredicate.cpp \ … … 24 25 Filling/Generators/NodeGenerator.hpp \ 25 26 Filling/Inserter/Inserter.hpp \ 27 Filling/Inserter/InserterBase.hpp \ 26 28 Filling/Inserter/SimpleInserter.hpp \ 27 29 Filling/NodeTypes.hpp \ -
src/Filling/unittests/FillerUnitTest.cpp
r901d87 rf61f61 30 30 #include "Filling/Cluster.hpp" 31 31 #include "Filling/Filler.hpp" 32 #include "Filling/Inserter/Inserter.hpp" 32 33 #include "Filling/Inserter/SimpleInserter.hpp" 33 34 #include "Filling/Mesh/Mesh.hpp" … … 71 72 predicate = new FillPredicate(AlwaysFillPredicate()); 72 73 mesh = new MeshStub(); 73 inserter = new SimpleInserter();74 inserter = new Inserter(Inserter::impl_ptr(new SimpleInserter())); 74 75 CPPUNIT_ASSERT_EQUAL( (size_t)5, mesh->getNodes().size() ); 75 76 filler = new Filler(*mesh, *predicate, *inserter);
Note:
See TracChangeset
for help on using the changeset viewer.