Annotation Interface NlsSafe


@Experimental @Retention(CLASS) @Documented @Target({TYPE_USE,METHOD,PARAMETER,FIELD,LOCAL_VARIABLE}) public @interface NlsSafe
Marker annotation for strings that don't require localization but still could be displayed in UI.

Examples:

  • File name or path
  • Project name
  • URL
  • Programming language or framework name
Avoid using NlsSafe just to suppress the "hardcoded string" inspection warning. Use @NonNls if something is not intended to be displayed to the user: internal identifier, XML tag attribute, substring to be searched in the external process output, etc.