refact Factory