Annotation Interface LargeDisplay


@Repeatable(LargeDisplays.class) @Retention(RUNTIME) @Target({FIELD,METHOD}) public @interface LargeDisplay
To display the value of the property in large format.

Generally with a large font, inside a small frame with spacing, etc. To make the value clearly visible, for emphasizing the value in the view, or for creating a dashboard style view.
Applies to properties.

Example:

 @LargeDisplay
 int activeUsersCount;
It will display the active user count with a large number in the user interface.
Moreover, you can specify a prefix/suffix and icon, like this:
 @LargeDisplay(suffix = "%", icon="label-percent-outline")
 BigDecimal vatPercentage;
In this case the suffix % is displayed after the value and the icon label-percent-outline is also displayed near the value, the icon is from Material Design Icons, like the ones used for actions.
Also if you combine @LargeDisplay with @Money and don't specify any value for suffix or prefix, the value for suffix/prefix is automatic, so if you write:
 @Money @LargeDisplay
 BigDecimal discount;
Now the discount is displayed with the suffix € if the server is configure for Spain, or with the prefix $ if the server is configured for USA.
Since:
7.4
Author:
Javier Paniza
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    List of comma separated view names where this annotation applies.
    An icon to show near the displayed value.
    List of comma separated view names where this annotation does not apply.
    Prefix to show before the value to be displayed.
    Suffix to show after the value to be displayed.
  • Element Details

    • forViews

      String forViews
      List of comma separated view names where this annotation applies.

      Exclusive with notForViews.
      If both forViews and notForViews are omitted then this annotation apply to all views.
      You can use the string "DEFAULT" for referencing to the default view (the view with no name).

      Default:
      ""
    • notForViews

      String notForViews
      List of comma separated view names where this annotation does not apply.

      Exclusive with forViews.
      If both forViews and notForViews are omitted then this annotation apply to all views.
      You can use the string "DEFAULT" for referencing to the default view (the view with no name).

      Default:
      ""
    • prefix

      String prefix
      Prefix to show before the value to be displayed.

      Often a symbol, but it can be any string.

      Default:
      ""
    • suffix

      String suffix
      Suffix to show after the value to be displayed.

      Often a symbol, but it can be any string.

      Default:
      ""
    • icon

      String icon
      An icon to show near the displayed value.

      The value is an id from Material Design Icons, like the ones we use when declaring actions.

      Default:
      ""