Separated files into more object-oriented manner