<commit_before>package org.cpic.haplotype;

import org.apache.commons.lang3.ObjectUtils;

import java.util.ArrayList;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class Variant implements Comparable<Variant> {

	private String CHROM;
	private String GeneName;
	private int POS;
	private int GenePOS;
	private ArrayList<String> HGVSg  = new ArrayList<>();
	private ArrayList<String> cDNA = new ArrayList<>();
	private ArrayList<String> ProteinEffect  = new ArrayList<>();
	private ArrayList<String> ALTs  = new ArrayList<>();
	private String REF;
	private String rsID;


	public Variant(){
	}
	public Variant(String _CHROM, String _GeneName,String _cDNA){
		CHROM = _CHROM;
		GeneName = _GeneName;
		if (_cDNA.contains(";")){
			String [] fields = _cDNA.split(";");
			for (int i = 0; i < fields.length; i++){
				cDNA.add(fields[i].trim());
			}
		}else{
			cDNA.add(_cDNA);
		}
	}
	public String getCHROM(){
		return CHROM;
	}
	public String getGeneName(){
		return GeneName;
	}
	public void set_cDNA(String _cDNA){
		if (_cDNA.contains(";")){
			String [] fields = _cDNA.split(";");
			for (int i = 0; i < fields.length; i++){
				cDNA.add(fields[i].trim());
			}
		}else{
			cDNA.add(_cDNA);
		}
	}
	public void addProteingEffect(String _ProteingEffect){
		if (_ProteingEffect.contains(";")){
			String [] fields = _ProteingEffect.split(";");
			for (int i = 0; i < fields.length; i++){
				ProteinEffect.add(fields[i].trim());
			}
		}else{

			ProteinEffect.add(_ProteingEffect);
		}
	}
	public void addHGVSg(String _HGVSg){
		if (_HGVSg.contains(";")){
			String [] fields = _HGVSg.split(";");
			for (int i = 0; i < fields.length; i++){
				HGVSg.add(fields[i].trim());
			}
		}else{

			HGVSg.add(_HGVSg);
		}
	}
	private int getStartPOS(String _HGVSg){

		  Pattern p = Pattern.compile("\\d+");
		  Matcher m = p.matcher(_HGVSg);

		  return Integer.parseInt(m.group(1));

	}
	public boolean setStartPOS(){
		if (HGVSg.isEmpty()){
			return false;
		}else{
			POS = getStartPOS(HGVSg.get(0));
			return true;
		}
	}
	public void setPOS(String _POS){
		POS = Integer.parseInt(_POS);
	}
	public int getPOS(){
		return POS;
	}
	public void setGenePOS(String _GenePOS){
		GenePOS = Integer.parseInt(_GenePOS);
	}
	public void setREF(String _REF){
		REF = (_REF);
	}
	public String getREF(){
		return REF;
	}
	public void set_rsID(String _rsID){
		rsID = (_rsID);
	}
	public void addALT(String _ALT){
		ALTs.add(_ALT);
	}
	public ArrayList<String> getALTs(){
		return ALTs;
	}


<commit_msg>filled out<commit_after>package org.cpic.haplotype;

import org.apache.commons.lang3.ObjectUtils;

import java.util.ArrayList;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class Variant implements Comparable<Variant> {

	private String CHROM;
	private String GeneName;
	private int POS;
	private int GenePOS;
	private ArrayList<String> HGVSg  = new ArrayList<>();
	private ArrayList<String> cDNA = new ArrayList<>();
	private ArrayList<String> ProteinEffect  = new ArrayList<>();
	private ArrayList<String> ALTs  = new ArrayList<>();
	private String REF;
	private String rsID;


	public Variant(){
	}
	public Variant(String _CHROM, String _GeneName,String _cDNA){
		CHROM = _CHROM;
		GeneName = _GeneName;
		if (_cDNA.contains(";")){
			String [] fields = _cDNA.split(";");
			for (int i = 0; i < fields.length; i++){
				cDNA.add(fields[i].trim());
			}
		}else{
			cDNA.add(_cDNA);
		}
	}
	public String getCHROM(){
		return CHROM;
	}
	public String getGeneName(){
		return GeneName;
	}
	public void set_cDNA(String _cDNA){
		if (_cDNA.contains(";")){
			String [] fields = _cDNA.split(";");
			for (int i = 0; i < fields.length; i++){
				cDNA.add(fields[i].trim());
			}
		}else{
			cDNA.add(_cDNA);
		}
	}
	public void addProteingEffect(String _ProteingEffect){
		if (_ProteingEffect.contains(";")){
			String [] fields = _ProteingEffect.split(";");
			for (int i = 0; i < fields.length; i++){
				ProteinEffect.add(fields[i].trim());
			}
		}else{

			ProteinEffect.add(_ProteingEffect);
		}
	}
	public void addHGVSg(String _HGVSg){
		if (_HGVSg.contains(";")){
			String [] fields = _HGVSg.split(";");
			for (int i = 0; i < fields.length; i++){
				HGVSg.add(fields[i].trim());
			}
		}else{

			HGVSg.add(_HGVSg);
		}
	}
	private int getStartPOS(String _HGVSg){

		  Pattern p = Pattern.compile("\\d+");
		  Matcher m = p.matcher(_HGVSg);

		  return Integer.parseInt(m.group(1));

	}
	public boolean setStartPOS(){
		if (HGVSg.isEmpty()){
			return false;
		}else{
			POS = getStartPOS(HGVSg.get(0));
			return true;
		}
	}
	public void setPOS(String _POS){
		POS = Integer.parseInt(_POS);
	}
	public int getPOS(){
		return POS;
	}
	public void setGenePOS(String _GenePOS){
		GenePOS = Integer.parseInt(_GenePOS);
	}
	public int getGenePOS(){
		return GenePOS;
	}
	public void setREF(String _REF){
		REF = (_REF);
	}
	public String getREF(){
		return REF;
	}
	public void set_rsID(String _rsID){
		rsID = (_rsID);
	}
	public String get_rsID(){
		return rsID;
	}
	public void addALT(String _ALT){
		ALTs.add(_ALT);
	}
	public ArrayList<String> getALTs(){
		return ALTs;
	}
	



{'fraction_non_alphanumeric': 0.15384615384615385, 'fraction_numerical': 0.002726387536514119, 'mean_word_length': 3.8361581920903953, 'pattern_counts': {'":': 0, '<': 31, '<?xml version=': 0, '>': 23, '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': '5705222', 'n_tokens_mistral': 2158, 'n_tokens_neox': 1868, 'n_words': 441}