class GroupServiceImpl extends SalesManagerEntityServiceImpl<Integer, Group>
    implements GroupService {

  GroupRepository groupRepository;


  @Inject
  public GroupServiceImpl(GroupRepository groupRepository) {
    super(groupRepository);
    this.groupRepository = groupRepository;

  }


  @Override
  public List<Group> listGroup(GroupType groupType) throws ServiceException {<FILL_FUNCTION_BODY>}

  public List<Group> listGroupByIds(Set<Integer> ids) throws ServiceException {

      try {
        return ids.isEmpty() ? new ArrayList<Group>() : groupRepository.findByIds(ids);
      } catch (Exception e) {
        throw new ServiceException(e);
      }

  }


  @Override
  public Group findByName(String groupName) throws ServiceException {
    return groupRepository.findByGroupName(groupName);
  }


  @Override
  public List<Group> listGroupByNames(List<String> names) throws ServiceException {
    return groupRepository.findByNames(names);
  }


}

    try {
      return groupRepository.findByType(groupType);
    } catch (Exception e) {
      throw new ServiceException(e);
    }
  
<methods>public void <init>(JpaRepository<com.salesmanager.core.model.user.Group,java.lang.Integer>) ,public java.lang.Long count() ,public void create(com.salesmanager.core.model.user.Group) throws com.salesmanager.core.business.exception.ServiceException,public void delete(com.salesmanager.core.model.user.Group) throws com.salesmanager.core.business.exception.ServiceException,public void flush() ,public com.salesmanager.core.model.user.Group getById(java.lang.Integer) ,public List<com.salesmanager.core.model.user.Group> list() ,public void save(com.salesmanager.core.model.user.Group) throws com.salesmanager.core.business.exception.ServiceException,public void saveAll(Iterable<com.salesmanager.core.model.user.Group>) throws com.salesmanager.core.business.exception.ServiceException,public void update(com.salesmanager.core.model.user.Group) throws com.salesmanager.core.business.exception.ServiceException<variables>private Class<com.salesmanager.core.model.user.Group> objectClass,private JpaRepository<com.salesmanager.core.model.user.Group,java.lang.Integer> repository