using Demo.Data.Repository; using Demo.domain.Models; namespace Demo.Domain.UseCase { public class GroupUseCase { private readonly GroupRepositoryImpl _repositoryGroupImpl; public GroupUseCase(GroupRepositoryImpl repositoryGroupImpl) { _repositoryGroupImpl = repositoryGroupImpl; } public List GetAllGroups() { return _repositoryGroupImpl.GetAllGroups(); } public void AddGroup(int id, string name) { _repositoryGroupImpl.AddGroup(id, name); } public void UpdateGroup(int id, string newName) { _repositoryGroupImpl.UpdateGroup(id, newName); } } }