public static TestBlueprint.SelectionAlgorithmType Value(object obj, TestBlueprint.SelectionAlgorithmType defaultValue) { try { if (Convert.IsDBNull(obj) || obj.ToString().Contains("NULL")) { return(defaultValue); } else { if (Convert.ToString(obj).StartsWith("adaptive", StringComparison.InvariantCultureIgnoreCase)) { return(TestBlueprint.SelectionAlgorithmType.Adaptive); } else if (Convert.ToString(obj).ToLower() == "fixedform") { return(TestBlueprint.SelectionAlgorithmType.FixedForm); } return(TestBlueprint.SelectionAlgorithmType.Adaptive); } } catch { return(defaultValue); } }
public bool HasSegment(TestBlueprint.SelectionAlgorithmType type) { return(HasSegment(new List <TestBlueprint.SelectionAlgorithmType>() { type })); }
public TestSegment(string id, int position, string formId, string formKey, string algorithmString, TestBlueprint.SelectionAlgorithmType algorithm) { this.ID = id; this.Position = position; this.FormID = formId; this.FormKey = formKey; this.AlgorithmString = algorithmString; this.Algorithm = algorithm; }