Partial pull on Issue48

There are some big modifications to the structure on 0d7412f34f571961e1dac85598fa3758c6c91505 , so I`m pulling this to master even if it the work on #48 is not finished.