Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-17292

User API should use a InternetAddress object for setting/getting user emails

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Fixed
    • Major
    • 12.4-rc-1
    • 12.3
    • User
    • None
    • Unit
    • Unknown

    Description

      Right now we return a String but it would be nicer to return a typed object which brings several advantages:

      • It offers more APIs (for example to get the user name in the email, the domain name, etc)
      • It provides a type to use in a displayer

      The reason for choosing InternetAddress is because it's standard (in javamail) and we already use it in the API for the mail sender, and we already have a Converter to convert from String to InternetAddress (which extends Address which is abstract).

      It could be better to use our own type. To be decided quickly.

      Attachments

        Issue Links

          Activity

            People

              vmassol Vincent Massol
              vmassol Vincent Massol
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: