Class AbstractMessageHelper

  • Direct Known Subclasses:
    MessageMethod, ScriptMessage

    public class AbstractMessageHelper
    extends java.lang.Object
    Author:
    Kevin Roast Base class for returning an I18N message string for a WebScript.

    Returns an I18N message resolved for the current locale and specified message ID.

    Firstly the service resource for the parent WebScript will be used for the lookup, followed by the global webscripts.properties resource bundle.

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected java.lang.String resolveMessage​(java.lang.String id, java.lang.Object... args)
      Get an I18Ned message.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AbstractMessageHelper

        public AbstractMessageHelper​(WebScript webscript)
        Constructor
        Parameters:
        webscript - The WebScript to lookup resources against first
    • Method Detail

      • resolveMessage

        protected final java.lang.String resolveMessage​(java.lang.String id,
                                                        java.lang.Object... args)
        Get an I18Ned message.
        Parameters:
        id - The message Id
        args - The optional list of message arguments
        Returns:
        resolved message string or the original ID if unable to find