add Factory Pattern