Changeset 839e85
- Timestamp:
- Aug 4, 2010, 10:19:50 AM (14 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:
- ca275d
- Parents:
- c4b85d
- Location:
- src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
src/Helpers/Assert.cpp
rc4b85d r839e85 46 46 } 47 47 48 using namespace Assert;49 50 48 #ifndef NDEBUG 51 49 52 A ction_my_assert::defaultAction = Ask;53 std::vector<Assert::hook_t> _my_assert::hooks;50 Assert::Action Assert::_my_assert::defaultAction = Ask; 51 std::vector<Assert::hook_t> Assert::_my_assert::hooks; 54 52 55 std::map<std::string,bool> _wrapper::ignores;56 const char* _wrapper::message_ptr = "source pointer did not point to object of desired type";57 const char* _wrapper::message_ref = "source reference did not contain object of desired type";53 std::map<std::string,bool> Assert::_wrapper::ignores; 54 const char* Assert::_wrapper::message_ptr = "source pointer did not point to object of desired type"; 55 const char* Assert::_wrapper::message_ref = "source reference did not contain object of desired type"; 58 56 59 57 60 bool _my_assert::check(const bool res,58 bool Assert::_my_assert::check(const bool res, 61 59 const char* condition, 62 60 const char* message, … … 70 68 while(true){ 71 69 char choice; 72 if(defaultAction==As k) {70 if(defaultAction==Assert::Ask) { 73 71 cout << "Please choose: (a)bort, (t)hrow execption, (i)gnore, al(w)ays ignore" << endl; 74 72 cin >> choice; … … 96 94 } 97 95 98 void _my_assert::doHooks(){96 void Assert::_my_assert::doHooks(){ 99 97 for(vector<hook_t>::reverse_iterator iter = hooks.rbegin(); iter!=hooks.rend(); ++iter ){ 100 98 (*iter)(); … … 102 100 } 103 101 104 void _my_assert::addHook(hook_t hook){102 void Assert::_my_assert::addHook(hook_t hook){ 105 103 hooks.push_back(hook); 106 104 } 107 105 108 void _my_assert::removeHook(Assert::hook_t hook){106 void Assert::_my_assert::removeHook(Assert::hook_t hook){ 109 107 for(vector<hook_t>::iterator iter = hooks.begin(); iter!=hooks.end();){ 110 108 if((*iter)==hook){ … … 117 115 } 118 116 119 void _my_assert::setDefault(Assert::Action action){117 void Assert::_my_assert::setDefault(Assert::Action action){ 120 118 defaultAction = action; 121 119 } 122 Assert::Action _my_assert::getDefault(){120 Assert::Action Assert::_my_assert::getDefault(){ 123 121 return defaultAction; 124 122 } 125 std::string _my_assert::printDefault(){123 std::string Assert::_my_assert::printDefault(){ 126 124 return ActionNames[defaultAction]; 127 125 } -
src/Parser/TremoloParser.cpp
rc4b85d r839e85 21 21 22 22 using namespace std; 23 using namespace boost;24 23 25 24 /** -
src/log.hpp
rc4b85d r839e85 12 12 #include "logger.hpp" 13 13 14 class logger *Log();15 class errorLogger *eLog();14 class logger & Log(); 15 class errorLogger & eLog(); 16 16 void setVerbosity(int verbosityLevel); 17 17 bool DoLog(int verbose);
Note:
See TracChangeset
for help on using the changeset viewer.