Index: src/UIElements/CommandLineUI/CommandLineParser.cpp
===================================================================
--- src/UIElements/CommandLineUI/CommandLineParser.cpp	(revision e4afb4b989433224538ab4ba0f471e4573bbeaf2)
+++ src/UIElements/CommandLineUI/CommandLineParser.cpp	(revision 3a21a725fe8654c46053fbab3d721519872c4fa0)
@@ -21,10 +21,8 @@
 
 #include <boost/filesystem.hpp>
-#include <boost/lexical_cast.hpp>
 #include <boost/program_options.hpp>
 #include <fstream>
 #include <iostream>
 #include <map>
-#include <vector>
 
 #include "Actions/Action.hpp"
@@ -34,115 +32,12 @@
 #include "Actions/OptionTrait.hpp"
 #include "Actions/Values.hpp"
-#include "Helpers/Assert.hpp"
 #include "Helpers/Log.hpp"
 #include "Helpers/Verbose.hpp"
 #include "CommandLineParser.hpp"
+#include "CommandLineParser_validate.hpp"
 
 #include "Patterns/Singleton_impl.hpp"
 
 class element;
-
-using namespace std;
-
-/** boost::program_options validator specialization for VectorValue.
- * \param &v  reference for return value
- * \param &values string vector of scanned options
- * \param *
- * \param
- *
- */
-void validate(boost::any& v, const std::vector<std::string>& values, VectorValue *, int)
-{
-  VectorValue VV;
-  std::vector<std::string> components;
-
-  // split comma-separated values
-  if (values.size() != 1) {
-    cerr <<  "Not one vector but " << values.size() << " given " << endl;
-    throw boost::program_options::validation_error("Unequal to one vector given");
-  }
-  std::string argument(values.at(0));
-  std::string::iterator Aiter = argument.begin();
-  std::string::iterator Biter = argument.begin();
-  for (; Aiter != argument.end(); ++Aiter) {
-    if (*Aiter == ',') {
-      components.push_back(string(Biter,Aiter));
-      do {
-        Aiter++;
-      } while (*Aiter == ' ' || *Aiter == '\t');
-      Biter = Aiter;
-    }
-  }
-  components.push_back(string(Biter,argument.end()));
-
-  if (components.size() != 3) {
-    cerr <<  "Specified vector does not have three components but " << components.size() << endl;
-    throw boost::program_options::validation_error("Specified vector does not have three components");
-  }
-  VV.x = boost::lexical_cast<double>(components.at(0));
-  VV.y = boost::lexical_cast<double>(components.at(1));
-  VV.z = boost::lexical_cast<double>(components.at(2));
-  v = boost::any(VectorValue(VV));
-}
-
-void validate(boost::any& v, const std::vector<std::string>& values, BoxValue *, int)
-{
-  BoxValue BV;
-  std::vector<std::string> components;
-
-  // split comma-separated values
-  if (values.size() != 1) {
-    cerr <<  "Not one vector but " << values.size() << " given " << endl;
-    throw boost::program_options::validation_error("Unequal to one vector given");
-  }
-  std::string argument(values.at(0));
-  std::string::iterator Aiter = argument.begin();
-  std::string::iterator Biter = argument.begin();
-  for (; Aiter != argument.end(); ++Aiter) {
-    if (*Aiter == ',') {
-      components.push_back(string(Biter,Aiter));
-      do {
-        Aiter++;
-      } while (*Aiter == ' ' || *Aiter == '\t');
-      Biter = Aiter;
-    }
-  }
-  components.push_back(string(Biter,argument.end()));
-
-  if (components.size() != 6) {
-    cerr <<  "Specified vector does not have three components but " << components.size() << endl;
-    throw boost::program_options::validation_error("Specified symmetric box matrix does not have six components");
-  }
-  BV.xx = boost::lexical_cast<double>(components.at(0));
-  BV.yx = boost::lexical_cast<double>(components.at(1));
-  BV.yy = boost::lexical_cast<double>(components.at(2));
-  BV.zx = boost::lexical_cast<double>(components.at(3));
-  BV.zy = boost::lexical_cast<double>(components.at(4));
-  BV.zz = boost::lexical_cast<double>(components.at(5));
-  v = boost::any(BoxValue(BV));
-}
-
-/** boost::program_options validator specialization for boost::filesystem::path.
- * \param &v  reference for return value
- * \param &values string vector of scanned options
- * \param *
- * \param
- *
- */
-void validate(boost::any& v, const std::vector<std::string>& values, boost::filesystem::path *, int)
-{
-  boost::filesystem::path filename;
-
-  std::cout << "boost::filesystem::path validator used." << std::endl;
-
-  // split comma-separated values
-  if (values.size() != 1) {
-    cerr <<  "Not one file but " << values.size() << " given " << endl;
-    throw boost::program_options::validation_error("Unequal to one file given");
-  }
-  filename = values.at(0);
-  v = boost::any(boost::filesystem::path(filename));
-}
-
 
 /** Constructor of class CommandLineParser.
@@ -461,5 +356,5 @@
 {
   po::store(po::command_line_parser(argc,argv).options(cmdline_options).run(), vm);
-  ifstream input;
+  std::ifstream input;
   input.open("example.cfg");
   if (!input.fail())
@@ -473,8 +368,8 @@
 void CommandLineParser::scanforSequenceOfArguments()
 {
-  map <std::string, std::string> ShortFormToActionMap = getShortFormToActionMap();
+  std::map <std::string, std::string> ShortFormToActionMap = getShortFormToActionMap();
   // go through all arguments
   for (int i=1;i<argc;i++) {
-    (cout << Verbose(1) << "Checking on " << argv[i] << endl);
+    (std::cout << Verbose(1) << "Checking on " << argv[i] << std::endl);
     // check whether they
     if (argv[i][0] == '-') { // .. begin with -
@@ -485,5 +380,5 @@
         //  .. and check that next letter is not numeric, if so insert
       } else if (((argv[i][1] < '0') || (argv[i][1] > '9')) && ((argv[i][1] != '.'))) {
-        map <std::string, std::string>::iterator iter = ShortFormToActionMap.find(&(argv[i][1]));
+        std::map <std::string, std::string>::iterator iter = ShortFormToActionMap.find(&(argv[i][1]));
         if (iter != ShortFormToActionMap.end()) {
           (cout << Verbose(1) << "Putting " << iter->second << " for " << iter->first << " into the sequence." << endl);
@@ -511,5 +406,5 @@
 std::map <std::string, std::string> CommandLineParser::getShortFormToActionMap()
 {
-  map <std::string, std::string> result;
+  std::map <std::string, std::string> result;
 
   ActionRegistry &AR = ActionRegistry::getInstance();
Index: src/UIElements/CommandLineUI/CommandLineParser_validate.cpp
===================================================================
--- src/UIElements/CommandLineUI/CommandLineParser_validate.cpp	(revision 3a21a725fe8654c46053fbab3d721519872c4fa0)
+++ src/UIElements/CommandLineUI/CommandLineParser_validate.cpp	(revision 3a21a725fe8654c46053fbab3d721519872c4fa0)
@@ -0,0 +1,127 @@
+/*
+ * Project: MoleCuilder
+ * Description: creates and alters molecular systems
+ * Copyright (C)  2010 University of Bonn. All rights reserved.
+ * Please see the LICENSE file or "Copyright notice" in builder.cpp for details.
+ */
+
+/*
+ * CommandLineParser_validate.cpp
+ *
+ *  Created on: Nov 8, 2010
+ *      Author: heber
+ */
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "Helpers/MemDebug.hpp"
+
+#include <iostream>
+#include <string>
+
+#include "Actions/Values.hpp"
+#include "CommandLineParser_validate.hpp"
+
+/** boost::program_options validator specialization for VectorValue.
+ * \param &v  reference for return value
+ * \param &values string vector of scanned options
+ * \param *
+ * \param
+ *
+ */
+void validate(boost::any& v, const std::vector<std::string>& values, VectorValue *, int)
+{
+  VectorValue VV;
+  std::vector<std::string> components;
+
+  // split comma-separated values
+  if (values.size() != 1) {
+    std::cerr <<  "Not one vector but " << values.size() << " given " << std::endl;
+    throw boost::program_options::validation_error("Unequal to one vector given");
+  }
+  std::string argument(values.at(0));
+  std::string::iterator Aiter = argument.begin();
+  std::string::iterator Biter = argument.begin();
+  for (; Aiter != argument.end(); ++Aiter) {
+    if (*Aiter == ',') {
+      components.push_back(std::string(Biter,Aiter));
+      do {
+        Aiter++;
+      } while (*Aiter == ' ' || *Aiter == '\t');
+      Biter = Aiter;
+    }
+  }
+  components.push_back(std::string(Biter,argument.end()));
+
+  if (components.size() != 3) {
+    std::cerr <<  "Specified vector does not have three components but " << components.size() << std::endl;
+    throw boost::program_options::validation_error("Specified vector does not have three components");
+  }
+  VV.x = boost::lexical_cast<double>(components.at(0));
+  VV.y = boost::lexical_cast<double>(components.at(1));
+  VV.z = boost::lexical_cast<double>(components.at(2));
+  v = boost::any(VectorValue(VV));
+}
+
+void validate(boost::any& v, const std::vector<std::string>& values, BoxValue *, int)
+{
+  BoxValue BV;
+  std::vector<std::string> components;
+
+  // split comma-separated values
+  if (values.size() != 1) {
+    std::cerr <<  "Not one vector but " << values.size() << " given " << std::endl;
+    throw boost::program_options::validation_error("Unequal to one vector given");
+  }
+  std::string argument(values.at(0));
+  std::string::iterator Aiter = argument.begin();
+  std::string::iterator Biter = argument.begin();
+  for (; Aiter != argument.end(); ++Aiter) {
+    if (*Aiter == ',') {
+      components.push_back(std::string(Biter,Aiter));
+      do {
+        Aiter++;
+      } while (*Aiter == ' ' || *Aiter == '\t');
+      Biter = Aiter;
+    }
+  }
+  components.push_back(std::string(Biter,argument.end()));
+
+  if (components.size() != 6) {
+    std::cerr <<  "Specified vector does not have three components but " << components.size() << std::endl;
+    throw boost::program_options::validation_error("Specified symmetric box matrix does not have six components");
+  }
+  BV.xx = boost::lexical_cast<double>(components.at(0));
+  BV.yx = boost::lexical_cast<double>(components.at(1));
+  BV.yy = boost::lexical_cast<double>(components.at(2));
+  BV.zx = boost::lexical_cast<double>(components.at(3));
+  BV.zy = boost::lexical_cast<double>(components.at(4));
+  BV.zz = boost::lexical_cast<double>(components.at(5));
+  v = boost::any(BoxValue(BV));
+}
+
+/** boost::program_options validator specialization for boost::filesystem::path.
+ * \param &v  reference for return value
+ * \param &values string vector of scanned options
+ * \param *
+ * \param
+ *
+ */
+void validate(boost::any& v, const std::vector<std::string>& values, boost::filesystem::path *, int)
+{
+  boost::filesystem::path filename;
+
+  std::cerr << "boost::filesystem::path validator used." << std::endl;
+
+  // split comma-separated values
+  if (values.size() != 1) {
+    std::cerr <<  "Not one file but " << values.size() << " given " << std::endl;
+    throw boost::program_options::validation_error("Unequal to one file given");
+  }
+  filename = values.at(0);
+  v = boost::any(boost::filesystem::path(filename));
+}
+
Index: src/UIElements/CommandLineUI/CommandLineParser_validate.hpp
===================================================================
--- src/UIElements/CommandLineUI/CommandLineParser_validate.hpp	(revision 3a21a725fe8654c46053fbab3d721519872c4fa0)
+++ src/UIElements/CommandLineUI/CommandLineParser_validate.hpp	(revision 3a21a725fe8654c46053fbab3d721519872c4fa0)
@@ -0,0 +1,25 @@
+/*
+ * CommandLineParser_validate.hpp
+ *
+ *  Created on: Nov 8, 2010
+ *      Author: heber
+ */
+
+#ifndef COMMANDLINEPARSER_VALIDATE_HPP_
+#define COMMANDLINEPARSER_VALIDATE_HPP_
+
+#include <vector>
+#include <iosfwd>
+
+#include <boost/program_options.hpp>
+#include <boost/filesystem.hpp>
+#include <boost/lexical_cast.hpp>
+
+class BoxValue;
+class VectorValue;
+
+void validate(boost::any& v, const std::vector<std::string>& values, VectorValue *, int);
+void validate(boost::any& v, const std::vector<std::string>& values, BoxValue *, int);
+void validate(boost::any& v, const std::vector<std::string>& values, boost::filesystem::path *, int);
+
+#endif /* COMMANDLINEPARSER_VALIDATE_HPP_ */
