Changed to template class