<commit_before>package org.blaazinsoftware.centaur.service;

import com.google.appengine.api.datastore.Cursor;
import com.google.appengine.api.datastore.Index;
import com.google.appengine.api.datastore.QueryResultList;

import java.util.ArrayList;
import java.util.List;

/**
 * Implementation of the <code>QueryResultList</code> to allow for paged results
 *
 * @author <NAME>
 *         Date: 14-10-30
 */
public class ResultList <T> extends ArrayList<T> implements QueryResultList<T> {
    private List<Index> indexList;
    private Cursor cursor;

    /**
     * Get the indexes used to perform the query.
     *
     * @return      - <code>Index</code>
     */
    public List<Index> getIndexList() {
        return indexList;
    }

    /**
     * Set the List of Indexes
     *
     * @param indexList     - List of Indexes
     */
    protected void setIndexList(List<Index> indexList) {
        this.indexList = indexList;
    }

    /**
     * Gets a Cursor that points to the result immediately after the last one in this list.
     *
     * @return              - <code>Cursor</code>
     */
    public Cursor getCursor() {
        return cursor;
    }

    /**
     * Gets a Cursor that points to the result immediately after the last one in this list.
     *
     * @param cursor        - <code>Cursor</code>
     */
    protected void setCursor(Cursor cursor) {
        this.cursor = cursor;
    }<commit_msg>Add a constructor to create a copy of a ResultList object.<commit_after>package org.blaazinsoftware.centaur.service;

import com.google.appengine.api.datastore.Cursor;
import com.google.appengine.api.datastore.Index;
import com.google.appengine.api.datastore.QueryResultList;

import java.util.ArrayList;
import java.util.List;

/**
 * Implementation of the <code>QueryResultList</code> to allow for paged results
 *
 * @author <NAME>
 *         Date: 14-10-30
 */
public class ResultList <T> extends ArrayList<T> implements QueryResultList<T> {
    private List<Index> indexList;
    private Cursor cursor;

    /**
     * Default Constructor
     */
    public ResultList() {

    }

    /**
     * Constructor for cloning a ResultList object
     *
     * @param cursor        - <code>Cursor</code> to use
     */
    public ResultList (Cursor cursor) {
        this.cursor = cursor;
    }

    /**
     * Get the indexes used to perform the query.
     *
     * @return              - <code>Index</code>
     */
    public List<Index> getIndexList() {
        return indexList;
    }

    /**
     * Set the List of Indexes
     *
     * @param indexList     - List of Indexes
     */
    protected void setIndexList(List<Index> indexList) {
        this.indexList = indexList;
    }

    /**
     * Gets a Cursor that points to the result immediately after the last one in this list.
     *
     * @return              - <code>Cursor</code>
     */
    public Cursor getCursor() {
        return cursor;
    }

    /**
     * Gets a Cursor that points to the result immediately after the last one in this list.
     *
     * @param cursor        - <code>Cursor</code>
     */
    protected void setCursor(Cursor cursor) {
        this.cursor = cursor;
    }
{'fraction_non_alphanumeric': 0.10326428123038292, 'fraction_numerical': 0.003766478342749529, 'mean_word_length': 2.2586912065439675, 'pattern_counts': {'":': 0, '<': 35, '<?xml version=': 0, '>': 35, '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': '2653134', 'n_tokens_mistral': 956, 'n_tokens_neox': 926, 'n_words': 267}