Example #1
0
        private void InitRecruitCardGroupFactory()
        {
            var recruitCardGroupByAdd = new RecruitCardGroup(_personalPhotoDirectoryPath);

            _recruitCardGroupFactory = new RecruitCardGroupFactory(_personalPhotoDirectoryPath, recruitCardGroupByAdd,
                                                                   _recruitImporter, _recruitInfoRepository);
        }
        public RecruitViewModel(IRecruitCardGroupFactory recruitCardGroupFactory,
                                IParameterizedCommandAsync <SaveRecruitCommandParameters> saveParameterizedRecruitCommand,
                                RecruitOperationEventArgs recruitOperationEventArgs,
                                Action <string> notValidCallback)
        {
            if (recruitCardGroupFactory == null)
            {
                throw new ArgumentNullException(nameof(recruitCardGroupFactory));
            }

            if (saveParameterizedRecruitCommand == null)
            {
                throw new ArgumentNullException(nameof(saveParameterizedRecruitCommand));
            }

            if (recruitOperationEventArgs == null)
            {
                throw new ArgumentNullException(nameof(recruitOperationEventArgs));
            }

            if (notValidCallback == null)
            {
                throw new ArgumentNullException(nameof(notValidCallback));
            }

            _saveParameterizedRecruitCommand = saveParameterizedRecruitCommand;
            _recruitOperationEventArgs       = recruitOperationEventArgs;
            _notValidCallback = notValidCallback;

            RecruitCardGroup = recruitCardGroupFactory.Create(_recruitOperationEventArgs);
        }