added bridge pattern using templage