Class LocalisedMessageException

All Implemented Interfaces:
Serializable

public class LocalisedMessageException extends TranslatableException
Generic exception for any exception that can directly provide a localized message
See Also:
  • Constructor Details

    • LocalisedMessageException

      public LocalisedMessageException(String localizedMessage)
      Parameters:
      localizedMessage -

      The localized message of this exception

    • LocalisedMessageException

      public LocalisedMessageException(String localizedMessage, @Nullable @Nullable Portal portal, @Nullable @Nullable MessageType messageType)
      Parameters:
      localizedMessage -

      the localized message of this exception

      portal -

      The the portal of this exception

      messageType -

      The message type of this exception

  • Method Details

    • getTranslatableMessage

      protected TranslatableMessage getTranslatableMessage()
      Specified by:
      getTranslatableMessage in class TranslatableException
      Returns:

      A translatable message that can be used to determine the localized message of this exception

    • getLocalisedMessage

      public String getLocalisedMessage(LanguageManager manager)
      Overrides:
      getLocalisedMessage in class TranslatableException
      Parameters:
      manager -

      A language manager able to provide localized messages

      Returns:

      The localized message of this exception

    • getPortal

      @Nullable public @Nullable Portal getPortal()
      Returns:

      The portal where this exception came from

    • getMessageType

      @Nullable public @Nullable MessageType getMessageType()
      Returns:

      The type of this localized message