<commit_before>﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MXitConnectionModule.MxitModel
{
    public class ContactList
    {
        public Contact[] Contacts;

        public void clearSelected()
        {
            foreach (Contact friend in Contacts)
            {
                friend.isSelected = false;
            }
        }

        public void toggleSelected(String friendMxitUserID)
        {
            Contact friend = Array.Find(Contacts,
	                            element => element.UserId == friendMxitUserID);

            if (friend != null)
            {
                friend.isSelected = !friend.isSelected;
            }
        }
    }

    
}<commit_msg>SendFromUserAToUserB and getContactList working<commit_after>﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MXitConnectionModule.MxitModel
{
    public class ContactList
    {
        public Contact[] Contacts;
        public int selectedFriendCount { get; private set; }

        public ContactList()
        {
            selectedFriendCount = 0;
        }

        public void clearSelected()
        {
            foreach (Contact friend in Contacts)
            {
                friend.isSelected = false;
            }
        }

        public void toggleSelected(String friendMxitUserID)
        {
            Contact friend = Array.Find(Contacts,
	                            element => element.UserId == friendMxitUserID);

            if (friend != null)
            {
                if (friend.isSelected)
                {
                    friend.isSelected = false;
                    lock (this) selectedFriendCount++;
                }
                else
                {
                    friend.isSelected = true;
                    lock (this) selectedFriendCount--;
                }
                
            }
        }


    }

    
}
{'fraction_non_alphanumeric': 0.07222787385554426, 'fraction_numerical': 0.000508646998982706, 'mean_word_length': 1.330568720379147, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2130865', 'n_tokens_mistral': 488, 'n_tokens_neox': 461, 'n_words': 106}