Final version.
Add read from xml.
Remove unnecessary classes and libs.