Dynamic constructor call could be safely replaced with a factory method call.