/// <summary> /// Initializes a new instance of the RecipientBlock class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public RecipientBlock(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the ExtendedRuleCondition class. /// </summary> public ExtendedRuleCondition() { this.countType = CountByte.TwoBytesCount; }
/// <summary> /// Initializes a new instance of the CommentRestriction class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public CommentRestriction(CountByte countType) { this.RestrictType = RestrictionType.CommentRestriction; this.CountType = countType; }
/// <summary> /// Generate a rule action. /// </summary> /// <param name="actionTypes">The action Type.</param> /// <param name="countBytes">The length of the bytes count.</param> /// <param name="actionDataBufferValue">The actionData buffer.</param> /// <param name="actionFlavor">Action flavor value.</param> /// <param name="actionFlags">Action flag value.</param> /// <returns>An instance of the RuleAction.</returns> private static RuleAction GetRuleAction(ActionType[] actionTypes, CountByte countBytes, IActionData[] actionDataBufferValue, uint[] actionFlavor, uint[] actionFlags) { ActionBlock[] actionBlocks = new ActionBlock[actionTypes.Length]; for (int i = 0; i < actionDataBufferValue.Length; i++) { ActionBlock actionBlock = new ActionBlock(countBytes) { ActionType = actionTypes[i], ActionFlags = actionFlags[i], ActionDataValue = actionDataBufferValue[i], ActionFlavor = actionFlavor[i] }; // Get actionBlock size int lengthOfActionLength = 0; if (actionBlock.CountType == CountByte.TwoBytesCount) { lengthOfActionLength += 2; } else if (actionBlock.CountType == CountByte.FourBytesCount) { lengthOfActionLength += 4; } // Length of ActionType is 1 // Length of ActionFlavor is 4 // Length of ActionFlags is 4 int size = lengthOfActionLength + 1 + 4 + 4 + actionBlock.ActionDataValue.Size(); actionBlock.ActionLength = (countBytes == CountByte.TwoBytesCount) ? (size - 2) : (size - 4); actionBlocks[i] = actionBlock; } RuleAction ruleAction = new RuleAction(countBytes) { NoOfActions = actionBlocks.Length, Actions = actionBlocks }; return ruleAction; }
/// <summary> /// Initializes a new instance of the ActionBlock class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public ActionBlock(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the ActionBlock class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public ActionBlock(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the Restrictions class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public Restrictions(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the SubObjectRestriction class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public SubObjectRestriction(CountByte countType) { this.RestrictType = RestrictionType.SubObjectRestriction; this.CountType = countType; }
/// <summary> /// Initializes a new instance of the Restrictions class. /// </summary> public Restrictions() { this.countType = CountByte.TwoBytesCount; }
/// <summary> /// Initializes a new instance of the ForwardDelegateActionData class. /// </summary> public ForwardDelegateActionData() { this.countType = CountByte.TwoBytesCount; }
/// <summary> /// Initializes a new instance of the ForwardDelegateActionData class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public ForwardDelegateActionData(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the RecipientBlock class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public RecipientBlock(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the RecipientBlock class. /// </summary> public RecipientBlock() { this.countType = CountByte.TwoBytesCount; }
/// <summary> /// Initializes a new instance of the NotRestriction class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public NotRestriction(CountByte countType) { this.RestrictType = RestrictionType.NotRestriction; this.CountType = countType; }
/// <summary> /// Initializes a new instance of the ForwardDelegateActionData class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public ForwardDelegateActionData(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the Restrictions class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public Restrictions(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the ActionBlock class. /// </summary> public ActionBlock() { this.countType = CountByte.TwoBytesCount; }
/// <summary> /// Initializes a new instance of the RuleCondition class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public RuleCondition(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the Restrictions class. /// </summary> public Restrictions() { this.countType = CountByte.TwoBytesCount; }
/// <summary> /// Initializes a new instance of the ExtendedRuleCondition class. /// </summary> public ExtendedRuleCondition() { this.countType = CountByte.TwoBytesCount; }
/// <summary> /// Generate a rule action. /// </summary> /// <param name="actionType">The action Type.</param> /// <param name="countBytes">The length of the bytes count.</param> /// <param name="actionDataBufferValue">The actionData buffer.</param> /// <param name="actionFlavor">Action flavor value.</param> /// <param name="actionFlags">Action flag value.</param> /// <returns>An instance of the RuleAction.</returns> private static RuleAction GetRuleAction(ActionType actionType, CountByte countBytes, IActionData actionDataBufferValue, uint actionFlavor, uint actionFlags) { ActionBlock actionBlock = new ActionBlock(countBytes) { ActionType = actionType, ActionFlags = actionFlags, ActionDataValue = actionDataBufferValue, ActionFlavor = actionFlavor }; // Get actionBlock size int lengthOfActionLength = 0; if (actionBlock.CountType == CountByte.TwoBytesCount) { lengthOfActionLength += 2; } else if (actionBlock.CountType == CountByte.FourBytesCount) { lengthOfActionLength += 4; } // Length of ActionType is 1 // Length of ActionFlavor is 4 // Length of ActionFlags is 4 int size = lengthOfActionLength + 1 + 4 + 4 + actionBlock.ActionDataValue.Size(); actionBlock.ActionLength = (countBytes == CountByte.TwoBytesCount) ? (size - 2) : (size - 4); RuleAction ruleAction = new RuleAction(countBytes) { NoOfActions = 0x01, Actions = new ActionBlock[1] { actionBlock } }; // Only one rule action is generated. return ruleAction; }
/// <summary> /// Initializes a new instance of the ExtendedRuleCondition class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public ExtendedRuleCondition(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the ActionBlock class. /// </summary> public ActionBlock() { this.countType = CountByte.TwoBytesCount; }
/// <summary> /// Initializes a new instance of the RuleCondition class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public RuleCondition(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the AndRestriction class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public AndRestriction(CountByte countType) { this.RestrictType = RestrictionType.AndRestriction; this.CountType = countType; }
/// <summary> /// Initializes a new instance of the RuleAction class. /// </summary> public RuleAction() { this.countType = CountByte.TwoBytesCount; }
/// <summary> /// Initializes a new instance of the ExtendedRuleCondition class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public ExtendedRuleCondition(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the RuleAction class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public RuleAction(CountByte countType) { this.countType = countType; }
/// <summary> /// Initializes a new instance of the RecipientBlock class. /// </summary> public RecipientBlock() { this.countType = CountByte.TwoBytesCount; }
/// <summary> /// Initializes a new instance of the SubObjectRestriction class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public SubObjectRestriction(CountByte countType) { this.RestrictType = RestrictionType.SubObjectRestriction; this.CountType = countType; }
/// <summary> /// Initializes a new instance of the CountRestriction class. /// </summary> /// <param name="countType">The COUNT Type of this class.</param> public CountRestriction(CountByte countType) { this.RestrictType = RestrictionType.CountRestriction; this.CountType = countType; }
/// <summary> /// Initializes a new instance of the ForwardDelegateActionData class. /// </summary> public ForwardDelegateActionData() { this.countType = CountByte.TwoBytesCount; }