added FactoryProducer class that generate factories