public CmsMessages getMessages(Locale locale) {

        CmsMessages result = null;
        if ((m_messageBundleNames == null) || m_messageBundleNames.isEmpty()) {
            return new CmsMessages(Messages.get().getBundleName(), locale);
        } else {
            // a message bundle was initialized
            CmsMultiMessages multiMessages = new CmsMultiMessages(locale);
            for (String messageBundleName : m_messageBundleNames) {
                multiMessages.addMessages(new CmsMessages(messageBundleName, locale));
            }
            if (!m_messageBundleNames.contains(Messages.get().getBundleName())) {
                multiMessages.addMessages(new CmsMessages(Messages.get().getBundleName(), locale));
            }
            result = multiMessages;

        }
        return result;
    }
public CmsMessages getMessages ( Locale locale ) { CmsMessages result = null ; if ( ( m_messageBundleNames == null ) || m_messageBundleNames . isEmpty ( ) ) { return new CmsMessages ( Messages . get ( ) . getBundleName ( ) , locale ) ; } else { CmsMultiMessages multiMessages = new CmsMultiMessages ( locale ) ; for ( String messageBundleName : m_messageBundleNames ) { multiMessages . addMessages ( new CmsMessages ( messageBundleName , locale ) ) ; } if ( ! m_messageBundleNames . contains ( Messages . get ( ) . getBundleName ( ) ) ) { multiMessages . addMessages ( new CmsMessages ( Messages . get ( ) . getBundleName ( ) , locale ) ) ; } result = multiMessages ; } return result ; }
@see org.opencms.xml.content.I_CmsXmlContentHandler#getMessages(java.util.Locale)