[#364] split files for better code readability (entity object is now isolated from the rest)