/// <summary> /// Initializes a new instance of the <see cref="CampaignRuleAction" /> class. /// </summary> /// <param name="Id">Id.</param> /// <param name="Parameters">The parameters for the CampaignRuleAction. Required for certain actionTypes..</param> /// <param name="ActionType">The action to take on the campaignRuleActionEntities. (required).</param> /// <param name="CampaignRuleActionEntities">The list of entities that this action will apply to. (required).</param> public CampaignRuleAction(string Id = null, CampaignRuleParameters Parameters = null, ActionTypeEnum?ActionType = null, CampaignRuleActionEntities CampaignRuleActionEntities = null) { this.Id = Id; this.Parameters = Parameters; this.ActionType = ActionType; this.CampaignRuleActionEntities = CampaignRuleActionEntities; }
/// <summary> /// Initializes a new instance of the <see cref="CampaignRuleCondition" /> class. /// </summary> /// <param name="Id">Id.</param> /// <param name="Parameters">The parameters for the CampaignRuleCondition. (required).</param> /// <param name="ConditionType">The type of condition to evaluate. (required).</param> public CampaignRuleCondition(string Id = null, CampaignRuleParameters Parameters = null, ConditionTypeEnum?ConditionType = null) { // to ensure "Parameters" is required (not null) if (Parameters == null) { throw new InvalidDataException("Parameters is a required property for CampaignRuleCondition and cannot be null"); } else { this.Parameters = Parameters; } // to ensure "ConditionType" is required (not null) if (ConditionType == null) { throw new InvalidDataException("ConditionType is a required property for CampaignRuleCondition and cannot be null"); } else { this.ConditionType = ConditionType; } this.Id = Id; }
/// <summary> /// Initializes a new instance of the <see cref="CampaignRuleAction" /> class. /// </summary> /// <param name="Id">Id.</param> /// <param name="Parameters">The parameters for the CampaignRuleAction. Required for certain actionTypes..</param> /// <param name="ActionType">The action to take on the campaignRuleActionEntities. (required).</param> /// <param name="CampaignRuleActionEntities">The list of entities that this action will apply to. (required).</param> public CampaignRuleAction(string Id = null, CampaignRuleParameters Parameters = null, ActionTypeEnum?ActionType = null, CampaignRuleActionEntities CampaignRuleActionEntities = null) { // to ensure "ActionType" is required (not null) if (ActionType == null) { throw new InvalidDataException("ActionType is a required property for CampaignRuleAction and cannot be null"); } else { this.ActionType = ActionType; } // to ensure "CampaignRuleActionEntities" is required (not null) if (CampaignRuleActionEntities == null) { throw new InvalidDataException("CampaignRuleActionEntities is a required property for CampaignRuleAction and cannot be null"); } else { this.CampaignRuleActionEntities = CampaignRuleActionEntities; } this.Id = Id; this.Parameters = Parameters; }
/// <summary> /// Initializes a new instance of the <see cref="CampaignRuleCondition" /> class. /// </summary> /// <param name="Id">Id.</param> /// <param name="Parameters">The parameters for the CampaignRuleCondition. (required).</param> /// <param name="ConditionType">The type of condition to evaluate. (required).</param> public CampaignRuleCondition(string Id = null, CampaignRuleParameters Parameters = null, ConditionTypeEnum?ConditionType = null) { this.Id = Id; this.Parameters = Parameters; this.ConditionType = ConditionType; }