public object BindModel(ModelBindingContext bindingContext, ControllerContext controllerContext, ISkillProfileRepository skillProfileRepository)
        {
            // Some modelbinders can update properties on existing model instances. This
            // one doesn't need to - it's only used to supply action method parameters.
            if (bindingContext.Model != null)
                throw new InvalidOperationException("Cannot update instances");

            // Return the skillProfile from Session[] (creating it first if necessary)
            SkillProfile skillProfile = (SkillProfile)controllerContext.HttpContext.Session[SkillProfileSessionKey];
            if (skillProfile == null) {
                skillProfile = skillProfileRepository.Load();
                controllerContext.HttpContext.Session[SkillProfileSessionKey] = skillProfile;
            }
            return skillProfile;
        }
 public EditProfileController(ISkillsRepository skillsRepository, ISkillProfileRepository skillProfileRepository, IExperienceTypeRepository experienceTypeRepository)
 {
     _skillsRepository = skillsRepository;
     _experienceTypeRepository = experienceTypeRepository;
     _skillProfileRepository = skillProfileRepository;
 }
 public MoveSkillsController(ISkillProfileRepository skillProfileRepository)
 {
     _skillProfileRepository = skillProfileRepository;
 }