Message (JBoss Logging I18n Documentation 2.2.1.Final API)

org.jboss.logging.annotations

## Annotation Type Message

-     @Target(value=METHOD)
       @Retention(value=CLASS)
       @Documented
      public @interface Message

  Assigns a message string to a resource method. The method arguments are used to supply the positional parameter values for the method.
  Author:
    David M. Lloyd

- - ### Field Summary

    Fields
    Modifier and Type | Fields and Description
    --- | ---
    `static int` | `INHERIT` Indicates that this message should inherit the ID from another message with the same name.
    `static int` | `NONE` Indicates that this message has no ID.

  - ### Required Element Summary

    Required Elements
    Modifier and Type | Required Element and Description
    --- | ---
    `String` | `value` The default format string of this message.

  - ### Optional Element Summary

    Optional Elements
    Modifier and Type | Optional Element and Description
    --- | ---
    `Message.Format` | `format` The format type of this method (defaults to `Message.Format.PRINTF`).
    `int` | `id` The message ID number.

- - ### Field Detail

    - #### NONE

          public static final int NONE

      Indicates that this message has no ID.

  - - #### INHERIT

          public static final int INHERIT

      Indicates that this message should inherit the ID from another message with the same name.

  - ### Element Detail

    - #### value

          public abstract String value

      The default format string of this message.

      Expressions in the form of `${property.key:default-value}` can be used for the value. If the property key is prefixed with `sys.` a system property will be used. If the key is prefixed with `env.` an environment variable will be used. In all other cases the `org.jboss.logging.tools.expressionProperties` processor argument is used to specify the path the properties file which contains the values for the expressions.

      Returns:
        the format string

  - - #### id

          public abstract int id

      The message ID number. Only one message with a given name may specify an ID other than `INHERIT`.
      Returns:
        the message ID number
      Default:
        -1

  - - #### format

          public abstract Message.Format format

      The format type of this method (defaults to `Message.Format.PRINTF`).
      Returns:
        the format type
      Default:
        org.jboss.logging.annotations.Message.Format.PRINTF

Copyright © 2019 JBoss by Red Hat. All rights reserved.