class ConfigurationFactoryImpl implements ConfigurationFactory {

    @Override
    public SecureConfigItem newSecuredConfigItem(final String name,
                                                 final String valueType) {
        final SecureConfigItem stringConfigItem = new SecureConfigItem();
        if (name.startsWith(CRYPT_PREFIX)) {
            stringConfigItem.setName(name.substring(CRYPT_PREFIX.length()));
        } else {
            stringConfigItem.setName(name);
        }
        stringConfigItem.setValue(secureService.encrypt(valueType));
        return stringConfigItem;
    }

    public  ConfigurationFactoryImpl();
    @Inject public  ConfigurationFactoryImpl(final PasswordService secureService);

}