removed code repetitions, added private constructors in static classes