EmailAddress.withEmailAddress constructor

EmailAddress.withEmailAddress(
  1. EmailAddress mailbox
)
Initializes a new instance of the The name used to initialize the EmailAddress. The address used to initialize the EmailAddress. The routing type used to initialize the EmailAddress. Mailbox type of the participant. ItemId of a Contact or PDL. Initializes a new instance of the EMailAddress instance to copy.

Implementation

//        EmailAddress(
//            String name,
//            String address,
//            String routingType,
//            MailboxType mailboxType,
//            ItemId itemId)
//            : this(name, address, routingType)
//        {
//            this.mailboxType = mailboxType;
//            this.id = itemId;
//        }

/// <summary>
/// Initializes a new instance of the <see cref="EmailAddress"/> class from another EmailAddress instance.
/// </summary>
/// <param name="mailbox">EMailAddress instance to copy.</param>
EmailAddress.withEmailAddress(EmailAddress mailbox) : super() {
  EwsUtilities.ValidateParam(mailbox, "mailbox");

  this.Name = mailbox.Name;
  this.Address = mailbox.Address;
  this.RoutingType = mailbox.RoutingType;
  this.MailboxType = mailbox.MailboxType;
  this.Id = mailbox.Id;
}