/// <summary> /// Converts a <see cref="DataValidationOperator"/> to a <see cref="OperatorType"/>. /// </summary> /// <param name="dataValidationOperator">The data validation operator to convert.</param> /// <returns> /// A <see cref="OperatorType"/> converted from a <see cref="DataValidationOperator"/>. /// </returns> public static OperatorType ToOperatorType( this DataValidationOperator dataValidationOperator) { switch (dataValidationOperator) { case DataValidationOperator.Between: return(OperatorType.Between); case DataValidationOperator.EqualTo: return(OperatorType.Equal); case DataValidationOperator.GreaterThan: return(OperatorType.GreaterThan); case DataValidationOperator.GreaterThanOrEqualTo: return(OperatorType.GreaterOrEqual); case DataValidationOperator.LessThan: return(OperatorType.LessThan); case DataValidationOperator.LessThanOrEqualTo: return(OperatorType.LessOrEqual); case DataValidationOperator.None: return(OperatorType.None); case DataValidationOperator.NotBetween: return(OperatorType.NotBetween); case DataValidationOperator.NotEqualTo: return(OperatorType.NotEqual); default: throw new NotSupportedException(Invariant($"This {nameof(DataValidationOperator)} is not supported: {dataValidationOperator}")); } }
public virtual DataValidation DeepCloneWithOperator(DataValidationOperator @operator) { throw new NotImplementedException("This method should be abstract. It was generated as virtual so that you aren't forced to override it when you create a new model that derives from this model. It will be overridden in the generated designer file."); }