/// <summary> /// Executes a command on the given <see cref="AppDriver"/> /// </summary> /// <param name="appDriver"> /// The <see cref="AppDriver"/> on which to executor the command. /// </param> /// <param name="name"> /// The name of the command. /// </param> /// <param name="jsonParameters"> /// The parameters of the command. /// </param> /// <returns> /// The response of the execution. /// </returns> private static Response ExecuteCommand(this AppDriver appDriver, string name, string jsonParameters) { var command = new Command(name, jsonParameters); var response = appDriver.GetCommandExecutor().Execute(command); return(response); }
/// <summary> /// Executes a command on the given <see cref="AppDriver"/> /// </summary> /// <param name="appDriver"> /// The <see cref="AppDriver"/> on which to executor the command. /// </param> /// <param name="name"> /// The name of the command. /// </param> /// <param name="parameters"> /// The parameters of the command. /// </param> /// <returns> /// The response of the execution. /// </returns> private static Response ExecuteCommand(this AppDriver appDriver, string name, Dictionary <string, object> parameters) { var command = new Command(appDriver.SessionId, name, parameters); var response = appDriver.GetCommandExecutor().Execute(command); return(response); }
/// <summary> /// Executes a command on the given <see cref="AppDriver"/> /// </summary> /// <typeparam name="T"> /// The response type /// </typeparam> /// <param name="appDriver"> /// The <see cref="AppDriver"/> on which to executor the command. /// </param> /// <param name="name"> /// The name of the command. /// </param> /// <param name="jsonParameters"> /// The parameters of the command. /// </param> /// <returns> /// The response of the execution. /// </returns> private static T ExecuteCommand <T>(this AppDriver appDriver, string name, string jsonParameters) { var command = new Command(name, jsonParameters); return(appDriver.GetCommandExecutor().Execute <T>(command)); }
/// <summary> /// Executes a command on the given <see cref="AppDriver"/> /// </summary> /// <typeparam name="T"> /// The response type /// </typeparam> /// <param name="appDriver"> /// The <see cref="AppDriver"/> on which to executor the command. /// </param> /// <param name="name"> /// The name of the command. /// </param> /// <param name="parameters"> /// The parameters of the command. /// </param> /// <returns> /// The response of the execution. /// </returns> private static T ExecuteCommand <T>(this AppDriver appDriver, string name, Dictionary <string, object> parameters) { var command = new Command(appDriver.SessionId, name, parameters); return(appDriver.GetCommandExecutor().Execute <T>(command)); }