<commit_before>/*******************************************************************************
 * Copyright (C) 2007 The University of Manchester   
 * 
 *  Modifications to the initial code base are copyright of their
 *  respective authors, or their employers as appropriate.
 * 
 *  This program is free software; you can redistribute it and/or
 *  modify it under the terms of the GNU Lesser General Public License
 *  as published by the Free Software Foundation; either version 2.1 of
 *  the License, or (at your option) any later version.
 *    
 *  This program is distributed in the hope that it will be useful, but
 *  WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 *  Lesser General Public License for more details.
 *    
 *  You should have received a copy of the GNU Lesser General Public
 *  License along with this program; if not, write to the Free Software
 *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
 ******************************************************************************/
package net.sf.taverna.cagrid.activity.config;

import java.io.IOException;
import java.io.StringReader;
import java.io.StringWriter;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.apache.log4j.Logger;

import au.com.bytecode.opencsv.CSVReader;
import au.com.bytecode.opencsv.CSVWriter;

import net.sf.taverna.t2.workbench.configuration.AbstractConfigurable;

/**
 * Configuration for the caGrid activity.
 * 
 * @author <NAME>
 */
public class CaGridConfiguration extends AbstractConfigurable {
	
	public static String uuid = "1df75ad0-491e-11de-8a39-0800200c9a66";
	
	// Default values
	public static String PRODUCTION_CAGRID_NAME =  "NCI Production CaGrid 1.3";
	public static String PRODUCTION_INDEX_SERVICE_URL = "http://cagrid-index.nci.nih.gov:8080/wsrf/services/DefaultIndexService";
	public static String PRODUCTION_AUTHN_SERVICE_URL = "https://cagrid-dorian.nci.nih.gov:8443/wsrf/services/cagrid/Dorian";
	public static String PRODUCTION_DORIAN_SERVICE_URL = "https://cagrid-dorian.nci.nih.gov:8443/wsrf/services/cagrid/Dorian";
	public static String PRODUCTION_PROXY_LIFETIME = "12"; // 12 hours is default and maximum
	public static String PRODUCTION_CADSR_SERVICE_URL = "http://cagrid-service.nci.nih.gov:8080/wsrf/services/cagrid/CaDSRService";

	public static String TRAINING_CAGRID_NAME =  "Training CaGrid 1.3";
	public static String TRAINING_INDEX_SERVICE_URL = "http://index.training.cagrid.org:8080/wsrf/services/DefaultIndexService";
	public static String TRAINING_AUTHN_SERVICE_URL = "https://dorian.training.cagrid.org:8443/wsrf/services/cagrid/Dorian";
	public static String TRAINING_DORIAN_SERVICE_URL = "https://dorian.training.cagrid.org:8443/wsrf/services/cagrid/Dorian";
	public static String TRAINING_PROXY_LIFETIME = "12"; // 12 hours is default and maximum
	public static String TRAINING_CADSR_SERVICE_URL = "https://cadsr.training.cagrid.org:8443/wsrf/services/cagrid/CaDSRService";

	private Map<String, String> defaultPropertyMap;

	private static CaGridConfiguration instance;

	private static Logger logger = Logger.getLogger(CaGridConfiguration.class);
	
	public static CaGridConfiguration getInstance() {
		if (instance == null) {
			instance = new CaGridConfiguration();
		}
		return instance;
	}

	private CaGridConfiguration() {
		super();
		initaliseDefaults();
	}

	public String getCategory() {
		return "cagrid";<commit_msg>Updated the caDSR URLs for production and training grids.<commit_after>/*******************************************************************************
 * Copyright (C) 2007 The University of Manchester   
 * 
 *  Modifications to the initial code base are copyright of their
 *  respective authors, or their employers as appropriate.
 * 
 *  This program is free software; you can redistribute it and/or
 *  modify it under the terms of the GNU Lesser General Public License
 *  as published by the Free Software Foundation; either version 2.1 of
 *  the License, or (at your option) any later version.
 *    
 *  This program is distributed in the hope that it will be useful, but
 *  WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 *  Lesser General Public License for more details.
 *    
 *  You should have received a copy of the GNU Lesser General Public
 *  License along with this program; if not, write to the Free Software
 *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
 ******************************************************************************/
package net.sf.taverna.cagrid.activity.config;

import java.io.IOException;
import java.io.StringReader;
import java.io.StringWriter;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.apache.log4j.Logger;

import au.com.bytecode.opencsv.CSVReader;
import au.com.bytecode.opencsv.CSVWriter;

import net.sf.taverna.t2.workbench.configuration.AbstractConfigurable;

/**
 * Configuration for the caGrid activity.
 * 
 * @author <NAME>
 */
public class CaGridConfiguration extends AbstractConfigurable {
	
	public static String uuid = "1df75ad0-491e-11de-8a39-0800200c9a66";
	
	// Default values
	public static String PRODUCTION_CAGRID_NAME =  "NCI Production CaGrid 1.3";
	public static String PRODUCTION_INDEX_SERVICE_URL = "http://cagrid-index.nci.nih.gov:8080/wsrf/services/DefaultIndexService";
	public static String PRODUCTION_AUTHN_SERVICE_URL = "https://cagrid-dorian.nci.nih.gov:8443/wsrf/services/cagrid/Dorian";
	public static String PRODUCTION_DORIAN_SERVICE_URL = "https://cagrid-dorian.nci.nih.gov:8443/wsrf/services/cagrid/Dorian";
	public static String PRODUCTION_PROXY_LIFETIME = "12"; // 12 hours is default and maximum
	public static String PRODUCTION_CADSR_SERVICE_URL = "http://cadsr-dataservice.nci.nih.gov/wsrf/services/cagrid/CaDSRDataService";
	
	public static String TRAINING_CAGRID_NAME =  "Training CaGrid 1.3";
	public static String TRAINING_INDEX_SERVICE_URL = "http://index.training.cagrid.org:8080/wsrf/services/DefaultIndexService";
	public static String TRAINING_AUTHN_SERVICE_URL = "https://dorian.training.cagrid.org:8443/wsrf/services/cagrid/Dorian";
	public static String TRAINING_DORIAN_SERVICE_URL = "https://dorian.training.cagrid.org:8443/wsrf/services/cagrid/Dorian";
	public static String TRAINING_PROXY_LIFETIME = "12"; // 12 hours is default and maximum
	public static String TRAINING_CADSR_SERVICE_URL = "http://cadsr-dataservice-sandbox.nci.nih.gov/wsrf/services/cagrid/CaDSRDataService";

	private Map<String, String> defaultPropertyMap;

	private static CaGridConfiguration instance;

	private static Logger logger = Logger.getLogger(CaGridConfiguration.class);
	
	public static CaGridConfiguration getInstance() {
		if (instance == null) {
			instance = new CaGridConfiguration();
		}
		return instance;
	}

	private CaGridConfiguration() {
		super();
		initaliseDefaults();
	}

	public String getCategory() {
		return "cagrid";
{'fraction_non_alphanumeric': 0.12935253810655853, 'fraction_numerical': 0.023493217731785764, 'mean_word_length': 5.015138772077376, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 9, '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': '5456440', 'n_tokens_mistral': 2317, 'n_tokens_neox': 2121, 'n_words': 595}