All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.jlot.client.config.ClientConfig Maven / Gradle / Ivy

There is a newer version: 1.2
Show newest version
package org.jlot.client.config;

import javax.inject.Inject;

import org.jlot.client.configuration.Console;
import org.jlot.client.configuration.UserConsole;
import org.springframework.context.MessageSource;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.support.MessageSourceAccessor;

import com.fasterxml.jackson.databind.ObjectMapper;

@Configuration
@ComponentScan(basePackages = { "org.jlot.client", "org.jlot.api", "org.jlot.core.utils" })
public class ClientConfig
{
	@Inject
	private MessageSource messageSource;

	@Bean
	public Console console ( )
	{
		return new UserConsole();
	}

	@Bean
	public ObjectMapper objectMapper ( )
	{
		return new ObjectMapper();
	}

	@Bean
	public MessageSourceAccessor messageSourceAccessor ( )
	{
		return new MessageSourceAccessor(messageSource);
	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy