<commit_before>/*
 * Copyright (c) 2017. Team CMPUT301F17T02, CMPUT301, University of Alberta - All Rights Reserved. You may use, distribute, or modify this code under terms and conditions of the Code of Students Behaviour at University of Alberta.
 */

package com.example.baard;

import java.util.ArrayList;

/**
 * Created by biancaangotti on 2017-10-20.
 */

public class HabitList {

    private ArrayList<Habit> habits = new ArrayList<Habit>();

    public HabitList(){

    }

    public Habit getHabit(int index){
        return habits.get(index);
    }
    
    public Habit getHabit(Habit habit){
        int find = habits.indexOf(habit);
        return habits.get(find);
    }

    public boolean hasHabit(Habit habit){
        return habits.contains(habit);
    }

    public void add(Habit habit) {<commit_msg>getting<commit_after>/*
 * Copyright (c) 2017. Team CMPUT301F17T02, CMPUT301, University of Alberta - All Rights Reserved. You may use, distribute, or modify this code under terms and conditions of the Code of Students Behaviour at University of Alberta.
 */

package com.example.baard;

import java.util.ArrayList;

/**
 * Created by biancaangotti on 2017-10-20.
 */

public class HabitList {

    private ArrayList<Habit> habits = new ArrayList<Habit>();

    public HabitList(){

    }

    public Habit getHabit(int index){
        return habits.get(index);
    }

    public Habit getHabit(Habit habit){
        int find = habits.indexOf(habit);
        return habits.get(find);
    }

    public boolean hasHabit(Habit habit){
        return habits.contains(habit);
    }

    public void add(Habit habit) {
{'fraction_non_alphanumeric': 0.09535452322738386, 'fraction_numerical': 0.02689486552567237, 'mean_word_length': 3.082294264339152, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, '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': '4036911', 'n_tokens_mistral': 549, 'n_tokens_neox': 480, 'n_words': 158}