diff --git a/alib2/src/AlibException.cpp b/alib2/src/AlibException.cpp
index 3e6e35b633621a9b11a7ea5f19f9f849314b5716..054eb0c615984dbdbb837a8a6eaf4da553cba502 100644
--- a/alib2/src/AlibException.cpp
+++ b/alib2/src/AlibException.cpp
@@ -2,7 +2,7 @@
  * AlibException.cpp
  *
  *  Created on: Apr 1, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include "AlibException.h"
diff --git a/alib2/src/AlibException.h b/alib2/src/AlibException.h
index a22efddc47d6b85abef031cc2dac31ce03bc21ef..5cef527fd5d039cd34d6d03609a599e4aacf48dc 100644
--- a/alib2/src/AlibException.h
+++ b/alib2/src/AlibException.h
@@ -2,29 +2,27 @@
  * AlibException.h
  *
  *  Created on: Apr 1, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
-#ifndef ALIBEXCEPTION_H_
-#define ALIBEXCEPTION_H_
+#ifndef ALIB_EXCEPTION_H_
+#define ALIB_EXCEPTION_H_
 
 #include <exception>
 #include <string>
 
 namespace alib {
 
-using namespace std;
-
 /**
  * Basic exception from which are derived all other exceptions.
  * Contains reason why the exception occured.
  */
-class AlibException: public exception {
+class AlibException : public std::exception {
 protected:
-	string cause;
+	std::string cause;
 public:
 	AlibException();
-	AlibException(const string& cause);
+	AlibException(const std::string& cause);
 	virtual ~AlibException() throw ();
 
 	/**
@@ -39,4 +37,5 @@ public:
 };
 
 } /* namespace alib */
-#endif /* ALIBEXCEPTION_H_ */
+
+#endif /* ALIB_EXCEPTION_H_ */
diff --git a/alib2/src/alphabet/Epsilon.cpp b/alib2/src/alphabet/Epsilon.cpp
index 22f884f5979f7bee164ca7fab4039c40c0dc774e..a95b26c47abe90547d2ad2c1538bb1eb15d206a4 100644
--- a/alib2/src/alphabet/Epsilon.cpp
+++ b/alib2/src/alphabet/Epsilon.cpp
@@ -27,8 +27,8 @@ bool Epsilon::operator !=(const Epsilon& other) const {
 
 std::ostream& operator<<(std::ostream& out, const Epsilon& symbol) {
 
-	out << "Epsilon";
+	out << "(Epsilon)";
 	return out;
 }
 
-} /* namespace language */
+} /* namespace alphabet */
diff --git a/alib2/src/alphabet/Epsilon.h b/alib2/src/alphabet/Epsilon.h
index d36616d7acec9bb3127dc389edbc3cb2cad8e3e4..36add1b28252946cbbd1a24e055d292c053f7059 100644
--- a/alib2/src/alphabet/Epsilon.h
+++ b/alib2/src/alphabet/Epsilon.h
@@ -28,5 +28,7 @@ public:
 
 	friend std::ostream& operator<<(std::ostream&, const Epsilon&);
 };
-}
+
+} /* namespace alphabet */
+
 #endif /* EPSILON_H_ */
diff --git a/alib2/src/alphabet/Symbol.cpp b/alib2/src/alphabet/Symbol.cpp
index b16010e82870a00571823f18cc478b699397e20b..29215ae225cefb926fa4fc7612e099da8cc1a328 100644
--- a/alib2/src/alphabet/Symbol.cpp
+++ b/alib2/src/alphabet/Symbol.cpp
@@ -35,8 +35,8 @@ bool Symbol::operator !=(const Symbol& other) const {
 
 std::ostream& operator<<(std::ostream& out, const Symbol& symbol) {
 
-	out << "Symbol " << (symbol.symbol == "" ? "\\epsilon" : symbol.symbol);
+	out << "(Symbol " << symbol.symbol << ")";
 	return out;
 }
 
-} /* namespace language */
+} /* namespace alphabet */
diff --git a/alib2/src/alphabet/Symbol.h b/alib2/src/alphabet/Symbol.h
index 9b82e08a355cdef5843cdcedb027776e28b0a95c..7bbe40df56a8fb91151a1cd61ff2e12e6cb55c6b 100644
--- a/alib2/src/alphabet/Symbol.h
+++ b/alib2/src/alphabet/Symbol.h
@@ -17,7 +17,6 @@ namespace alphabet {
  * Represents symbol in an alphabet.
  */
 class Symbol {
-protected:
 	std::string symbol;
 public:
 	/**
@@ -38,5 +37,7 @@ public:
 
 	friend std::ostream& operator<<(std::ostream&, const Symbol&);
 };
-}
+
+} /* namespace alphabet */
+
 #endif /* SYMBOL_H_ */
diff --git a/alib2/src/factory/RegExpFactory.cpp b/alib2/src/factory/RegExpFactory.cpp
index 093a77e3a43bdb040df33c0a81acc209664aa88a..05196f5506d2fe62075240f76eb2819612633156 100644
--- a/alib2/src/factory/RegExpFactory.cpp
+++ b/alib2/src/factory/RegExpFactory.cpp
@@ -2,7 +2,7 @@
  * RegExpFactory.cpp
  *
  *  Created on: Jan 1, 2014
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include <iostream>
@@ -13,28 +13,28 @@
 
 namespace regexp {
 
-RegExp RegExpFactory::fromFile(const string& filename) {
-	std::list<Token> tokens;
-	SaxInterface::parseFile(filename, tokens);
+RegExp RegExpFactory::fromFile(const std::string& filename) {
+	std::list<sax::Token> tokens;
+	sax::SaxInterface::parseFile(filename, tokens);
 	return parse(tokens);
 }
 
-RegExp RegExpFactory::fromString(const string& str) {
-	list<Token> tokens;
-	SaxInterface::parseMemory(str, tokens);
+RegExp RegExpFactory::fromString(const std::string& str) {
+	std::list<sax::Token> tokens;
+	sax::SaxInterface::parseMemory(str, tokens);
 	return parse(tokens);
 }
 
 RegExp RegExpFactory::fromStdin() {
-	return RegExpFactory::fromStream(cin);
+	return RegExpFactory::fromStream(std::cin);
 }
 
 RegExp RegExpFactory::fromStream(std::istream& in) {
-	string input(istreambuf_iterator<char>(in), (istreambuf_iterator<char>()));
+	std::string input(std::istreambuf_iterator<char>(in), (std::istreambuf_iterator<char>()));
 	return RegExpFactory::fromString(input);
 }
 
-RegExp RegExpFactory::parse(list<sax::Token> tokens) {
+RegExp RegExpFactory::parse(std::list<sax::Token> tokens) {
 	RegExpFromXMLParser parser;
 	return parser.parse(tokens);
 }
diff --git a/alib2/src/factory/RegExpFactory.h b/alib2/src/factory/RegExpFactory.h
index b9940207f613569432f4c142eb95fef66cbbe891..84112c3c9685658dabd7a01f8326b37b40e02879 100644
--- a/alib2/src/factory/RegExpFactory.h
+++ b/alib2/src/factory/RegExpFactory.h
@@ -2,20 +2,17 @@
  * RegExpFactory.h
  *
  *  Created on: Jan 1, 2014
- *      Author: martin
+ *      Author: Martin Zak
  */
 
-#ifndef REGEXPFACTORY_H_
-#define REGEXPFACTORY_H_
+#ifndef REG_EXP_FACTORY_H_
+#define REG_EXP_FACTORY_H_
 
 #include "../sax/Token.h"
 #include "../regexp/RegExp.h"
 
 namespace regexp {
 
-using namespace std;
-using namespace sax;
-
 /**
  * RegExp builder.
  */
@@ -26,14 +23,14 @@ public:
 	 * @param filename path to the file
 	 * @return RegExp
 	 */
-	static RegExp fromFile(const string& filename);
+	static RegExp fromFile(const std::string& filename);
 
 	/**
 	 * Parses the XML and returns the RegExp.
 	 * @param str string containing the XML
 	 * @return RegExp
 	 */
-	static RegExp fromString(const string& str);
+	static RegExp fromString(const std::string& str);
 	
 	/**
 	 * Parses the XML from stdin and returns the RegExp.
@@ -53,8 +50,9 @@ protected:
 	 * @param tokens XML represented as list of tokens
 	 * @return parsed RegExp
 	 */
-	static RegExp parse(list<Token> tokens);
+	static RegExp parse(std::list<sax::Token> tokens);
 };
 
 } /* namespace regexp */
-#endif /* REGEXPFACTORY_H_ */
+
+#endif /* REG_EXP_FACTORY_H_ */
diff --git a/alib2/src/regexp/Alternation.cpp b/alib2/src/regexp/Alternation.cpp
index e3fd7b15088d0944555cba27474135b42da89455..8662f584038f55fd0946941b120b14504e20f138 100644
--- a/alib2/src/regexp/Alternation.cpp
+++ b/alib2/src/regexp/Alternation.cpp
@@ -2,7 +2,7 @@
  * Alternation.cpp
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include "Alternation.h"
@@ -10,15 +10,16 @@
 namespace regexp {
 
 Alternation::Alternation() {
+
 }
 
 Alternation::Alternation(const Alternation& other) {
-	for (auto element : other.elements) {
+	for (const auto& element : other.elements) {
 		elements.push_back(element->clone());
 	}
 }
 
-Alternation& Alternation::operator =(const Alternation& other) {
+Alternation& Alternation::operator=(const Alternation& other) {
 	if (this == &other) {
 		return *this;
 	}
@@ -28,7 +29,7 @@ Alternation& Alternation::operator =(const Alternation& other) {
 	}
 	elements.clear();
 
-	for (auto element : other.elements) {
+	for (const auto& element : other.elements) {
 		elements.push_back(element->clone());
 	}
 
@@ -42,11 +43,11 @@ Alternation::~Alternation() {
 	elements.clear();
 }
 
-list<RegExpElement*>& Alternation::getElements() {
+std::list<RegExpElement*>& Alternation::getElements() {
 	return elements;
 }
 
-const list<RegExpElement*>& Alternation::getElements() const {
+const std::list<RegExpElement*>& Alternation::getElements() const {
 	return elements;
 }
 
@@ -104,7 +105,7 @@ bool Alternation::operator==(const Alternation& other) const {
 	return true;
 }
 
-void Alternation::operator>>(ostream& out) const {
+void Alternation::operator>>(std::ostream& out) const {
 	out << "(Alternation";
 	for(const auto& e : getElements())
 		out << " " << *e;
diff --git a/alib2/src/regexp/Alternation.h b/alib2/src/regexp/Alternation.h
index a5e7b56b6716dbef32db9ac2c02839e265672b40..6b14f5bbd2006d871b266180ceb861816cd051bc 100644
--- a/alib2/src/regexp/Alternation.h
+++ b/alib2/src/regexp/Alternation.h
@@ -2,7 +2,7 @@
  * Alternation.h
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #ifndef ALTERNATION_H_
@@ -13,15 +13,13 @@
 
 namespace regexp {
 
-using namespace std;
-
 /**
  * Represents alternation operator in the regular expression. Contains list of RegExpElement
  * as operands of the operator.
  */
 class Alternation: public RegExpElement, public std::element<Alternation, RegExpElement::visitor_type> {
 private:
-	list<RegExpElement*> elements;
+	std::list<RegExpElement*> elements;
 public:
 	Alternation();
 	Alternation(const Alternation& other);
@@ -31,12 +29,12 @@ public:
 	/**
 	 * @return list of operands
 	 */
-	list<RegExpElement*>& getElements();
+	std::list<RegExpElement*>& getElements();
 
 	/**
 	 * @return list of operands
 	 */
-	const list<RegExpElement*>& getElements() const;
+	const std::list<RegExpElement*>& getElements() const;
 
 	/**
 	 * @copydoc RegExpElement::clone() const
@@ -54,7 +52,7 @@ public:
 	/**
 	 * @copydoc RegExpElement::operator>>() const
 	 */
-	virtual void operator>>(ostream& out) const;
+	virtual void operator>>(std::ostream& out) const;
 
 	/**
 	 * @copydoc RegExpElement::getAlphabet() const
@@ -73,4 +71,5 @@ public:
 };
 
 } /* namespace regexp */
+
 #endif /* ALTERNATION_H_ */
diff --git a/alib2/src/regexp/Concatenation.cpp b/alib2/src/regexp/Concatenation.cpp
index e2553fc7567bf9e4d85750e202b915e6ef854d97..a7f4138b284be6950c403a39c2c1d2a1a1d9c875 100644
--- a/alib2/src/regexp/Concatenation.cpp
+++ b/alib2/src/regexp/Concatenation.cpp
@@ -2,7 +2,7 @@
  * Concatenation.cpp
  *
  *  Created on: Nov 27, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include "Concatenation.h"
@@ -28,7 +28,7 @@ Concatenation& Concatenation::operator =(const Concatenation& other) {
 	}
 	elements.clear();
 
-	for (auto element : other.elements) {
+	for (const auto& element : other.elements) {
 		elements.push_back(element->clone());
 	}
 
@@ -42,11 +42,11 @@ Concatenation::~Concatenation() {
 	elements.clear();
 }
 
-list<RegExpElement*>& Concatenation::getElements() {
+std::list<RegExpElement*>& Concatenation::getElements() {
 	return elements;
 }
 
-const list<RegExpElement*>& Concatenation::getElements() const {
+const std::list<RegExpElement*>& Concatenation::getElements() const {
 	return elements;
 }
 
@@ -95,7 +95,7 @@ bool Concatenation::operator==(const Concatenation& other) const {
 	return true;
 }
 
-void Concatenation::operator>>(ostream& out) const {
+void Concatenation::operator>>(std::ostream& out) const {
 	out << "(Concatenation";
 	for(const auto& e : getElements())
 		out << " " << *e;
diff --git a/alib2/src/regexp/Concatenation.h b/alib2/src/regexp/Concatenation.h
index 03a3115fc5bc5d231d0bacd1ba3ae593064b59a9..3d52b41ef85bf6f49e1322e08391957eb148a8c2 100644
--- a/alib2/src/regexp/Concatenation.h
+++ b/alib2/src/regexp/Concatenation.h
@@ -2,7 +2,7 @@
  * Concatenation.h
  *
  *  Created on: Nov 27, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #ifndef CONCATENATION_H_
@@ -13,15 +13,13 @@
 
 namespace regexp {
 
-using namespace std;
-
 /**
  * Represents concatenation operator in the regular expression. Contains list of RegExpElement
  * as operands of the operator.
  */
 class Concatenation: public RegExpElement, public std::element<Concatenation, RegExpElement::visitor_type> {
 private:
-	list<RegExpElement*> elements;
+	std::list<RegExpElement*> elements;
 public:
 	Concatenation();
 	Concatenation(const Concatenation& other);
@@ -31,12 +29,12 @@ public:
 	/**
 	 * @return list of operands
 	 */
-	list<RegExpElement*>& getElements();
+	std::list<RegExpElement*>& getElements();
 
 	/**
 	 * @return list of operands
 	 */
-	const list<RegExpElement*>& getElements() const;
+	const std::list<RegExpElement*>& getElements() const;
 
 	/**
 	 * @copydoc RegExpElement::clone() const
@@ -53,7 +51,7 @@ public:
 	/**
 	 * @copydoc RegExpElement::operator>>() const
 	 */
-	virtual void operator>>(ostream& out) const;
+	virtual void operator>>(std::ostream& out) const;
 
 	/**
 	 * @copydoc RegExpElement::getAlphabet() const
@@ -72,4 +70,5 @@ public:
 };
 
 } /* namespace regexp */
+
 #endif /* CONCATENATION_H_ */
diff --git a/alib2/src/regexp/Iteration.cpp b/alib2/src/regexp/Iteration.cpp
index 6bd9f316252b1beee19f2965ea10833ffb46536c..436b3eaca33d03d6d47b9471ca4f4556b5f437ba 100644
--- a/alib2/src/regexp/Iteration.cpp
+++ b/alib2/src/regexp/Iteration.cpp
@@ -2,7 +2,7 @@
  * Iteration.cpp
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include "Iteration.h"
@@ -93,7 +93,7 @@ bool Iteration::operator==(const Iteration& other) const {
 	return *(this->element) == *(other.element);
 }
 
-void Iteration::operator>>(ostream& out) const {
+void Iteration::operator>>(std::ostream& out) const {
 	out << "(RegExpIteration " << *element << ")";
 }
 
diff --git a/alib2/src/regexp/Iteration.h b/alib2/src/regexp/Iteration.h
index 097e249b17dd511bc82036930b8106b6da2dda51..09617598a836fb07b8975cb101ec7479c73ccfd8 100644
--- a/alib2/src/regexp/Iteration.h
+++ b/alib2/src/regexp/Iteration.h
@@ -2,7 +2,7 @@
  * Iteration.h
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #ifndef ITERATION_H_
@@ -13,8 +13,6 @@
 
 namespace regexp {
 
-using namespace std;
-
 /**
  * Represents iteration operator in the regular expression. Contains one RegExpElement
  * as operand.
@@ -61,7 +59,7 @@ public:
 	/**
 	 * @copydoc RegExpElement::operator>>() const
 	 */
-	virtual void operator>>(ostream& out) const;
+	virtual void operator>>(std::ostream& out) const;
 
 	/**
 	 * @copydoc RegExpElement::getAlphabet() const
@@ -80,4 +78,5 @@ public:
 };
 
 } /* namespace regexp */
+
 #endif /* ITERATION_H_ */
diff --git a/alib2/src/regexp/RegExp.cpp b/alib2/src/regexp/RegExp.cpp
index 6d0ea276b729fe99dfd8ec4f00e5b1ec1e998120..cfa2967a7726d91fdcb24f0920ceb667edf97657 100644
--- a/alib2/src/regexp/RegExp.cpp
+++ b/alib2/src/regexp/RegExp.cpp
@@ -2,7 +2,7 @@
  * RegExp.cpp
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include "RegExp.h"
@@ -69,8 +69,8 @@ void RegExp::setRegExp(RegExpElement* regExp) {
 	this->regExp = regExp;
 }
 
-set<alphabet::Symbol> RegExp::getAlphabet() const {
-	set<alphabet::Symbol> alphabet;
+std::set<alphabet::Symbol> RegExp::getAlphabet() const {
+	std::set<alphabet::Symbol> alphabet;
 
 	if(regExp)
 		regExp->getAlphabet( alphabet );
@@ -89,7 +89,7 @@ bool RegExp::containsEmptyString() const {
 	return false;
 }
 
-ostream& operator <<(ostream& out, const RegExp& regexp) {
+std::ostream& operator <<(std::ostream& out, const RegExp& regexp) {
 	out << "(RegExp " << *(regexp.regExp) << ")";
 	return out;
 }
diff --git a/alib2/src/regexp/RegExp.h b/alib2/src/regexp/RegExp.h
index 8e25d80d332707d67120e9d0c3df38a093709e15..eac9004daf64ded3fc7316000e79bdf77d3f33df 100644
--- a/alib2/src/regexp/RegExp.h
+++ b/alib2/src/regexp/RegExp.h
@@ -2,11 +2,11 @@
  * RegExp.h
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
-#ifndef REGEXP_H_
-#define REGEXP_H_
+#ifndef REG_EXP_H_
+#define REG_EXP_H_
 
 #include <vector>
 #include <list>
@@ -17,8 +17,6 @@
 
 namespace regexp {
 
-using namespace std;
-
 /**
  * Represents regular expression parsed from the XML. Regular expression is stored
  * as a tree of RegExpElement.
@@ -77,7 +75,7 @@ public:
 	 * @param out output stream to which print the RegExp
 	 * @param regexp RegExp to print
 	 */
-	friend ostream& operator<<(ostream& out, const RegExp& regexp);
+	friend std::ostream& operator<<(std::ostream& out, const RegExp& regexp);
 
 	bool operator<(const RegExp&) const;
 	bool operator<=(const RegExp&) const;
@@ -88,4 +86,5 @@ public:
 };
 
 } /* namespace regexp */
-#endif /* REGEXP_H_ */
+
+#endif /* REG_EXP_H_ */
diff --git a/alib2/src/regexp/RegExpElement.cpp b/alib2/src/regexp/RegExpElement.cpp
index 1f4bee974028994d7855c4a7ecfc8cfc6668646f..dd880a8d0d261f56a8e0e2cfd6daaef1055078f3 100644
--- a/alib2/src/regexp/RegExpElement.cpp
+++ b/alib2/src/regexp/RegExpElement.cpp
@@ -2,7 +2,7 @@
  * RegExpElement.cpp
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include "RegExpElement.h"
@@ -75,7 +75,7 @@ bool RegExpElement::operator==(const RegExpEmpty& other) const {
 	return false;
 }
 
-ostream& operator<<(ostream& out, const RegExpElement& regexp) {
+std::ostream& operator<<(std::ostream& out, const RegExpElement& regexp) {
 	regexp >> out;
 	return out;
 }
diff --git a/alib2/src/regexp/RegExpElement.h b/alib2/src/regexp/RegExpElement.h
index ed283d91254fb4385d17a4167597a395e9c3803d..12db32db1b7f3dc2d06f2f183ec64917a8ef8c44 100644
--- a/alib2/src/regexp/RegExpElement.h
+++ b/alib2/src/regexp/RegExpElement.h
@@ -2,11 +2,11 @@
  * RegExpElement.h
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
-#ifndef REGEXPELEMENT_H_
-#define REGEXPELEMENT_H_
+#ifndef REG_EXP_ELEMENT_H_
+#define REG_EXP_ELEMENT_H_
 
 #include "../std/visitor.hpp"
 #include "../alphabet/Symbol.h"
@@ -14,9 +14,6 @@
 
 namespace regexp {
 
-using namespace std;
-
-
 class Alternation;
 class Concatenation;
 class Iteration;
@@ -64,14 +61,14 @@ public:
 	 * Prints XML representation of the RegExp to the output stream.
 	 * @param out output stream to which print the RegExp
 	 */
-	virtual void operator>>(ostream& out) const = 0;
+	virtual void operator>>(std::ostream& out) const = 0;
 	
 	/**
 	 * Prints XML representation of the RegExp to the output stream.
 	 * @param out output stream to which print the RegExp
 	 * @param regexp RegExp to print
 	 */
-	friend ostream& operator<<(ostream& out, const RegExpElement& regexp);
+	friend std::ostream& operator<<(std::ostream& out, const RegExpElement& regexp);
 
 	/**
 	 * @return true if this subtree of regexp matches empty string (epsilon)
@@ -92,4 +89,5 @@ public:
 };
 
 } /* namespace regexp */
-#endif /* REGEXPELEMENT_H_ */
+
+#endif /* REG_EXP_ELEMENT_H_ */
diff --git a/alib2/src/regexp/RegExpElements.h b/alib2/src/regexp/RegExpElements.h
index b0f3401aec912ee4fc073d0c903f17183d00b5b0..b3d1f02de90fa08a2ecb480b0fae1cad6214ccc1 100644
--- a/alib2/src/regexp/RegExpElements.h
+++ b/alib2/src/regexp/RegExpElements.h
@@ -2,12 +2,11 @@
  * RegExpElements.h
  *
  *  Created on: 14. 3. 2014
- *      Author: tomas
+ *      Author: Tomas Pecka
  */
 
-#ifndef REGEXPELEMENTS_H_
-#define REGEXPELEMENTS_H_
-
+#ifndef REG_EXP_ELEMENTS_H_
+#define REG_EXP_ELEMENTS_H_
 
 #include "Alternation.h"
 #include "Concatenation.h"
@@ -17,5 +16,4 @@
 #include "RegExpEmpty.h"
 #include "RegExpSymbol.h"
 
-
-#endif /* REGEXPELEMENTS_H_ */
+#endif /* REG_EXP_ELEMENTS_H_ */
diff --git a/alib2/src/regexp/RegExpEmpty.cpp b/alib2/src/regexp/RegExpEmpty.cpp
index 83d0c1f2480f407f4a426adba8f68a08e5ffe1c3..9c37ac53e795472b0ecfb4f884126b9e6c8dc9e3 100644
--- a/alib2/src/regexp/RegExpEmpty.cpp
+++ b/alib2/src/regexp/RegExpEmpty.cpp
@@ -2,7 +2,7 @@
  * RegExpEmpty.cpp
  *
  *  Created on: Jan 30, 2014
- *      Author: honza
+ *      Author: Jan Travnicek
  */
 
 #include "RegExpEmpty.h"
@@ -53,7 +53,7 @@ bool RegExpEmpty::operator==(const RegExpEmpty&) const {
 	return true;
 }
 
-void RegExpEmpty::operator>>(ostream& out) const {
+void RegExpEmpty::operator>>(std::ostream& out) const {
 	out << "(RegExpEmpty)";
 }
 
@@ -70,4 +70,3 @@ bool RegExpEmpty::isEmpty() const {
 }
 
 } /* namespace regexp */
-
diff --git a/alib2/src/regexp/RegExpEmpty.h b/alib2/src/regexp/RegExpEmpty.h
index 150ebda6afa88ec1d03bd1a7f1979e52c00783c6..4b4198c1887f6ef3f2c1f88d8ff22cd5b1573078 100644
--- a/alib2/src/regexp/RegExpEmpty.h
+++ b/alib2/src/regexp/RegExpEmpty.h
@@ -2,18 +2,16 @@
  * RegExpEmpty.h
  *
  *  Created on: Jan 30, 2014
- *      Author: honza
+ *      Author: Jan Travnicek
  */
 
-#ifndef REGEXPEMPTY_H_
-#define REGEXPEMPTY_H_
+#ifndef REG_EXP_EMPTY_H_
+#define REG_EXP_EMPTY_H_
 
 #include "RegExpElement.h"
 
 namespace regexp {
 
-using namespace std;
-
 /**
  * Represents empty regular expression in the regular expression.
  */
@@ -40,7 +38,7 @@ public:
 	/**
 	 * @copydoc RegExpElement::operator>>() const
 	 */
-	virtual void operator>>(ostream& out) const;
+	virtual void operator>>(std::ostream& out) const;
 
 	/**
 	 * @copydoc RegExpElement::getAlphabet() const
@@ -59,4 +57,5 @@ public:
 };
 
 } /* namespace regexp */
-#endif /* REGEXPEMPTY_H_ */
+
+#endif /* REG_EXP_EMPTY_H_ */
diff --git a/alib2/src/regexp/RegExpEpsilon.cpp b/alib2/src/regexp/RegExpEpsilon.cpp
index 18940c9d3dab4f9c49bd07093372a1b016d7f8f6..0ed91e5d050f22cb114dab87f095a26718c57e79 100644
--- a/alib2/src/regexp/RegExpEpsilon.cpp
+++ b/alib2/src/regexp/RegExpEpsilon.cpp
@@ -2,7 +2,7 @@
  * RegExpEpsilon.cpp
  *
  *  Created on: Jan 30, 2014
- *      Author: honza
+ *      Author: Jan Travnicek
  */
 
 #include "RegExpEpsilon.h"
@@ -49,7 +49,7 @@ bool RegExpEpsilon::operator==(const RegExpEpsilon&) const {
 	  return true;
 }
 
-void RegExpEpsilon::operator>>(ostream& out) const {
+void RegExpEpsilon::operator>>(std::ostream& out) const {
 	out << "(RegExpEpsilon)";
 }
 
diff --git a/alib2/src/regexp/RegExpEpsilon.h b/alib2/src/regexp/RegExpEpsilon.h
index 57c64dccdbc8e8698427fdac40d756d91a9ae437..24f82b22b157c8cae9c56eadb846cb9d25fdfb64 100644
--- a/alib2/src/regexp/RegExpEpsilon.h
+++ b/alib2/src/regexp/RegExpEpsilon.h
@@ -2,20 +2,17 @@
  * RegExpEpsilon.h
  *
  *  Created on: Jan 30, 2014
- *      Author: honza
+ *      Author: Jan Travnicek
  */
 
-#ifndef REGEXPEPSILON_H_
-#define REGEXPEPSILON_H_
+#ifndef REG_EXP_EPSILON_H_
+#define REG_EXP_EPSILON_H_
 
 #include "RegExpElement.h"
 #include "../alphabet/Epsilon.h"
 
 namespace regexp {
 
-using namespace std;
-using namespace alphabet;
-
 /**
  * Represents epsilon in the regular expression.
  */
@@ -41,7 +38,7 @@ public:
 	/**
 	 * @copydoc RegExpElement::operator>>() const
 	 */
-	virtual void operator>>(ostream& out) const;
+	virtual void operator>>(std::ostream& out) const;
 	
 	/**
 	 * @copydoc RegExpElement::getAlphabet() const
@@ -60,4 +57,5 @@ public:
 };
 
 } /* namespace regexp */
-#endif /* REGEXPEPSILON_H_ */
+
+#endif /* REG_EXP_EPSILON_H_ */
diff --git a/alib2/src/regexp/RegExpFromXMLParser.cpp b/alib2/src/regexp/RegExpFromXMLParser.cpp
index 53c730e5c3d6e72c6a9b27ac542929e7812eb0e0..b9f8af8e7c91093140cba2464b77106c15741aec 100644
--- a/alib2/src/regexp/RegExpFromXMLParser.cpp
+++ b/alib2/src/regexp/RegExpFromXMLParser.cpp
@@ -10,7 +10,7 @@
 
 namespace regexp {
 
-RegExp RegExpFromXMLParser::parse(list<sax::Token>& input) {
+RegExp RegExpFromXMLParser::parse(std::list<sax::Token>& input) {
 	popToken(input, sax::Token::START_ELEMENT, "regexp");
 	RegExp regexp;
 	regexp.setRegExp(parseElement(input));
@@ -19,7 +19,7 @@ RegExp RegExpFromXMLParser::parse(list<sax::Token>& input) {
 	return regexp;
 }
 
-RegExpElement* RegExpFromXMLParser::parseElement(list<sax::Token>& input) {
+RegExpElement* RegExpFromXMLParser::parseElement(std::list<sax::Token>& input) {
 	if (isToken(input, sax::Token::START_ELEMENT, "symbol")) {
 		return parseSymbol(input);
 	} else if (isToken(input, sax::Token::START_ELEMENT, "empty")) {
@@ -37,7 +37,7 @@ RegExpElement* RegExpFromXMLParser::parseElement(list<sax::Token>& input) {
 	}
 }
 
-Alternation* RegExpFromXMLParser::parseAlternation(list<sax::Token>& input) {
+Alternation* RegExpFromXMLParser::parseAlternation(std::list<sax::Token>& input) {
 	popToken(input, sax::Token::START_ELEMENT, "alternation");
 
 	Alternation* alternation = new Alternation;
@@ -47,7 +47,7 @@ Alternation* RegExpFromXMLParser::parseAlternation(list<sax::Token>& input) {
 	return alternation;
 }
 
-Concatenation* RegExpFromXMLParser::parseConcatenation(list<sax::Token>& input) {
+Concatenation* RegExpFromXMLParser::parseConcatenation(std::list<sax::Token>& input) {
 	popToken(input, sax::Token::START_ELEMENT, "concatenation");
 
 	Concatenation* concatenation = new Concatenation();
@@ -58,7 +58,7 @@ Concatenation* RegExpFromXMLParser::parseConcatenation(list<sax::Token>& input)
 
 }
 
-Iteration* RegExpFromXMLParser::parseIteration(list<sax::Token>& input) {
+Iteration* RegExpFromXMLParser::parseIteration(std::list<sax::Token>& input) {
 	popToken(input, sax::Token::START_ELEMENT, "iteration");
 
 	Iteration* iteration = new Iteration();
@@ -68,7 +68,7 @@ Iteration* RegExpFromXMLParser::parseIteration(list<sax::Token>& input) {
 	return iteration;
 }
 
-void RegExpFromXMLParser::parseContent(list<sax::Token>& input, list<RegExpElement*>& elements) {
+void RegExpFromXMLParser::parseContent(std::list<sax::Token>& input, std::list<RegExpElement*>& elements) {
 	while (true) {
 		RegExpElement* element = parseElement(input);
 		if(!element) return;
@@ -76,7 +76,7 @@ void RegExpFromXMLParser::parseContent(list<sax::Token>& input, list<RegExpEleme
 	}
 }
 
-RegExpEpsilon* RegExpFromXMLParser::parseEpsilon(list<sax::Token>& input) {
+RegExpEpsilon* RegExpFromXMLParser::parseEpsilon(std::list<sax::Token>& input) {
 	popToken(input, sax::Token::START_ELEMENT, "epsilon");
 
 	RegExpEpsilon* epsilon = new RegExpEpsilon();
@@ -85,7 +85,7 @@ RegExpEpsilon* RegExpFromXMLParser::parseEpsilon(list<sax::Token>& input) {
 	return epsilon;
 }
 
-RegExpEmpty* RegExpFromXMLParser::parseEmpty(list<sax::Token>& input) {
+RegExpEmpty* RegExpFromXMLParser::parseEmpty(std::list<sax::Token>& input) {
 	popToken(input, sax::Token::START_ELEMENT, "empty");
 
 	RegExpEmpty* empty = new RegExpEmpty();
@@ -94,7 +94,7 @@ RegExpEmpty* RegExpFromXMLParser::parseEmpty(list<sax::Token>& input) {
 	return empty;
 }
 
-RegExpSymbol* RegExpFromXMLParser::parseSymbol(list<sax::Token>& input) {
+RegExpSymbol* RegExpFromXMLParser::parseSymbol(std::list<sax::Token>& input) {
 	popToken(input, sax::Token::START_ELEMENT, "symbol");
 
 	if (input.front().getType() == sax::Token::CHARACTER) {
@@ -107,11 +107,11 @@ RegExpSymbol* RegExpFromXMLParser::parseSymbol(list<sax::Token>& input) {
 	}
 }
 
-bool RegExpFromXMLParser::isToken(list<sax::Token>& input, sax::Token::TokenType type, string data) {
+bool RegExpFromXMLParser::isToken(std::list<sax::Token>& input, sax::Token::TokenType type, std::string data) {
 	return input.front().getType() == type && input.front().getData() == data;
 }
 
-void RegExpFromXMLParser::popToken(list<sax::Token>& input, sax::Token::TokenType type, string data) {
+void RegExpFromXMLParser::popToken(std::list<sax::Token>& input, sax::Token::TokenType type, std::string data) {
 	if (isToken(input, type, data)) {
 		input.pop_front();
 	} else {
diff --git a/alib2/src/regexp/RegExpFromXMLParser.h b/alib2/src/regexp/RegExpFromXMLParser.h
index 20ce98fe8270ea50a8970b8d44620bd0371e7d71..a6cbac18d6b3af9398267bc0404e35deff8e547f 100644
--- a/alib2/src/regexp/RegExpFromXMLParser.h
+++ b/alib2/src/regexp/RegExpFromXMLParser.h
@@ -2,7 +2,7 @@
  * RegExpFromXMLParser.h
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #ifndef REG_EXP_FROM_XML_PARSER_H_
@@ -18,17 +18,17 @@ namespace regexp {
  * Parser used to get RegExp from XML parsed into list of tokens.
  */
 class RegExpFromXMLParser {
-	void parseContent(list<sax::Token>& input, list<RegExpElement*>& elements);
-	RegExpElement* parseElement(list<sax::Token>& input);
+	void parseContent(std::list<sax::Token>& input, std::list<RegExpElement*>& elements);
+	RegExpElement* parseElement(std::list<sax::Token>& input);
 
-	RegExpEpsilon* parseEpsilon(list<sax::Token>& input);
-	RegExpEmpty* parseEmpty(list<sax::Token>& input);
-	RegExpSymbol* parseSymbol(list<sax::Token> &input);
-	Iteration* parseIteration(list<sax::Token> &input);
-	Alternation* parseAlternation(list<sax::Token> &input);
-	Concatenation* parseConcatenation(list<sax::Token> &input);
-	bool isToken(list<sax::Token> &input, sax::Token::TokenType type, string data);
-	void popToken(list<sax::Token> &input, sax::Token::TokenType type, string data);
+	RegExpEpsilon* parseEpsilon(std::list<sax::Token>& input);
+	RegExpEmpty* parseEmpty(std::list<sax::Token>& input);
+	RegExpSymbol* parseSymbol(std::list<sax::Token> &input);
+	Iteration* parseIteration(std::list<sax::Token> &input);
+	Alternation* parseAlternation(std::list<sax::Token> &input);
+	Concatenation* parseConcatenation(std::list<sax::Token> &input);
+	bool isToken(std::list<sax::Token> &input, sax::Token::TokenType type, std::string data);
+	void popToken(std::list<sax::Token> &input, sax::Token::TokenType type, std::string data);
 
 public:
 	/**
@@ -37,7 +37,7 @@ public:
 	 * @return RegExp
 	 * @throws ParserException when an error occurs
 	 */
-	RegExp parse(list<sax::Token>& input);
+	RegExp parse(std::list<sax::Token>& input);
 };
 
 } /* namespace regexp */
diff --git a/alib2/src/regexp/RegExpSymbol.cpp b/alib2/src/regexp/RegExpSymbol.cpp
index 9f091a5b705b4c1ff275d2bebdefa1040f4f29df..bcc30faf6fef848b71e346ee13991d8d92fd9fba 100644
--- a/alib2/src/regexp/RegExpSymbol.cpp
+++ b/alib2/src/regexp/RegExpSymbol.cpp
@@ -2,7 +2,7 @@
  * RegExpSymbol.cpp
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include "RegExpSymbol.h"
@@ -13,7 +13,7 @@ RegExpSymbol::RegExpSymbol() :
 		symbol("") {
 }
 
-RegExpSymbol::RegExpSymbol(const string& symbol) :
+RegExpSymbol::RegExpSymbol(const std::string& symbol) :
 		symbol(symbol) {
 }
 
@@ -54,7 +54,7 @@ bool RegExpSymbol::operator==(const RegExpSymbol& other) const {
 	return this->symbol == other.symbol;
 }
 
-void RegExpSymbol::operator>>(ostream& out) const {
+void RegExpSymbol::operator>>(std::ostream& out) const {
 	out << "(RegExpSymbol " << symbol << ")";
 }
 
@@ -67,10 +67,10 @@ bool RegExpSymbol::isEmpty() const {
 }
 
 void RegExpSymbol::getAlphabet( std::set<alphabet::Symbol> & alphabet ) const {
-	alphabet.insert( Symbol( this->getSymbol( ) ) );
+	alphabet.insert( alphabet::Symbol( this->getSymbol( ) ) );
 }
 
-const string& RegExpSymbol::getSymbol() const {
+const std::string& RegExpSymbol::getSymbol() const {
 	return this->symbol;
 }
 
diff --git a/alib2/src/regexp/RegExpSymbol.h b/alib2/src/regexp/RegExpSymbol.h
index 5325b49a1367a54e5e9f20047b6a8acbfb20838e..8296bce29f595b67341ad9301e4c8de37424c80c 100644
--- a/alib2/src/regexp/RegExpSymbol.h
+++ b/alib2/src/regexp/RegExpSymbol.h
@@ -2,11 +2,11 @@
  * RegExpSymbol.h
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
-#ifndef REGEXPSYMBOL_H_
-#define REGEXPSYMBOL_H_
+#ifndef REG_EXP_SYMBOL_H_
+#define REG_EXP_SYMBOL_H_
 
 #include <string>
 #include "RegExpElement.h"
@@ -14,17 +14,14 @@
 
 namespace regexp {
 
-using namespace std;
-using namespace alphabet;
-
 /**
  * Represents symbol in the regular expression. Contains name of the symbol.
  */
 class RegExpSymbol : public RegExpElement, public std::element<RegExpSymbol, RegExpElement::visitor_type> {
-	string symbol;
+	std::string symbol;
 public:
 	RegExpSymbol();
-	RegExpSymbol(const string& symbol);
+	RegExpSymbol(const std::string& symbol);
 
 	/**
 	 * @copydoc RegExpElement::clone() const
@@ -44,7 +41,7 @@ public:
 	/**
 	 * @copydoc RegExpElement::operator>>() const
 	 */
-	virtual void operator>>(ostream& out) const;
+	virtual void operator>>(std::ostream& out) const;
 
 	/**
 	 * @copydoc RegExpElement::getAlphabet() const
@@ -56,7 +53,10 @@ public:
 	 */
 	virtual bool containsEmptyString() const;
 
-	const string& getSymbol() const;
+	/**
+	 * Returns the string representation of RegExp Symbol.
+	 */
+	const std::string& getSymbol() const;
 
 	/**
 	 * @copydoc RegExpElement::isEmpty() const
@@ -65,4 +65,5 @@ public:
 };
 
 } /* namespace regexp */
-#endif /* REGEXPSYMBOL_H_ */
+
+#endif /* REG_EXP_SYMBOL_H_ */
diff --git a/alib2/src/regexp/RegExpToXMLPrinter.cpp b/alib2/src/regexp/RegExpToXMLPrinter.cpp
index 39e33625a05dede34a33fef7b2abb545fabec820..5d6d2e797e22e984939131b850350a206bba891d 100644
--- a/alib2/src/regexp/RegExpToXMLPrinter.cpp
+++ b/alib2/src/regexp/RegExpToXMLPrinter.cpp
@@ -2,23 +2,21 @@
  * RegExpToXMLPrinter.cpp
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include "RegExpToXMLPrinter.h"
 
 namespace regexp {
 
-const string RegExpToXMLPrinter::c_Indentation = "\t";
-
-RegExpToXMLPrinter::RegExpToXMLPrinter(ostream& out) : m_Out(out) {
+RegExpToXMLPrinter::RegExpToXMLPrinter(std::ostream& out) : m_Out(out) {
 
 }
 
 void RegExpToXMLPrinter::Visit(const RegExp::element_type& regexp) {
-	m_Out << "<regexp>" << endl;
+	m_Out << "<regexp>" << std::endl;
 	regexp.Accept(*this);
-	m_Out << "</regexp>" << endl;
+	m_Out << "</regexp>" << std::endl;
 }
 
 void RegExpToXMLPrinter::Visit(const RegExpElement::element_type& element) {
@@ -26,51 +24,51 @@ void RegExpToXMLPrinter::Visit(const RegExpElement::element_type& element) {
 }
 
 void RegExpToXMLPrinter::Visit(const Alternation& alternation) {
-	m_Out << "<alternation>" << endl;
-	for (auto element : alternation.getElements()) {
+	m_Out << "<alternation>" << std::endl;
+	for (const auto& element : alternation.getElements()) {
 		const RegExpElement::element_type& object = static_cast<const RegExpElement::element_type&>(*element);
 		object.Accept(*this);
 	}
-	m_Out << "</alternation>" << endl;
+	m_Out << "</alternation>" << std::endl;
 }
 
 void RegExpToXMLPrinter::Visit(const Concatenation& concatenation) {
-	m_Out <<"<concatenation>" << endl;
+	m_Out <<"<concatenation>" << std::endl;
 	for (auto element : concatenation.getElements()) {
 		const RegExpElement::element_type& object = static_cast<const RegExpElement::element_type&>(*element);
 		object.Accept(*this);
 	}
-	m_Out <<"</concatenation>" << endl;
+	m_Out <<"</concatenation>" << std::endl;
 
 }
 
 void RegExpToXMLPrinter::Visit(const Iteration& iteration) {
-	m_Out << "<iteration>" << endl;
+	m_Out << "<iteration>" << std::endl;
 	const RegExpElement::element_type& object = static_cast<const RegExpElement::element_type&>(*iteration.getElement());
 	object.Accept(*this);
-	m_Out << "</iteration>" << endl;
+	m_Out << "</iteration>" << std::endl;
 }
 
 void RegExpToXMLPrinter::Visit(const RegExpSymbol& symbol) {
 	m_Out << "<symbol>";
 	m_Out << symbol.getSymbol();
-	m_Out << "</symbol>" << endl;
+	m_Out << "</symbol>" << std::endl;
 }
 
 void RegExpToXMLPrinter::Visit(const RegExpEpsilon& epsilon) {
 	m_Out << "<epsilon>";
-	m_Out << "</epsilon>" << endl;
+	m_Out << "</epsilon>" << std::endl;
 }
 
 void RegExpToXMLPrinter::Visit(const RegExpEmpty& empty) {
 	m_Out << "<empty>";
-	m_Out << "</empty>" << endl;
+	m_Out << "</empty>" << std::endl;
 }
 
 void RegExpToXMLPrinter::Visit(const RegExp& regexp) {
-	m_Out << "<regexp>" << endl;
+	m_Out << "<regexp>" << std::endl;
 	regexp.getRegExp()->Accept(*this);
-	m_Out << "</regexp>" << endl;
+	m_Out << "</regexp>" << std::endl;
 }
 
 } /* namespace regexp */
diff --git a/alib2/src/regexp/RegExpToXMLPrinter.h b/alib2/src/regexp/RegExpToXMLPrinter.h
index 880f455fc85fab93fb49d447c9f40f6e461d299c..3f0fdcc019801509b7368e7c99a0730dd5dc0378 100644
--- a/alib2/src/regexp/RegExpToXMLPrinter.h
+++ b/alib2/src/regexp/RegExpToXMLPrinter.h
@@ -2,7 +2,7 @@
  * RegExpToXMLPrinter.h
  *
  *  Created on: Nov 23, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #ifndef REGEXP_TO_XML_PRINTER_H_
@@ -15,18 +15,15 @@
 
 namespace regexp {
 
-using namespace std;
-
 /**
  * This class contains methods to print XML representation of regular expression to the output stream.
  */
 class RegExpToXMLPrinter : public RegExp::visitor_type, public RegExpElement::visitor_type {
-	static const string c_Indentation;
 
-	ostream& m_Out;
+	std::ostream& m_Out;
 
 public:
-	RegExpToXMLPrinter(ostream& out);
+	RegExpToXMLPrinter(std::ostream& out);
 
 	void Visit(const Alternation& alternation);
 	void Visit(const Concatenation& concatenation);
@@ -48,4 +45,5 @@ public:
 };
 
 } /* namespace regexp */
+
 #endif /* REGEXP_TO_XML_PRINTER_H_ */
diff --git a/alib2/src/sax/ParserException.cpp b/alib2/src/sax/ParserException.cpp
index c40a1b2d59647d5507edd99198a3eaec02cd428c..25c6cf790e83731928a875f319f8658f0e24cc6d 100644
--- a/alib2/src/sax/ParserException.cpp
+++ b/alib2/src/sax/ParserException.cpp
@@ -2,7 +2,7 @@
  * ParserException.cpp
  *
  *  Created on: Apr 16, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include "ParserException.h"
@@ -14,6 +14,7 @@ ParserException::ParserException(const Token& expected, const Token& read) :
 
 	cause = "Parser Exception: Expected: " + expected.getData() + " Read: " + read.getData();
 }
+
 ParserException::~ParserException() throw () {
 
 }
diff --git a/alib2/src/sax/ParserException.h b/alib2/src/sax/ParserException.h
index c2a8881ad1b9b6c5e29b0d93623c865e494bfa99..a7af6523ddf733e22fc3323992efec356a797b41 100644
--- a/alib2/src/sax/ParserException.h
+++ b/alib2/src/sax/ParserException.h
@@ -2,15 +2,15 @@
  * ParserException.h
  *
  *  Created on: Apr 16, 2013
- *      Author: martin
+ *      Author: Martin Zak
  */
 
-#ifndef PARSEREXCEPTION_H_
-#define PARSEREXCEPTION_H_
+#ifndef PARSER_EXCEPTION_H_
+#define PARSER_EXCEPTION_H_
 
 #include "../AlibException.h"
 #include "Token.h"
-#include <string.h>
+
 namespace sax {
 
 /**
@@ -26,4 +26,5 @@ public:
 };
 
 } /* namespace sax */
-#endif /* PARSEREXCEPTION_H_ */
+
+#endif /* PARSER_EXCEPTION_H_ */
diff --git a/alib2/src/sax/SaxInterface.cpp b/alib2/src/sax/SaxInterface.cpp
index 6370398af127c5ebb731b33412a1b32e18feede4..cdc67adaa27dbc4dd919b2b09ab048ea27e5a851 100644
--- a/alib2/src/sax/SaxInterface.cpp
+++ b/alib2/src/sax/SaxInterface.cpp
@@ -2,7 +2,7 @@
  * SaxInterface.cpp
  *
  *  Created on: 8.8.2012
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include "SaxInterface.h"
@@ -14,9 +14,6 @@
 
 namespace sax {
 
-using namespace std;
-using namespace alib;
-
 void SaxInterface::initSAXHandler(xmlSAXHandler& handler) {
 	memset(&handler, 0, sizeof(handler));
 	handler.initialized = XML_SAX2_MAGIC;
@@ -26,7 +23,7 @@ void SaxInterface::initSAXHandler(xmlSAXHandler& handler) {
 	handler.endElement = &sax::SaxInterface::endElement;
 }
 
-void SaxInterface::parseMemory(string xmlIn, list<Token>& out) {
+void SaxInterface::parseMemory(const std::string& xmlIn, std::list<Token>& out) {
 	xmlSAXHandler handler;
 	initSAXHandler(handler);
 
@@ -34,11 +31,11 @@ void SaxInterface::parseMemory(string xmlIn, list<Token>& out) {
 	xmlCleanupParser();
 
 	if (result != 0) {
-		throw AlibException("Cannot parse the XML string.");
+		throw alib::AlibException("Cannot parse the XML string.");
 	}
 }
 
-void SaxInterface::parseFile(string filename, list<Token>& out) {
+void SaxInterface::parseFile(const std::string& filename, std::list<Token>& out) {
 	xmlSAXHandler handler;
 	initSAXHandler(handler);
 
@@ -46,14 +43,14 @@ void SaxInterface::parseFile(string filename, list<Token>& out) {
 	xmlCleanupParser();
 
 	if (result != 0) {
-		throw AlibException("Cannot parse the XML file " + filename);
+		throw alib::AlibException("Cannot parse the XML file " + filename);
 	}
 
 }
 
 void SaxInterface::characters(void * userData, const xmlChar * ch, int len) {
-	list<Token> &out = *((list<Token>*) userData);
-	string tmp((char*) ch, len);
+	std::list<Token> &out = *((std::list<Token>*) userData);
+	std::string tmp((char*) ch, len);
 
 	for (unsigned int i = 0; i < tmp.length(); i++) {
 		if (!isspace(tmp[i])) {
@@ -64,15 +61,13 @@ void SaxInterface::characters(void * userData, const xmlChar * ch, int len) {
 	}
 }
 
-void SaxInterface::startElement(void* userData, const xmlChar* name, const xmlChar** attrs) {
-	(void)attrs;
-
-	list<Token> &out = *((list<Token>*) userData);
+void SaxInterface::startElement(void* userData, const xmlChar* name, const xmlChar** /*attrs*/) {
+	std::list<Token> &out = *((std::list<Token>*) userData);
 	out.push_back(Token((char*) name, Token::START_ELEMENT));
 }
 
 void SaxInterface::endElement(void * userData, const xmlChar * name) {
-	list<Token> &out = *((list<Token>*) userData);
+	std::list<Token> &out = *((std::list<Token>*) userData);
 	out.push_back(Token((char*) name, Token::END_ELEMENT));
 }
 } /* namespace sax */
diff --git a/alib2/src/sax/SaxInterface.h b/alib2/src/sax/SaxInterface.h
index d181b1e1dcfb0c4dbcad8a797e34eddf9084b294..37998926c87f69604b4caa8ad0c3785b2571edd7 100644
--- a/alib2/src/sax/SaxInterface.h
+++ b/alib2/src/sax/SaxInterface.h
@@ -2,11 +2,11 @@
  * SaxInterface.h
  *
  *  Created on: 8.8.2012
- *      Author: martin
+ *      Author: Martin Zak
  */
 
-#ifndef SAXINTERFACE_H_
-#define SAXINTERFACE_H_
+#ifndef SAX_INTERFACE_H_
+#define SAX_INTERFACE_H_
 
 #include <libxml/parser.h>
 #include <list>
@@ -14,8 +14,6 @@
 
 namespace sax {
 
-using namespace std;
-
 /**
  * This class performs parsing of file or string containing XML. Contains callback
  * methods for libxml SAX parser.
@@ -58,7 +56,7 @@ public:
 	 * @param out list of tokens that are returned
 	 * @throws AlibException when an error occurs (e.g. XML is not valid)
 	 */
-	static void parseMemory(string xmlIn, list<Token>& out);
+	static void parseMemory(const std::string& xmlIn, std::list<Token>& out);
 
 	/**
 	 * Parses the file containing XML.
@@ -66,8 +64,9 @@ public:
 	 * @param out list of tokens that are returned
 	 * @throws AlibException when an error occurs (e.g. file doesn't exist, XML is not valid)
 	 */
-	static void parseFile(string filename, list<Token>& out);
+	static void parseFile(const std::string& filename, std::list<Token>& out);
 };
 
 } /* namespace sax */
-#endif /* SAXINTERFACE_H_ */
+
+#endif /* SAX_INTERFACE_H_ */
diff --git a/alib2/src/sax/Token.cpp b/alib2/src/sax/Token.cpp
index a0880c8a3e348e3c981c95e0194e2b690a436980..5e7049694ae08f449fec85652b3218b6a76f6386 100644
--- a/alib2/src/sax/Token.cpp
+++ b/alib2/src/sax/Token.cpp
@@ -2,14 +2,14 @@
  * ParseToken.cpp
  *
  *  Created on: 9.8.2012
- *      Author: martin
+ *      Author: Martin Zak
  */
 
 #include "Token.h"
 
 namespace sax {
 
-Token::Token(const std::string data, const Token::TokenType type) :
+Token::Token(const std::string& data, const Token::TokenType type) :
 		data(data), type(type) {
 
 }
@@ -18,7 +18,7 @@ Token::~Token() {
 
 }
 
-std::string Token::getData() const {
+const std::string& Token::getData() const {
 	return data;
 }
 
diff --git a/alib2/src/sax/Token.h b/alib2/src/sax/Token.h
index 3f544dabb47ad32c140d53594b19bac4de66e334..6f3f0c8765f7302666cc76df394347d1a6124b10 100644
--- a/alib2/src/sax/Token.h
+++ b/alib2/src/sax/Token.h
@@ -2,18 +2,16 @@
  * ParseToken.h
  *
  *  Created on: 9.8.2012
- *      Author: martin
+ *      Author: Martin Zak
  */
 
-#ifndef PARSETOKEN_H_
-#define PARSETOKEN_H_
+#ifndef TOKEN_H_
+#define TOKEN_H_
 
 #include <string>
 
 namespace sax {
 
-using namespace std;
-
 /**
  * Represents part of parsed XML. Can be start of tag, end of tag,
  * tag attribute or array of characters.
@@ -26,17 +24,17 @@ public:
 	};
 
 private:
-	string data;
+	std::string data;
 	TokenType type;
 
 public:
-	Token(const string, const TokenType);
+	Token(const std::string&, const TokenType);
 	virtual ~Token();
 
 	/**
 	 * @return name of the tag or characters read
 	 */
-	string getData() const;
+	const std::string& getData() const;
 
 	/**
 	 * @return type of the token - star of the tag, end of the tag, attribute
@@ -47,4 +45,4 @@ public:
 
 } /* namespace sax */
 
-#endif /* PARSETOKEN_H_ */
+#endif /* TOKEN_H_ */
diff --git a/alib2/src/std/type_traits.hpp b/alib2/src/std/type_traits.hpp
index 1ee68e2268877a8cfcc1fe23624cfc840211dca7..d357fcdbe6443c194a4a61a25d0c6575e54347d5 100644
--- a/alib2/src/std/type_traits.hpp
+++ b/alib2/src/std/type_traits.hpp
@@ -1,9 +1,15 @@
+/**
+ *  Created on: Feb 28, 2014
+ *      Author: Jan Travnicek
+ */
+
 #ifndef TYPE_TRAITS_HPP_
 #define TYPE_TRAITS_HPP_
 
 #include <type_traits>
 
 namespace std {
+
 	template <typename T>
 	struct is_base_of<T, T> {
 		static const bool value = true;
@@ -23,6 +29,7 @@ namespace std {
 	{
 		static const bool value = is_base_of<T, F>::value || is_base_of_any<T, Ts...>::value;
 	};
-}
 
-#endif
+} /* namespace std */
+
+#endif // TYPE_TRAITS_HPP_
diff --git a/alib2/src/std/variant.hpp b/alib2/src/std/variant.hpp
index 3771d4c477ba9c520d15381f71e35b0c460812c6..396e628e6f98c2b260e18f7b151c9b2aac15b2fd 100644
--- a/alib2/src/std/variant.hpp
+++ b/alib2/src/std/variant.hpp
@@ -1,8 +1,8 @@
 /**
  *  https://gist.github.com/tibordp/6909880
  *  Created on: Feb 28, 2014
- * 	Author: Tibor Djurica Potpara
- * 	Modified: Jan Travnicek
+ *      Author: Tibor Djurica Potpara
+ *      Modified: Jan Travnicek
  */
 
 #ifndef VATIANT_HPP_
@@ -14,6 +14,8 @@
 #include "type_traits.hpp"
 #include <string>
 
+namespace std {
+
 template <size_t arg1, size_t ... others>
 struct static_max;
 
@@ -192,4 +194,6 @@ public:
 	}
 };
 
+} /* namespace std */
+
 #endif
diff --git a/alib2/src/std/visitor.hpp b/alib2/src/std/visitor.hpp
index 077357faf2de0798e3141517a97327e1a538a774..51bd5b1e3cd2ec1c56cdbcf12dd847d529a2bdca 100644
--- a/alib2/src/std/visitor.hpp
+++ b/alib2/src/std/visitor.hpp
@@ -3,6 +3,7 @@
  *
  *  Created on: Apr 05, 2014
  *      Author: Andrew Durward
+ *      Modified: Jan Travnicek
  */
 
 #ifndef VISITOR_H_