State commands

On this page

getState

Find a state by name.

Arguments

Argument Name Type Description

projectName

String

The name for the project that must be unique among all projects. (Required)

workflowName

String

The name of the workflow. (Required)

stateName

String

The name used for the new state (Required)

Usage

import com.electriccloud.client.groovy.ElectricFlow
import com.electriccloud.client.groovy.models.*


ElectricFlow ef = new ElectricFlow()

def result = ef.getState(
                projectName: 'test-projectName',
                workflowName: 'test-workflowName',
                stateName: 'test-stateName')

getStates

Retrieve all states in a workflow.

Arguments

Argument Name Type Description

projectName

String

The name for the project that must be unique among all projects. (Required)

workflowName

String

The name of the workflow. (Required)

Usage

import com.electriccloud.client.groovy.ElectricFlow
import com.electriccloud.client.groovy.models.*


ElectricFlow ef = new ElectricFlow()

def result = ef.getStates(
                projectName: 'test-projectName',
                workflowName: 'test-workflowName')