PHP Class Pantheon\Terminus\Collections\Workflows

Inheritance: extends TerminusCollection, implements Pantheon\Terminus\Session\SessionAwareInterface, use trait Pantheon\Terminus\Session\SessionAwareTrait
Mostrar archivo Open project: pantheon-systems/terminus Class Usage Examples

Protected Properties

Property Type Description
$collected_class string
$owner mixed

Public Methods

Method Description
__construct ( array $options = [] ) Instantiates the collection, sets param members as properties
allFinished ( ) : Workflow[] Returns all existing workflows that have finished
allWithLogs ( ) : Workflow[] Returns all existing workflows that contain logs
create ( string $type, array $options = [] ) : Workflow Creates a new workflow and adds its data to the collection
fetchWithOperations ( array $options = [] ) : void Fetches workflow data hydrated with operations
findLatestWithLogs ( ) : Workflow | null Get most-recent workflow from existing collection that has logs
getOwnerObject ( ) : mixed Returns the object which controls this collection
getUrl ( ) : string Get the URL for this model
lastCreatedAt ( ) : integer | null Get timestamp of most recently created Workflow
lastFinishedAt ( ) : integer | null Get timestamp of most recently finished workflow

Method Details

__construct() public method

Instantiates the collection, sets param members as properties
public __construct ( array $options = [] )
$options array Options with which to configure this collection

allFinished() public method

Returns all existing workflows that have finished
public allFinished ( ) : Workflow[]
return Workflow[]

allWithLogs() public method

Returns all existing workflows that contain logs
public allWithLogs ( ) : Workflow[]
return Workflow[]

create() public method

Creates a new workflow and adds its data to the collection
public create ( string $type, array $options = [] ) : Workflow
$type string Type of workflow to create
$options array Additional information for the request, with the following possible keys: - environment: string - params: associative array of parameters for the request
return Workflow $model

fetchWithOperations() public method

Fetches workflow data hydrated with operations
public fetchWithOperations ( array $options = [] ) : void
$options array Additional information for the request
return void

findLatestWithLogs() public method

Get most-recent workflow from existing collection that has logs
public findLatestWithLogs ( ) : Workflow | null
return Workflow | null

getOwnerObject() public method

Returns the object which controls this collection
public getOwnerObject ( ) : mixed
return mixed

getUrl() public method

Get the URL for this model
public getUrl ( ) : string
return string

lastCreatedAt() public method

Get timestamp of most recently created Workflow
public lastCreatedAt ( ) : integer | null
return integer | null Timestamp

lastFinishedAt() public method

Get timestamp of most recently finished workflow
public lastFinishedAt ( ) : integer | null
return integer | null Timestamp

Property Details

$collected_class protected_oe property

protected string $collected_class
return string

$owner protected_oe property

protected mixed $owner
return mixed