added parameters to constructor