<commit_before>package org.tndata.android.compass.model;

import android.widget.ImageView;

import com.google.gson.annotations.SerializedName;

import org.tndata.android.compass.util.ImageLoader;

import java.io.Serializable;


/**
 * Model class for categories.
 *
 * @author Edited by <NAME>
 * @version 1.0.0
 */
public class CategoryContent extends TDCContent implements Serializable{
    private static final long serialVersionUID = -1751642109285216370L;

    public static final String TYPE = "category";


    @SerializedName("order")
    private int mOrder = -1;
    @SerializedName("image_url")
    private String mImageUrl = "";
    @SerializedName("color")
    private String mColor = "";
    @SerializedName("secondary_color")
    private String mSecondaryColor = "";

    @SerializedName("packaged_content")
    private boolean mPackagedContent = false;


    /*---------*
     * GETTERS *
     *---------*/

    public int getOrder(){
        return mOrder;
    }

    public String getImageUrl(){
        return mImageUrl;
    }

    public String getColor(){
        return mColor;
    }

    public String getSecondaryColor(){
        return this.mSecondaryColor;
    }

    public boolean isPackagedContent(){
        return mPackagedContent;
    }

    @Override
    protected String getType(){
        return TYPE;
    }

    /*---------*
     * UTILITY *
     *---------*/

    public void loadImageIntoView(ImageView imageView){
        String url = getImageUrl();
        if (url != null && !url.isEmpty()){
            ImageLoader.Options options = new ImageLoader.Options()
                    .setUsePlaceholder(false)
                    .setCropToCircle(true);
            ImageLoader.loadBitmap(imageView, url, options);
        }
    }

    @Override
    public String toString(){
        return "CategoryContent #" + getId() + ": " + getTitle();
    }
}<commit_msg>adding the selected_by_default attribute on Categories<commit_after>package org.tndata.android.compass.model;

import android.widget.ImageView;

import com.google.gson.annotations.SerializedName;

import org.tndata.android.compass.util.ImageLoader;

import java.io.Serializable;


/**
 * Model class for categories.
 *
 * @author Edited by <NAME>
 * @version 1.0.0
 */
public class CategoryContent extends TDCContent implements Serializable{
    private static final long serialVersionUID = -1751642109285216370L;

    public static final String TYPE = "category";


    @SerializedName("order")
    private int mOrder = -1;
    @SerializedName("image_url")
    private String mImageUrl = "";
    @SerializedName("color")
    private String mColor = "";
    @SerializedName("secondary_color")
    private String mSecondaryColor = "";

    @SerializedName("packaged_content")
    private boolean mPackagedContent = false;

    @SerializedName("selected_by_default")
    private boolean mSelectedByDefault = false;


    /*---------*
     * GETTERS *
     *---------*/

    public int getOrder(){
        return mOrder;
    }

    public String getImageUrl(){
        return mImageUrl;
    }

    public String getColor(){
        return mColor;
    }

    public String getSecondaryColor(){
        return this.mSecondaryColor;
    }

    public boolean isPackagedContent(){
        return mPackagedContent;
    }

    public boolean isSelectedByDefault() { return mSelectedByDefault; }

    @Override
    protected String getType(){
        return TYPE;
    }

    /*---------*
     * UTILITY *
     *---------*/

    public void loadImageIntoView(ImageView imageView){
        String url = getImageUrl();
        if (url != null && !url.isEmpty()){
            ImageLoader.Options options = new ImageLoader.Options()
                    .setUsePlaceholder(false)
                    .setCropToCircle(true);
            ImageLoader.loadBitmap(imageView, url, options);
        }
    }

    @Override
    public String toString(){
        return "CategoryContent #" + getId() + ": " + getTitle();
    }
}
{'fraction_non_alphanumeric': 0.1195, 'fraction_numerical': 0.0115, 'mean_word_length': 2.506573181419807, 'pattern_counts': {'":': 2, '<': 5, '<?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': '6744234', 'n_tokens_mistral': 1166, 'n_tokens_neox': 1090, 'n_words': 259}