<commit_before>package edu.duke.cabig.c3pr.web.admin;

import gov.nih.nci.cabig.ctms.web.tabs.Flow;
import gov.nih.nci.cabig.ctms.web.tabs.Tab;
import gov.nih.nci.cabig.ctms.web.tabs.TabConfigurer;

import org.springframework.context.ApplicationContextAware;
import org.springframework.context.ApplicationContext;
import org.springframework.beans.factory.config.AutowireCapableBeanFactory;

/**
 * Implements {@link TabConfigurer} by delegating to the containing application context.
 *
 * @author <NAME>
 */
public class C3PRDefaultTabConfigurer implements TabConfigurer, ApplicationContextAware {
	
	
    public C3PRDefaultTabConfigurer() {
		super();
		// TODO Auto-generated constructor stub
	}

	private ApplicationContext applicationContext;

    public void injectDependencies(Tab<?> tab) {
        AutowireCapableBeanFactory autowireer = getBeanFactory();
            autowireer.autowireBeanProperties(tab,
                AutowireCapableBeanFactory.AUTOWIRE_BY_NAME,
                false /* Not all settable properties are expected to be in the context */);
    }

    protected AutowireCapableBeanFactory getBeanFactory() {
        return applicationContext.getAutowireCapableBeanFactory();
    }

    public void setApplicationContext(ApplicationContext applicationContext) {
        this.applicationContext = applicationContext;
    }

	public void injectDependencies(Flow<?> arg0) {
		// TODO Auto-generated method stub
		
	}
}<commit_msg>updated inject dependencies<commit_after>package edu.duke.cabig.c3pr.web.admin;

import gov.nih.nci.cabig.ctms.web.tabs.Flow;
import gov.nih.nci.cabig.ctms.web.tabs.Tab;
import gov.nih.nci.cabig.ctms.web.tabs.TabConfigurer;

import org.springframework.context.ApplicationContextAware;
import org.springframework.context.ApplicationContext;
import org.springframework.beans.factory.config.AutowireCapableBeanFactory;

/**
 * Implements {@link TabConfigurer} by delegating to the containing application context.
 *
 * @author <NAME>
 */
public class C3PRDefaultTabConfigurer implements TabConfigurer, ApplicationContextAware {
	
	
    public C3PRDefaultTabConfigurer() {
		super();
		// TODO Auto-generated constructor stub
	}

	private ApplicationContext applicationContext;

    public void injectDependencies(Tab<?> tab) {
        AutowireCapableBeanFactory autowireer = getBeanFactory();
            autowireer.autowireBeanProperties(tab,
                AutowireCapableBeanFactory.AUTOWIRE_BY_NAME,
                false /* Not all settable properties are expected to be in the context */);
    }

    protected AutowireCapableBeanFactory getBeanFactory() {
        return applicationContext.getAutowireCapableBeanFactory();
    }

    public void setApplicationContext(ApplicationContext applicationContext) {
        this.applicationContext = applicationContext;
    }

	public void injectDependencies(Flow<?> flow) {
		 AutowireCapableBeanFactory autowireer = getBeanFactory();
	        for (Tab<?> tab : flow.getTabs()) {
	            autowireer.autowireBeanProperties(tab,
	                AutowireCapableBeanFactory.AUTOWIRE_BY_NAME,
	                false /* Not all settable properties are expected to be in the context */);
	        }
		
	}
}
{'fraction_non_alphanumeric': 0.08387901465544122, 'fraction_numerical': 0.002182725288431556, 'mean_word_length': 3.897709923664122, 'pattern_counts': {'":': 0, '<': 10, '<?xml version=': 0, '>': 10, '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': '144709', 'n_tokens_mistral': 929, 'n_tokens_neox': 894, 'n_words': 183}