\Dewdrop\Db\Dbdeploy\CommandStatus

Check the status of the supplied changesets, letting you know what revisions are currently applied in the database along with what revisions are available but not yet applied.

Summary

Methods
Properties
Constants
__construct()
execute()
getAvailableChangesCount()
getAvailableChangesBySet()
No public properties found
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
$changesets
$availableChangesCount
$availableChangesBySet
N/A

Properties

$changesets

$changesets : array

The changesets whose status you'd like to check.

Type

array

$availableChangesCount

$availableChangesCount : integer

The number of available changes found during the previous call to execute.

Type

integer

$availableChangesBySet

$availableChangesBySet : array

An array of available change files and current revisions, grouped by changeset.

Type

array

Methods

__construct()

__construct(array  $changesets) 

Provide an array of changesets to check when calling execute().

Parameters

array $changesets

execute()

execute() : boolean

Iterate overall all available changesets and check their status.

You can call getAvailableChangesCount() and getAvailableChangesBySet() after execute() to get status information.

Returns

boolean

getAvailableChangesCount()

getAvailableChangesCount() : integer

Get the number of available changes following a call to execute().

Returns

integer

getAvailableChangesBySet()

getAvailableChangesBySet() : array

Get an array of status information following a call to execute. Will follow this format:

array(
    'changeset-1' => array(
        'current' => 8,
        'files'   => array(
            9  => '00009-new-revision.sql',
            10 => '00010-new-revision.sql'
        )
    ),
    'changeset-2' => array(
        'current' => 8,
        'files'   => array()
    ),
)

Returns

array