コード例 #1
0
        public void SetLastname(string lastname)
        {
            if (string.IsNullOrEmpty(lastname))
            {
                throw new DatingAppException(ErrorCode.Empty(nameof(lastname)));
            }

            this.Lastname = lastname;
        }
コード例 #2
0
        public void SetFristname(string firstname)
        {
            if (string.IsNullOrEmpty(firstname))
            {
                throw new DatingAppException(ErrorCode.Empty(nameof(firstname)));
            }

            this.Firstname = firstname;
        }
コード例 #3
0
        public void SetUsername(string username)
        {
            if (string.IsNullOrEmpty(username))
            {
                throw new DatingAppException(ErrorCode.Empty(nameof(username)));
            }

            this.Username = username;
        }
コード例 #4
0
        public void SetEmail(string email)
        {
            if (string.IsNullOrEmpty(email))
            {
                throw new DatingAppException(ErrorCode.Empty(nameof(email)));
            }

            this.Email = email;
        }
コード例 #5
0
        public void SetPassword(string hash, string salt)
        {
            if (string.IsNullOrEmpty(hash) || string.IsNullOrEmpty(salt))
            {
                throw new DatingAppException(ErrorCode.Empty("password"));
            }

            this.Hash = hash;
            this.Salt = salt;
        }