How to retrieve all Spring Boot I18N Messages -


i need retrieve messages have in file messages_en.properties, messages_es.properties, etc. depending of current locale, far can not find way more value of property.

what need nothing more return translations corresponding current locale, can handle internationalization angularjs in front end.

thanks in advance,

you can use plain old java load entries of properties file:

properties properties = new properties(); inputstream in = getclass().getresourceasstream("messages_en.properties"); properties.load(in); in.close(); (map.entry<object, object> entry : properties.entryset()) {    system.out.println(entry.getkey() + " -> " + entry.getvalue()); } 

Comments

Popular posts from this blog

angular - Ionic slides - dynamically add slides before and after -

minify - Minimizing css files -

Add a dynamic header in angular 2 http provider -