Factory pattern desian