switched to protoype pattern