public KweetManagementController(IUserService userService, IKweetService kweetService, IMapper mapper)
        {
            _userService  = userService;
            _kweetService = kweetService;

            _mapper = mapper;
        }
        public async Task Init()
        {
            _unitOfWork            = new UnitOfWork(_context);
            _hashTagService        = new HashTagService(new HashTagRepository(_context, _unitOfWork));
            _kweetService          = new KweetService(new KweetRepository(_context, _unitOfWork));
            _hashTagInKweetService = new Service <HashTagInKweet>(new Repository <HashTagInKweet>(_context, _unitOfWork));

            await Seed();
        }
Example #3
0
        public async Task Init()
        {
            _unitOfWork   = new UnitOfWork(_context);
            _kweetService = new KweetService(new KweetRepository(_context, _unitOfWork));
            _userService  = new UserService(new UserRepository(_context, _unitOfWork));
            _likeService  = new LikeService(new Repository <Like>(_context, _unitOfWork));

            await Seed();
        }
Example #4
0
 public KweetsController(IUnitOfWorkAsync unitOfWork, IKweetService kweetService, ILikeService likeService, IHashTagService hashTagService, IHashTagInKweetService hashTagInKweetService, IMentionService mentionService, IMapper mapper)
 {
     _unitOfWork            = unitOfWork;
     _kweetService          = kweetService;
     _likeService           = likeService;
     _hashTagService        = hashTagService;
     _hashTagInKweetService = hashTagInKweetService;
     _mentionService        = mentionService;
     _mapper = mapper;
 }
Example #5
0
 public KweetController(IKweetService kweetService)
 {
     _kweetService = kweetService;
 }