예제 #1
0
        /*************************************************************************************************/
        public void UpdateUsersCSVFile(string filename, List <User> encryptedUsers)
        {
            if (encryptedUsers == null)
            {
                throw new ArgumentNullException(nameof(encryptedUsers));
            }

            _writer.Initialize(filename);

            foreach (var user in encryptedUsers)
            {
                _writer.WriteLine(user.GetUserString());
            }

            _writer.Close();
        }
예제 #2
0
        /*************************************************************************************************/
        public void UpdatePasswordCSVFile(string filename, List <DatabasePassword> encryptedPasswords)
        {
            if (encryptedPasswords == null)
            {
                throw new ArgumentNullException(nameof(encryptedPasswords));
            }

            _writer.Initialize(filename);

            foreach (var password in encryptedPasswords)
            {
                _writer.WriteLine(password.GetPasswordString());
            }

            _writer.Close();
        }