Package org.apache.sling.commons.messaging.mail.internal

## Class SimpleMessageIdProvider

- java.lang.Object
- - org.apache.sling.commons.messaging.mail.internal.SimpleMessageIdProvider

All Implemented Interfaces:
  `MessageIdProvider`

    public final class SimpleMessageIdProvider
    extends Object
    implements MessageIdProvider

Provider for message identifiers.
Creates a `Message-ID` in form of `<UUID>.<current time in milliseconds>@<host>` where `host` is configurable.

See Also:
  `MimeMessage`

### Constructor Summary

Constructors
`SimpleMessageIdProvider()`

### Method Summary

All Methods Instance Methods Concrete Methods
`@NotNull String` `getMessageId​(@NotNull jakarta.mail.internet.MimeMessage message)` Provides an identifier for given message.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### SimpleMessageIdProvider

    public SimpleMessageIdProvider()

### Method Detail

#### getMessageId

    @NotNull
    public @NotNull String getMessageId​(@NotNull
                                        @NotNull jakarta.mail.internet.MimeMessage message)
                                 throws jakarta.mail.MessagingException

Description copied from interface: `MessageIdProvider`
Provides an identifier for given message.

Specified by:
  `getMessageId` in interface `MessageIdProvider`
Parameters:
  `message` - the message to provide an identifier for
Returns:
  the message identifier
Throws:
  `jakarta.mail.MessagingException` - if providing an identifier fails
See Also:
  `MimeMessage.getMessageID()`