<commit_before>package mil.dds.anet.database;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.skife.jdbi.v2.Handle;

import mil.dds.anet.beans.AdminSetting;
import mil.dds.anet.database.mappers.AdminSettingMapper;

public class AdminDao {

	public static enum AdminSettingKeys { 
		SECURITY_BANNER_TEXT,
		SECURITY_BANNER_COLOR, 
		DEFAULT_APPROVAL_ORGANIZATION,
		MAP_LAYERS,
		HELP_LINK_URL,
		CONTACT_EMAIL,
		DAILY_ROLLUP_MAX_REPORT_AGE_DAYS,
		EXTERNAL_DOCUMENTATION_LINK_URL,
		GENERAL_BANNER_TEXT
	}
	
	private Handle dbHandle;
	private Map<String,String> cachedSettings = null;
	
	public AdminDao(Handle db) { 
		this.dbHandle = db;
	}
	
	private void initCache() { 
		cachedSettings = new HashMap<String,String>();
		List<AdminSetting> settings = getAllSettings();<commit_msg>Add GENERAL_BANNER_LEVEL to Admin settings keys enum<commit_after>package mil.dds.anet.database;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.skife.jdbi.v2.Handle;

import mil.dds.anet.beans.AdminSetting;
import mil.dds.anet.database.mappers.AdminSettingMapper;

public class AdminDao {

	public static enum AdminSettingKeys { 
		SECURITY_BANNER_TEXT,
		SECURITY_BANNER_COLOR, 
		DEFAULT_APPROVAL_ORGANIZATION,
		MAP_LAYERS,
		HELP_LINK_URL,
		CONTACT_EMAIL,
		DAILY_ROLLUP_MAX_REPORT_AGE_DAYS,
		EXTERNAL_DOCUMENTATION_LINK_URL,
		GENERAL_BANNER_LEVEL,
		GENERAL_BANNER_TEXT
	}
	
	private Handle dbHandle;
	private Map<String,String> cachedSettings = null;
	
	public AdminDao(Handle db) { 
		this.dbHandle = db;
	}
	
	private void initCache() { 
		cachedSettings = new HashMap<String,String>();
		List<AdminSetting> settings = getAllSettings();
{'fraction_non_alphanumeric': 0.08504398826979472, 'fraction_numerical': 0.0011730205278592375, 'mean_word_length': 5.365671641791045, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, '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': '4548756', 'n_tokens_mistral': 669, 'n_tokens_neox': 622, 'n_words': 108}