C# Class Shiloh.DataGeneration.ValueConstraints.ValueConstraints

Defines the current set of value constraints (or range limits) for generating random data.
This is a static class because we need to ensure that the defaults and constraints used by the RandomGenerator to create anonymous test data are the same defaults and constraints used by the DbHelper to insert those values into the database. The main case for this is when a date value is supposed to be null, the min sql value is used (since it cannot be null in memory). When inserting the data..if the value is the min value, a DBNull is actually inserted. The comparison against min value to determine if a DBNull should be inserted is the purpose for this class and the DefaultConstraints class.
ファイルを表示 Open project: ChrisEdwards/Fluency

Public Methods

Method Description
Use ( IValueConstraints valueConstraints ) : void

Uses the specified ValueConstraints for all subsequent calls to Get.

Method Details

Use() public static method

Uses the specified ValueConstraints for all subsequent calls to Get.
public static Use ( IValueConstraints valueConstraints ) : void
valueConstraints IValueConstraints The value constraints.
return void