added parameterization to addinstance