<commit_before>package gov.nih.nci.ncia.dbadapter;

import java.io.File;

import org.apache.log4j.Logger;
import org.rsna.ctp.objects.DicomObject;
import org.rsna.ctp.objects.FileObject;
import org.rsna.ctp.objects.XmlObject;
import org.rsna.ctp.objects.ZipObject;
import org.rsna.ctp.pipeline.Status;
import org.rsna.ctp.stdstages.database.DatabaseAdapter;
import org.springframework.context.support.ClassPathXmlApplicationContext;


public class NCIADatabase extends DatabaseAdapter{
    private Logger log = Logger.getLogger(NCIADatabase.class);
	public static ClassPathXmlApplicationContext ctx = new ClassPathXmlApplicationContext("applicationContext.xml");
   	public static NCIADatabaseDelegator delegator = (NCIADatabaseDelegator)ctx.getBean("nciaDelegator");
   	
    public Status process(DicomObject file, File storedFile,String url) {
    	Status status = Status.OK;
    	try{
    		System.out.println("hashCode: " + this.hashCode());
    		delegator.process(file, storedFile, url);
    		status = Status.OK;
    	}catch(RuntimeException rx){
    		log.error("Dicom Submission Failed!");
    		status = Status.FAIL;
    	}
    	return status;
    }
    
    public Status process(XmlObject file,File storedFile, String url) {
    	Status status = Status.OK;
    	
    	try{
    		delegator.process(file, storedFile, url);
    		status = Status.OK;
    	}catch(RuntimeException rx){
    		log.error("XML Submission Failed!");
    		status = Status.FAIL;
    	}
    	return status;
    	
    }
    
    public Status process(ZipObject file, File storedFile, String url) {
    	Status status = Status.OK;
    	
    	try{
    		delegator.process(file, storedFile, url);
    		status = Status.OK;
    	}catch(RuntimeException rx){
    		log.error("ZIP Submission Failed!");
    		status = Status.FAIL;
    	}
    	return status;
    	
    }
    
    public Status process(FileObject file, File storedFile, String url) {
    	Status status = Status.OK;
    	
    	try{
    		delegator.process(file, storedFile, url);
    		status = Status.OK;
    	}catch(RuntimeException rx){
    		log.error("File Submission Failed!");
    		status = Status.FAIL;
    	}
    	return status;
    	
    }
    
}<commit_msg>Fix UIDQuery issue<commit_after>package gov.nih.nci.ncia.dbadapter;

import java.io.File;
import java.util.Map;
import java.util.Set;


import org.apache.log4j.Logger;
import org.rsna.ctp.objects.DicomObject;
import org.rsna.ctp.objects.FileObject;
import org.rsna.ctp.objects.XmlObject;
import org.rsna.ctp.objects.ZipObject;
import org.rsna.ctp.pipeline.Status;
import org.rsna.ctp.stdstages.database.DatabaseAdapter;
import org.springframework.context.support.ClassPathXmlApplicationContext;
import org.rsna.ctp.stdstages.database.UIDResult;


public class NCIADatabase extends DatabaseAdapter{
    private Logger log = Logger.getLogger(NCIADatabase.class);
	public static ClassPathXmlApplicationContext ctx = new ClassPathXmlApplicationContext("applicationContext.xml");
   	public static NCIADatabaseDelegator delegator = (NCIADatabaseDelegator)ctx.getBean("nciaDelegator");
   	
    public Status process(DicomObject file, File storedFile,String url) {
    	Status status = Status.OK;
    	try{
    		System.out.println("hashCode: " + this.hashCode());
    		delegator.process(file, storedFile, url);
    		status = Status.OK;
    	}catch(RuntimeException rx){
    		log.error("Dicom Submission Failed!");
    		status = Status.FAIL;
    	}
    	return status;
    }
    
    public Status process(XmlObject file,File storedFile, String url) {
    	Status status = Status.OK;
    	
    	try{
    		delegator.process(file, storedFile, url);
    		status = Status.OK;
    	}catch(RuntimeException rx){
    		log.error("XML Submission Failed!");
    		status = Status.FAIL;
    	}
    	return status;
    	
    }
    
    public Status process(ZipObject file, File storedFile, String url) {
    	Status status = Status.OK;
    	
    	try{
    		delegator.process(file, storedFile, url);
    		status = Status.OK;
    	}catch(RuntimeException rx){
    		log.error("ZIP Submission Failed!");
    		status = Status.FAIL;
    	}
    	return status;
    	
    }
    
    public Status process(FileObject file, File storedFile, String url) {
    	Status status = Status.OK;
    	
    	try{
    		delegator.process(file, storedFile, url);
    		status = Status.OK;
    	}catch(RuntimeException rx){
    		log.error("File Submission Failed!");
    		status = Status.FAIL;
    	}
    	return status;
    	
    }
    
    public Map<String, UIDResult> uidQuery(Set<String> uidSet)
    {
    	return delegator.uidQuery(uidSet);
    }
    
}
{'fraction_non_alphanumeric': 0.10314384151593455, 'fraction_numerical': 0.0004306632213608958, 'mean_word_length': 3.0638670166229223, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, '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': '981749', 'n_tokens_mistral': 1541, 'n_tokens_neox': 1534, 'n_words': 303}