<commit_before>package com.example.anudeepsamaiya.recyclerviewdemo;

import android.content.Context;
import android.support.v7.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;

import java.util.List;

/**
 * Created by AnudeepSamaiya on 18-10-2015.
 */
public class ExampleAdapter extends RecyclerView.Adapter<ExampleAdapter.ItemViewHolder> {
    Context context;
    List<String> dataset;

    public ExampleAdapter(Context context, List<String> dataset){
        this.context = context;
        this.dataset = dataset;
    }

    @Override
    public ItemViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
        return new ItemViewHolder(LayoutInflater.from(context).inflate(R.layout.item, parent, false));
    }

    @Override
    public void onBindViewHolder(ItemViewHolder holder, int position) {
        holder.tvTitle.setText(dataset.get(position));
    }

    @Override
    public int getItemCount() {
        return 0;
    }

    public class ItemViewHolder extends RecyclerView.ViewHolder {
        TextView tvTitle;
        public ItemViewHolder(View itemView) {
            super(itemView);
            tvTitle = (TextView) itemView.findViewById(R.id.tv_title);
        }
    }
}<commit_msg>return dataset size from getItemCount()<commit_after>package com.example.anudeepsamaiya.recyclerviewdemo;

import android.content.Context;
import android.support.v7.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;

import java.util.List;

/**
 * Created by AnudeepSamaiya on 18-10-2015.
 */
public class ExampleAdapter extends RecyclerView.Adapter<ExampleAdapter.ItemViewHolder> {
    Context context;
    List<String> dataset;

    public ExampleAdapter(Context context, List<String> dataset){
        this.context = context;
        this.dataset = dataset;
    }

    @Override
    public ItemViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
        return new ItemViewHolder(LayoutInflater.from(context).inflate(R.layout.item, parent, false));
    }

    @Override
    public void onBindViewHolder(ItemViewHolder holder, int position) {
        holder.tvTitle.setText(dataset.get(position));
    }

    @Override
    public int getItemCount() {
        return dataset.size();
    }

    public class ItemViewHolder extends RecyclerView.ViewHolder {
        TextView tvTitle;
        public ItemViewHolder(View itemView) {
            super(itemView);
            tvTitle = (TextView) itemView.findViewById(R.id.tv_title);
        }
    }
}
{'fraction_non_alphanumeric': 0.09254402397901836, 'fraction_numerical': 0.007118771075309105, 'mean_word_length': 3.494949494949495, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, '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': '3113204', 'n_tokens_mistral': 785, 'n_tokens_neox': 740, 'n_words': 162}