<repo_name>cscites/LeadSorter1<file_sep>/src/com/ho8c/Client.java
package com.ho8c;

/**
 * Created by chris.scites on 6/12/2017.
 */
public class Client {
    private String opportunityName;
    private String type;
    private String amount;
    private String closeDate;
    private String fiscalPeriod;
    private String accountName;
    private String leadSource;
    private String billingState;
    private String primaryCampaignSource;
    private String marketingCampaign;
    private String opportunityOwner;

    public Client(String opportunityName, String type, String amount, String closeDate, String fiscalPeriod,
                  String accountName, String leadSource, String billingState, String primaryCampaignSource,
                  String marketingCampaign, String opportunityOwner){
        this.opportunityName = opportunityName;
        this.type = type;
        this.amount = amount;
        this.closeDate = closeDate;
        this.fiscalPeriod = fiscalPeriod;
        this.accountName = accountName;
        this.leadSource = leadSource;
        this.billingState = billingState;
        this.primaryCampaignSource = primaryCampaignSource;
        this.marketingCampaign = marketingCampaign;
        this.opportunityOwner = opportunityOwner;
    }

    public String getOpportunityName(){
        return opportunityName;
    }

    public String getType(){
        return type;
    }

    public String getAmount(){
        return amount;
    }

    public String getCloseDate() {
        return closeDate;
    }

    public String getFiscalPeriod() {
        return fiscalPeriod;
    }

    public String getAccountName() {
        return accountName;
    }

    public String getBillingState() {
        return billingState;
    }

    public String getLeadSource() {
        return leadSource;
    }

    public String getMarketingCampaign() {
        return marketingCampaign;
    }

    public String getPrimaryCampaignSource() {
        return primaryCampaignSource;
    }

    public String getOpportunityOwner() {
        return opportunityOwner;
    }

}
<file_sep>/src/com/ho8c/CsvParser.java
package com.ho8c;

import org.apache.commons.csv.CSVFormat;
import org.apache.commons.csv.CSVRecord;

import java.io.File;
import java.io.FileReader;
import java.io.IOException;
import java.io.Reader;
import java.util.ArrayList;

/**
 * Created by chris on 5/29/17.
 */
public class CsvParser extends ArrayList<String[]> {
    private String[] headerArray;
    private ArrayList<CSVRecord> variableSets  = new ArrayList<>();


    public CsvParser(String csvFile) throws IOException {

        File csv = new File(csvFile);
        Reader in = new FileReader(csv);
        Iterable<CSVRecord> records = CSVFormat.DEFAULT.parse(in);


        for(CSVRecord record:records){
            variableSets.add(record);
        }

        int n = variableSets.get(0).size();
        headerArray = new String[n];
        int a = 0;
        while (a < n){
            headerArray[a] = variableSets.get(0).get(a);
            a++;
        }

        variableSets.remove(0);

        in.close();

    }

    ArrayList<CSVRecord> getVariableSets(){
        return variableSets;
    }

    String[] getHeaders(){
        return headerArray;
    }

}
<file_sep>/src/com/ho8c/Lead.java
package com.ho8c;

/**
 * Created by chris on 5/21/17.
 */
public class Lead {
    private String source;
    private String specialty;
    private String conference;
    private String date;
    private String prefix;
    private String firstName;
    private String middleName;
    private String lastName;
    private String degree;
    private String company;
    private String address1;
    private String address2;
    private String city;
    private String state;
    private String zip;
    private String country;
    private String phone;
    private String fax;
    private String email;
    private String notes;
    private String geoInt;
    private String availability;
    private String status;
    public Lead(String source, String specialty, String conference, String date, String prefix, String firstName,
                String middleName, String lastName, String degree, String company, String address1,
                String address2, String city, String state, String zip, String country,
                String phone, String fax, String email, String notes, String geoInt,
                String availability, String status){
        this.source = source;
        this.specialty = specialty;
        this.conference = conference;
        this.date = date;
        this.prefix = prefix;
        this.firstName = firstName;
        this.middleName = middleName;
        this.lastName = lastName;
        this.degree = degree;
        this.company = company;
        this.address1 = address1;
        this.address2 = address2;
        this.city = city;
        this.state = state;
        this.zip = zip;
        this.country = country;
        this.phone = phone;
        this.fax = fax;
        this.email = email;
        this.notes = notes;
        this.geoInt = geoInt;
        this.availability = availability;
        this.status = status;
    }

    public String getSource(){
        return source;
    }

    public String getSpecialty(){
        return specialty;
    }

    public String getConference(){
        return conference;
    }

    public String getDate(){
        return date;
    }

    public String getPrefix(){
        return prefix;
    }

    public String getFirstName(){
        return firstName;
    }

    public String getMiddleName(){
        return middleName;
    }

    public String getLastName(){
        return lastName;
    }

    public String getDegree(){
        return degree;
    }

    public String getCompany(){
        return company;
    }

    public String getAddress1(){
        return address1;
    }

    public String getAddress2(){
        return address2;
    }

    public String getCity(){
        return city;
    }

    public String getState(){
        return state;
    }

    public String getZip(){
        return zip;
    }

    public String getCountry(){
        return country;
    }

    public String getPhone(){
        return phone;
    }

    public String getFax(){
        return fax;
    }

    public String getEmail(){
        return email;
    }

    public String getNotes(){
        return notes;
    }

    public String getGeoInt(){
        return geoInt;
    }

    public String getAvailability(){
        return availability;
    }

    public String getStatus(){
        return status;
    }
}

