Exemplo n.º 1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="CampaignVoiceSendRequest" /> class.
        /// </summary>
        /// <param name="listId">listId (required).</param>
        /// <param name="segments">segments (required).</param>
        /// <param name="notify">Array of IDs of the users to notify.</param>
        /// <param name="destinationField">Destination field of this campaign (required).</param>
        /// <param name="uniqueContactsOnly">True to send the campaign only to unique contacts (default to false).</param>
        /// <param name="limitContacts">limitContacts.</param>
        /// <param name="limitHour">limitHour.</param>
        /// <param name="limitSpeed">Speed limit to send the campaign.</param>
        /// <param name="scheduleDate">The date and time.</param>
        public CampaignVoiceSendRequest(int listId = default(int), OSegmentsActionSend segments = default(OSegmentsActionSend), List <int> notify = default(List <int>), DestinationFieldEnum destinationField = default(DestinationFieldEnum), bool uniqueContactsOnly = false, OLimitContactsActionSend limitContacts = default(OLimitContactsActionSend), LimitHourActionSendLimitHour limitHour = default(LimitHourActionSendLimitHour), int limitSpeed = default(int), DateTime scheduleDate = default(DateTime))
        {
            // to ensure "listId" is required (not null)
            if (listId == null)
            {
                throw new InvalidDataException("listId is a required property for CampaignVoiceSendRequest and cannot be null");
            }
            else
            {
                this.ListId = listId;
            }

            // to ensure "segments" is required (not null)
            if (segments == null)
            {
                throw new InvalidDataException("segments is a required property for CampaignVoiceSendRequest and cannot be null");
            }
            else
            {
                this.Segments = segments;
            }

            // to ensure "destinationField" is required (not null)
            if (destinationField == null)
            {
                throw new InvalidDataException("destinationField is a required property for CampaignVoiceSendRequest and cannot be null");
            }
            else
            {
                this.DestinationField = destinationField;
            }

            this.Notify = notify;
            // use default value if no "uniqueContactsOnly" provided
            if (uniqueContactsOnly == null)
            {
                this.UniqueContactsOnly = false;
            }
            else
            {
                this.UniqueContactsOnly = uniqueContactsOnly;
            }
            this.LimitContacts = limitContacts;
            this.LimitHour     = limitHour;
            this.LimitSpeed    = limitSpeed;
            this.ScheduleDate  = scheduleDate;
        }
Exemplo n.º 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="SegmentsActionSend" /> class.
 /// </summary>
 /// <param name="segments">segments.</param>
 public SegmentsActionSend(OSegmentsActionSend segments = default(OSegmentsActionSend))
 {
     this.Segments = segments;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="CampaignVoiceSendRequest" /> class.
 /// </summary>
 public CampaignVoiceSendRequest(int?listId = default(int?), OSegmentsActionSend segments = default(OSegmentsActionSend), List <int?> notify = default(List <int?>), DestinationFieldEnum?destinationField = default(DestinationFieldEnum?), OLimitContactsActionSend limitContacts = default(OLimitContactsActionSend), LimitHourActionSendLimitHour limitHour = default(LimitHourActionSendLimitHour), int?limitSpeed = default(int?), DateTime?scheduleDate = default(DateTime?))
 {
 }
Exemplo n.º 4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="AbstractSendVoice" /> class.
 /// </summary>
 /// <param name="destinationField">Destination field of this campaign.</param>
 public AbstractSendVoice(DestinationFieldEnum?destinationField = default(DestinationFieldEnum?), OSegmentsActionSend segments = default(OSegmentsActionSend), List <int?> notify = default(List <int?>), OLimitContactsActionSend limitContacts = default(OLimitContactsActionSend), LimitHourActionSendLimitHour limitHour = default(LimitHourActionSendLimitHour), int?limitSpeed = default(int?)) : base(segments)
 {
     this.DestinationField = destinationField;
 }