moved methods to its own file