switch to constructor