<commit_before>package edu.umich.verdict;

import org.apache.spark.sql.DataFrame;
import org.apache.spark.sql.SQLContext;

import edu.umich.verdict.dbms.Dbms;
import edu.umich.verdict.exceptions.VerdictException;

/**
 * Spark 1.6 support
 * @author <NAME>
 *
 */
public class VerdictSparkContext extends VerdictContext {

	private SQLContext sqlContext;

	public VerdictSparkContext(SQLContext sqlContext) throws VerdictException {
		this(sqlContext, new VerdictConf());
		conf.setDbms("spark");
		setDbms(Dbms.from(this, conf));
	}
	
	public VerdictSparkContext(SQLContext sqlContext, VerdictConf conf) throws VerdictException {
		super(conf);
	}
	
	DataFrame executeSparkQuery(String sql) {
		DataFrame df = sqlContext.sql(sql);
		return df;
	}
}<commit_msg>minor<commit_after>package edu.umich.verdict;

import org.apache.spark.sql.DataFrame;
import org.apache.spark.sql.SQLContext;

import edu.umich.verdict.dbms.Dbms;
import edu.umich.verdict.exceptions.VerdictException;

/**
 * Spark 1.6 support
 * @author <NAME>
 *
 */
public class VerdictSparkContext extends VerdictContext {

	private SQLContext sqlContext;

	public VerdictSparkContext(SQLContext sqlContext) throws VerdictException {
		this(sqlContext, new VerdictConf());
		conf.setDbms("spark");
		setDbms(Dbms.from(this, conf));
	}
	
	public VerdictSparkContext(SQLContext sqlContext, VerdictConf conf) throws VerdictException {
		super(conf);
	}
	
	public DataFrame executeSparkQuery(String sql) {
		DataFrame df = sqlContext.sql(sql);
		return df;
	}
}
{'fraction_non_alphanumeric': 0.10782380013149244, 'fraction_numerical': 0.0026298487836949377, 'mean_word_length': 5.341666666666667, 'pattern_counts': {'":': 0, '<': 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': '4553823', 'n_tokens_mistral': 539, 'n_tokens_neox': 502, 'n_words': 101}