<commit_before>package fr.inria.spirals.repairnator.config;

import fr.inria.jtravis.JTravis;
import fr.inria.spirals.repairnator.states.BearsMode;
import fr.inria.spirals.repairnator.states.LauncherMode;
import org.kohsuke.github.GitHub;

import java.io.File;
import java.io.IOException;
import java.time.Duration;
import java.util.Arrays;
import java.util.Date;

/**
 * Created by urli on 08/03/2017.
 */
public class RepairnatorConfig {
    private String runId;
    private LauncherMode launcherMode = LauncherMode.REPAIR;

    private boolean serializeJson;
    private String inputPath;
    private String outputPath;
    private String mongodbHost;
    private String mongodbName;
    private String smtpServer;
    private String[] notifyTo;
    private boolean notifyEndProcess;
    private boolean push;
    private String pushRemoteRepo;
    private boolean fork;

    // Scanner
    private Date lookFromDate;
    private Date lookToDate;
    private BearsMode bearsMode;

    // Pipeline
    private int buildId;
    private int nextBuildId;
    private String z3solverPath;
    private String workspacePath;<commit_msg>Avoid NPE when bearsMode is not set in config.<commit_after>package fr.inria.spirals.repairnator.config;

import fr.inria.jtravis.JTravis;
import fr.inria.spirals.repairnator.states.BearsMode;
import fr.inria.spirals.repairnator.states.LauncherMode;
import org.kohsuke.github.GitHub;

import java.io.File;
import java.io.IOException;
import java.time.Duration;
import java.util.Arrays;
import java.util.Date;

/**
 * Created by urli on 08/03/2017.
 */
public class RepairnatorConfig {
    private String runId;
    private LauncherMode launcherMode = LauncherMode.REPAIR;

    private boolean serializeJson;
    private String inputPath;
    private String outputPath;
    private String mongodbHost;
    private String mongodbName;
    private String smtpServer;
    private String[] notifyTo;
    private boolean notifyEndProcess;
    private boolean push;
    private String pushRemoteRepo;
    private boolean fork;

    // Scanner
    private Date lookFromDate;
    private Date lookToDate;
    private BearsMode bearsMode = BearsMode.BOTH;

    // Pipeline
    private int buildId;
    private int nextBuildId;
    private String z3solverPath;
    private String workspacePath;
{'fraction_non_alphanumeric': 0.07124352331606218, 'fraction_numerical': 0.007772020725388601, 'mean_word_length': 3.837160751565762, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '2149716', 'n_tokens_mistral': 724, 'n_tokens_neox': 696, 'n_words': 190}