Added support for generics