<commit_before>package com.autonomy.abc.selenium.indexes;

import java.util.ArrayList;
import java.util.Collection;
import java.util.Collections;
import java.util.List;

public class Index {
    private final String name;
    private final List<String> parametricFields = new ArrayList<>();
    private final List<String> indexFields = new ArrayList<>();

    public final static Index DEFAULT = new Index("default_index");

    public Index(String name) {
        this.name = name;
    }

    public Index withParametricFields(Collection<String> fields) {
        parametricFields.addAll(fields);
        return this;
    }

    public Index withIndexFields(Collection<String> fields) {
        getIndexFields().addAll(fields);
        return this;
    }

    public String getName() {
        return name;
    }

    public List<String> getParametricFields() {
        return Collections.unmodifiableList(parametricFields);
    }

    public List<String> getIndexFields() {
        return Collections.unmodifiableList(indexFields);
    }

    public String getCreateNotification() {
        return "Created a new index: " + name;
    }
}<commit_msg>Overridden equals and toString methods in Index<commit_after>package com.autonomy.abc.selenium.indexes;

import java.util.ArrayList;
import java.util.Collection;
import java.util.Collections;
import java.util.List;

public class Index {
    private final String name;
    private final List<String> parametricFields = new ArrayList<>();
    private final List<String> indexFields = new ArrayList<>();

    public final static Index DEFAULT = new Index("default_index");

    public Index(String name) {
        this.name = name;
    }

    public Index withParametricFields(Collection<String> fields) {
        parametricFields.addAll(fields);
        return this;
    }

    public Index withIndexFields(Collection<String> fields) {
        getIndexFields().addAll(fields);
        return this;
    }

    public String getName() {
        return name;
    }

    public List<String> getParametricFields() {
        return Collections.unmodifiableList(parametricFields);
    }

    public List<String> getIndexFields() {
        return Collections.unmodifiableList(indexFields);
    }

    public String getCreateNotification() {
        return "Created a new index: " + name;
    }

    @Override
    public boolean equals(Object obj) {
        if(obj instanceof Index){
            if (((Index) obj).getName().equals(getName())){
                return true;
            }
        }

        return false;
    }

    @Override
    public String toString() {
        return "Index<" + getName() + ">";
    }
}
{'fraction_non_alphanumeric': 0.09879789631855748, 'fraction_numerical': 0.0, 'mean_word_length': 2.910425844346549, 'pattern_counts': {'":': 0, '<': 20, '<?xml version=': 0, '>': 20, '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': '3435887', 'n_tokens_mistral': 719, 'n_tokens_neox': 691, 'n_words': 186}