abstract factory and factory