You can retrieve all messages at once, in a single call from Java/JSP.
This approach may improve performance in portlets that require frequent access to the resource bundle and want to consolidate the message retrieval to a single call. The rest of the page then makes lookups into the loaded map.
<%@ page import="com.endeca.portlet.util.LanguageUtils" %> <%@ page import="java.util.Map" %> <% Map<String, String> messages = LanguageUtils.getAllPortletMessages(renderRequest); %> <%= messages.get("reset") %> <%= messages.get("num-records") %> <%= LanguageUtils.replaceMessageTokens(messages.get("search-for"), new String[]{ "American" }) %>