<commit_before>package cz.metacentrum.perun.ldapc.beans;

import java.util.Properties;
import org.springframework.beans.factory.annotation.Autowired;

/**
 * LdapProperties data from properties file.
 * This class is singleton.
 * 
 * @author norexan
 */
public class LdapProperties {
  
    private static LdapProperties instance = null;
    
    @Autowired
    private Properties ldapcProperties;
    
    private String ldapConsumerName;
    private String ldapBase;
    private String ldapLoginNamespace;
    
    protected LdapProperties() {
       this.ldapConsumerName=ldapcProperties.getProperty("ldap.consumerName");
       this.ldapBase=ldapcProperties.getProperty("ldap.base");
       this.ldapLoginNamespace=ldapcProperties.getProperty("ldap.loginNamespace");
    }

    public Properties getLdapcProperties() {
        return ldapcProperties;
    }

    public String getLdapConsumerName() {
        return ldapConsumerName;
    }

    public String getLdapBase() {
        return ldapBase;
    }

    public String getLdapLoginNamespace() {
        return ldapLoginNamespace;
    }
    
    public synchronized static LdapProperties getInstance() {
        if(instance == null) {
            instance = new LdapProperties();
        }
        return instance;
    }
}<commit_msg>Ldapc: LdapProperties class, add setter for ldapcProperties<commit_after>package cz.metacentrum.perun.ldapc.beans;

import java.util.Properties;
import org.springframework.beans.factory.annotation.Autowired;

/**
 * LdapProperties data from properties file.
 * This class is singleton.
 * 
 * @author norexan
 */
public class LdapProperties {
  
    private static LdapProperties instance = null;
    
    @Autowired
    private Properties ldapcProperties;
    
    private String ldapConsumerName;
    private String ldapBase;
    private String ldapLoginNamespace;
    
    protected LdapProperties() {
       this.ldapConsumerName=ldapcProperties.getProperty("ldap.consumerName");
       this.ldapBase=ldapcProperties.getProperty("ldap.base");
       this.ldapLoginNamespace=ldapcProperties.getProperty("ldap.loginNamespace");
    }

    public Properties getLdapcProperties() {
        return ldapcProperties;
    }

    public String getLdapConsumerName() {
        return ldapConsumerName;
    }

    public String getLdapBase() {
        return ldapBase;
    }

    public String getLdapLoginNamespace() {
        return ldapLoginNamespace;
    }
    
    public synchronized static LdapProperties getInstance() {
        if(instance == null) {
            instance = new LdapProperties();
        }
        return instance;
    }

    public void setLdapcProperties(Properties ldapcProperties) {
        this.ldapcProperties = ldapcProperties;
    }
}
{'fraction_non_alphanumeric': 0.07885174418604651, 'fraction_numerical': 0.0, 'mean_word_length': 3.0967261904761907, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '5939112', 'n_tokens_mistral': 766, 'n_tokens_neox': 786, 'n_words': 162}