Beispiel #1
0
 /// <summary>
 /// Creates a question returning the <see cref="IWebElement"/> values as booleans
 /// </summary>
 /// <param name="state"></param>
 /// <returns></returns>
 public static IQuestion <ImmutableArray <bool> > AsBoolean(this ManyUIState <IWebElement> state)
 {
     return(state.As(BooleanConverter));
 }
Beispiel #2
0
 /// <summary>
 /// Creates a question returning the <see cref="IWebElement"/> values as integers
 /// </summary>
 /// <param name="state"></param>
 /// <returns></returns>
 public static IQuestion <ImmutableArray <int> > AsInteger(this ManyUIState <IWebElement> state)
 {
     return(state.As(IntegerConverter));
 }
Beispiel #3
0
 /// <summary>
 /// Creates a question returning the <see cref="IWebElement"/> values as strings
 /// </summary>
 /// <param name="state"></param>
 /// <returns></returns>
 public static IQuestion <ImmutableArray <string> > AsText(this ManyUIState <IWebElement> state)
 {
     return(state.As(TextConverter));
 }
Beispiel #4
0
 /// <summary>
 /// Creates a question returning the <see cref="IWebElement"/> values as DateTimes
 /// </summary>
 /// <param name="state"></param>
 /// <returns></returns>
 public static IQuestion <ImmutableArray <DateTime> > AsDateTime(this ManyUIState <IWebElement> state)
 {
     return(state.As(DateTimeConverter));
 }
 /// <summary>
 /// Creates a question returning the string values as enums
 /// </summary>
 /// <param name="state">The source state</param>
 /// <typeparam name="T">The type of the enum</typeparam>
 /// <returns></returns>
 public static IQuestion <ImmutableArray <T> > AsEnum <T>(this ManyUIState <string> state) where T : struct
 {
     return(state.As(new StringToEnumConverter <T>()));
 }
Beispiel #6
0
 /// <summary>
 /// Creates a question returning the string values as integers
 /// </summary>
 /// <param name="state">The source state</param>
 /// <returns></returns>
 public static IQuestion <ImmutableArray <double> > AsDouble(this ManyUIState <string> state)
 {
     return(state.As(DoubleConverter));
 }