getAll changed to generic type