com.aspose.email

Interfaces

Classes

Enums

Exceptions

com.aspose.email

Class MailAddress

    • Constructor Detail

      • MailAddress

        public MailAddress(String address,
                   boolean ignoreSmtpCheck)

        Initializes a new instance of the MailAddress class.

        Parameters:
        address - The mail address.
        ignoreSmtpCheck - if set to true then SMTP check will be omitted.
      • MailAddress

        public MailAddress(String address,
                   String displayName,
                   boolean ignoreSmtpCheck)

        Initializes a new instance of the MailAddress class.

        Parameters:
        address - The mail address.
        displayName - The display name.
        ignoreSmtpCheck - if set to true then SMTP check will be omitted.
      • MailAddress

        public MailAddress(String address,
                   String displayName,
                   Charset displayNameEncoding)

        Initializes a new instance of the MailAddress class.

        Parameters:
        address - The mail address.
        displayName - The display name.
        displayNameEncoding - The display name encoding.
      • MailAddress

        public MailAddress(String address,
                   String displayName,
                   Charset displayNameEncoding,
                   boolean ignoreSmtpCheck)

        Initializes a new instance of the MailAddress class.

        Parameters:
        address - The mail address.
        displayName - The display name.
        displayNameEncoding - The display name encoding.
        ignoreSmtpCheck - if set to true then SMTP check will be omitted.
      • MailAddress

        public MailAddress(String address)

        Initializes a new instance of the MailAddress class.

        Parameters:
        address - The mail address.
      • MailAddress

        public MailAddress(String address,
                   String displayName)

        Initializes a new instance of the MailAddress class.

        Parameters:
        address - The mail address.
        displayName - The display name.
    • Method Detail

      • getDisplayName

        public String getDisplayName()

        Gets or sets a display name.

        Value: A String that contains the display name.
        Specified by:
        getDisplayName in interface IMailAddress
        Returns:
        a String object.
      • setDisplayName

        public void setDisplayName(String value)

        Gets or sets a display name.

        Value: A String that contains the display name.
        Specified by:
        setDisplayName in interface IMailAddress
        Parameters:
        value - a String object.
      • getUser

        public String getUser()

        Gets the username.

        Value: A String that contains the user name.
      • getHost

        public String getHost()

        Gets the host portion of the address.

        Value: A String that contains the name of the host.
      • getAddress

        public String getAddress()

        Gets or sets the e-mail address.

        Value: A String that contains the e-mail address.
        Specified by:
        getAddress in interface IMailAddress
        Returns:
        a String object.
      • setAddress

        public void setAddress(String value)

        Gets or sets the e-mail address.

        Value: A String that contains the e-mail address.
        Specified by:
        setAddress in interface IMailAddress
        Parameters:
        value - a String object.
      • getOriginalAddressString

        public String getOriginalAddressString()

        Gets or sets the original e-mail address string.

        Value: A String that contains the original e-mail address.
      • getCount

        public int getCount()

        Contains count of mail addresses.

      • get_Item

        public MailAddress get_Item(int i)

        Gets the element at the specified index.

        Parameters:
        i - The zero-based index of the element to get or set.
        Returns:
        Returns the element at the specified index.
      • getId

        public ObjectIdentifier getId()

        Gets object identification information

      • to_MailAddress

        public static MailAddress to_MailAddress(String address)

        Performs an implicit conversion from System.String to MailAddress.

        Parameters:
        address - The address.
        Returns:
        The result of the conversion.
      • to_MailAddress

        public static MailAddress to_MailAddress(MailAddressCollection addresses)

        Performs an implicit conversion from MailAddressCollection to MailAddress.

        Parameters:
        addresses - The address collection.
        Returns:
        The result of the conversion.
      • toString

        public String toString()

        Returns a System.String that represents this instance.

        Overrides:
        toString in class Object
        Returns:
        A System.String that represents this instance.
      • equals

        public boolean equals(Object value)

        Determines whether the specified System.Object is equal to this instance.

        Overrides:
        equals in class Object
        Parameters:
        value - The System.Object to compare with this instance.
        Returns:
        true if the specified System.Object is equal to this instance; otherwise, false.
      • hashCode

        public int hashCode()

        Returns a hash code for this instance.

        Overrides:
        hashCode in class Object
        Returns:
        A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table.