Package com.helger.mail.address
Class InternetAddressHelper
java.lang.Object
com.helger.mail.address.InternetAddressHelper
This class handles a single email address. It is split into an address part
and an optional name. The personal name is optional and may be
null.- Author:
- Philip Helger
-
Method Summary
Modifier and TypeMethodDescriptionstatic com.helger.commons.email.EmailAddressgetAsEmailAddress(jakarta.mail.internet.InternetAddress aInternetAddress) Convert the passedInternetAddressto anEmailAddressstatic jakarta.mail.internet.InternetAddressgetAsInternetAddress(com.helger.commons.email.IEmailAddress aAddress, String sCharset) static jakarta.mail.internet.InternetAddressgetAsInternetAddress(com.helger.commons.email.IEmailAddress aAddress, Charset aCharset) static jakarta.mail.internet.InternetAddressgetAsInternetAddress(String sAddress, String sPersonal, String sCharset) static jakarta.mail.internet.InternetAddressgetAsInternetAddress(String sAddress, String sPersonal, Charset aCharset) static jakarta.mail.internet.InternetAddress[]getAsInternetAddressArray(com.helger.commons.collection.impl.ICommonsList<? extends com.helger.commons.email.IEmailAddress> aAddresses, Charset aCharset)
-
Method Details
-
getAsInternetAddress
@Nonnull public static jakarta.mail.internet.InternetAddress getAsInternetAddress(@Nonnull com.helger.commons.email.IEmailAddress aAddress, @Nullable Charset aCharset) throws jakarta.mail.internet.AddressException - Throws:
jakarta.mail.internet.AddressException
-
getAsInternetAddress
@Nonnull public static jakarta.mail.internet.InternetAddress getAsInternetAddress(@Nonnull String sAddress, @Nullable String sPersonal, @Nullable Charset aCharset) throws jakarta.mail.internet.AddressException - Throws:
jakarta.mail.internet.AddressException
-
getAsInternetAddress
@Nonnull public static jakarta.mail.internet.InternetAddress getAsInternetAddress(@Nonnull com.helger.commons.email.IEmailAddress aAddress, @Nullable String sCharset) throws UnsupportedEncodingException, jakarta.mail.internet.AddressException - Throws:
UnsupportedEncodingExceptionjakarta.mail.internet.AddressException
-
getAsInternetAddress
@Nonnull public static jakarta.mail.internet.InternetAddress getAsInternetAddress(@Nonnull String sAddress, @Nullable String sPersonal, @Nullable String sCharset) throws UnsupportedEncodingException, jakarta.mail.internet.AddressException - Throws:
UnsupportedEncodingExceptionjakarta.mail.internet.AddressException
-
getAsInternetAddressArray
@Nonnull public static jakarta.mail.internet.InternetAddress[] getAsInternetAddressArray(@Nonnull com.helger.commons.collection.impl.ICommonsList<? extends com.helger.commons.email.IEmailAddress> aAddresses, @Nullable Charset aCharset) throws jakarta.mail.internet.AddressException - Throws:
jakarta.mail.internet.AddressException
-
getAsEmailAddress
@Nullable public static com.helger.commons.email.EmailAddress getAsEmailAddress(@Nullable jakarta.mail.internet.InternetAddress aInternetAddress) Convert the passedInternetAddressto anEmailAddress- Parameters:
aInternetAddress- Source object. May benull.- Returns:
nullif the source object isnull.
-