public AccountController() { _healthyEntities = new HealthyEntities(); _passwordHasher = new PasswordHasher <User>(); _accountRepository = new AccountRepository(_healthyEntities); _accountService = new AccountService(_passwordHasher, _accountRepository); _userRelationshipRepository = new UserRelationshipRepository(_healthyEntities); _userRealtionshipService = new UserRelationshipService(_userRelationshipRepository); }
// ninject will provide us with repo instance public UserRelationshipsController(IUserRelationshipRepository userRelationshipRepository) { _userRelationshipRepository = userRelationshipRepository; }
// ninject will provide us with repo instance public UsersController(IUserRepository userRepository, IPostRepository postRepository, IUserRelationshipRepository userRelationshipRepository) { _userRepository = userRepository; _postRepository = postRepository; _userRelationshipRepository = userRelationshipRepository; }
public UserRelationshipService(IUserRelationshipRepository userRelationshipRepository) { _userRelationshipRepository = userRelationshipRepository; }
public UserRelationshipController() { _healthyEntities = new HealthyEntities(); _userRelationshipRepository = new UserRelationshipRepository(_healthyEntities); }