Change factory method name to newInstance and newType.