Skip to content

Commit

Permalink
Resolved lint whitespace errors
Browse files Browse the repository at this point in the history
  • Loading branch information
Jithesh.Poojary authored and Jithesh.Poojary committed Jan 10, 2024
1 parent 2ae6a33 commit cf4449e
Show file tree
Hide file tree
Showing 2 changed files with 104 additions and 104 deletions.
192 changes: 96 additions & 96 deletions Conductor/Api/WorkflowResourceApi.cs
Original file line number Diff line number Diff line change
Expand Up @@ -72,26 +72,26 @@ public interface IWorkflowResourceApi : IApiAccessor
/// <returns>WorkflowRun</returns>
WorkflowRun ExecuteWorkflow(StartWorkflowRequest body, string requestId, string name, int? version, string waitUntilTaskRef = null);

/// <summary>
/// Update the value of the workflow variables for the given workflow id
/// </summary>
/// <param name="workflow"></param>
/// <returns>ApiResponse of Object(void)</returns>
Object UpdateWorkflowVariables(Workflow workflow);
/// <summary>
/// Execute a workflow synchronously
/// </summary>
/// <remarks>
///
/// </remarks>
/// <exception cref="Conductor.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="body"></param>
/// <param name="requestId"></param>
/// <param name="name"></param>
/// <param name="version"></param>
/// <param name="waitUntilTaskRef"> (optional)</param>
/// <returns>ApiResponse of WorkflowRun</returns>
ApiResponse<WorkflowRun> ExecuteWorkflowWithHttpInfo(StartWorkflowRequest body, string requestId, string name, int? version, string waitUntilTaskRef = null);
/// <summary>
/// Update the value of the workflow variables for the given workflow id
/// </summary>
/// <param name="workflow"></param>
/// <returns>ApiResponse of Object(void)</returns>
Object UpdateWorkflowVariables(Workflow workflow);
/// <summary>
/// Execute a workflow synchronously
/// </summary>
/// <remarks>
///
/// </remarks>
/// <exception cref="Conductor.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="body"></param>
/// <param name="requestId"></param>
/// <param name="name"></param>
/// <param name="version"></param>
/// <param name="waitUntilTaskRef"> (optional)</param>
/// <returns>ApiResponse of WorkflowRun</returns>
ApiResponse<WorkflowRun> ExecuteWorkflowWithHttpInfo(StartWorkflowRequest body, string requestId, string name, int? version, string waitUntilTaskRef = null);
/// <summary>
/// Gets the workflow by workflow id
/// </summary>
Expand Down Expand Up @@ -1035,82 +1035,82 @@ public ApiResponse<WorkflowRun> ExecuteWorkflowWithHttpInfo(StartWorkflowRequest
(WorkflowRun)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(WorkflowRun)));
}

public Object UpdateWorkflowVariables(Workflow workflow)
{
ApiResponse<Object> localVarResponse = UpdateWorkflowVariablesWithHttpInfo(workflow);
return localVarResponse.Data;
}

public ApiResponse<Object> UpdateWorkflowVariablesWithHttpInfo(Workflow workflow)
{
// verify the required parameter 'body' is set
if (workflow == null)
throw new ApiException(400, "Missing required parameter 'body' when calling WorkflowResourceApi->Update");

if (string.IsNullOrEmpty(workflow.WorkflowId))
throw new ApiException(400, "Missing required parameter 'WorkflowId' when calling WorkflowResourceApi->Update");

if (workflow.Variables == null)
throw new ApiException(400, "Missing required parameter 'Variables' when calling WorkflowResourceApi->Update");

var localVarPath = $"/workflow/{workflow.WorkflowId}/variables";
var localVarPathParams = new Dictionary<String, String>();
var localVarQueryParams = new List<KeyValuePair<String, String>>();
var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
var localVarFormParams = new Dictionary<String, String>();
var localVarFileParams = new Dictionary<String, FileParameter>();
Object localVarPostBody = null;

// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
"application/json"
};
String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"*/*"
};
String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

if (workflow != null && workflow.GetType() != typeof(byte[]))
{
localVarPostBody = this.Configuration.ApiClient.Serialize(workflow.Variables);
}

// authentication (api_key) required
if (!String.IsNullOrEmpty(this.Configuration.AccessToken))
{
localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
}

IRestResponse localVarResponse = (IRestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
Method.POST, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
localVarPathParams, localVarHttpContentType);
int localVarStatusCode = (int)localVarResponse.StatusCode;

if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("Update", localVarResponse);
if (exception != null) throw exception;
}

return new ApiResponse<Object>(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
(Object)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(Object)));
}

/// <summary>
/// Gets the workflow by workflow id
/// </summary>
/// <exception cref="Conductor.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="workflowId"></param>
/// <param name="includeTasks"> (optional, default to true)</param>
/// <param name="summarize"> (optional, default to false)</param>
/// <returns>Workflow</returns>
public Workflow GetExecutionStatus(string workflowId, bool? includeTasks = null, bool? summarize = null)
public Object UpdateWorkflowVariables(Workflow workflow)
{
ApiResponse<Object> localVarResponse = UpdateWorkflowVariablesWithHttpInfo(workflow);
return localVarResponse.Data;
}

public ApiResponse<Object> UpdateWorkflowVariablesWithHttpInfo(Workflow workflow)
{
// verify the required parameter 'body' is set
if (workflow == null)
throw new ApiException(400, "Missing required parameter 'body' when calling WorkflowResourceApi->Update");

if (string.IsNullOrEmpty(workflow.WorkflowId))
throw new ApiException(400, "Missing required parameter 'WorkflowId' when calling WorkflowResourceApi->Update");

if (workflow.Variables == null)
throw new ApiException(400, "Missing required parameter 'Variables' when calling WorkflowResourceApi->Update");

var localVarPath = $"/workflow/{workflow.WorkflowId}/variables";
var localVarPathParams = new Dictionary<String, String>();
var localVarQueryParams = new List<KeyValuePair<String, String>>();
var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
var localVarFormParams = new Dictionary<String, String>();
var localVarFileParams = new Dictionary<String, FileParameter>();
Object localVarPostBody = null;

// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
"application/json"
};
String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"*/*"
};
String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);

if (workflow != null && workflow.GetType() != typeof(byte[]))
{
localVarPostBody = this.Configuration.ApiClient.Serialize(workflow.Variables);
}

// authentication (api_key) required
if (!String.IsNullOrEmpty(this.Configuration.AccessToken))
{
localVarHeaderParams["X-Authorization"] = this.Configuration.AccessToken;
}

IRestResponse localVarResponse = (IRestResponse)this.Configuration.ApiClient.CallApi(localVarPath,
Method.POST, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
localVarPathParams, localVarHttpContentType);
int localVarStatusCode = (int)localVarResponse.StatusCode;

if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("Update", localVarResponse);
if (exception != null) throw exception;
}

return new ApiResponse<Object>(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Name, x => string.Join(",", x.Value)),
(Object)this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(Object)));
}

/// <summary>
/// Gets the workflow by workflow id
/// </summary>
/// <exception cref="Conductor.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="workflowId"></param>
/// <param name="includeTasks"> (optional, default to true)</param>
/// <param name="summarize"> (optional, default to false)</param>
/// <returns>Workflow</returns>
public Workflow GetExecutionStatus(string workflowId, bool? includeTasks = null, bool? summarize = null)
{
ApiResponse<Workflow> localVarResponse = GetExecutionStatusWithHttpInfo(workflowId, includeTasks, summarize);
return localVarResponse.Data;
Expand Down
16 changes: 8 additions & 8 deletions Conductor/Definition/ConductorWorkflow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,14 @@ public ConductorWorkflow WithOutputParameter(string key, object value)
return this;
}

public ConductorWorkflow WithVariable(string key, object value)
{
if (Variables == null) // if workflow does not have any variables, initialize with empty collection
Variables = new Dictionary<string, object>();
Variables.Add(key, value);
return this;
}
public ConductorWorkflow WithOwner(string ownerEmail)
public ConductorWorkflow WithVariable(string key, object value)
{
if (Variables == null) // if workflow does not have any variables, initialize with empty collection
Variables = new Dictionary<string, object>();
Variables.Add(key, value);
return this;
}
public ConductorWorkflow WithOwner(string ownerEmail)
{
OwnerEmail = ownerEmail;
return this;
Expand Down

0 comments on commit cf4449e

Please sign in to comment.